1 2013-10-28 Zan Dobersek <zdobersek@igalia.com>
3 Clean up ScopedEventQueue
4 https://bugs.webkit.org/show_bug.cgi?id=123408
6 Reviewed by Darin Adler.
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.
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.
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.
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):
27 2013-10-28 Andreas Kling <akling@apple.com>
29 applyTextTransform() should take a const RenderStyle&.
30 <https://webkit.org/b/123434>
32 This function is always called with an existing RenderStyle object.
34 Reviewed by Anders Carlsson.
36 2013-10-28 Andreas Kling <akling@apple.com>
38 RenderSVGResource::applyResource() should take a const RenderStyle&.
39 <https://webkit.org/b/123433>
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.
45 Reviewed by Anders Carlsson.
47 2013-10-28 Andreas Kling <akling@apple.com>
49 Remove unused RenderTextControl::textBaseStyle().
50 <https://webkit.org/b/123432>
52 Reviewed by Anders Carlsson.
54 2013-10-28 Zan Dobersek <zdobersek@igalia.com>
56 HTML input type objects should be managed through std::unique_ptr
57 https://bugs.webkit.org/show_bug.cgi?id=123160
59 Reviewed by Darin Adler.
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.
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.
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.
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):
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):
145 2013-10-28 Brady Eidson <beidson@apple.com>
147 Refactor IDB factory creation.
148 https://bugs.webkit.org/show_bug.cgi?id=123347
150 Reviewed by Andreas Kling.
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.
156 * Modules/indexeddb/IDBFactory.cpp:
157 (WebCore::IDBFactory::openInternal):
159 * Modules/indexeddb/IDBFactoryBackendInterface.cpp:
160 (WebCore::IDBFactoryBackendInterface::create):
161 * Modules/indexeddb/IDBFactoryBackendInterface.h:
163 * Modules/indexeddb/PageGroupIndexedDatabase.cpp:
164 (WebCore::PageGroupIndexedDatabase::PageGroupIndexedDatabase):
165 (WebCore::PageGroupIndexedDatabase::from):
166 (WebCore::PageGroupIndexedDatabase::factoryBackend):
167 * Modules/indexeddb/PageGroupIndexedDatabase.h:
169 * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.cpp:
170 (WebCore::WorkerGlobalScopeIndexedDatabase::WorkerGlobalScopeIndexedDatabase):
171 (WebCore::WorkerGlobalScopeIndexedDatabase::from):
172 (WebCore::WorkerGlobalScopeIndexedDatabase::indexedDB):
173 * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.h:
175 * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
176 (WebCore::IDBBackingStoreLevelDB::open):
177 (WebCore::IDBBackingStoreLevelDB::openInMemory):
178 * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
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):
193 * platform/DatabaseStrategy.cpp:
194 (WebCore::DatabaseStrategy::createIDBFactoryBackend):
195 * platform/DatabaseStrategy.h:
197 2013-10-28 Andreas Kling <akling@apple.com>
199 RenderElement::style() should return a reference.
200 <https://webkit.org/b/123414>
202 Now that renderers always have style, go ahead and make style()
203 return a RenderStyle&.
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.
209 Reviewed by Anders Carlsson.
211 2013-10-28 Tim Horton <timothy_horton@apple.com>
213 Make TileController create the appropriate PlatformCALayer subclasses
214 https://bugs.webkit.org/show_bug.cgi?id=123418
216 Reviewed by Simon Fraser.
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).
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.
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.
238 2013-10-28 Alexandru Chiculita <achicu@adobe.com>
240 Web Inspector: CSS Regions: Add protocol API to expose content nodes addition/removal
241 https://bugs.webkit.org/show_bug.cgi?id=123424
243 Reviewed by Timothy Hatcher.
245 Test: inspector-protocol/model/content-flow-content-nodes.html
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.
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):
266 2013-10-28 Joseph Pecoraro <pecoraro@apple.com>
268 Web Inspector: Remove unused inspector/inline-javascript-imports.py
269 https://bugs.webkit.org/show_bug.cgi?id=123425
271 Reviewed by Timothy Hatcher.
273 * inspector/inline-javascript-imports.py: Removed.
275 2013-10-28 Joseph Pecoraro <pecoraro@apple.com>
277 Web Inspector: Remove unused "externs" files and generators
278 https://bugs.webkit.org/show_bug.cgi?id=123427
280 Reviewed by Timothy Hatcher.
282 * inspector/InjectedScriptExterns.js: Removed.
283 * inspector/generate_protocol_externs.py: Removed.
285 2013-10-28 Joseph Pecoraro <pecoraro@apple.com>
287 Upstream remaining PLATFORM(IOS) and ENABLE(REMOTE_INSPECTOR) pieces
288 https://bugs.webkit.org/show_bug.cgi?id=123411
290 Reviewed by Timothy Hatcher.
292 Include an InspectorClient hook for when node searching is enabled / disabled.
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:
302 2013-10-28 Benjamin Poulain <benjamin@webkit.org>
304 Rename applyPageScaleFactorInCompositor to delegatesPageScaling
305 https://bugs.webkit.org/show_bug.cgi?id=123417
307 Reviewed by Simon Fraser.
310 (WebCore::Frame::frameScaleFactor):
311 * page/FrameView.cpp:
312 (WebCore::FrameView::visibleContentScaleFactor):
314 (WebCore::Page::setPageScaleFactor):
316 * platform/ScrollView.h:
317 * rendering/RenderLayerCompositor.cpp:
318 (WebCore::RenderLayerCompositor::addToOverlapMap):
320 2013-10-28 Myles C. Maxfield <mmaxfield@apple.com>
322 Parsing support for -webkit-text-decoration-skip: ink
323 https://bugs.webkit.org/show_bug.cgi?id=123358
325 Reviewed by Dean Jackson.
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.
331 Test: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-roundtrip.html
333 * Configurations/FeatureDefines.xcconfig: Adding ENABLE(CSS3_TEXT_DECORATION)
334 * css/CSSComputedStyleDeclaration.cpp: Mapping internal representation of text-decoration-skip
336 (WebCore::renderTextDecorationSkipFlagsToCSSValue):
337 (WebCore::ComputedStyleExtractor::propertyValue):
338 * css/CSSParser.cpp: Actually parsing tokens
339 (WebCore::CSSParser::parseValue):
340 (WebCore::CSSParser::parseTextDecorationSkip):
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
358 2013-10-28 Anders Carlsson <andersca@apple.com>
360 RunLoop::dispatch should take an std::function
361 https://bugs.webkit.org/show_bug.cgi?id=123407
363 Reviewed by Andreas Kling.
366 * platform/RunLoop.cpp:
367 (WebCore::RunLoop::performWork):
368 (WebCore::RunLoop::dispatch):
369 * platform/RunLoop.h:
371 2013-10-28 Tim Horton <timothy_horton@apple.com>
373 Make TileController manipulate PlatformCALayers instead of CALayers
374 https://bugs.webkit.org/show_bug.cgi?id=123279
376 Reviewed by Simon Fraser.
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.
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.
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.
390 No new tests, just a (largeish) refactor.
393 The signature of some methods has changed.
395 * WebCore.xcodeproj/project.pbxproj:
396 Remove WebTileLayer.*
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.
404 * platform/graphics/TiledBacking.h:
405 tiledScrollingIndicatorLayer() should return a PlatformCALayer.
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.
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.
425 Add LayerTypeTiledBackingTileLayer, which is used simply to distinguish
426 TileController Tile layers from other LayerTypeSimpleLayers.
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.
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.
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.
452 (WebCore::TileController::platformCALayerDrawsContent):
453 All of the layers who have TileController as their client paint their contents.
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.
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.
466 * platform/graphics/ca/mac/TileController.mm:
467 Remove CALayer (WebCALayerDetails), WebTiledScrollingIndicatorLayer,
468 and a bunch of includes that we don't need anymore.
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.
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.
482 (WebCore::TileController::tileCacheLayerBoundsChanged):
483 (WebCore::TileController::setNeedsDisplay):
484 Straightforward adjustments towards use of PlatformCALayer.
486 (WebCore::TileController::setTileNeedsDisplayInRect):
487 Adjustments towards use of PlatformCALayer; we need FloatRects so we can
488 pass pointers to PlatformCALayer::setNeedsDisplay.
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.
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.
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.
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.
522 (WebCore::TileController::updateTileCoverageMap):
523 Adjustments towards use of PlatformCALayer; rename backgroundColor
524 to visibleRectIndicatorColor, since it's actually a border, not a background.
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.
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.
536 (WebCore::TileController::platformCALayerIncrementRepaintCount):
537 Manage repaint counts for tiles in TileController now.
539 (WebCore::TileController::drawTileMapContents):
540 Adjustments towards use of PlatformCALayer.
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.
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.
555 (-[WebTiledBackingLayer setBorderColor:]):
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.
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.
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)
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.
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.
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.
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.
602 2013-10-24 Sam Weinig <sam@webkit.org>
604 Move RenderBlock functions only used by RenderBlockFlow to RenderBlockFlow
605 https://bugs.webkit.org/show_bug.cgi?id=123318
607 Reviewed by David Hyatt.
609 * rendering/LineLayoutState.h:
610 Move FloatWithRect from RenderBlock.
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.
619 2013-10-28 Sergio Villar Senin <svillar@igalia.com>
621 [CSS Grid Layout] Add support for order inside grid items
622 https://bugs.webkit.org/show_bug.cgi?id=123208
624 Reviewed by Antti Koivisto.
626 Based on Blink r153457 and r153536 by <jchaffraix@chromium.org>
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.
632 Tests: fast/css-grid-layout/grid-item-order-auto-flow-resolution.html
633 fast/css-grid-layout/grid-item-order-paint-order.html
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:
658 2013-10-28 Afonso R. Costa Jr. <afonso.costa@samsung.com>
660 Methods on window.internals shouldn't pass a document.
661 https://bugs.webkit.org/show_bug.cgi?id=107301
663 Reviewed by Alexey Proskuryakov.
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.
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:
723 2013-10-28 Xabier Rodriguez Calvar <calvaris@igalia.com>
725 Remove HTMLMediaElement.startTime
726 https://bugs.webkit.org/show_bug.cgi?id=123264
728 Reviewed by Eric Carlson.
730 Patch based on one by: philipj@opera.com
731 Blink review URL: https://codereview.chromium.org/32583003
733 startTime has been removed from the HTMLMediaElement and its use
734 in the rest of components.
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
749 * html/HTMLMediaElement.h:
750 * html/HTMLMediaElement.idl: Removed startTime()
751 * rendering/RenderThemeWinCE.cpp:
752 (WebCore::RenderThemeWinCE::paintSliderThumb): Removed use of
755 2013-10-28 Andreas Kling <akling@apple.com>
757 RenderElement::m_style should be a Ref.
758 <https://webkit.org/b/123401>
760 Made RenderElement::m_style a Ref. This codifies the fact that it
761 can never be null after construction.
763 Removed a couple of unnecessary null checks that were exposed as
764 compilation failures.
766 Reviewed by Antti Koivisto.
768 2013-10-28 Bastien Nocera <hadess@hadess.net>
770 Name all the GLib timeout sources
771 https://bugs.webkit.org/show_bug.cgi?id=123229
773 Reviewed by Anders Carlsson.
775 Give a name to GLib timeout sources, this is helpful when
776 profiling WebKitGTK applications.
778 No new tests, no change in functionality.
780 2013-10-28 Philippe Normand <pnormand@igalia.com>
782 MediaStreamTrackPrivate's m_client uninitialized
783 https://bugs.webkit.org/show_bug.cgi?id=123403
785 Reviewed by Eric Carlson.
787 No new tests, no change in functionality.
789 * platform/mediastream/MediaStreamTrackPrivate.cpp:
790 (WebCore::MediaStreamTrackPrivate::MediaStreamTrackPrivate):
791 Initialize the m_client member variable.
793 2013-10-28 Carlos Garcia Campos <cgarcia@igalia.com>
795 Unreviewed. Fix make distcheck.
797 * GNUmakefile.am: Add crypto idl files to EXTRA_DIST and remove
798 css/fullscreenQuickTime.css that was removed.
800 2013-10-28 Antti Koivisto <antti@apple.com>
802 Prepare simple line layout to support multiple runs per line
803 https://bugs.webkit.org/show_bug.cgi?id=123400
805 Reviewed by Andreas Kling.
807 Bunch of renaming and some refactoring for future support for text runs.
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()
815 Added resolver construction functions:
817 SimpleLineLayout::runResolver()
818 SimpleLineLayout::lineResolver()
820 2013-10-28 Mario Sanchez Prada <mario.prada@samsung.com>
822 [GTK] Expose title and alternative text for links in image maps
823 https://bugs.webkit.org/show_bug.cgi?id=84045
825 Reviewed by Chris Fleizach.
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.
832 This actually mimics what the Mac port does and so makes possible
833 to share both the layout test and its expected results.
835 * accessibility/atk/WebKitAccessibleUtil.cpp:
836 (accessibilityDescription): Update the method to determine
837 whether the title attribute should be used for the description.
839 2013-10-28 Bastien Nocera <hadess@hadess.net>
841 Replace 0 timeouts g_timeout_add() by g_idle_add()
842 https://bugs.webkit.org/show_bug.cgi?id=123260
844 Reviewed by Carlos Garcia Campos.
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.
849 No new tests, no change in functionality.
851 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp: Use g_idle_add() instead
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):
861 2013-10-28 Zan Dobersek <zdobersek@igalia.com>
863 Re-enable simple line layout for GTK
864 https://bugs.webkit.org/show_bug.cgi?id=123388
866 Reviewed by Andreas Kling.
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.
872 2013-10-27 Andreas Kling <akling@apple.com>
874 Fix 4 asserting SVG tests after r158097.
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.
881 * rendering/RenderElement.cpp:
882 (WebCore::RenderElement::initializeStyle):
884 2013-10-27 Andreas Kling <akling@apple.com>
886 Tone down overzealous assertion from r158097.
888 RenderElement::initializeStyle() really only cares that there are no
889 text renderers that we should be calling styleDidChange() on.
891 Tweak the code to only check that there are no text children.
893 * rendering/RenderElement.cpp:
894 (WebCore::RenderElement::initializeStyle):
896 2013-10-27 Antti Koivisto <antti@apple.com>
898 Enable center and right text alignment for simple lines
899 https://bugs.webkit.org/show_bug.cgi?id=123398
901 Reviewed by Andreas Kling.
903 Support text-align:center and text-align:right on simple line layout path.
905 * rendering/SimpleLineLayout.cpp:
906 (WebCore::SimpleLineLayout::canUseFor):
908 text-align:justify is still not supported.
910 (WebCore::SimpleLineLayout::computeLineLeft):
911 (WebCore::SimpleLineLayout::createLines):
913 Do a rounding dance that matches the line boxes.
915 * rendering/SimpleLineLayout.h:
917 Add left position to lines.
919 * rendering/SimpleLineLayoutResolver.h:
920 (WebCore::SimpleLineLayout::Resolver::Line::rect):
922 We now do rounding during layout.
924 (WebCore::SimpleLineLayout::Resolver::Line::baseline):
926 2013-10-27 Andreas Kling <akling@apple.com>
928 Renderers should receive their style at construction.
929 <https://webkit.org/b/123396>
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.
936 With this change, RenderElement::m_style is never null. Subsequent
937 patches will add enforcement for this and also make style() return
940 I'm adding three FIXME's in this patch:
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.
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.
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.
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.
961 Reviewed by Antti Koivisto.
963 2013-10-26 Tim Horton <timothy_horton@apple.com>
965 [mac] Remove WebTiledLayer
966 https://bugs.webkit.org/show_bug.cgi?id=123395
968 Reviewed by Anders Carlsson.
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.
974 No new tests, just removing dead code.
976 * WebCore.xcodeproj/project.pbxproj:
977 Remove WebTiledLayer.*
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.
986 * platform/graphics/mac/WebTiledLayer.h: Removed.
987 * platform/graphics/mac/WebTiledLayer.mm: Removed.
989 2013-10-26 Andreas Kling <akling@apple.com>
991 CTTE: RenderImageResourceStyleImage always has a StyleImage.
992 <https://webkit.org/b/123390>
994 Codify the fact that RenderImageResourceStyleImage always wraps an
995 existing StyleImage object.
997 Reviewed by Antti Koivisto.
999 2013-10-26 Antti Koivisto <antti@apple.com>
1001 Revert some accidental changes.
1003 * css/CSSFontFaceSource.cpp:
1004 (WebCore::CSSFontFaceSource::getFontData):
1005 * css/CSSFontSelector.cpp:
1006 * css/CSSFontSelector.h:
1008 2013-10-26 Mark Lam <mark.lam@apple.com>
1010 Gardening: fixed broken build.
1011 https://bugs.webkit.org/show_bug.cgi?id=123354.
1013 * css/CSSFontSelector.h:
1015 2013-10-26 Antti Koivisto <antti@apple.com>
1017 fast/frames/seamless/seamless-nested-crash.html asserts on wk2 only
1018 https://bugs.webkit.org/show_bug.cgi?id=123354
1020 Reviewed by Andreas Kling.
1022 * rendering/SimpleLineLayout.cpp:
1023 (WebCore::SimpleLineLayout::canUseFor):
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.
1029 2013-10-26 Carlos Garcia Campos <cgarcia@igalia.com>
1031 [GTK] Deprecate public dispatch_event method in objects implementing EventTarget interface
1032 https://bugs.webkit.org/show_bug.cgi?id=123261
1034 Reviewed by Gustavo Noronha Silva.
1036 The interface function should be used instead.
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
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:
1060 2013-10-25 Mark Lam <mark.lam@apple.com>
1062 DatabaseManager's ProposedDatabases need to be thread-safe.
1063 https://bugs.webkit.org/show_bug.cgi?id=123313.
1065 Reviewed by Geoffrey Garen.
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:
1083 2013-10-25 Joseph Pecoraro <pecoraro@apple.com>
1085 Upstream ENABLE(REMOTE_INSPECTOR) and enable on iOS and Mac
1086 https://bugs.webkit.org/show_bug.cgi?id=123111
1088 Reviewed by Timothy Hatcher.
1090 * Configurations/FeatureDefines.xcconfig:
1093 2013-10-25 Hans Muller <hmuller@adobe.com>
1095 [CSS Shapes] CORS-enabled fetch for shape image values
1096 https://bugs.webkit.org/show_bug.cgi?id=123114
1098 Reviewed by Andreas Kling.
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.
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.
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.
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.
1122 Test: http/tests/security/shape-image-cors.html
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.
1142 2013-10-25 Jer Noble <jer.noble@apple.com>
1144 [MSE] Fix runtime errors caused by mediasource IDL attributes.
1145 https://bugs.webkit.org/show_bug.cgi?id=123352
1147 Reviewed by Eric Carlson.
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.
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:
1158 2013-10-25 Jacky Jiang <zhajiang@blackberry.com>
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
1163 Reviewed by George Staikos.
1164 Internally reviewed by George Staikos, Konrad Piascik, Eli Fidler and Arvid Nilsson.
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.
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):
1185 2013-10-25 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
1187 Adding platform implementation of MediaStreamTrack
1188 https://bugs.webkit.org/show_bug.cgi?id=123301
1190 Reviewed by Eric Carlson.
1192 No new tests needed.
1195 * Modules/mediastream/AudioStreamTrack.cpp:
1196 (WebCore::AudioStreamTrack::create): Create method now receives a MediaStreamTrackPrivate as parameter.
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.
1204 (WebCore::MediaStream::addRemoteSource): Calling AudioStreamTrack and VideoStreamTrack with
1205 MediaStreamTrackPrivate as parameter.
1207 * Modules/mediastream/MediaStreamTrack.cpp:
1208 (WebCore::MediaStreamTrack::MediaStreamTrack): Constructor now receives a MediaStreamTrackPrivate, instead of a
1211 (WebCore::MediaStreamTrack::~MediaStreamTrack):
1212 (WebCore::MediaStreamTrack::kind): Calling method from MediaStreamTrackPrivate.
1214 (WebCore::MediaStreamTrack::setSource): Ditto.
1216 (WebCore::MediaStreamTrack::id): Ditto.
1218 (WebCore::MediaStreamTrack::label): Ditto.
1220 (WebCore::MediaStreamTrack::enabled): Ditto.
1222 (WebCore::MediaStreamTrack::setEnabled): Ditto.
1224 (WebCore::MediaStreamTrack::muted): Ditto.
1226 (WebCore::MediaStreamTrack::readonly): Ditto.
1228 (WebCore::MediaStreamTrack::remote): Ditto.
1230 (WebCore::MediaStreamTrack::readyState): Ditto.
1232 (WebCore::MediaStreamTrack::states):
1233 (WebCore::MediaStreamTrack::capabilities):
1234 (WebCore::MediaStreamTrack::clone):
1235 (WebCore::MediaStreamTrack::stopProducingData):
1236 (WebCore::MediaStreamTrack::ended): Ditto.
1238 (WebCore::MediaStreamTrack::sourceStateChanged): Ditto.
1240 (WebCore::MediaStreamTrack::sourceMutedChanged): Ditto.
1242 (WebCore::MediaStreamTrack::sourceEnabledChanged): Ditto.
1243 (WebCore::MediaStreamTrack::configureTrackRendering):
1244 (WebCore::MediaStreamTrack::stopped): Ditto.
1246 (WebCore::MediaStreamTrack::trackDidEnd): Setting Ended ready state in MediaStreamTrackPrivate.
1248 (WebCore::MediaStreamTrack::trackReadyStateChanged): Dispatches Live or Ended event.
1250 (WebCore::MediaStreamTrack::trackMutedChanged): Dispatches Muted event.
1252 * Modules/mediastream/MediaStreamTrack.h: Now inheriting from MediaStreamTrackPrivateClient.
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).
1264 (WebCore::MediaStreamDescriptor::addTrack): Adds a private track to the tracks' Vector
1266 (WebCore::MediaStreamDescriptor::removeTrack): Removes a private track from the tracks' Vector
1268 * platform/mediastream/MediaStreamDescriptor.h:
1269 (WebCore::MediaStreamDescriptor::numberOfAudioSources): Renamed from numberOfAudioStreams.
1271 (WebCore::MediaStreamDescriptor::audioSources): Renamed from audioStreams.
1273 (WebCore::MediaStreamDescriptor::numberOfVideoSources): Renamed from numberOfVideoStreams.
1275 (WebCore::MediaStreamDescriptor::videoSources): Renamed from videoStreams.
1277 (WebCore::MediaStreamDescriptor::numberOfAudioTracks): Returns the number of audio tracks this MediaStreamDescriptor
1280 (WebCore::MediaStreamDescriptor::audioTracks): Returns a audio track, given an index
1282 (WebCore::MediaStreamDescriptor::numberOfVideoTracks): Returns the number of video tracks this MediaStreamDescriptor
1284 (WebCore::MediaStreamDescriptor::videoTracks): Returns a video track, given an index
1285 * platform/mediastream/MediaStreamTrackPrivate.cpp: Added.
1286 * platform/mediastream/MediaStreamTrackPrivate.h: Added.
1288 2013-10-25 Zoltan Horvath <zoltan@webkit.org>
1290 [CSS Regions][CSS Shapes] Update updateShapeAndSegmentsForCurrentLineInFlowThread to deal better with multiple regions
1291 <https://webkit.org/b/123210>
1293 Reviewed by David Hyatt.
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.
1299 No new tests, covered by existing tests.
1301 * rendering/RenderBlockLineLayout.cpp:
1302 (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLineInFlowThread):
1304 2013-10-25 Zoltan Horvath <zoltan@webkit.org>
1306 [CSS Regions][CSS Shapes] Update updateShapeAndSegmentsForCurrentLineInFlowThread to deal better with the first lines
1307 <https://bugs.webkit.org/show_bug.cgi?id=123275>
1309 Reviewed by David Hyatt.
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.
1314 No new tests, no behavior change.
1316 * rendering/RenderBlockLineLayout.cpp:
1317 (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLineInFlowThread):
1319 2013-10-25 Antti Koivisto <antti@apple.com>
1321 Faster way for simple line layout to check if text has fallback fonts
1322 https://bugs.webkit.org/show_bug.cgi?id=123342
1324 Reviewed by Andreas Kling.
1326 Don't use RenderText::knownToHaveNoOverflowAndNoFallbackFonts as it is slow.
1328 Simple text code path test already guarantees there is no overflow. Test for fallback
1331 * platform/graphics/SimpleFontData.h:
1335 * rendering/RenderText.cpp:
1336 * rendering/RenderText.h:
1338 Remove knownToHaveNoOverflowAndNoFallbackFonts() as it has no clients.
1340 * rendering/SimpleLineLayout.cpp:
1341 (WebCore::SimpleLineLayout::canUseFor):
1343 Check if all characters can be found from the primary font.
1345 2013-10-25 Andreas Kling <akling@apple.com>
1347 SVGResourcesCache::clientDestroyed() should take a RenderElement&.
1348 <https://webkit.org/b/123339>
1350 This function is always called with an object, and that object
1351 is guaranteed to never be a text renderer.
1353 Reviewed by Antti Koivisto.
1355 2013-10-25 Andreas Kling <akling@apple.com>
1357 SVGResourcesCache::clientLayoutChanged() should take a RenderElement&.
1358 <https://webkit.org/b/123336>
1360 This function is always called with an object, and that object
1361 is guaranteed to never be a text renderer.
1363 Reviewed by Antti Koivisto.
1365 2013-10-25 Andreas Kling <akling@apple.com>
1367 SVGResourcesCache::clientStyleChanged() should take a RenderElement&.
1368 <https://webkit.org/b/123335>
1370 This function is always called with an object, and that object
1371 is guaranteed to never be a text renderer.
1373 Reviewed by Antti Koivisto.
1375 2013-10-25 Andreas Kling <akling@apple.com>
1377 SVG: postApplyResource() should take a RenderElement&.
1378 <https://webkit.org/b/123334>
1380 This function is always called with an object, and that object
1381 is guaranteed to never be a text renderer.
1383 Reviewed by Antti Koivisto.
1385 2013-10-25 Antti Koivisto <antti@apple.com>
1387 REGRESSION(r157950): It made many tests assert on Windows, EFL, GTK
1388 https://bugs.webkit.org/show_bug.cgi?id=123309
1390 Reviewed by Andreas Kling.
1392 Disable simple line layout on non-Mac plaforms for now.
1394 * rendering/SimpleLineLayout.cpp:
1395 (WebCore::SimpleLineLayout::canUseFor):
1397 2013-10-24 Andreas Kling <akling@apple.com>
1399 SVG: applyResource() should take a RenderElement&.
1400 <https://webkit.org/b/123286>
1402 This function is always called with an object, and that object
1403 is guaranteed to never be a text renderer.
1405 Reviewed by Antti Koivisto.
1407 2013-10-25 Andreas Kling <akling@apple.com>
1409 RenderElement::styleWillChange() should pass newStyle as reference.
1410 <https://webkit.org/b/123332>
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.
1416 Reviewed by Antti Koivisto.
1418 2013-10-25 peavo@outlook.com <peavo@outlook.com>
1420 [WinCairo] Compile fixes.
1421 https://bugs.webkit.org/show_bug.cgi?id=123269
1423 Reviewed by Csaba Osztrogonác.
1425 * platform/graphics/win/ImageCairoWin.cpp: Added new parameter to BitmapImage::draw() calls.
1426 (WebCore::BitmapImage::getHBITMAPOfSize):
1427 (WebCore::BitmapImage::drawFrameMatchingSourceSize):
1429 2013-10-25 Sergio Villar Senin <svillar@igalia.com>
1431 Use a Vector instead of HashSet to computed the orderValues in RenderFlexibleBox
1432 https://bugs.webkit.org/show_bug.cgi?id=118620
1434 Reviewed by Antti Koivisto.
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.
1441 Also added the performance test that shows a ~1% win when using a
1442 vector instead of the HashSet.
1444 * rendering/RenderFlexibleBox.cpp:
1445 (WebCore::RenderFlexibleBox::OrderIterator::setOrderValues):
1446 (WebCore::RenderFlexibleBox::layoutBlock):
1447 (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
1448 * rendering/RenderFlexibleBox.h:
1450 2013-10-25 Sergio Villar Senin <svillar@igalia.com>
1452 Non-SVG build broken after r157950
1453 https://bugs.webkit.org/show_bug.cgi?id=123328
1455 Reviewed by Xan Lopez.
1457 The isSVGInlineTest() check should be done only if SVG is enabled.
1459 * rendering/SimpleLineLayout.cpp:
1460 (WebCore::SimpleLineLayout::canUseFor):
1462 2013-10-24 Jer Noble <jer.noble@apple.com>
1464 [Mac] Add helper methods to convert CMTime <--> MediaTime
1465 https://bugs.webkit.org/show_bug.cgi?id=123285
1467 Reviewed by Eric Carlson.
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.
1472 * platform/mac/MediaTimeMac.h:
1473 * platform/mac/MediaTimeMac.cpp:
1474 (WebCore::toMediaTime): Added conversion utility method.
1475 (WebCore::toCMTime): Ditto.
1477 * platform/mac/PlatformClockCM.h:
1478 * platform/mac/PlatformClockCM.mm:
1479 (PlatformClockCM::setCurrentMediaTime): Added.
1480 (PlatformClockCM::currentMediaTime): Added.
1482 * WebCore.xcodeproj/project.pbxproj: Add new files to project.
1484 2013-10-24 Mark Rowe <mrowe@apple.com>
1486 Remove references to OS X 10.7 from Xcode configuration settings.
1488 Now that we're not building for OS X 10.7 they're no longer needed.
1490 Reviewed by Anders Carlsson.
1493 * Configurations/Base.xcconfig:
1494 * Configurations/DebugRelease.xcconfig:
1495 * Configurations/FeatureDefines.xcconfig:
1496 * Configurations/Version.xcconfig:
1498 2013-10-24 Antti Koivisto <antti@apple.com>
1500 Cache line layout path
1501 https://bugs.webkit.org/show_bug.cgi?id=123298
1503 Reviewed by Sam Weinig.
1505 Determining the path can be non-trivial. Avoid computing it repeatedly on relayouts.
1507 * rendering/RenderBlock.cpp:
1508 (WebCore::RenderBlock::RenderBlock):
1509 (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
1510 (WebCore::RenderBlock::invalidateLineLayoutPath):
1511 (WebCore::RenderBlock::removeChild):
1513 Invalidate the path when children change.
1515 * rendering/RenderBlock.h:
1516 * rendering/RenderBlockFlow.cpp:
1517 (WebCore::RenderBlockFlow::layoutInlineChildren):
1518 (WebCore::RenderBlockFlow::styleDidChange):
1520 Invalidate the path when style changes.
1522 (WebCore::RenderBlockFlow::deleteLineBoxesBeforeSimpleLineLayout):
1523 (WebCore::RenderBlockFlow::ensureLineBoxes):
1524 * rendering/RenderText.cpp:
1525 (WebCore::RenderText::setText):
1527 Invalidate the path when text changes.
1529 2013-10-24 Mark Rowe <mrowe@apple.com>
1531 <rdar://problem/15312643> Prepare for the mysterious future.
1533 Reviewed by David Kilzer.
1536 * Configurations/Base.xcconfig:
1537 * Configurations/DebugRelease.xcconfig:
1538 * Configurations/FeatureDefines.xcconfig:
1539 * Configurations/Version.xcconfig:
1541 2013-10-24 Andreas Kling <akling@apple.com>
1543 DocumentLoader::cachedResourceLoader() should return a reference.
1544 <https://webkit.org/b/123303>
1546 ..and while we're at it, make DocumentLoader::m_cachedResourceLoader
1547 a Ref, and have CachedResourceLoader::create return a PassRef.
1549 Reviewed by Sam Weinig.
1551 2013-10-24 Anders Carlsson <andersca@apple.com>
1553 Stop bringing in the std namespace
1554 https://bugs.webkit.org/show_bug.cgi?id=123273
1556 Reviewed by Andreas Kling.
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:
1638 (WebCore::Document::minimumLayoutDelay):
1640 (WebCore::Node::compareDocumentPosition):
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):
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):
1839 2013-10-24 Andreas Kling <akling@apple.com>
1841 Uncomplicate some of SVGTextRunRenderingContext.
1842 <https://webkit.org/b/123294>
1844 This class was weird about a few things, so I've taken these steps
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.
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.
1857 Reviewed by Antti Koivisto.
1859 2013-10-24 Roger Fong <roger_fong@apple.com>
1861 Add texture level dependent size checks to textureImage2D calls.
1862 https://bugs.webkit.org/show_bug.cgi?id=123290
1863 <rdar://problem/15201382>
1865 Reviewed by Dean Jackson
1867 Test covered by WebGL Conformance suite 1.0.2 test, textures/texture-size-limit.html.
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.
1872 * html/canvas/WebGLRenderingContext.cpp:
1873 (WebCore::WebGLRenderingContext::validateTexFuncParameters):
1875 2013-10-24 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
1877 [MediaStream API] allow a stream source to be shared
1878 https://bugs.webkit.org/show_bug.cgi?id=121954
1880 Reviewed by Eric Carlson.
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
1887 No new tests, no change in functionality.
1889 * Modules/mediastream/MediaStream.cpp:
1890 (WebCore::MediaStream::MediaStream): Adding the MediaStream as an observer for each track it owns.
1892 (WebCore::MediaStream::addTrack): Now adding the MediaStream as an observer the new added track
1893 and adding the source to the MediaStreamDescriptor.
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.
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.
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.
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.
1912 * Modules/mediastream/MediaStreamTrack.h: Adding Observer class.
1914 * platform/mediastream/MediaStreamDescriptor.cpp: Destructor now does nothing. Previously it was setting
1915 each MediaStreamSource's descriptor to null.
1917 (WebCore::MediaStreamDescriptor::removeSource): Not setting the stream in source anymore.
1919 (WebCore::MediaStreamDescriptor::MediaStreamDescriptor): Ditto.
1921 (WebCore::MediaStreamDescriptor::setEnded): Not setting the state of the source to Ended
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:
1930 2013-10-24 Daniel Bates <dabates@apple.com>
1932 Crash in WebCore::NavigationScheduler::startTimer()
1933 https://bugs.webkit.org/show_bug.cgi?id=123288
1934 <rdar://problem/14055644>
1936 Reviewed by Alexey Proskuryakov.
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.
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.
1949 * loader/NavigationScheduler.cpp:
1950 (WebCore::NavigationScheduler::startTimer):
1952 2013-10-24 Antti Koivisto <antti@apple.com>
1954 Try to fix build without CSS_SHAPES.
1956 * rendering/SimpleLineLayout.cpp:
1957 (WebCore::SimpleLineLayout::canUseFor):
1959 2013-10-24 Antti Koivisto <antti@apple.com>
1962 https://bugs.webkit.org/show_bug.cgi?id=122458
1964 Reviewed by Darin Adler.
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
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).
1974 Simple line layout aims to produce pixel-exact rendering result when compared to the line box layout.
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.
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.
1984 * GNUmakefile.list.am:
1985 * WebCore.vcxproj/WebCore.vcxproj:
1986 * WebCore.xcodeproj/project.pbxproj:
1988 (WebCore::Position::upstream):
1989 (WebCore::Position::downstream):
1990 (WebCore::Position::getInlineBoxAndOffset):
1992 Creating positions within a simple line flow causes switch to line boxes.
1994 * editing/TextIterator.cpp:
1995 (WebCore::TextIterator::handleTextNode):
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.
2001 * rendering/RenderBlock.cpp:
2002 (WebCore::RenderBlock::RenderBlock):
2003 (WebCore::RenderBlock::layoutShapeInsideInfo):
2004 * rendering/RenderBlock.h:
2005 * rendering/RenderBlockFlow.cpp:
2006 (WebCore::RenderBlockFlow::layoutInlineChildren):
2008 Select the layout path to use.
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):
2025 (WebCore::RenderBlockFlow::deleteLineBoxesBeforeSimpleLineLayout):
2026 (WebCore::RenderBlockFlow::ensureLineBoxes):
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).
2031 * rendering/RenderBlockFlow.h:
2032 (WebCore::RenderBlockFlow::simpleLines):
2033 * rendering/RenderBlockLineLayout.cpp:
2034 (WebCore::RenderBlockFlow::layoutLineBoxes):
2036 Rename the line box layout function.
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):
2066 * rendering/SimpleLineLayout.cpp: Added.
2067 (WebCore::SimpleLineLayout::canUseFor):
2069 This check for the cases supported by the simple line layout path.
2071 (WebCore::SimpleLineLayout::isWhitespace):
2072 (WebCore::SimpleLineLayout::skipWhitespaces):
2073 (WebCore::SimpleLineLayout::textWidth):
2074 (WebCore::SimpleLineLayout::createLines):
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.
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):
2095 Support functions called from RenderBlockFlow and RenderText. They are equivalent to
2096 similar line box functions.
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*):
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.
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[]):
2121 2013-10-24 Myles C. Maxfield <mmaxfield@apple.com>
2123 Gaps between underlines in adjacent underlined text runs
2124 https://bugs.webkit.org/show_bug.cgi?id=123236
2126 Reviewed by Simon Fraser and Darin Adler.
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
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.
2141 Test: fast/css3-text/css3-text-decoration/no-gap-between-two-rounded-textboxes.html
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
2150 2013-10-24 Andreas Kling <akling@apple.com>
2152 SVGRenderingContext should wrap a RenderElement.
2153 <https://webkit.org/b/123283>
2155 The SVG rendering context class is never used with text renderers
2156 so we can have it wrap a RenderElement for tighter code.
2158 Also renamed SVGRenderingContext::m_object to m_renderer.
2160 Reviewed by Antti Koivisto.
2162 2013-10-24 Santosh Mahto <santosh.ma@samsung.com>
2164 [contenteditable] Content after non-editable element disappears when merging lines using backspace
2165 https://bugs.webkit.org/show_bug.cgi?id=122748
2167 Reviewed by Ryosuke Niwa.
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.
2179 Test: editing/deleting/merge-paragraph-contatining-noneditable.html
2181 * editing/DeleteSelectionCommand.cpp:
2182 (WebCore::DeleteSelectionCommand::mergeParagraphs): use CanSkipOverEditingBoundary
2183 condition while calculating endOfParagraphToMove.
2185 2013-10-24 Antoine Quint <graouts@apple.com>
2187 Web Inspector: Inspector doesn't show webkitTransitionEnd events in the timeline
2188 https://bugs.webkit.org/show_bug.cgi?id=123263
2190 Reviewed by Timothy Hatcher.
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
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.
2203 * dom/EventDispatcher.cpp:
2204 (WebCore::EventDispatcher::dispatchEvent):
2205 Remove calls to InspectorInstrumentation::willDispatchEvent() and InspectorInstrumentation::didDispatchEvent().
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.
2213 2013-10-24 Andreas Kling <akling@apple.com>
2215 SVG: RenderElement-ize intersectRepaintRectWithResources().
2216 <https://webkit.org/b/123278>
2218 SVGRenderSupport::intersectRepaintRectWithResources() is only ever
2219 called with non-text renderers so make it take RenderElement&.
2221 Had to tweak RenderSVGResource::resourceBoundingBox() to take the
2222 renderer by reference.
2224 Reviewed by Antti Koivisto.
2226 2013-10-24 Joseph Pecoraro <pecoraro@apple.com>
2228 Web Inspector: Breakpoints in sourceURL named scripts do not work
2229 https://bugs.webkit.org/show_bug.cgi?id=123231
2231 Reviewed by Timothy Hatcher.
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.
2238 Test: inspector-protocol/debugger/setBreakpointByUrl-sourceURL.html
2240 * inspector/InspectorDebuggerAgent.cpp:
2241 (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
2242 (WebCore::InspectorDebuggerAgent::didParseSource):
2243 * inspector/InspectorDebuggerAgent.h:
2244 * inspector/ScriptDebugListener.h:
2246 2013-10-23 Alexey Proskuryakov <ap@apple.com>
2248 Add CryptoKey base class and bindings
2249 https://bugs.webkit.org/show_bug.cgi?id=123216
2251 Reviewed by Sam Weinig.
2253 * crypto/CryptoKey.idl: Added.
2256 * DerivedSources.make:
2257 * GNUmakefile.list.am:
2260 * WebCore.xcodeproj/project.pbxproj: Added files.
2262 * bindings/js/JSCryptoKeyCustom.cpp: Added.
2263 (WebCore::JSCryptoKey::algorithm): Use a visitor to build algorithm dictionary
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.
2272 * bindings/js/JSCryptoAlgorithmBuilder.cpp: Added.
2273 * bindings/js/JSCryptoAlgorithmBuilder.h: Added.
2274 An implementation that builds an algorithm description dictionary for JS bindings.
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.
2283 2013-10-24 Commit Queue <commit-queue@webkit.org>
2285 Unreviewed, rolling out r157916.
2286 http://trac.webkit.org/changeset/157916
2287 https://bugs.webkit.org/show_bug.cgi?id=123274
2289 Broke Layout/flexbox-lots-of-data.html on perfbot (Requested
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:
2301 2013-10-24 Zan Dobersek <zdobersek@igalia.com>
2303 Comment in ScopedEventQueue::dispatchEvent is unnecessarily verbose
2304 https://bugs.webkit.org/show_bug.cgi?id=123252
2306 Reviewed by Darin Adler.
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.
2312 * dom/ScopedEventQueue.cpp:
2313 (WebCore::ScopedEventQueue::dispatchEvent):
2315 2013-10-24 Alex Christensen <achristensen@webkit.org>
2317 Removed unused ThreadSafeCoordinatedSurface and CertificateInfoCurl files.
2318 https://bugs.webkit.org/show_bug.cgi?id=123246
2320 Reviewed by Noam Rosenthal.
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.
2329 2013-10-24 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
2331 Removed Qt workaround.
2332 https://bugs.webkit.org/show_bug.cgi?id=123258
2334 Reviewed by Csaba Osztrogonác.
2336 No change of functionality, no new tests needed.
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
2341 * css/make-css-file-arrays.pl:
2343 2013-10-24 Antti Koivisto <antti@apple.com>
2345 Remove a stray space.
2349 * accessibility/AccessibilityRenderObject.cpp:
2350 (WebCore::AccessibilityRenderObject::addImageMapChildren):
2352 2013-10-24 Antti Koivisto <antti@apple.com>
2354 Element iterator functions should take reference
2355 https://bugs.webkit.org/show_bug.cgi?id=123267
2357 Reviewed by Andreas Kling.
2359 The argument has to be non-null.
2361 2013-10-24 Ryuan Choi <ryuan.choi@samsung.com>
2363 [EFL] Build break with latest EFL 1.8 libraries.
2364 https://bugs.webkit.org/show_bug.cgi?id=123245
2366 Reviewed by Gyuyoung Kim.
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.
2371 * platform/Widget.h: Changed Eo typedef.
2372 * platform/efl/EflScreenUtilities.h: Ditto.
2373 * platform/graphics/Image.h: Ditto.
2375 2013-10-24 Andreas Kling <akling@apple.com>
2377 RenderSVGResource: Pass RenderElement to fill/strokePaintingResource.
2378 <https://webkit.org/b/123242>
2380 We never pass text renderers to these functions, so make them take
2381 RenderElement instead.
2383 Reviewed by Anders Carlsson.
2385 2013-10-24 Carlos Garcia Campos <cgarcia@igalia.com>
2387 [GObject bindings] Make EventTarget interface introspectable
2388 https://bugs.webkit.org/show_bug.cgi?id=77835
2390 Reviewed by Gustavo Noronha Silva.
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
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):
2425 2013-10-14 Sergio Villar Senin <svillar@igalia.com>
2427 Use a Vector instead of HashSet to computed the orderValues in RenderFlexibleBox
2428 https://bugs.webkit.org/show_bug.cgi?id=118620
2430 Reviewed by Antti Koivisto.
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.
2437 Also added the performance test that shows a ~1% win when using a
2438 vector instead of the HashSet.
2440 * rendering/RenderFlexibleBox.cpp:
2441 (WebCore::RenderFlexibleBox::OrderIterator::setOrderValues):
2442 (WebCore::RenderFlexibleBox::layoutBlock):
2443 (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
2444 * rendering/RenderFlexibleBox.h:
2446 2013-10-23 ChangSeok Oh <changseok.oh@collabora.com>
2448 Unreviewed build fix since r157823.
2449 FilterOperation::getOperationType() is renamed FilterOperation::type().
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):
2460 2013-10-23 Ryuan Choi <ryuan.choi@samsung.com>
2462 Unreviewed build fix on CMake based ports when CMAKE_BUILD_TYPE is not given.
2464 When CMAKE_BUILD_TYPE is empty, FIND command will be failed.
2468 2013-10-23 Gyuyoung Kim <gyuyoung.kim@samsung.com>
2470 Integrate css3-images image-orientation with existing EXIF support
2471 https://bugs.webkit.org/show_bug.cgi?id=91566
2473 Reviewed by Beth Dakin.
2475 Original patch by David Barr(davidbarr@chromium.org).
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.
2481 Spec: http://dev.w3.org/csswg/css-images-3/#the-image-orientation
2482 The css3-images module specification is at last call.
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.
2487 * loader/cache/CachedImage.cpp:
2488 (WebCore::CachedImage::imageSizeForRenderer):
2489 * page/DragController.cpp:
2490 (WebCore::DragController::doImageDrag):
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:
2542 2013-10-23 Andreas Kling <akling@apple.com>
2544 Tighten typing in SVGInlineTextBox a bit.
2545 <https://webkit.org/b/123238>
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().
2551 Reviewed by Anders Carlsson.
2553 2013-10-23 Gyuyoung Kim <gyuyoung.kim@samsung.com>
2555 Introduce RENDER_OBJECT_TYPE_CASTS to replace manual toFoo() in child render object
2556 https://bugs.webkit.org/show_bug.cgi?id=123150
2558 Reviewed by Andreas Kling.
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.
2564 Some unnecessary type casts are fixed by this change.
2566 No new tests, no behavior changes.
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):
2637 2013-10-23 Myles C. Maxfield <mmaxfield@apple.com>
2639 Include misspelling dot gap width when centering misspelling dots
2640 https://bugs.webkit.org/show_bug.cgi?id=122365
2642 Reviewed by Simon Fraser.
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.
2655 Test: editing/spelling/centering-misspelling-dots.html
2657 * platform/graphics/mac/GraphicsContextMac.mm:
2658 (WebCore::GraphicsContext::drawLineForDocumentMarker):
2660 2013-10-23 Andreas Kling <akling@apple.com>
2662 SVGFilterBuilder should not be ref-counted.
2663 <https://webkit.org/b/123222>
2665 These objects are singly-owned and do not need ref counting.
2667 Reviewed by Anders Carlsson.
2669 2013-10-23 Brady Eidson <beidson@apple.com>
2671 Remove unused IDBBackingStoreLevelDB default constructor.
2673 Rubberstamped by Anders Carlsson.
2675 * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
2676 * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
2678 2013-10-23 Alex Christensen <achristensen@webkit.org>
2680 Added Texture Mapper and Coordinated Graphics to Windows build for WinCairo.
2681 https://bugs.webkit.org/show_bug.cgi?id=123215
2683 Reviewed by Brent Fulgham.
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.
2691 2013-10-23 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
2693 Adding mock class to test RTCDataChannelHandler
2694 https://bugs.webkit.org/show_bug.cgi?id=123205
2696 Reviewed by Eric Carlson.
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)
2701 Existing tests updated.
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):
2716 2013-10-23 Andreas Kling <akling@apple.com>
2718 Clock should not be ref-counted.
2719 <https://webkit.org/b/123217>
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.
2724 Also slapped the Clock subclasses with FINAL and OVERRIDE.
2726 Reviewed by Anders Carlsson.
2728 2013-10-23 Mark Lam <mark.lam@apple.com>
2730 Fix assertion in DatabaseManager::detailsForNameAndOrigin() to be iOS friendly.
2731 https://bugs.webkit.org/show_bug.cgi?id=123218.
2733 Reviewed by Joseph Pecoraro.
2737 * Modules/webdatabase/DatabaseManager.cpp:
2738 (WebCore::DatabaseManager::detailsForNameAndOrigin):
2740 2013-10-23 Alex Christensen <achristensen@webkit.org>
2742 Separated USE(CA) from USE(ACCELERATED_COMPOSITING) to prepare WinCairo for accelerated compositing.
2743 https://bugs.webkit.org/show_bug.cgi?id=123214
2745 Reviewed by Brent Fulgham.
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.
2755 2013-10-23 Myles C. Maxfield <mmaxfield@apple.com>
2757 Antialias underlines if they're not axis-aligned
2758 https://bugs.webkit.org/show_bug.cgi?id=123004
2760 Reviewed by Simon Fraser.
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.
2774 Tests: svg/custom/foreign-object-skew.html
2775 svg/zoom/page/zoom-foreignObject.html
2776 svg/zoom/text/zoom-foreignObject.html:
2778 * platform/graphics/cg/GraphicsContextCG.cpp:
2779 (WebCore::GraphicsContext::drawLineForText):
2781 2013-10-23 Mark Lam <mark.lam@apple.com>
2783 Re-instate ProposedDatabases needed by detailsForNameAndOrigin().
2784 https://bugs.webkit.org/show_bug.cgi?id=123131.
2786 Reviewed by Geoffrey Garen.
2788 Test: storage/websql/open-database-expand-quota.html
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.
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.
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):
2812 2013-10-23 Tim Horton <timothy_horton@apple.com>
2814 [cg] Fix the capitalization of kCGImageSourceSkipMetaData (-> Metadata)
2815 https://bugs.webkit.org/show_bug.cgi?id=122918
2817 Reviewed by Anders Carlsson.
2819 * platform/graphics/cg/ImageSourceCG.cpp:
2820 (WebCore::imageSourceOptions):
2821 The capitalization of kCGImageSourceSkipMetaData changed to
2822 kCGImageSourceSkipMetadata in Mountain Lion.
2824 2013-10-23 Brady Eidson <beidson@apple.com>
2826 Make IDBDatabaseBackendLevelDB.cpp be cross platform
2827 https://bugs.webkit.org/show_bug.cgi?id=123027
2829 Attentively reviewed by Dean Jackson.
2831 Move it out of the indexeddb/leveldb directory, and rename it to IDBDatabaseBackendImpl.
2835 * GNUmakefile.list.am:
2836 * WebCore.vcxproj/WebCore.vcxproj:
2837 * WebCore.vcxproj/WebCore.vcxproj.filters:
2838 * WebCore.xcodeproj/project.pbxproj:
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.
2843 * Modules/indexeddb/IDBDatabaseBackendInterface.h:
2844 (WebCore::IDBDatabaseBackendInterface::isIDBDatabaseBackendImpl): Add to support a required cast in LevelDB code.
2846 * Modules/indexeddb/IDBFactoryBackendInterface.h:
2848 * Modules/indexeddb/leveldb/IDBCursorBackendLevelDB.cpp:
2849 * Modules/indexeddb/leveldb/IDBCursorBackendLevelDB.h:
2851 * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
2852 (WebCore::IDBFactoryBackendLevelDB::deleteDatabase):
2853 (WebCore::IDBFactoryBackendLevelDB::open):
2854 (WebCore::IDBFactoryBackendLevelDB::maybeCreateTransactionBackend):
2855 * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.h:
2857 * Modules/indexeddb/leveldb/IDBLevelDBCoding.cpp:
2858 * Modules/indexeddb/leveldb/IDBLevelDBCoding.h:
2860 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.cpp:
2861 (WebCore::IDBTransactionBackendLevelDB::create):
2862 (WebCore::IDBTransactionBackendLevelDB::IDBTransactionBackendLevelDB):
2863 (WebCore::IDBTransactionBackendLevelDB::scheduleVersionChangeOperation):
2864 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.h:
2866 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.cpp:
2867 (WebCore::IDBDatabaseBackendImpl::VersionChangeOperation::perform):
2868 (WebCore::IDBDatabaseBackendImpl::VersionChangeAbortOperation::perform):
2869 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.h:
2871 2013-10-23 Daniel Bates <dabates@apple.com>
2873 [iOS] Upstream more ARMv7s bits
2874 https://bugs.webkit.org/show_bug.cgi?id=123052
2876 Reviewed by Joseph Pecoraro.
2878 Define exported symbol file for armv7s and arm64.
2880 * Configurations/WebCore.xcconfig:
2882 2013-10-23 Krzysztof Wolanski <k.wolanski@samsung.com>
2884 [GTK] accessibility/self-referencing-aria-labelledby.html is failing
2885 https://bugs.webkit.org/show_bug.cgi?id=121594
2887 Reviewed by Mario Sanchez Prada.
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.
2893 * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2894 (webkitAccessibleGetDescription):
2896 2013-10-15 Andreas Kling <akling@apple.com>
2898 Tighten animation-driven restyle to operate on Element only.
2899 <https://webkit.org/b/122820>
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.
2905 Reviewed by Antti Koivisto.
2907 2013-10-22 Andreas Kling <akling@apple.com>
2909 Even more PassRef<RenderStyle>!
2910 <https://webkit.org/b/123147>
2912 Convert more of the WebCore code to use PassRef for RenderStyle
2913 in places where they are known to be non-null.
2915 Re-landing this without region styling since that caused some
2916 assertions last time.
2918 Reviewed by Antti Koivisto.
2920 2013-10-22 Zoltan Horvath <zoltan@webkit.org>
2922 Refactor LineBreaker::nextSegmentBreak, add BreakingContext that holds all its state
2923 https://bugs.webkit.org/show_bug.cgi?id=123038
2925 Reviewed by David Hyatt.
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.
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.
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.
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):
2965 2013-10-22 Commit Queue <commit-queue@webkit.org>
2967 Unreviewed, rolling out r157826.
2968 http://trac.webkit.org/changeset/157826
2969 https://bugs.webkit.org/show_bug.cgi?id=123197
2971 Caused some regions tests to assert (Requested by smfr on
2975 (WebCore::Document::styleForElementIgnoringPendingStylesheets):
2978 (WebCore::Element::styleForRenderer):
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):
3004 2013-10-22 Ryuan Choi <ryuan.choi@samsung.com>
3006 [EFL] Remove HAVE_GLX macro
3007 https://bugs.webkit.org/show_bug.cgi?id=123191
3009 Reviewed by Gyuyoung Kim.
3011 Since r138313, HAVE(GLX) was replaced to USE(GLX) except in GraphicsSurfaceToken.h.
3013 * platform/graphics/surfaces/GraphicsSurfaceToken.h:
3014 Replace HAVE(GLX) to USE(GLX)
3016 2013-10-22 Mark Lam <mark.lam@apple.com>
3018 Gardening: fix broken build on Windows.
3019 https://bugs.webkit.org/show_bug.cgi?id=123174.
3025 * WebCore.vcxproj/WebCore.vcxproj:
3026 * WebCore.vcxproj/WebCore.vcxproj.filters:
3028 2013-10-22 Brady Eidson <beidson@apple.com>
3030 Get rid of IDBObjectStoreBackendLevelDB
3031 https://bugs.webkit.org/show_bug.cgi?id=123174
3033 Reviewed by Tim Horton.
3035 This file was kind of a dumping ground.
3036 Its contents can be merged into IDBBackingStoreInterface and a new IDBIndexWriter class.
3038 Also took the opportunity to do a little bit of RefPtr<> and pointer-vs-reference cleanup.
3041 * GNUmakefile.list.am:
3042 * WebCore.xcodeproj/project.pbxproj:
3044 * Modules/indexeddb/leveldb/IDBObjectStoreBackendLevelDB.cpp: Removed.
3045 * Modules/indexeddb/leveldb/IDBObjectStoreBackendLevelDB.h: Removed.
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):
3055 * Modules/indexeddb/IDBBackingStoreInterface.h:
3056 * Modules/indexeddb/IDBDatabaseBackendInterface.h:
3058 * Modules/indexeddb/IDBMetadata.h:
3059 * Modules/indexeddb/IDBTransactionBackendInterface.h:
3061 * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
3062 (WebCore::IDBBackingStoreLevelDB::makeIndexWriters):
3063 (WebCore::IDBBackingStoreLevelDB::generateKey):
3064 (WebCore::IDBBackingStoreLevelDB::updateKeyGenerator):
3065 * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.h:
3067 * Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.cpp:
3068 (WebCore::IDBDatabaseBackendLevelDB::setIndexKeys):
3069 (WebCore::IDBDatabaseBackendLevelDB::setIndexesReady):
3070 * Modules/indexeddb/leveldb/IDBDatabaseBackendLevelDB.h:
3072 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.cpp:
3073 (WebCore::IDBTransactionBackendLevelDB::schedulePutOperation):
3074 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDB.h:
3076 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.cpp:
3077 (WebCore::PutOperation::perform):
3078 * Modules/indexeddb/leveldb/IDBTransactionBackendLevelDBOperations.h:
3079 (WebCore::PutOperation::create):
3080 (WebCore::PutOperation::PutOperation):
3082 2013-10-22 Dean Jackson <dino@apple.com>
3084 [WebGL] Implement a software rendering option on Mac
3085 https://bugs.webkit.org/show_bug.cgi?id=123177
3087 Reviewed by Tim Horton.
3089 Implement a way to force software OpenGL rendering
3090 for WebGL, via a Setting/Preference.
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.
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
3117 2013-10-22 Anders Carlsson <andersca@apple.com>
3119 Revert r157445 since it broke certificates on Mac.
3120 <rdar://problem/15246926&15254017&15269117>
3122 * GNUmakefile.list.am:
3123 * PlatformEfl.cmake:
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):
3155 2013-10-22 Jer Noble <jer.noble@apple.com>
3157 [Media] Refactor supportsType() factory method to take a parameters object.
3158 https://bugs.webkit.org/show_bug.cgi?id=122489
3160 Reviewed by Eric Carlson.
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.
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.
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:
3201 2013-10-22 Andreas Kling <akling@apple.com>
3203 Merge SVGRenderBlock::styleWillChange() into styleDidChange().
3204 <https://webkit.org/b/123181>
3206 I meant to do this one in r157787, but better late than never.
3208 Reviewed by Geoffrey Garen.
3210 2013-10-22 Sam Weinig <sam@webkit.org>
3212 CTTE: Modernize RenderBlock a bit
3213 https://bugs.webkit.org/show_bug.cgi?id=123162
3215 Reviewed by Andreas Kling.
3217 Start threading references through RenderBlock. While we
3218 are here, do some selective modernization as well.
3220 2013-10-22 Andreas Kling <akling@apple.com>
3222 Even more PassRef<RenderStyle>!
3223 <https://webkit.org/b/123147>
3225 Convert the remaining WebCore code to use PassRef for RenderStyle
3226 wherever they are known to be non-null.
3228 Reviewed by Antti Koivisto.
3230 2013-10-22 Commit Queue <commit-queue@webkit.org>
3232 Unreviewed, rolling out r157819.
3233 http://trac.webkit.org/changeset/157819
3234 https://bugs.webkit.org/show_bug.cgi?id=123180
3236 Broke 32-bit builds (Requested by smfr on #webkit).
3238 * Configurations/WebCore.xcconfig:
3240 2013-10-22 Antti Koivisto <antti@apple.com>
3242 Rename deleteLineBoxTree to deleteLines
3243 https://bugs.webkit.org/show_bug.cgi?id=123176
3245 Reviewed by Andreas Kling.
3247 RenderBlock::deleteLineBoxTree -> RenderBlock::deleteLines
3248 RenderInline::deleteLineBoxTree -> RenderInline::deleteLines
3250 2013-10-22 Tim Horton <timothy_horton@apple.com>
3252 {ClipPathOperation, FilterOperation}::getOperationType() should not include 'get'
3253 https://bugs.webkit.org/show_bug.cgi?id=123172
3255 Reviewed by Simon Fraser.
3257 No new tests, just a rename.
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.
3263 Removed long and useless list of files.
3265 2013-10-22 Samuel White <samuel_white@apple.com>
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
3270 Reviewed by Chris Fleizach.
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.
3275 Test: platform/mac/accessibility/text-marker-for-bounds.html
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:]):
3289 2013-10-22 Zoltan Horvath <zoltan@webkit.org>
3291 [CSS Shapes] Match adjustLogicalLineTopAndLogicalHeightIfNeeded's implementation with Blink's
3292 https://bugs.webkit.org/show_bug.cgi?id=123033
3294 Reviewed by David Hyatt.
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.
3299 No new tests, covered by existing texts.
3301 * rendering/RenderBlockLineLayout.cpp:
3302 (WebCore::RenderBlockFlow::adjustLogicalLineTopAndLogicalHeightIfNeeded):
3304 2013-10-22 Daniel Bates <dabates@apple.com>
3306 [iOS] Upstream more ARMv7s bits
3307 https://bugs.webkit.org/show_bug.cgi?id=123052
3309 Reviewed by Joseph Pecoraro.
3311 * Configurations/WebCore.xcconfig:
3313 2013-10-22 Simon Fraser <simon.fraser@apple.com>
3315 Try to fix Mavericks build; use <> for framework include.
3317 * page/CaptionUserPreferencesMediaAF.cpp:
3319 2013-10-22 Tim Horton <timothy_horton@apple.com>
3321 GammaFilterOperation seems to be dead code
3322 https://bugs.webkit.org/show_bug.cgi?id=123173
3324 Reviewed by Simon Fraser.
3326 * platform/graphics/filters/FilterOperation.cpp:
3327 * platform/graphics/filters/FilterOperation.h:
3330 2013-10-22 Antti Koivisto <antti@apple.com>
3332 Rename some line box functions to be just about lines
3333 https://bugs.webkit.org/show_bug.cgi?id=123168
3335 Reviewed by Dave Hyatt.
3337 firstLineBoxBaseline -> firstLineBaseline
3338 hasInlineBoxChildren -> hasLines
3340 Also use hasLines in a bunch of places where firstLineBox() was used.
3342 * accessibility/AccessibilityRenderObject.cpp:
3343 (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
3345 Also use hasRenderedText() instead of firstTextBox()
3347 * rendering/RenderFullScreen.cpp:
3351 2013-10-22 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
3353 Adding Mock class to test RTCPeerConnection
3354 https://bugs.webkit.org/show_bug.cgi?id=122848
3356 Reviewed by Eric Carlson.
3358 The following tests can be run:
3360 RTCPeerConnection-createAnswer.html
3361 RTCPeerConnection-createOffer.html
3362 RTCPeerConnection-ice.html
3363 RTCPeerConnection-localDescription.html
3364 RTCPeerConnection-remoteDescription.html
3365 RTCPeerConnection-state.html
3367 Tests that require a MediaStream object, by invoking getUserMedia,
3368 are not ready to run yet.
3370 No new tests needed.
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:
3387 2013-10-22 Zan Dobersek <zdobersek@igalia.com>
3389 WebCore::fillWithEmptyClients adopts new empty clients before leaking their pointers
3390 https://bugs.webkit.org/show_bug.cgi?id=122945
3392 Reviewed by Anders Carlsson.
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.
3398 2013-10-22 Zan Dobersek <zdobersek@igalia.com>
3400 Simplify HRTFDatabaseLoader's load map
3401 https://bugs.webkit.org/show_bug.cgi?id=122944
3403 Reviewed by Eric Carlson.
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.
3412 2013-10-22 Tim Horton <timothy_horton@apple.com>
3414 Remote Layer Tree: Support hardware accelerated filters
3415 https://bugs.webkit.org/show_bug.cgi?id=123139
3417 Reviewed by Anders Carlsson.
3420 Export a variety of filter-related things.
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.
3433 2013-10-22 Brendan Long <b.long@cablelabs.com>
3435 cue.text fails for some track element cues
3436 https://bugs.webkit.org/show_bug.cgi?id=81123
3438 Reviewed by Eric Carlson.
3440 Test: media/track/track-long-captions-file.html
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.
3452 2013-10-22 peavo@outlook.com <peavo@outlook.com>
3454 [WinCairo] Compile error.
3455 https://bugs.webkit.org/show_bug.cgi?id=123161
3457 Reviewed by Brent Fulgham.
3459 * rendering/RenderFlowThread.h: Move USE(ACCELERATED_COMPOSITING) guard to expose needed type.
3461 2013-10-21 Brady Eidson <beidson@apple.com>
3463 Add a cross-platform IDBRecordIdentifier
3464 https://bugs.webkit.org/show_bug.cgi?id=123138
3466 Reviewed by Andreas Kling.
3468 Add the cross-platform header:
3469 * Modules/indexeddb/IDBRecordIdentifier.h: Added.
3470 (WebCore::IDBRecordIdentifier::create):
3471 (WebCore::IDBRecordIdentifier::encodedPrimaryKey):