Clean up ScopedEventQueue
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-10-28  Zan Dobersek  <zdobersek@igalia.com>
2
3         Clean up ScopedEventQueue
4         https://bugs.webkit.org/show_bug.cgi?id=123408
5
6         Reviewed by Darin Adler.
7
8         Clean up the ScopedEventQueue implementation. ScopedEventQueue::instance() should return a reference to a
9         NeverDestroyed<ScopedEventQueue> object. The static ScopedEventQueue::s_instance pointer is removed.
10
11         The ScopedEventQueue destructor, the dispatchAllEvents method and the scope level incrementation/decrementation
12         methods are made private. NeverDestroyed<ScopedEventQueue> and EventQueueScope are made friends of the
13         ScopedEventQueue class so they can access the constructor and the incrementation/decrementation methods, respectively.
14
15         ScopedEventQueue method definitions are reordered to follow the order of their declarations in the header file.
16         ScopedEventQueue::dispatchAllEvents() now uses std::move to efficiently dispatch and clear all currently queued events.
17
18         * dom/EventDispatcher.cpp:
19         (WebCore::EventDispatcher::dispatchScopedEvent):
20         * dom/ScopedEventQueue.cpp:
21         (WebCore::ScopedEventQueue::instance):
22         (WebCore::ScopedEventQueue::dispatchAllEvents):
23         * dom/ScopedEventQueue.h:
24         (WebCore::EventQueueScope::EventQueueScope):
25         (WebCore::EventQueueScope::~EventQueueScope):
26
27 2013-10-28  Andreas Kling  <akling@apple.com>
28
29         applyTextTransform() should take a const RenderStyle&.
30         <https://webkit.org/b/123434>
31
32         This function is always called with an existing RenderStyle object.
33
34         Reviewed by Anders Carlsson.
35
36 2013-10-28  Andreas Kling  <akling@apple.com>
37
38         RenderSVGResource::applyResource() should take a const RenderStyle&.
39         <https://webkit.org/b/123433>
40
41         These functions are always called with an existing RenderStyle object
42         so let them take a const reference instead of a raw pointer.
43         Also sprinkled some missing OVERRIDEs.
44
45         Reviewed by Anders Carlsson.
46
47 2013-10-28  Andreas Kling  <akling@apple.com>
48
49         Remove unused RenderTextControl::textBaseStyle().
50         <https://webkit.org/b/123432>
51
52         Reviewed by Anders Carlsson.
53
54 2013-10-28  Zan Dobersek  <zdobersek@igalia.com>
55
56         HTML input type objects should be managed through std::unique_ptr
57         https://bugs.webkit.org/show_bug.cgi?id=123160
58
59         Reviewed by Darin Adler.
60
61         Make the constructors of the InputType subclasses public. This makes it possible to use std::make_unique on these classes
62         and makes the T::create() helpers redundant. New instances of these classes are now managed through std::unique_ptr.
63
64         InputType::create() now uses a NeverDestroyed InputTypeFactoryMap that maps type names to InputTypeFactoryFunctions and
65         gets populated when the method is first called and the map is still empty. Certain types are not added to the factory map
66         if they're disabled at runtime.
67
68         The factory is used to create the new InputType object if the requested type was found in the map, and TextInputType is used otherwise.
69
70         * html/ButtonInputType.cpp:
71         * html/ButtonInputType.h:
72         (WebCore::ButtonInputType::ButtonInputType):
73         * html/CheckboxInputType.cpp:
74         * html/CheckboxInputType.h:
75         (WebCore::CheckboxInputType::CheckboxInputType):
76         * html/ColorInputType.cpp:
77         * html/ColorInputType.h:
78         (WebCore::ColorInputType::ColorInputType):
79         * html/DateInputType.cpp:
80         * html/DateInputType.h:
81         * html/DateTimeInputType.cpp:
82         * html/DateTimeInputType.h:
83         (WebCore::DateTimeInputType::DateTimeInputType):
84         * html/DateTimeLocalInputType.cpp:
85         * html/DateTimeLocalInputType.h:
86         (WebCore::DateTimeLocalInputType::DateTimeLocalInputType):
87         * html/EmailInputType.cpp:
88         * html/EmailInputType.h:
89         (WebCore::EmailInputType::EmailInputType):
90         * html/FileInputType.cpp:
91         * html/FileInputType.h:
92         * html/HTMLInputElement.cpp:
93         (WebCore::HTMLInputElement::updateType):
94         * html/HTMLInputElement.h:
95         * html/HiddenInputType.cpp:
96         * html/HiddenInputType.h:
97         (WebCore::HiddenInputType::HiddenInputType):
98         * html/ImageInputType.cpp:
99         (WebCore::ImageInputType::ImageInputType):
100         * html/ImageInputType.h:
101         * html/InputType.cpp:
102         (WebCore::createInputType): A templated helper that constructs a new InputType subclass object through std::make_unique.
103         (WebCore::populateInputTypeFactoryMap): Populates the passed-in map with type-createInputType<T> pairs.
104         (WebCore::InputType::create): Get the InputTypeFactoryFunction for the specified type, or fall back to TextInputType.
105         (WebCore::InputType::createText):
106         * html/InputType.h:
107         * html/MonthInputType.cpp:
108         * html/MonthInputType.h:
109         (WebCore::MonthInputType::MonthInputType):
110         * html/NumberInputType.cpp:
111         * html/NumberInputType.h:
112         (WebCore::NumberInputType::NumberInputType):
113         * html/PasswordInputType.cpp:
114         * html/PasswordInputType.h:
115         (WebCore::PasswordInputType::PasswordInputType):
116         * html/RadioInputType.cpp:
117         * html/RadioInputType.h:
118         (WebCore::RadioInputType::RadioInputType):
119         * html/RangeInputType.cpp:
120         * html/RangeInputType.h:
121         * html/ResetInputType.cpp:
122         * html/ResetInputType.h:
123         (WebCore::ResetInputType::ResetInputType):
124         * html/SearchInputType.cpp:
125         (WebCore::SearchInputType::SearchInputType):
126         * html/SearchInputType.h:
127         * html/SubmitInputType.cpp:
128         * html/SubmitInputType.h:
129         (WebCore::SubmitInputType::SubmitInputType):
130         * html/TelephoneInputType.cpp:
131         * html/TelephoneInputType.h:
132         (WebCore::TelephoneInputType::TelephoneInputType):
133         * html/TextInputType.cpp:
134         * html/TextInputType.h:
135         (WebCore::TextInputType::TextInputType):
136         * html/TimeInputType.cpp:
137         * html/TimeInputType.h:
138         * html/URLInputType.cpp:
139         * html/URLInputType.h:
140         (WebCore::URLInputType::URLInputType):
141         * html/WeekInputType.cpp:
142         * html/WeekInputType.h:
143         (WebCore::WeekInputType::WeekInputType):
144
145 2013-10-28  Brady Eidson  <beidson@apple.com>
146
147         Refactor IDB factory creation.
148         https://bugs.webkit.org/show_bug.cgi?id=123347
149
150         Reviewed by Andreas Kling.
151
152         - Rework how database directory location is passed around.
153         - Make (some) SecurityOrigin arguments be references instead of pointers.
154         - Add two SecurityOrigin arguments to opening databases for future use.
155
156         * Modules/indexeddb/IDBFactory.cpp:
157         (WebCore::IDBFactory::openInternal):
158
159         * Modules/indexeddb/IDBFactoryBackendInterface.cpp:
160         (WebCore::IDBFactoryBackendInterface::create):
161         * Modules/indexeddb/IDBFactoryBackendInterface.h:
162
163         * Modules/indexeddb/PageGroupIndexedDatabase.cpp:
164         (WebCore::PageGroupIndexedDatabase::PageGroupIndexedDatabase):
165         (WebCore::PageGroupIndexedDatabase::from):
166         (WebCore::PageGroupIndexedDatabase::factoryBackend):
167         * Modules/indexeddb/PageGroupIndexedDatabase.h:
168
169         * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.cpp:
170         (WebCore::WorkerGlobalScopeIndexedDatabase::WorkerGlobalScopeIndexedDatabase):
171         (WebCore::WorkerGlobalScopeIndexedDatabase::from):
172         (WebCore::WorkerGlobalScopeIndexedDatabase::indexedDB):
173         * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.h:
174
175         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
176         (WebCore::IDBBackingStoreLevelDB::open):
177         (WebCore::IDBBackingStoreLevelDB::openInMemory):
178         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
179
180         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
181         (WebCore::computeFileIdentifier):
182         (WebCore::computeUniqueIdentifier):
183         (WebCore::IDBFactoryBackendLevelDB::IDBFactoryBackendLevelDB):
184         (WebCore::IDBFactoryBackendLevelDB::getDatabaseNames):
185         (WebCore::IDBFactoryBackendLevelDB::deleteDatabase):
186         (WebCore::IDBFactoryBackendLevelDB::openBackingStore):
187         (WebCore::IDBFactoryBackendLevelDB::open):
188         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.h:
189         (WebCore::IDBFactoryBackendLevelDB::create):
190
191         * WebCore.exp.in:
192
193         * platform/DatabaseStrategy.cpp:
194         (WebCore::DatabaseStrategy::createIDBFactoryBackend):
195         * platform/DatabaseStrategy.h:
196
197 2013-10-28  Andreas Kling  <akling@apple.com>
198
199         RenderElement::style() should return a reference.
200         <https://webkit.org/b/123414>
201
202         Now that renderers always have style, go ahead and make style()
203         return a RenderStyle&.
204
205         There are countless opportunities for further cleanup enabled by
206         this change. I'm simply passing &style() in many cases where we
207         can really do something nicer instead.
208
209         Reviewed by Anders Carlsson.
210
211 2013-10-28  Tim Horton  <timothy_horton@apple.com>
212
213         Make TileController create the appropriate PlatformCALayer subclasses
214         https://bugs.webkit.org/show_bug.cgi?id=123418
215
216         Reviewed by Simon Fraser.
217
218         Add PlatformCALayer::createCompatibleLayer, which is overridden in
219         each of the subclasses to create a PlatformCALayer instance of the same
220         subclass. This is used in TileController to make bare PlatformCALayers
221         of the correct type (Mac, Win, or Remote).
222
223         * platform/graphics/ca/PlatformCALayer.h:
224         * platform/graphics/ca/mac/PlatformCALayerMac.h:
225         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
226         (PlatformCALayerMac::createCompatibleLayer):
227         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
228         (PlatformCALayerWin::createCompatibleLayer):
229         * platform/graphics/ca/win/PlatformCALayerWin.h:
230         Add createCompatibleLayer and implement it in the subclasses.
231
232         * platform/graphics/ca/mac/TileController.mm:
233         (WebCore::TileController::TileController):
234         (WebCore::TileController::tiledScrollingIndicatorLayer):
235         (WebCore::TileController::createTileLayer):
236         Make use of createCompatibleLayer when creating PlatformCALayers.
237
238 2013-10-28  Alexandru Chiculita  <achicu@adobe.com>
239
240         Web Inspector: CSS Regions: Add protocol API to expose content nodes addition/removal
241         https://bugs.webkit.org/show_bug.cgi?id=123424
242
243         Reviewed by Timothy Hatcher.
244
245         Test: inspector-protocol/model/content-flow-content-nodes.html
246
247         Adding two new inspector-protocol APIs to handle the cases when new elements are
248         added or removed from a named flow. These APIs will trigger even though there
249         is no region associated with the named flow.
250
251         * inspector/Inspector.json:
252         * inspector/InspectorCSSAgent.cpp:
253         (WebCore::InspectorCSSAgent::didRegisterNamedFlowContentElement):
254         (WebCore::InspectorCSSAgent::didUnregisterNamedFlowContentElement):
255         * inspector/InspectorCSSAgent.h:
256         * inspector/InspectorInstrumentation.cpp:
257         (WebCore::InspectorInstrumentation::didRegisterNamedFlowContentElementImpl):
258         (WebCore::InspectorInstrumentation::didUnregisterNamedFlowContentElementImpl):
259         * inspector/InspectorInstrumentation.h:
260         (WebCore::InspectorInstrumentation::didRegisterNamedFlowContentElement):
261         (WebCore::InspectorInstrumentation::didUnregisterNamedFlowContentElement):
262         * rendering/RenderNamedFlowThread.cpp:
263         (WebCore::RenderNamedFlowThread::registerNamedFlowContentElement):
264         (WebCore::RenderNamedFlowThread::unregisterNamedFlowContentElement):
265
266 2013-10-28  Joseph Pecoraro  <pecoraro@apple.com>
267
268         Web Inspector: Remove unused inspector/inline-javascript-imports.py
269         https://bugs.webkit.org/show_bug.cgi?id=123425
270
271         Reviewed by Timothy Hatcher.
272
273         * inspector/inline-javascript-imports.py: Removed.
274
275 2013-10-28  Joseph Pecoraro  <pecoraro@apple.com>
276
277         Web Inspector: Remove unused "externs" files and generators
278         https://bugs.webkit.org/show_bug.cgi?id=123427
279
280         Reviewed by Timothy Hatcher.
281
282         * inspector/InjectedScriptExterns.js: Removed.
283         * inspector/generate_protocol_externs.py: Removed.
284
285 2013-10-28  Joseph Pecoraro  <pecoraro@apple.com>
286
287         Upstream remaining PLATFORM(IOS) and ENABLE(REMOTE_INSPECTOR) pieces
288         https://bugs.webkit.org/show_bug.cgi?id=123411
289
290         Reviewed by Timothy Hatcher.
291
292         Include an InspectorClient hook for when node searching is enabled / disabled.
293
294         * inspector/InspectorClient.h:
295         (WebCore::InspectorClient::didSetSearchingForNode):
296         * inspector/InspectorDOMAgent.cpp:
297         (WebCore::InspectorDOMAgent::setSearchingForNode):
298         * inspector/InspectorOverlay.cpp:
299         (WebCore::InspectorOverlay::didSetSearchingForNode):
300         * inspector/InspectorOverlay.h:
301
302 2013-10-28  Benjamin Poulain  <benjamin@webkit.org>
303
304         Rename applyPageScaleFactorInCompositor to delegatesPageScaling
305         https://bugs.webkit.org/show_bug.cgi?id=123417
306
307         Reviewed by Simon Fraser.
308
309         * page/Frame.cpp:
310         (WebCore::Frame::frameScaleFactor):
311         * page/FrameView.cpp:
312         (WebCore::FrameView::visibleContentScaleFactor):
313         * page/Page.cpp:
314         (WebCore::Page::setPageScaleFactor):
315         * page/Settings.in:
316         * platform/ScrollView.h:
317         * rendering/RenderLayerCompositor.cpp:
318         (WebCore::RenderLayerCompositor::addToOverlapMap):
319
320 2013-10-28  Myles C. Maxfield  <mmaxfield@apple.com>
321
322         Parsing support for -webkit-text-decoration-skip: ink
323         https://bugs.webkit.org/show_bug.cgi?id=123358
324
325         Reviewed by Dean Jackson.
326
327         Adds initial parsing support for parsing -webkit-text-decoration-skip with
328         values of "none" and "ink". This work is behind the new
329         ENABLE(CSS3_TEXT_DECORATION) compile-time flag.
330
331         Test: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-roundtrip.html
332
333         * Configurations/FeatureDefines.xcconfig: Adding ENABLE(CSS3_TEXT_DECORATION)
334         * css/CSSComputedStyleDeclaration.cpp: Mapping internal representation of text-decoration-skip
335         to a CSSValue
336         (WebCore::renderTextDecorationSkipFlagsToCSSValue):
337         (WebCore::ComputedStyleExtractor::propertyValue):
338         * css/CSSParser.cpp: Actually parsing tokens
339         (WebCore::CSSParser::parseValue):
340         (WebCore::CSSParser::parseTextDecorationSkip):
341         * css/CSSParser.h:
342         * css/CSSPropertyNames.in: adding -webkit-text-decoration-skip
343         * css/CSSValueKeywords.in: adding ink
344         * css/DeprecatedStyleBuilder.cpp: Mapping from CSSValue to internal representation
345         (WebCore::ApplyPropertyTextDecorationSkip::valueToDecorationSkip):
346         (WebCore::ApplyPropertyTextDecorationSkip::applyValue):
347         (WebCore::ApplyPropertyTextDecorationSkip::createHandler):
348         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
349         * css/StyleResolver.cpp: decoration-skip uses DeprecatedStyleBuilder
350         (WebCore::StyleResolver::applyProperty):
351         * rendering/style/RenderStyle.h: Adding functions for modifying and accessing decoration-skip properties
352         * rendering/style/RenderStyleConstants.h: Definition of internal representation
353         * rendering/style/StyleRareInheritedData.cpp: Setting up constructors and comparators
354         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
355         (WebCore::StyleRareInheritedData::operator==):
356         * rendering/style/StyleRareInheritedData.h: Holds actual value of internal representation
357
358 2013-10-28  Anders Carlsson  <andersca@apple.com>
359
360         RunLoop::dispatch should take an std::function
361         https://bugs.webkit.org/show_bug.cgi?id=123407
362
363         Reviewed by Andreas Kling.
364
365         * WebCore.exp.in:
366         * platform/RunLoop.cpp:
367         (WebCore::RunLoop::performWork):
368         (WebCore::RunLoop::dispatch):
369         * platform/RunLoop.h:
370
371 2013-10-28  Tim Horton  <timothy_horton@apple.com>
372
373         Make TileController manipulate PlatformCALayers instead of CALayers
374         https://bugs.webkit.org/show_bug.cgi?id=123279
375
376         Reviewed by Simon Fraser.
377
378         In the interest of making TileController more platform-independent
379         (so that it can be used with the remote layer tree, and maybe Windows),
380         move TileController onto our PlatformCALayer abstraction instead of
381         direct manipulation of CALayers.
382
383         Some fallout from this includes getting rid of special Mac-specific
384         TileController-specific CALayer subclasses, and reworking tile
385         painting to work in a more generic way.
386
387         This is a first step, and doesn't get us all the way to a platform independent
388         TileController, but more patches are forthcoming.
389
390         No new tests, just a (largeish) refactor.
391
392         * WebCore.exp.in:
393         The signature of some methods has changed.
394
395         * WebCore.xcodeproj/project.pbxproj:
396         Remove WebTileLayer.*
397
398         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
399         (WebCore::ScrollingTreeScrollingNodeMac::logExposedUnfilledArea):
400         Use the "isTile" key on the CALayer dictionary instead of the layer's
401         class to determine if it's a tile. TileController will set this on a tile
402         when it is created, for now.
403
404         * platform/graphics/TiledBacking.h:
405         tiledScrollingIndicatorLayer() should return a PlatformCALayer.
406
407         * platform/graphics/ca/GraphicsLayerCA.cpp:
408         (WebCore::GraphicsLayerCA::platformCALayerPaintContents):
409         * platform/graphics/ca/GraphicsLayerCA.h:
410         (WebCore::GraphicsLayerCA::platformCALayerIncrementRepaintCount):
411         * platform/graphics/ca/PlatformCALayerClient.h:
412         The PlatformCALayerClient paintContents and incrementRepaintCount callbacks
413         should include the platformCALayer that caused the callback.
414
415         * platform/graphics/ca/PlatformCALayer.h:
416         Add LayerTypeSimpleLayer, which is similar to LayerTypeWebLayer
417         except it just calls back its client to paint, instead of doing
418         complicated things with repaint rects. This is so that TileController
419         doesn't re-enter drawLayerContents when asking its GraphicsLayer
420         to paint for each PlatformCALayer (it will be entering drawLayerContents
421         for the first time for each layer). It also happens to be useful
422         for things like the tile controller overlay, which don't need
423         all that complication.
424
425         Add LayerTypeTiledBackingTileLayer, which is used simply to distinguish
426         TileController Tile layers from other LayerTypeSimpleLayers.
427
428         * platform/graphics/ca/mac/LayerPool.h:
429         * platform/graphics/ca/mac/LayerPool.mm:
430         (WebCore::LayerPool::addLayer):
431         (WebCore::LayerPool::takeLayerWithSize):
432         LayerPool should operate on PlatformCALayers now.
433
434         * platform/graphics/ca/mac/PlatformCALayerMac.h:
435         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
436         (PlatformCALayerMac::PlatformCALayerMac):
437         Set the "isTile" key on the CALayer to true for TiledBackingTileLayers,
438         so that the scrolling performance logging can tell a tile apart from
439         any other layer, on the scrolling thread, without touching PlatformCALayers
440         or the TileController or any other main-thread data structures.
441
442         (PlatformCALayerMac::setEdgeAntialiasingMask): Added.
443         * platform/graphics/ca/mac/TileController.h:
444         Remove references to Objective-C classes; instead use PlatformCALayer everywhere.
445         TileController is now a PlatformCALayerClient, and the layers it owns are
446         all PlatformCALayers (and it is constructed with a PlatformCALayer, etc.).
447         Hand in the tile debug border color as a WebCore color, instead of a CGColorRef.
448         blankPixelCountForTiles() now operates on a list of PlatformLayers instead of
449         WebTileLayers specifically, since WebTileLayer is gone.
450         Make drawTileMapContents private because WebTileCacheMapLayer no longer exists.
451
452         (WebCore::TileController::platformCALayerDrawsContent):
453         All of the layers who have TileController as their client paint their contents.
454
455         (WebCore::TileController::platformCALayerContentsOpaque):
456         This will only be called for layers which paint via drawLayerContents,
457         so it's OK that we don't special-case the debugging overlay here.
458
459         (WebCore::TileController::owningGraphicsLayer):
460         Return the GraphicsLayer that owns the TileController's main
461         layer, via its conformance to PlatformCALayerClient. This is
462         a bit strange (because it's not strictly a GraphicsLayer, despite
463         always being so at the moment), but is done for clarity inside
464         TileController itself.
465
466         * platform/graphics/ca/mac/TileController.mm:
467         Remove CALayer (WebCALayerDetails), WebTiledScrollingIndicatorLayer,
468         and a bunch of includes that we don't need anymore.
469
470         (WebCore::TileController::create):
471         (WebCore::TileController::TileController):
472         TileController is passed a PlatformCALayer for the tile cache root layer,
473         instead of a WebTiledBackingLayer. It also creates a PlatformCALayer with
474         LayerTypeLayer instead of a bare CALayer for the container layer.
475         It's OK to remove the transaction because it was only used to stop
476         the implicit animation, which PlatformCALayer will do for us.
477
478         (WebCore::TileController::~TileController):
479         Clear the owner of the PlatformCALayers which the TileController previously owned,
480         so they don't try to call back a destroyed TileController.
481
482         (WebCore::TileController::tileCacheLayerBoundsChanged):
483         (WebCore::TileController::setNeedsDisplay):
484         Straightforward adjustments towards use of PlatformCALayer.
485
486         (WebCore::TileController::setTileNeedsDisplayInRect):
487         Adjustments towards use of PlatformCALayer; we need FloatRects so we can
488         pass pointers to PlatformCALayer::setNeedsDisplay.
489
490         (WebCore::TileController::platformCALayerPaintContents):
491         Replace drawLayer with platformCALayerPaintContents, which will be called
492         back from our various WebSimpleLayers. If the PlatformCALayer is our
493         tiled scrolling debug indicator, paint that. Otherwise, it's a tile.
494         Make use of drawLayerContents() to paint the tile contents.
495         Make use of drawRepaintIndicator() to paint the repaint indicator if needed.
496         Move scrolling performance logging code that used to be in WebTileLayer here.
497
498         (WebCore::TileController::platformCALayerDeviceScaleFactor):
499         (WebCore::TileController::platformCALayerShowDebugBorders):
500         (WebCore::TileController::platformCALayerShowRepaintCounter):
501         Forward these to the owning GraphicsLayerCA, because it will have the right answers.
502
503         (WebCore::TileController::setScale):
504         Adjustments towards use of PlatformCALayer; remove some code that Simon
505         caused to be unused in 156291 but did not remove.
506
507         (WebCore::TileController::setAcceleratesDrawing):
508         (WebCore::TileController::setTilesOpaque):
509         (WebCore::TileController::setVisibleRect):
510         (WebCore::TileController::revalidateTiles):
511         (WebCore::TileController::setTileDebugBorderWidth):
512         (WebCore::TileController::setTileDebugBorderColor):
513         (WebCore::TileController::bounds):
514         (WebCore::TileController::blankPixelCount):
515         (WebCore::TileController::blankPixelCountForTiles):
516         (WebCore::queueTileForRemoval):
517         (WebCore::TileController::setNeedsRevalidateTiles):
518         (WebCore::TileController::ensureTilesForRect):
519         (WebCore::TileController::retainedTileBackingStoreMemory):
520         Straightforward adjustments towards use of PlatformCALayer.
521
522         (WebCore::TileController::updateTileCoverageMap):
523         Adjustments towards use of PlatformCALayer; rename backgroundColor
524         to visibleRectIndicatorColor, since it's actually a border, not a background.
525
526         (WebCore::TileController::tiledScrollingIndicatorLayer):
527         Create a LayerTypeSimpleLayer PlatformCALayer for the tiled scrolling indicator.
528         It will be asked to paint straightforwardly, like a CALayer would.
529         Create a LayerTypeLayer PlatformCALayer for the visible rect indicator.
530         It doesn't need to paint anything, so it doesn't get an owner.
531
532         (WebCore::TileController::createTileLayer):
533         When creating a new tile layer, adopt it by setting its owner.
534         Otherwise, straightforward adjustments towards use of PlatformCALayer.
535
536         (WebCore::TileController::platformCALayerIncrementRepaintCount):
537         Manage repaint counts for tiles in TileController now.
538
539         (WebCore::TileController::drawTileMapContents):
540         Adjustments towards use of PlatformCALayer.
541
542         * platform/graphics/ca/mac/WebTileLayer.h: Removed.
543         * platform/graphics/ca/mac/WebTileLayer.mm: Removed.
544         We don't need WebTileLayer anymore, tiles are now just WebSimpleLayers
545         owned by TileController. Its behavior has been moved into TileController.
546
547         * platform/graphics/ca/mac/WebTiledBackingLayer.h:
548         * platform/graphics/ca/mac/WebTiledBackingLayer.mm:
549         (-[WebTiledBackingLayer createTileController:]):
550         Add createTileController: so that the WebTiledBackingLayer's owner can
551         hand the TileController the PlatformCALayer for the WebTiledBackingLayer
552         without propagating additional usage of PlatformCALayer::platformCALayer(),
553         which we need to remove in light of the remote layer tree work.
554
555         (-[WebTiledBackingLayer setBorderColor:]):
556
557         * platform/graphics/ca/win/PlatformCALayerWin.h:
558         Add an empty implementation of setEdgeAntialiasingMask.
559         We'll probably want to implement it before adopting TileController on Windows.
560
561         * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
562         (PlatformCALayerWinInternal::displayCallback):
563         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
564         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerPaintContents):
565         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerIncrementRepaintCount):
566         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
567         (WebCore::LayerClient::platformCALayerPaintContents):
568         (WebCore::LayerClient::platformCALayerIncrementRepaintCount):
569         Adjust for new parameters on PlatformCALayerClient callbacks.
570
571         * platform/graphics/mac/WebLayer.h:
572         Add WebSimpleLayer, which inherits directly from CALayer, and make
573         our standard WebLayer (which is used for compositing layers in web content)
574         inherit from that.
575
576         * platform/graphics/mac/WebLayer.mm:
577         Move most of the behavior of WebLayer onto WebSimpleLayer, except for its
578         complex painting code. That stays as an override on WebLayer.
579
580         (WebCore::drawLayerContents):
581         Use the PlatformCALayer's PlatformLayer - if it exists - to extract
582         fine-grained repaint rects. If it doesn't, we'll just use the CGContext's
583         clip rect as our single repaint rect.
584         Rename platformLayer to platformCALayer for accuracy.
585         Remove special code for CATiledLayer since we ought not use it on Mac anymore.
586
587         (WebCore::drawRepaintIndicator):
588         Factor repaint indicator code out into its own function so that TileController
589         can use it. It can't be called from drawLayerContents for TileController, since
590         the PlatformCALayer that TileController passes in to drawLayerContents is actually
591         that of the tile cache's root layer, not the tile itself.
592         Also, add a custom background color parameter so TileController can override
593         the default green color with its own standard purple.
594
595         (-[WebLayer drawInContext:]):
596         (-[WebSimpleLayer drawInContext:]):
597         * platform/graphics/mac/WebTiledLayer.mm:
598         (-[WebTiledLayer drawInContext:]):
599         Removed a param from drawLayerContents because it's trivially acquirable
600         from the PlatformCALayer.
601
602 2013-10-24  Sam Weinig  <sam@webkit.org>
603
604         Move RenderBlock functions only used by RenderBlockFlow to RenderBlockFlow
605         https://bugs.webkit.org/show_bug.cgi?id=123318
606
607         Reviewed by David Hyatt.
608
609         * rendering/LineLayoutState.h:
610         Move FloatWithRect from RenderBlock.
611
612         * rendering/RenderBlock.cpp:
613         * rendering/RenderBlock.h:
614         * rendering/RenderBlockFlow.cpp:
615         * rendering/RenderBlockFlow.h:
616         * rendering/RenderBlockLineLayout.cpp:
617         Move pagination and float functions.
618
619 2013-10-28  Sergio Villar Senin  <svillar@igalia.com>
620
621         [CSS Grid Layout] Add support for order inside grid items
622         https://bugs.webkit.org/show_bug.cgi?id=123208
623
624         Reviewed by Antti Koivisto.
625
626         Based on Blink r153457 and r153536 by <jchaffraix@chromium.org>
627
628         Added support for sorting grid items by using -webkit-order
629         property. Used OrderIterator to implement it so it had to be moved
630         out of RenderFlexibleBox to be shared with RenderGrid.
631
632         Tests: fast/css-grid-layout/grid-item-order-auto-flow-resolution.html
633                fast/css-grid-layout/grid-item-order-paint-order.html
634
635         * CMakeLists.txt: Added new file.
636         * GNUmakefile.list.am: Ditto.
637         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
638         * WebCore.xcodeproj/project.pbxproj: Ditto.
639         * rendering/OrderIterator.cpp: Added. Ripped out of RenderFlexibleBox.
640         (WebCore::OrderIterator::OrderIterator):
641         (WebCore::OrderIterator::setOrderValues): Use std::move semantics.
642         (WebCore::OrderIterator::first): Use an integer as iterator.
643         (WebCore::OrderIterator::next): Ditto.
644         (WebCore::OrderIterator::reset): Ditto.
645         * rendering/OrderIterator.h: Added.
646         (WebCore::OrderIterator::currentChild):
647         * rendering/RenderFlexibleBox.cpp:
648         (WebCore::RenderFlexibleBox::RenderFlexibleBox):
649         (WebCore::RenderFlexibleBox::layoutBlock):
650         * rendering/RenderFlexibleBox.h:
651         * rendering/RenderGrid.cpp:
652         (WebCore::RenderGrid::RenderGrid):
653         (WebCore::RenderGrid::placeItemsOnGrid):
654         (WebCore::RenderGrid::populateExplicitGridAndOrderIterator):
655         (WebCore::RenderGrid::paintChildren):
656         * rendering/RenderGrid.h:
657
658 2013-10-28  Afonso R. Costa Jr.  <afonso.costa@samsung.com>
659
660         Methods on window.internals shouldn't pass a document.
661         https://bugs.webkit.org/show_bug.cgi?id=107301
662
663         Reviewed by Alexey Proskuryakov.
664
665         Each 'Internals' instance is associated with a 'Document'. So, it
666         is not necessary to pass a document as argument. Only nodesFromRect and
667         layerTreeAsText methods were kept because, in some Layout Tests, the
668         'Document' object is not the same used by Internals::contextDocument.
669
670         * testing/Internals.cpp: Removed 'document' parameter.
671         (WebCore::Internals::animationsAreSuspended):
672         (WebCore::Internals::suspendAnimations):
673         (WebCore::Internals::resumeAnimations):
674         (WebCore::Internals::inspectorHighlightRects):
675         (WebCore::Internals::inspectorHighlightObject):
676         (WebCore::Internals::setScrollViewPosition):
677         (WebCore::Internals::setPagination):
678         (WebCore::Internals::configurationForViewport):
679         (WebCore::Internals::paintControlTints):
680         (WebCore::Internals::setDelegatesScrolling):
681         (WebCore::Internals::touchPositionAdjustedToBestClickableNode):
682         (WebCore::Internals::touchNodeAdjustedToBestClickableNode):
683         (WebCore::Internals::touchPositionAdjustedToBestContextMenuNode):
684         (WebCore::Internals::touchNodeAdjustedToBestContextMenuNode):
685         (WebCore::Internals::bestZoomableAreaForTouchPoint):
686         (WebCore::Internals::lastSpellCheckRequestSequence):
687         (WebCore::Internals::lastSpellCheckProcessedSequence):
688         (WebCore::Internals::wheelEventHandlerCount):
689         (WebCore::Internals::touchEventHandlerCount):
690         (WebCore::Internals::setBatteryStatus):
691         (WebCore::Internals::setNetworkInformation):
692         (WebCore::Internals::setDeviceProximity):
693         (WebCore::Internals::hasSpellingMarker):
694         (WebCore::Internals::hasAutocorrectedMarker):
695         (WebCore::Internals::isOverwriteModeEnabled):
696         (WebCore::Internals::toggleOverwriteModeEnabled):
697         (WebCore::Internals::consoleMessageArgumentCounts):
698         (WebCore::Internals::hasGrammarMarker):
699         (WebCore::Internals::numberOfScrollableAreas):
700         (WebCore::Internals::isPageBoxVisible):
701         (WebCore::Internals::repaintRectsAsText):
702         (WebCore::Internals::scrollingStateTreeAsText):
703         (WebCore::Internals::mainThreadScrollingReasons):
704         (WebCore::Internals::nonFastScrollableRects):
705         (WebCore::Internals::garbageCollectDocumentResources):
706         (WebCore::Internals::insertAuthorCSS):
707         (WebCore::Internals::insertUserCSS):
708         (WebCore::Internals::shortcutIconURLs):
709         (WebCore::Internals::allIconURLs):
710         (WebCore::Internals::setHeaderHeight):
711         (WebCore::Internals::setFooterHeight):
712         (WebCore::Internals::webkitWillEnterFullScreenForElement):
713         (WebCore::Internals::webkitDidEnterFullScreenForElement):
714         (WebCore::Internals::webkitWillExitFullScreenForElement):
715         (WebCore::Internals::webkitDidExitFullScreenForElement):
716         (WebCore::Internals::startTrackingRepaints):
717         (WebCore::Internals::stopTrackingRepaints):
718         (WebCore::Internals::getCurrentCursorInfo):
719         * testing/Internals.h:
720         (WebCore::Internals::setPagination):
721         * testing/Internals.idl:
722
723 2013-10-28  Xabier Rodriguez Calvar  <calvaris@igalia.com>
724
725         Remove HTMLMediaElement.startTime
726         https://bugs.webkit.org/show_bug.cgi?id=123264
727
728         Reviewed by Eric Carlson.
729
730         Patch based on one by: philipj@opera.com
731         Blink review URL: https://codereview.chromium.org/32583003
732
733         startTime has been removed from the HTMLMediaElement and its use
734         in the rest of components.
735
736         * Modules/mediacontrols/mediaControlsApple.js:
737         (Controller.prototype.handleRewindButtonClicked):
738         (Controller.prototype.handleTimelineMouseMove):
739         (Controller.prototype.updateDuration):
740         (Controller.prototype.updateTime): Removed used of startTime().
741         * bindings/gobject/WebKitDOMCustom.cpp:
742         (webkit_dom_html_media_element_get_start_time):
743         * bindings/gobject/WebKitDOMCustom.h:
744         * bindings/gobject/WebKitDOMCustom.symbols: Added phony function.
745         * html/HTMLMediaElement.cpp:
746         (WebCore::HTMLMediaElement::mediaPlayerTimeChanged):
747         (WebCore::HTMLMediaElement::isBlockedOnMediaController): Removed
748         use of startTime()
749         * html/HTMLMediaElement.h:
750         * html/HTMLMediaElement.idl: Removed startTime()
751         * rendering/RenderThemeWinCE.cpp:
752         (WebCore::RenderThemeWinCE::paintSliderThumb): Removed use of
753         startTime()
754
755 2013-10-28  Andreas Kling  <akling@apple.com>
756
757         RenderElement::m_style should be a Ref.
758         <https://webkit.org/b/123401>
759
760         Made RenderElement::m_style a Ref. This codifies the fact that it
761         can never be null after construction.
762
763         Removed a couple of unnecessary null checks that were exposed as
764         compilation failures.
765
766         Reviewed by Antti Koivisto.
767
768 2013-10-28  Bastien Nocera <hadess@hadess.net>
769
770         Name all the GLib timeout sources
771         https://bugs.webkit.org/show_bug.cgi?id=123229
772
773         Reviewed by Anders Carlsson.
774
775         Give a name to GLib timeout sources, this is helpful when
776         profiling WebKitGTK applications.
777
778         No new tests, no change in functionality.
779
780 2013-10-28  Philippe Normand  <pnormand@igalia.com>
781
782         MediaStreamTrackPrivate's m_client uninitialized
783         https://bugs.webkit.org/show_bug.cgi?id=123403
784
785         Reviewed by Eric Carlson.
786
787         No new tests, no change in functionality.
788
789         * platform/mediastream/MediaStreamTrackPrivate.cpp:
790         (WebCore::MediaStreamTrackPrivate::MediaStreamTrackPrivate):
791         Initialize the m_client member variable.
792
793 2013-10-28  Carlos Garcia Campos  <cgarcia@igalia.com>
794
795         Unreviewed. Fix make distcheck.
796
797         * GNUmakefile.am: Add crypto idl files to EXTRA_DIST and remove
798         css/fullscreenQuickTime.css that was removed.
799
800 2013-10-28  Antti Koivisto  <antti@apple.com>
801
802         Prepare simple line layout to support multiple runs per line
803         https://bugs.webkit.org/show_bug.cgi?id=123400
804
805         Reviewed by Andreas Kling.
806
807         Bunch of renaming and some refactoring for future support for text runs.
808
809         SimpleLineLayout::Lines -> SimpleLineLayout::Layout and becomes a class instead of a typedef.
810         SimpleLineLayout::Resolver::Line -> SimpleLineLayout::Resolver::Run
811         SimpleLineLayout::createLines() -> SimpleLineLayout::create()
812         RenderBlockFlow::simpleLines() -> RenderBlockFlow::simpleLineLayout()
813         RenderText::simpleLines() -> RenderText::simpleLineLayout()
814         
815         Added resolver construction functions:
816         
817         SimpleLineLayout::runResolver()
818         SimpleLineLayout::lineResolver()
819
820 2013-10-28  Mario Sanchez Prada  <mario.prada@samsung.com>
821
822         [GTK] Expose title and alternative text for links in image maps
823         https://bugs.webkit.org/show_bug.cgi?id=84045
824
825         Reviewed by Chris Fleizach.
826
827         Change the way we decide when the title attribute should be
828         used for the accessible description, by not relying in the
829         titleTagShouldBeUsedInDescriptionField() helper function but
830         in whether we have found a visible text for it or not.
831
832         This actually mimics what the Mac port does and so makes possible
833         to share both the layout test and its expected results.
834
835         * accessibility/atk/WebKitAccessibleUtil.cpp:
836         (accessibilityDescription): Update the method to determine
837         whether the title attribute should be used for the description.
838
839 2013-10-28  Bastien Nocera <hadess@hadess.net>
840
841         Replace 0 timeouts g_timeout_add() by g_idle_add()
842         https://bugs.webkit.org/show_bug.cgi?id=123260
843
844         Reviewed by Carlos Garcia Campos.
845
846         A zero timeout should be equivalent to using g_idle_add_full(G_PRIORITY_DEFAULT, ...)
847         without the nagging feeling that the wrong API was used.
848
849         No new tests, no change in functionality.
850
851         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp: Use g_idle_add() instead
852         of 0-timer.
853         (WebCore::MediaPlayerPrivateGStreamer::videoChanged):
854         (WebCore::MediaPlayerPrivateGStreamer::audioChanged):
855         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: Ditto.
856         (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
857         (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
858         * platform/gtk/GtkDragAndDropHelper.cpp: Ditto.
859         (WebCore::GtkDragAndDropHelper::handleDragLeave):
860
861 2013-10-28  Zan Dobersek  <zdobersek@igalia.com>
862
863         Re-enable simple line layout for GTK
864         https://bugs.webkit.org/show_bug.cgi?id=123388
865
866         Reviewed by Andreas Kling.
867
868         * rendering/SimpleLineLayout.cpp:
869         (WebCore::SimpleLineLayout::canUseFor): 8-bit TextRun support is now enabled for the GTK port, so the port
870         can use the simple line layout.
871
872 2013-10-27  Andreas Kling  <akling@apple.com>
873
874         Fix 4 asserting SVG tests after r158097.
875
876         RenderElement::setStyle() is, quite surprisingly, a virtual function
877         with a single override in RenderSVGBlock.
878         To match the old behavior, we have to rewrite the display type from
879         any inline type to block instead.
880
881         * rendering/RenderElement.cpp:
882         (WebCore::RenderElement::initializeStyle):
883
884 2013-10-27  Andreas Kling  <akling@apple.com>
885
886         Tone down overzealous assertion from r158097.
887
888         RenderElement::initializeStyle() really only cares that there are no
889         text renderers that we should be calling styleDidChange() on.
890
891         Tweak the code to only check that there are no text children.
892
893         * rendering/RenderElement.cpp:
894         (WebCore::RenderElement::initializeStyle):
895
896 2013-10-27  Antti Koivisto  <antti@apple.com>
897
898         Enable center and right text alignment for simple lines
899         https://bugs.webkit.org/show_bug.cgi?id=123398
900
901         Reviewed by Andreas Kling.
902
903         Support text-align:center and text-align:right on simple line layout path.
904
905         * rendering/SimpleLineLayout.cpp:
906         (WebCore::SimpleLineLayout::canUseFor):
907         
908             text-align:justify is still not supported.
909
910         (WebCore::SimpleLineLayout::computeLineLeft):
911         (WebCore::SimpleLineLayout::createLines):
912         
913             Do a rounding dance that matches the line boxes.
914
915         * rendering/SimpleLineLayout.h:
916         
917             Add left position to lines.
918
919         * rendering/SimpleLineLayoutResolver.h:
920         (WebCore::SimpleLineLayout::Resolver::Line::rect):
921         
922             We now do rounding during layout.
923
924         (WebCore::SimpleLineLayout::Resolver::Line::baseline):
925
926 2013-10-27  Andreas Kling  <akling@apple.com>
927
928         Renderers should receive their style at construction.
929         <https://webkit.org/b/123396>
930
931         Pass the RenderStyle to all non-text renderer constructors.
932         After construction, initializeStyle() must be called (as a stopgap
933         measure) until we are able to do style-derived initialization
934         without virtual function calls.
935
936         With this change, RenderElement::m_style is never null. Subsequent
937         patches will add enforcement for this and also make style() return
938         a RenderStyle&.
939
940         I'm adding three FIXME's in this patch:
941
942             - createRendererIfNeeded() calls AnimationController to set up
943               the initial style manually instead of asking RenderElement's
944               setAnimatedStyle() to do it. This can probably be done in a
945               nicer way, but it's not clear yet how.
946
947             - ImageContentData::createRenderer() does a bit of unnecessary
948               work. This should be easy to clean up but got too distracting
949               to be part of this patch.
950
951             - Document::createRenderTree() creates the RenderView with an
952               initial dummy RenderStyle. I've done this because resolving
953               the document style assumes we already have a RenderView.
954
955         For styleWillChange() implementations to detect that they are
956         reacting to the initial style, I've added a hasInitializedStyle()
957         function on RenderElement. This will return false until you've
958         called initializeStyle() on the renderer. This should go away
959         along with initializeStyle() eventually.
960
961         Reviewed by Antti Koivisto.
962
963 2013-10-26  Tim Horton  <timothy_horton@apple.com>
964
965         [mac] Remove WebTiledLayer
966         https://bugs.webkit.org/show_bug.cgi?id=123395
967
968         Reviewed by Anders Carlsson.
969
970         Mac doesn't use CATiledLayer at all anymore. We have to keep
971         LayerTypeTiledLayer around for Windows, for now, but we can
972         get rid of WebTiledLayer and some related Mac-specific code.
973
974         No new tests, just removing dead code.
975
976         * WebCore.xcodeproj/project.pbxproj:
977         Remove WebTiledLayer.*
978
979         * platform/graphics/ca/PlatformCALayer.h:
980         * platform/graphics/ca/mac/PlatformCALayerMac.h:
981         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
982         (PlatformCALayerMac::PlatformCALayerMac):
983         Remove synchronouslyDisplayTilesInRect, which was only used for WebTiledLayer on Mac.
984         Remove WebTiledLayer instantiation and setup code.
985
986         * platform/graphics/mac/WebTiledLayer.h: Removed.
987         * platform/graphics/mac/WebTiledLayer.mm: Removed.
988
989 2013-10-26  Andreas Kling  <akling@apple.com>
990
991         CTTE: RenderImageResourceStyleImage always has a StyleImage.
992         <https://webkit.org/b/123390>
993
994         Codify the fact that RenderImageResourceStyleImage always wraps an
995         existing StyleImage object.
996
997         Reviewed by Antti Koivisto.
998
999 2013-10-26  Antti Koivisto  <antti@apple.com>
1000
1001         Revert some accidental changes.
1002
1003         * css/CSSFontFaceSource.cpp:
1004         (WebCore::CSSFontFaceSource::getFontData):
1005         * css/CSSFontSelector.cpp:
1006         * css/CSSFontSelector.h:
1007
1008 2013-10-26  Mark Lam  <mark.lam@apple.com>
1009
1010         Gardening: fixed broken build.
1011         https://bugs.webkit.org/show_bug.cgi?id=123354.
1012
1013         * css/CSSFontSelector.h:
1014
1015 2013-10-26  Antti Koivisto  <antti@apple.com>
1016
1017         fast/frames/seamless/seamless-nested-crash.html asserts on wk2 only
1018         https://bugs.webkit.org/show_bug.cgi?id=123354
1019
1020         Reviewed by Andreas Kling.
1021
1022         * rendering/SimpleLineLayout.cpp:
1023         (WebCore::SimpleLineLayout::canUseFor):
1024         
1025             Don't enable simple line layout if the primary font is loading. The code expects
1026             to use the primary font metrics for all lines but those won't match the fallbacks
1027             when font is not loaded.
1028
1029 2013-10-26  Carlos Garcia Campos  <cgarcia@igalia.com>
1030
1031         [GTK] Deprecate public dispatch_event method in objects implementing EventTarget interface
1032         https://bugs.webkit.org/show_bug.cgi?id=123261
1033
1034         Reviewed by Gustavo Noronha Silva.
1035
1036         The interface function should be used instead.
1037
1038         * bindings/scripts/CodeGeneratorGObject.pm:
1039         (GetFunctionDeprecationInformation): Helper function to return the
1040         version when the function was deprecated and the function
1041         replacing the deprecated one.
1042         (GenerateFunction): Check if the function is deprecated to mark it
1043         as such in the header and API docs.
1044         * bindings/scripts/gobject-generate-headers.pl: Replace the unused
1045         WEBKIT_OBSOLETE_API macro with new macros to mark function as
1046         deprecated, using the glib macros so that we don't need checks for
1047         the platform.
1048         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
1049         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
1050         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
1051         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.h:
1052         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
1053         * bindings/scripts/test/GObject/WebKitDOMTestException.h:
1054         * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
1055         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
1056         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h:
1057         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:
1058         * bindings/scripts/test/GObject/WebKitDOMattribute.h:
1059
1060 2013-10-25  Mark Lam  <mark.lam@apple.com>
1061
1062         DatabaseManager's ProposedDatabases need to be thread-safe.
1063         https://bugs.webkit.org/show_bug.cgi?id=123313.
1064
1065         Reviewed by Geoffrey Garen.
1066
1067         No new tests.
1068
1069         * Modules/webdatabase/DatabaseManager.cpp:
1070         (WebCore::DatabaseManager::DatabaseManager):
1071         (WebCore::DatabaseManager::existingDatabaseContextFor):
1072         (WebCore::DatabaseManager::registerDatabaseContext):
1073         (WebCore::DatabaseManager::unregisterDatabaseContext):
1074         (WebCore::DatabaseManager::didConstructDatabaseContext):
1075         (WebCore::DatabaseManager::didDestructDatabaseContext):
1076         (WebCore::DatabaseManager::openDatabaseBackend):
1077         (WebCore::DatabaseManager::addProposedDatabase):
1078         (WebCore::DatabaseManager::removeProposedDatabase):
1079         (WebCore::DatabaseManager::fullPathForDatabase):
1080         (WebCore::DatabaseManager::detailsForNameAndOrigin):
1081         * Modules/webdatabase/DatabaseManager.h:
1082
1083 2013-10-25  Joseph Pecoraro  <pecoraro@apple.com>
1084
1085         Upstream ENABLE(REMOTE_INSPECTOR) and enable on iOS and Mac
1086         https://bugs.webkit.org/show_bug.cgi?id=123111
1087
1088         Reviewed by Timothy Hatcher.
1089
1090         * Configurations/FeatureDefines.xcconfig:
1091         * WebCore.exp.in:
1092
1093 2013-10-25  Hans Muller  <hmuller@adobe.com>
1094
1095         [CSS Shapes] CORS-enabled fetch for shape image values
1096         https://bugs.webkit.org/show_bug.cgi?id=123114
1097
1098         Reviewed by Andreas Kling.
1099
1100         Access to shape images is now controlled by CORS CSS shape per
1101         http://dev.w3.org/csswg/css-shapes/#shape-outside-property.
1102         Previously shape images had to be same-origin.
1103
1104         Shape image URL access is defined by the same logic that defines
1105         canvas tainting: same-origin and data URLs are allowed and images
1106         with a "Access-Control-Allow-Origin:" header that's either "*" or
1107         that matches the document's origin.
1108
1109         A PotentiallyCrossOriginEnabled RequestOriginPolicy was added to
1110         ResourceLoaderOptions, to indicate that a "potentially CORS-enabled fetch"
1111         was to be undertaken. The CSSImageValue::cachedImage() method handles this
1112         option by effectively setting the "Origin:" request header (see
1113         updateRequestForAccessControl() in CrossOriginAccessControl.cpp).
1114         StyleResolver::loadPendingShapeImage() uses the new ResourceLoaderOption.
1115
1116         The static ShapeInsideInfo and ShapeOutsideInfo isEnabledFor() method
1117         now performs the CORS check for image valued shapes. The private
1118         isOriginClean() method from CanvasRenderingContext2D has been moved to
1119         the CachedImage class so that it can be shared by the Canvas and Shape
1120         implementations. It checks the response headers per the CORS spec.
1121
1122         Test: http/tests/security/shape-image-cors.html
1123
1124         * css/CSSImageValue.cpp:
1125         (WebCore::CSSImageValue::cachedImage): Handle the new ResourceLoaderOption.
1126         * css/StyleResolver.cpp:
1127         (WebCore::StyleResolver::loadPendingShapeImage): Set the new ResourceLoaderOption.
1128         * html/canvas/CanvasRenderingContext2D.cpp:
1129         (WebCore::CanvasRenderingContext2D::createPattern): Use the CachedImage::isOriginClean().
1130         * loader/ResourceLoaderOptions.h: Added PotentiallyCrossOriginEnabled to RequestOriginPolicy.
1131         * loader/cache/CachedImage.cpp:
1132         (WebCore::CachedImage::isOriginClean): Migrated from CanvasRenderingContext2D.
1133         * loader/cache/CachedImage.h:
1134         * rendering/shapes/ShapeInfo.cpp:
1135         (WebCore::::checkImageOrigin): Do the CORS check and log an error message if neccessary.
1136         * rendering/shapes/ShapeInfo.h:
1137         * rendering/shapes/ShapeInsideInfo.cpp:
1138         (WebCore::ShapeInsideInfo::isEnabledFor): Call checkImageOrigin() for images.
1139         * rendering/shapes/ShapeOutsideInfo.cpp:
1140         (WebCore::ShapeOutsideInfo::isEnabledFor): Ditto.
1141
1142 2013-10-25  Jer Noble  <jer.noble@apple.com>
1143
1144         [MSE] Fix runtime errors caused by mediasource IDL attributes.
1145         https://bugs.webkit.org/show_bug.cgi?id=123352
1146
1147         Reviewed by Eric Carlson.
1148
1149         Due to http://webkit.org/b/123178, MediaSource classes must add a GenerateIsReachable
1150         (and also a JSGenerateToJSObject) attribute to avoid runtime asserts and crashes.
1151
1152         * Modules/mediasource/MediaSource.idl:
1153         * Modules/mediasource/SourceBuffer.idl:
1154         * Modules/mediasource/SourceBufferList.idl:
1155         * Modules/mediasource/WebKitMediaSource.idl:
1156         * Modules/mediasource/WebKitSourceBufferList.idl:
1157
1158 2013-10-25  Jacky Jiang  <zhajiang@blackberry.com>
1159
1160         [BlackBerry] Browser crashed at PlatformGraphicsContext::addDrawLineForText() when trying to upload a video to youtube
1161         https://bugs.webkit.org/show_bug.cgi?id=123349
1162
1163         Reviewed by George Staikos.
1164         Internally reviewed by George Staikos, Konrad Piascik, Eli Fidler and Arvid Nilsson.
1165
1166         Browser crashed when dereferencing null PlatformGraphicsContext*.
1167         In FrameView::paintControlTints(), we intentionally constructed GraphicsContext
1168         with null PlatformGraphicsContext* and disabled painting by doing
1169         context.setUpdatingControlTints(true). So we should not go further in
1170         GraphicsContext::drawLineForText() if painting is disabled.
1171         Check paintingDisabled() for the other functions in PathBlackBerry.cpp
1172         as well; otherwise, it is likely we will crash at those places.
1173
1174         * platform/graphics/blackberry/PathBlackBerry.cpp:
1175         (WebCore::GraphicsContext::fillPath):
1176         (WebCore::GraphicsContext::strokePath):
1177         (WebCore::GraphicsContext::drawLine):
1178         (WebCore::GraphicsContext::drawLineForDocumentMarker):
1179         (WebCore::GraphicsContext::drawLineForText):
1180         (WebCore::GraphicsContext::clip):
1181         (WebCore::GraphicsContext::clipPath):
1182         (WebCore::GraphicsContext::canvasClip):
1183         (WebCore::GraphicsContext::clipOut):
1184
1185 2013-10-25  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1186
1187         Adding platform implementation of MediaStreamTrack
1188         https://bugs.webkit.org/show_bug.cgi?id=123301
1189
1190         Reviewed by Eric Carlson.
1191
1192         No new tests needed.
1193
1194         * CMakeLists.txt:
1195         * Modules/mediastream/AudioStreamTrack.cpp:
1196         (WebCore::AudioStreamTrack::create): Create method now receives a MediaStreamTrackPrivate as parameter.
1197
1198         (WebCore::AudioStreamTrack::AudioStreamTrack):
1199         * Modules/mediastream/AudioStreamTrack.h:
1200         * Modules/mediastream/MediaStream.cpp:
1201         (WebCore::MediaStream::MediaStream): Constructor now iterates through a set of MediaStreamTrackPrivate
1202         instances to create each MediaStreamTrack of MediaStream.
1203
1204         (WebCore::MediaStream::addRemoteSource): Calling AudioStreamTrack and VideoStreamTrack with
1205         MediaStreamTrackPrivate as parameter.
1206
1207         * Modules/mediastream/MediaStreamTrack.cpp:
1208         (WebCore::MediaStreamTrack::MediaStreamTrack): Constructor now receives a MediaStreamTrackPrivate, instead of a
1209         MediaStreamSource.
1210
1211         (WebCore::MediaStreamTrack::~MediaStreamTrack):
1212         (WebCore::MediaStreamTrack::kind): Calling method from MediaStreamTrackPrivate.
1213
1214         (WebCore::MediaStreamTrack::setSource): Ditto.
1215
1216         (WebCore::MediaStreamTrack::id): Ditto.
1217
1218         (WebCore::MediaStreamTrack::label): Ditto.
1219
1220         (WebCore::MediaStreamTrack::enabled): Ditto.
1221
1222         (WebCore::MediaStreamTrack::setEnabled): Ditto.
1223
1224         (WebCore::MediaStreamTrack::muted): Ditto.
1225
1226         (WebCore::MediaStreamTrack::readonly): Ditto.
1227
1228         (WebCore::MediaStreamTrack::remote): Ditto.
1229
1230         (WebCore::MediaStreamTrack::readyState): Ditto.
1231
1232         (WebCore::MediaStreamTrack::states):
1233         (WebCore::MediaStreamTrack::capabilities):
1234         (WebCore::MediaStreamTrack::clone):
1235         (WebCore::MediaStreamTrack::stopProducingData):
1236         (WebCore::MediaStreamTrack::ended): Ditto.
1237
1238         (WebCore::MediaStreamTrack::sourceStateChanged): Ditto.
1239
1240         (WebCore::MediaStreamTrack::sourceMutedChanged): Ditto.
1241
1242         (WebCore::MediaStreamTrack::sourceEnabledChanged): Ditto.
1243         (WebCore::MediaStreamTrack::configureTrackRendering):
1244         (WebCore::MediaStreamTrack::stopped): Ditto.
1245
1246         (WebCore::MediaStreamTrack::trackDidEnd): Setting Ended ready state in MediaStreamTrackPrivate.
1247
1248         (WebCore::MediaStreamTrack::trackReadyStateChanged): Dispatches Live or Ended event.
1249
1250         (WebCore::MediaStreamTrack::trackMutedChanged): Dispatches Muted event.
1251
1252         * Modules/mediastream/MediaStreamTrack.h: Now inheriting from MediaStreamTrackPrivateClient.
1253
1254         (WebCore::MediaStreamTrack::source): Calling method from MediaStreamTrackPrivate.
1255         (WebCore::MediaStreamTrack::privateTrack):
1256         * Modules/mediastream/VideoStreamTrack.cpp:
1257         (WebCore::VideoStreamTrack::create):
1258         (WebCore::VideoStreamTrack::VideoStreamTrack): Create method now receives a MediaStreamTrackPrivate as parameter.
1259         * Modules/mediastream/VideoStreamTrack.h:
1260         * platform/mediastream/MediaStreamDescriptor.cpp:
1261         (WebCore::MediaStreamDescriptor::MediaStreamDescriptor): Stores the private tracks in a Vector (property of
1262         MediaStreamDescriptor class).
1263
1264         (WebCore::MediaStreamDescriptor::addTrack): Adds a private track to the tracks' Vector
1265
1266         (WebCore::MediaStreamDescriptor::removeTrack): Removes a private track from the tracks' Vector
1267
1268         * platform/mediastream/MediaStreamDescriptor.h:
1269         (WebCore::MediaStreamDescriptor::numberOfAudioSources): Renamed from numberOfAudioStreams.
1270
1271         (WebCore::MediaStreamDescriptor::audioSources): Renamed from audioStreams.
1272
1273         (WebCore::MediaStreamDescriptor::numberOfVideoSources): Renamed from numberOfVideoStreams.
1274
1275         (WebCore::MediaStreamDescriptor::videoSources): Renamed from videoStreams.
1276
1277         (WebCore::MediaStreamDescriptor::numberOfAudioTracks): Returns the number of audio tracks this MediaStreamDescriptor
1278         has.
1279
1280         (WebCore::MediaStreamDescriptor::audioTracks): Returns a audio track, given an index
1281
1282         (WebCore::MediaStreamDescriptor::numberOfVideoTracks): Returns the number of video tracks this MediaStreamDescriptor
1283         has.
1284         (WebCore::MediaStreamDescriptor::videoTracks): Returns a video track, given an index
1285         * platform/mediastream/MediaStreamTrackPrivate.cpp: Added.
1286         * platform/mediastream/MediaStreamTrackPrivate.h: Added.
1287
1288 2013-10-25  Zoltan Horvath  <zoltan@webkit.org>
1289
1290         [CSS Regions][CSS Shapes] Update updateShapeAndSegmentsForCurrentLineInFlowThread to deal better with multiple regions
1291         <https://webkit.org/b/123210>
1292
1293         Reviewed by David Hyatt.
1294
1295         I simplified the determination of the next region part of updateShapeAndSegmentsForCurrentLineInFlowThread's implementation
1296         in order to make the code more straightforward. I also tried to avoid using regionAtBlockOffset(...) function where it's possible,
1297         since it's not always that reliable, what I'll will report in a separate bug.
1298
1299         No new tests, covered by existing tests.
1300
1301         * rendering/RenderBlockLineLayout.cpp:
1302         (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLineInFlowThread):
1303
1304 2013-10-25  Zoltan Horvath  <zoltan@webkit.org>
1305
1306         [CSS Regions][CSS Shapes] Update updateShapeAndSegmentsForCurrentLineInFlowThread to deal better with the first lines
1307         <https://bugs.webkit.org/show_bug.cgi?id=123275>
1308
1309         Reviewed by David Hyatt.
1310
1311         We have a complex condition in updateShapeAndSegmentsForCurrentLineInFlowThread, which is
1312         adjusting the first line to the shape's top. This patch adds two boolean to make that clear.
1313
1314         No new tests, no behavior change.
1315
1316         * rendering/RenderBlockLineLayout.cpp:
1317         (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLineInFlowThread):
1318
1319 2013-10-25  Antti Koivisto  <antti@apple.com>
1320
1321         Faster way for simple line layout to check if text has fallback fonts
1322         https://bugs.webkit.org/show_bug.cgi?id=123342
1323
1324         Reviewed by Andreas Kling.
1325         
1326         Don't use RenderText::knownToHaveNoOverflowAndNoFallbackFonts as it is slow.
1327
1328         Simple text code path test already guarantees there is no overflow. Test for fallback
1329         fonts explicitly.
1330
1331         * platform/graphics/SimpleFontData.h:
1332         
1333             Make FINAL.
1334
1335         * rendering/RenderText.cpp:
1336         * rendering/RenderText.h:
1337         
1338             Remove knownToHaveNoOverflowAndNoFallbackFonts() as it has no clients.
1339
1340         * rendering/SimpleLineLayout.cpp:
1341         (WebCore::SimpleLineLayout::canUseFor):
1342         
1343             Check if all characters can be found from the primary font.
1344
1345 2013-10-25  Andreas Kling  <akling@apple.com>
1346
1347         SVGResourcesCache::clientDestroyed() should take a RenderElement&.
1348         <https://webkit.org/b/123339>
1349
1350         This function is always called with an object, and that object
1351         is guaranteed to never be a text renderer.
1352
1353         Reviewed by Antti Koivisto.
1354
1355 2013-10-25  Andreas Kling  <akling@apple.com>
1356
1357         SVGResourcesCache::clientLayoutChanged() should take a RenderElement&.
1358         <https://webkit.org/b/123336>
1359
1360         This function is always called with an object, and that object
1361         is guaranteed to never be a text renderer.
1362
1363         Reviewed by Antti Koivisto.
1364
1365 2013-10-25  Andreas Kling  <akling@apple.com>
1366
1367         SVGResourcesCache::clientStyleChanged() should take a RenderElement&.
1368         <https://webkit.org/b/123335>
1369
1370         This function is always called with an object, and that object
1371         is guaranteed to never be a text renderer.
1372
1373         Reviewed by Antti Koivisto.
1374
1375 2013-10-25  Andreas Kling  <akling@apple.com>
1376
1377         SVG: postApplyResource() should take a RenderElement&.
1378         <https://webkit.org/b/123334>
1379
1380         This function is always called with an object, and that object
1381         is guaranteed to never be a text renderer.
1382
1383         Reviewed by Antti Koivisto.
1384
1385 2013-10-25  Antti Koivisto  <antti@apple.com>
1386
1387         REGRESSION(r157950): It made many tests assert on Windows, EFL, GTK
1388         https://bugs.webkit.org/show_bug.cgi?id=123309
1389
1390         Reviewed by Andreas Kling.
1391
1392         Disable simple line layout on non-Mac plaforms for now.
1393
1394         * rendering/SimpleLineLayout.cpp:
1395         (WebCore::SimpleLineLayout::canUseFor):
1396
1397 2013-10-24  Andreas Kling  <akling@apple.com>
1398
1399         SVG: applyResource() should take a RenderElement&.
1400         <https://webkit.org/b/123286>
1401
1402         This function is always called with an object, and that object
1403         is guaranteed to never be a text renderer.
1404
1405         Reviewed by Antti Koivisto.
1406
1407 2013-10-25  Andreas Kling  <akling@apple.com>
1408
1409         RenderElement::styleWillChange() should pass newStyle as reference.
1410         <https://webkit.org/b/123332>
1411
1412         When styleWillChange() is called, there is always a new style getting
1413         set so there's no need to handle the null style case.
1414         This flushed out a couple of unnecessary checks.
1415
1416         Reviewed by Antti Koivisto.
1417
1418 2013-10-25  peavo@outlook.com  <peavo@outlook.com>
1419
1420         [WinCairo] Compile fixes.
1421         https://bugs.webkit.org/show_bug.cgi?id=123269
1422
1423         Reviewed by Csaba Osztrogon√°c.
1424
1425         * platform/graphics/win/ImageCairoWin.cpp: Added new parameter to BitmapImage::draw() calls.
1426         (WebCore::BitmapImage::getHBITMAPOfSize):
1427         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
1428
1429 2013-10-25  Sergio Villar Senin  <svillar@igalia.com>
1430
1431         Use a Vector instead of HashSet to computed the orderValues in RenderFlexibleBox
1432         https://bugs.webkit.org/show_bug.cgi?id=118620
1433
1434         Reviewed by Antti Koivisto.
1435
1436         Turns out that order is extremelly uncommon so using a Vector is
1437         much less expensive. This also special-cases the much common case
1438         of only having order of value 0 by using Vectors with just one
1439         preallocated member.
1440
1441         Also added the performance test that shows a ~1% win when using a
1442         vector instead of the HashSet.
1443
1444         * rendering/RenderFlexibleBox.cpp:
1445         (WebCore::RenderFlexibleBox::OrderIterator::setOrderValues):
1446         (WebCore::RenderFlexibleBox::layoutBlock):
1447         (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
1448         * rendering/RenderFlexibleBox.h:
1449
1450 2013-10-25  Sergio Villar Senin  <svillar@igalia.com>
1451
1452         Non-SVG build broken after r157950
1453         https://bugs.webkit.org/show_bug.cgi?id=123328
1454
1455         Reviewed by Xan Lopez.
1456
1457         The isSVGInlineTest() check should be done only if SVG is enabled.
1458
1459         * rendering/SimpleLineLayout.cpp:
1460         (WebCore::SimpleLineLayout::canUseFor):
1461
1462 2013-10-24  Jer Noble  <jer.noble@apple.com>
1463
1464         [Mac] Add helper methods to convert CMTime <--> MediaTime
1465         https://bugs.webkit.org/show_bug.cgi?id=123285
1466
1467         Reviewed by Eric Carlson.
1468
1469         Add utility methods to convert between CMTime (a rational time class) and MediaTime.
1470         Once there, PlatformClockCM can now vend and accept MediaTimes for currentTime.
1471
1472         * platform/mac/MediaTimeMac.h:
1473         * platform/mac/MediaTimeMac.cpp:
1474         (WebCore::toMediaTime): Added conversion utility method.
1475         (WebCore::toCMTime): Ditto.
1476
1477         * platform/mac/PlatformClockCM.h:
1478         * platform/mac/PlatformClockCM.mm:
1479         (PlatformClockCM::setCurrentMediaTime): Added.
1480         (PlatformClockCM::currentMediaTime): Added.
1481
1482         * WebCore.xcodeproj/project.pbxproj: Add new files to project.
1483
1484 2013-10-24  Mark Rowe  <mrowe@apple.com>
1485
1486         Remove references to OS X 10.7 from Xcode configuration settings.
1487
1488         Now that we're not building for OS X 10.7 they're no longer needed.
1489
1490         Reviewed by Anders Carlsson.
1491
1492
1493         * Configurations/Base.xcconfig:
1494         * Configurations/DebugRelease.xcconfig:
1495         * Configurations/FeatureDefines.xcconfig:
1496         * Configurations/Version.xcconfig:
1497
1498 2013-10-24  Antti Koivisto  <antti@apple.com>
1499
1500         Cache line layout path
1501         https://bugs.webkit.org/show_bug.cgi?id=123298
1502
1503         Reviewed by Sam Weinig.
1504         
1505         Determining the path can be non-trivial. Avoid computing it repeatedly on relayouts.
1506
1507         * rendering/RenderBlock.cpp:
1508         (WebCore::RenderBlock::RenderBlock):
1509         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
1510         (WebCore::RenderBlock::invalidateLineLayoutPath):
1511         (WebCore::RenderBlock::removeChild):
1512         
1513             Invalidate the path when children change.
1514
1515         * rendering/RenderBlock.h:
1516         * rendering/RenderBlockFlow.cpp:
1517         (WebCore::RenderBlockFlow::layoutInlineChildren):
1518         (WebCore::RenderBlockFlow::styleDidChange):
1519         
1520             Invalidate the path when style changes.
1521
1522         (WebCore::RenderBlockFlow::deleteLineBoxesBeforeSimpleLineLayout):
1523         (WebCore::RenderBlockFlow::ensureLineBoxes):
1524         * rendering/RenderText.cpp:
1525         (WebCore::RenderText::setText):
1526         
1527             Invalidate the path when text changes.
1528
1529 2013-10-24  Mark Rowe  <mrowe@apple.com>
1530
1531         <rdar://problem/15312643> Prepare for the mysterious future.
1532
1533         Reviewed by David Kilzer.
1534
1535
1536         * Configurations/Base.xcconfig:
1537         * Configurations/DebugRelease.xcconfig:
1538         * Configurations/FeatureDefines.xcconfig:
1539         * Configurations/Version.xcconfig:
1540
1541 2013-10-24  Andreas Kling  <akling@apple.com>
1542
1543         DocumentLoader::cachedResourceLoader() should return a reference.
1544         <https://webkit.org/b/123303>
1545
1546         ..and while we're at it, make DocumentLoader::m_cachedResourceLoader
1547         a Ref, and have CachedResourceLoader::create return a PassRef.
1548
1549         Reviewed by Sam Weinig.
1550
1551 2013-10-24  Anders Carlsson  <andersca@apple.com>
1552
1553         Stop bringing in the std namespace
1554         https://bugs.webkit.org/show_bug.cgi?id=123273
1555
1556         Reviewed by Andreas Kling.
1557
1558         * Modules/webaudio/AudioBufferSourceNode.cpp:
1559         (WebCore::AudioBufferSourceNode::renderFromBuffer):
1560         (WebCore::AudioBufferSourceNode::startGrain):
1561         (WebCore::AudioBufferSourceNode::totalPitchRate):
1562         * Modules/webaudio/AudioNodeInput.cpp:
1563         (WebCore::AudioNodeInput::numberOfChannels):
1564         * Modules/webaudio/AudioParamTimeline.cpp:
1565         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
1566         * Modules/webaudio/AudioScheduledSourceNode.cpp:
1567         (WebCore::AudioScheduledSourceNode::updateSchedulingInfo):
1568         (WebCore::AudioScheduledSourceNode::stop):
1569         * Modules/webaudio/AudioSummingJunction.cpp:
1570         * Modules/webaudio/DelayDSPKernel.cpp:
1571         (WebCore::DelayDSPKernel::process):
1572         * Modules/webaudio/OfflineAudioDestinationNode.cpp:
1573         (WebCore::OfflineAudioDestinationNode::offlineRender):
1574         * Modules/webaudio/OscillatorNode.cpp:
1575         * Modules/webaudio/PannerNode.cpp:
1576         (WebCore::PannerNode::dopplerRate):
1577         * Modules/webaudio/WaveShaperDSPKernel.cpp:
1578         (WebCore::WaveShaperDSPKernel::processCurve):
1579         * Modules/webdatabase/DatabaseTracker.cpp:
1580         (WebCore::DatabaseTracker::hasAdequateQuotaForOrigin):
1581         * Modules/websockets/WebSocket.cpp:
1582         (WebCore::saturateAdd):
1583         * Modules/websockets/WebSocketChannel.cpp:
1584         * Modules/websockets/WebSocketFrame.cpp:
1585         (WebCore::WebSocketFrame::parseFrame):
1586         * accessibility/AccessibilityARIAGrid.cpp:
1587         * accessibility/AccessibilityARIAGridCell.cpp:
1588         * accessibility/AccessibilityARIAGridRow.cpp:
1589         * accessibility/AccessibilityList.cpp:
1590         * accessibility/AccessibilityListBox.cpp:
1591         * accessibility/AccessibilityListBoxOption.cpp:
1592         * accessibility/AccessibilityNodeObject.cpp:
1593         * accessibility/AccessibilityObject.cpp:
1594         * accessibility/AccessibilityRenderObject.cpp:
1595         * accessibility/AccessibilityTable.cpp:
1596         (WebCore::AccessibilityTable::addChildren):
1597         * accessibility/AccessibilityTableCell.cpp:
1598         * accessibility/AccessibilityTableColumn.cpp:
1599         * accessibility/AccessibilityTableHeaderContainer.cpp:
1600         * accessibility/AccessibilityTableRow.cpp:
1601         * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
1602         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
1603         (-[WebAccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
1604         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
1605         (WebCore::JSCSSStyleDeclaration::getOwnPropertyNames):
1606         * bindings/js/JSGeolocationCustom.cpp:
1607         (WebCore::setTimeout):
1608         (WebCore::setMaximumAge):
1609         * bindings/js/ScriptController.cpp:
1610         * bindings/js/SerializedScriptValue.cpp:
1611         (WebCore::writeLittleEndian):
1612         (WebCore::CloneSerializer::write):
1613         (WebCore::CloneDeserializer::deserialize):
1614         (WebCore::CloneDeserializer::readString):
1615         * css/CSSComputedStyleDeclaration.cpp:
1616         (WebCore::ComputedStyleExtractor::propertyValue):
1617         * css/CSSFontSelector.cpp:
1618         (WebCore::CSSFontSelector::getFontFace):
1619         * css/CSSGradientValue.cpp:
1620         (WebCore::CSSRadialGradientValue::createGradient):
1621         * css/CSSParser.cpp:
1622         (WebCore::CSSParser::parseValue):
1623         (WebCore::CSSParser::parseColorParameters):
1624         (WebCore::CSSParser::parseHSLParameters):
1625         * css/CSSReflectValue.cpp:
1626         * css/DeprecatedStyleBuilder.cpp:
1627         (WebCore::ApplyPropertyFontSize::applyValue):
1628         * css/PropertySetCSSStyleDeclaration.cpp:
1629         * css/SVGCSSParser.cpp:
1630         * css/StylePropertySet.cpp:
1631         (WebCore::StylePropertySet::getLayeredShorthandValue):
1632         * css/StyleResolver.cpp:
1633         (WebCore::StyleResolver::viewportPercentageValue):
1634         * dom/CharacterData.cpp:
1635         (WebCore::CharacterData::parserAppendData):
1636         * dom/ContainerNode.cpp:
1637         * dom/Document.cpp:
1638         (WebCore::Document::minimumLayoutDelay):
1639         * dom/Node.cpp:
1640         (WebCore::Node::compareDocumentPosition):
1641         * dom/Range.cpp:
1642         (WebCore::Range::toString):
1643         (WebCore::Range::textRects):
1644         (WebCore::Range::textQuads):
1645         * dom/ScriptedAnimationController.cpp:
1646         (WebCore::ScriptedAnimationController::scheduleAnimation):
1647         * dom/StyledElement.cpp:
1648         (WebCore::StyledElement::makePresentationAttributeCacheKey):
1649         * dom/Text.cpp:
1650         * dom/ViewportArguments.cpp:
1651         (WebCore::clampLengthValue):
1652         (WebCore::clampScaleValue):
1653         (WebCore::ViewportArguments::resolve):
1654         (WebCore::computeMinimumScaleFactorForContentContained):
1655         (WebCore::restrictMinimumScaleFactorToViewportSize):
1656         * editing/AlternativeTextController.cpp:
1657         * editing/ApplyStyleCommand.cpp:
1658         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
1659         * editing/CompositeEditCommand.cpp:
1660         (WebCore::CompositeEditCommand::deleteInsignificantText):
1661         * editing/Editor.cpp:
1662         (WebCore::Editor::setComposition):
1663         (WebCore::Editor::compositionRange):
1664         * editing/EditorCommand.cpp:
1665         (WebCore::verticalScrollDistance):
1666         * editing/TextIterator.cpp:
1667         (WebCore::TextIterator::handleTextNode):
1668         (WebCore::TextIterator::handleTextBox):
1669         (WebCore::CharacterIterator::string):
1670         (WebCore::SearchBuffer::SearchBuffer):
1671         (WebCore::SearchBuffer::append):
1672         (WebCore::SearchBuffer::prependContext):
1673         (WebCore::SearchBuffer::search):
1674         * editing/VisibleUnits.cpp:
1675         (WebCore::startOfParagraph):
1676         * editing/htmlediting.cpp:
1677         * editing/markup.cpp:
1678         * fileapi/FileReaderLoader.cpp:
1679         (WebCore::FileReaderLoader::didReceiveResponse):
1680         (WebCore::FileReaderLoader::didReceiveData):
1681         * history/BackForwardList.cpp:
1682         (WebCore::BackForwardList::backListWithLimit):
1683         (WebCore::BackForwardList::forwardListWithLimit):
1684         * history/PageCache.cpp:
1685         (WebCore::PageCache::setCapacity):
1686         * html/BaseDateAndTimeInputType.cpp:
1687         * html/FTPDirectoryDocument.cpp:
1688         * html/HTMLAreaElement.cpp:
1689         (WebCore::HTMLAreaElement::getRegion):
1690         * html/HTMLElement.cpp:
1691         (WebCore::HTMLElement::parseAttribute):
1692         (WebCore::parseColorStringWithCrazyLegacyRules):
1693         * html/HTMLFormControlElement.cpp:
1694         * html/HTMLFormElement.cpp:
1695         (WebCore::HTMLFormElement::getTextFieldValues):
1696         * html/HTMLImageElement.cpp:
1697         * html/HTMLInputElement.cpp:
1698         * html/HTMLMapElement.cpp:
1699         * html/HTMLMediaElement.cpp:
1700         (WebCore::HTMLMediaElement::HTMLMediaElement):
1701         (WebCore::HTMLMediaElement::updateActiveTextTrackCues):
1702         (WebCore::HTMLMediaElement::textTrackAddCue):
1703         (WebCore::HTMLMediaElement::textTrackRemoveCue):
1704         (WebCore::HTMLMediaElement::rewind):
1705         (WebCore::HTMLMediaElement::seek):
1706         (WebCore::HTMLMediaElement::duration):
1707         * html/HTMLSelectElement.cpp:
1708         (WebCore::HTMLSelectElement::parseAttribute):
1709         (WebCore::HTMLSelectElement::updateListBoxSelection):
1710         * html/HTMLSourceElement.cpp:
1711         * html/HTMLTableCellElement.cpp:
1712         (WebCore::HTMLTableCellElement::colSpan):
1713         (WebCore::HTMLTableCellElement::rowSpan):
1714         * html/HTMLTableElement.cpp:
1715         (WebCore::HTMLTableElement::parseAttribute):
1716         * html/HTMLTextFormControlElement.cpp:
1717         (WebCore::HTMLTextFormControlElement::setSelectionStart):
1718         (WebCore::HTMLTextFormControlElement::setSelectionEnd):
1719         (WebCore::HTMLTextFormControlElement::select):
1720         (WebCore::HTMLTextFormControlElement::setSelectionRange):
1721         * html/HTMLTrackElement.cpp:
1722         * html/ImageDocument.cpp:
1723         (WebCore::ImageDocument::scale):
1724         * html/InputType.cpp:
1725         (WebCore::InputType::valueAsDouble):
1726         * html/MediaController.cpp:
1727         (MediaController::duration):
1728         (MediaController::currentTime):
1729         (MediaController::setCurrentTime):
1730         (MediaController::updateReadyState):
1731         * html/NumberInputType.cpp:
1732         (WebCore::NumberInputType::setValueAsDouble):
1733         (WebCore::NumberInputType::setValueAsDecimal):
1734         (WebCore::NumberInputType::createStepRange):
1735         * html/RangeInputType.cpp:
1736         (WebCore::RangeInputType::handleKeydownEvent):
1737         * html/SearchInputType.cpp:
1738         (WebCore::SearchInputType::startSearchEventTimer):
1739         * html/StepRange.cpp:
1740         (WebCore::StepRange::clampValue):
1741         (WebCore::StepRange::parseStep):
1742         * html/TimeRanges.cpp:
1743         * html/ValidationMessage.cpp:
1744         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
1745         (WebCore::adjustBubblePosition):
1746         * html/canvas/CanvasRenderingContext2D.cpp:
1747         (WebCore::normalizeRect):
1748         * html/canvas/WebGLRenderingContext.cpp:
1749         (WebCore::WebGLRenderingContext::validateIndexArrayConservative):
1750         (WebCore::WebGLRenderingContext::validateCompressedTexFuncData):
1751         * html/shadow/MediaControlElements.cpp:
1752         (WebCore::MediaControlRewindButtonElement::defaultEventHandler):
1753         * html/shadow/MediaControlsApple.cpp:
1754         * html/shadow/SliderThumbElement.cpp:
1755         (WebCore::SliderThumbElement::setPositionFromPoint):
1756         * inspector/ContentSearchUtils.cpp:
1757         * inspector/DOMEditor.cpp:
1758         * inspector/DOMPatchSupport.cpp:
1759         (WebCore::DOMPatchSupport::diff):
1760         * inspector/InjectedScriptHost.cpp:
1761         * loader/ProgressTracker.cpp:
1762         (WebCore::ProgressTracker::incrementProgress):
1763         * loader/cache/CachedImage.cpp:
1764         * page/DOMWindow.cpp:
1765         (WebCore::DOMWindow::adjustWindowRect):
1766         * page/EventHandler.cpp:
1767         (WebCore::MaximumDurationTracker::~MaximumDurationTracker):
1768         * page/FrameTree.cpp:
1769         * page/FrameView.cpp:
1770         (WebCore::FrameView::adjustedDeferredRepaintDelay):
1771         (WebCore::FrameView::autoSizeIfEnabled):
1772         * page/PrintContext.cpp:
1773         (WebCore::PrintContext::computeAutomaticScaleFactor):
1774         * page/SpatialNavigation.cpp:
1775         (WebCore::entryAndExitPointsForDirection):
1776         * page/animation/CSSPropertyAnimation.cpp:
1777         (WebCore::blendFilterOperations):
1778         (WebCore::PropertyWrapperShadow::blendMismatchedShadowLists):
1779         * platform/graphics/FloatRect.cpp:
1780         (WebCore::FloatRect::FloatRect):
1781         (WebCore::FloatRect::intersect):
1782         (WebCore::FloatRect::uniteEvenIfEmpty):
1783         (WebCore::FloatRect::extend):
1784         (WebCore::FloatRect::fitToPoints):
1785         * platform/graphics/GlyphPageTreeNode.cpp:
1786         (WebCore::GlyphPageTreeNode::initializePage):
1787         (WebCore::GlyphPageTreeNode::getChild):
1788         * platform/graphics/IntRect.cpp:
1789         (WebCore::IntRect::intersect):
1790         (WebCore::IntRect::unite):
1791         (WebCore::IntRect::uniteIfNonZero):
1792         * platform/graphics/LayoutRect.cpp:
1793         (WebCore::LayoutRect::intersect):
1794         (WebCore::LayoutRect::unite):
1795         (WebCore::LayoutRect::uniteIfNonZero):
1796         * platform/graphics/filters/FEMorphology.cpp:
1797         (WebCore::FEMorphology::platformApplyGeneric):
1798         (WebCore::FEMorphology::platformApplySoftware):
1799         * platform/mac/MemoryPressureHandlerMac.mm:
1800         (WebCore::MemoryPressureHandler::respondToMemoryPressure):
1801         * platform/text/TextCodecICU.cpp:
1802         * rendering/LineWidth.cpp:
1803         (WebCore::LineWidth::fitBelowFloats):
1804         (WebCore::LineWidth::computeAvailableWidthFromLeftAndRight):
1805         * rendering/RenderBlock.h:
1806         (WebCore::RenderBlock::availableLogicalWidthForLine):
1807         (WebCore::RenderBlock::availableLogicalWidthForContent):
1808         * rendering/RenderFieldset.cpp:
1809         (WebCore::RenderFieldset::computePreferredLogicalWidths):
1810         (WebCore::RenderFieldset::layoutSpecialExcludedChild):
1811         (WebCore::RenderFieldset::paintBoxDecorations):
1812         * rendering/RenderFlowThread.cpp:
1813         (WebCore::RenderFlowThread::updateLogicalWidth):
1814         (WebCore::RenderFlowThread::addForcedRegionBreak):
1815         * rendering/RenderFrameBase.cpp:
1816         (WebCore::RenderFrameBase::layoutWithFlattening):
1817         * rendering/RenderFrameSet.cpp:
1818         (WebCore::RenderFrameSet::layOutAxis):
1819         * rendering/RenderSlider.cpp:
1820         (WebCore::RenderSlider::computePreferredLogicalWidths):
1821         * rendering/RenderTableCell.h:
1822         * rendering/RenderTreeAsText.cpp:
1823         (WebCore::writeLayers):
1824         * rendering/RootInlineBox.h:
1825         (WebCore::RootInlineBox::selectionHeight):
1826         (WebCore::RootInlineBox::selectionHeightAdjustedForPrecedingBlock):
1827         * rendering/mathml/RenderMathMLRow.cpp:
1828         (WebCore::RenderMathMLRow::layout):
1829         * rendering/mathml/RenderMathMLScripts.cpp:
1830         (WebCore::RenderMathMLScripts::layout):
1831         * rendering/style/RenderStyle.h:
1832         * rendering/style/StyleGeneratedImage.cpp:
1833         (WebCore::StyleGeneratedImage::imageSize):
1834         * style/StyleFontSizeFunctions.cpp:
1835         (WebCore::Style::fontSizeForKeyword):
1836         * svg/SVGSVGElement.cpp:
1837         (WebCore::SVGSVGElement::setCurrentTime):
1838
1839 2013-10-24  Andreas Kling  <akling@apple.com>
1840
1841         Uncomplicate some of SVGTextRunRenderingContext.
1842         <https://webkit.org/b/123294>
1843
1844         This class was weird about a few things, so I've taken these steps
1845         to clear things up:
1846
1847         - FINAL and OVERRIDE all the things.
1848         - Constructor now takes a RenderObject&.
1849         - renderer() now returns a RenderObject&.
1850         - drawSVGGlyphs() no longer takes a TextRun.
1851         - glyphDataForCharacter() no longer takes a TextRun.
1852
1853         To expand on the last two, there was also some awkward hoop-jumping
1854         where we'd go through the TextRun passed by argument to find its
1855         rendering context, which was really just |this| all along.
1856
1857         Reviewed by Antti Koivisto.
1858
1859 2013-10-24  Roger Fong  <roger_fong@apple.com>
1860
1861         Add texture level dependent size checks to textureImage2D calls.
1862         https://bugs.webkit.org/show_bug.cgi?id=123290
1863         <rdar://problem/15201382>
1864
1865         Reviewed by Dean Jackson
1866
1867         Test covered by WebGL Conformance suite 1.0.2 test, textures/texture-size-limit.html.
1868
1869         There are different size limits when calling textureImage2D on different texture levels.
1870         We should be throwing an error if our texture size exceeds these limits.
1871
1872         * html/canvas/WebGLRenderingContext.cpp:
1873         (WebCore::WebGLRenderingContext::validateTexFuncParameters):
1874
1875 2013-10-24  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1876
1877         [MediaStream API] allow a stream source to be shared
1878         https://bugs.webkit.org/show_bug.cgi?id=121954
1879
1880         Reviewed by Eric Carlson.
1881
1882         Now, the MediaStreamSource don't know about the MediaStream that owns it,
1883         since there can be more than one MediaStream that has it as source for some track.
1884         MediaStreamTrack classes now have observers registered, in case there are more than
1885         one MediaStream owning that track
1886
1887         No new tests, no change in functionality.
1888
1889         * Modules/mediastream/MediaStream.cpp:
1890         (WebCore::MediaStream::MediaStream): Adding the MediaStream as an observer for each track it owns.
1891
1892         (WebCore::MediaStream::addTrack): Now adding the MediaStream as an observer the new added track
1893         and adding the source to the MediaStreamDescriptor.
1894
1895         (WebCore::MediaStream::removeTrack): Instead of removing the source right away, we first check if
1896         there isn't any other track using that source, if not we remove the source.
1897
1898         (WebCore::MediaStream::haveTrackWithSource):
1899         (WebCore::MediaStream::addRemoteSource): MediaStreamSource has no information about the MediaStream
1900         that uses it, so now we don't set the stream in the source anymore.
1901
1902         (WebCore::MediaStream::removeRemoteSource): There can be more than on track using the source. So we
1903         get each track that is using the source and then remove it and fire the ended event.
1904
1905         * Modules/mediastream/MediaStream.h:
1906         * Modules/mediastream/MediaStreamTrack.cpp:
1907         (WebCore::MediaStreamTrack::addObserver):
1908         (WebCore::MediaStreamTrack::removeObserver):
1909         (WebCore::MediaStreamTrack::trackDidEnd): Does not get the client from the MediaStreamDescriptor, it now
1910         notify each of its observers that the track ended.
1911
1912         * Modules/mediastream/MediaStreamTrack.h: Adding Observer class.
1913
1914         * platform/mediastream/MediaStreamDescriptor.cpp: Destructor now does nothing. Previously it was setting
1915         each MediaStreamSource's descriptor to null.
1916
1917         (WebCore::MediaStreamDescriptor::removeSource): Not setting the stream in source anymore.
1918
1919         (WebCore::MediaStreamDescriptor::MediaStreamDescriptor): Ditto.
1920
1921         (WebCore::MediaStreamDescriptor::setEnded): Not setting the state of the source to Ended
1922
1923         * platform/mediastream/MediaStreamDescriptor.h:
1924         (WebCore::MediaStreamDescriptor::~MediaStreamDescriptor):
1925         * platform/mediastream/MediaStreamSource.cpp: Removing references to MediaStream object
1926         (WebCore::MediaStreamSource::MediaStreamSource):
1927         (WebCore::MediaStreamSource::reset):
1928         * platform/mediastream/MediaStreamSource.h:
1929
1930 2013-10-24  Daniel Bates  <dabates@apple.com>
1931
1932         Crash in WebCore::NavigationScheduler::startTimer()
1933         https://bugs.webkit.org/show_bug.cgi?id=123288
1934         <rdar://problem/14055644>
1935
1936         Reviewed by Alexey Proskuryakov.
1937
1938         Currently NavigationScheduler::startTimer() synchronously notifies the client
1939         before the Web Inspector of a scheduled redirect. If a client cancels this
1940         redirect then NavigationScheduler::m_redirect will become null and we'll
1941         subsequently crash when informing the Web Inspector of this formerly scheduled
1942         redirect. Instead, NavigationScheduler::startTimer() should notify the Web
1943         Inspector before it notifies the client of a scheduled redirect.
1944
1945         As a side benefit of this change, the Web Inspector is notified of a scheduled
1946         redirect before being notified of it being canceled when a client chooses to cancel
1947         a scheduled redirect.
1948
1949         * loader/NavigationScheduler.cpp:
1950         (WebCore::NavigationScheduler::startTimer):
1951
1952 2013-10-24  Antti Koivisto  <antti@apple.com>
1953
1954         Try to fix build without CSS_SHAPES.
1955
1956         * rendering/SimpleLineLayout.cpp:
1957         (WebCore::SimpleLineLayout::canUseFor):
1958
1959 2013-10-24  Antti Koivisto  <antti@apple.com>
1960
1961         Simple line layout
1962         https://bugs.webkit.org/show_bug.cgi?id=122458
1963
1964         Reviewed by Darin Adler.
1965
1966         Line box based inline layout is powerful but also rather slow and memory intensive. Simple line layout
1967         is a compact alternative data structure and fast code path to cover common cases without requiring line
1968         boxes.
1969         
1970         This patch handles a case single left-aligned text renderer inside flow with no floats. Even this very basic
1971         case is sufficiently common to handle up to 25% of all text lines on some popular new sites. The decision
1972         which path to use is made per block flow (paragraph).
1973         
1974         Simple line layout aims to produce pixel-exact rendering result when compared to the line box layout.
1975         
1976         The goal is to handle everything that requires line level access in cases that allow use of simple lines.
1977         This is not quite the case yet. For example selections and outline painting are not supported. In these
1978         cases we seamlessly switch to the line boxes.
1979
1980         The simple line data structure currently uses 12 bytes per line. Lineboxes take ~160 bytes minimum per line.
1981         Laying out the lines is also several times faster as is iterating over them.
1982
1983         * CMakeLists.txt:
1984         * GNUmakefile.list.am:
1985         * WebCore.vcxproj/WebCore.vcxproj:
1986         * WebCore.xcodeproj/project.pbxproj:
1987         * dom/Position.cpp:
1988         (WebCore::Position::upstream):
1989         (WebCore::Position::downstream):
1990         (WebCore::Position::getInlineBoxAndOffset):
1991         
1992             Creating positions within a simple line flow causes switch to line boxes.
1993
1994         * editing/TextIterator.cpp:
1995         (WebCore::TextIterator::handleTextNode):
1996         
1997             TextIterator traverses line boxes if available. In case simple line case we need to replicate the
1998             same results (for compatibility but especially to avoid changing test results). This is done here
1999             by just traversing the string without actually using the layout.
2000
2001         * rendering/RenderBlock.cpp:
2002         (WebCore::RenderBlock::RenderBlock):
2003         (WebCore::RenderBlock::layoutShapeInsideInfo):
2004         * rendering/RenderBlock.h:
2005         * rendering/RenderBlockFlow.cpp:
2006         (WebCore::RenderBlockFlow::layoutInlineChildren):
2007         
2008             Select the layout path to use.
2009
2010         (WebCore::RenderBlockFlow::deleteLines):
2011         (WebCore::RenderBlockFlow::hitTestInlineChildren):
2012         (WebCore::RenderBlockFlow::adjustForBorderFit):
2013         (WebCore::RenderBlockFlow::firstLineBaseline):
2014         (WebCore::RenderBlockFlow::inlineBlockBaseline):
2015         (WebCore::RenderBlockFlow::inlineSelectionGaps):
2016         (WebCore::RenderBlockFlow::clearTruncation):
2017         (WebCore::RenderBlockFlow::positionForPointWithInlineChildren):
2018         (WebCore::RenderBlockFlow::addFocusRingRectsForInlineChildren):
2019         (WebCore::RenderBlockFlow::paintInlineChildren):
2020         (WebCore::RenderBlockFlow::hasLines):
2021         (WebCore::RenderBlockFlow::layoutSimpleLines):
2022         
2023             Do simple layout.
2024
2025         (WebCore::RenderBlockFlow::deleteLineBoxesBeforeSimpleLineLayout):
2026         (WebCore::RenderBlockFlow::ensureLineBoxes):
2027         
2028             This function switches from simple lines to line boxes. The switching can be done outside normal layout.
2029             This is used to cover some cases that are not yet supported by simple lines (like selections).
2030
2031         * rendering/RenderBlockFlow.h:
2032         (WebCore::RenderBlockFlow::simpleLines):
2033         * rendering/RenderBlockLineLayout.cpp:
2034         (WebCore::RenderBlockFlow::layoutLineBoxes):
2035         
2036             Rename the line box layout function.
2037
2038         (WebCore::RenderBlockFlow::addOverflowFromInlineChildren):
2039         * rendering/RenderText.cpp:
2040         (WebCore::RenderText::deleteLineBoxesBeforeSimpleLineLayout):
2041         (WebCore::RenderText::absoluteRects):
2042         (WebCore::RenderText::absoluteRectsForRange):
2043         (WebCore::RenderText::absoluteQuadsClippedToEllipsis):
2044         (WebCore::RenderText::absoluteQuads):
2045         (WebCore::RenderText::absoluteQuadsForRange):
2046         (WebCore::RenderText::positionForPoint):
2047         (WebCore::RenderText::knownToHaveNoOverflowAndNoFallbackFonts):
2048         (WebCore::RenderText::setSelectionState):
2049         (WebCore::RenderText::setTextWithOffset):
2050         (WebCore::RenderText::ensureLineBoxes):
2051         (WebCore::RenderText::simpleLines):
2052         (WebCore::RenderText::linesBoundingBox):
2053         (WebCore::RenderText::linesVisualOverflowBoundingBox):
2054         (WebCore::RenderText::selectionRectForRepaint):
2055         (WebCore::RenderText::caretMinOffset):
2056         (WebCore::RenderText::caretMaxOffset):
2057         (WebCore::RenderText::countRenderedCharacterOffsetsUntil):
2058         (WebCore::RenderText::containsRenderedCharacterOffset):
2059         (WebCore::RenderText::containsCaretOffset):
2060         (WebCore::RenderText::hasRenderedText):
2061         * rendering/RenderText.h:
2062         * rendering/RenderTreeAsText.cpp:
2063         (WebCore::RenderTreeAsText::writeRenderObject):
2064         (WebCore::writeSimpleLine):
2065         (WebCore::write):
2066         * rendering/SimpleLineLayout.cpp: Added.
2067         (WebCore::SimpleLineLayout::canUseFor):
2068         
2069             This check for the cases supported by the simple line layout path.
2070
2071         (WebCore::SimpleLineLayout::isWhitespace):
2072         (WebCore::SimpleLineLayout::skipWhitespaces):
2073         (WebCore::SimpleLineLayout::textWidth):
2074         (WebCore::SimpleLineLayout::createLines):
2075         
2076             The main layout functions that breaks text to lines. It only handles the cases allowed by 
2077             SimpleLineLayout::canUseFor. What it handles it aims to break exactly as line box layout does.
2078
2079         * rendering/SimpleLineLayout.h: Added.
2080         * rendering/SimpleLineLayoutFunctions.cpp: Added.
2081         (WebCore::SimpleLineLayout::paintFlow):
2082         (WebCore::SimpleLineLayout::hitTestFlow):
2083         (WebCore::SimpleLineLayout::collectFlowOverflow):
2084         (WebCore::SimpleLineLayout::computeTextBoundingBox):
2085         * rendering/SimpleLineLayoutFunctions.h: Added.
2086         (WebCore::SimpleLineLayout::computeFlowHeight):
2087         (WebCore::SimpleLineLayout::computeFlowFirstLineBaseline):
2088         (WebCore::SimpleLineLayout::computeFlowLastLineBaseline):
2089         (WebCore::SimpleLineLayout::findTextCaretMinimumOffset):
2090         (WebCore::SimpleLineLayout::findTextCaretMaximumOffset):
2091         (WebCore::SimpleLineLayout::containsTextCaretOffset):
2092         (WebCore::SimpleLineLayout::isTextRendered):
2093         (WebCore::SimpleLineLayout::lineHeightFromFlow):
2094         
2095             Support functions called from RenderBlockFlow and RenderText. They are equivalent to
2096             similar line box functions.
2097
2098         (WebCore::SimpleLineLayout::baselineFromFlow):
2099         * rendering/SimpleLineLayoutResolver.h: Added.
2100         (WebCore::SimpleLineLayout::Resolver::Line::Line):
2101         (WebCore::SimpleLineLayout::Resolver::Line::rect):
2102         (WebCore::SimpleLineLayout::Resolver::Line::baseline):
2103         (WebCore::SimpleLineLayout::Resolver::Line::text):
2104         (WebCore::SimpleLineLayout::Resolver::Iterator::Iterator):
2105         (WebCore::SimpleLineLayout::Resolver::Iterator::operator++):
2106         (WebCore::SimpleLineLayout::Resolver::Iterator::operator--):
2107         (WebCore::SimpleLineLayout::Resolver::Iterator::operator==):
2108         (WebCore::SimpleLineLayout::Resolver::Iterator::operator!=):
2109         (WebCore::SimpleLineLayout::Resolver::Iterator::operator*):
2110         
2111             Lazy iterator for deriving line metrics. This keeps the line data structure small as
2112             we don't need to keep easily derived values around.
2113
2114         (WebCore::SimpleLineLayout::Resolver::Resolver):
2115         (WebCore::SimpleLineLayout::Resolver::size):
2116         (WebCore::SimpleLineLayout::Resolver::begin):
2117         (WebCore::SimpleLineLayout::Resolver::end):
2118         (WebCore::SimpleLineLayout::Resolver::last):
2119         (WebCore::SimpleLineLayout::Resolver::operator[]):
2120
2121 2013-10-24  Myles C. Maxfield  <mmaxfield@apple.com>
2122
2123         Gaps between underlines in adjacent underlined text runs
2124         https://bugs.webkit.org/show_bug.cgi?id=123236
2125
2126         Reviewed by Simon Fraser and Darin Adler.
2127
2128         There are two pieces to this change. The first piece is in
2129         InlineTextBox::paint(). We were putting floating-point
2130         extents into a LayoutSize, which simply uses ints (for now),
2131         and then immediately converting this back to a FloatSize.
2132         Instead, we should be using floats throughout all of
2133         this code.
2134
2135         In addition, inside GraphicsContext::drawLineForText(), we are
2136         rounding the underline to pixel boundaries so that it appears
2137         very crisp on the screen. However, we should round once after
2138         performing computations, rather than rounding twice and then
2139         performing computations on the rounded numbers.
2140
2141         Test: fast/css3-text/css3-text-decoration/no-gap-between-two-rounded-textboxes.html
2142
2143         * platform/graphics/cg/GraphicsContextCG.cpp:
2144         (WebCore::GraphicsContext::drawLineForText): Change rounding mode
2145             to perform computations before rounding
2146         * rendering/InlineTextBox.cpp:
2147         (WebCore::InlineTextBox::paint): Don't convert to a LayoutSize
2148             just to convert to a FloatSize
2149
2150 2013-10-24  Andreas Kling  <akling@apple.com>
2151
2152         SVGRenderingContext should wrap a RenderElement.
2153         <https://webkit.org/b/123283>
2154
2155         The SVG rendering context class is never used with text renderers
2156         so we can have it wrap a RenderElement for tighter code.
2157
2158         Also renamed SVGRenderingContext::m_object to m_renderer.
2159
2160         Reviewed by Antti Koivisto.
2161
2162 2013-10-24  Santosh Mahto  <santosh.ma@samsung.com>
2163
2164         [contenteditable] Content after non-editable element disappears when merging lines using backspace
2165         https://bugs.webkit.org/show_bug.cgi?id=122748
2166
2167         Reviewed by Ryosuke Niwa.
2168
2169         In case of paragraph merging after deletion if second paragraph
2170         contains non-editable element, then content after the non-editable
2171         element(including non-editable element) will be removed while the
2172         content before the element will be merged with the first paragraph.
2173         This happens becasue endOfParagraphToMove calculation in merging function
2174         stop at editing boundary so endOfParagraphToMove becomes position just
2175         before non-editable content.
2176         With this patch now endOfParagraphToMove is calculated by skipping
2177         over the non-editable element.
2178
2179         Test: editing/deleting/merge-paragraph-contatining-noneditable.html
2180
2181         * editing/DeleteSelectionCommand.cpp:
2182         (WebCore::DeleteSelectionCommand::mergeParagraphs): use CanSkipOverEditingBoundary
2183         condition while calculating endOfParagraphToMove.
2184
2185 2013-10-24  Antoine Quint  <graouts@apple.com>
2186
2187         Web Inspector: Inspector doesn't show webkitTransitionEnd events in the timeline
2188         https://bugs.webkit.org/show_bug.cgi?id=123263
2189
2190         Reviewed by Timothy Hatcher.
2191
2192         A legacy event type is only set on an event in EventTarget::fireEventListeners(Event*)
2193         which is called after we used to call InspectorInstrumentation::willDispatchEvent(), the method
2194         that would ultimately yield the creation of a TimelineRecord for the event in the Web Inspector
2195         frontend, and as a result we would try to dispatch an event with an unprefixed event type to
2196         the frontend, which wouldn't even happen because most likely it wouldn't have listeners for this
2197         unprefixed type.
2198
2199         We now move the call to InspectorInstrumentation::willDispatchEvent() in
2200         EventTarget::fireEventListeners(Event*, EventTargetData*, EventListenerVector&) such that the
2201         correct event type and list of listeners is used to determine what event to dispatch to the frontend.
2202
2203         * dom/EventDispatcher.cpp:
2204         (WebCore::EventDispatcher::dispatchEvent):
2205         Remove calls to InspectorInstrumentation::willDispatchEvent() and InspectorInstrumentation::didDispatchEvent().
2206
2207         * dom/EventTarget.cpp:
2208         (WebCore::EventTarget::fireEventListeners):
2209         Add call to InspectorInstrumentation::willDispatchEvent() before we go through each listener and
2210         call InspectorInstrumentation::willHandleEvent(). Additionally, we refactor some code since we're
2211         getting references to the ScriptExecutionContext and Document upfront now.
2212
2213 2013-10-24  Andreas Kling  <akling@apple.com>
2214
2215         SVG: RenderElement-ize intersectRepaintRectWithResources().
2216         <https://webkit.org/b/123278>
2217
2218         SVGRenderSupport::intersectRepaintRectWithResources() is only ever
2219         called with non-text renderers so make it take RenderElement&.
2220
2221         Had to tweak RenderSVGResource::resourceBoundingBox() to take the
2222         renderer by reference.
2223
2224         Reviewed by Antti Koivisto.
2225
2226 2013-10-24  Joseph Pecoraro  <pecoraro@apple.com>
2227
2228         Web Inspector: Breakpoints in sourceURL named scripts do not work
2229         https://bugs.webkit.org/show_bug.cgi?id=123231
2230
2231         Reviewed by Timothy Hatcher.
2232
2233         Remember a Script's sourceURL and sourceMappingURL. When setting a
2234         breakpoint by URL, check it against the sourceURL or original URL.
2235         If a script had a sourceURL that would have been the only URL sent
2236         to the frontend, so that receives priority.
2237
2238         Test: inspector-protocol/debugger/setBreakpointByUrl-sourceURL.html
2239
2240         * inspector/InspectorDebuggerAgent.cpp:
2241         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
2242         (WebCore::InspectorDebuggerAgent::didParseSource):
2243         * inspector/InspectorDebuggerAgent.h:
2244         * inspector/ScriptDebugListener.h:
2245
2246 2013-10-23  Alexey Proskuryakov  <ap@apple.com>
2247
2248         Add CryptoKey base class and bindings
2249         https://bugs.webkit.org/show_bug.cgi?id=123216
2250
2251         Reviewed by Sam Weinig.
2252
2253         * crypto/CryptoKey.idl: Added.
2254
2255         * CMakeLists.txt:
2256         * DerivedSources.make:
2257         * GNUmakefile.list.am:
2258         Process the IDL.
2259
2260         * WebCore.xcodeproj/project.pbxproj: Added files.
2261
2262         * bindings/js/JSCryptoKeyCustom.cpp: Added.
2263         (WebCore::JSCryptoKey::algorithm): Use a visitor to build algorithm dictionary
2264         for the key.
2265
2266         * crypto/CryptoAlgorithmDescriptionBuilder.cpp: Added.
2267         * crypto/CryptoAlgorithmDescriptionBuilder.h: Added.
2268         An interface for a visitor we'll use to expose CrytoKey.algorithm in bindings,
2269         and possibly also for storage serialization. Not complete yet, we'll need support
2270         for a few more simple types, and less trivially, for nested algorithms.
2271
2272         * bindings/js/JSCryptoAlgorithmBuilder.cpp: Added.
2273         * bindings/js/JSCryptoAlgorithmBuilder.h: Added.
2274         An implementation that builds an algorithm description dictionary for JS bindings.
2275
2276         * crypto/CryptoKey.cpp: Added.
2277         (WebCore::CryptoKey::~CryptoKey):
2278         (WebCore::CryptoKey::buildAlgorithmDescription):
2279         * crypto/CryptoKey.h: Added.
2280         Added an almost empty implementation. Some of the functions that are currently
2281         marked as pure virtual will likely be implemented in this base class.
2282
2283 2013-10-24  Commit Queue  <commit-queue@webkit.org>
2284
2285         Unreviewed, rolling out r157916.
2286         http://trac.webkit.org/changeset/157916
2287         https://bugs.webkit.org/show_bug.cgi?id=123274
2288
2289         Broke Layout/flexbox-lots-of-data.html on perfbot (Requested
2290         by ap on #webkit).
2291
2292         * rendering/RenderFlexibleBox.cpp:
2293         (WebCore::RenderFlexibleBox::OrderHashTraits::emptyValue):
2294         (WebCore::RenderFlexibleBox::OrderHashTraits::constructDeletedValue):
2295         (WebCore::RenderFlexibleBox::OrderHashTraits::isDeletedValue):
2296         (WebCore::RenderFlexibleBox::OrderIterator::setOrderValues):
2297         (WebCore::RenderFlexibleBox::layoutBlock):
2298         (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
2299         * rendering/RenderFlexibleBox.h:
2300
2301 2013-10-24  Zan Dobersek  <zdobersek@igalia.com>
2302
2303         Comment in ScopedEventQueue::dispatchEvent is unnecessarily verbose
2304         https://bugs.webkit.org/show_bug.cgi?id=123252
2305
2306         Reviewed by Darin Adler.
2307
2308         Shorten the comment about the crash avoidance in ScopedEventQueue::dispatchEvent due to
2309         the calling convention in C++ is left unspecified. The problem was already fixed in r157219
2310         and later adjusted in r157401, but the comment could have been shorter and simpler in both cases.
2311
2312         * dom/ScopedEventQueue.cpp:
2313         (WebCore::ScopedEventQueue::dispatchEvent):
2314
2315 2013-10-24  Alex Christensen  <achristensen@webkit.org>
2316
2317         Removed unused ThreadSafeCoordinatedSurface and CertificateInfoCurl files.
2318         https://bugs.webkit.org/show_bug.cgi?id=123246
2319
2320         Reviewed by Noam Rosenthal.
2321
2322         * WebCore.vcxproj/WebCore.vcxproj:
2323         * WebCore.vcxproj/WebCore.vcxproj.filters:
2324         Removed references to ThreadSafeCoordinatedSurface and CertificateInfoCurl.
2325         * platform/graphics/texmap/coordinated/ThreadSafeCoordinatedSurface.cpp: Removed.
2326         * platform/graphics/texmap/coordinated/ThreadSafeCoordinatedSurface.h: Removed.
2327         * platform/network/curl/CertificateInfoCurl.cpp: Removed.
2328
2329 2013-10-24  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
2330
2331         Removed Qt workaround.
2332         https://bugs.webkit.org/show_bug.cgi?id=123258
2333
2334         Reviewed by Csaba Osztrogon√°c.
2335
2336         No change of functionality, no new tests needed.
2337
2338         !$defines case can be removed, because Qt and Android aren't in WebKit trunk,
2339         all ports (Mac,EFL,GTK,Windows) call this script with --defines option now
2340
2341         * css/make-css-file-arrays.pl:
2342
2343 2013-10-24  Antti Koivisto  <antti@apple.com>
2344
2345         Remove a stray space.
2346         
2347         Not reviewed.
2348
2349         * accessibility/AccessibilityRenderObject.cpp:
2350         (WebCore::AccessibilityRenderObject::addImageMapChildren):
2351
2352 2013-10-24  Antti Koivisto  <antti@apple.com>
2353
2354         Element iterator functions should take reference
2355         https://bugs.webkit.org/show_bug.cgi?id=123267
2356
2357         Reviewed by Andreas Kling.
2358
2359         The argument has to be non-null.
2360
2361 2013-10-24  Ryuan Choi  <ryuan.choi@samsung.com>
2362
2363         [EFL] Build break with latest EFL 1.8 libraries.
2364         https://bugs.webkit.org/show_bug.cgi?id=123245
2365
2366         Reviewed by Gyuyoung Kim.
2367
2368         After fixed build break on EFL 1.8 at r138326, EFL libraries are changed
2369         Eo typedef and splitted header files which contain version macro.
2370
2371         * platform/Widget.h: Changed Eo typedef.
2372         * platform/efl/EflScreenUtilities.h: Ditto.
2373         * platform/graphics/Image.h: Ditto.
2374
2375 2013-10-24  Andreas Kling  <akling@apple.com>
2376
2377         RenderSVGResource: Pass RenderElement to fill/strokePaintingResource.
2378         <https://webkit.org/b/123242>
2379
2380         We never pass text renderers to these functions, so make them take
2381         RenderElement instead.
2382
2383         Reviewed by Anders Carlsson.
2384
2385 2013-10-24  Carlos Garcia Campos  <cgarcia@igalia.com>
2386
2387         [GObject bindings] Make EventTarget interface introspectable
2388         https://bugs.webkit.org/show_bug.cgi?id=77835
2389
2390         Reviewed by Gustavo Noronha Silva.
2391
2392         Add webkit_dom_event_target_add_event_listener_with_closure and
2393         webkit_dom_event_target_remove_event_listener_with_closure to be
2394         used by GObject instrospection bindings. Instead of receving a
2395         GCallback, which makes the function not introspectable, they
2396         receive a GClosure.
2397
2398         * bindings/gobject/GObjectEventListener.cpp:
2399         (WebCore::GObjectEventListener::GObjectEventListener):
2400         (WebCore::GObjectEventListener::~GObjectEventListener):
2401         (WebCore::GObjectEventListener::gobjectDestroyed):
2402         (WebCore::GObjectEventListener::handleEvent):
2403         (WebCore::GObjectEventListener::operator==):
2404         * bindings/gobject/GObjectEventListener.h:
2405         (WebCore::GObjectEventListener::addEventListener):
2406         (WebCore::GObjectEventListener::removeEventListener):
2407         * bindings/gobject/WebKitDOMEventTarget.cpp:
2408         (webkit_dom_event_target_dispatch_event):
2409         (webkit_dom_event_target_add_event_listener):
2410         (webkit_dom_event_target_remove_event_listener):
2411         (webkit_dom_event_target_add_event_listener_with_closure):
2412         (webkit_dom_event_target_remove_event_listener_with_closure):
2413         * bindings/gobject/WebKitDOMEventTarget.h:
2414         * bindings/scripts/CodeGeneratorGObject.pm:
2415         (GenerateEventTargetIface):
2416         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
2417         (webkit_dom_test_event_target_dispatch_event):
2418         (webkit_dom_test_event_target_add_event_listener):
2419         (webkit_dom_test_event_target_remove_event_listener):
2420         * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
2421         (webkit_dom_test_node_dispatch_event):
2422         (webkit_dom_test_node_add_event_listener):
2423         (webkit_dom_test_node_remove_event_listener):
2424
2425 2013-10-14  Sergio Villar Senin  <svillar@igalia.com>
2426
2427         Use a Vector instead of HashSet to computed the orderValues in RenderFlexibleBox
2428         https://bugs.webkit.org/show_bug.cgi?id=118620
2429
2430         Reviewed by Antti Koivisto.
2431
2432         Turns out that order is extremelly uncommon so using a Vector is
2433         much less expensive. This also special-cases the much common case
2434         of only having order of value 0 by using Vectors with just one
2435         preallocated member.
2436
2437         Also added the performance test that shows a ~1% win when using a
2438         vector instead of the HashSet.
2439
2440         * rendering/RenderFlexibleBox.cpp:
2441         (WebCore::RenderFlexibleBox::OrderIterator::setOrderValues):
2442         (WebCore::RenderFlexibleBox::layoutBlock):
2443         (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
2444         * rendering/RenderFlexibleBox.h:
2445
2446 2013-10-23  ChangSeok Oh  <changseok.oh@collabora.com>
2447
2448         Unreviewed build fix since r157823.
2449         FilterOperation::getOperationType() is renamed FilterOperation::type().
2450
2451         * platform/graphics/texmap/TextureMapperGL.cpp:
2452         (WebCore::prepareFilterProgram):
2453         (WebCore::TextureMapperGL::drawTexture):
2454         (WebCore::TextureMapperGL::drawUsingCustomFilter):
2455         (WebCore::TextureMapperGL::drawFiltered):
2456         (WebCore::BitmapTextureGL::applyFilters):
2457         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
2458         (WebCore::CoordinatedGraphicsScene::injectCachedCustomFilterPrograms):
2459
2460 2013-10-23  Ryuan Choi  <ryuan.choi@samsung.com>
2461
2462         Unreviewed build fix on CMake based ports when CMAKE_BUILD_TYPE is not given.
2463
2464         When CMAKE_BUILD_TYPE is empty, FIND command will be failed.
2465
2466         * CMakeLists.txt:
2467
2468 2013-10-23  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2469
2470         Integrate css3-images image-orientation with existing EXIF support
2471         https://bugs.webkit.org/show_bug.cgi?id=91566
2472
2473         Reviewed by Beth Dakin.
2474
2475         Original patch by David Barr(davidbarr@chromium.org).
2476
2477         This patch passes an information of image orientation into existing EXIF support functions
2478         (draw() functions of image classes mainly). We need to let the functions to know the information
2479         in order to meet the image-orientation requirement.
2480
2481         Spec: http://dev.w3.org/csswg/css-images-3/#the-image-orientation
2482         The css3-images module specification is at last call.
2483
2484         Test: fast/css/image-orientation/image-orientation.html
2485         Image orientation test is to check if incorrect rotation value can be fixed with correct orientation.
2486
2487         * loader/cache/CachedImage.cpp:
2488         (WebCore::CachedImage::imageSizeForRenderer):
2489         * page/DragController.cpp:
2490         (WebCore::DragController::doImageDrag):
2491         * page/Frame.cpp:
2492         (WebCore::Frame::nodeImage):
2493         * platform/graphics/BitmapImage.cpp:
2494         (WebCore::BitmapImage::updateSize):
2495         (WebCore::BitmapImage::sizeRespectingOrientation):
2496         (WebCore::BitmapImage::drawPattern):
2497         * platform/graphics/BitmapImage.h:
2498         * platform/graphics/CrossfadeGeneratedImage.cpp:
2499         (WebCore::CrossfadeGeneratedImage::draw):
2500         * platform/graphics/CrossfadeGeneratedImage.h:
2501         * platform/graphics/GeneratedImage.h:
2502         * platform/graphics/GradientImage.cpp:
2503         (WebCore::GradientImage::draw):
2504         * platform/graphics/GradientImage.h:
2505         * platform/graphics/Image.cpp:
2506         (WebCore::Image::draw):
2507         (WebCore::Image::drawTiled):
2508         * platform/graphics/Image.h:
2509         * platform/graphics/blackberry/ImageBlackBerry.cpp:
2510         * platform/graphics/cairo/BitmapImageCairo.cpp:
2511         (WebCore::BitmapImage::draw):
2512         * platform/graphics/cg/BitmapImageCG.cpp:
2513         * platform/graphics/cg/PDFDocumentImage.cpp:
2514         (WebCore::PDFDocumentImage::draw):
2515         * platform/graphics/cg/PDFDocumentImage.h:
2516         * platform/graphics/win/ImageCGWin.cpp:
2517         (WebCore::BitmapImage::getHBITMAPOfSize):
2518         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
2519         * platform/graphics/wince/ImageBufferWinCE.cpp:
2520         (WebCore::BufferedImage::draw):
2521         * platform/graphics/wince/ImageWinCE.cpp:
2522         (WebCore::BitmapImage::draw):
2523         * platform/mac/DragImageMac.mm:
2524         (WebCore::createDragImageFromImage):
2525         * rendering/RenderEmbeddedObject.cpp:
2526         (WebCore::RenderEmbeddedObject::paintSnapshotImage):
2527         * rendering/RenderImage.cpp:
2528         (WebCore::RenderImage::styleDidChange):
2529         * rendering/RenderSnapshottedPlugIn.cpp:
2530         (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
2531         * rendering/style/RenderStyle.cpp:
2532         (WebCore::RenderStyle::changeRequiresLayout):
2533         * svg/graphics/SVGImage.cpp:
2534         (WebCore::SVGImage::drawForContainer):
2535         (WebCore::SVGImage::nativeImageForCurrentFrame):
2536         (WebCore::SVGImage::draw):
2537         * svg/graphics/SVGImage.h:
2538         * svg/graphics/SVGImageForContainer.cpp:
2539         (WebCore::SVGImageForContainer::draw):
2540         * svg/graphics/SVGImageForContainer.h:
2541
2542 2013-10-23  Andreas Kling  <akling@apple.com>
2543
2544         Tighten typing in SVGInlineTextBox a bit.
2545         <https://webkit.org/b/123238>
2546
2547         Use RenderBoxModelObject& instead of generic RenderObject* in some
2548         places where it happens as a natural consequence of keeping the
2549         original return type from InlineBox::parent()->renderer().
2550
2551         Reviewed by Anders Carlsson.
2552
2553 2013-10-23  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2554
2555         Introduce RENDER_OBJECT_TYPE_CASTS to replace manual toFoo() in child render object
2556         https://bugs.webkit.org/show_bug.cgi?id=123150
2557
2558         Reviewed by Andreas Kling.
2559
2560         As a step to let toFoo use TYPE_CASTS_BASE, toRenderFoo() can use it for child render object.
2561         So, this patch introduces RENDER_OBJECT_TYPE_CASTS based on the TYPE_CASTS_BASE. This will
2562         generate plenty more helper functions for render object type cast.
2563
2564         Some unnecessary type casts are fixed by this change.
2565
2566         No new tests, no behavior changes.
2567
2568         * rendering/RenderBlock.h:
2569         * rendering/RenderBlockFlow.h:
2570         * rendering/RenderBox.h:
2571         * rendering/RenderBoxModelObject.h:
2572         * rendering/RenderButton.h:
2573         * rendering/RenderCounter.h:
2574         * rendering/RenderElement.h:
2575         (WebCore::RenderElement::generatingElement):
2576         * rendering/RenderEmbeddedObject.h:
2577         * rendering/RenderFieldset.h:
2578         * rendering/RenderFileUploadControl.h:
2579         * rendering/RenderFlexibleBox.h:
2580         * rendering/RenderFlowThread.h:
2581         * rendering/RenderFrame.h:
2582         * rendering/RenderFrameSet.h:
2583         * rendering/RenderFullScreen.h:
2584         * rendering/RenderHTMLCanvas.h:
2585         * rendering/RenderIFrame.h:
2586         * rendering/RenderImage.h:
2587         * rendering/RenderInline.h:
2588         * rendering/RenderLayerModelObject.h:
2589         * rendering/RenderLineBreak.h:
2590         * rendering/RenderListBox.h:
2591         * rendering/RenderListItem.h:
2592         * rendering/RenderMedia.h:
2593         * rendering/RenderMenuList.h:
2594         * rendering/RenderMeter.h:
2595         * rendering/RenderMultiColumnBlock.h:
2596         * rendering/RenderMultiColumnSet.h:
2597         * rendering/RenderNamedFlowFragment.h:
2598         * rendering/RenderNamedFlowThread.h:
2599         * rendering/RenderObject.h:
2600         * rendering/RenderProgress.h:
2601         * rendering/RenderQuote.h:
2602         * rendering/RenderRegion.h:
2603         * rendering/RenderReplaced.h:
2604         * rendering/RenderRubyRun.h:
2605         * rendering/RenderScrollbarPart.h:
2606         * rendering/RenderSearchField.h:
2607         * rendering/RenderSlider.h:
2608         * rendering/RenderSnapshottedPlugIn.h:
2609         * rendering/RenderTable.h:
2610         * rendering/RenderTableCaption.h:
2611         * rendering/RenderTableCell.h:
2612         * rendering/RenderTableCol.h:
2613         * rendering/RenderTableRow.h:
2614         * rendering/RenderTableSection.h:
2615         * rendering/RenderText.h:
2616         * rendering/RenderTextControl.h:
2617         * rendering/RenderTextControlMultiLine.h:
2618         * rendering/RenderTextControlSingleLine.h:
2619         * rendering/RenderWidget.h:
2620         * rendering/mathml/RenderMathMLBlock.h:
2621         * rendering/svg/RenderSVGContainer.h:
2622         * rendering/svg/RenderSVGGradientStop.h:
2623         * rendering/svg/RenderSVGImage.h:
2624         * rendering/svg/RenderSVGInlineText.h:
2625         * rendering/svg/RenderSVGPath.h:
2626         * rendering/svg/RenderSVGResourceFilter.h:
2627         * rendering/svg/RenderSVGResourceFilterPrimitive.cpp:
2628         (WebCore::RenderSVGResourceFilterPrimitive::styleDidChange):
2629         * rendering/svg/RenderSVGRoot.h:
2630         * rendering/svg/RenderSVGShape.h:
2631         * rendering/svg/RenderSVGText.h:
2632         * rendering/svg/RenderSVGTextPath.h:
2633         * rendering/svg/RenderSVGViewportContainer.h:
2634         * rendering/svg/SVGInlineFlowBox.cpp:
2635         (WebCore::SVGInlineFlowBox::paint):
2636
2637 2013-10-23  Myles C. Maxfield  <mmaxfield@apple.com>
2638
2639         Include misspelling dot gap width when centering misspelling dots
2640         https://bugs.webkit.org/show_bug.cgi?id=122365
2641
2642         Reviewed by Simon Fraser.
2643
2644         When calculating where to place the misspelling dots, we find the
2645         maximum number of full dots that can fit under the misspelled word,
2646         and then center a run of that many dots. However, when we're
2647         centering the run, we are only considering the size of the extra
2648         fractional dot that we cut off. However, the dot image has a "gap"
2649         of transparent pixels (which visually provide tracking for the dots)
2650         which visually appears to be empty space. We should take this gap
2651         space into consideration when centering the run of dots. We also
2652         should make sure that our dots start on integral pixel boundaries
2653         because otherwise we can't set the phase of the dot run properly.
2654
2655         Test: editing/spelling/centering-misspelling-dots.html
2656
2657         * platform/graphics/mac/GraphicsContextMac.mm:
2658         (WebCore::GraphicsContext::drawLineForDocumentMarker):
2659
2660 2013-10-23  Andreas Kling  <akling@apple.com>
2661
2662         SVGFilterBuilder should not be ref-counted.
2663         <https://webkit.org/b/123222>
2664
2665         These objects are singly-owned and do not need ref counting.
2666
2667         Reviewed by Anders Carlsson.
2668
2669 2013-10-23  Brady Eidson  <beidson@apple.com>
2670
2671         Remove unused IDBBackingStoreLevelDB default constructor.
2672
2673         Rubberstamped by Anders Carlsson.
2674
2675         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
2676         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
2677
2678 2013-10-23  Alex Christensen  <achristensen@webkit.org>
2679
2680         Added Texture Mapper and Coordinated Graphics to Windows build for WinCairo.
2681         https://bugs.webkit.org/show_bug.cgi?id=123215
2682
2683         Reviewed by Brent Fulgham.
2684
2685         * WebCore.vcxproj/WebCore.vcxproj:
2686         * WebCore.vcxproj/WebCore.vcxproj.filters:
2687         Added source files for Texture Mapper to Windows build.
2688         * WebCore.vcxproj/WebCoreCairo.props:
2689         Added Texture Mapper include directories for WinCairo.
2690
2691 2013-10-23  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
2692
2693         Adding mock class to test RTCDataChannelHandler
2694         https://bugs.webkit.org/show_bug.cgi?id=123205
2695
2696         Reviewed by Eric Carlson.
2697
2698         Now RTCPeerConnectionHandler-datachannel LayouTest can run properly.
2699         Also updated the expected file, removing the reliable property check (which was removed in the spec)
2700
2701         Existing tests updated.
2702
2703         * CMakeLists.txt:
2704         * platform/mediastream/RTCDataChannelHandlerClient.h:
2705         * platform/mock/RTCDataChannelHandlerMock.cpp: Added.
2706         * platform/mock/RTCDataChannelHandlerMock.h: Added.
2707         * platform/mock/RTCNotifiersMock.cpp:
2708         (WebCore::RemoteDataChannelNotifier::RemoteDataChannelNotifier):
2709         (WebCore::RemoteDataChannelNotifier::fire):
2710         (WebCore::DataChannelStateNotifier::DataChannelStateNotifier):
2711         (WebCore::DataChannelStateNotifier::fire):
2712         * platform/mock/RTCNotifiersMock.h:
2713         * platform/mock/RTCPeerConnectionHandlerMock.cpp:
2714         (WebCore::RTCPeerConnectionHandlerMock::createDataChannel):
2715
2716 2013-10-23  Andreas Kling  <akling@apple.com>
2717
2718         Clock should not be ref-counted.
2719         <https://webkit.org/b/123217>
2720
2721         The Clock object is only ever owned by the MediaController,
2722         so remove the ref counting and store it in a std::unique_ptr.
2723
2724         Also slapped the Clock subclasses with FINAL and OVERRIDE.
2725
2726         Reviewed by Anders Carlsson.
2727
2728 2013-10-23  Mark Lam  <mark.lam@apple.com>
2729
2730         Fix assertion in DatabaseManager::detailsForNameAndOrigin() to be iOS friendly.
2731         https://bugs.webkit.org/show_bug.cgi?id=123218.
2732
2733         Reviewed by Joseph Pecoraro.
2734
2735         No new tests.
2736
2737         * Modules/webdatabase/DatabaseManager.cpp:
2738         (WebCore::DatabaseManager::detailsForNameAndOrigin):
2739
2740 2013-10-23  Alex Christensen  <achristensen@webkit.org>
2741
2742         Separated USE(CA) from USE(ACCELERATED_COMPOSITING) to prepare WinCairo for accelerated compositing.
2743         https://bugs.webkit.org/show_bug.cgi?id=123214
2744
2745         Reviewed by Brent Fulgham.
2746
2747         * platform/graphics/PlatformLayer.h:
2748         Added TextureMapperPlatformLayer PlatformLayer declaration for WinCairo.
2749         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.cpp:
2750         (WebCore::MediaPlayerPrivateFullscreenWindow::createWindow):
2751         (WebCore::MediaPlayerPrivateFullscreenWindow::wndProc):
2752         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h:
2753         Added USE(CA) where necessary to compile WinCairo with accelerated compositing.
2754
2755 2013-10-23  Myles C. Maxfield  <mmaxfield@apple.com>
2756
2757         Antialias underlines if they're not axis-aligned
2758         https://bugs.webkit.org/show_bug.cgi?id=123004
2759
2760         Reviewed by Simon Fraser.
2761
2762         In order to make underlines crisp, GraphicsContext:drawLineForText
2763         modifies the bounds of the underline rect in order to make the rect
2764         device-pixel-aligned, and then turns off antialiasing when drawing
2765         the line. This makes sense when the underline is axis-aligned, but
2766         doesn't when the rect is rotated or skewed. Therefore, we should
2767         only opt-in to this behavior if the underline we're about to draw
2768         is axis-aligned. This requires figuring out whether or not the
2769         current transformation is axis-aligned every time
2770         GraphicsContext::drawLineForText is called, which will incur a small
2771         performance hit. However, this is justified by underlines looking
2772         much better (antialiased) when the context is rotated or skewed.
2773
2774         Tests: svg/custom/foreign-object-skew.html
2775                svg/zoom/page/zoom-foreignObject.html
2776                svg/zoom/text/zoom-foreignObject.html:
2777
2778         * platform/graphics/cg/GraphicsContextCG.cpp:
2779         (WebCore::GraphicsContext::drawLineForText):
2780
2781 2013-10-23  Mark Lam  <mark.lam@apple.com>
2782
2783         Re-instate ProposedDatabases needed by detailsForNameAndOrigin().
2784         https://bugs.webkit.org/show_bug.cgi?id=123131.
2785
2786         Reviewed by Geoffrey Garen.
2787
2788         Test: storage/websql/open-database-expand-quota.html
2789
2790         If a webpage tries to create a database that exceeds the database size
2791         quota for that security origin, the WebKit1 quota request mechanism
2792         uses detailsForNameAndOrigin() to get the requested size of the database
2793         (that the webpage is attempting to open) in order to determine whether
2794         to increase the quota or not.
2795
2796         Previously, detailsForNameAndOrigin() relies on the ProposedDatabase
2797         mechanism to provide this size information. This change re-instates the
2798         ProposedDatabase mechanism so that WebKit1 client code that relies on
2799         this behavior will continue to work.
2800
2801         * Modules/webdatabase/DatabaseManager.cpp:
2802         (WebCore::DatabaseManager::ProposedDatabase::ProposedDatabase):
2803         (WebCore::DatabaseManager::ProposedDatabase::~ProposedDatabase):
2804         (WebCore::DatabaseManager::DatabaseManager):
2805         (WebCore::DatabaseManager::openDatabaseBackend):
2806         (WebCore::DatabaseManager::fullPathForDatabase):
2807         (WebCore::DatabaseManager::detailsForNameAndOrigin):
2808         * Modules/webdatabase/DatabaseManager.h:
2809         (WebCore::DatabaseManager::ProposedDatabase::origin):
2810         (WebCore::DatabaseManager::ProposedDatabase::details):
2811
2812 2013-10-23  Tim Horton  <timothy_horton@apple.com>
2813
2814         [cg] Fix the capitalization of kCGImageSourceSkipMetaData (-> Metadata)
2815         https://bugs.webkit.org/show_bug.cgi?id=122918
2816
2817         Reviewed by Anders Carlsson.
2818
2819         * platform/graphics/cg/ImageSourceCG.cpp:
2820         (WebCore::imageSourceOptions):
2821         The capitalization of kCGImageSourceSkipMetaData changed to
2822         kCGImageSourceSkipMetadata in Mountain Lion.
2823
2824 2013-10-23  Brady Eidson  <beidson@apple.com>
2825
2826         Make IDBDatabaseBackendLevelDB.cpp be cross platform
2827         https://bugs.webkit.org/show_bug.cgi?id=123027
2828
2829         Attentively reviewed by Dean Jackson.
2830
2831         Move it out of the indexeddb/leveldb directory, and rename it to IDBDatabaseBackendImpl.
2832
2833         Project files:
2834         * CMakeLists.txt:
2835         * GNUmakefile.list.am:
2836         * WebCore.vcxproj/WebCore.vcxproj:
2837         * WebCore.vcxproj/WebCore.vcxproj.filters:
2838         * WebCore.xcodeproj/project.pbxproj:
2839
2840         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp: Renamed from Source/WebCore/Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.cpp.
2841         * Modules/indexeddb/IDBDatabaseBackendImpl.h: Renamed from Source/WebCore/Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.h.
2842
2843         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
2844         (WebCore::IDBDatabaseBackendInterface::isIDBDatabaseBackendImpl): Add to support a required cast in LevelDB code.
2845
2846         * Modules/indexeddb/IDBFactoryBackendInterface.h:
2847
2848         * Modules/indexeddb/leveldb/IDBCursorBackendLevelDB.cpp:
2849         * Modules/indexeddb/leveldb/IDBCursorBackendLevelDB.h:
2850
2851         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
2852         (WebCore::IDBFactoryBackendLevelDB::deleteDatabase):
2853         (WebCore::IDBFactoryBackendLevelDB::open):
2854         (WebCore::IDBFactoryBackendLevelDB::maybeCreateTransactionBackend):
2855         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.h:
2856
2857         * Modules/indexeddb/leveldb/IDBLevelDBCoding.cpp:
2858         * Modules/indexeddb/leveldb/IDBLevelDBCoding.h:
2859
2860         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.cpp:
2861         (WebCore::IDBTransactionBackendLevelDB::create):
2862         (WebCore::IDBTransactionBackendLevelDB::IDBTransactionBackendLevelDB):
2863         (WebCore::IDBTransactionBackendLevelDB::scheduleVersionChangeOperation):
2864         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.h:
2865
2866         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.cpp:
2867         (WebCore::IDBDatabaseBackendImpl::VersionChangeOperation::perform):
2868         (WebCore::IDBDatabaseBackendImpl::VersionChangeAbortOperation::perform):
2869         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.h:
2870
2871 2013-10-23  Daniel Bates  <dabates@apple.com>
2872
2873         [iOS] Upstream more ARMv7s bits
2874         https://bugs.webkit.org/show_bug.cgi?id=123052
2875
2876         Reviewed by Joseph Pecoraro.
2877
2878         Define exported symbol file for armv7s and arm64.
2879
2880         * Configurations/WebCore.xcconfig:
2881
2882 2013-10-23  Krzysztof Wolanski  <k.wolanski@samsung.com>
2883
2884         [GTK] accessibility/self-referencing-aria-labelledby.html is failing
2885         https://bugs.webkit.org/show_bug.cgi?id=121594
2886
2887         Reviewed by Mario Sanchez Prada.
2888
2889         According to http://www.w3.org/TR/REC-html40/struct/objects.html#edef-IMG
2890         description of image element should be determined by alt attribute, then
2891         if it is empty by title attributte.
2892
2893         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2894         (webkitAccessibleGetDescription):
2895
2896 2013-10-15  Andreas Kling  <akling@apple.com>
2897
2898         Tighten animation-driven restyle to operate on Element only.
2899         <https://webkit.org/b/122820>
2900
2901         Text nodes are never directly animated, so we can tighten this code
2902         to work on Element only. This happens naturally since the code was
2903         already working with RenderElement everywhere.
2904
2905         Reviewed by Antti Koivisto.
2906
2907 2013-10-22  Andreas Kling  <akling@apple.com>
2908
2909         Even more PassRef<RenderStyle>!
2910         <https://webkit.org/b/123147>
2911
2912         Convert more of the WebCore code to use PassRef for RenderStyle
2913         in places where they are known to be non-null.
2914
2915         Re-landing this without region styling since that caused some
2916         assertions last time.
2917
2918         Reviewed by Antti Koivisto.
2919
2920 2013-10-22  Zoltan Horvath  <zoltan@webkit.org>
2921
2922         Refactor LineBreaker::nextSegmentBreak, add BreakingContext that holds all its state
2923         https://bugs.webkit.org/show_bug.cgi?id=123038
2924
2925         Reviewed by David Hyatt.
2926
2927         I followed Levi's logic on Blink's nextSegmentBreak refactoring (https://chromiumcodereview.appspot.com/25054004). 
2928         I mostly did the same changes, but the code is too diverged at this point to just apply that patch on our trunk. The patch
2929         introduces BreakingContext as a separate class. I added new methods for each condition, which were originally located in
2930         nextSegmentBreak. I also removed the goto-s from the code. All the new methods are inline in order to avoid introducing any
2931         performance regression. The change makes the code so much cleaner and understandable.
2932
2933         This change would be the first step of the nextSegmentBreak refactoring, I wanted to keep things in place in RenderBlockLineLayout.cpp
2934         for now, but I'm planning to separate BreakingContext into a new file and do additional changes to make things nicer. I'm tracking
2935         the entire progress under http://webkit.org/b/121261 meta bug.
2936
2937         No new tests, covered by existing tests.
2938         - I updated 1 expected result, because there was a 1 pixel difference on the result, which I believe comes from a rounding situation.
2939
2940         * rendering/RenderBlockFlow.h:
2941         * rendering/RenderBlockLineLayout.cpp:
2942         (WebCore::BreakingContext::BreakingContext):
2943         (WebCore::BreakingContext::currentObject):
2944         (WebCore::BreakingContext::lineBreak):
2945         (WebCore::BreakingContext::lineBreakRef):
2946         (WebCore::BreakingContext::lineWidth):
2947         (WebCore::BreakingContext::atEnd):
2948         (WebCore::BreakingContext::clearLineBreakIfFitsOnLine):
2949         (WebCore::BreakingContext::commitLineBreakAtCurrentWidth):
2950         (WebCore::BreakingContext::initializeForCurrentObject):
2951         (WebCore::BreakingContext::increment):
2952         (WebCore::BreakingContext::handleBR):
2953         (WebCore::BreakingContext::handleOutOfFlowPositioned):
2954         (WebCore::BreakingContext::handleFloat):
2955         (WebCore::BreakingContext::handleEmptyInline):
2956         (WebCore::BreakingContext::handleReplaced):
2957         (WebCore::nextCharacter):
2958         (WebCore::BreakingContext::handleText):
2959         (WebCore::textBeginsWithBreakablePosition):
2960         (WebCore::BreakingContext::canBreakAtThisPosition):
2961         (WebCore::BreakingContext::commitAndUpdateLineBreakIfNeeded):
2962         (WebCore::BreakingContext::handleEndOfLine):
2963         (WebCore::LineBreaker::nextSegmentBreak):
2964
2965 2013-10-22  Commit Queue  <commit-queue@webkit.org>
2966
2967         Unreviewed, rolling out r157826.
2968         http://trac.webkit.org/changeset/157826
2969         https://bugs.webkit.org/show_bug.cgi?id=123197
2970
2971         Caused some regions tests to assert (Requested by smfr on
2972         #webkit).
2973
2974         * dom/Document.cpp:
2975         (WebCore::Document::styleForElementIgnoringPendingStylesheets):
2976         * dom/Document.h:
2977         * dom/Element.cpp:
2978         (WebCore::Element::styleForRenderer):
2979         * dom/Element.h:
2980         * dom/ElementRareData.h:
2981         (WebCore::ElementRareData::setComputedStyle):
2982         (WebCore::ElementRareData::resetComputedStyle):
2983         * html/HTMLTitleElement.cpp:
2984         (WebCore::HTMLTitleElement::textWithDirection):
2985         * page/animation/AnimationController.cpp:
2986         (WebCore::AnimationController::updateAnimations):
2987         * page/animation/CompositeAnimation.cpp:
2988         (WebCore::CompositeAnimation::animate):
2989         * page/animation/CompositeAnimation.h:
2990         * rendering/RenderElement.cpp:
2991         (WebCore::RenderElement::createFor):
2992         * rendering/RenderElement.h:
2993         (WebCore::RenderElement::setStyleInternal):
2994         * rendering/RenderRegion.cpp:
2995         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
2996         (WebCore::RenderRegion::restoreRegionObjectsOriginalStyle):
2997         (WebCore::RenderRegion::computeStyleInRegion):
2998         (WebCore::RenderRegion::computeChildrenStyleInRegion):
2999         (WebCore::RenderRegion::setObjectStyleInRegion):
3000         * rendering/RenderRegion.h:
3001         * style/StyleResolveTree.cpp:
3002         (WebCore::Style::resolveLocal):
3003
3004 2013-10-22  Ryuan Choi  <ryuan.choi@samsung.com>
3005
3006         [EFL] Remove HAVE_GLX macro
3007         https://bugs.webkit.org/show_bug.cgi?id=123191
3008
3009         Reviewed by Gyuyoung Kim.
3010
3011         Since r138313, HAVE(GLX) was replaced to USE(GLX) except in GraphicsSurfaceToken.h.
3012
3013         * platform/graphics/surfaces/GraphicsSurfaceToken.h:
3014         Replace HAVE(GLX) to USE(GLX)
3015
3016 2013-10-22  Mark Lam  <mark.lam@apple.com>
3017
3018         Gardening: fix broken build on Windows.
3019         https://bugs.webkit.org/show_bug.cgi?id=123174.
3020
3021         Not reviewed.
3022
3023         No new tests.
3024
3025         * WebCore.vcxproj/WebCore.vcxproj:
3026         * WebCore.vcxproj/WebCore.vcxproj.filters:
3027
3028 2013-10-22  Brady Eidson  <beidson@apple.com>
3029
3030         Get rid of IDBObjectStoreBackendLevelDB
3031         https://bugs.webkit.org/show_bug.cgi?id=123174
3032
3033         Reviewed by Tim Horton.
3034
3035         This file was kind of a dumping ground.
3036         Its contents can be merged into IDBBackingStoreInterface and a new IDBIndexWriter class.
3037
3038         Also took the opportunity to do a little bit of RefPtr<> and pointer-vs-reference cleanup.
3039
3040         * CMakeLists.txt:
3041         * GNUmakefile.list.am:
3042         * WebCore.xcodeproj/project.pbxproj:
3043
3044         * Modules/indexeddb/leveldb/IDBObjectStoreBackendLevelDB.cpp: Removed.
3045         * Modules/indexeddb/leveldb/IDBObjectStoreBackendLevelDB.h: Removed.
3046
3047         * Modules/indexeddb/IDBIndexWriter.cpp: Added.
3048         (WebCore::IDBIndexWriter::IDBIndexWriter):
3049         (WebCore::IDBIndexWriter::writeIndexKeys):
3050         (WebCore::IDBIndexWriter::verifyIndexKeys):
3051         (WebCore::IDBIndexWriter::addingKeyAllowed):
3052         * Modules/indexeddb/IDBIndexWriter.h: Added.
3053         (WebCore::IDBIndexWriter::create):
3054
3055         * Modules/indexeddb/IDBBackingStoreInterface.h:
3056         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
3057
3058         * Modules/indexeddb/IDBMetadata.h:
3059         * Modules/indexeddb/IDBTransactionBackendInterface.h:
3060
3061         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
3062         (WebCore::IDBBackingStoreLevelDB::makeIndexWriters):
3063         (WebCore::IDBBackingStoreLevelDB::generateKey):
3064         (WebCore::IDBBackingStoreLevelDB::updateKeyGenerator):
3065         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
3066
3067         * Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.cpp:
3068         (WebCore::IDBDatabaseBackendLevelDB::setIndexKeys):
3069         (WebCore::IDBDatabaseBackendLevelDB::setIndexesReady):
3070         * Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.h:
3071
3072         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.cpp:
3073         (WebCore::IDBTransactionBackendLevelDB::schedulePutOperation):
3074         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.h:
3075
3076         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.cpp:
3077         (WebCore::PutOperation::perform):
3078         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.h:
3079         (WebCore::PutOperation::create):
3080         (WebCore::PutOperation::PutOperation):
3081
3082 2013-10-22  Dean Jackson  <dino@apple.com>
3083
3084         [WebGL] Implement a software rendering option on Mac
3085         https://bugs.webkit.org/show_bug.cgi?id=123177
3086
3087         Reviewed by Tim Horton.
3088
3089         Implement a way to force software OpenGL rendering
3090         for WebGL, via a Setting/Preference.
3091
3092         No new tests. We intentionally hide the capabilities of
3093         the renderer from the content, so you can't test for
3094         this setting. However, manual inspection is pretty
3095         obvious. Just go to a page with a complex shader
3096         such as https://www.shadertoy.com/view/lss3WS.
3097
3098         * html/canvas/WebGLRenderingContext.cpp:
3099         (WebCore::WebGLRenderingContext::create): If we're forcing software
3100         rendering, mark the context attributes as such.
3101         * page/Settings.in: New setting key.
3102         * platform/graphics/GraphicsContext3D.h: New flag in Attributes.
3103         (WebCore::GraphicsContext3D::Attributes::Attributes):
3104         * platform/graphics/mac/GraphicsContext3DMac.mm:
3105         (WebCore::GraphicsContext3D::GraphicsContext3D): Slight update to the
3106         algorithm that sets a pixel format. If we're forcing software rendering,
3107         obviously we never want to create an accelerated pixel format.
3108         * platform/graphics/filters/CustomFilterGlobalContext.cpp:
3109         (WebCore::CustomFilterGlobalContext::prepareContextIfNeeded): Set the attribute
3110         here before trying to create the context.
3111         * platform/graphics/filters/CustomFilterGlobalContext.h: Add a forceSoftwareRendering
3112         flag to prepareContextIfNeeded.
3113         * rendering/FilterEffectRenderer.cpp:
3114         (WebCore::createCustomFilterEffect): Check the Setting before creating a custom
3115         filter context.
3116
3117 2013-10-22  Anders Carlsson  <andersca@apple.com>
3118
3119         Revert r157445 since it broke certificates on Mac.
3120         <rdar://problem/15246926&15254017&15269117>
3121
3122         * GNUmakefile.list.am:
3123         * PlatformEfl.cmake:
3124         * WebCore.exp.in:
3125         * WebCore.vcxproj/WebCore.vcxproj:
3126         * WebCore.vcxproj/WebCore.vcxproj.filters:
3127         * WebCore.xcodeproj/project.pbxproj:
3128         * platform/network/ResourceErrorBase.h:
3129         * platform/network/ResourceResponseBase.h:
3130         * platform/network/cf/CertificateInfoCFNet.cpp: Removed.
3131         * platform/network/cf/ResourceResponse.h:
3132         * platform/network/mac/ResourceResponseMac.mm:
3133         (WebCore::ResourceResponse::setCertificateChain):
3134         (WebCore::ResourceResponse::certificateChain):
3135         * platform/network/soup/ResourceError.h:
3136         (WebCore::ResourceError::ResourceError):
3137         (WebCore::ResourceError::tlsErrors):
3138         (WebCore::ResourceError::setTLSErrors):
3139         (WebCore::ResourceError::certificate):
3140         (WebCore::ResourceError::setCertificate):
3141         * platform/network/soup/ResourceErrorSoup.cpp:
3142         (WebCore::ResourceError::tlsError):
3143         (WebCore::ResourceError::platformCopy):
3144         (WebCore::ResourceError::platformCompare):
3145         * platform/network/soup/ResourceResponse.h:
3146         (WebCore::ResourceResponse::ResourceResponse):
3147         (WebCore::ResourceResponse::soupMessageCertificate):
3148         (WebCore::ResourceResponse::setSoupMessageCertificate):
3149         (WebCore::ResourceResponse::soupMessageTLSErrors):
3150         (WebCore::ResourceResponse::setSoupMessageTLSErrors):
3151         * platform/network/soup/ResourceResponseSoup.cpp:
3152         (WebCore::ResourceResponse::toSoupMessage):
3153         (WebCore::ResourceResponse::updateFromSoupMessage):
3154
3155 2013-10-22  Jer Noble  <jer.noble@apple.com>
3156
3157         [Media] Refactor supportsType() factory method to take a parameters object.
3158         https://bugs.webkit.org/show_bug.cgi?id=122489
3159
3160         Reviewed by Eric Carlson.
3161
3162         In order to support adding new conditional properties with which to decide
3163         what MediaPlayerPrivate subclass to create, replace the two versions of the
3164         supportsType() factory method with a single one taking a parameters object.
3165
3166         At the same time, add a 'isMediaSource' parameter to that object, allowing
3167         MediaPlayerPrivate subclasses which support the same type and codecs but
3168         which do not both support MediaSource to be distinguised.
3169
3170         * platform/graphics/MediaPlayer.cpp:
3171         (WebCore::bestMediaEngineForSupportParameters): Renamed from
3172             bestMediaEngineForTypeAndCodecs.
3173         (WebCore::MediaPlayer::nextBestMediaEngine): Added convenience function.
3174         (WebCore::MediaPlayer::loadWithNextMediaEngine): Call nextBestMediaEngine()
3175         (WebCore::MediaPlayer::supportsType): Pass parameter object.
3176         (WebCore::MediaPlayer::networkStateChanged): Call nextBestMediaEngine().
3177         * platform/graphics/MediaPlayer.h:
3178         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3179         (WebCore::MediaPlayerPrivateAVFoundationCF::supportsType): Handle parameter object.
3180         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
3181         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
3182         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3183         (WebCore::MediaPlayerPrivateAVFoundationObjC::registerMediaEngine): Remove extraneous
3184             extendedSupportsType method.
3185         (WebCore::MediaPlayerPrivateAVFoundationObjC::supportsType): Handle parameter object.
3186         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
3187         (WebCore::MediaPlayerPrivate::supportsType): Ditto.
3188         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
3189         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3190         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
3191         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3192         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3193         (WebCore::MediaPlayerPrivateQTKit::registerMediaEngine): Remove extraneous
3194             extendedSupportsType method.
3195         (WebCore::MediaPlayerPrivateQTKit::supportsType): Handle parameter object.
3196         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
3197         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::supportsType): Ditto.
3198         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
3199         * platform/graphics/wince/MediaPlayerPrivateWinCE.h:
3200
3201 2013-10-22  Andreas Kling  <akling@apple.com>
3202
3203         Merge SVGRenderBlock::styleWillChange() into styleDidChange().
3204         <https://webkit.org/b/123181>
3205
3206         I meant to do this one in r157787, but better late than never.
3207
3208         Reviewed by Geoffrey Garen.
3209
3210 2013-10-22  Sam Weinig  <sam@webkit.org>
3211
3212         CTTE: Modernize RenderBlock a bit
3213         https://bugs.webkit.org/show_bug.cgi?id=123162
3214
3215         Reviewed by Andreas Kling.
3216
3217         Start threading references through RenderBlock. While we 
3218         are here, do some selective modernization as well.
3219
3220 2013-10-22  Andreas Kling  <akling@apple.com>
3221
3222         Even more PassRef<RenderStyle>!
3223         <https://webkit.org/b/123147>
3224
3225         Convert the remaining WebCore code to use PassRef for RenderStyle
3226         wherever they are known to be non-null.
3227
3228         Reviewed by Antti Koivisto.
3229
3230 2013-10-22  Commit Queue  <commit-queue@webkit.org>
3231
3232         Unreviewed, rolling out r157819.
3233         http://trac.webkit.org/changeset/157819
3234         https://bugs.webkit.org/show_bug.cgi?id=123180
3235
3236         Broke 32-bit builds (Requested by smfr on #webkit).
3237
3238         * Configurations/WebCore.xcconfig:
3239
3240 2013-10-22  Antti Koivisto  <antti@apple.com>
3241
3242         Rename deleteLineBoxTree to deleteLines
3243         https://bugs.webkit.org/show_bug.cgi?id=123176
3244
3245         Reviewed by Andreas Kling.
3246
3247         RenderBlock::deleteLineBoxTree -> RenderBlock::deleteLines
3248         RenderInline::deleteLineBoxTree -> RenderInline::deleteLines
3249
3250 2013-10-22  Tim Horton  <timothy_horton@apple.com>
3251
3252         {ClipPathOperation, FilterOperation}::getOperationType() should not include 'get'
3253         https://bugs.webkit.org/show_bug.cgi?id=123172
3254
3255         Reviewed by Simon Fraser.
3256
3257         No new tests, just a rename.
3258
3259         "get" in WebCore tends to mean that the function has out arguments; these have no arguments.
3260         Rename FilterOperation::getOperationType() to FilterOperation::type().
3261         I noticed that ClipPathOperation had the same mistake, so I fixed it there too.
3262
3263         Removed long and useless list of files.
3264
3265 2013-10-22  Samuel White  <samuel_white@apple.com>
3266
3267         AX: Add paramAttrs to fetch start and end text markers in a given rect.
3268         https://bugs.webkit.org/show_bug.cgi?id=122164
3269
3270         Reviewed by Chris Fleizach.
3271
3272         Added ability to fetch end and start text markers inside a given bounds. This gives ScreenReaders
3273         like VoiceOver a way to retrieve the text markers for a specified column of page text.
3274
3275         Test: platform/mac/accessibility/text-marker-for-bounds.html
3276
3277         * accessibility/AccessibilityObject.cpp:
3278         (WebCore::AccessibilityObject::mainFrame):
3279         (WebCore::AccessibilityObject::topDocument):
3280         (WebCore::AccessibilityObject::visiblePositionForBounds):
3281         * accessibility/AccessibilityObject.h:
3282         * accessibility/AccessibilityRenderObject.cpp:
3283         * accessibility/AccessibilityRenderObject.h:
3284         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
3285         (-[WebAccessibilityObjectWrapper screenToContents:]):
3286         (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
3287         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
3288
3289 2013-10-22  Zoltan Horvath  <zoltan@webkit.org>
3290
3291         [CSS Shapes] Match adjustLogicalLineTopAndLogicalHeightIfNeeded's implementation with Blink's
3292         https://bugs.webkit.org/show_bug.cgi?id=123033
3293
3294         Reviewed by David Hyatt.
3295
3296         In Blink I made this function in a bit different way. This change modifies it
3297         to be identical, which helps a lot in the future cross-merging patches.
3298
3299         No new tests, covered by existing texts.
3300
3301         * rendering/RenderBlockLineLayout.cpp:
3302         (WebCore::RenderBlockFlow::adjustLogicalLineTopAndLogicalHeightIfNeeded):
3303
3304 2013-10-22  Daniel Bates  <dabates@apple.com>
3305
3306         [iOS] Upstream more ARMv7s bits
3307         https://bugs.webkit.org/show_bug.cgi?id=123052
3308
3309         Reviewed by Joseph Pecoraro.
3310
3311         * Configurations/WebCore.xcconfig:
3312
3313 2013-10-22  Simon Fraser  <simon.fraser@apple.com>
3314
3315         Try to fix Mavericks build; use <> for framework include.
3316
3317         * page/CaptionUserPreferencesMediaAF.cpp:
3318
3319 2013-10-22  Tim Horton  <timothy_horton@apple.com>
3320
3321         GammaFilterOperation seems to be dead code
3322         https://bugs.webkit.org/show_bug.cgi?id=123173
3323
3324         Reviewed by Simon Fraser.
3325
3326         * platform/graphics/filters/FilterOperation.cpp:
3327         * platform/graphics/filters/FilterOperation.h:
3328         Remove dead code.
3329
3330 2013-10-22  Antti Koivisto  <antti@apple.com>
3331
3332         Rename some line box functions to be just about lines
3333         https://bugs.webkit.org/show_bug.cgi?id=123168
3334
3335         Reviewed by Dave Hyatt.
3336
3337         firstLineBoxBaseline -> firstLineBaseline
3338         hasInlineBoxChildren -> hasLines
3339         
3340         Also use hasLines in a bunch of places where firstLineBox() was used.
3341
3342         * accessibility/AccessibilityRenderObject.cpp:
3343         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
3344         
3345             Also use hasRenderedText() instead of firstTextBox()
3346
3347         * rendering/RenderFullScreen.cpp:
3348         
3349             Fix namespace.
3350
3351 2013-10-22  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3352
3353         Adding Mock class to test RTCPeerConnection
3354         https://bugs.webkit.org/show_bug.cgi?id=122848
3355
3356         Reviewed by Eric Carlson.
3357
3358         The following tests can be run:
3359
3360             RTCPeerConnection-createAnswer.html
3361             RTCPeerConnection-createOffer.html
3362             RTCPeerConnection-ice.html
3363             RTCPeerConnection-localDescription.html
3364             RTCPeerConnection-remoteDescription.html
3365             RTCPeerConnection-state.html
3366
3367         Tests that require a MediaStream object, by invoking getUserMedia,
3368         are not ready to run yet.
3369
3370         No new tests needed.
3371
3372         * CMakeLists.txt:
3373         * platform/mediastream/RTCPeerConnectionHandler.cpp:
3374         (WebCore::createHandler):
3375         * platform/mediastream/RTCPeerConnectionHandler.h:
3376         * platform/mediastream/RTCPeerConnectionHandlerClient.h:
3377         * platform/mock/RTCNotifiersMock.cpp: Added.
3378         * platform/mock/RTCNotifiersMock.h: Added.
3379         * platform/mock/RTCPeerConnectionHandlerMock.cpp: Added.
3380         * platform/mock/RTCPeerConnectionHandlerMock.h: Copied from Source/WebCore/platform/mediastream/RTCPeerConnectionHandler.h.
3381         * platform/mock/TimerEventBasedMock.h: Added.
3382         * testing/Internals.cpp:
3383         (WebCore::Internals::Internals):
3384         (WebCore::Internals::enableMockRTCPeerConnectionHandler):
3385         * testing/Internals.h:
3386
3387 2013-10-22  Zan Dobersek  <zdobersek@igalia.com>
3388
3389         WebCore::fillWithEmptyClients adopts new empty clients before leaking their pointers
3390         https://bugs.webkit.org/show_bug.cgi?id=122945
3391
3392         Reviewed by Anders Carlsson.
3393
3394         * loader/EmptyClients.cpp:
3395         (WebCore::fillWithEmptyClients): Store the static empty clients as NeverDestroyed, rather than
3396         adopting the pointer of each heap-allocated object and then immediately leaking that pointer.
3397
3398 2013-10-22  Zan Dobersek  <zdobersek@igalia.com>
3399
3400         Simplify HRTFDatabaseLoader's load map
3401         https://bugs.webkit.org/show_bug.cgi?id=122944
3402
3403         Reviewed by Eric Carlson.
3404
3405         * platform/audio/HRTFDatabaseLoader.cpp:
3406         (WebCore::loaderMap): Return a reference to a NeverDestroyed HashMap that maps sample rates to loaders.
3407         (WebCore::HRTFDatabaseLoader::createAndLoadAsynchronouslyIfNecessary):
3408         (WebCore::HRTFDatabaseLoader::~HRTFDatabaseLoader):
3409         * platform/audio/HRTFDatabaseLoader.h: Remove the LoaderMap type definition, the private singleton of that type
3410         and the singleton's unused getter.
3411
3412 2013-10-22  Tim Horton  <timothy_horton@apple.com>
3413
3414         Remote Layer Tree: Support hardware accelerated filters
3415         https://bugs.webkit.org/show_bug.cgi?id=123139
3416
3417         Reviewed by Anders Carlsson.
3418
3419         * WebCore.exp.in:
3420         Export a variety of filter-related things.
3421
3422         * platform/graphics/ca/PlatformCAFilters.h:
3423         * platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
3424         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
3425         (PlatformCALayerMac::setFilters):
3426         * platform/graphics/ca/win/PlatformCAFiltersWin.cpp:
3427         (PlatformCAFilters::setFiltersOnLayer):
3428         setFiltersOnLayer should take a PlatformLayer instead of a PlatformCALayer
3429         as its argument, because it doesn't need a PlatformCALayer, and this way
3430         we can share code with the RemoteLayerTreeHost, which only has PlatformLayers
3431         and not PlatformCALayers.
3432
3433 2013-10-22  Brendan Long  <b.long@cablelabs.com>
3434
3435         cue.text fails for some track element cues
3436         https://bugs.webkit.org/show_bug.cgi?id=81123
3437
3438         Reviewed by Eric Carlson.
3439
3440         Test: media/track/track-long-captions-file.html
3441
3442         * html/track/WebVTTParser.cpp:
3443         (WebCore::WebVTTParser::parseBytes): Use buffer when we don't have full lines.
3444         (WebCore::WebVTTParser::fileFinished): Force file to finish parsing.
3445         (WebCore::WebVTTParser::hasRequiredFileIdentifier): Simplify due to using String.
3446         (WebCore::WebVTTParser::collectCueText): Don't automatically create cues when we run out of data.
3447         (WebCore::WebVTTParser::collectNextLine): Use buffer.
3448         * html/track/WebVTTParser.h: Add m_buffer and Finished state.
3449         * loader/TextTrackLoader.cpp:
3450         (WebCore::TextTrackLoader::notifyFinished): Call m_parser->fileFinished() when done.
3451
3452 2013-10-22  peavo@outlook.com  <peavo@outlook.com>
3453
3454         [WinCairo] Compile error.
3455         https://bugs.webkit.org/show_bug.cgi?id=123161
3456
3457         Reviewed by Brent Fulgham.
3458
3459         * rendering/RenderFlowThread.h: Move USE(ACCELERATED_COMPOSITING) guard to expose needed type.
3460
3461 2013-10-21  Brady Eidson  <beidson@apple.com>
3462
3463         Add a cross-platform IDBRecordIdentifier
3464         https://bugs.webkit.org/show_bug.cgi?id=123138
3465
3466         Reviewed by Andreas Kling.
3467
3468         Add the cross-platform header:
3469         * Modules/indexeddb/IDBRecordIdentifier.h: Added.
3470         (WebCore::IDBRecordIdentifier::create):
3471         (WebCore::IDBRecordIdentifier::encodedPrimaryKey):
3472         (WebCore::IDBRecordIdentifier::version):
3473         (WebCore::IDBRecordIdentifier::reset):
3474         (WebCore::IDBRecordIdentifier::IDBRecordIdentifier):
3475         * WebCore.xcodeproj/project.pbxproj:
3476         * GNUmakefile.list.am:
3477
3478         Remove the old abstract and LevelDB classes:
3479         * Modules/indexeddb/IDBBackingStoreInterface.h:
3480         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
3481
3482         Use the cross-platform one everywhere:
3483         * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
3484         (WebCore::IDBBackingStoreLevelDB::putRecord):
3485         (WebCore::IDBBackingStoreLevelDB::deleteRecord):
3486         (WebCore::IDBBackingStoreLevelDB::keyExistsInObjectStore):
3487         (WebCore::IDBBackingStoreLevelDB::putIndexDataForRecord):
3488         (WebCore::ObjectStoreKeyCursorImpl::loadCurrentRow):
3489         (WebCore::ObjectStoreCursorImpl::loadCurrentRow):
3490
3491         * Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.cpp:
3492         (WebCore::IDBDatabaseBackendLevelDB::setIndexKeys):
3493
3494         * Modules/indexeddb/leveldb/IDBObjectStoreBackendLevelDB.cpp:
3495         (WebCore::IDBObjectStoreBackendLevelDB::IndexWriter::writeIndexKeys):
3496
3497         * Modules/indexeddb/leveldb/IDBObjectStoreBackendLevelDB.h:
3498         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.cpp:
3499         (WebCore::PutOperation::perform):
3500
3501 2013-10-22  Andrei Bucur  <abucur@adobe.com>
3502
3503         [CSS Regions] Possible performance regression after r157567
3504         https://bugs.webkit.org/show_bug.cgi?id=123016
3505
3506         Reviewed by Andreas Kling.
3507
3508         The revision 157567 http://trac.webkit.org/changeset/157567 may have regressed
3509         Parser/html5-full-render by ~1.1% and Parser/html-parser by ~2%. These changes
3510         try to optimize the initial patch, based on Andreas Kling's review.
3511
3512         The patch also adds a couple of refactorings that should make the code easier to read:
3513         - the CSS Shapes functions are now wrapped in a single #if clause
3514         - the CSS Shapes and CSS Regions pre-layout preparations are wrapped in a helper function
3515
3516         The RenderFlowThread::logicalWidthChangedInRegionsForBlock function is optimized by passing
3517         it information about the state of the relayout children flag. If the flag is true already,
3518         some of the steps are skipped.
3519
3520         Tests: no new tests.
3521
3522         * dom/Element.cpp:
3523         (WebCore::Element::webkitGetRegionFlowRanges):
3524         * inspector/InspectorOverlay.cpp:
3525         (WebCore::buildObjectForElementInfo):
3526         * rendering/RenderBlock.cpp:
3527         (WebCore::shapeInfoRequiresRelayout):
3528         (WebCore::RenderBlock::updateShapesBeforeBlockLayout):
3529         (WebCore::RenderBlock::computeShapeSize):
3530         (WebCore::RenderBlock::prepareShapesAndPaginationBeforeBlockLayout):
3531         * rendering/RenderBlock.h:
3532         * rendering/RenderBlockFlow.cpp:
3533         (WebCore::RenderBlockFlow::layoutBlock):
3534         (WebCore::RenderBlockFlow::createRenderNamedFlowFragmentIfNeeded):
3535         (WebCore::RenderBlockFlow::setRenderNamedFlowFragment):
3536         (WebCore::RenderBlockFlow::ensureRareData):
3537         * rendering/RenderBlockFlow.h:
3538         (WebCore::RenderBlockFlow::RenderBlockFlowRareData::RenderBlockFlowRareData):
3539         (WebCore::RenderElement::isRenderNamedFlowFragmentContainer):
3540         * rendering/RenderDeprecatedFlexibleBox.cpp:
3541         (WebCore::RenderDeprecatedFlexibleBox::layoutBlock):
3542         * rendering/RenderElement.h:
3543         (WebCore::RenderElement::generatingElement):
3544         * rendering/RenderFlexibleBox.cpp:
3545         (WebCore::RenderFlexibleBox::layoutBlock):
3546         * rendering/RenderFlowThread.cpp:
3547         (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
3548         * rendering/RenderFlowThread.h:
3549         * rendering/RenderGrid.cpp:
3550         (WebCore::RenderGrid::layoutBlock):
3551         * rendering/RenderNamedFlowFragment.h:
3552         * rendering/RenderObject.cpp:
3553         * rendering/RenderObject.h:
3554         * rendering/RenderTreeAsText.cpp:
3555         (WebCore::write):
3556         * style/StyleResolveTree.cpp:
3557         (WebCore::Style::elementInsideRegionNeedsRenderer):
3558
3559 2013-10-22  Andreas Kling  <akling@apple.com>
3560
3561         CSSStyleSheet constructor functions should return PassRef.
3562         <https://webkit.org/b/123156>
3563
3564         Make CSSStyleSheet::create*() return PassRef and tighten some call
3565         sites that were using them. Most callers didn't need any tweaks to
3566         take advantage of PassRef.
3567
3568         Reviewed by Antti Koivisto.
3569
3570 2013-10-22  Andreas Kling  <akling@apple.com>
3571
3572         CTTE: RenderMathMLFraction always has a MathMLInlineContainerElement.
3573         <https://webkit.org/b/123154>
3574
3575         This renderer is never anonymous and always has a corresponding
3576         MathMLInlineContainerElement. Overload element() with a tighter
3577         return type.
3578
3579         Also marked the class FINAL and made most member functions private.
3580
3581         Reviewed by Antti Koivisto.
3582
3583 2013-10-22  Andreas Kling  <akling@apple.com>
3584
3585         FontGlyphs constructor functions should return PassRef.
3586         <https://webkit.org/b/123159>
3587
3588         Made the two FontGlyphs creator functions return PassRef and tweaked
3589         the FontGlyphsCache in Font.cpp to make more efficient use of it.
3590
3591         Reviewed by Antti Koivisto.
3592
3593 2013-10-22  Andreas Kling  <akling@apple.com>
3594
3595         Fix some more code to use RenderElement instead of RenderObject.
3596         <https://webkit.org/b/123149>
3597
3598         Using RenderElement where possible lets us skip the isRenderElement()
3599         branch in RenderObject::style() and generates much tighter code.
3600
3601         Reviewed by Antti Koivisto.
3602
3603 2013-10-22  Andreas Kling  <akling@apple.com>
3604
3605         Merge SVG renderers' styleWillChange() into styleDidChange().
3606         <https://webkit.org/b/123108>
3607
3608         This work can just as well be done after setting the style.
3609         Three more styleWillChange() overloads gone.
3610
3611         Reviewed by Antti Koivisto.
3612
3613 2013-10-22  Andreas Kling  <akling@apple.com>
3614
3615         CSSValueList constructor functions should return PassRef.
3616         <https://webkit.org/b/123151>
3617
3618         These functions always return objects, and thus can return PassRef.
3619         Also made CSSValueList::createFromParserValueList() take a reference
3620         since that function is only ever called with a non-null value.
3621
3622         Reviewed by Antti Koivisto.
3623
3624 2013-10-22  Andreas Kling  <akling@apple.com>
3625
3626         Avoid parent style ref churn in createTextRendererIfNeeded().
3627         <https://webkit.org/b/123148>
3628
3629         There's no need to take a temporary ref on the parent's RenderStyle
3630         while creating a text renderer. It's not going away, and the text
3631         renderer is not going to participate in ownership afterwards.
3632
3633         Reviewed by Antti Koivisto.
3634
3635 2013-10-22  Andreas Kling  <akling@apple.com>
3636
3637         Remove some unnecessary null checks in RenderElement::setStyle().
3638         <https://webkit.org/b/123146>
3639
3640         After assigning the new style to RenderElement::m_style, we know that
3641         it'll be non-null, so remove all the checking for this.
3642
3643         Reviewed by Antti Koivisto.
3644
3645 2013-10-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3646
3647         Introduce ACCESSIBILITY_OBJECT_TYPE_CASTS to replace manual toFoo() in accessibility child class
3648         https://bugs.webkit.org/show_bug.cgi?id=123140
3649
3650         Reviewed by Andreas Kling.
3651
3652         As a step to let toFoo use TYPE_CASTS_BASE, DEFINE_TYPE_CASTS can be used for toFoo() in accessibility
3653         child class. The DEFINE_TYPE_CASTS will generate plenty more helper functions for accessibility type cast.
3654
3655         No new tests, no behavior changes.
3656
3657         * accessibility/AccessibilityList.h:
3658         * accessibility/AccessibilityMenuList.h:
3659         * accessibility/AccessibilityMockObject.h:
3660         * accessibility/AccessibilityNodeObject.h:
3661         * accessibility/AccessibilityObject.h:
3662         * accessibility/AccessibilityRenderObject.h:
3663         * accessibility/AccessibilitySVGRoot.h:
3664         * accessibility/AccessibilityScrollView.h:
3665         * accessibility/AccessibilitySpinButton.h:
3666         * accessibility/AccessibilityTable.h:
3667
3668 2013-10-22  Brian Holt  <brian.holt@samsung.com>
3669
3670         [GTK] Add WebKit2 API for TLS errors
3671         https://bugs.webkit.org/show_bug.cgi?id=120160
3672
3673         Reviewed by Carlos Garcia Campos.
3674
3675         Added a new constructor for CertificateInfo under Soup.
3676
3677         * platform/network/CertificateInfo.h:
3678         * platform/network/soup/CertificateInfoSoup.cpp:
3679         (WebCore::CertificateInfo::CertificateInfo): New constructor using
3680         GTlsCertificateFlags and GTlsCertificate.
3681
3682 2013-10-22  Mihnea Ovidenie  <mihnea@adobe.com>
3683
3684         [CSSRegions] Use RenderStyle::hasFlowFrom when needed
3685         https://bugs.webkit.org/show_bug.cgi?id=122543
3686
3687         Reviewed by David Hyatt.
3688
3689         Rename RenderStyle::hasStyleRegion -> RenderStyle::hasFlowFrom.
3690         Use RenderStyle::hasFlowFrom() helper function instead of directly
3691         checking the value of RenderStyle::regionThread().
3692
3693         No change of functionality, covered by existing tests.
3694
3695         * css/CSSComputedStyleDeclaration.cpp:
3696         (WebCore::contentToCSSValue):
3697         (WebCore::ComputedStyleExtractor::propertyValue):
3698         * css/StyleResolver.cpp:
3699         (WebCore::StyleResolver::adjustRenderStyle):
3700         * dom/PseudoElement.cpp:
3701         (WebCore::PseudoElement::didAttachRenderers):
3702         * dom/PseudoElement.h:
3703         (WebCore::pseudoElementRendererIsNeeded):
3704         * rendering/RenderBlockFlow.cpp:
3705         (WebCore::RenderBlockFlow::createRenderNamedFlowFragmentIfNeeded):
3706         * rendering/RenderLayer.cpp:
3707         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
3708         * rendering/style/RenderStyle.h:
3709
3710 2013-10-21  Brent Fulgham  <bfulgham@apple.com>
3711
3712         [WIN] Properly support reverse animations without needing software fallback.
3713         https://bugs.webkit.org/show_bug.cgi?id=85121
3714
3715         Reviewed by Dean Jackson.
3716
3717         Testing is provided by existing animation tests.
3718
3719         * platform/animation/TimingFunction.h:
3720         (WebCore::CubicBezierTimingFunction::createReversed): Added.
3721         * platform/graphics/ca/GraphicsLayerCA.cpp:
3722         (WebCore::GraphicsLayerCA::addAnimation): The early return when performing a reverse or
3723         autoreverse animation is no longer needed.
3724         * platform/graphics/ca/PlatformCAAnimation.h:
3725         * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
3726         (toCAMediaTimingFunction): Use new reversed function.
3727         * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
3728         (toCACFTimingFunction): Ditto.
3729         (PlatformCAAnimation::setTimingFunction): Pass 'reverse' flag.
3730         (PlatformCAAnimation::setTimingFunctions): Ditto.
3731
3732 2013-10-21  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3733
3734         Use TYPE_CASTS_BASE for CSS_VALUE_TYPE_CASTS
3735         https://bugs.webkit.org/show_bug.cgi?id=123126
3736
3737         Reviewed by Andreas Kling.
3738
3739         TYPE_CASTS_BASE was moved to common place to be used by all toFoo().
3740         CSS_VALUE_TYPE_CASTS starts to use it for CSS child value. This change
3741         generates plenty more helper functions for toCSSFooValue().
3742
3743         Additionally, this use support that toWebKitCSSFooValue, which couldn't
3744         use CSS_VALUE_TYPE_CASTS macro.
3745
3746         No new tests, no behavior change.
3747
3748         * css/CSSAspectRatioValue.h:
3749         * css/CSSBorderImageSliceValue.h:
3750         * css/CSSCalculationValue.h:
3751         * css/CSSCanvasValue.h:
3752         * css/CSSCrossfadeValue.h:
3753         * css/CSSCursorImageValue.h:
3754         * css/CSSFilterImageValue.h:
3755         * css/CSSFontFaceSrcValue.h:
3756         * css/CSSFontFeatureValue.h:
3757         * css/CSSFontValue.h:
3758         * css/CSSFunctionValue.h:
3759         * css/CSSGradientValue.h:
3760         * css/CSSGridTemplateValue.h:
3761         * css/CSSImageSetValue.h:
3762         * css/CSSImageValue.h:
3763         * css/CSSInheritedValue.h:
3764         * css/CSSInitialValue.h:
3765         * css/CSSLineBoxContainValue.h:
3766         * css/CSSPrimitiveValue.h:
3767         * css/CSSReflectValue.h:
3768         * css/CSSShadowValue.h:
3769         * css/CSSTimingFunctionValue.h:
3770         * css/CSSUnicodeRangeValue.h:
3771         * css/CSSValue.h:
3772         * css/CSSValueList.h:
3773         * css/CSSVariableValue.h:
3774         * css/WebKitCSSArrayFunctionValue.h:
3775         * css/WebKitCSSFilterValue.h:
3776         * css/WebKitCSSMatFunctionValue.h:
3777         * css/WebKitCSSMixFunctionValue.h:
3778         * css/WebKitCSSSVGDocumentValue.h:
3779         * css/WebKitCSSShaderValue.h:
3780
3781 2013-10-21  Joone Hur  <joone.hur@intel.com>
3782
3783         Bad cast with toRenderBoxModelObject in RenderBlock::updateFirstLetter()
3784         https://bugs.webkit.org/show_bug.cgi?id=123013
3785
3786         Reviewed by Andreas Kling.
3787
3788         No new tests because this was reported by Google ClusterFuzz.
3789         https://codereview.chromium.org/25713009/
3790
3791         There is a case that toRenderBoxModelObject causes a crash in RenderBlock::updateFirstLetter() 
3792         due to bad cast, so we need to check whether the RenderObject is a RenderBoxModelObject 
3793         by running isBoxModelObject() before calling toRenderBoxModelObject.  
3794
3795         * rendering/RenderBlock.cpp:
3796         (WebCore::RenderBlock::updateFirstLetter):
3797
3798 2013-10-21  Brady Eidson  <beidson@apple.com>
3799
3800         Make IDBTransactionCoordinatorLevelDB cross platform
3801         https://bugs.webkit.org/show_bug.cgi?id=123124
3802
3803         Enthusiastically reviewed by Tim Horton.
3804
3805         * CMakeLists.txt:
3806         * GNUmakefile.list.am:
3807         * WebCore.xcodeproj/project.pbxproj:
3808
3809         Make more methods pure virtual in the interface:
3810         * Modules/indexeddb/IDBTransactionBackendInterface.h:
3811         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.cpp:
3812         * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.h:
3813
3814         Update the name of the class, and use IDBTransactionBackendInterface instead of IDBTransactionBackendLeveDB:
3815         * Modules/indexeddb/IDBTransactionCoordinator.cpp: Renamed from Source/WebCore/Modules/indexeddb/leveldb/IDBTransactionCoordinatorLevelDB.cpp.
3816         (WebCore::IDBTransactionCoordinator::create):
3817         (WebCore::IDBTransactionCoordinator::IDBTransactionCoordinator):
3818         (WebCore::IDBTransactionCoordinator::~IDBTransactionCoordinator):
3819         (WebCore::IDBTransactionCoordinator::didCreateTransaction):
3820         (WebCore::IDBTransactionCoordinator::didStartTransaction):
3821         (WebCore::IDBTransactionCoordinator::didFinishTransaction):
3822         (WebCore::IDBTransactionCoordinator::isActive):
3823         (WebCore::IDBTransactionCoordinator::processStartedTransactions):
3824         (WebCore::doScopesOverlap):
3825         (WebCore::IDBTransactionCoordinator::canRunTransaction):
3826         * Modules/indexeddb/IDBTransactionCoordinator.h: Renamed from Source/WebCore/Modules/indexeddb/leveldb/IDBTransactionCoordinatorLevelDB.h.
3827
3828         Update the name of the class elsewhere:
3829         * Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.cpp:
3830         (WebCore::IDBDatabaseBackendLevelDB::IDBDatabaseBackendLevelDB):
3831         * Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.h:
3832         (WebCore::IDBDatabaseBackendLevelDB::transactionCoordinator):
3833         * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
3834
3835 2013-10-21  Daniel Bates  <dabates@apple.com>
3836
3837         [iOS] Upstream JSGlobalObject::shouldInterruptScriptBeforeTimeout()
3838         https://bugs.webkit.org/show_bug.cgi?id=123045
3839
3840         Reviewed by Joseph Pecoraro.
3841
3842         * bindings/js/JSDOMWindowBase.cpp:
3843         (WebCore::shouldInterruptScriptToPreventInfiniteRecursionWhenClosingPage): Added.
3844         (WebCore::JSDOMWindowBase::shouldInterruptScript): Extracted comment and assertion
3845         about null Page object into WebCore::shouldInterruptScriptToPreventInfiniteRecursionWhenClosingPage()
3846         so that it can be shared by both this function and JSDOMWindowBase::shouldInterruptScriptBeforeTimeout().
3847         (WebCore::JSDOMWindowBase::shouldInterruptScriptBeforeTimeout):
3848         * bindings/js/JSDOMWindowBase.h:
3849         * bindings/js/JSWorkerGlobalScopeBase.cpp:
3850         (WebCore::JSWorkerGlobalScopeBase::shouldInterruptScriptBeforeTimeout): Added.
3851         * bindings/js/JSWorkerGlobalScopeBase.h:
3852         * loader/EmptyClients.h: Added isStopping(). We'll land the iOS chrome client implementation
3853         in a subsequent patch.
3854         * page/ChromeClient.h: Added isStopping().
3855
3856 2013-10-21  Anders Carlsson  <andersca@apple.com>
3857
3858         Navigation policy callback not called when performing the same fragment navigation twice
3859         https://bugs.webkit.org/show_bug.cgi?id=123121
3860         <rdar://problem/15230466>
3861
3862         Reviewed by Beth Dakin.
3863
3864         There's code in PolicyChecker::checkNavigationPolicy that will call the decision function right away 
3865         if the requests are equal, without consulting any policy client. Because of this, make sure to empty out
3866         the last checked request of the document loader when doing a fragment navigation.
3867
3868         * loader/FrameLoader.cpp:
3869         (WebCore::FrameLoader::loadURL):
3870         (WebCore::FrameLoader::loadWithDocumentLoader):
3871
3872 2013-10-21  Jer Noble  <jer.noble@apple.com>
3873
3874         Unreviewed build fix; unprotect the declaration of updateSleepDisabling();
3875
3876         * html/HTMLMediaElement.h:
3877
3878 2013-10-20  Mark Lam  <mark.lam@apple.com>
3879
3880         Avoid JSC debugger overhead unless needed.
3881         https://bugs.webkit.org/show_bug.cgi?id=123084.
3882
3883         Reviewed by Geoffrey Garen.
3884
3885         No new tests.
3886
3887         - If no breakpoints are set, we now avoid calling the debug hook callbacks.
3888         - If no break on exception is set, we also avoid exception event debug callbacks.
3889         - When we return from the ScriptDebugServer to the JSC::Debugger, we may no
3890           longer call the debug hook callbacks if not needed. Hence, the m_currentCallFrame
3891           pointer in the ScriptDebugServer may become stale. To avoid this issue, before
3892           returning, the ScriptDebugServer will clear its m_currentCallFrame if
3893           needsOpDebugCallbacks() is false.
3894
3895         * bindings/js/ScriptDebugServer.cpp:
3896         (WebCore::ScriptDebugServer::setBreakpoint):
3897         (WebCore::ScriptDebugServer::removeBreakpoint):
3898         (WebCore::ScriptDebugServer::clearBreakpoints):
3899         (WebCore::ScriptDebugServer::setPauseOnExceptionsState):
3900         (WebCore::ScriptDebugServer::setPauseOnNextStatement):
3901         (WebCore::ScriptDebugServer::breakProgram):
3902         (WebCore::ScriptDebugServer::stepIntoStatement):
3903         (WebCore::ScriptDebugServer::dispatchDidContinue):
3904         (WebCore::ScriptDebugServer::exception):
3905         (WebCore::ScriptDebugServer::didReachBreakpoint):
3906         * inspector/InspectorDebuggerAgent.cpp:
3907         (WebCore::InspectorDebuggerAgent::reset):
3908
3909 2013-10-21  Myles C. Maxfield  <mmaxfield@apple.com>
3910
3911         Grammar markers are not updated when switching between 1x and 2x
3912         https://bugs.webkit.org/show_bug.cgi?id=122146
3913
3914         Reviewed by Dean Jackson.
3915
3916         When running editing/spelling/grammar-markers-hidpi.html, the 2x
3917         grammar/spelling dot resources are cached. If you then run
3918         editing/spelling/grammar-markers.html without tearing down WebKit,
3919         it re-uses the 2x dots. The difference between the two tests is a call
3920         to testRunner.setBackingScaleFactor().
3921
3922         We create a NSColor from an NSImage, and remember it in a static
3923         variable. However, NSColor inspects the current graphics context to
3924         determine which resolution to use, and then remembers that decision.
3925         Therefore, we want to recreate the NSColor whenever the device pixel
3926         ratio changes. This patch adds a new static function to GraphicsContext
3927         which recreates this NSColor every time the ratio changes.
3928
3929         Tests: editing/spelling/grammar-markers.html
3930                editing/spelling/inline_spelling_markers.html
3931
3932         * platform/graphics/mac/GraphicsContextMac.mm:
3933         (WebCore::makePattern):
3934         (WebCore::GraphicsContext::drawLineForDocumentMarker):
3935
3936 2013-10-21  Simon Fraser  <simon.fraser@apple.com>
3937
3938         Use pink layer borders for compositing layers with a contents layer
3939         https://bugs.webkit.org/show_bug.cgi?id=123118
3940
3941         Reviewed by Dean Jackson.
3942
3943         With the existing layer border colors, it's not possible to distinguish an empty
3944         layer from one with solid color, image or video contents. So use a pink color
3945         for those. This makes it easier to diagnose bugs like 122784.
3946
3947         * platform/graphics/GraphicsLayer.cpp:
3948         (WebCore::GraphicsLayer::getDebugBorderInfo):
3949
3950 2013-10-21  Jer Noble  <jer.noble@apple.com>
3951
3952         Limit use of display sleep assertion when <video> element is off-screen.
3953         https://bugs.webkit.org/show_bug.cgi?id=123041
3954
3955         Reviewed by Darin Adler.
3956
3957         Use page visibility changes to suspend and resume the use of sleep assertions in
3958         HTMLMediaElement.
3959
3960         Page will propogate the page visibility change notifications to its Documents, which
3961         will further propogate those notifications to registered elements.  Upon receiving
3962         these notifications, HTMLMediaElement will release or take a DisplaySleepDisabler
3963         token if necessary.
3964
3965         Also, rename HTMLMediaElement's updateDisableSleep() to updateSleepDisabling() and wrap
3966         the implementation in a PLATFORM(MAC) guard rather than at each call site.
3967
3968         * dom/Document.cpp:
3969         (WebCore::Document::registerForVisibilityStateCallbacks): Added registration method.
3970         (WebCore::Document::unregisterForVisibilityStateCallbacks): Added unregistration method.
3971         (WebCore::Document::visibilityStateChanged): Call all registered clients.
3972         * dom/Document.h:
3973         * dom/Element.h:
3974         (WebCore::Element::visibilityStateChanged): Added default virtual method to be overridden
3975             by subclasses.
3976         * html/HTMLMediaElement.cpp:
3977         (WebCore::HTMLMediaElement::HTMLMediaElement): Register for the notification, and check the
3978             current status of Document::hidden().
3979         (WebCore::HTMLMediaElement::~HTMLMediaElement): Unregister for the notification.
3980         (WebCore::HTMLMediaElement::visibilityStateChanged): Set m_displaySleepDisablingSuspended
3981             and call updateSleepDisabling().
3982         (WebCore::HTMLMediaElement::shouldDisableSleep): Add a check for m_displaySleepDisablingSuspended.
3983         * html/HTMLMediaElement.h:
3984         * page/Page.cpp:
3985         (WebCore::Page::setVisibilityState): Pass to every child document.
3986
3987         Rename updateDisableSleep() -> updateSleepDisabling():
3988         * html/HTMLMediaElement.cpp:
3989         (WebCore::HTMLMediaElement::HTMLMediaElement):
3990         (WebCore::HTMLMediaElement::~HTMLMediaElement):
3991         (WebCore::HTMLMediaElement::parseAttribute):
3992         (WebCore::HTMLMediaElement::mediaPlayerRateChanged):
3993         (WebCore::HTMLMediaElement::clearMediaPlayer):
3994         (WebCore::HTMLMediaElement::stop):
3995
3996 2013-10-21  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
3997
3998         MediaStreamTrack now tracks its own state
3999         https://bugs.webkit.org/show_bug.cgi?id=123025
4000
4001         Reviewed by Jer Noble.
4002
4003         The spec says that a MediaStreamSource can be shared by different tracks,
4004         so a track must have its own state tracking, synchronizing with its MediaStreamSource when
4005         the underlying MediaStreamSource changes the readyState.
4006         In the old implementation if a user invoked the stop method, its readyState method was still
4007         returning the MediaStreamSource state, which was wrong.
4008         This also adds a setEnabled method, which can be used to set the state of a track when a
4009         remote peer ends it, for instance.
4010
4011         No new tests needed.
4012
4013         * Modules/mediastream/MediaStreamTrack.cpp:
4014         (WebCore::MediaStreamTrack::readyState):
4015         (WebCore::MediaStreamTrack::setState):
4016         (WebCore::MediaStreamTrack::stopProducingData):
4017         (WebCore::MediaStreamTrack::ended):
4018         (WebCore::MediaStreamTrack::sourceStateChanged):
4019         (WebCore::MediaStreamTrack::trackDidEnd):
4020         * Modules/mediastream/MediaStreamTrack.h:
4021
4022 2013-10-21  Tim Horton  <timothy_horton@apple.com>
4023
4024         Remote Layer Tree: Clean up transaction logging
4025         https://bugs.webkit.org/show_bug.cgi?id=123116
4026
4027         Reviewed by Anders Carlsson.
4028
4029         * WebCore.exp.in:
4030         Export some TextStream functions.
4031
4032 2013-10-21  Brady Eidson  <beidson@apple.com>
4033
4034         Transition most use of IDBBackingStoreLevelDB to IDBBackingStoreInterface
4035         https://bugs.webkit.org/show_bug.cgi?id=123105
4036
4037         Reviewed by Anders Carlsson.
4038
4039         Export more required headers:
4040         * WebCore.xcodeproj/project.pbxproj:
4041
4042         Flesh out many of the pure virtual methods on IDBBackingStoreInterface, as well as
4043         the RecordIdentifier and Cursor classes:
4044
4045         * Modules/indexeddb/IDBBackingStoreInterface.h:
4046         (WebCore::IDBBackingStoreInterface::RecordIdentifier::~RecordIdentifier):
4047         (WebCore::IDBBackingStoreInterface::Cursor::~Cursor):
4048
4049         Use IDBBackingStoreInterface, IDBBackingStoreInterface::RecordIdentifier, and
4050         IDBBackingStoreInterface::Cursor wherever possible: