Use render box background over border draw strategy in cases with background-image
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-12-12  Justin Novosad  <junov@google.com>
2
3         Use render box background over border draw strategy in cases with background-image
4         https://bugs.webkit.org/show_bug.cgi?id=103409
5
6         Reviewed by Simon Fraser.
7
8         The BackgroundOverBorderBleedAvoidance mode was not being used in
9         cases where the background is an opaque image. It was also not
10         being used in cases with multiple layers. The multiple layer
11         case is now safe with respect to color bleeding if the top layer
12         is opaque, thank to the recent addition of layer occlusion culling
13         in r135629.
14
15         No new tests. Testing already covered by the following tests:
16         fast/backgrounds/background-opaque-images-over-color.html
17         fast/backgrounds/gradient-background-leakage-2.html
18
19         * rendering/RenderBox.cpp:
20         (WebCore::RenderBox::determineBackgroundBleedAvoidance):
21         (WebCore::RenderBox::backgroundHasOpaqueTopLayer):
22         * rendering/RenderBox.h:
23         (RenderBox):
24
25 2012-12-12  Ilya Tikhonovsky  <loislo@chromium.org>
26
27         Web Inspector: instrument static parts of RenderBlock and RenderBox
28         https://bugs.webkit.org/show_bug.cgi?id=104660
29
30         Reviewed by Yury Semikhatsky.
31
32         Plain vanilla instrumentation.
33
34         * dom/WebCoreMemoryInstrumentation.cpp:
35         (WebCore):
36         (WebCore::WebCoreMemoryInstrumentation::reportMemoryUsage):
37         * dom/WebCoreMemoryInstrumentation.h:
38         (WebCoreMemoryTypes):
39         (WebCoreMemoryInstrumentation):
40         (WebCore):
41         * inspector/InspectorMemoryAgent.cpp:
42         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
43         * rendering/RenderBlock.cpp:
44         (WebCore::RenderBlock::reportStaticMembersMemoryUsage):
45         (WebCore):
46         * rendering/RenderBlock.h:
47         (RenderBlock):
48         * rendering/RenderBox.cpp:
49         (WebCore::RenderBox::reportStaticMembersMemoryUsage):
50         (WebCore):
51         * rendering/RenderBox.h:
52         (RenderBox):
53
54 2012-12-12  Ilya Tikhonovsky  <loislo@chromium.org>
55
56         Web Inspector: Native Memory Instrumentation: remove fake root MemoryObjectInfo.
57         https://bugs.webkit.org/show_bug.cgi?id=104796
58
59         Reviewed by Yury Semikhatsky.
60
61         It was not a good idea to introduce a fake root MemoryObjectInfo.
62         It makes a problem when we visit an object without its own MemoryObjectType.
63
64         Example: RenderBox has a global pointer to a hash map.
65         HashMap doesn't have its own object type because it is a generic container.
66         It will inherit object type from the fake root memory object info.
67         The same could happen for another container in another class with other MemoryObjectType.
68
69         This fact forces me to create custom process method for root objects
70         because they need to have their own MemoryObjectInfo with customisable memory object type.
71
72         Drive by fix: InstrumentedPointer* was replaced with Wrapper* because actually it is using
73         for instrumented and not instrumented object classes.
74
75         * inspector/MemoryInstrumentationImpl.cpp:
76         (WebCore::MemoryInstrumentationImpl::processDeferredObjects):
77         (WebCore::MemoryInstrumentationImpl::deferObject):
78         (WebCore::MemoryInstrumentationImpl::reportMemoryUsage):
79         * inspector/MemoryInstrumentationImpl.h:
80         (MemoryInstrumentationImpl):
81
82 2012-12-12  Kondapally Kalyan  <kalyan.kondapally@intel.com>
83
84         [EFL [WebGL] [Wk2] Resizing the canvas breaks WebGL.
85         https://bugs.webkit.org/show_bug.cgi?id=104535.
86
87         Reviewed by Kenneth Rohde Christiansen.
88
89         GraphicsContext3DEfl does not re-create the surface on canvas resize, this
90         conflicted with the logic in coordinated graphics Layer.
91         CoordinatedGraphicsLayer checks for GraphicsSurfaceToken to decide if the surface
92         in UI-Process should be recreated or not. With this
93         patch we also check for size of the platform Layer.
94
95         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
96         (WebCore::GraphicsContext3D::createGraphicsSurfaces):
97         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
98         (GraphicsContext3DPrivate::didResizeCanvas):
99         (GraphicsContext3DPrivate::platformLayerSize):
100         * platform/graphics/efl/GraphicsContext3DPrivate.h:
101         (GraphicsContext3DPrivate):
102
103 2012-12-12  Antoine Quint  <graouts@apple.com>
104
105         Web Inspector: Crash in InspectorDOMAgent::pushNodePathToFrontend when inspecting document with CSS generated content
106         https://bugs.webkit.org/show_bug.cgi?id=104780
107
108         Reviewed by Pavel Feldman.
109
110         The pushNodePathForRenderLayerToFrontend() method added to InspectorDOMAgent naively assumed
111         that all RenderLayers have a Node associated to them. However, in the case of CSS generated
112         content, that will not be the case and we would call into pushNodePathToFrontend() with a 0
113         parameter that would hit the first ASSERT in this method. We're now checking that we indeed
114         have an associated node for the provided RenderLayer and return 0 in case we don't, without
115         calling into pushNodePathToFrontend().
116
117         Test: inspector-protocol/layer-tree-generated-content.html
118
119         * inspector/InspectorDOMAgent.cpp:
120         (WebCore::InspectorDOMAgent::pushNodePathForRenderLayerToFrontend):
121
122 2012-12-12  Alexander Pavlov  <apavlov@chromium.org>
123
124         Web Inspector: [Crash] Clear cached stylesheet rules in InspectorStyleSheet::deleteRule()
125         https://bugs.webkit.org/show_bug.cgi?id=104806
126
127         Reviewed by Vsevolod Vlasov.
128
129         Cached rules (m_flatRules) should get cleared whenever a rule is deleted.
130
131         Test: inspector/styles/undo-add-rule-crash.html
132
133         * inspector/InspectorStyleSheet.cpp:
134         (WebCore::InspectorStyleSheet::deleteRule):
135
136 2012-12-12  Stephen White  <senorblanco@chromium.org>
137
138         Unreviewed, rolling out r136975.
139         http://trac.webkit.org/changeset/136975
140         https://bugs.webkit.org/show_bug.cgi?id=90405
141
142         Correctness issues.
143
144         * dom/Element.cpp:
145         * dom/Element.h:
146         (Element):
147         * dom/ElementRareData.h:
148         (ElementRareData):
149         (WebCore::ElementRareData::ElementRareData):
150         * platform/graphics/texmap/TextureMapperImageBuffer.cpp:
151         (WebCore::BitmapTextureImageBuffer::applyFilters):
152         * rendering/FilterEffectRenderer.cpp:
153         (WebCore::createCustomFilterEffect):
154         (WebCore::FilterEffectRenderer::buildReferenceFilter):
155         (WebCore::FilterEffectRenderer::build):
156         * rendering/FilterEffectRenderer.h:
157         (FilterEffectRenderer):
158         * rendering/RenderLayer.cpp:
159         (WebCore::RenderLayer::updateOrRemoveFilterEffectRenderer):
160         * rendering/RenderObject.cpp:
161         (WebCore::RenderObject::willBeDestroyed):
162         * rendering/svg/RenderSVGResourceContainer.cpp:
163         (WebCore::RenderSVGResourceContainer::registerResource):
164         * rendering/svg/SVGResources.cpp:
165         (WebCore::SVGResources::buildCachedResources):
166         * rendering/svg/SVGResourcesCache.cpp:
167         (WebCore::SVGResourcesCache::addResourcesFromRenderObject):
168         (WebCore::SVGResourcesCache::clientStyleChanged):
169         (WebCore::SVGResourcesCache::resourceDestroyed):
170         * svg/SVGDocumentExtensions.cpp:
171         (WebCore::SVGDocumentExtensions::addPendingResource):
172         (WebCore::SVGDocumentExtensions::isElementPendingResources):
173         (WebCore::SVGDocumentExtensions::isElementPendingResource):
174         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
175         (WebCore::SVGDocumentExtensions::removeElementFromPendingResourcesForRemoval):
176         * svg/SVGDocumentExtensions.h:
177         (WebCore):
178         (SVGDocumentExtensions):
179         * svg/SVGElement.cpp:
180         (WebCore::SVGElement::hasPendingResources):
181         (WebCore):
182         (WebCore::SVGElement::setHasPendingResources):
183         (WebCore::SVGElement::clearHasPendingResourcesIfPossible):
184         * svg/SVGElement.h:
185         (SVGElement):
186         (WebCore::SVGElement::buildPendingResource):
187         * svg/SVGElementRareData.h:
188         (WebCore::SVGElementRareData::SVGElementRareData):
189         (WebCore::SVGElementRareData::hasPendingResources):
190         (WebCore::SVGElementRareData::setHasPendingResources):
191         (SVGElementRareData):
192         * svg/SVGStyledElement.cpp:
193         (WebCore::SVGStyledElement::buildPendingResourcesIfNeeded):
194
195 2012-12-12  Stephen White  <senorblanco@chromium.org>
196
197         Unreviewed, rolling out r137022.
198         http://trac.webkit.org/changeset/137022
199
200         Precursor to rollout of 136975.
201
202         * rendering/svg/SVGResources.cpp:
203         (WebCore::SVGResources::buildCachedResources):
204
205 2012-12-12  Stephen White  <senorblanco@chromium.org>
206
207         Unreviewed, rolling out r137027.
208         http://trac.webkit.org/changeset/137027
209
210         Precursor to rollout of 136975.
211
212         * dom/ElementRareData.h:
213         (ElementRareData):
214
215 2012-12-12  Alexei Filippov  <alph@chromium.org>
216
217         Web Inspector: add memory used by memory allocator itself to NMI
218         https://bugs.webkit.org/show_bug.cgi?id=93372
219
220         Make native memory instrumentation report memory retained
221         for the memory allocator internal purposes.
222
223         Reviewed by Yury Semikhatsky.
224
225         * inspector/front-end/NativeMemorySnapshotView.js:
226         (WebInspector.MemoryBlockViewProperties._initialize):
227         * platform/chromium/MemoryUsageSupportChromium.cpp:
228         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
229
230 2012-12-12  Sheriff Bot  <webkit.review.bot@gmail.com>
231
232         Unreviewed, rolling out r137438.
233         http://trac.webkit.org/changeset/137438
234         https://bugs.webkit.org/show_bug.cgi?id=104798
235
236         assertion reached when removing tile (Requested by tmpsantos
237         on #webkit).
238
239         * page/Frame.cpp:
240         (WebCore::Frame::setTiledBackingStoreEnabled):
241         * platform/graphics/TiledBackingStore.cpp:
242         (WebCore::TiledBackingStore::TiledBackingStore):
243         (WebCore::TiledBackingStore::setTileCreationDelay):
244         (WebCore::TiledBackingStore::coverWithTilesIfNeeded):
245         (WebCore::TiledBackingStore::updateTileBuffers):
246         (WebCore::TiledBackingStore::createTiles):
247         (WebCore::TiledBackingStore::isTileBufferUpdatesSuspended):
248         (WebCore::TiledBackingStore::startTileBufferUpdateTimer):
249         (WebCore::TiledBackingStore::tileBufferUpdateTimerFired):
250         (WebCore::TiledBackingStore::startBackingStoreUpdateTimer):
251         (WebCore::TiledBackingStore::backingStoreUpdateTimerFired):
252         * platform/graphics/TiledBackingStore.h:
253         (TiledBackingStore):
254         (WebCore::TiledBackingStore::tileCreationDelay):
255         * platform/graphics/TiledBackingStoreClient.h:
256         (WebCore::TiledBackingStoreClient::tiledBackingStoreUpdatesAllowed):
257
258 2012-12-12  Csaba Osztrogonác  <ossy@webkit.org>
259
260         [Qt] Unreviewed typo fix after r137446.
261
262         * WebCore.pri:
263
264 2012-12-12  Zan Dobersek  <zandobersek@gmail.com>
265
266         [GTK] Remove the last of unnecessary configuration options in configure.ac
267         https://bugs.webkit.org/show_bug.cgi?id=104793
268
269         Reviewed by Martin Robinson.
270
271         Remove the feature define overriding that's based on the automake variables which are
272         not set anymore due to the corresponding configuration options being removed.
273
274         No new tests - no new functionality.
275
276         * GNUmakefile.am:
277
278 2012-12-12  Simon Hausmann  <simon.hausmann@digia.com>
279
280         [Qt] Fix build on Mac
281
282         Reviewed by Csaba Osztrogonác.
283
284         On Mac OS X we have sqlite as a system library available.
285
286         * WebCore.pri:
287
288 2012-12-12  Simon Hausmann  <simon.hausmann@digia.com>
289
290         [Qt] Fix linkage against SQLite
291         https://bugs.webkit.org/show_bug.cgi?id=104781
292
293         Reviewed by Csaba Osztrogonác.
294
295         Detect SQLite either through pkg-config, from the SQLITE3SRCDIR
296         environment variable or from qtbase via a qt5.git build. Bail out early
297         with an error message if neither option applies.
298
299         This removes the usage of $$QT.core.sources and the dependency on Qt's
300         system-sqlite configure setting. We should always favour a system
301         library over a copy in Qt.
302
303         * Target.pri:
304         * WebCore.pri:
305
306 2012-12-12  Allan Sandfeld Jensen  <allan.jensen@digia.com>
307
308         [TexMap] Uninitialized m_context pointer in TextureMapper
309         https://bugs.webkit.org/show_bug.cgi?id=104785
310
311         Reviewed by Kenneth Rohde Christiansen.
312
313         * platform/graphics/texmap/TextureMapper.cpp:
314         (WebCore::TextureMapper::TextureMapper):
315         * platform/graphics/texmap/TextureMapperGL.cpp:
316         (WebCore::TextureMapperGL::TextureMapperGL):
317
318 2012-12-12  Tommy Widenflycht  <tommyw@google.com>
319
320         MediaStream API: Change the data channel descriptor pattern to a handler pattern
321         https://bugs.webkit.org/show_bug.cgi?id=104543
322
323         Reviewed by Kent Tamura.
324
325         In short the code is refactured to use the Handler/Client pattern (see RTCPeerConnectionHandler)
326         instead of the Descriptor pattern.
327         This will fix lifetime/memory/code structure issues in the chromium port.
328
329         Existing tests cover this patch.
330
331         * CMakeLists.txt:
332         * GNUmakefile.list.am:
333         * Modules/mediastream/RTCDataChannel.cpp:
334         (WebCore::RTCDataChannel::create):
335         (WebCore::RTCDataChannel::RTCDataChannel):
336         (WebCore::RTCDataChannel::~RTCDataChannel):
337         (WebCore::RTCDataChannel::label):
338         (WebCore::RTCDataChannel::reliable):
339         (WebCore::RTCDataChannel::readyState):
340         (WebCore::RTCDataChannel::bufferedAmount):
341         (WebCore::RTCDataChannel::send):
342         (WebCore::RTCDataChannel::close):
343         (WebCore::RTCDataChannel::didChangeReadyState):
344         (WebCore::RTCDataChannel::didReceiveStringData):
345         (WebCore::RTCDataChannel::didReceiveRawData):
346         (WebCore::RTCDataChannel::didDetectError):
347         (WebCore::RTCDataChannel::stop):
348         * Modules/mediastream/RTCDataChannel.h:
349         (WebCore):
350         (RTCDataChannel):
351         * Modules/mediastream/RTCPeerConnection.cpp:
352         (WebCore::RTCPeerConnection::didAddRemoteDataChannel):
353         * Modules/mediastream/RTCPeerConnection.h:
354         (RTCPeerConnection):
355         * WebCore.gypi:
356         * platform/chromium/support/WebRTCDataChannel.cpp: Removed.
357         * platform/mediastream/RTCDataChannelDescriptor.h: Removed.
358         * platform/mediastream/RTCDataChannelHandler.h: Copied from Source/WebCore/platform/mediastream/RTCDataChannelDescriptor.cpp.
359         (WebCore):
360         (RTCDataChannelHandler):
361         (WebCore::RTCDataChannelHandler::~RTCDataChannelHandler):
362         * platform/mediastream/RTCDataChannelHandlerClient.h: Renamed from Source/WebCore/platform/mediastream/RTCDataChannelDescriptor.cpp.
363         (WebCore):
364         (RTCDataChannelHandlerClient):
365         (WebCore::RTCDataChannelHandlerClient::~RTCDataChannelHandlerClient):
366         * platform/mediastream/RTCPeerConnectionHandler.cpp:
367         (WebCore):
368         (WebCore::RTCPeerConnectionHandler::create):
369         * platform/mediastream/RTCPeerConnectionHandler.h:
370         (WebCore):
371         (RTCPeerConnectionHandler):
372         * platform/mediastream/RTCPeerConnectionHandlerClient.h:
373         (WebCore):
374         (RTCPeerConnectionHandlerClient):
375         * platform/mediastream/chromium/RTCDataChannelHandlerChromium.cpp: Added.
376         (WebCore):
377         (WebCore::RTCDataChannelHandlerChromium::create):
378         (WebCore::RTCDataChannelHandlerChromium::RTCDataChannelHandlerChromium):
379         (WebCore::RTCDataChannelHandlerChromium::~RTCDataChannelHandlerChromium):
380         (WebCore::RTCDataChannelHandlerChromium::setClient):
381         (WebCore::RTCDataChannelHandlerChromium::label):
382         (WebCore::RTCDataChannelHandlerChromium::isReliable):
383         (WebCore::RTCDataChannelHandlerChromium::bufferedAmount):
384         (WebCore::RTCDataChannelHandlerChromium::sendStringData):
385         (WebCore::RTCDataChannelHandlerChromium::sendRawData):
386         (WebCore::RTCDataChannelHandlerChromium::close):
387         (WebCore::RTCDataChannelHandlerChromium::didChangeReadyState):
388         (WebCore::RTCDataChannelHandlerChromium::didReceiveStringData):
389         (WebCore::RTCDataChannelHandlerChromium::didReceiveRawData):
390         (WebCore::RTCDataChannelHandlerChromium::didDetectError):
391         * platform/mediastream/chromium/RTCDataChannelHandlerChromium.h: Added.
392         (WebCore):
393         (RTCDataChannelHandlerChromium):
394         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
395         (WebCore::RTCPeerConnectionHandlerChromium::createDataChannel):
396         (WebCore::RTCPeerConnectionHandlerChromium::didAddRemoteDataChannel):
397         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
398         (WebCore):
399         (RTCPeerConnectionHandlerChromium):
400
401 2012-12-12  Huang Dongsung  <luxtella@company100.net>
402
403         Coordinated Graphics: Refactor TiledBackingStore code in CoordinatedGraphicsLayer.
404         https://bugs.webkit.org/show_bug.cgi?id=103959
405
406         Reviewed by Kenneth Rohde Christiansen.
407
408         TiledBackingStore::setCommitTileUpdatesOnIdleEventLoop() is used when class
409         methods cannot be called asynchronously by client. Updates of tiles are
410         committed as soon as all the events in event queue have been processed.
411         After this patch Frame sets m_commitTileUpdatesOnIdleEventLoop to true.
412
413         In addition, remove TiledBackingStoreClient::tiledBackingStoreUpdatesAllowed()
414         which was introduced for Coordinated Graphics.
415
416         Refactoring covered by existing tests.
417
418         * page/Frame.cpp:
419         (WebCore::Frame::setTiledBackingStoreEnabled):
420         * platform/graphics/TiledBackingStore.cpp:
421         (WebCore::TiledBackingStore::TiledBackingStore):
422         (WebCore::TiledBackingStore::setTrajectoryVector):
423           Separate setting a trajectory vector from coverWithTilesIfNeeded().
424         (WebCore::TiledBackingStore::coverWithTilesIfNeeded):
425         (WebCore::TiledBackingStore::updateTileBuffers):
426         (WebCore::TiledBackingStore::createTiles):
427         (WebCore::TiledBackingStore::isTileBufferUpdatesSuspended):
428         (WebCore::TiledBackingStore::startTileBufferUpdateTimer):
429         (WebCore::TiledBackingStore::tileBufferUpdateTimerFired):
430         (WebCore::TiledBackingStore::startBackingStoreUpdateTimer):
431         (WebCore::TiledBackingStore::backingStoreUpdateTimerFired):
432         * platform/graphics/TiledBackingStore.h:
433         (TiledBackingStore):
434         (WebCore::TiledBackingStore::setCommitTileUpdatesOnIdleEventLoop):
435         * platform/graphics/TiledBackingStoreClient.h:
436         (WebCore::TiledBackingStoreClient::tiledBackingStoreHasPendingTileCreation):
437             If TiledBackingStore does not create all tiles, TiledBackingStore
438             notifies a client of needing to create tiles more, when
439             m_commitTileUpdatesOnIdleEventLoop is false.
440
441 2012-12-11  Jocelyn Turcotte  <jocelyn.turcotte@digia.com>
442
443         [Qt] Fix the inspector not showing up on Windows
444         https://bugs.webkit.org/show_bug.cgi?id=104677
445
446         Reviewed by Simon Hausmann.
447
448         * Target.pri:
449
450 2012-11-29  Yury Semikhatsky  <yurys@chromium.org>
451
452         Web Inspector: Heap snapshot crashes on any page in MacOS Canary
453         https://bugs.webkit.org/show_bug.cgi?id=103076
454
455         Reviewed by Adam Barth.
456
457         Provide global object name resolver to the heap profiler. The callback allows
458         to safely retrieve document URL to be used as a label for corresponding global
459         object in the heap snapshot.
460
461         Test: inspector-protocol/take-heap-snapshot.html
462
463         * bindings/v8/ScriptProfiler.cpp:
464         (WebCore):
465         (WebCore::ScriptProfiler::takeHeapSnapshot):
466
467 2012-12-12  Sheriff Bot  <webkit.review.bot@gmail.com>
468
469         Unreviewed, rolling out r137428.
470         http://trac.webkit.org/changeset/137428
471         https://bugs.webkit.org/show_bug.cgi?id=104776
472
473         It broke the build everywhere (Requested by Ossy on #webkit).
474
475         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
476         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
477         * platform/graphics/texmap/TextureMapperGL.cpp:
478         (WebCore::TextureMapperGL::drawQuad):
479         (WebCore::TextureMapperGL::drawBorder):
480         (WebCore::TextureMapperGL::drawTexture):
481         (WebCore):
482         (WebCore::TextureMapperGL::drawTextureRectangleARB):
483         (WebCore::TextureMapperGL::drawSolidColor):
484         (WebCore::TextureMapperGL::drawTextureWithAntialiasing):
485         (WebCore::TextureMapperGL::drawTexturedQuadWithProgram):
486         * platform/graphics/texmap/TextureMapperGL.h:
487         (TextureMapperGL):
488         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
489         (WebCore::getShaderSpec):
490         * platform/graphics/texmap/TextureMapperShaderManager.h:
491         (TextureMapperShaderProgram):
492
493 2012-12-12  Martin Robinson  <mrobinson@igalia.com>
494
495         Web inspector prints a warning about "Debug" not being localized
496         https://bugs.webkit.org/show_bug.cgi?id=104679
497
498         Reviewed by Vsevolod Vlasov.
499
500         Add a missing localization entry for the "Debug" string which is used in the web
501         inspector front-end. This prevents warnings about a missing localized version
502         of the word "Debug" and allows it to be properly localized.
503
504         * English.lproj/localizedStrings.js: Add "Debug"
505
506 2012-12-12  Shinya Kawanaka  <shinyak@chromium.org>
507
508         [Shadow DOM] Implement HTMLShadowElement::olderShadowRoot
509         https://bugs.webkit.org/show_bug.cgi?id=104218
510
511         Reviewed by Hajime Morita.
512
513         Implements HTMLShadowElement::olderShadowRoot, which returns the ShadowRoot the HTMLShadowElement is assigned to.
514         When such ShadowRoot does not exist, 0 is returned.
515
516         Test: fast/dom/shadow/olderShadowRoot-in-shadowelement.html
517
518         * dom/ElementShadow.cpp:
519         (WebCore::ElementShadow::ensureDistributionFromDocument): Ensures distribution of this ElementShadow and
520         all of the parent TreeScope distribution. This function will be shared for Bug 104345.
521         (WebCore):
522         * dom/ElementShadow.h:
523         (ElementShadow):
524         * html/shadow/HTMLShadowElement.cpp:
525         (WebCore::HTMLShadowElement::olderShadowRoot):
526         (WebCore):
527         * html/shadow/HTMLShadowElement.h:
528         * html/shadow/HTMLShadowElement.idl:
529
530 2012-12-12  No'am Rosenthal  <noam@webkit.org>
531
532         [Texmap] Consolidate redundant code for ARB_RECT texture
533         https://bugs.webkit.org/show_bug.cgi?id=104705
534
535         Reviewed by Kenneth Rohde Christiansen.
536
537         Instead of having a whole different function for RECT textures,
538         keep the existing functions and pass a flag that tells
539         TextureMapperGL to use the non-normalized coordinates and the
540         RECT shaders.
541
542         No new tests, refactor only. Tested to not break WebGL on
543         Qt-Mac.
544
545         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
546         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
547         * platform/graphics/texmap/TextureMapperGL.cpp:
548         (WebCore::TextureMapperGL::drawQuad):
549             Compensate for rect textures in drawQuad.
550
551         (WebCore::TextureMapperGL::drawBorder):
552         (WebCore::TextureMapperGL::drawTexture):
553         (WebCore::TextureMapperGL::drawSolidColor):
554         (WebCore::TextureMapperGL::drawTextureWithAntialiasing):
555         (WebCore::TextureMapperGL::drawTexturedQuadWithProgram):
556             Pass flags to TextureMapperGL::drawQuad instead of a bool.
557
558         * platform/graphics/texmap/TextureMapperGL.h:
559         (TextureMapperGL):
560         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
561         (WebCore::getShaderSpec):
562         * platform/graphics/texmap/TextureMapperShaderManager.h:
563         (TextureMapperShaderProgram):
564             Compensate for the texture-size in the vertex
565             shader instead of in the fragment shader.
566
567 2012-12-11  Hayato Ito  <hayato@chromium.org>
568
569         REGRESSION(r137408): breaks chromium's browser tests which use WebKitShadowRoot (Requested by hayato on #webkit).
570         https://bugs.webkit.org/show_bug.cgi?id=104770
571
572         Unreviewed, build fix.
573
574         * dom/ShadowRoot.idl:
575         * page/DOMWindow.idl:
576
577 2012-12-11  Sheriff Bot  <webkit.review.bot@gmail.com>
578
579         Unreviewed, rolling out r137333, r137344, r137364, and
580         r137377.
581         http://trac.webkit.org/changeset/137333
582         http://trac.webkit.org/changeset/137344
583         http://trac.webkit.org/changeset/137364
584         http://trac.webkit.org/changeset/137377
585         https://bugs.webkit.org/show_bug.cgi?id=104771
586
587         Caused a raft of browser_test failures in Chromium (Requested
588         by aklein on #webkit).
589
590         * loader/DocumentLoader.cpp:
591         (WebCore::DocumentLoader::setRequest):
592         (WebCore::DocumentLoader::subresource):
593         (WebCore::DocumentLoader::addSubresourceLoader):
594         (WebCore::DocumentLoader::removeSubresourceLoader):
595         (WebCore::DocumentLoader::startLoadingMainResource):
596         * loader/MainResourceLoader.cpp:
597         (WebCore::MainResourceLoader::MainResourceLoader):
598         (WebCore::MainResourceLoader::~MainResourceLoader):
599         (WebCore::MainResourceLoader::receivedError):
600         (WebCore::MainResourceLoader::willCancel):
601         (WebCore::MainResourceLoader::didCancel):
602         (WebCore::MainResourceLoader::continueAfterNavigationPolicy):
603         (WebCore::MainResourceLoader::addData):
604         (WebCore::MainResourceLoader::willSendRequest):
605         (WebCore::MainResourceLoader::continueAfterContentPolicy):
606         (WebCore::MainResourceLoader::didReceiveResponse):
607         (WebCore::MainResourceLoader::didReceiveData):
608         (WebCore::MainResourceLoader::didFinishLoading):
609         (WebCore::MainResourceLoader::didFail):
610         (WebCore::MainResourceLoader::reportMemoryUsage):
611         (WebCore::MainResourceLoader::handleSubstituteDataLoadNow):
612         (WebCore::MainResourceLoader::loadNow):
613         (WebCore):
614         (WebCore::MainResourceLoader::load):
615         (WebCore::MainResourceLoader::setDefersLoading):
616         * loader/MainResourceLoader.h:
617         (MainResourceLoader):
618         * loader/ResourceLoader.cpp:
619         (WebCore::ResourceLoader::willSendRequest):
620         * loader/ResourceLoader.h:
621         (ResourceLoader):
622         (WebCore::ResourceLoader::defersLoading):
623         * loader/SubresourceLoader.cpp:
624         (WebCore::SubresourceLoader::willSendRequest):
625         * loader/appcache/ApplicationCacheHost.cpp:
626         (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainResponse):
627         (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainError):
628         * loader/cache/CachedRawResource.cpp:
629         (WebCore::CachedRawResource::willSendRequest):
630         * loader/cache/CachedResourceLoader.cpp:
631         (WebCore::CachedResourceLoader::loadDone):
632         * loader/mac/DocumentLoaderMac.cpp:
633         (WebCore::DocumentLoader::schedule):
634         (WebCore::DocumentLoader::unschedule):
635
636 2012-12-11  Kentaro Hara  <haraken@chromium.org>
637
638         Unreviewed, rolling out r137398.
639         http://trac.webkit.org/changeset/137398
640         https://bugs.webkit.org/show_bug.cgi?id=104188
641
642         A bunch of webaudio tests hit ASSERTs
643
644         * CMakeLists.txt:
645         * DerivedSources.make:
646         * DerivedSources.pri:
647         * GNUmakefile.list.am:
648         * Modules/webaudio/AudioContext.cpp:
649         (WebCore::AudioContext::createOfflineContext):
650         (WebCore):
651         * Modules/webaudio/AudioContext.h:
652         (AudioContext):
653         * Modules/webaudio/DOMWindowWebAudio.idl:
654         * Modules/webaudio/OfflineAudioContext.cpp: Removed.
655         * Modules/webaudio/OfflineAudioContext.h: Removed.
656         * Modules/webaudio/OfflineAudioContext.idl: Removed.
657         * WebCore.gypi:
658         * WebCore.xcodeproj/project.pbxproj:
659         * bindings/generic/RuntimeEnabledFeatures.h:
660         * bindings/js/JSAudioContextCustom.cpp:
661         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
662         * bindings/v8/custom/V8AudioContextCustom.cpp:
663         (WebCore::V8AudioContext::constructorCallbackCustom):
664
665 2012-12-11  Shinya Kawanaka  <shinyak@chromium.org>
666
667         [Shadow DOM] registering InsertionPoints to ShadowRoot should work out of a document.
668         https://bugs.webkit.org/show_bug.cgi?id=104346
669
670         Reviewed by Hajime Morita.
671
672         We need to register InsertionPoints even if ShadowRoot is out of Document, since distribution should work
673         out of Document, too.
674
675         Instead of checking isInDocument(), we have to make sure InsertionPoint and an element which InsertionPoint
676         inserted into have the same treescope.
677
678         Tests: fast/dom/shadow/has-content-elements.html
679                fast/dom/shadow/has-shadow-insertion-point.html
680
681         * html/shadow/InsertionPoint.cpp:
682         (WebCore::InsertionPoint::insertedInto):
683         (WebCore::InsertionPoint::removedFrom):
684
685 2012-12-11  Takashi Sakamoto  <tasak@google.com>
686
687         Text nodes in shadow roots don't inherit style properly
688         https://bugs.webkit.org/show_bug.cgi?id=101116
689
690         Reviewed by Hajime Morita.
691
692         Use NodeRenderingContext to resolve styles of text nodes.
693         If text nodes are direct children of shadow roots, the text nodes
694         should be inherited styles from their shadow hosts.
695         But if reset-style-inheritance flag is true, the text nodes should
696         not be inherited. And if text nodes are distributed nodes,
697         we have to check whether their insertion point's
698         reset-style-inheritance.
699         c.f. shadow dom spec is:
700         http://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html#styles
701
702         Test: fast/dom/shadow/text-node-in-shadow.html
703
704         * css/StyleResolver.cpp:
705         (WebCore::StyleResolver::styleForElement):
706         Modified to use defaultStyleForElement if the given element has
707         no parent style.
708         (WebCore::StyleResolver::initForStyleResolve):
709         Removed shouldResetStyleInheritance, because now NodeRenderingContext
710         resetStyleInheritance() takes care of reset-style-inheritance of
711         both shadow roots and insertion points.
712         (WebCore::StyleResolver::defaultStyleForElement):
713         Added to create a default style for elements.
714         (WebCore):
715         (WebCore::StyleResolver::styleForText):
716         Use NodeRenderingContext to find the parent node for style from the
717         given text node. If no parent node is found or reset-style-inheritance
718         is true, returns a default style (i.e. empty render style).
719         Otherwise, just returns the found node's style.
720         * css/StyleResolver.h:
721         (StyleResolver):
722         * dom/ComposedShadowTreeWalker.cpp:
723         (WebCore::ComposedShadowTreeWalker::ParentTraversalDetails::didTraverseInsertionPoint):
724         Modify to consider insertion point's resetStyleInheritance.
725         * dom/NodeRenderingContext.cpp:
726         (WebCore::NodeRenderingContext::createRendererForTextIfNeeded):
727         Since NodeRenderingContext has already found a parent node for
728         rendering and style and a parentRenderer is just the found node's
729         renderer, we have to only check reset-style-inheritance.
730         If reset, use default style. Otherwise, the parentRenderer's style.
731         * dom/Text.cpp:
732         (WebCore::Text::recalcTextStyle):
733         Use styleForText instead of parentRenderer's styles if the given text
734         node is a direct child of a shadow root or a direct child of a shadow
735         host.
736
737 2012-12-11  Takashi Sakamoto  <tasak@google.com>
738
739         Hide HOST_RULE behind SHADOW_DOM flag.
740         https://bugs.webkit.org/show_bug.cgi?id=102321
741
742         Reviewed by Dimitri Glazkov.
743
744         @host @-rules are only available when the rules are declared in styles
745         in shadow dom trees. So if SHADOW_DOM is disabled, we don't need
746         @host @-rules.
747
748         No new tests. Just hide HOST_RULE behind SHADOW_DOM flag.
749
750         * css/StyleResolver.h:
751         Hide "class ShadowRuleHost".
752         * css/StyleRule.cpp:
753         (WebCore::StyleRuleBase::reportMemoryUsage):
754         (WebCore::StyleRuleBase::destroy):
755         (WebCore::StyleRuleBase::copy):
756         (WebCore::StyleRuleBase::createCSSOMWrapper):
757         * css/StyleRule.h:
758         (StyleRuleBase):
759         Hide "Host" type and isHostRule.
760         (StyleRuleHost):
761         Hide "class StyleRuleHost".
762         * css/StyleSheetContents.cpp:
763         (WebCore::childRulesHaveFailedOrCanceledSubresources):
764
765 2012-12-11  Dominic Mazzoni  <dmazzoni@google.com>
766
767         AX: accessibilityIsIgnored should avoid computing textUnderElement
768         https://bugs.webkit.org/show_bug.cgi?id=104688
769
770         Reviewed by Chris Fleizach.
771
772         Simplify the logic in accessibilityIsIgnored without affecting
773         the results of any tests. In particular, avoid expensive calls to
774         textUnderElement.
775
776         Covered by existing tests.
777
778         * accessibility/AccessibilityNodeObject.cpp:
779         (WebCore::AccessibilityNodeObject::isGenericFocusableElement):
780         * accessibility/AccessibilityRenderObject.cpp:
781         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
782
783 2012-12-11  Kentaro Hara  <haraken@chromium.org>
784
785         [V8] Reachable event listeners on image elements can be collected in a minor DOM GC
786         https://bugs.webkit.org/show_bug.cgi?id=104734
787
788         Reviewed by Kenneth Russell.
789
790         A major DOM GC treats image elements specially. In
791         V8GCController::opaqueRootForGC(), a major DOM GC puts image elements
792         that have pending activities into the same object group of their document.
793         This guarantees that image elements that have pending activities
794         are not garbage collected in the major DOM GC.
795
796         This patch adds the same special handling to a minor DOM GC to guarantee
797         the same thing in the minor DOM GC too.
798
799         In long-term, we might want to remove the special handling by making
800         image elements active DOM nodes.
801
802         Test: Manually confirmed that all characters in
803         http://alteredqualia.com/three/examples/webgl_animation_skinning_tf2.html
804         are rendered correctly.
805
806         * bindings/v8/V8GCController.cpp:
807         (WebCore::V8GCController::opaqueRootForGC):
808         (WebCore::gcTree):
809
810 2012-12-11  Dominic Mazzoni  <dmazzoni@google.com>
811
812         AX: Make isActionSupported cross-platform.
813         https://bugs.webkit.org/show_bug.cgi?id=104681
814
815         Reviewed by Chris Fleizach.
816
817         Add UserGestureIndicator to increment() and decrement()
818         so that all accessibility actions are treated as
819         user actions, not scripted actions.
820
821         * accessibility/AccessibilityNodeObject.cpp:
822         (WebCore::AccessibilityNodeObject::increment):
823         (WebCore::AccessibilityNodeObject::decrement):
824
825 2012-12-11  Viatcheslav Ostapenko  <v.ostapenko@samsung.com>
826
827         Remove conversion to/from float and float division from ImageFrame::setRGBA
828         https://bugs.webkit.org/show_bug.cgi?id=103693
829
830         Reviewed by Brent Fulgham.
831
832         Replace floating point operations used for alpha premultiply with fixed point arithmetic
833         which is basically integer operations. Allows to shave extra couple percent from decoding
834         images with transparency.
835
836         Covered by existing tests.
837
838         * platform/image-decoders/ImageDecoder.h:
839         (ImageFrame):
840         (WebCore::ImageFrame::fixPointUnsignedMultiply):
841         (WebCore::ImageFrame::setRGBA):
842
843 2012-12-11  Kihong Kwon  <kihong.kwon@samsung.com>
844
845         Vibration API: IDL type doesn't match implementation type
846         https://bugs.webkit.org/show_bug.cgi?id=103899
847
848         Reviewed by Kentaro Hara.
849
850         According to WebIDL, "unsigned long" corresponds to "unsigned" in the platform.
851         Therefore unsigned long need to be changed to unsigned for the Vibration API.
852         - Change a parameter type of vibrate function from unsigned long to unsigned.
853
854         No new tests, it is covered by exist test.
855
856         * Modules/vibration/NavigatorVibration.cpp:
857         (WebCore::NavigatorVibration::vibrate):
858         * Modules/vibration/NavigatorVibration.h:
859         (NavigatorVibration):
860         * Modules/vibration/Vibration.cpp:
861         (WebCore::Vibration::vibrate):
862         * Modules/vibration/Vibration.h:
863         (Vibration):
864         * Modules/vibration/VibrationClient.h:
865         (VibrationClient):
866         * bindings/js/JSDOMBinding.h:
867         * bindings/scripts/CodeGeneratorJS.pm:
868         Remove workaround codes for the Vibration API which is mapped from unsigned long to unsigned long.
869         It should be mapped from unsigned long to unsigned by WebIDL spec.
870         (GetNativeVectorInnerType):
871         * bindings/scripts/test/JS/JSTestObj.cpp:
872         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
873         (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
874
875 2012-12-11  Xinazhu Wang  <wangxianzhu@chromium.org>
876
877         ScrollingCoordinator::hasVisibleSlowRepaintFixedObject() should exclude out-of-view fixed position elements
878         https://bugs.webkit.org/show_bug.cgi?id=102543
879
880         Let RenderLayerCompositor manage the reasons that fixed position elements are not composited.
881         Check the reason in ScrollingCoordinator::hasVisibleSlowRepaintFixedObjects(), don't let fixed position layer not composited with explicit reasons cause slow scrolling.
882
883         Reviewed by James Robinson.
884
885         Test: compositing/layer-creation/fixed-position-out-of-view-scroll-reason.html
886
887         * page/scrolling/ScrollingCoordinator.cpp:
888         (WebCore::ScrollingCoordinator::hasVisibleSlowRepaintFixedObjects): Exclude fixed position elements that are not composited for explicit reasons.
889         * rendering/RenderLayerCompositor.cpp:
890         (WebCore::RenderLayerCompositor::computeCompositingRequirements): Manages m_fixedPositionLayerNotCompositedReasonMap.
891         (WebCore::RenderLayerCompositor::needsToBeComposited):
892         (WebCore::RenderLayerCompositor::requiresCompositingLayer):
893         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
894         * rendering/RenderLayerCompositor.h:
895         (WebCore::RenderLayerCompositor::fixedPositionLayerNotCompositedReason): Now outputs fixedPositionLayerNotCompositedreason.
896         (RenderLayerCompositor):
897
898 2012-12-11  Hayato Ito  <hayato@chromium.org>
899
900         [Shadow DOM] Kill ShadowRoot constructor
901         https://bugs.webkit.org/show_bug.cgi?id=102913
902
903         Reviewed by Dimitri Glazkov.
904
905         Remove ShadowRoot constructor in favor of Element.webkitCreateShadowRoot().
906
907         No new tests. Update existing tests.
908
909         * dom/ShadowRoot.idl:
910         * page/DOMWindow.idl:
911         * testing/Internals.cpp:
912         (WebCore::Internals::createShadowRoot):
913         (WebCore):
914         * testing/Internals.h:
915         (Internals):
916         * testing/Internals.idl:
917
918 2012-12-11  Antti Koivisto  <antti@apple.com>
919
920         Add Element-specific traversal functions
921         https://bugs.webkit.org/show_bug.cgi?id=104685
922
923         Reviewed by Ryosuke Niwa.
924
925         In many cases where we use NodeTraversal we really only want Elements. By having
926         Element specific iteration functions we can tighten the code and make it faster too.
927
928         This patch adds ElementTraversal namespace, similar to NodeTraversal. It also switches
929         bunch of NodeTraversal call sites that obviously only care about elements to using
930         the new interface.
931         
932         This should be a speedup too as we avoid number of branches by not having to look
933         for children of non-ContainerNodes and by allowing use of ContainerNode specific
934         accessors.
935
936         * accessibility/AccessibilityRenderObject.cpp:
937         (WebCore::AccessibilityRenderObject::addImageMapChildren):
938         * css/SelectorChecker.cpp:
939         (WebCore::linkAttribute):
940         (WebCore::SelectorChecker::allVisitedStateChanged):
941         (WebCore::SelectorChecker::visitedStateChanged):
942         * css/StyleInvalidationAnalysis.cpp:
943         (WebCore::elementMatchesSelectorScopes):
944         (WebCore::StyleInvalidationAnalysis::invalidateStyle):
945         * dom/ContainerNodeAlgorithms.h:
946         (WebCore::ChildFrameDisconnector::collectDescendant):
947         * dom/Document.cpp:
948         (WebCore::Document::buildAccessKeyMap):
949         (WebCore::Document::updateBaseURL):
950         (WebCore::Document::processBaseElement):
951         * dom/DocumentOrderedMap.cpp:
952         (WebCore::DocumentOrderedMap::get):
953         * dom/Element.cpp:
954         (WebCore::Element::firstElementChild):
955         * dom/Element.h:
956         (WebCore):
957         * dom/ElementShadow.cpp:
958         (WebCore::ElementShadow::collectSelectFeatureSetFrom):
959         * dom/NodeTraversal.h:
960         (ElementTraversal):
961         (WebCore):
962         (WebCore::ElementTraversal::traverseNextElementTemplate):
963         (WebCore::ElementTraversal::next):
964         (WebCore::ElementTraversal::firstWithin):
965         (WebCore::ElementTraversal::traverseNextElementSkippingChildrenTemplate):
966         (WebCore::ElementTraversal::nextSkippingChildren):
967         (NodeTraversal):
968         * dom/TreeScope.cpp:
969         (WebCore::TreeScope::labelElementForId):
970         (WebCore::TreeScope::findAnchor):
971         * editing/CompositeEditCommand.cpp:
972         (WebCore::CompositeEditCommand::cloneParagraphUnderNewElement):
973         * editing/DeleteSelectionCommand.cpp:
974         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
975         * editing/FrameSelection.cpp:
976         (WebCore::scanForForm):
977         * editing/markup.cpp:
978         (WebCore::completeURLs):
979         * html/HTMLFieldSetElement.cpp:
980         (WebCore::HTMLFieldSetElement::invalidateDisabledStateUnder):
981         (WebCore::HTMLFieldSetElement::childrenChanged):
982         (WebCore::HTMLFieldSetElement::legend):
983         (WebCore::HTMLFieldSetElement::refreshElementsIfNeeded):
984         * html/HTMLFormElement.cpp:
985         (WebCore::HTMLFormElement::formElementIndex):
986         * html/HTMLLabelElement.cpp:
987         (WebCore::HTMLLabelElement::control):
988         * html/HTMLLegendElement.cpp:
989         (WebCore::HTMLLegendElement::associatedControl):
990         * html/HTMLMapElement.cpp:
991         (WebCore::HTMLMapElement::mapMouseEvent):
992         * html/HTMLNameCollection.cpp:
993         (WebCore::HTMLNameCollection::virtualItemAfter):
994         * html/HTMLObjectElement.cpp:
995         (WebCore::HTMLObjectElement::containsJavaApplet):
996         * html/HTMLSelectElement.cpp:
997         (WebCore::HTMLSelectElement::recalcListItems):
998         * html/shadow/ContentDistributor.cpp:
999         (WebCore::ShadowRootContentDistributionData::ensureInsertionPointList):
1000         * page/FocusController.cpp:
1001         (WebCore::FocusController::findFocusCandidateInContainer):
1002         * rendering/RenderCounter.cpp:
1003         (WebCore::nextInPreOrder):
1004         * svg/SVGSVGElement.cpp:
1005         (WebCore::SVGSVGElement::collectIntersectionOrEnclosureList):
1006         * svg/SVGStyledElement.cpp:
1007         (WebCore::SVGStyledElement::title):
1008         * svg/SVGUseElement.cpp:
1009         (WebCore::removeDisallowedElementsFromSubtree):
1010         * svg/animation/SMILTimeContainer.cpp:
1011         (WebCore::SMILTimeContainer::updateDocumentOrderIndexes):
1012
1013 2012-12-11  KyungTae Kim  <ktf.kim@samsung.com>
1014
1015         [soup] Unused parameter in ResourceHandleSoup.cpp
1016         https://bugs.webkit.org/show_bug.cgi?id=104728
1017
1018         Reviewed by Kentaro Hara.
1019
1020         The soupLogPrinter has unused parameter 'logger', 
1021         remove the parameter name to fix 'unused parameter' build warning.
1022
1023         * platform/network/soup/ResourceHandleSoup.cpp:
1024         (WebCore::soupLogPrinter):
1025
1026 2012-12-11  Xianzhu Wang  <wangxianzhu@chromium.org>
1027
1028         Fixed position out-of-view check is incorrect when page is scaled
1029         https://bugs.webkit.org/show_bug.cgi?id=104303
1030
1031         Reviewed by Kenneth Rohde Christiansen.
1032
1033         Test: compositing/layer-creation/fixed-position-out-of-view-scaled.html
1034               compositing/layer-creation/fixed-position-out-of-view-scaled-scroll.html
1035
1036         * rendering/RenderLayerCompositor.cpp:
1037         (WebCore::RenderLayerCompositor::requiresCompositingForPosition): Scale the content rect of the fixed position layer before checking out-of-view.
1038
1039 2012-12-11  Chris Rogers  <crogers@google.com>
1040
1041         Implement OfflineAudioContext constructor
1042         https://bugs.webkit.org/show_bug.cgi?id=104188
1043
1044         Reviewed by Kentaro Hara.
1045
1046         The Web Audio layout tests have relied on an undocumented way (in the specification) to render
1047         audio faster than realtime using an OfflineAudioContext.  We want to expose a proper OfflineAudioContext
1048         object and constructor instead of piggybacking off of the normal AudioContext.
1049             
1050         * CMakeLists.txt:
1051         * DerivedSources.make:
1052         * DerivedSources.pri:
1053         * GNUmakefile.list.am:
1054         * Modules/webaudio/AudioContext.cpp:
1055         (WebCore::AudioContext::isSampleRateRangeGood):
1056         * Modules/webaudio/AudioContext.h:
1057         (AudioContext):
1058         * Modules/webaudio/DOMWindowWebAudio.idl:
1059         * Modules/webaudio/OfflineAudioContext.cpp: Added.
1060         (WebCore):
1061         (WebCore::OfflineAudioContext::create):
1062         (WebCore::OfflineAudioContext::OfflineAudioContext):
1063         (WebCore::OfflineAudioContext::~OfflineAudioContext):
1064         * Modules/webaudio/OfflineAudioContext.h: Added.
1065         (WebCore):
1066         (OfflineAudioContext):
1067         * Modules/webaudio/OfflineAudioContext.idl: Added.
1068         * WebCore.gypi:
1069         * WebCore.xcodeproj/project.pbxproj:
1070         * bindings/generic/RuntimeEnabledFeatures.h:
1071         (WebCore::RuntimeEnabledFeatures::webkitOfflineAudioContextEnabled):
1072         * bindings/js/JSAudioContextCustom.cpp:
1073         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
1074         * bindings/v8/custom/V8AudioContextCustom.cpp:
1075         (WebCore::V8AudioContext::constructorCallbackCustom):
1076
1077 2012-12-11  Jun Jiang  <jun.a.jiang@intel.com>
1078
1079         WebGL: Avoid unnecessary memory copy or conversion in texImage2D and texSubImage2D for HTMLVideoElement
1080         https://bugs.webkit.org/show_bug.cgi?id=102161
1081
1082         Reviewed by Kenneth Russell.
1083
1084         There are several memory copy or conversions in the texImage2D and texSubImage2D for HTMLVideoElement which may be avoided. This patch removes the redundant BackingStore copy if the corresponding Graphics port supports the DontCopyBackingStore behavior. Moreover, it optimizes the AlphaOp if the Image source is from HTMLVideoElement to avoid unnecessary Unmultiply or Premultiply operation in unpack/pack. 
1085
1086         Already covered by current tests. 
1087
1088         * html/canvas/WebGLRenderingContext.cpp:
1089         (WebCore):
1090         (WebCore::WebGLRenderingContext::texImage2DImpl):
1091         (WebCore::WebGLRenderingContext::texImage2D):
1092         (WebCore::WebGLRenderingContext::videoFrameToImage): add a parameter to choose BackingStore copy behavior.
1093         (WebCore::WebGLRenderingContext::texSubImage2DImpl):
1094         (WebCore::WebGLRenderingContext::texSubImage2D):
1095         * html/canvas/WebGLRenderingContext.h:
1096         (WebGLRenderingContext):
1097         * platform/graphics/GraphicsContext3D.cpp:
1098         (WebCore::GraphicsContext3D::ImageExtractor::ImageExtractor):
1099         * platform/graphics/GraphicsContext3D.h:
1100         (ImageExtractor):
1101         (WebCore::GraphicsContext3D::ImageExtractor::imageSourceUnpackAlignment):
1102         (WebCore::GraphicsContext3D::ImageExtractor::imageHtmlDomSource):
1103         * platform/graphics/ImageBuffer.h:
1104         (ImageBuffer):
1105         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
1106         (WebCore::GraphicsContext3D::ImageExtractor::extractImage): optimize the AlphaOp for HTMLVideoElement input.
1107         * platform/graphics/cairo/ImageBufferCairo.cpp:
1108         (WebCore::ImageBuffer::fastCopyImageMode):
1109         (WebCore):
1110         * platform/graphics/cg/ImageBufferCG.cpp:
1111         (WebCore::ImageBuffer::fastCopyImageMode):
1112         (WebCore):
1113         * platform/graphics/qt/ImageBufferQt.cpp:
1114         (WebCore::ImageBuffer::fastCopyImageMode):
1115         (WebCore):
1116         * platform/graphics/skia/GraphicsContext3DSkia.cpp:
1117         (WebCore::GraphicsContext3D::ImageExtractor::extractImage): optimize the AlphaOp for HTMLVideoElement input.
1118         * platform/graphics/skia/ImageBufferSkia.cpp:
1119         (WebCore::ImageBuffer::fastCopyImageMode):
1120         (WebCore):
1121         * platform/graphics/wince/ImageBufferWinCE.cpp:
1122         (WebCore::ImageBuffer::fastCopyImageMode):
1123         (WebCore):
1124         * platform/graphics/wx/ImageBufferWx.cpp:
1125         (WebCore::ImageBuffer::fastCopyImageMode):
1126         (WebCore):
1127
1128 2012-12-11  Viatcheslav Ostapenko  <v.ostapenko@samsung.com>
1129
1130         [EFL] Missing implementation of GraphicsContext3DPrivate::platformLayerSize()
1131         https://bugs.webkit.org/show_bug.cgi?id=104726
1132
1133         Reviewed by Kenneth Rohde Christiansen.
1134
1135         Add common implementation of GraphicsContext3DPrivate::platformLayerSize() similar
1136         to Qt version. There is nothing platform specific in Qt version. 
1137
1138         Covered by existing tests.
1139
1140         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
1141         (GraphicsContext3DPrivate::platformLayerSize):
1142         * platform/graphics/efl/GraphicsContext3DPrivate.h:
1143         (GraphicsContext3DPrivate):
1144
1145 2012-12-11  No'am Rosenthal  <noam@webkit.org>
1146
1147         [Texmap] Slightly improve readability of the antialias shader
1148         https://bugs.webkit.org/show_bug.cgi?id=104708
1149
1150         Reviewed by Martin Robinson.
1151
1152         Modify the antialiasing shader to include separate function that perform
1153         discrete operations, rather than one big function that repeats the same
1154         operations.
1155
1156         No new tests, readability fix.
1157
1158         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
1159         (WebCore::getShaderSpec):
1160
1161 2012-12-11  Tim Horton  <timothy_horton@apple.com>
1162
1163         -webkit-svg-shadow radius changes don't cause children's boundaries to be recomputed
1164         https://bugs.webkit.org/show_bug.cgi?id=104722
1165         <rdar://problem/12821080>
1166
1167         Reviewed by Simon Fraser.
1168
1169         Changes to -webkit-svg-shadow currently cause a relayout of the directly affected renderer
1170         and its parents, but not its children. However, children have the shadow radius
1171         baked into their cached boundaries, so these need to be invalidated.
1172
1173         Test: svg/repaint/repaint-webkit-svg-shadow-container.html
1174
1175         * rendering/RenderObject.h: Expose needsBoundariesUpdate().
1176         * rendering/svg/RenderSVGContainer.h: Expose needsBoundariesUpdate().
1177         * rendering/svg/RenderSVGImage.h: Expose needsBoundariesUpdate().
1178         * rendering/svg/RenderSVGRoot.h: Expose needsBoundariesUpdate().
1179         * rendering/svg/RenderSVGShape.h: Expose needsBoundariesUpdate().
1180         * rendering/svg/SVGRenderSupport.cpp:
1181         (WebCore::SVGRenderSupport::layoutChildren): If the renderer has a shadow and
1182         is in needs of a boundaries update, mark children as needing boundaries updates too.
1183
1184 2012-12-11  Xianzhu Wang  <wangxianzhu@chromium.org>
1185
1186         Add window.internals.mainThreadScrollReasonsAsText for testing slow scrolling
1187         https://bugs.webkit.org/show_bug.cgi?id=104714
1188
1189         Reviewed by Eric Seidel.
1190
1191         No new tests. Adds test api for bug 102543 and other bugs.
1192
1193         * WebCore.exp.in:
1194         * page/Page.cpp:
1195         (WebCore::ScrollingCoordinator::mainThreadScrollingReasonsAsText): Extracted from ScrollingStateScrollingNode::dumpProperties for layout tests.
1196         (WebCore):
1197         * page/Page.h:
1198         (Page):
1199         * page/scrolling/ScrollingCoordinator.cpp:
1200         (WebCore::ScrollingCoordinator::mainThreadScrollingReasonsAsText):
1201         (WebCore):
1202         * page/scrolling/ScrollingCoordinator.h:
1203         (ScrollingCoordinator):
1204         * page/scrolling/ScrollingStateScrollingNode.cpp:
1205         (WebCore::ScrollingStateScrollingNode::dumpProperties): Moved code for mainThreadScrollingReasons to ScrollingCoordinator.cpp.
1206         * testing/Internals.cpp:
1207         (WebCore::Internals::mainThreadScrollingReasons):
1208         (WebCore):
1209         * testing/Internals.h:
1210         * testing/Internals.idl:
1211
1212 2012-12-11  Simon Fraser  <simon.fraser@apple.com>
1213
1214         Enhance the TileCache to cache more tiles
1215         https://bugs.webkit.org/show_bug.cgi?id=104612
1216
1217         Reviewed by Tim Horton.
1218
1219         Add smarts to the TileCache so that it keeps some tiles around
1220         for longer and can prepopulate tiles in to-be-scrolled-to regions.
1221
1222         The new tile management is as follows:
1223         * As before, we expand the visible rect to create a "tile coverage rect"
1224         which is twice the width, and three times the height of the visible rect.
1225         * At the edges, this coverage rect is constrained by them, rather than being
1226         truncated as before (leading to larger initial tile coverage).
1227         * When tiles leave the coverage rect, we keep them around but track
1228         them in cohorts (where a cohort is a set of tiles that left the coverage rect
1229         at the same time).
1230         * If a repaint comes in for a "secondary" tile, we don't paint it, but mark
1231         the tile as being stale. It will get repainted (in full) if it moves back inside
1232         the coverage rect.
1233         * Cohorts are kept around for 2 seconds after they were created. A repeating
1234         1-second timer clears tiles in old cohorts.
1235         * Secondary tiles are pruned if the visible rect changes, or if zooming happens.
1236         * TiledBacking exposes a way to prepopulate a rect with tiles; this is called
1237         when scrolling (e.g. via Home/End keys). Tiles created this way (if outside
1238         the coverage rect) go into a cohort.
1239
1240         * page/FrameView.cpp:
1241         (WebCore::FrameView::requestScrollPositionUpdate): Tell the TiledBacking
1242         to prepopulate some tiles.
1243         * platform/graphics/TiledBacking.h:
1244         (TiledBacking): Add prepopulateRect().
1245         * platform/graphics/ca/mac/TileCache.h:
1246         (TileInfo): The TileMap contains TileInfos, which contain a pointer
1247         to the layer, their cohort, and a 'stale content' flag.
1248         (WebCore::TileCache::TileInfo::TileInfo):
1249         (TileCache):
1250         (TileCohortInfo):
1251         (WebCore::TileCache::TileCohortInfo::TileCohortInfo):
1252         * platform/graphics/ca/mac/TileCache.mm:
1253         (WebCore::TileCache::TileCache):
1254         (WebCore::TileCache::~TileCache):
1255         (WebCore::TileCache::setNeedsDisplay):
1256         (WebCore::TileCache::setNeedsDisplayInRect):
1257         (WebCore::TileCache::setTileNeedsDisplayInRect):
1258         (WebCore::TileCache::setScale):
1259         (WebCore::TileCache::setAcceleratesDrawing):
1260         (WebCore::TileCache::setTilesOpaque):
1261         (WebCore::TileCache::prepopulateRect):
1262         (WebCore::TileCache::setTileDebugBorderWidth):
1263         (WebCore::TileCache::setTileDebugBorderColor):
1264         (WebCore::TileCache::computeTileCoverageRect):
1265         (WebCore::TileCache::tileSizeForCoverageRect):
1266         (WebCore::TileCache::tileRevalidationTimerFired):
1267         (WebCore::TileCache::blankPixelCount):
1268         (WebCore::queueTileForRemoval):
1269         (WebCore::TileCache::removeAllTiles):
1270         (WebCore::TileCache::removeAllSecondaryTiles):
1271         (WebCore::TileCache::removeTilesInCohort):
1272         (WebCore::TileCache::revalidateTiles):
1273         (WebCore::TileCache::nextTileCohort):
1274         (WebCore::TileCache::startedNewCohort):
1275         (WebCore::TileCache::newestTileCohort):
1276         (WebCore::TileCache::oldestTileCohort):
1277         (WebCore::TileCache::scheduleCohortRemoval):
1278         (WebCore::TileCache::cohortRemovalTimerFired):
1279         (WebCore::TileCache::ensureTilesForRect):
1280         (WebCore::TileCache::tileGridExtent):
1281         (WebCore::TileCache::tileCoverageRect):
1282         (WebCore::TileCache::tileLayerAtIndex):
1283         (WebCore::TileCache::drawTileMapContents):
1284
1285 2012-12-11  Simon Fraser  <simon.fraser@apple.com>
1286
1287         Remove redundant AffineTransform in RenderSVGShape::fillAndStrokeShape()
1288         https://bugs.webkit.org/show_bug.cgi?id=104736
1289
1290         Reviewed by Dean Jackson.
1291
1292         RenderSVGShape::fillAndStrokeShape() allocated a AffineTransform on
1293         the stack which was shadowed by another one in narrower scope. It
1294         can be removed.
1295
1296         * rendering/svg/RenderSVGShape.cpp:
1297         (WebCore::RenderSVGShape::fillAndStrokeShape):
1298
1299 2012-12-11  Seokju Kwon  <seokju.kwon@gmail.com>
1300
1301         [EFL] Remove unused headers
1302         https://bugs.webkit.org/show_bug.cgi?id=104661
1303
1304         Reviewed by Ryosuke Niwa.
1305
1306         Header inclusion cleanup.
1307         Remove "NotImplemented.h".
1308
1309         No new tests, no behavior change.
1310
1311         * platform/efl/CursorEfl.cpp:
1312         * platform/efl/FileSystemEfl.cpp:
1313         * platform/efl/ScrollViewEfl.cpp:
1314         * platform/efl/ScrollbarThemeEfl.cpp:
1315         * platform/efl/SoundEfl.cpp:
1316
1317 2012-12-11  Alec Flett  <alecflett@chromium.org>
1318
1319         IndexedDB: Stub out data operations on IDBDatabaseBackendInterface
1320         https://bugs.webkit.org/show_bug.cgi?id=104592
1321
1322         Reviewed by Dimitri Glazkov.
1323
1324         In preparation for removing objectStore/index backend
1325         interfaces, stub out the basic data operations around
1326         get, put, cursors, etc. on IDBDatabaseBackendInterface.
1327
1328         No new tests, this is just preparation for refactoring.
1329
1330         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
1331         (WebCore::IDBDatabaseBackendImpl::get):
1332         (WebCore):
1333         (WebCore::IDBDatabaseBackendImpl::put):
1334         (WebCore::IDBDatabaseBackendImpl::setIndexKeys):
1335         (WebCore::IDBDatabaseBackendImpl::setIndexesReady):
1336         (WebCore::IDBDatabaseBackendImpl::openCursor):
1337         (WebCore::IDBDatabaseBackendImpl::count):
1338         (WebCore::IDBDatabaseBackendImpl::deleteRange):
1339         (WebCore::IDBDatabaseBackendImpl::clear):
1340         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
1341         (IDBDatabaseBackendImpl):
1342         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
1343         (WebCore):
1344         (IDBDatabaseBackendInterface):
1345
1346 2012-12-11  Roger Fong  <roger_fong@apple.com>
1347
1348         Make Video Track compile on Windows in debug mode.
1349         https://bugs.webkit.org/show_bug.cgi?id=104720.
1350
1351         Reviewed by Alexey Proskuryakov.
1352
1353         urlForLogging method was defined in both HTMLMediaElement.cpp and HTMLTrackElement.cpp. 
1354         On Windows all the HTMLElements sources are included in an AllInOne source file, 
1355         so the definitions conflicted. Fixed by renaming the definition in each source file.
1356
1357         * html/HTMLMediaElement.cpp:
1358         (WebCore::urlForLoggingMedia):
1359         (WebCore::HTMLMediaElement::loadResource):
1360         (WebCore::HTMLMediaElement::isSafeToLoadURL):
1361         (WebCore::HTMLMediaElement::didRemoveTrack):
1362         (WebCore::HTMLMediaElement::selectNextSourceChild):
1363         (WebCore::HTMLMediaElement::sourceWasAdded):
1364         (WebCore::HTMLMediaElement::sourceWasRemoved):
1365         * html/HTMLTrackElement.cpp:
1366         (WebCore::urlForLoggingTrack):
1367         (WebCore::HTMLTrackElement::canLoadUrl):
1368
1369 2012-12-11  Ryosuke Niwa  <rniwa@webkit.org>
1370
1371         Mail hangs when resizing the font size of a large RTL text
1372         https://bugs.webkit.org/show_bug.cgi?id=104643
1373
1374         Reviewed by Enrica Casucci.
1375
1376         The bug was caused by ApplyStyleCommand::applyInlineStyleToNodeRange obtaining computed styles while
1377         removing and adding nodes. Fixed the slowness by breaking it into three phases:
1378         1. Split the range into contiguous inline runs, and determine whether styles need to be removed or applied.
1379         2. Remove any conflicting styles, and insert dummy elements at positions where inline styles ought to be
1380         computed as needed.
1381         3. Remove the dummy elements and apply ilnine styles as needed.
1382
1383         No new tests are added since there is no behavior change. This is just a performance improvement. 
1384
1385         * editing/ApplyStyleCommand.cpp:
1386         (WebCore::InlineRunToApplyStyle::InlineRunToApplyStyle):
1387         (WebCore::InlineRunToApplyStyle::startAndEndAreStillInDocument):
1388         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
1389         (WebCore::ApplyStyleCommand::shouldApplyInlineStyleToRun):
1390         (WebCore::ApplyStyleCommand::removeConflictingInlineStyleFromRun):
1391         (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded):
1392         (WebCore::ApplyStyleCommand::positionToComputeInlineStyleChange):
1393         (WebCore::ApplyStyleCommand::applyInlineStyleChange):
1394         * editing/ApplyStyleCommand.h:
1395         * editing/EditingStyle.h:
1396         (WebCore::StyleChange::StyleChange):
1397
1398 2012-12-11  Xianzhu Wang  <wangxianzhu@chromium.org>
1399
1400         Incorrect position of layers for fixed position elements when page is scaled smaller than viewport
1401         https://bugs.webkit.org/show_bug.cgi?id=104294
1402
1403         Reviewed by James Robinson.
1404
1405         Fixed issue in scrollOffsetForFixedPosition when contentRect is smaller than visibleContentRect.
1406         This happens when a page originally bigger than viewport is scaled down to smaller than the viewport.
1407
1408         Test: compositing/geometry/fixed-position-composited-page-scale-smaller-than-viewport.html
1409
1410         * page/scrolling/ScrollingCoordinator.cpp:
1411         (WebCore::fixedPositionScrollOffset): Moved common code in scrollOffsetForFixedPosition here. Fixed issue when contentsSize < visibleContentSize.
1412         (WebCore::scrollOffsetForFixedPosition):
1413
1414 2012-12-11  Beth Dakin  <bdakin@apple.com>
1415
1416         https://bugs.webkit.org/show_bug.cgi?id=104725
1417         Crash in EventHandler::selectCursor() on Mac bots running 
1418         fast/events/mouse-cursor-image-set.html
1419
1420         Reviewed by Tim Horton.
1421
1422         https://bugs.webkit.org/show_bug.cgi?id=99493 enabled image-set for 
1423         the CSS cursor property. Most of the change is guarded behind #if 
1424         ENABLE(MOUSE_CURSOR_SCALE). However, image-set was still allowed to 
1425         parse for the cursor property as long as image-set is enabled 
1426         (which is the current state on the Mac). This would lead to an 
1427         inconsistent state where style information would reflect a world 
1428         where mouse cursor scaling is enabled even though nothing else on 
1429         the Mac would. 
1430
1431         The parsing should also be guarded by the cursor scaling flag.
1432         * css/CSSParser.cpp:
1433         (WebCore::CSSParser::parseValue):
1434
1435 2012-12-11  Emil A Eklund  <eae@chromium.org>
1436
1437         Clamp out-of-range numbers in CSS
1438         https://bugs.webkit.org/show_bug.cgi?id=102735
1439
1440         Reviewed by Simon Fraser.
1441
1442         Currently when a large number (outside of the supported range)
1443         is applied from a style rule or set from javascript using
1444         Element.style we check if it is within the supported range and
1445         set it to zero if it is not. This is incorrect and confusing.
1446         
1447         Change it to clamp values to the supported range. This matches
1448         the behavior in Gecko.
1449
1450         Test: fast/css/large-numbers.html
1451
1452         * css/CSSPrimitiveValue.cpp:
1453         (WebCore::CSSPrimitiveValue::computeLength):
1454         Change to clamp out-of-range values instead of interpreting them
1455         as zero.
1456
1457 2012-12-11  Nate Chapin  <japhet@chromium.org>
1458
1459         Ensure ResourceRequests for main resources include fragment indentifiers when necessary,
1460         regressed by r137333.
1461         https://bugs.webkit.org/show_bug.cgi?id=104721
1462
1463         Rubber-stamped by Dimitri Glazkov.
1464
1465         No new tests.
1466
1467         * loader/SubresourceLoader.cpp:
1468         (WebCore::SubresourceLoader::willSendRequest):
1469
1470 2012-12-11  Huang Dongsung  <luxtella@company100.net>
1471
1472         [GTK] REGRESSION(r135620): Accelerated Compositing does not draw some pages.
1473         https://bugs.webkit.org/show_bug.cgi?id=104640
1474
1475         Reviewed by Noam Rosenthal.
1476
1477         After r135620, Accelerated Compositing does not draw some pages, because
1478         r135620 changes the tree-traversal behavior.  Before r135620, we
1479         returned early if TextureMapperLayer can not get TextureMapper from the
1480         root layer. However, after r135620, we run the tree-traversal even if
1481         TextureMapperLayer can not get TextureMapper.  This patch makes
1482         TextureMapperLayer return early like code before r135620.
1483
1484         Covered by existing tests.
1485
1486         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
1487         (WebCore::GraphicsLayerTextureMapper::flushCompositingState):
1488
1489 2012-12-11  Dan Bernstein  <mitz@apple.com>
1490
1491         <rdar://problem/12771885> Support ruby-position: {before, after}
1492         https://bugs.webkit.org/show_bug.cgi?id=103569
1493
1494         Reviewed by Anders Carlsson.
1495
1496         Specified in <http://www.w3.org/TR/2011/WD-css3-ruby-20110630/#rubypos>, the ruby-position
1497         property takes four values: before, after, inter-character, and inline. This change adds
1498         support for the values before and after.
1499
1500         Test: fast/ruby/position-after.html
1501
1502         * css/CSSComputedStyleDeclaration.cpp:
1503         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Handle ruby-position.
1504         * css/CSSParser.cpp:
1505         (WebCore::isValidKeywordPropertyAndValue): Accept before and after as valid values for
1506         ruby-position.
1507         (WebCore::isKeywordPropertyID): Added ruby-position to the list of properties with keyword
1508         values.
1509         (WebCore::CSSParser::parseValue): Added ruby-position to the switch statement.
1510         * css/CSSPrimitiveValueMappings.h:
1511         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Added mapping from RubyPosition.
1512         (WebCore::CSSPrimitiveValue::operator RubyPosition): Added mapping from CSSPrimitiveValue.
1513         * css/CSSProperty.cpp:
1514         (WebCore::CSSProperty::isInheritedProperty): Added ruby-position as an inherited property.
1515         * css/CSSPropertyNames.in: Added -webkit-ruby-position.
1516         * css/CSSValueKeywords.in: Added after and before.
1517         * css/StyleBuilder.cpp:
1518         (WebCore::StyleBuilder::StyleBuilder): Added a handler for ruby-position.
1519         * css/StyleResolver.cpp:
1520         (WebCore::StyleResolver::applyProperty): Added ruby-position.
1521         * rendering/InlineFlowBox.cpp:
1522         (WebCore::InlineFlowBox::placeBoxesInBlockDirection): Changed to choose which of
1523         hasAnnotationsBefore and hasAnnotationsAfter to set based on ruby position.
1524         (WebCore::InlineFlowBox::computeOverAnnotationAdjustment): Changed to adjust only for
1525         ruby positioned before the base.
1526         (WebCore::InlineFlowBox::computeUnderAnnotationAdjustment): Added adjustment for ruby
1527         positioned after the base.
1528         * rendering/RenderRubyRun.cpp:
1529         (WebCore::RenderRubyRun::layout): Account for ruby-position when positioning the ruby text
1530         relative to the base.
1531         * rendering/style/RenderStyle.cpp:
1532         (WebCore::RenderStyle::diff): Made a ruby-position difference a layout difference.
1533         * rendering/style/RenderStyle.h: Added rubyPosition(), setRubyPosition(), and 
1534         initialRubyPosition().
1535         * rendering/style/RenderStyleConstants.h: Added the RubyPosition enum.
1536         * rendering/style/StyleRareInheritedData.cpp:
1537         (WebCore::StyleRareInheritedData::StyleRareInheritedData): Added initialized for
1538         m_rubyPosition. Added copying the value of this member to the copy constructor.
1539         (WebCore::StyleRareInheritedData::operator==): Added comparison of m_rubyPosition.
1540         * rendering/style/StyleRareInheritedData.h:
1541         (StyleRareInheritedData): Added m_rubyPosition member variable.
1542
1543 2012-12-11  Michael Pruett  <michael@68k.org>
1544
1545         [JSC] Add tests for explicit serialization values
1546         https://bugs.webkit.org/show_bug.cgi?id=104423
1547
1548         Reviewed by Oliver Hunt.
1549
1550         Add tests for serialization and deserialization mechanisms of
1551         the JSC implementation of SerializedScriptValue. Similar tests
1552         already exist for the V8 implementation.
1553
1554         Test: platform/jsc/fast/storage/serialized-script-value.html
1555
1556         * WebCore.exp.in:
1557         * testing/Internals.cpp:
1558         (WebCore::Internals::serializeObject):
1559         (WebCore::Internals::deserializeBuffer):
1560
1561 2012-12-11  Alexis Menard  <alexis@webkit.org>
1562
1563         Cleanup: Use consistent naming in CSSParser when dealing with the forward slash operator.
1564         https://bugs.webkit.org/show_bug.cgi?id=104699
1565
1566         Reviewed by Daniel Bates.
1567
1568         http://trac.webkit.org/changeset/136525 added an helper function to
1569         check if a CSSParserValue is a forward slash operator.
1570         BorderImageParseContext is also dealing with the forward slash operator
1571         but its naming is inconsistent with isForwardSlashOperator(). This is
1572         fixed with this patch where BorderImageParseContext::{allowSlash,
1573         commitSlash}() is now replaced by BorderImageParseContext::{allowForwardSlashOperator,
1574         commitForwardSlashOperator}().
1575
1576         No new tests : just a renaming, covered by existing tests..
1577
1578         * css/CSSParser.cpp:
1579         (WebCore::CSSParser::parseFillPosition): A little fixup on the way, use
1580         isForwardSlashOperator() instead of the current code here.
1581         (WebCore::BorderImageParseContext::BorderImageParseContext):
1582         (WebCore::BorderImageParseContext::allowForwardSlashOperator):
1583         (WebCore::BorderImageParseContext::commitImage):
1584         (WebCore::BorderImageParseContext::commitImageSlice):
1585         (WebCore::BorderImageParseContext::commitForwardSlashOperator):
1586         (WebCore::BorderImageParseContext::commitBorderWidth):
1587         (WebCore::BorderImageParseContext::commitBorderOutset):
1588         (WebCore::BorderImageParseContext::commitRepeat):
1589         (BorderImageParseContext):
1590         (WebCore::CSSParser::parseBorderImage):
1591
1592 2012-12-11  Nate Chapin  <japhet@chromium.org>
1593
1594         cr-linux valgrind is showing leaks due to r137333.
1595
1596         Rubber-stamped by Antti Koivisto.
1597
1598         MainResourceLoader's destructor should call m_resource->removeClient(this) is m_resource is still non-null.
1599         The missing removeClient() call will leak the CachedResource.
1600
1601         No new tests, should shut valgrind up.
1602
1603         * loader/MainResourceLoader.cpp:
1604         (WebCore::MainResourceLoader::~MainResourceLoader):
1605
1606 2012-12-11  Andreas Kling  <akling@apple.com>
1607
1608         REGRESSION(r133492): Heap-use-after-free in WebCore::Element::normalizeAttributes
1609         <http://webkit.org/b/104488>
1610
1611         Reviewed by Antti Koivisto.
1612
1613         Don't cache the AttrNodeList* in a local when iterating over an Element's Attr nodes since
1614         that pointer may go stale if JS runs in response to a DOMSubtreeModified event below Node::normalize().
1615
1616         Test: fast/dom/normalize-attributes-mutation-event-crash.html
1617
1618         * dom/Element.cpp:
1619         (WebCore::Element::normalizeAttributes):
1620
1621 2012-12-11  Jonathon Jongsma  <jonathon.jongsma@collabora.co.uk>
1622
1623         [GTK] Soup network logs are frequently interrupted by other logging messages
1624         https://bugs.webkit.org/show_bug.cgi?id=104668
1625
1626         Reviewed by Martin Robinson.
1627
1628         Set an external soup log printer that uses the WebKit logging
1629         infrastructure so that log messages are properly synchronized.
1630
1631         * platform/network/soup/ResourceHandleSoup.cpp:
1632         (WebCore::soupLogPrinter):
1633         (WebCore):
1634         (WebCore::ensureSessionIsInitialized):
1635
1636 2012-12-11  Elliott Sprehn  <esprehn@chromium.org>
1637
1638         Switch to new PseudoElement based :before and :after
1639         https://bugs.webkit.org/show_bug.cgi?id=104462
1640
1641         Reviewed by Antti Koivisto.
1642
1643         Switch to the new PseudoElement based generated content implementation
1644         that moves :before and :after into the DOM. This also switches to using
1645         the ComposedShadowTreeWalker for determining the siblings of PseudoElement's
1646         making the new generated content implementation support adding :before
1647         and :after into <input> elements.
1648
1649         Tests: fast/css-generated-content/block-inside-inline.html
1650                fast/css-generated-content/box-orient.html
1651
1652         * dom/ComposedShadowTreeWalker.cpp:
1653         (WebCore::ComposedShadowTreeWalker::pseudoAwareNextSibling):
1654         (WebCore):
1655         (WebCore::ComposedShadowTreeWalker::pseudoAwarePreviousSibling):
1656         (WebCore::ComposedShadowTreeWalker::traverseParent):
1657         * dom/ComposedShadowTreeWalker.h:
1658         (ComposedShadowTreeWalker):
1659         * dom/Element.cpp:
1660         (WebCore::Element::attach):
1661         (WebCore::Element::recalcStyle):
1662         * dom/Node.cpp:
1663         * dom/Node.h:
1664         (Node):
1665         * dom/NodeRenderingContext.cpp:
1666         (WebCore::NodeRenderingContext::nextRenderer):
1667         (WebCore::NodeRenderingContext::previousRenderer):
1668         (WebCore::NodeRenderingContext::createRendererForElementIfNeeded):
1669         * dom/Position.cpp:
1670         (WebCore::Position::Position):
1671         (WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
1672         * editing/visible_units.cpp:
1673         (WebCore::logicallyPreviousBox):
1674         (WebCore::logicallyNextBox):
1675         (WebCore::startPositionForLine):
1676         (WebCore::endPositionForLine):
1677         * html/HTMLTextFormControlElement.cpp:
1678         (WebCore::HTMLTextFormControlElement::childShouldCreateRenderer):
1679         * page/DragController.cpp:
1680         (WebCore::DragController::draggableNode):
1681         * rendering/RenderBlock.cpp:
1682         (WebCore::RenderBlock::styleDidChange):
1683         (WebCore::RenderBlock::splitBlocks):
1684         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
1685         (WebCore::RenderBlock::createReplacementRunIn):
1686         (WebCore::RenderBlock::isSelectionRoot):
1687         * rendering/RenderBlock.h:
1688         (RenderBlock):
1689         * rendering/RenderButton.cpp:
1690         * rendering/RenderButton.h:
1691         (RenderButton):
1692         * rendering/RenderInline.cpp:
1693         (WebCore::RenderInline::styleDidChange):
1694         (WebCore::RenderInline::addChildIgnoringContinuation):
1695         (WebCore::RenderInline::splitInlines):
1696         * rendering/RenderListItem.cpp:
1697         (WebCore::RenderListItem::updateMarkerLocation):
1698         * rendering/RenderObject.cpp:
1699         (WebCore::RenderObject::createVisiblePosition):
1700         * rendering/RenderObject.h:
1701         (WebCore::RenderObject::nonPseudoNode):
1702         (RenderObject):
1703         (WebCore::RenderObject::clearNode):
1704         (WebCore::RenderObject::generatingNode):
1705         * rendering/RenderObjectChildList.cpp:
1706         * rendering/RenderObjectChildList.h:
1707         (RenderObjectChildList):
1708         * rendering/RenderRubyText.cpp:
1709         * rendering/RenderRubyText.h:
1710         (RenderRubyText):
1711         * rendering/RenderTableRow.cpp:
1712         (WebCore::RenderTableRow::styleDidChange):
1713         * rendering/RenderTableRow.h:
1714         * rendering/RenderTableSection.cpp:
1715         (WebCore::RenderTableSection::addChild):
1716         * rendering/RenderWidget.cpp:
1717         (WebCore::RenderWidget::destroy):
1718
1719 2012-12-11  Jacky Jiang  <zhajiang@rim.com>
1720
1721         [BlackBerry] Clean up unused defaultViewportArguments in RenderThemeBlackBerry.cpp
1722         https://bugs.webkit.org/show_bug.cgi?id=104683
1723
1724         Reviewed by Rob Buis.
1725
1726         * platform/blackberry/RenderThemeBlackBerry.cpp:
1727         (WebCore::determineFullScreenMultiplier):
1728
1729 2012-12-11  Nate Chapin  <japhet@chromium.org>
1730
1731         Route main resource loads through the memory cache.
1732         https://bugs.webkit.org/show_bug.cgi?id=49246
1733
1734         Reviewed by Antti Koivisto.
1735
1736         Note that this patch doesn't actually enable caching of main resources. That will be done in a later patch.
1737         The MainResourceLoader actually has an underlying SubresourceLoader (with the cache layer between them).
1738         In several places, the MainResourceLoader's SubresourceLoader is treated as special.
1739
1740         No new tests, as this is primarily a refactor. A couple of expected results changed slightly.
1741
1742         * loader/DocumentLoader.cpp:
1743         (WebCore::DocumentLoader::setRequest):
1744         (WebCore::DocumentLoader::subresource):
1745         (WebCore::DocumentLoader::addSubresourceLoader): Because the SubresourceLoader underlying the main resource
1746             needs special handling in certain cases, track it separately from the real SubresourceLoaders.
1747         (WebCore::DocumentLoader::removeSubresourceLoader):
1748         (WebCore::DocumentLoader::startLoadingMainResource):
1749         * loader/MainResourceLoader.cpp:
1750         (WebCore::MainResourceLoader::MainResourceLoader):
1751         (WebCore::MainResourceLoader::receivedError):
1752         (WebCore::MainResourceLoader::cancel):
1753         (WebCore::MainResourceLoader::clearResource):
1754         (WebCore):
1755         (WebCore::MainResourceLoader::frameLoader):
1756         (WebCore::MainResourceLoader::request):
1757         (WebCore::MainResourceLoader::continueAfterNavigationPolicy):
1758         (WebCore::MainResourceLoader::resourceData):
1759         (WebCore::MainResourceLoader::redirectReceived):
1760         (WebCore::MainResourceLoader::willSendRequest):
1761         (WebCore::MainResourceLoader::continueAfterContentPolicy):
1762         (WebCore::MainResourceLoader::responseReceived):
1763         (WebCore::MainResourceLoader::dataReceived):
1764         (WebCore::MainResourceLoader::didFinishLoading):
1765         (WebCore::MainResourceLoader::notifyFinished):
1766         (WebCore::MainResourceLoader::reportMemoryUsage):
1767         (WebCore::MainResourceLoader::handleSubstituteDataLoadNow):
1768         (WebCore::MainResourceLoader::load):
1769         (WebCore::MainResourceLoader::setDefersLoading):
1770         (WebCore::MainResourceLoader::defersLoading):
1771         (WebCore::MainResourceLoader::setShouldBufferData):
1772         (WebCore::MainResourceLoader::loader):
1773         (WebCore::MainResourceLoader::identifier):
1774         * loader/MainResourceLoader.h:
1775         (MainResourceLoader):
1776         (WebCore::MainResourceLoader::documentLoader):
1777         * loader/ResourceLoader.cpp:
1778         (WebCore::ResourceLoader::willSendRequest):
1779         * loader/ResourceLoader.h:
1780         (WebCore::ResourceLoader::defersLoading):
1781         (WebCore::ResourceLoader::cancelled):
1782         * loader/appcache/ApplicationCacheHost.cpp:
1783         (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainResponse):
1784         (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainError):
1785         * loader/mac/DocumentLoaderMac.cpp:
1786         (WebCore::DocumentLoader::schedule):
1787         (WebCore::DocumentLoader::unschedule):
1788
1789 2012-12-11  Aaron Colwell  <acolwell@chromium.org>
1790
1791         Update MediaSource to allow append() calls in "ended" state.
1792         https://bugs.webkit.org/show_bug.cgi?id=104581
1793
1794         Reviewed by Eric Carlson.
1795
1796         Updated append and setTimestampOffset to allow appending in the "ended" readyState. An append() call
1797         in the "ended" state now triggers a transition to the "open" state and allows the append to succeed.
1798
1799         Tests: http/tests/media/media-source/video-media-source-append-in-ended-state.html
1800                http/tests/media/media-source/video-media-source-append-with-offset-in-ended-state.html
1801                http/tests/media/media-source/video-media-source-zero-byte-append-in-ended-state.html
1802
1803         * Modules/mediasource/MediaSource.cpp:
1804         (WebCore::MediaSource::append):
1805         (WebCore::MediaSource::setTimestampOffset):
1806
1807 2012-12-11  Robert Hogan  <robert@webkit.org>
1808
1809         REGRESSION(r121789): Text not wrapping in presence of floating objects
1810         https://bugs.webkit.org/show_bug.cgi?id=101803
1811
1812         Reviewed by David Hyatt.
1813
1814         When determining if a line needs to offset to avoid any floats use RenderBlock::lineHeight() 
1815         to estimate the height of the line. If the container has floats stacked up with different widths
1816         that straddle the line, using a height of zero will make the first line think it has
1817         more width available than it actually does and it will end up extruding from its container.
1818         
1819         The logic for finding the offset of inline blocks and images needs to use a similar heuristic.
1820         So nextLineBreak() now updates the available width if it encounters a replaced element (e.g. inline block,
1821         image) at the start of a line, using the height of the element to decide which floats to avoid. 
1822         RenderBlock::computeInlineDirectionPositionsForLine() does the same thing when laying out the line.
1823
1824         Tests: fast/block/float/floats-offset-image-quirk-lineheight.html
1825                fast/block/float/floats-offset-image-quirk.html
1826                fast/block/float/floats-offset-image-strict-lineheight.html
1827                fast/block/float/floats-offset-image-strict.html
1828                fast/block/float/floats-offset-inline-block-quirk-lineheight.html
1829                fast/block/float/floats-offset-inline-block-strict-lineheight.html
1830                fast/block/float/floats-offset-linebox-contain-block.html
1831                fast/block/float/floats-offset-linebox-contain-inline.html
1832                fast/block/float/floats-wrap-inside-inline-006.html
1833                fast/block/float/floats-wrap-inside-inline-007.html
1834
1835         * rendering/RenderBlockLineLayout.cpp:
1836         (LineWidth):
1837         (WebCore::logicalHeightForLine):
1838             This method needs to cope with the quirk where an image alone on a line will get its descent stripped away so
1839             ignore the height of the line and use the height of the image in that case.
1840         (WebCore::LineWidth::updateAvailableWidth):
1841         (WebCore::updateLogicalInlinePositions):
1842         (WebCore):
1843         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine):
1844         (WebCore::RenderBlock::computeInlineDirectionPositionsForSegment):
1845         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
1846
1847 2012-12-11  Carlos Garcia Campos  <cgarcia@igalia.com>
1848
1849         [GTK] Install GObject DOM bindings headers in its own directory
1850         https://bugs.webkit.org/show_bug.cgi?id=104663
1851
1852         Reviewed by Gustavo Noronha Silva.
1853
1854         Move the headers from webkit to webkitdom directory.
1855
1856         * bindings/gobject/GNUmakefile.am:
1857         * bindings/gobject/WebKitDOMBinding.h:
1858         * bindings/gobject/WebKitDOMCustom.h:
1859         * bindings/gobject/WebKitDOMEventTarget.h:
1860         * bindings/gobject/WebKitDOMEventTargetPrivate.h:
1861         * bindings/gobject/WebKitDOMObject.h:
1862         * bindings/scripts/CodeGeneratorGObject.pm:
1863         (Generate):
1864         (WriteData):
1865         * bindings/scripts/gobject-generate-headers.pl:
1866         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.h:
1867         * bindings/scripts/test/GObject/WebKitDOMFloat64ArrayPrivate.h:
1868         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
1869         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObjectPrivate.h:
1870         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
1871         * bindings/scripts/test/GObject/WebKitDOMTestCallbackPrivate.h:
1872         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
1873         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetterPrivate.h:
1874         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.h:
1875         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructorPrivate.h:
1876         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
1877         * bindings/scripts/test/GObject/WebKitDOMTestEventTargetPrivate.h:
1878         * bindings/scripts/test/GObject/WebKitDOMTestException.h:
1879         * bindings/scripts/test/GObject/WebKitDOMTestExceptionPrivate.h:
1880         * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
1881         * bindings/scripts/test/GObject/WebKitDOMTestInterfacePrivate.h:
1882         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.h:
1883         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListenerPrivate.h:
1884         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.h:
1885         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructorPrivate.h:
1886         * bindings/scripts/test/GObject/WebKitDOMTestNode.h:
1887         * bindings/scripts/test/GObject/WebKitDOMTestNodePrivate.h:
1888         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
1889         * bindings/scripts/test/GObject/WebKitDOMTestObjPrivate.h:
1890         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.h:
1891         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructorsPrivate.h:
1892         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h:
1893         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterfacePrivate.h:
1894
1895 2012-12-11  Mark Pilgrim  <pilgrim@chromium.org>
1896
1897         [Chromium] Clean up unused interfaces in PlatformSupport
1898         https://bugs.webkit.org/show_bug.cgi?id=104674
1899
1900         Reviewed by Darin Fisher.
1901
1902         Part of a refactoring series. See tracking bug 82948. Also, there
1903         were some function declarations that were supposed to be removed
1904         as part of bug 102699 but got left out of the final patch.
1905
1906         * platform/chromium/PlatformSupport.h:
1907         (WebCore):
1908         (PlatformSupport):
1909
1910 2012-12-11  Joone Hur  <joone.hur@intel.com>, Gustavo Noronha Silva  <gustavo.noronha@collabora.com>
1911
1912         [GTK] Update GraphicsLayerClutter
1913         https://bugs.webkit.org/show_bug.cgi?id=92045
1914
1915         Reviewed by Gustavo Noronha Silva.
1916
1917         Add more methods to GraphicsLayerClutter in order to run CSS 3D transforms 
1918         by using GraphicsLayerActor.
1919
1920         No new tests. This will be covered by pixel tests for Qt and GTK+ accelerated
1921         compositing and 3D transforms.
1922
1923         * platform/graphics/clutter/GraphicsLayerClutter.cpp:
1924         (WebCore):
1925         (WebCore::GraphicsLayerClutter::GraphicsLayerClutter):
1926         (WebCore::idleDestroy):
1927         (WebCore::GraphicsLayerClutter::~GraphicsLayerClutter):
1928         (WebCore::GraphicsLayerClutter::setName):
1929         (WebCore::GraphicsLayerClutter::platformLayer): Returns the platform layer(ClutterAcotr).
1930         (WebCore::GraphicsLayerClutter::setNeedsDisplay): Update the display.
1931         (WebCore::GraphicsLayerClutter::setNeedsDisplayInRect): Update part of the Display.
1932         (WebCore::GraphicsLayerClutter::setAnchorPoint):
1933         (WebCore::GraphicsLayerClutter::setPosition):
1934         (WebCore::GraphicsLayerClutter::setSize):
1935         (WebCore::GraphicsLayerClutter::setTransform):
1936         (WebCore::GraphicsLayerClutter::setDrawsContent):
1937         (WebCore::GraphicsLayerClutter::setParent):
1938         (WebCore::GraphicsLayerClutter::setChildren):
1939         (WebCore::GraphicsLayerClutter::addChild):
1940         (WebCore::GraphicsLayerClutter::addChildAtIndex):
1941         (WebCore::GraphicsLayerClutter::addChildBelow):
1942         (WebCore::GraphicsLayerClutter::addChildAbove):
1943         (WebCore::GraphicsLayerClutter::replaceChild):
1944         (WebCore::GraphicsLayerClutter::removeFromParent):
1945         (WebCore::GraphicsLayerClutter::platformClutterLayerPaintContents):
1946         (WebCore::GraphicsLayerClutter::platformClutterLayerAnimationStarted):
1947         (WebCore::GraphicsLayerClutter::repaintLayerDirtyRects):
1948         (WebCore::GraphicsLayerClutter::computePositionRelativeToBase):
1949         (WebCore::GraphicsLayerClutter::flushCompositingState): Synchronize the corresponding Actors with the current 
1950         compositing states of this GraphicsLayer and its child layers. 
1951         (WebCore::GraphicsLayerClutter::recursiveCommitChanges):
1952         (WebCore::GraphicsLayerClutter::flushCompositingStateForThisLayerOnly): Commit batched changes non-recursively. 
1953         (WebCore::GraphicsLayerClutter::commitLayerChangesAfterSublayers): Reset layer changes after we recurse on children.
1954         (WebCore::GraphicsLayerClutter::noteSublayersChanged):
1955         (WebCore::GraphicsLayerClutter::noteLayerPropertyChanged):
1956         (WebCore::GraphicsLayerClutter::commitLayerChangesBeforeSublayers): Commit layer changes before we recurse on children.
1957         (WebCore::GraphicsLayerClutter::updateGeometry): Updated the position and size of the Actor.
1958         (WebCore::GraphicsLayerClutter::updateSublayerList): Updated the list of child Actors. 
1959         (WebCore::GraphicsLayerClutter::updateLayerNames):
1960         (WebCore::GraphicsLayerClutter::updateTransform):
1961         (WebCore::GraphicsLayerClutter::updateLayerDrawsContent):
1962         (WebCore::GraphicsLayerClutter::layerForSuperlayer):
1963         * platform/graphics/clutter/GraphicsLayerClutter.h:
1964         (WebCore):
1965         (WebCore::GraphicsLayerClutter::primaryLayer):
1966         (GraphicsLayerClutter):
1967
1968 2012-12-11  Jessie Berlin  <jberlin@apple.com>
1969
1970         Revert incorrect build fix.
1971
1972         * WebCore.exp.in:
1973
1974 2012-12-11  Jessie Berlin  <jberlin@apple.com>
1975
1976         Fix the Mac build after r137261
1977
1978         * WebCore.exp.in:
1979
1980 2012-12-11  Joone Hur  <joone.hur@intel.com>, Gustavo Noronha Silva  <gustavo.noronha@collabora.com>
1981
1982         [GTK] Add GraphicsLayerActor
1983         https://bugs.webkit.org/show_bug.cgi?id=91940
1984
1985         Reviewed by Gustavo Noronha Silva.
1986
1987         GraphicsLayerActor, which is a new ClutterActor, represents a node in the GPU-renderable layer tree
1988         when accelerated compositing is enabled with Clutter as acceleration backend.
1989         This patch allows to support basic features of CSS 3D Transforms.
1990
1991         No new tests. This will be covered by pixel tests for Qt and GTK+ accelerated
1992         compositing and 3D transforms.
1993
1994         * GNUmakefile.list.am:
1995         * platform/graphics/clutter/GraphicsLayerActor.cpp: Added.
1996         (_GraphicsLayerActorPrivate):
1997         (graphics_layer_actor_class_init): GObject configuration of a new Clutter Actor.
1998         (graphics_layer_actor_init): Initialization of the private data of this actor.
1999         (graphicsLayerActorSetProperty): GObject property setter.
2000         (graphicsLayerActorGetProperty): GObject property getter.
2001         (graphicsLayerActorDispose): Called to drop all references to other objects.
2002         (graphicsLayerActorAllocate):  Called to set the coordinates of an actor.
2003         (graphicsLayerActorApplyTransform): Applying the transformation to an actor before painting it.
2004         (graphicsLayerActorPaint): Called to paint the actor.
2005         (graphicsLayerActorDraw): Called each time a ClutterCairoTexture has been invalidated.
2006         (graphicsLayerActorAdded): Called each time an actor has been added to container.
2007         (graphicsLayerActorRemoved): Called each time an actor is removed from container.
2008         (graphicsLayerActorNew): Create a specific layer type of GraphicsLayerActor object.
2009         (graphicsLayerActorNewWithClient): Create a specific layer type of GraphicsLayerActor object with 
2010         its PlatformClutterClientLayer.
2011         (graphicsLayerActorSetClient): Added setter to set the PlatformClutterClientLayer.
2012         (graphicsLayerActorGetClient): Added getter to get the PlatformClutterClientLayer.
2013         (graphicsLayerActorRemoveAll): Remove all child actors.
2014         (graphicsLayerUpdateTexture): Create a ClutterCairoTexture.
2015         (graphicsLayerActorGetSurface): Added setter to set a cairo_surface_t.
2016         (graphicsLayerActorSetSurface): Added getter to get the cairo_surface_t.
2017         (graphicsLayerActorInvalidateRectangle):
2018         (graphicsLayerActorSetTransform): Set a CoglMatrix to apply matrix transform.
2019         (graphicsLayerActorSetAnchorPoint):
2020         (graphicsLayerActorGetAnchorPoint):
2021         (graphicsLayerActorSetScrollPosition):
2022         (graphicsLayerActorGetnChildren):
2023         (graphicsLayerActorReplaceSublayer):
2024         (graphicsLayerActorInsertSublayer):
2025         (graphicsLayerActorSetSublayers):
2026         (graphicsLayerActorGetLayerType):
2027         (graphicsLayerActorSetLayerType):
2028         (graphicsLayerActorSetTranslateX):
2029         (graphicsLayerActorGetTranslateX):
2030         (graphicsLayerActorSetTranslateY):
2031         (graphicsLayerActorGetTranslateY):
2032         (graphicsLayerActorSetDrawsContent): Added setter to paint content inside a layer.
2033         (graphicsLayerActorGetDrawsContent): Added getter to get the value of the drawsContent. 
2034         * platform/graphics/clutter/GraphicsLayerActor.h: Added.
2035         (_GraphicsLayerActor):
2036         (_GraphicsLayerActorClass):
2037         * platform/graphics/clutter/GraphicsLayerClutter.h:
2038         (WebCore):
2039
2040 2012-12-11  Mike West  <mkwst@chromium.org>
2041
2042         Web Inspector: ConsoleTypes should not expose MessageType - it should be private to inspector.
2043         https://bugs.webkit.org/show_bug.cgi?id=66371
2044
2045         Reviewed by Pavel Feldman.
2046
2047         We can simplify console message generation a bit, as nothing outside the
2048         Console object itself will generate messages of any type other than
2049         LogMessageType. This patch refactors the externally-facing API endpoints
2050         on ScriptExecutionContext and Console to drop the MessageType parameter,
2051         moves the MessageType enum into a new InspectorConsoleTypes.h header,
2052         and updates all the call sites (and ChromeClients) to drop the parameter
2053         from their interfaces.
2054
2055         As a temporary bandage for ports using this interface, this patch
2056         includes aliases for the new methods that retain the old interface.
2057         I'll remove them in a future patch.
2058
2059         Here, we only refactor an internal interface. No tests should break.
2060
2061         * GNUmakefile.list.am:
2062         * Target.pri:
2063         * WebCore.gypi:
2064         * WebCore.vcproj/WebCore.vcproj:
2065         * WebCore.xcodeproj/project.pbxproj:
2066             We added a new file! OMG!
2067         * Modules/webaudio/AudioBufferSourceNode.cpp:
2068         (WebCore::AudioBufferSourceNode::looping):
2069         (WebCore::AudioBufferSourceNode::setLooping):
2070         * Modules/webdatabase/AbstractDatabase.cpp:
2071         (WebCore::AbstractDatabase::logErrorMessage):
2072         * Modules/websockets/WebSocket.cpp:
2073         (WebCore::WebSocket::connect):
2074         (WebCore::WebSocket::send):
2075         (WebCore::WebSocket::close):
2076         (WebCore::WebSocket::setBinaryType):
2077         * Modules/websockets/WebSocketChannel.cpp:
2078         (WebCore::WebSocketChannel::fail):
2079         (WebCore::WebSocketChannel::didFailSocketStream):
2080         * bindings/js/JSCustomXPathNSResolver.cpp:
2081         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
2082         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
2083         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
2084         * css/MediaList.cpp:
2085         (WebCore::addResolutionWarningMessageToConsole):
2086         * dom/Document.cpp:
2087         (WebCore::Document::logExceptionToConsole):
2088         (WebCore::Document::processHttpEquiv):
2089         (WebCore::Document::addMessage):
2090         * dom/Document.h:
2091         (Document):
2092         * dom/ScriptElement.cpp:
2093         (WebCore::ScriptElement::notifyFinished):
2094         * dom/ScriptExecutionContext.cpp:
2095         (WebCore::ScriptExecutionContext::AddConsoleMessageTask::performTask):
2096         (WebCore::ScriptExecutionContext::addConsoleMessage):
2097         * dom/ScriptExecutionContext.h:
2098         (ScriptExecutionContext):
2099         (WebCore::ScriptExecutionContext::AddConsoleMessageTask::create):
2100         (WebCore::ScriptExecutionContext::AddConsoleMessageTask::AddConsoleMessageTask):
2101         * dom/ViewportArguments.cpp:
2102         (WebCore::reportViewportWarning):
2103         * fileapi/WebKitBlobBuilder.cpp:
2104         (WebCore::BlobBuilder::append):
2105         * html/HTMLFormControlElement.cpp:
2106         (WebCore::shouldAutofocus):
2107         * html/HTMLFormElement.cpp:
2108         (WebCore::HTMLFormElement::validateInteractively):
2109         * html/HTMLIFrameElement.cpp:
2110         (WebCore::HTMLIFrameElement::parseAttribute):
2111         * html/HTMLTrackElement.cpp:
2112         (WebCore::HTMLTrackElement::canLoadUrl):
2113         * html/canvas/CanvasRenderingContext2D.cpp:
2114         (WebCore::CanvasRenderingContext2D::getImageData):
2115         * html/canvas/WebGLRenderingContext.cpp:
2116         (WebCore):
2117         (WebCore::WebGLRenderingContext::printWarningToConsole):
2118         * html/parser/XSSAuditor.cpp:
2119         (WebCore::XSSAuditor::init):
2120         (WebCore::XSSAuditor::filterToken):
2121         * inspector/ConsoleAPITypes.h: Added.
2122         (WebCore):
2123         * inspector/ConsoleMessage.h:
2124         * inspector/InspectorConsoleAgent.h:
2125         * inspector/InspectorDebuggerAgent.h:
2126         * inspector/InspectorInstrumentation.cpp:
2127         (WebCore):
2128         * inspector/InspectorInstrumentation.h:
2129         * inspector/InspectorProfilerAgent.cpp:
2130         * loader/EmptyClients.h:
2131         (WebCore::EmptyChromeClient::addMessageToConsole):
2132         * loader/FrameLoader.cpp:
2133         (WebCore::FrameLoader::reportLocalLoadFailed):
2134         (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
2135         * loader/ImageLoader.cpp:
2136         (WebCore::ImageLoader::notifyFinished):
2137         * loader/MainResourceLoader.cpp:
2138         (WebCore::MainResourceLoader::didReceiveResponse):
2139         * loader/MixedContentChecker.cpp:
2140         (WebCore::MixedContentChecker::logWarning):
2141         * loader/TextTrackLoader.cpp:
2142         (WebCore::TextTrackLoader::corsPolicyPreventedLoad):
2143         * loader/appcache/ApplicationCacheGroup.cpp:
2144         (WebCore::ApplicationCacheGroup::abort):
2145         (WebCore::ApplicationCacheGroup::didReceiveResponse):
2146         (WebCore::ApplicationCacheGroup::didFinishLoading):
2147         (WebCore::ApplicationCacheGroup::didFail):
2148         (WebCore::ApplicationCacheGroup::didReceiveManifestResponse):
2149         (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
2150         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
2151         * loader/cache/CachedResourceLoader.cpp:
2152         (WebCore::CachedResourceLoader::printAccessDeniedMessage):
2153         * page/ChromeClient.h:
2154         (ChromeClient):
2155             Drop LogMessageType from everywhere.
2156         * page/Console.cpp:
2157         (WebCore::Console::addMessage):
2158         (WebCore::internalAddMessage):
2159         (WebCore::Console::error):
2160         (WebCore::Console::log):
2161         (WebCore::Console::warn):
2162         (WebCore::Console::dir):
2163         (WebCore::Console::dirxml):
2164         (WebCore::Console::clear):
2165         (WebCore::Console::trace):
2166         (WebCore::Console::assertCondition):
2167         * page/Console.h:
2168         (Console):
2169             Create a new internalAddMessage that's used for the various
2170             Console message types. Everything else routes through
2171             ::addMessage.
2172         * page/ConsoleTypes.h:
2173             Drop MessageTypes from this file, add it to ConsoleAPIType.h
2174         * page/ContentSecurityPolicy.cpp:
2175         (WebCore::ContentSecurityPolicy::logToConsole):
2176         * page/DOMWindow.cpp:
2177         (WebCore::DOMWindow::dispatchMessageEventWithOriginCheck):
2178         (WebCore::DOMWindow::printErrorMessage):
2179         * page/EventSource.cpp:
2180         (WebCore::EventSource::didReceiveResponse):
2181         * svg/SVGDocumentExtensions.cpp:
2182         (WebCore::reportMessage):
2183         * workers/DefaultSharedWorkerRepository.cpp:
2184         (SharedWorkerProxy):
2185         (WebCore::postConsoleMessageTask):
2186         (WebCore::SharedWorkerProxy::postConsoleMessageToWorkerObject):
2187         * workers/SharedWorkerContext.cpp:
2188         (WebCore::SharedWorkerContext::logExceptionToConsole):
2189         * workers/WorkerContext.cpp:
2190         (WebCore::WorkerContext::addMessage):
2191         (WebCore::WorkerContext::addMessageToWorkerConsole):
2192         * workers/WorkerContext.h:
2193         (WorkerContext):
2194         * workers/WorkerMessagingProxy.cpp:
2195         (WebCore::postConsoleMessageTask):
2196         (WebCore::WorkerMessagingProxy::postConsoleMessageToWorkerObject):
2197         * workers/WorkerMessagingProxy.h:
2198         (WorkerMessagingProxy):
2199         * workers/WorkerReportingProxy.h:
2200         (WorkerReportingProxy):
2201         * xml/XMLHttpRequest.cpp:
2202         (WebCore::logConsoleError):
2203         (WebCore::XMLHttpRequest::send):
2204         * xml/XSLTProcessorLibxslt.cpp:
2205         (WebCore::XSLTProcessor::parseErrorFunc):
2206         * xml/XSLTProcessorQt.cpp:
2207         (WebCore::XSLTMessageHandler::handleMessage):
2208             Drop LogMessageType from everywhere.
2209
2210 2012-12-11  Simon Hausmann  <simon.hausmann@digia.com>
2211
2212         [Qt] Unreviewed, rolling out r137313 and r137316 because they broke the system-sqlite build.
2213
2214         * WebCore.pri:
2215
2216 2012-12-11  Simon Hausmann  <simon.hausmann@digia.com>
2217
2218         Unreviewed Qt build fix: Don't error out if SQLITE3SRCDIR isn't set but
2219         we have a system sqlite to use.
2220
2221         * WebCore.pri:
2222
2223 2012-12-11  Oswald Buddenhagen  <oswald.buddenhagen@digia.com>
2224
2225         [Qt] make qtbase source requirement explicit
2226
2227         Reviewed by Simon Hausmann.
2228
2229         getting rid of QT.<module>.sources references, as they don't go well
2230         with real modularization.
2231
2232         * WebCore.pri:
2233
2234 2012-12-11  Oswald Buddenhagen  <oswald.buddenhagen@digia.com>
2235
2236         [Qt] move SQLITE3SRCDIR assignment to only use site
2237
2238         Reviewed by Simon Hausmann.
2239
2240         Target.pri includes WebCore.pri the almost first thing, so that is
2241         covered as well.
2242
2243         * WebCore.pri:
2244
2245 2012-12-11  Eugene Klyuchnikov  <eustas@chromium.org>
2246
2247         Web Inspector: Timeline: rename "Parse" to "Parse HTML".
2248         https://bugs.webkit.org/show_bug.cgi?id=104639
2249
2250         Reviewed by Yury Semikhatsky.
2251
2252         "Parse" sounds ambiguous, it could mean JSON.parse() or Date.parse().
2253         "Parse HTML" is a much more clear record description.
2254
2255         * inspector/front-end/TimelinePresentationModel.js: Fix text.
2256
2257 2012-12-11  Oswald Buddenhagen  <oswald.buddenhagen@digia.com>
2258
2259         [Qt] change setup of QMAKE_MOC
2260
2261         Reviewed by Simon Hausmann.
2262
2263         don't load(moc) explicitly - turns out that this breaks
2264         debug_and_release builds (the feature does not like being loaded before
2265         default_post has been loaded).
2266         so instead just do a minimal call to find the moc executable.
2267
2268         as it's in fact only two files which need it, so de-centralize this call
2269         for the sake of saving some cpu cycles spent in qmake.
2270
2271         * DerivedSources.pri:
2272
2273 2012-12-11  Alexander Pavlov  <apavlov@chromium.org>
2274
2275         REGRESSION(r136948): inspector/styles/import-pseudoclass-crash.html hits an assertion
2276         https://bugs.webkit.org/show_bug.cgi?id=104473
2277
2278         Reviewed by Vsevolod Vlasov.
2279
2280         Avoid building full CSSOM wrappers up front during rule matching.
2281         Instead, move this code down to the point where these wrappers are actually needed.
2282
2283         * inspector/InspectorCSSAgent.cpp:
2284         (WebCore::InspectorCSSAgent::willMatchRule):
2285         (WebCore::InspectorCSSAgent::willProcessRule):
2286         * inspector/InspectorCSSAgent.h:
2287         (WebCore):
2288         (InspectorCSSAgent):
2289         * inspector/InspectorInstrumentation.cpp:
2290         (WebCore):
2291         (WebCore::InspectorInstrumentation::willMatchRuleImpl):
2292         (WebCore::InspectorInstrumentation::willProcessRuleImpl):
2293
2294 2012-12-11  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
2295
2296         [GStreamer] Avoid linking to GStreamer video libraries if only using ENABLE_AUDIO
2297         https://bugs.webkit.org/show_bug.cgi?id=104590
2298
2299         Reviewed by Philippe Normand.
2300
2301         Make getVideoSizeAndFormatFromCaps() only available when ENABLE_VIDEO is set.
2302
2303         No new tests, no change in behavior.
2304
2305         * platform/graphics/gstreamer/GStreamerVersioning.cpp:
2306         * platform/graphics/gstreamer/GStreamerVersioning.h:
2307
2308 2012-12-11  Zeno Albisser  <zeno@webkit.org>
2309
2310         [Qt][Mac] Fix transparency for WebGL content.
2311         https://bugs.webkit.org/show_bug.cgi?id=104659
2312
2313         When drawing a texture to the TextureMapper the flag SupportsBlending
2314         must be passed in order to allow for transparent webgl content.
2315         We are doing this for GLX already, but the flag was still missing
2316         in GraphicsSurfaceMac.
2317
2318         Reviewed by Kenneth Rohde Christiansen.
2319
2320         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
2321         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
2322
2323 2012-12-11  Alexander Pavlov  <apavlov@chromium.org>
2324
2325         Web Inspector: Duplicate emulated touch events in iframe
2326         https://bugs.webkit.org/show_bug.cgi?id=104653
2327
2328         Reviewed by Vsevolod Vlasov.
2329
2330         Synthetic touch events should be dispatched only on the frame containing its target, not on its ancestor frames,
2331         up to the top frame.
2332
2333         * page/EventHandler.cpp:
2334         (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
2335           Do not dispatch a synthetic touch event on the current frame if its target is in a subframe.
2336
2337 2012-12-11  Kondapally Kalyan  <kalyan.kondapally@intel.com>
2338
2339         [EFL][WebGL] Regression(r137211) WebGL is broken with NVIDIA Drivers.
2340         https://bugs.webkit.org/show_bug.cgi?id=104652.
2341
2342         Reviewed by Kenneth Rohde Christiansen.
2343
2344         Reverting some of the changes from r137211, as it causes regressions
2345         on NVIDIA drivers.
2346
2347         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
2348         (WebCore::GraphicsContext3D::GraphicsContext3D):
2349         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
2350         (GraphicsContext3DPrivate::copyToGraphicsSurface):
2351         * platform/graphics/opengl/GLPlatformSurface.cpp:
2352         (WebCore::GLPlatformSurface::updateContents):
2353         * platform/graphics/opengl/GLPlatformSurface.h:
2354         (GLPlatformSurface):
2355
2356 2012-12-11  Pavel Feldman  <pfeldman@chromium.org>
2357
2358         Web Inspector: follow up to r136974: do not process shortcuts while editing
2359         https://bugs.webkit.org/show_bug.cgi?id=104440
2360
2361         Reviewed by Alexander Pavlov.
2362
2363         Currently, typing H while editing node results in corresponding shortcut processing.
2364
2365         * inspector/front-end/ElementsTreeOutline.js:
2366         (WebInspector.ElementsTreeOutline):
2367         (WebInspector.ElementsTreeOutline.prototype.handleShortcut):
2368         (WebInspector.ElementsTreeElement.prototype.onenter):
2369         (WebInspector.ElementsTreeElement.prototype._startEditingAttribute):
2370         (WebInspector.ElementsTreeElement.prototype.dispose):
2371         (WebInspector.ElementsTreeElement.prototype._startEditingAsHTML):
2372         (WebInspector.ElementsTreeElement.prototype._editingCancelled):
2373
2374 2012-12-11  Ken Kania  <kkania@chromium.org>
2375
2376         [Inspector] Add command for dispatching mouse events.
2377         https://bugs.webkit.org/show_bug.cgi?id=104074
2378
2379         Reviewed by Yury Semikhatsky.
2380
2381         Platform mouse event coordinates are relative to the containing window,
2382         but the inspector command assumes they follow standard web coordinates,
2383         where the origin is at the top left of the page and y increases as you
2384         go down. We convert the coordinates to the window before constructing
2385         the event. This also fixes the fact that some platforms have flipped
2386         coordinate systems.
2387         Also, update dispatchKeyEvent test to follow simpler dispatchMouseEvent
2388         test.
2389
2390         Test: inspector-protocol/input/dispatchMouseEvent.html
2391
2392         * inspector/Inspector.json:
2393         * inspector/InspectorInputAgent.cpp:
2394         (WebCore::InspectorInputAgent::dispatchMouseEvent):
2395         (WebCore):
2396         * inspector/InspectorInputAgent.h:
2397         (InspectorInputAgent):
2398
2399 2012-12-11  Pavel Feldman  <pfeldman@chromium.org>
2400
2401         Not reviewed: follow up to r137283: reduce inspector toolbar spacing 1px.
2402
2403         * inspector/front-end/inspector.css:
2404         (body.dock-to-bottom:not(.show-toolbar-icons) .toolbar-item.toggleable):
2405         (body.dock-to-bottom:not(.show-toolbar-icons) .toolbar-item.toggleable.toggled-on):
2406
2407 2012-12-11  Kent Tamura  <tkent@chromium.org>
2408
2409         Refactoring: Rename Element::shouldMatchReadOnlySelector and shouldMatchReadWriteSelector
2410         https://bugs.webkit.org/show_bug.cgi?id=104651
2411
2412         Reviewed by Kentaro Hara.
2413
2414         ':read-only' and ':read-write' are pseudo classes. They are not
2415         selectors in the context of these functions.  This patch rename them so
2416         that they contain 'pseudo class,' and make them match to an existing
2417         function, matchesFocusPseudoClass.
2418
2419         No new tests. This shouldn't make behavior changes.
2420
2421         * css/SelectorChecker.cpp:
2422         (WebCore::SelectorChecker::checkOneSelector):
2423         * dom/Element.cpp:
2424         (WebCore::Element::recalcStyle):
2425         (WebCore::Element::matchesReadOnlyPseudoClass):
2426         (WebCore::Element::matchesReadWritePseudoClass):
2427         * dom/Element.h:
2428         (Element):
2429         * html/HTMLInputElement.cpp:
2430         (WebCore::HTMLInputElement::matchesReadOnlyPseudoClass):
2431         (WebCore::HTMLInputElement::matchesReadWritePseudoClass):
2432         * html/HTMLInputElement.h:
2433         (HTMLInputElement):
2434         * html/HTMLTextAreaElement.cpp:
2435         (WebCore::HTMLTextAreaElement::matchesReadOnlyPseudoClass):
2436         (WebCore::HTMLTextAreaElement::matchesReadWritePseudoClass):
2437         * html/HTMLTextAreaElement.h:
2438         (HTMLTextAreaElement):
2439         * html/shadow/SliderThumbElement.cpp:
2440         (WebCore::SliderThumbElement::matchesReadOnlyPseudoClass):
2441         (WebCore::SliderThumbElement::matchesReadWritePseudoClass):
2442         * html/shadow/SliderThumbElement.h:
2443         (SliderThumbElement):
2444         * html/shadow/SpinButtonElement.cpp:
2445         (WebCore::SpinButtonElement::matchesReadOnlyPseudoClass):
2446         (WebCore::SpinButtonElement::matchesReadWritePseudoClass):
2447         * html/shadow/SpinButtonElement.h:
2448         (SpinButtonElement):
2449         * rendering/RenderTheme.cpp:
2450         (WebCore::RenderTheme::isReadOnlyControl):
2451
2452 2012-12-11  Pavel Feldman  <pfeldman@chromium.org>
2453
2454         Web Inspector: add more horizontal spacing for toolbar items in docked to bottom mode
2455         https://bugs.webkit.org/show_bug.cgi?id=104655
2456
2457         Reviewed by Alexander Pavlov.
2458
2459         Drive-by increase height to 26px.
2460
2461         * inspector/front-end/inspector.css:
2462         (#toolbar):
2463         (body:not(.show-toolbar-icons) .toolbar-item):
2464         (body.dock-to-bottom:not(.show-toolbar-icons) .toolbar-item.toggleable):
2465         (body.dock-to-bottom:not(.show-toolbar-icons) .toolbar-item.toggleable.toggled-on):
2466         (body.show-toolbar-icons.dock-to-bottom .toolbar-item.toggleable):
2467         (#toolbar-dropdown-arrow):
2468         (#main):
2469
2470 2012-12-11  Keishi Hattori  <keishi@webkit.org>
2471
2472         Use histogram enumeration in Calendar Picker so we can get stats on UI usage
2473         https://bugs.webkit.org/show_bug.cgi?id=104646
2474
2475         Reviewed by Kent Tamura.
2476
2477         Use histogram support to get stats on the calendar picker so we can improve the UI.
2478
2479         No new tests.
2480
2481         * Resources/pagepopups/calendarPicker.js:
2482         (CalendarPicker):
2483         (CalendarPicker.prototype.recordAction): Records action to histogram.
2484         (CalendarPicker.prototype.handleToday): Record action.
2485         (CalendarPicker.prototype.handleClear): Ditto.
2486         (YearMonthController.prototype._showPopup): Ditto.
2487         (YearMonthController.prototype._handleYearMonthChange): Ditto.
2488         (YearMonthController.prototype._handleButtonClick): Ditto.
2489         (DaysTable.prototype._handleDayClick): Ditto.
2490         * page/PagePopupController.cpp:
2491         (WebCore::PagePopupController::histogramEnumeration):
2492         (WebCore):
2493         * page/PagePopupController.h:
2494         (PagePopupController):
2495         * page/PagePopupController.idl: Added histogramEnumeration.
2496
2497 2012-12-11  Hajime Morrita  <morrita@google.com>
2498
2499         IsActiveFlag, IsHoverFlag, InActiveChainFlag can be unified.
2500         https://bugs.webkit.org/show_bug.cgi?id=103697
2501
2502         Reviewed by Ryosuke Niwa.
2503
2504         To save two more NodeFlags bits, this patch inroduces
2505         UserActionElementSet to get IsLinkFlag, IsHoverFlag,
2506         InActiveChainFlag together. These three old flags are replaced by
2507         UserActionElementSet::ElementFlags and UserActionElementSet
2508         collection which tracks elements which are flagged with one of
2509         a ElementFlags.
2510
2511         When marking an element as active for example, WebKit sets
2512         UserActionElementSet::IsActiveFlag to the element and store it
2513         into corresponding element set of the document. This set maintains
2514         marked elements and corresponding flags for each elements.
2515
2516         UserActionElementSet can be seen as a yet another rare data for
2517         these flags. However, the following characteristics of these flags
2518         make adding a new data structure on Document an attractive
2519         alternative:
2520
2521         - UserActionElementSet is maintained for each Document instead of a
2522           global collecton. This fits element lifetime better.
2523
2524         - The number of elements which have these flags is generally
2525           small, and a group of elements for each flag is largely overlapped
2526           due to its nature. This property keeps the set small, and lets
2527           flag retrieval efficient. On majority of the elements, all these
2528           flags are false thus the check is done by just checking
2529           IsInUserActionFlag.
2530
2531         As a bonus, isFocused flag, which was on NodeRareData, is also moved to this model.
2532
2533         No new tests, covered by existing test.
2534
2535         * CMakeLists.txt:
2536         * GNUmakefile.list.am:
2537         * Target.pri:
2538         * WebCore.gypi:
2539         * WebCore.xcodeproj/project.pbxproj:
2540         * dom/DOMAllInOne.cpp:
2541         * dom/Document.cpp:
2542         (WebCore::Document::removedLastRef):
2543         (WebCore::Document::updateHoverActiveState):
2544         * dom/Document.h:
2545         (WebCore::Document::userActionElements): Added.
2546         (Document):
2547         * dom/Node.cpp:
2548         (WebCore::Node::detach):
2549         * dom/Node.h:
2550         (WebCore):
2551         (WebCore::Node::isUserActionElement): Added.
2552         (WebCore::Node::setUserActionElement): Added.
2553         (Node):
2554         (WebCore::Node::active): Switched to UserActionElementSet.
2555         (WebCore::Node::inActiveChain): Switched to UserActionElementSet.
2556         (WebCore::Node::hovered): Switched to UserActionElementSet.
2557         (WebCore::Node::focused): Switched to UserActionElementSet.
2558         (WebCore::Node::setFocus): Switched to UserActionElementSet.
2559         (WebCore::Node::setActive): Switched to UserActionElementSet.
2560         (WebCore::Node::setHovered): Switched to UserActionElementSet.
2561         * dom/NodeRareData.h:
2562         (WebCore::NodeRareData::NodeRareData):
2563         (NodeRareData):
2564         * dom/UserActionElementSet.cpp: Added.
2565         (WebCore):
2566         (WebCore::UserActionElementSet::instanceFor):
2567         (WebCore::UserActionElementSet::UserActionElementSet):
2568         (WebCore::UserActionElementSet::~UserActionElementSet):
2569         (WebCore::UserActionElementSet::didDetach):
2570         (WebCore::UserActionElementSet::documentDidRemoveLastRef):
2571         (WebCore::UserActionElementSet::hasFlags):
2572         (WebCore::UserActionElementSet::setFlags):
2573         (WebCore::UserActionElementSet::clearFlags):
2574         * dom/UserActionElementSet.h: Added.
2575         (WebCore):
2576         (UserActionElementSet):
2577         (WebCore::UserActionElementSet::create):
2578         (WebCore::UserActionElementSet::isFocused):
2579         (WebCore::UserActionElementSet::setFocused):
2580         (WebCore::UserActionElementSet::isActive):
2581         (WebCore::UserActionElementSet::setActive):
2582         (WebCore::UserActionElementSet::isInActiveChain):
2583         (WebCore::UserActionElementSet::setInActiveChain):
2584         (WebCore::UserActionElementSet::isHovered):
2585         (WebCore::UserActionElementSet::setHovered):
2586         (WebCore::UserActionElementSet::setFlags):
2587
2588 2012-12-11  Kent Tamura  <tkent@chromium.org>
2589
2590         INPUT_MULTIPLE_FIELDS_UI: Disable focus navigation by right/left keys in RTL locales
2591         https://bugs.webkit.org/show_bug.cgi?id=104644
2592
2593         Reviewed by Hajime Morita.
2594
2595         Pressing the left key should focus on the field at the left of the
2596         current focused field, and pressing the right key should focus on the
2597         field at the right of the current focused field. This works well in LTR
2598         locales.
2599         In RTL locale, the current code doesn't work. We disable this behavior
2600         for RTL locales for now. This issue will be handled in Bug 104650.
2601
2602         No new tests. Update some *-multiple-fields tests for new behavior.
2603
2604         * html/shadow/DateTimeFieldElement.cpp:
2605         (WebCore::DateTimeFieldElement::defaultKeyboardEventHandler):
2606         If this sub-field is in an RTL locale, we don't change focus.
2607         (WebCore::DateTimeFieldElement::localeForOwner):
2608         Moved from DateTimeNumericFieldElement.
2609         * html/shadow/DateTimeFieldElement.h:
2610         (DateTimeFieldElement): Remove isRTL, add localeForOwner.
2611         * html/shadow/DateTimeNumericFieldElement.cpp: Remove localeForOwner.
2612         * html/shadow/DateTimeNumericFieldElement.h:
2613         (DateTimeNumericFieldElement): Ditto.
2614
2615 2012-12-11  Pavel Podivilov  <podivilov@google.com>
2616
2617         Remove pango files deleted at r137263 form WebCore.gypi.
2618
2619         Unreviewed, gardening.
2620
2621         * WebCore.gypi:
2622
2623 2012-12-11  Zan Dobersek  <zandobersek@gmail.com>
2624
2625         [GTK] Feature enabling/disabling should be possible through build-webkit
2626         https://bugs.webkit.org/show_bug.cgi?id=99271
2627
2628         Reviewed by Gustavo Noronha Silva.
2629
2630         Move the contents of GNUmakefile.features.am into GNUmakefile.features.am.in.
2631         The former is then copied from the latter but then appropriately modified if
2632         the build-webkit script overrides any of the default feature defines.
2633
2634         No new tests - no new testable functionality.
2635
2636         * GNUmakefile.features.am.in: Renamed from Source/WebCore/GNUmakefile.features.am.
2637
2638 2012-12-11  Jinwoo Song  <jinwoo7.song@samsung.com>
2639
2640         [QT][EFL][WK2] Move the GraphicsSurfaceGLX.cpp to common place
2641         https://bugs.webkit.org/show_bug.cgi?id=104433
2642
2643         Reviewed by Kenneth Rohde Christiansen.
2644
2645         QT and EFL are commonly using the GraphicsSurfaceGLX.cpp and
2646         it looks better to move this file to /glx directory.
2647
2648         * PlatformEfl.cmake:
2649         * Target.pri:
2650         * platform/graphics/surfaces/glx/GraphicsSurfaceGLX.cpp: Renamed from Source/WebCore/platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp.
2651         (WebCore):
2652         (OffScreenRootWindow):
2653         (WebCore::OffScreenRootWindow::OffScreenRootWindow):
2654         (WebCore::OffScreenRootWindow::getXWindow):
2655         (WebCore::OffScreenRootWindow::display):
2656         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
2657         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
2658         (GraphicsSurfacePrivate):
2659         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
2660         (WebCore::GraphicsSurfacePrivate::createSurface):
2661         (WebCore::GraphicsSurfacePrivate::createPixmap):
2662         (WebCore::GraphicsSurfacePrivate::textureIsYInverted):
2663         (WebCore::GraphicsSurfacePrivate::makeCurrent):
2664         (WebCore::GraphicsSurfacePrivate::doneCurrent):
2665         (WebCore::GraphicsSurfacePrivate::swapBuffers):
2666         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
2667         (WebCore::GraphicsSurfacePrivate::display):
2668         (WebCore::GraphicsSurfacePrivate::glxPixmap):
2669         (WebCore::GraphicsSurfacePrivate::size):
2670         (WebCore::resolveGLMethods):
2671         (WebCore::GraphicsSurface::platformExport):
2672         (WebCore::GraphicsSurface::platformGetTextureID):
2673         (WebCore::GraphicsSurface::platformCopyToGLTexture):
2674         (WebCore::GraphicsSurface::platformCopyFromTexture):
2675         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
2676         (WebCore::GraphicsSurface::platformFrontBuffer):
2677         (WebCore::GraphicsSurface::platformSwapBuffers):
2678         (WebCore::GraphicsSurface::platformSize):
2679         (WebCore::GraphicsSurface::platformCreate):
2680         (WebCore::GraphicsSurface::platformImport):
2681         (WebCore::GraphicsSurface::platformLock):
2682         (WebCore::GraphicsSurface::platformUnlock):
2683         (WebCore::GraphicsSurface::platformDestroy):
2684         (WebCore::GraphicsSurface::platformBeginPaint):
2685         (WebCore::GraphicsSurface::createReadOnlyImage):
2686
2687 2012-12-11  Mike West  <mkwst@chromium.org>
2688
2689         Web Inspector: Evaluate private browsing mode's effect on console messages.
2690         https://bugs.webkit.org/show_bug.cgi?id=104383
2691
2692         Reviewed by Pavel Feldman.
2693
2694         Two sets of console messages are currently gated on private browsing
2695         mode being inactive. This patch centralizes the private browsing checks
2696         in order to apply them equally to all console messages, and changes the
2697         granularity at which they act.
2698
2699         The current checks block the console messages entirely. This patch
2700         blocks only notifications to ChromeClient and ensures that messages
2701         won't be passed to printf where they might end up in system logs.
2702         Notifications to InspectorInstrumentation seem safe; so far as I can
2703         tell, there's no compelling reason to prevent console-based debugging
2704         in private browsing mode. This patch excludes those calls from the
2705         private browsing check.
2706
2707         Test: inspector/console/clients-ignored-in-privatebrowsing.html
2708
2709         * loader/cache/CachedResourceLoader.cpp:
2710         (WebCore::CachedResourceLoader::printAccessDeniedMessage):
2711             Drop the private browsing check.
2712         * page/Console.cpp:
2713         (WebCore::Console::addMessage):
2714             Add private browsing checks to the two ::addMessage variants that
2715             do real work. Ensure that calls to printf and notifications to
2716             ChromeClients are gated on these checks, but always allow
2717             notifications to InspectorInstrumentation.
2718         * page/DOMWindow.cpp:
2719         (WebCore::DOMWindow::printErrorMessage):
2720             Drop the private browsing check.
2721
2722 2012-12-10  Dan Winship  <danw@gnome.org>
2723
2724         [Soup] Fix spelling of "initiating" in API.
2725
2726         Reviewed by Martin Robinson.
2727
2728         No new tests (just internal renaming).
2729
2730         * platform/network/ResourceHandle.h:
2731         (ResourceHandle):
2732         * platform/network/soup/ResourceHandleSoup.cpp:
2733         (WebCore):
2734         (WebCore::setSoupRequestInitiatingPageIDFromNetworkingContext):
2735         (WebCore::ResourceHandle::start):
2736         (WebCore::ResourceHandle::getSoupRequestInitiatingPageID):
2737
2738 2012-12-10  Martin Robinson  <mrobinson@igalia.com>
2739
2740         [GTK] Remove the Pango backend
2741         https://bugs.webkit.org/show_bug.cgi?id=104569
2742
2743         Reviewed by Daniel Bates.
2744
2745         Remove the Pango backend entirely. The EFL build has no support for it and it's
2746         not really maintained enough for the GTK+ port, now that HarfbuzzNG shapes complex
2747         text when Freetype is the active text rendering backend.
2748
2749         No new tests. This does not change behavior.
2750
2751         * GNUmakefile.am: Remove Pango backend options and move Freetype options to the common list.
2752         * GNUmakefile.list.am: Ditto.
2753         * platform/graphics/FontPlatformData.h:
2754         * platform/graphics/pango/FontCachePango.cpp: Removed.
2755         * platform/graphics/pango/FontCustomPlatformDataPango.cpp: Removed.
2756         * platform/graphics/pango/FontPango.cpp: Removed.
2757         * platform/graphics/pango/FontPlatformData.h: Removed.
2758         * platform/graphics/pango/FontPlatformDataPango.cpp: Removed.
2759         * platform/graphics/pango/GlyphPageTreeNodePango.cpp: Removed.
2760         * platform/graphics/pango/PangoUtilities.cpp: Removed.
2761         * platform/graphics/pango/PangoUtilities.h: Removed.
2762         * platform/graphics/pango/SimpleFontDataPango.cpp: Removed.
2763
2764 2012-12-11  Andrey Adaikin  <aandrey@chromium.org>
2765
2766         Web Inspector: [WebGL] prevent GC from collecting WebGLObject instances currently bound to the context state
2767         https://bugs.webkit.org/show_bug.cgi?id=104119
2768
2769         Reviewed by Pavel Feldman.
2770
2771         This is to prevent GC from collecting resources bound to a context (WebGL or 2D).
2772         Otherwise, for example in WebGL, subsequent calls to gl.getParameter() may return a recently created
2773         instance that is no longer bound to a Resource object (thus, no history to replay it later).
2774
2775         * inspector/InjectedScriptCanvasModuleSource.js:
2776         (.):
2777
2778 2012-12-11  Zan Dobersek  <zandobersek@gmail.com>
2779
2780         Unreviewed build fix after r137243.
2781
2782         * bindings/gobject/GNUmakefile.am:
2783
2784 2012-12-10  No'am Rosenthal  <noam@webkit.org>
2785
2786         REGRESSION (r137006): CSS clip on solid color composited div broken
2787         https://bugs.webkit.org/show_bug.cgi?id=104604
2788
2789         Reviewed by Simon Fraser.
2790
2791         Disable direct compositing of background color for clipping layers.
2792
2793         Test: compositing/geometry/clip-inside.html
2794
2795         * rendering/RenderLayerBacking.cpp:
2796         (WebCore::supportsDirectBoxDecorationsComposition):
2797             Never allow direct background composition if there is a clip.
2798
2799 2012-12-10  Simon Fraser  <simon.fraser@apple.com>
2800
2801         REGRESSION (r137215): WebKit stretches and shrinks a part of screen on scroll
2802         https://bugs.webkit.org/show_bug.cgi?id=104626
2803
2804         Reviewed by Beth Dakin.
2805
2806         r137215 removed a compositing layer repaint on size changes. However, there
2807         are cases where the compositing code constrains layer size by clipping
2808         with the viewport and a clipping ancestor. When that happens, we must
2809         invalidate the layer on a size change to avoid showing stretched or
2810         shrunken content.
2811
2812         Test: compositing/repaint/clipped-layer-size-change.html
2813
2814         * rendering/RenderLayerBacking.cpp:
2815         (WebCore::RenderLayerBacking::RenderLayerBacking):
2816         (WebCore::RenderLayerBacking::updateCompositedBounds):
2817         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2818         * rendering/RenderLayerBacking.h:
2819         (RenderLayerBacking):
2820
2821 2012-12-10  Dean Jackson  <dino@apple.com>
2822
2823         Remove old WebKit Animation API code
2824         https://bugs.webkit.org/show_bug.cgi?id=104611
2825
2826         Reviewed by Simon Fraser.
2827
2828         Remove the existing, unused animation API code. We'll look into
2829         implementing the W3C Animation API if/when it is stable.
2830
2831         * CMakeLists.txt: Remove WebKitAnimation and WebKitAnimationList classes.
2832         * DerivedSources.cpp:
2833         * DerivedSources.make:
2834         * DerivedSources.pri:
2835         * GNUmakefile.list.am:
2836         * Target.pri:
2837         * UseJSC.cmake:
2838         * UseV8.cmake:
2839         * WebCore.gypi:
2840         * WebCore.vcproj/WebCore.vcproj:
2841         * WebCore.xcodeproj/project.pbxproj:
2842         * bindings/js/JSBindingsAllInOne.cpp: Remove includes.
2843         * bindings/js/JSWebKitAnimationCustom.cpp: Removed.
2844         * bindings/js/JSWebKitAnimationListCustom.cpp: Removed.
2845         * dom/Element.cpp: Remove API.
2846         * dom/Element.h: Ditto.
2847         * dom/Element.idl: Ditto.
2848         * page/DOMWindow.idl: Ditto.
2849         * page/WebKitAnimation.cpp: Removed.
2850         * page/WebKitAnimation.h: Removed.
2851         * page/WebKitAnimation.idl: Removed.
2852         * page/WebKitAnimationList.cpp: Removed.
2853         * page/WebKitAnimationList.h: Removed.
2854         * page/WebKitAnimationList.idl: Removed.
2855         * page/animation/AnimationController.cpp: Remove API.
2856         * page/animation/AnimationController.h: Ditto.
2857         * page/animation/AnimationControllerPrivate.h: Ditto.
2858         * page/animation/CompositeAnimation.cpp: Ditto.
2859         * page/animation/CompositeAnimation.h: Ditto.
2860
2861 2012-12-10  Jessie Berlin  <jberlin@apple.com>
2862
2863         Fix the Mac build after r137233
2864
2865         * html/shadow/HTMLShadowElement.h:
2866         Remove a declaration of a member variable that was moved to the InsertionPoint superclass.
2867
2868 2012-12-10  KyungTae Kim  <ktf.kim@samsung.com>
2869
2870         Build fix after r137221
2871         https://bugs.webkit.org/show_bug.cgi?id=104617
2872
2873         Unreviewed build fix
2874
2875         * html/HTMLPropertiesCollection.cpp:
2876         (WebCore::nextNodeWithProperty):
2877
2878 2012-12-10  Hajime Morrita  <morrita@google.com>
2879
2880         [Shadow DOM][Refactoring] HTMLContentElement,HTMLShadowElement::m_registeredWithShadowRoot should be moved to InsertionPoint
2881         https://bugs.webkit.org/show_bug.cgi?id=104516
2882
2883         Reviewed by Dimitri Glazkov.
2884
2885         This change pulls duplicated code in removedFrom() and
2886         insertedInto() of both both HTMLShadowElement and
2887         HTMLContentElement to their super class InsertionPoint.
2888
2889         This is a part of effor that encapsulate node distribution algorithm to
2890         ContentDistributor and its family.
2891
2892         No new tests, no behavior change.
2893
2894         * dom/ShadowRoot.cpp:
2895         (WebCore::ShadowRoot::registerInsertionPoint): Added.
2896         (WebCore::ShadowRoot::unregisterInsertionPoint): Added.
2897         * dom/ShadowRoot.h:
2898         (ShadowRoot):
2899         * html/shadow/ContentDistributor.cpp:
2900         (WebCore::ShadowRootContentDistributionData::regiterInsertionPoint): Generalized two methods for <content> and <shadow>.
2901         (WebCore):
2902         (WebCore::ShadowRootContentDistributionData::unregisterInsertionPoint): Ditto.
2903         * html/shadow/ContentDistributor.h:
2904         (ShadowRootContentDistributionData):
2905         * html/shadow/HTMLContentElement.cpp:
2906         (WebCore::HTMLContentElement::HTMLContentElement):
2907         * html/shadow/HTMLContentElement.h:
2908         * html/shadow/HTMLShadowElement.cpp:
2909         (WebCore::HTMLShadowElement::HTMLShadowElement):
2910         * html/shadow/HTMLShadowElement.h:
2911         * html/shadow/InsertionPoint.cpp:
2912         (WebCore::InsertionPoint::InsertionPoint):
2913         (WebCore::InsertionPoint::insertedInto): Pulled up from subclasses
2914         (WebCore::InsertionPoint::removedFrom): Pulled up from subclasses
2915         * html/shadow/InsertionPoint.h:
2916         (InsertionPoint):
2917
2918 2012-12-10  Jon Lee  <jonlee@apple.com>
2919
2920         Keep track of plug-in snapshots clicked by user
2921         https://bugs.webkit.org/show_bug.cgi?id=103206
2922         <rdar://problem/12746483>
2923
2924         Reviewed by Anders Carlsson.
2925
2926         * html/HTMLPlugInImageElement.cpp:
2927         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): Initially the hash is
2928         unknown. Set to 0. Move the check for whether to snapshot the plugin into the
2929         new function subframeLoaderWillLoadPlugIn.
2930         (WebCore::HTMLPlugInImageElement::userDidClickSnapshot): Rename
2931         setPendingClickEvent to userDidClickSnapshot. In addition to holding onto the
2932         click event used to activate the plug-in, the function now also tells the plug-in
2933         client to add the origin hash as an auto-start origin.
2934         (WebCore::HTMLPlugInImageElement::subframeLoaderWillLoadPlugIn): Calculate the
2935         hash based on the provided URL, which is the URL the plug-in will load. Extend
2936         the check that used to be in the constructor to see if the plug-in should not
2937         automatically load, including checking the plug-in size and whether the hash
2938         is an auto-start origin.
2939         * html/HTMLPlugInImageElement.h: Rename setPendingClickEvent to userDidClickSnapshot
2940         and add a variable for the origin hash.
2941
2942         * loader/SubframeLoader.cpp:
2943         (WebCore::SubframeLoader::requestPlugin): When the loader is about to load the
2944         plug-in, pass the URL to the element, so that it can calculate the hash.
2945
2946         * page/Page.cpp:
2947         (WebCore::Page::Page): Take the plugInClient from the page clients.
2948         (WebCore::Page::~Page): If the client exists, tell it that the page is being
2949         destroyed.
2950         (WebCore::Page::PageClients::PageClients): Initialize this optional client to
2951         null.
2952         * page/Page.h: Add PlugInClient to page clients.
2953         (PageClients): Add PlugInClient variable.
2954         (WebCore::Page::plugInClient):
2955         * page/PlugInClient.h: Added.
2956
2957         * rendering/RenderSnapshottedPlugIn.cpp:
2958         (WebCore::RenderSnapshottedPlugIn::handleEvent): Call the renamed function
2959         userDidClickSnapshot().
2960         (WebCore::RenderSnapshottedPlugIn::layout): Move the check of the plug-in size
2961         to subframeLoaderWillLoadPlugIn.
2962
2963         Add PlugInClient.h.
2964         * GNUmakefile.list.am:
2965         * Target.pri:
2966         * WebCore.vcproj/WebCore.vcproj:
2967         * WebCore.xcodeproj/project.pbxproj:
2968
2969 2012-12-10  Antti Koivisto  <antti@apple.com>
2970
2971         Not reviewed.
2972         
2973         Build fix.
2974
2975         * html/HTMLPropertiesCollection.cpp:
2976         (WebCore::nextNodeWithProperty):
2977         * page/TouchDisambiguation.cpp:
2978         (WebCore::boundingBoxForEventNodes):
2979
2980 2012-12-10  Beth Dakin  <bdakin@apple.com>
2981
2982         https://bugs.webkit.org/show_bug.cgi?id=104602
2983         DidHitRelevantRepaintedObjectsAreaThreshold LayoutMilestone fires too 
2984         early on some pages with iframes
2985
2986         Reviewed by Simon Fraser.
2987
2988         This change makes it so that any RenderObjects inside iframes are not 
2989         considered relevant.
2990         * page/Page.cpp:
2991         (WebCore::Page::addRelevantRepaintedObject):
2992
2993 2012-12-10  David Grogan  <dgrogan@chromium.org>
2994
2995         IndexedDB: Propagate more leveldb errors to script
2996         https://bugs.webkit.org/show_bug.cgi?id=104422
2997
2998         Reviewed by Tony Chang.
2999
3000         These are the last places that ignore leveldb errors that can get the
3001         usual ok/found treatment.
3002
3003         Nothing called getBool, so it is deleted.
3004
3005         * Modules/indexeddb/IDBBackingStore.cpp:
3006         (WebCore):
3007         (WebCore::getInt):
3008         (WebCore::isSchemaKnown):
3009         (WebCore::setUpMetadata):
3010         (WebCore::getMaxObjectStoreId):
3011         (WebCore::IDBBackingStore::open):
3012         (WebCore::IDBBackingStore::getIDBDatabaseMetaData):
3013         (WebCore::getNewDatabaseId):
3014         (WebCore::IDBBackingStore::createIDBDatabaseMetaData):
3015         (WebCore::setMaxObjectStoreId):
3016         (WebCore::getNewVersionNumber):
3017         (WebCore::IDBBackingStore::putRecord):
3018         (WebCore::setMaxIndexId):
3019         * Modules/indexeddb/IDBBackingStore.h:
3020         (IDBBackingStore):
3021         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
3022         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
3023         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreStorageOperation::perform):
3024
3025 2012-12-09  Antti Koivisto  <antti@apple.com>
3026
3027         Factor node traversal into standalone functions
3028         https://bugs.webkit.org/show_bug.cgi?id=104507
3029
3030         Reviewed by Eric Seidel.
3031
3032         Node traversal functions are currently Node and ContainerNode members. Their implementations
3033         are confusingly scattered over multiple header and source files. These functions have no particular
3034         reason to be members as they don't require non-public access. They should be made freestanding
3035         function instead and gathered together.
3036         
3037         This patch adds NodeTraversal namespace, defined in NodeTraversal.h. It contains freestanding
3038         functions for traversing Nodes. Most popular functions are inlined (as before) and
3039         there are ContainerNode specific specializations (as before).
3040         
3041         In client code
3042         
3043             node = node->traverseNextNode();
3044             node = node->traverseNextSibling();
3045         
3046         becomes
3047         
3048             node = NodeTraversal::next(node);
3049             node = NodeTraversal::nextSkippingChildren(node);
3050             
3051         etc.
3052
3053         * WebCore.exp.in:
3054         * WebCore.xcodeproj/project.pbxproj:
3055         * accessibility/AccessibilityNodeObject.cpp:
3056         (WebCore::AccessibilityNodeObject::accessibilityDescriptionForElements):
3057         * accessibility/AccessibilityObject.cpp:
3058         (WebCore::AccessibilityObject::firstAccessibleObjectFromNode):
3059         * accessibility/AccessibilityRenderObject.cpp:
3060         (WebCore::AccessibilityRenderObject::addImageMapChildren):
3061         * bindings/js/JSDocumentCustom.cpp:
3062         (WebCore::toJS):
3063         * css/SelectorChecker.cpp:
3064         (WebCore::SelectorChecker::allVisitedStateChanged):
3065         (WebCore::SelectorChecker::visitedStateChanged):
3066         * css/StyleInvalidationAnalysis.cpp:
3067         (WebCore::StyleInvalidationAnalysis::invalidateStyle):
3068         * dom/ContainerNode.cpp:
3069         (WebCore::dispatchChildInsertionEvents):
3070         (WebCore::dispatchChildRemovalEvents):
3071         * dom/ContainerNode.h:
3072         (ContainerNode):
3073         (WebCore):
3074         * dom/ContainerNodeAlgorithms.h:
3075         (WebCore::ChildFrameDisconnector::collectDescendant):
3076         * dom/Document.cpp:
3077         (WebCore::Document::buildAccessKeyMap):
3078         (WebCore::Document::removeAllEventListeners):
3079         (WebCore::Document::updateBaseURL):
3080         (WebCore::Document::processBaseElement):
3081         (WebCore::Document::nodeAbsIndex):
3082         (WebCore::Document::nodeWithAbsIndex):
3083         (WebCore::Document::getFocusableNodes):
3084         * dom/DocumentMarkerController.cpp:
3085         (WebCore::DocumentMarkerController::markersInRange):
3086         (WebCore::DocumentMarkerController::setMarkersActive):
3087         (WebCore::DocumentMarkerController::hasMarkers):
3088         (WebCore::DocumentMarkerController::clearDescriptionOnMarkersIntersectingRange):
3089         * dom/DocumentOrderedMap.cpp:
3090         (WebCore::DocumentOrderedMap::get):
3091         * dom/ElementShadow.cpp:
3092         (WebCore::ElementShadow::collectSelectFeatureSetFrom):
3093         * dom/Node.cpp:
3094         (WebCore::Node::normalize):
3095         (WebCore::Node::lazyAttach):
3096         (WebCore):
3097         (WebCore::Node::detach):
3098         (WebCore::traverseTreeAndMark):
3099         * dom/Node.h:
3100         (Node):
3101         * dom/NodeIterator.cpp:
3102         (WebCore::NodeIterator::NodePointer::moveToNext):
3103         (WebCore::NodeIterator::NodePointer::moveToPrevious):
3104         (WebCore::NodeIterator::updateForNodeRemoval):
3105         * dom/NodeTraversal.h: Added.
3106         (WebCore):
3107         (NodeTraversal):
3108         (WebCore::NodeTraversal::traverseNextNodeTemplate):
3109         (WebCore::NodeTraversal::next):
3110         (WebCore::NodeTraversal::traverseNextSiblingTemplate):
3111         (WebCore::NodeTraversal::nextSibling):
3112         * dom/Range.cpp:
3113         (WebCore::Range::toString):
3114         (WebCore::Range::checkDeleteExtract):
3115         (WebCore::Range::firstNode):
3116         (WebCore::Range::pastLastNode):
3117         (WebCore::Range::textRects):
3118         (WebCore::Range::textQuads):
3119         (WebCore::Range::getBorderAndTextQuads):
3120         * dom/TreeScope.cpp:
3121         (WebCore::TreeScope::labelElementForId):
3122         (WebCore::TreeScope::findAnchor):
3123         * dom/TreeScopeAdopter.cpp:
3124         (WebCore::TreeScopeAdopter::moveTreeToNewScope):
3125         (WebCore::TreeScopeAdopter::moveTreeToNewDocument):
3126         * dom/TreeWalker.cpp:
3127         (WebCore::TreeWalker::nextNode):
3128         * editing/ApplyStyleCommand.cpp:
3129         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
3130         (WebCore::ApplyStyleCommand::fixRangeAndApplyInlineStyle):
3131         (WebCore::containsNonEditableRegion):
3132         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
3133         (WebCore::ApplyStyleCommand::removeStyleFromRunBeforeApplyingStyle):
3134         (WebCore::ApplyStyleCommand::removeInlineStyle):
3135         * editing/BreakBlockquoteCommand.cpp:
3136         (WebCore::BreakBlockquoteCommand::doApply):
3137         * editing/CompositeEditCommand.cpp:
3138         (WebCore::CompositeEditCommand::deleteInsignificantText):
3139         (WebCore::CompositeEditCommand::cloneParagraphUnderNewElement):
3140         * editing/DeleteSelectionCommand.cpp:
3141         (WebCore::firstEditablePositionInNode):
3142         (WebCore::DeleteSelectionCommand::makeStylingElementsDirectChildrenOfEditableRootToPreventStyleLoss):
3143         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
3144         * editing/EditCommand.cpp:
3145         (WebCore::SimpleEditCommand::addNodeAndDescendants):
3146         * editing/EditingStyle.cpp:
3147         (WebCore::EditingStyle::triStateOfStyle):
3148         (WebCore::EditingStyle::textDirectionForSelection):
3149         * editing/Editor.cpp:
3150         (WebCore::Editor::simplifyMarkup):
3151         * editing/FrameSelection.cpp:
3152         (WebCore::scanForForm):
3153         (WebCore::FrameSelection::setSelectionFromNone):
3154         * editing/InsertParagraphSeparatorCommand.cpp:
3155         (WebCore::InsertParagraphSeparatorCommand::doApply):
3156         * editing/ReplaceSelectionCommand.cpp:
3157         (WebCore::ReplacementFragment::removeUnrenderedNodes):
3158         (WebCore::ReplacementFragment::removeInterchangeNodes):
3159         (WebCore::ReplaceSelectionCommand::InsertedNodes::willRemoveNodePreservingChildren):
3160         (WebCore::ReplaceSelectionCommand::InsertedNodes::willRemoveNode):
3161         (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
3162         (WebCore::removeHeadContents):
3163         (WebCore::ReplaceSelectionCommand::handleStyleSpans):
3164         * editing/ReplaceSelectionCommand.h:
3165         (WebCore::ReplaceSelectionCommand::InsertedNodes::pastLastLeaf):
3166         * editing/SimplifyMarkupCommand.cpp:
3167         (WebCore::SimplifyMarkupCommand::doApply):
3168         * editing/TextIterator.cpp:
3169         (WebCore::TextIterator::advance):
3170         (WebCore::shouldEmitNewlineAfterNode):
3171         * editing/htmlediting.cpp:
3172         (WebCore::hasARenderedDescendant):
3173         * editing/mac/EditorMac.mm:
3174         (WebCore::Editor::fontForSelection):
3175         * editing/markup.cpp:
3176         (WebCore::completeURLs):
3177         (WebCore::StyledMarkupAccumulator::traverseNodesForSerialization):
3178         (WebCore::findNodesSurroundingContext):
3179         (WebCore::trimFragment):
3180         * editing/visible_units.cpp:
3181         (WebCore::startOfParagraph):
3182         (WebCore::endOfParagraph):
3183         * html/HTMLCollection.cpp:
3184         (WebCore::nextNode):
3185         * html/HTMLElement.cpp:
3186         (WebCore::setHasDirAutoFlagRecursively):
3187         (WebCore::HTMLElement::directionality):
3188         (WebCore::HTMLElement::adjustDirectionalityIfNeededAfterChildrenChanged):
3189         (WebCore::HTMLElement::getItemRefElements):
3190         * html/HTMLFieldSetElement.cpp:
3191         (WebCore::HTMLFieldSetElement::invalidateDisabledStateUnder):
3192         (WebCore::HTMLFieldSetElement::refreshElementsIfNeeded):
3193         * html/HTMLFormElement.cpp:
3194         (WebCore::HTMLFormElement::formElementIndex):
3195         * html/HTMLLabelElement.cpp:
3196         (WebCore::HTMLLabelElement::control):
3197         * html/HTMLLegendElement.cpp:
3198         (WebCore::HTMLLegendElement::associatedControl):
3199         * html/HTMLMapElement.cpp:
3200         (WebCore::HTMLMapElement::mapMouseEvent):
3201         * html/HTMLNameCollection.cpp:
3202         (WebCore::HTMLNameCollection::virtualItemAfter):
3203         * html/HTMLOptionElement.cpp:
3204         (WebCore::HTMLOptionElement::collectOptionInnerText):
3205         * html/HTMLPropertiesCollection.cpp:
3206         (WebCore::nextNodeWithProperty):
3207         * html/HTMLSelectElement.cpp:
3208         (WebCore::HTMLSelectElement::recalcListItems):
3209         * html/HTMLTextFormControlElement.cpp:
3210         (WebCore::HTMLTextFormControlElement::selection):
3211         (WebCore::HTMLTextFormControlElement::innerTextValue):
3212         (WebCore::HTMLTextFormControlElement::valueWithHardLineBreaks):
3213         * html/RadioInputType.cpp:
3214         (WebCore::RadioInputType::handleKeydownEvent):
3215         * html/shadow/ContentDistributor.cpp:
3216         (WebCore::ShadowRootContentDistributionData::ensureInsertionPointList):
3217         * inspector/InspectorDOMAgent.cpp:
3218         (WebCore::InspectorDOMAgent::performSearch):
3219         * inspector/InspectorMemoryAgent.cpp:
3220         * page/FocusController.cpp:
3221         (WebCore::FocusController::findFocusCandidateInContainer):
3222         * page/Frame.cpp:
3223         (WebCore::Frame::searchForLabelsAboveCell):
3224         (WebCore::Frame::searchForLabelsBeforeElement):
3225         * rendering/RenderNamedFlowThread.cpp:
3226         (WebCore::RenderNamedFlowThread::getRanges):
3227         * svg/SVGSVGElement.cpp:
3228         (WebCore::SVGSVGElement::collectIntersectionOrEnclosureList):
3229         (WebCore::SVGSVGElement::getElementById):
3230         * svg/SVGUseElement.cpp:
3231         (WebCore::removeDisallowedElementsFromSubtree):
3232         * svg/animation/SMILTimeContainer.cpp:
3233         (WebCore::SMILTimeContainer::updateDocumentOrderIndexes):
3234         * xml/XPathNodeSet.cpp:
3235         (WebCore::XPath::NodeSet::traversalSort):
3236         * xml/XPathStep.cpp:
3237         (WebCore::XPath::Step::nodesInAxis):
3238         * xml/XPathUtil.cpp:
3239         (WebCore::XPath::stringValue):
3240
3241 2012-12-10  Min Qin  <qinmin@chromium.org>
3242
3243         Sending multi-touch events to the same Iframe
3244         https://bugs.webkit.org/show_bug.cgi?id=97973
3245
3246         Reviewed by Dimitri Glazkov.
3247
3248         Multi-Touch in different iframe can give both documents access to each other.
3249         This could cause cross-origin access. To solve this, all the touch events should
3250         be sent to the iframe where the first touchstart happens.
3251
3252         Test: fast/events/touch/multi-touch-inside-iframes.html
3253               fast/events/touch/multi-touch-inside-nested-iframes.html
3254
3255         * page/EventHandler.cpp:
3256         (WebCore::EventHandler::handleTouchEvent):
3257         * page/EventHandler.h:
3258
3259 2012-12-10  KyungTae Kim  <ktf.kim@samsung.com>
3260
3261         [soup] Fix build warning in ResourceHandleSoup.cpp
3262         https://bugs.webkit.org/show_bug.cgi?id=104605
3263
3264         Reviewed by Martin Robinson.
3265
3266         The nextMultipartResponsePartCallback has unused parameter 'source',
3267         comment out it to fix 'unused parameter' build warning.
3268
3269         * platform/network/soup/ResourceHandleSoup.cpp:
3270         (WebCore::nextMultipartResponsePartCallback):
3271
3272 2012-12-10  Simon Fraser  <simon.fraser@apple.com>
3273
3274         Fix frame border painting in tiled drawing mode
3275         https://bugs.webkit.org/show_bug.cgi?id=104453
3276         <rdar://problem/11678611>
3277
3278         Reviewed by Dan Bernstein.
3279
3280         Frame borders were not correctly invalidated when in tiled drawing mode, because
3281         RenderFrameSet::layout() invalidated directly on the view, which skips the tile
3282         cache.
3283         
3284         Fix by invalidating like all other renderers, via the repaint container.
3285         
3286         Also, the layer transform should be updated before the invalidation, and
3287         we make use of RenderObject::updateLayerTransform() which has the same behavior
3288         as the old code.
3289
3290         Attempts to make a layout test failed. Resizing composited framesets repainted
3291         via layer resizing, and an attempt to make a ref test in tiled drawing mode
3292         failed (the test passed without the patch).
3293
3294         * rendering/RenderFrameSet.cpp:
3295         (WebCore::RenderFrameSet::layout):
3296
3297 2012-12-10  Simon Fraser  <simon.fraser@apple.com>
3298
3299         When converting a layer into a tiled layer, ensure that we update the visible rect
3300         https://bugs.webkit.org/show_bug.cgi?id=104467
3301
3302         Reviewed by Darin Adler.
3303
3304         When a GraphicsLayerCA toggles to use a TileCache, we have to ensure that the
3305         layer's visible rect (which is used to ensure tile coverage) is updated in
3306         the same commit. Otherwise we can get blank layers until something else causes
3307         the visible rect to be updated.
3308
3309         Test: compositing/tiling/tiled-layer-resize.html
3310
3311         * platform/graphics/ca/GraphicsLayerCA.cpp:
3312         (WebCore::GraphicsLayerCA::dumpAdditionalProperties): With the debug flag, dump the TiledBacking
3313         address for ease of debugging.
3314         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer): Set the VisibleRectChanged bit in
3315         m_uncommittedChanges if we've just switched to a tiled layer.
3316
3317 2012-12-10  Simon Fraser  <simon.fraser@apple.com>
3318
3319         Don't unconditionally repaint compositing layers when their size changes
3320         https://bugs.webkit.org/show_bug.cgi?id=104461
3321
3322         Reviewed by Sam Weinig.
3323
3324         RenderLayerBacking always repainted the entire compositing layer when its size
3325         changed. This was done to fix repaint issues when outline widths changes, but
3326         that issue is now solved by repainting in GraphicsLayer::setOffsetFromRenderer(),
3327         add in r134628. I believe this is no longer necessary.
3328         
3329         Always repainting when the size changes is terrible for the tile cache when
3330         loading large documents, as all tiles repaint every time the document gets
3331         longer.
3332
3333         Test: compositing/repaint/resize-repaint.html
3334
3335         * rendering/RenderLayerBacking.cpp:
3336         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
3337
3338 2012-12-10  Ojan Vafai  <ojan@chromium.org>
3339
3340         Unreviewed, rolling out r134150.
3341         http://trac.webkit.org/changeset/134150
3342         https://bugs.webkit.org/show_bug.cgi?id=99940
3343
3344         Caused JS-based tooltips to remain during scroll on Facebook
3345         and Gmail. Rollout until I have time to experiment with less
3346         aggresive approaches.
3347
3348         * page/EventHandler.cpp:
3349         (WebCore):
3350         (WebCore::MaximumDurationTracker::MaximumDurationTracker):
3351         (WebCore::MaximumDurationTracker::~MaximumDurationTracker):
3352         (MaximumDurationTracker):
3353         (WebCore::EventHandler::EventHandler):
3354         (WebCore::EventHandler::clear):
3355         (WebCore::EventHandler::mouseMoved):
3356         (WebCore::EventHandler::dispatchFakeMouseMoveEventSoon):
3357         (WebCore::EventHandler::fakeMouseMoveEventTimerFired):
3358         * page/EventHandler.h:
3359         (EventHandler):
3360         * platform/Timer.h:
3361
3362 2012-12-10  Yi Shen  <max.hong.shen@gmail.com>
3363
3364         Keyboard caret movement in textarea with RTL Override Character can make tab unresponsive
3365         https://bugs.webkit.org/show_bug.cgi?id=103067
3366
3367         Reviewed by Ryosuke Niwa.
3368
3369         For textarea with RTL override character, the line break could be the previous leaf InlineTextBox of
3370         the InlineTextBox for the RTL override text. When overshots the left/right, make sure the 
3371         leftVisuallyDistinctCandidate and rightVisuallyDistinctCandidate return the visually distinct 
3372         left/right position by ignoring the line break.
3373
3374         Test: editing/selection/move-by-character-crash-test-textarea.html
3375
3376         * editing/VisiblePosition.cpp:
3377         (WebCore::VisiblePosition::leftVisuallyDistinctCandidate):
3378         (WebCore::VisiblePosition::rightVisuallyDistinctCandidate):
3379
3380 2012-12-10  Kondapally Kalyan  <kalyan.kondapally@intel.com>
3381
3382         [EFL][WebGL] Minor Refactoring in GraphicsContext3DEfl.
3383         https://bugs.webkit.org/show_bug.cgi?id=104553.
3384
3385         Reviewed by Kenneth Rohde Christiansen.
3386
3387         We use different FBO for canvas and offscreen surface of our platform layer.
3388         Thus we need to manage any bound buffers while copying contents to the surface. Currently, Surface
3389         always uses double buffering but in future we should be able to configure it to use either
3390         double or single buffer. For these use cases, it would be handy to bind buffers directly to
3391         FBO used by the surface. This patch does the needed changes in GraphicsContext3DEfl and
3392         PlatformSurface. Also, removes some unused code.
3393
3394         Covered by existing tests.
3395
3396         Relevant changes in GraphicsContext3DEfl to obtain FBO id from PlatformSurface.
3397         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
3398         (WebCore::GraphicsContext3D::GraphicsContext3D):
3399         (WebCore::GraphicsContext3D::~GraphicsContext3D):
3400
3401         Renamed createGraphicsSurface to didResizeCanvas.
3402         (WebCore::GraphicsContext3D::createGraphicsSurfaces):
3403         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
3404         (GraphicsContext3DPrivate::didResizeCanvas):
3405         (GraphicsContext3DPrivate::copyToGraphicsSurface):
3406         * platform/graphics/efl/GraphicsContext3DPrivate.h:
3407         (GraphicsContext3DPrivate):
3408
3409         Header cleanup.
3410         * platform/graphics/opengl/GLDefs.h:
3411         * platform/graphics/opengl/GLPlatformContext.cpp:
3412         (WebCore::GLPlatformContext::createContext):
3413         * platform/graphics/opengl/GLPlatformContext.h:
3414
3415         Added initialize method to expose FBO id of the surface.
3416         Removed unused code.
3417         * platform/graphics/opengl/GLPlatformSurface.cpp:
3418         (WebCore::GLPlatformSurface::initialize):
3419         (WebCore):
3420         (WebCore::GLPlatformSurface::updateContents):
3421         * platform/graphics/opengl/GLPlatformSurface.h:
3422         (GLPlatformSurface):
3423         * platform/graphics/surfaces/glx/GLXSurface.h:
3424
3425 2012-12-07  Simon Fraser  <simon.fraser@apple.com>
3426
3427         Tidy up the tiled scrolling indicator, fix with zooming
3428         https://bugs.webkit.org/show_bug.cgi?id=104386
3429
3430         Reviewed by Tim Horton.
3431
3432         Fix the tiled scrolling indicator to not get tiny when zooming,
3433         to not poke out of the bottom of the window, and to not look
3434         so crappy.
3435
3436         * platform/graphics/ca/mac/TileCache.mm:
3437         (WebCore::TileCache::updateTileCoverageMap):
3438         (WebCore::TileCache::drawTileMapContents):
3439
3440 2012-12-10  Sheriff Bot  <webkit.review.bot@gmail.com>
3441
3442         Unreviewed, rolling out r136817.
3443         http://trac.webkit.org/changeset/136817
3444         https://bugs.webkit.org/show_bug.cgi?id=104596
3445
3446         This patch was an unnecessarily complex solution to handling
3447         conversion of union types. (Requested by mpruett on #webkit).
3448
3449         * bindings/js/JSDictionary.cpp:
3450         (WebCore::JSDictionary::convertValue):
3451         * bindings/js/JSDictionary.h:
3452         (WebCore::JSDictionary::tryGetPropertyAndResult):
3453
3454 2012-12-10  Tab Atkins  <tabatkins@google.com>
3455
3456         Deprecate prefixed linear-gradient and radial-gradient functions
3457         https://bugs.webkit.org/show_bug.cgi?id=104591
3458
3459         Reviewed by Dean Jackson.
3460
3461         Rename the old gradient parsing functions in anticipation of functions that parse the new syntax.
3462
3463         No new tests added - this is a rename and has no functionality change.
3464
3465         * css/CSSParser.cpp:
3466         (WebCore::CSSParser::parseDeprecatedLinearGradient):
3467         (WebCore::CSSParser::parseDeprecatedRadialGradient):
3468         (WebCore::CSSParser::parseGeneratedImage):
3469         * css/CSSParser.h:
3470
3471 2012-12-10  Mark Pilgrim  <pilgrim@chromium.org>
3472
3473         [Chromium][Win] Remove theme-related functions from PlatformSupport
3474         https://bugs.webkit.org/show_bug.cgi?id=102699
3475
3476         Reviewed by Adam Barth.
3477
3478         Call theme engine directly instead of going through
3479         PlatformSupport. Part of a refactoring series. See tracking bug 82948.
3480
3481         * platform/chromium/PlatformSupport.h:
3482         (PlatformSupport):
3483         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
3484         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
3485         (WebCore::ScrollbarThemeChromiumWin::paintButton):
3486         * rendering/RenderThemeChromiumWin.cpp:
3487         (WebCore):
3488         (WebCore::RenderThemeChromiumWin::paintButton):
3489         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
3490         (WebCore::RenderThemeChromiumWin::paintSliderThumb):
3491         (WebCore::RenderThemeChromiumWin::paintMenuList):
3492         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
3493         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
3494         (WebCore::RenderThemeChromiumWin::paintProgressBar):
3495
3496 2012-12-10  Dean Jackson  <dino@apple.com>
3497
3498         Support for CSS widows and orphans
3499         https://bugs.webkit.org/show_bug.cgi?id=9410
3500
3501         Reviewed by Darin Adler.
3502
3503         The CSS 'widow' and 'orphan' properties were supported by the parser and
3504         style system, but were not actually doing anything in layout. Now they do!
3505
3506         In order to not break existing content, I unfortunately had to go against
3507         the specification and change our default value from 2 to auto. A value of
3508         auto means that widows and orphans will not cause any page/column breaks.
3509
3510         Supporting orphans was a small change. During line layout, if we realise
3511         we need to move to a new page in a situation that would create an orphan,
3512         move the entire block to the new page. There was already code to do this.
3513
3514         Support for widows was trickier. When we finish laying out a block, count
3515         the number of hanging lines. If we've created a widow, and there are enough
3516         available lines on the previous page, then steal some and remember the line
3517         to break at. Trigger a relayout. Then notice the line that was marked for
3518         breaking and avoid the widow. This means some blocks go through layout
3519         twice, but as long as the widow value is small it shouldn't be a huge penalty.
3520
3521         Tests: fast/multicol/widows-and-orphans.html (new test)
3522                printing/page-break-orphans.html
3523                printing/page-break-orphans-and-widows.html
3524                printing/page-break-widows.html
3525
3526         * css/CSSComputedStyleDeclaration.cpp:
3527         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Return CSSValueAuto for widows and orphans if necessary.
3528         * css/CSSParser.cpp:
3529         (WebCore::CSSParser::parseValue): Support "auto" in widow and orphan property parsing.
3530         * css/StyleBuilder.cpp:
3531         (WebCore::StyleBuilder::StyleBuilder): Change property handler to something that supports auto.
3532         * page/animation/CSSPropertyAnimation.cpp:
3533         (WebCore::CSSPropertyAnimation::ensurePropertyMap): Add widows and orphans to the animation map.
3534         * rendering/RenderBlock.cpp:
3535         (WebCore::RenderBlock::layoutBlockChild): Detect if we've caused a widow-fixing break, and request relayout evaluation.
3536         (WebCore::RenderBlock::markForPaginationRelayoutIfNeeded): Test for a widow-fixing line.
3537         (WebCore::RenderBlock::setBreakAtLineToAvoidWidow): New function to remember where we should break on next layout.
3538         (WebCore::RenderBlock::adjustLinePositionForPagination): Move the entire block to a new page if this would create an orphan.
3539         * rendering/RenderBlock.h:
3540         (WebCore::RenderBlock::shouldBreakAtLineToAvoidWidow): New function to indicate if we are remembering a widow.
3541         (WebCore::RenderBlock::clearShouldBreakAtLineToAvoidWidow): Reset the line breaks.
3542         (WebCore::RenderBlock::lineBreakToAvoidWidow):
3543         (WebCore::RenderBlock::RenderBlockRareData::RenderBlockRareData): Add a flag for indicating if we are remembering a line, and the actual line itself.
3544         * rendering/RenderBlockLineLayout.cpp:
3545         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): The code to detect and fix widows. Explained above.
3546         * rendering/style/RenderStyle.h: New methods for indicating if widows and orphans are non-default values.
3547         * rendering/style/StyleRareInheritedData.cpp: Ditto.
3548         * rendering/style/StyleRareInheritedData.h: Ditto.
3549
3550 2012-12-10  Zan Dobersek  <zandobersek@gmail.com>
3551
3552         REGRESSION (r118735): svg/dom/complex-svgView-specification.html, svg/dom/SVGViewSpec.html, svg/dom/viewspec-parser.html failing on GTK Linux 64-bit Release
3553         https://bugs.webkit.org/show_bug.cgi?id=87734
3554
3555         Reviewed by Martin Robinson.
3556
3557         Don't modify ResourceRequest's URL to have the value of the (encoded)
3558         URI of the SoupMessage. The only exception is in the case of cancelled
3559         SoupMessage - the URL of the ResourceRequest should then be null.
3560
3561         No new tests - existing tests should show no regressions.
3562
3563         * platform/network/soup/ResourceRequestSoup.cpp:
3564         (WebCore::ResourceRequest::updateFromSoupMessage):
3565
3566 2012-12-10  Gustavo Noronha Silva  <gns@gnome.org>
3567
3568         Unreviewed distcheck fix.
3569
3570         * GNUmakefile.list.am:
3571
3572 2012-12-10  Eric Seidel  <eric@webkit.org>
3573
3574         Caused crashes in v8.  Rolling out until abarth can fix.  See cr-issue 165136 for more info
3575         https://bugs.webkit.org/show_bug.cgi?id=104575
3576
3577         Unreviewed, just rolling out r136559.
3578
3579         * bindings/v8/V8GCController.cpp:
3580         * bindings/v8/V8NodeFilterCondition.cpp:
3581         (WebCore::V8NodeFilterCondition::V8NodeFilterCondition):
3582         (WebCore::V8NodeFilterCondition::acceptNode):
3583         * bindings/v8/V8NodeFilterCondition.h:
3584         (WebCore::V8NodeFilterCondition::create):
3585         (V8NodeFilterCondition):
3586         * dom/NodeFilter.h:
3587
3588 2012-12-10  Eric Carlson  <eric.carlson@apple.com>
3589
3590         Unreviewed build fix after r137167.
3591
3592         * WebCore.xcodeproj/project.pbxproj: Add InbandTextTrackPrivate.h to framework private 
3593             headers.
3594
3595 2012-12-10  Martin Robinson  <mrobinson@igalia.com>
3596
3597         Fix the GTK+ build after a collision of two patches.
3598
3599         Unreviewed build fix.
3600
3601         * bindings/gobject/GNUmakefile.am: The GObject DOM bindings library needs to
3602         include the harfbuzz cflags when compiling.
3603
3604 2012-12-10  Parth Patel  <parpatel@rim.com>
3605
3606         Make hiddenPageDomTimerInterval a setting
3607         https://bugs.webkit.org/show_bug.cgi?id=104555
3608
3609         Reviewed by Yong Li.
3610
3611         Make hiddenPageDomTimerInterval a setting so client can customize it.
3612
3613         No new tests are needed.
3614
3615         * page/Page.cpp:
3616         (WebCore):
3617         (WebCore::Page::setVisibilityState):
3618         * page/Settings.cpp:
3619         (WebCore):
3620         (WebCore::Settings::setHiddenPageDOMTimerAlignmentInterval):
3621         (WebCore::Settings::hiddenPageDOMTimerAlignmentInterval):
3622         * page/Settings.h:
3623         (Settings):
3624
3625 2012-12-10  peavo@outlook.com  <peavo@outlook.com>
3626
3627         [WinCairo] Compile fix in ImageCairoWin.cpp
3628         https://bugs.webkit.org/show_bug.cgi?id=104554
3629
3630         Reviewed by Brent Fulgham.
3631
3632         * platform/graphics/win/ImageCairoWin.cpp:
3633         (WebCore::BitmapImage::getHBITMAPOfSize): Added parameter.
3634         (WebCore::BitmapImage::drawFrameMatchingSourceSize): Added parameter.
3635
3636 2012-12-10  Mike West  <mkwst@chromium.org>
3637
3638         Log to console when script is blocked by sandbox attributes.
3639         https://bugs.webkit.org/show_bug.cgi?id=104365
3640
3641         Reviewed by Ojan Vafai.
3642
3643         Adds a console message to cover script execution blocked within the
3644         context of a sandboxed frame which lacks the 'allow-scripts' permission.
3645
3646         * bindings/ScriptControllerBase.cpp:
3647         (WebCore::ScriptController::canExecuteScripts):
3648             Log a warning when sandboxing flags block script execution.
3649
3650 2012-12-10  Chris Fleizach  <cfleizach@apple.com>
3651
3652         AX: Crash in NSAccessibilityUnignoredDescendant
3653         https://bugs.webkit.org/show_bug.cgi?id=104468
3654
3655         Reviewed by Anders Carlsson.
3656
3657         This crash occurred because AccessibilityScrollView stopped retaining it's ScrollView pointer.
3658
3659         Unfortunately, there was still a case that didn't correctly clear that variable. 
3660
3661         That case was when a Frame had a new FrameView associated with it. The old FrameView didn't inform the 
3662         accessibility object cache that it should be removed. As a result, when the FrameView deallocated and 
3663         did try to remove, it used the wrong AXObjectCache because it was no longer correctly hooked into the 
3664         document tree.
3665
3666         No new tests. Existing tests will stop crashing.
3667  
3668         * page/Frame.cpp:
3669         (WebCore::Frame::setView): change the name of the method that tells the FrameView to detach
3670         * page/FrameView.cpp:
3671         (WebCore::FrameView::~FrameView):
3672         (WebCore::FrameView::removeFromAXObjectCache): add a method that can be called in multiple places
3673         (WebCore::FrameView::isFrameView):
3674         (WebCore::FrameView::prepareForDetach): detaches scrollbars and accessibility
3675         * page/FrameView.h:
3676         (FrameView):
3677
3678 2012-12-10  Mark Pilgrim  <pilgrim@chromium.org>
3679
3680         [Chromium] Move getPluginsList out of PlatformSupport
3681         https://bugs.webkit.org/show_bug.cgi?id=96507
3682
3683         Reviewed by Darin Fisher.
3684
3685         Part of a refactoring series. See tracking bug 82948.
3686
3687         * WebCore.gypi:
3688         * platform/chromium/PlatformSupport.h:
3689         (PlatformSupport):
3690         * plugins/chromium/PluginDataChromium.cpp:
3691         (WebCore::PluginCache::plugins):
3692         * plugins/chromium/PluginListBuilder.cpp: Added.
3693         (WebKit):
3694         (WebKit::PluginListBuilder::addPlugin):
3695         (WebKit::PluginListBuilder::addMediaTypeToLastPlugin):
3696         (WebKit::PluginListBuilder::addFileExtensionToLastMediaType):
3697         * plugins/chromium/PluginListBuilder.h: Added.
3698         (WebKit):
3699         (PluginListBuilder):
3700         (WebKit::PluginListBuilder::PluginListBuilder):
3701
3702 2012-12-10  Carlos Garcia Campos  <cgarcia@igalia.com>
3703
3704         [GTK] Build GObject DOM bindings as a separate library
3705         https://bugs.webkit.org/show_bug.cgi?id=104527
3706
3707         Reviewed by Xan Lopez.
3708
3709         * bindings/gobject/GNUmakefile.am: Add libWebCoreDOM library.
3710         * bindings/gobject/WebKitDOMBinding.h: Define private macros.
3711         * bindings/gobject/WebKitDOMCustom.h: Don't include webkit/webkitdefines.h.
3712         * bindings/gobject/WebKitDOMEventTarget.h: Ditto.
3713         * bindings/gobject/WebKitDOMObject.h: Ditto.
3714         * bindings/scripts/CodeGeneratorGObject.pm:
3715         (Generate): Don't include webkitglobalsprivate.h.
3716         (WriteData): Don't include webkit/webkitdefines.h.
3717         * bindings/scripts/gobject-generate-headers.pl: Define WEBKIT_API
3718         macro in webkitdomdefines.h.
3719         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
3720         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.h:
3721         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
3722         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
3723         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
3724         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
3725         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
3726         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
3727         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
3728         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.h:
3729         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
3730         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
3731         * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
3732         * bindings/scripts/test/GObject/WebKitDOMTestException.h:
3733         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
3734         * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
3735         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
3736         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.h:
3737         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
3738         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.h:
3739         * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
3740         * bindings/scripts/test/GObject/WebKitDOMTestNode.h:
3741         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
3742         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
3743         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.cpp:
3744         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.h:
3745         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
3746         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h:
3747
3748 2012-12-10  Adam Klein  <adamk@chromium.org>
3749
3750         In InbandTextTrackPrivate, return emptyAtoms instead of emptyString() by default.
3751
3752         Unreviewed build fix.
3753
3754         * platform/graphics/InbandTextTrackPrivate.h:
3755         (WebCore::InbandTextTrackPrivate::label):
3756         (WebCore::InbandTextTrackPrivate::language):
3757
3758 2012-12-10  Ilya Tikhonovsky  <loislo@chromium.org>
3759
3760         Web Inspector: Native Memory Instrumentation: instrument RenderBox descendants.
3761         https://bugs.webkit.org/show_bug.cgi?id=104026
3762
3763         Reviewed by Eric Seidel.
3764
3765         Plain vanilla instrumentation for RenderBox descendants.
3766
3767         * rendering/RenderFrameSet.cpp:
3768         (WebCore::RenderFrameSet::reportMemoryUsage):
3769         (WebCore):
3770         (WebCore::RenderFrameSet::GridAxis::reportMemoryUsage):
3771         * rendering/RenderFrameSet.h:
3772         (RenderFrameSet):
3773         (GridAxis):
3774         * rendering/RenderListMarker.cpp:
3775         (WebCore::RenderListMarker::reportMemoryUsage):
3776         (WebCore):
3777         * rendering/RenderListMarker.h:
3778         (RenderListMarker):
3779         * rendering/RenderReplaced.cpp:
3780         (WebCore::RenderReplaced::reportMemoryUsage):
3781         (WebCore):
3782         * rendering/RenderReplaced.h:
3783         (RenderReplaced):
3784         * rendering/RenderTableCol.cpp:
3785         (WebCore::RenderTableCol::reportMemoryUsage):
3786         (WebCore):
3787         * rendering/RenderTableCol.h:
3788         (RenderTableCol):
3789         * rendering/RenderTableRow.cpp:
3790         (WebCore::RenderTableRow::reportMemoryUsage):
3791         (WebCore):
3792         * rendering/RenderTableRow.h:
3793         (RenderTableRow):
3794         * rendering/RenderTableSection.cpp:
3795         (WebCore::RenderTableSection::reportMemoryUsage):
3796         (WebCore):
3797         (WebCore::RenderTableSection::RowStruct::reportMemoryUsage):
3798         (WebCore::RenderTableSection::CellStruct::reportMemoryUsage):
3799         * rendering/RenderTableSection.h:
3800         (CellStruct):
3801         (RowStruct):
3802
3803 2012-12-10  Alejandro Piñeiro  <apinheiro@igalia.com>
3804
3805         AX: wrong Enabled states on a ListBox
3806         https://bugs.webkit.org/show_bug.cgi?id=104483
3807
3808         Reviewed by Chris Fleizach.
3809
3810         Test: accessibility/listbox-enabled-states.html
3811
3812         * accessibility/AccessibilityListBoxOption.cpp:
3813         (WebCore::AccessibilityListBoxOption::isEnabled): taking into
3814         account the DISABLED attribute and the aria-disabled attribute to
3815         decide if the item is enabled or not.
3816
3817 2012-12-10  Adam Klein  <adamk@chromium.org>
3818
3819         cr-win build fix after r137161.
3820
3821         Unreviewed.
3822
3823         * platform/graphics/MediaPlayer.h: Replace forward-decl of
3824         InbandTextTrackPrivate with #include as the definition is required.
3825
3826 2012-12-10  Alexis Menard  <alexis@webkit.org>
3827
3828         [CSS3 Backgrounds and Borders] Remove CSS3_BACKGROUND feature flag.
3829         https://bugs.webkit.org/show_bug.cgi?id=104539
3830
3831         Reviewed by Antonio Gomes.
3832
3833         As discussed on webkit-dev it is not needed to keep this feature flag 
3834         as support for <position> type is a small feature that is already 
3835         implemented by three other UAs. It was useful while landing this 
3836         feature as partial bits were landed one after one.
3837
3838         No new tests : the feature is covered by various tests and it is already enabled in many ports.
3839
3840         * Configurations/FeatureDefines.xcconfig:
3841         * GNUmakefile.am:
3842         * GNUmakefile.features.am:
3843         * css/CSSParser.cpp:
3844         (WebCore::CSSParser::parseFillPosition):
3845         (WebCore::CSSParser::parseFillProperty):
3846         * css/CSSParser.h:
3847         * css/CSSToStyleMap.cpp:
3848         (WebCore::CSSToStyleMap::mapFillXPosition):
3849         (WebCore::CSSToStyleMap::mapFillYPosition):
3850         * rendering/style/FillLayer.cpp:
3851         (SameSizeAsFillLayer):
3852         (WebCore::FillLayer::FillLayer):
3853         (WebCore::FillLayer::operator=):
3854         (WebCore::FillLayer::operator==):
3855         (WebCore::FillLayer::fillUnsetProperties):
3856         * rendering/style/FillLayer.h:
3857         (WebCore::FillLayer::backgroundXOrigin):
3858         (WebCore::FillLayer::backgroundYOrigin):
3859         (WebCore::FillLayer::isBackgroundOriginSet):
3860         (WebCore::FillLayer::clearXPosition):
3861         (WebCore::FillLayer::clearYPosition):
3862         (FillLayer):
3863
3864 2012-12-10  Eric Carlson  <eric.carlson@apple.com>
3865
3866         Add support for in-band text tracks to Mac port
3867         https://bugs.webkit.org/show_bug.cgi?id=103663
3868
3869         Reviewed by Sam Weinig.
3870
3871         Test: media/track/track-in-band.html
3872
3873         * GNUmakefile.list.am: Move InbandTextTrackPrivate.h to platform/graphics. Add InbandTextTrackPrivateClient.h.
3874         * Target.pri: Ditto.
3875         * WebCore.gypi: Ditto.
3876
3877         * WebCore.xcodeproj/project.pbxproj: Add new files.
3878
3879         * html/HTMLMediaElement.cpp:
3880         (WebCore::HTMLMediaElement::setReadyState): No need to call processInbandTextTracks, in-band tracks
3881             are now registered by the media engine as they are discovered.
3882         (WebCore::HTMLMediaElement::mediaPlayerDidAddTrack): New, called by the media player when a new
3883             in-band track is found.
3884         (WebCore::HTMLMediaElement::mediaPlayerDidRemoveTrack): New, called by the media player when an
3885             in-band track goes away.
3886         * html/HTMLMediaElement.h:
3887
3888         * html/track/InbandTextTrack.cpp:
3889         (WebCore::InbandTextTrack::InbandTextTrack): Use m_private instead of tracksPrivate because
3890             it is zeroed during assignment.
3891
3892         * platform/graphics/MediaPlayer.cpp:
3893         (WebCore::MediaPlayer::addTextTrack): New MediaPlayerClient method to allow MediaPlayerPrivate subclasses
3894             to add a new in-band track.
3895         (WebCore::MediaPlayer::removeTextTrack): New MediaPlayerClient method to allow MediaPlayerPrivate subclasses
3896             to remove a new in-band track.
3897         * platform/graphics/MediaPlayer.h:
3898         * platform/graphics/MediaPlayerPrivate.h:
3899
3900         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp: Added.
3901         (WebCore::InbandTextTrackPrivateAVF::InbandTextTrackPrivateAVF):
3902         (WebCore::InbandTextTrackPrivateAVF::~InbandTextTrackPrivateAVF):
3903         (WebCore::InbandTextTrackPrivateAVF::processCueAttributes): Convert an attribute string into WebVTT 
3904             cue setting and content strings.
3905         (WebCore::InbandTextTrackPrivateAVF::processCue): Process a new cue.
3906         (WebCore::InbandTextTrackPrivateAVF::disconnect): Clear member variables.
3907         (WebCore::InbandTextTrackPrivateAVF::resetCueValues): Reset cue values to defaults.
3908         (WebCore::InbandTextTrackPrivateAVF::setMode): Set track mode and call player's trackModeChanged.
3909         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h: Added.
3910
3911         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp: Initialize 
3912             m_inbandTrackConfigurationPending.
3913         (WebCore::MediaPlayerPrivateAVFoundation::MediaPlayerPrivateAVFoundation):
3914         (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted): Flush the currently accumulating
3915             cue so it doesn't get the wrong duration.
3916         (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification): Handle InbandTracksNeedConfiguration.
3917         (WebCore::MediaPlayerPrivateAVFoundation::flushCurrentCue): New, pass the current cue up to the client.
3918         (WebCore::MediaPlayerPrivateAVFoundation::configureInbandTracks): Configure in-band tracks.
3919         (WebCore::MediaPlayerPrivateAVFoundation::trackModeChanged): Schedule a call to configureInbandTracks.
3920         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
3921
3922         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h: Added.
3923         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm: Added.
3924         (WebCore::InbandTextTrackPrivateAVFObjC::InbandTextTrackPrivateAVFObjC):
3925         (WebCore::InbandTextTrackPrivateAVFObjC::disconnect):
3926         (WebCore::InbandTextTrackPrivateAVFObjC::kind): Return track kind.
3927         (WebCore::InbandTextTrackPrivateAVFObjC::label): Return track label.
3928         (WebCore::InbandTextTrackPrivateAVFObjC::language): Return track language.
3929         (WebCore::InbandTextTrackPrivateAVFObjC::isDefault): 
3930         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
3931         (MediaPlayerPrivateAVFoundationObjC):
3932         (WebCore::MediaPlayerPrivateAVFoundationObjC::playerItem):
3933         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3934         (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize m_currentTrack.
3935         (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad): Clear m_legibleOutput.
3936         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Create and initialize m_legibleOutput.
3937         (WebCore::MediaPlayerPrivateAVFoundationObjC::processTextTracks): Called when the player item's
3938             "tracks" changes, add and remove in-band text tracks as necessary.
3939         (WebCore::MediaPlayerPrivateAVFoundationObjC::processCue): Pass an attributed string to the current 
3940             track to be processed.
3941         (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTrack): Tell AVFoundation to select an in-band track.
3942         (WebCore::MediaPlayerPrivateAVFoundationObjC::currentTrack): Return the current track.
3943         (-[WebCoreAVFMovieObserver legibleOutput:didOutputAttributedStrings:nativeSampleBuffers:forItemTime:]): Legible
3944             output delegate.
3945
3946 2012-12-10  Pavel Feldman  <pfeldman@chromium.org>
3947
3948         Web Inspector: fix front-end compilation warnings
3949         https://bugs.webkit.org/show_bug.cgi?id=104557
3950
3951         Reviewed by Alexander Pavlov.
3952
3953         Corresponding annotations added.
3954
3955         * inspector/Inspector.json:
3956         * inspector/InspectorDOMAgent.cpp:
3957         (WebCore::InspectorDOMAgent::highlightNode):
3958         * inspector/InspectorDOMAgent.h:
3959         (InspectorDOMAgent):
3960         * inspector/front-end/CSSStyleModel.js:
3961         (WebInspector.CSSStyleDeclaration.prototype.):
3962         (WebInspector.CSSStyleDeclaration.prototype.insertPropertyAt):
3963         * inspector/front-end/ConsoleMessage.js:
3964         (WebInspector.ConsoleMessageImpl.prototype._appendPropertyPreview):
3965         * inspector/front-end/DOMAgent.js:
3966         (WebInspector.DOMAgent.prototype.highlightDOMNode):
3967         * inspector/front-end/DOMPresentationUtils.js:
3968         (WebInspector.DOMPresentationUtils.linkifyNodeReference):
3969         * inspector/front-end/ObjectPropertiesSection.js:
3970         (WebInspector.ObjectPropertyTreeElement.prototype.update):
3971         * inspector/front-end/Toolbar.js:
3972
3973 2012-12-10  Zeno Albisser  <zeno@webkit.org>
3974
3975         [Qt] MediaPlayerQTKit broken after switching QPainter to raster engine.
3976         https://bugs.webkit.org/show_bug.cgi?id=104550
3977
3978         With Qt5 QPainter changed to using the raster engine.
3979         Therefore we no longer have an NSGraphicsContext that we can
3980         use for drawing video frames.
3981         With this patch we are rendering the video frame into an image buffer
3982         and then paint it manually using QPainter.
3983
3984         Reviewed by Simon Hausmann.
3985
3986         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3987         (WebCore):
3988         (WebCore::swapBgrToRgb):
3989             Swap the color format from BGR to RGB,
3990             since BGR is not supported by QImage.
3991         (WebCore::MediaPlayerPrivateQTKit::paint):
3992
3993 2012-12-10  peavo@outlook.com  <peavo@outlook.com>
3994
3995         [WinCairo] Link fix in InspectorController.cpp
3996         https://bugs.webkit.org/show_bug.cgi?id=104556
3997
3998         Reviewed by Pavel Feldman.
3999
4000         * inspector/InspectorController.cpp:
4001         (WebCore::InspectorController::InspectorController): Added missing #if check.
4002
4003 2012-12-10  Pavel Feldman  <pfeldman@chromium.org>
4004
4005         Web Inspector: remove the Overrides / Settings context menu from gear icon
4006         https://bugs.webkit.org/show_bug.cgi?id=104546
4007
4008         Reviewed by Alexander Pavlov.
4009
4010         It sounds like too many people don't like the way it works. Bringing things back: overrides will be a tab in settings for now.
4011         Moving present behavior to under experiment.
4012
4013         * inspector/front-end/OverridesView.js:
4014         (WebInspector.OverridesView):
4015         * inspector/front-end/Settings.js:
4016         (WebInspector.ExperimentsSettings):
4017         * inspector/front-end/SettingsScreen.js:
4018         (WebInspector.OverridesSettingsTab):
4019         (WebInspector.SettingsController):
4020         (WebInspector.SettingsController.prototype.get statusBarItem):
4021         (WebInspector.SettingsController.prototype._mouseDo