64805d7fa1e90b1fe0f6c62c6a83c178b5c002ab
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-02-27  Brian Burg  <bburg@apple.com>
2
3         Web Inspector: model tests should use a special Test.html inspector page
4         https://bugs.webkit.org/show_bug.cgi?id=129190
5
6         Reviewed by Timothy Hatcher.
7
8         Convert InspectorController::isUnderTest() into a flag, and expose an
9         Internals method so it can be set by the test before opening the inspector.
10
11         Test: inspector/test-harness-trivially-works.html
12
13         * inspector/InspectorController.cpp:
14         (WebCore::InspectorController::evaluateForTestInFrontend):
15         * inspector/InspectorController.h:
16         * testing/Internals.cpp:
17         (WebCore::Internals::setInspectorIsUnderTest): Added.
18         * testing/Internals.h:
19         * testing/Internals.idl:
20
21 2014-02-27  Joseph Pecoraro  <pecoraro@apple.com>
22
23         Unreviewed build fix after r164824.
24
25         Accidentally re-added some code that was removed.
26
27         * page/ContentSecurityPolicy.cpp:
28
29 2014-02-26  Alex Christensen  <achristensen@webkit.org>
30
31         Compile fix when not using TEXTURE_MAPPER_GL.
32         https://bugs.webkit.org/show_bug.cgi?id=129417
33
34         Reviewed by Darin Adler.
35
36         * platform/graphics/texmap/TextureMapperGL.cpp:
37         Protect platformCreateAccelerated with USE(TEXTURE_MAPPER_GL).
38
39 2014-02-27  Joseph Pecoraro  <pecoraro@apple.com>
40
41         Web Inspector: JSContext inspection should report exceptions in the console
42         https://bugs.webkit.org/show_bug.cgi?id=128776
43
44         Reviewed by Timothy Hatcher.
45
46         Include some clean up of ConsoleMessage and ScriptCallStack construction.
47
48         Covered by existing tests.
49
50         * bindings/js/JSDOMBinding.cpp:
51         (WebCore::reportException):
52         Simplify code now that createStackTraceFromException handles it.
53
54         * page/ContentSecurityPolicy.cpp:
55         (WebCore::gatherSecurityPolicyViolationEventData):
56         (WebCore::ContentSecurityPolicy::reportViolation):
57         ScriptCallStack can give us the first non-native callframe.
58
59         * inspector/InspectorResourceAgent.cpp:
60         (WebCore::InspectorResourceAgent::buildInitiatorObject):
61         * inspector/PageDebuggerAgent.cpp:
62         (WebCore::PageDebuggerAgent::breakpointActionLog):
63         * inspector/TimelineRecordFactory.cpp:
64         (WebCore::TimelineRecordFactory::createGenericRecord):
65         * page/Console.cpp:
66         (WebCore::internalAddMessage):
67         (WebCore::Console::profile):
68         (WebCore::Console::profileEnd):
69         (WebCore::Console::timeEnd):
70         * page/ContentSecurityPolicy.cpp:
71         (WebCore::gatherSecurityPolicyViolationEventData):
72         (WebCore::ContentSecurityPolicy::reportViolation):
73         * page/DOMWindow.cpp:
74         (WebCore::DOMWindow::postMessage):
75
76 2014-02-27  Andreas Kling  <akling@apple.com>
77
78         Remove FeatureObserver.
79         <https://webkit.org/b/129439>
80
81         This code was only used by the Chromium port and nobody else is
82         making use of it.
83
84         Reviewed by Anders Carlsson.
85
86         * CMakeLists.txt:
87         * GNUmakefile.list.am:
88         * WebCore.vcxproj/WebCore.vcxproj:
89         * WebCore.vcxproj/WebCore.vcxproj.filters:
90         * WebCore.xcodeproj/project.pbxproj:
91         * dom/EventTarget.cpp:
92         (WebCore::EventTarget::fireEventListeners):
93         * dom/EventTarget.h:
94         * html/ColorInputType.cpp:
95         * html/ColorInputType.h:
96         * html/DateInputType.cpp:
97         * html/DateInputType.h:
98         * html/DateTimeInputType.cpp:
99         * html/DateTimeInputType.h:
100         * html/DateTimeLocalInputType.cpp:
101         * html/DateTimeLocalInputType.h:
102         * html/EmailInputType.cpp:
103         * html/EmailInputType.h:
104         * html/HTMLDataListElement.cpp:
105         (WebCore::HTMLDataListElement::create):
106         * html/HTMLFormControlElement.cpp:
107         (WebCore::HTMLFormControlElement::parseAttribute):
108         * html/HTMLInputElement.cpp:
109         (WebCore::HTMLInputElement::parseAttribute):
110         * html/HTMLTextFormControlElement.cpp:
111         (WebCore::HTMLTextFormControlElement::parseAttribute):
112         * html/InputType.cpp:
113         * html/InputType.h:
114         * html/MonthInputType.cpp:
115         * html/MonthInputType.h:
116         * html/NumberInputType.cpp:
117         * html/NumberInputType.h:
118         * html/RangeInputType.cpp:
119         * html/RangeInputType.h:
120         * html/SearchInputType.cpp:
121         * html/SearchInputType.h:
122         * html/TelephoneInputType.cpp:
123         * html/TelephoneInputType.h:
124         * html/TextInputType.cpp:
125         * html/TextInputType.h:
126         * html/TimeInputType.cpp:
127         * html/TimeInputType.h:
128         * html/URLInputType.cpp:
129         * html/URLInputType.h:
130         * html/WeekInputType.cpp:
131         * html/WeekInputType.h:
132         * loader/DocumentLoader.cpp:
133         (WebCore::DocumentLoader::responseReceived):
134         * loader/FrameLoader.cpp:
135         (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
136         (WebCore::FrameLoader::dispatchDidCommitLoad):
137         * page/ContentSecurityPolicy.cpp:
138         (WebCore::ContentSecurityPolicy::didReceiveHeader):
139         * page/EventHandler.cpp:
140         (WebCore::EventHandler::selectCursor):
141         * page/FeatureObserver.cpp: Removed.
142         * page/FeatureObserver.h: Removed.
143         * page/Page.h:
144         * rendering/RenderDeprecatedFlexibleBox.cpp:
145         (WebCore::RenderDeprecatedFlexibleBox::RenderDeprecatedFlexibleBox):
146         * rendering/RenderLayer.cpp:
147         (WebCore::RenderLayer::calculateClipRects):
148         * workers/SharedWorker.cpp:
149         (WebCore::SharedWorker::create):
150         * workers/Worker.cpp:
151         (WebCore::Worker::create):
152
153 2014-02-27  Chris Fleizach  <cfleizach@apple.com>
154
155         speechSynthesis.speak of a zero length utterance kills future speech
156         https://bugs.webkit.org/show_bug.cgi?id=129403
157
158         Reviewed by Mario Sanchez Prada.
159
160         Empty length strings may choke a synthesizer and result in didFinishSpeaking not being called. 
161         The WebKit code should be proactive about screening out empty length strings.
162
163         Test: platform/mac/fast/speechsynthesis/speech-synthesis-speak-empty-string.html
164
165         * Modules/speech/SpeechSynthesis.cpp:
166         (WebCore::SpeechSynthesis::startSpeakingImmediately):
167
168 2014-02-27  Commit Queue  <commit-queue@webkit.org>
169
170         Unreviewed, rolling out r164783.
171         http://trac.webkit.org/changeset/164783
172         https://bugs.webkit.org/show_bug.cgi?id=129425
173
174         Broke number of multicol tests (Requested by anttik on
175         #webkit).
176
177         * rendering/RenderBlock.cpp:
178         (WebCore::RenderBlock::containingColumnsBlock):
179
180 2014-02-27  Antoine Quint  <graouts@webkit.org>
181
182         Respect SVG fragment identifiers in <img> src attribute
183         https://bugs.webkit.org/show_bug.cgi?id=129387
184
185         Reviewed by Antti Koivisto.
186
187         Test: svg/css/svg-resource-fragment-identifier-img-src.html
188
189         When providing an SVG image for a given renderer, check that the URL used to load
190         that image is taken into account in case it featured a fragment identifier, ensuring
191         that the CSS :target pseudo-class is correctly handled for SVG resources. This patch
192         is specific to <img> elements, specific support will also need to be added for various
193         CSS properties that support SVG images.
194
195         * svg/graphics/SVGImageCache.cpp:
196         (WebCore::SVGImageCache::imageForRenderer):
197         Check if the provided renderer is attached to an <img> element and, if so, pass the
198         resolved <img> source URL, taking into account srcset, to the SVGImageForContainer.
199
200         * svg/graphics/SVGImageForContainer.cpp:
201         (WebCore::SVGImageForContainer::setURL):
202         Trigger the FrameView machinery to ensure that the :target pseudo-class is respected
203         should the provided URL feature a fragment identifier.
204
205         * svg/graphics/SVGImageForContainer.h:
206         Declare the new setURL() method.
207
208 2014-02-27  Krzysztof Czech  <k.czech@samsung.com>
209
210         [ATK] Fix style errors in enum members
211         https://bugs.webkit.org/show_bug.cgi?id=129421
212
213         Reviewed by Mario Sanchez Prada.
214
215         No new tests. No new functionality.
216
217         Enum members should use InterCaps with an initial capital letter.
218
219         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
220         (getInterfaceMaskFromObject):
221
222 2014-02-27  Mihai Tica  <mitica@adobe.com>
223
224         [CSS Blending] Parse and implement the -webkit-isolation CSS property.
225
226         https://bugs.webkit.org/show_bug.cgi?id=128958
227
228         Reviewed by Dirk Schulze.
229
230         Parse and implement -webkit-isolation, part of the CSS Blending and Compositing spec.
231         This patch adds functionality for HTML and SVG.
232         -webkit-isolation: isolate restricts any child elements from blending with any of the content outside the isolated parent element.
233
234         Tests: css3/compositing/isolation-isolate-blended-child.html
235                css3/compositing/isolation-parsing.html
236                css3/compositing/svg-isolation-default.html
237                css3/compositing/svg-isolation-isolated-group.html
238                css3/compositing/svg-isolation-simple.html
239
240         * css/CSSComputedStyleDeclaration.cpp:
241         (WebCore::ComputedStyleExtractor::propertyValue):
242         * css/CSSParser.cpp:
243         (WebCore::isValidKeywordPropertyAndValue):
244         (WebCore::isKeywordPropertyID):
245         (WebCore::CSSParser::parseValue):
246         * css/CSSPrimitiveValueMappings.h:
247         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
248         (WebCore::CSSPrimitiveValue::operator Isolation):
249         * css/CSSPropertyNames.in: Add -webkit-isolation.
250         * css/CSSValueKeywords.in: Add the isolate value.
251         * css/DeprecatedStyleBuilder.cpp:
252         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
253         * css/StyleResolver.cpp:
254         (WebCore::StyleResolver::adjustRenderStyle): Explicitly set isolation:isolate to create a stacking context.
255         * rendering/style/RenderStyle.cpp:
256         (WebCore::RenderStyle::changeRequiresLayerRepaint): Changing isolation should trigger a repaint.
257         * rendering/style/RenderStyle.h: Setters and getters for isolation.
258         * rendering/style/RenderStyleConstants.h: Add Isolation enum.
259         * rendering/style/StyleRareNonInheritedData.cpp: Add m_isolation.
260         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
261         (WebCore::StyleRareNonInheritedData::operator==):
262         * rendering/style/StyleRareNonInheritedData.h:
263         * rendering/svg/SVGRenderingContext.cpp:
264         (WebCore::SVGRenderingContext::prepareToRenderSVGContent): If isolated, paint in a transparency layer.
265
266 2014-02-27  Krzysztof Czech  <k.czech@samsung.com>
267
268         [ATK] Utilize AtkTableCell to expose directly AccessibilityTableCell to AT
269         https://bugs.webkit.org/show_bug.cgi?id=129250
270
271         Reviewed by Mario Sanchez Prada.
272
273         Test: accessibility/table-scope.html
274
275         Exposing AtkTableCell to AT. Implementing possibility to get column headers and row headers
276         as an array of cells.
277
278         * GNUmakefile.list.am:
279         * PlatformEfl.cmake:
280         * accessibility/atk/WebKitAccessibleInterfaceTableCell.cpp: Added.
281         (convertToGPtrArray):
282         (core):
283         (webkitAccessibleTableCellGetColumnHeaderCells):
284         (webkitAccessibleTableCellGetRowHeaderCells):
285         (webkitAccessibleTableCellInterfaceInit):
286         * accessibility/atk/WebKitAccessibleInterfaceTableCell.h: Added.
287         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
288         (getInterfaceMaskFromObject):
289
290 2014-02-27  Renata Hodovan  <rhodovan.u-szeged@partner.samsung.com>
291
292         Improving containing column block determination
293         https://bugs.webkit.org/show_bug.cgi?id=125449
294
295         Reviewed by Darin Adler.
296
297         Making sure that the containing column block of any elements
298         can not be oneself.
299
300         Test: fast/css/crash-on-column-splitting.html
301
302         * rendering/RenderBlock.cpp:
303         (WebCore::RenderBlock::containingColumnsBlock):
304         (WebCore::RenderBlock::splitFlow):
305
306 2014-02-27  Xabier Rodriguez Calvar  <calvaris@igalia.com>
307
308         [GTK] Improve JavaScript multimedia controls
309         https://bugs.webkit.org/show_bug.cgi?id=129044
310
311         Reviewed by Jer Noble.
312
313         After webkit.org/b/123097 a follow up was needed to improve
314         accessibily and some other cosmetic problems, like cleaner CSS and
315         new missing baselines.
316
317         No new tests because of no new functionality.
318
319         * Modules/mediacontrols/mediaControlsApple.js:
320         Added hiding class name.
321         * Modules/mediacontrols/mediaControlsGtk.js:
322         (ControllerGtk.prototype.createControls): Set remaining time as
323         hidden by default and turned volumebox hidden into hiding.
324         (ControllerGtk.prototype.updateTime): Simplified the hiding and
325         showing by removing the show class and using hidden only.
326         (ControllerGtk.prototype.handleMuteButtonMouseOver):
327         (ControllerGtk.prototype.handleVolumeBoxMouseOut): Turned hidden
328         into hiding.
329         (ControllerGtk.prototype.updateReadyState): Changed coding style
330         and added down class for the panel too.
331         (ControllerGtk.prototype.updatePlaying): Change for coding style
332         coherence.
333         (ControllerGtk.prototype.handleCaptionButtonClicked): Call
334         handleCaptionButtonShowMenu.
335         (ControllerGtk.prototype.handleCaptionButtonMouseOver): Call
336         handleCaptionButtonShowMenu.
337         (ControllerGtk.prototype.handleCaptionButtonShowMenu): Created
338         with the former behavior of handleCaptionButtonMouseOver.
339         * css/mediaControlsGtk.css:
340         (.hidden): Set display none for all objects with hidden class.
341         (audio::-webkit-media-controls-panel *:focus):
342         (audio::-webkit-media-controls-panel.down *:focus): Added gradient
343         for the active and focus status.
344         (audio::-webkit-media-controls-time-remaining-display)
345         (video::-webkit-media-controls-time-remaining-display): Set
346         display block.
347         (audio::-webkit-media-controls-volume-slider-container)
348         (video::-webkit-media-controls-volume-slider-container): Set
349         display flex.
350         (video::-webkit-media-controls-volume-slider-container.hiding):
351         Changed from hidden.
352         (video::-webkit-media-controls-panel .hiding.down): Changed from
353         hidden.
354         * platform/gtk/RenderThemeGtk.cpp:
355         (WebCore::RenderThemeGtk::paintMediaButton): Returning true to
356         allow CSS painting the gradient.
357
358 2014-02-27  Zan Dobersek  <zdobersek@igalia.com>
359
360         Unreviewed. Fixing the GTK build fix after r164757.
361
362         * platform/network/NetworkStateNotifier.cpp: r164757 introduced a layering violation by including
363         the Settings.h header. The use of that class is guarded by PLATFORM(IOS), so the header inclusion
364         should be guarded as well.
365
366 2014-02-26  Ryosuke Niwa  <rniwa@webkit.org>
367
368         Extract named items caches in HTMLCollection as a class
369         https://bugs.webkit.org/show_bug.cgi?id=129365
370
371         Reviewed by Antti Koivisto.
372
373         Extracted CollectionNamedElementCache, like CollectionIndexCache, out of HTMLCollection.
374         We can move more named item related functions into this class in the future.
375
376         HTMLCollection's member variables m_isNameCacheValid, m_idCache, and m_nameCache were replaced by
377         a single unique_ptr that holds an instance of CollectionNamedElementCache since this object rarely
378         exists in most HTMLCollections.
379
380         Also removed m_isItemRefElementsCacheValid since it was only used by Microdata API removed in r153772
381         and renamed a whole bunch of member functions and variables for consistency.
382
383         * dom/Document.cpp:
384         (WebCore::Document::collectionCachedIdNameMap):
385         (WebCore::Document::collectionWillClearIdNameMap):
386         * dom/Document.h:
387         * dom/NodeRareData.h:
388         (WebCore::NodeListsNodeData::adoptDocument):
389         * html/HTMLAllCollection.cpp:
390         (WebCore::HTMLAllCollection::namedItemWithIndex):
391         * html/HTMLCollection.cpp:
392         (WebCore::HTMLCollection::HTMLCollection):
393         (WebCore::HTMLCollection::~HTMLCollection):
394         (WebCore::HTMLCollection::invalidateCache):
395         (WebCore::HTMLCollection::invalidateNamedElementCache): Renamed from invalidateIdNameCacheMaps.
396         (WebCore::HTMLCollection::namedItem):
397         (WebCore::HTMLCollection::updateNamedElementCache): Renamed from updateNameCache.
398         (WebCore::HTMLCollection::namedItems):
399
400         * html/HTMLCollection.h:
401         (WebCore::CollectionNamedElementCache::findElementsWithId): Renamed from HTMLCollection::idCache.
402         (WebCore::CollectionNamedElementCache::findElementsWithName): Renamed from HTMLCollection::nameCache.
403         (WebCore::CollectionNamedElementCache::appendIdCache): Moved from HTMLCollection.
404         (WebCore::CollectionNamedElementCache::appendNameCache): Ditto.
405         (WebCore::CollectionNamedElementCache::find): Ditto.
406         (WebCore::CollectionNamedElementCache::append): Ditto.
407
408         (WebCore::HTMLCollection::invalidateCache):
409         (WebCore::HTMLCollection::hasNamedElementCache): Renamed from hasIdNameCache.
410         (WebCore::HTMLCollection::createNameItemCache): Added.
411         (WebCore::HTMLCollection::namedItemCaches): Added.
412
413         * html/HTMLFormControlsCollection.cpp:
414         (WebCore::HTMLFormControlsCollection::updateNamedElementCache):
415         * html/HTMLFormControlsCollection.h:
416
417 2014-02-26  Ryosuke Niwa  <rniwa@webkit.org>
418
419         Indenting an indented image element resulted in an extra indentation
420         https://bugs.webkit.org/show_bug.cgi?id=129201
421
422         Reviewed by Enrica Casucci.
423
424         The bug was caused by endOfParagraph returning a position at the beginning of a block when the position
425         passed into the function was at the beginning of the block. Consider the following DOM:
426         <blockquote><img></blockquote>
427
428         When endOfParagraph is called on (blockquote, 0), the condition r->isBR() || isBlock(n) in endOfParagraph
429         matches immediately on startNode and it returns (blockquote, 0) again.
430
431         This resulted in moveParagraphWithClones invoked by indentIntoBlockquote to erroneously clone the inner
432         blockquote. Worked around this bug in ApplyBlockElementCommand::formatSelection by checking this specific
433         condition and moving the position to the end of the block. Unfortunately, a lot of existing code depends
434         on the current behavior of endOfParagraph so fixing the function itself was not possible.
435
436         There was another bug in indentIntoBlockquote to incorrectly insert a new blockquote into the existing
437         blockquote due to the code introduced in r99594 to avoid inserting before the root editable element.
438         Since this happens only if outerBlock is the root editable element, which is nodeToSplitTo or an ancestor
439         of nodeToSplitTo, explicitly look for this condition.
440
441         Test: editing/execCommand/indent-img-twice.html
442
443         * editing/ApplyBlockElementCommand.cpp:
444         (WebCore::ApplyBlockElementCommand::formatSelection):
445         (WebCore::isNewLineAtPosition):
446         * editing/IndentOutdentCommand.cpp:
447         (WebCore::IndentOutdentCommand::indentIntoBlockquote):
448         * editing/VisibleUnits.cpp:
449         (WebCore::endOfParagraph): Added a FIXME.
450
451 2014-02-26  Simon Fraser  <simon.fraser@apple.com>
452
453         Fix two assertions/crashes in compositing code
454         https://bugs.webkit.org/show_bug.cgi?id=129414
455
456         Reviewed by Dean Jackson.
457
458         Fix two issues introduced in r164759.
459
460         * rendering/RenderLayerCompositor.cpp:
461         (WebCore::RenderLayerCompositor::removeFromScrollCoordinatedLayers): Don't call
462         ourselves recursively!
463         (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer): We call this
464         function unconditionally on layer teardown, so this assertion is bogus.
465
466 2014-02-26  Simon Fraser  <simon.fraser@apple.com>
467
468         Fix the build with some compiler configurations.
469
470         * platform/mac/ScrollAnimatorMac.mm:
471         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
472         (WebCore::ScrollAnimatorMac::didAddVerticalScrollbar):
473         (WebCore::ScrollAnimatorMac::didAddHorizontalScrollbar):
474
475 2014-02-26  Myles C. Maxfield  <mmaxfield@apple.com>
476
477         Ranges given to createMarkupInternal might not be canonicalized
478         https://bugs.webkit.org/show_bug.cgi?id=129408
479
480         Reviewed by Ryosuke Niwa.
481
482         When WebKit clients (such as Mail) call WKWebArchiveCreateFromRange() with a range,
483         that range is not necessarily canonicalized. Therefore, comparing it for equality
484         with a canonicalized range might return a false negative. Instead, we should compare
485         canonicalized ranges.
486
487         No new tests because this codepath will only be reached via SPI.
488
489         * editing/markup.cpp:
490         (WebCore::createMarkupInternal):
491
492 2014-02-26  Enrica Casucci  <enrica@apple.com>
493
494         [iOS WebKit2] Form controls handling: implement date and time controls.
495         https://bugs.webkit.org/show_bug.cgi?id=129344
496
497         Reviewed by Simon Fraser and Joseph Pecoraro.
498
499         Adding one localizable string.
500
501         * English.lproj/Localizable.strings:
502
503 2014-02-26  Simon Fraser  <simon.fraser@apple.com>
504
505         Prepare for overflow scrolling nodes in the scrolling tree
506         https://bugs.webkit.org/show_bug.cgi?id=129398
507
508         Reviewed by Tim Horton.
509
510         Lay some groundwork for overflow:scrolling nodes in the scrolling tree.
511         Change terminology to refer to "scroll-coordinatored" layers now, not just viewport-constrained
512         layers.
513         
514         A given layer can be both viewport-constrained and overflow-scrolling (e.g. position:fixed,
515         overflow:scroll), so handle that in RenderLayerBacking, and use some "reason" flags
516         in RenderLayerCompositor.
517
518         * page/FrameView.cpp:
519         (WebCore::FrameView::scrollLayerID): Rename
520         * page/scrolling/ScrollingStateTree.cpp:
521         (WebCore::ScrollingStateTree::attachNode): Remove invalid assertion.
522         * rendering/RenderLayerBacking.cpp:
523         (WebCore::RenderLayerBacking::RenderLayerBacking):
524         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
525         (WebCore::RenderLayerBacking::updateScrollingLayers): Simplify the logic with
526         an early return.
527         (WebCore::RenderLayerBacking::detachFromScrollingCoordinator):
528         Allow a layer to play both viewport-constrained and scrolling roles
529         in the scrolling tree.
530         * rendering/RenderLayerBacking.h:
531         (WebCore::RenderLayerBacking::viewportConstrainedNodeID):
532         (WebCore::RenderLayerBacking::setViewportConstrainedNodeID):
533         (WebCore::RenderLayerBacking::scrollingNodeID):
534         (WebCore::RenderLayerBacking::setScrollingNodeID):
535         (WebCore::RenderLayerBacking::scrollingNodeIDForChildren):
536         * rendering/RenderLayerCompositor.cpp:
537         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
538         (WebCore::RenderLayerCompositor::didFlushChangesForLayer):
539         (WebCore::RenderLayerCompositor::updateBacking):
540         (WebCore::RenderLayerCompositor::layerWillBeRemoved):
541         (WebCore::RenderLayerCompositor::fixedRootBackgroundLayerChanged):
542         (WebCore::RenderLayerCompositor::clearBackingForLayerIncludingDescendants):
543         (WebCore::RenderLayerCompositor::requiresCompositingLayer):
544         (WebCore::RenderLayerCompositor::requiresOwnBackingStore):
545         (WebCore::RenderLayerCompositor::reasonsForCompositing):
546         (WebCore::RenderLayerCompositor::requiresCompositingForScrolling):
547         (WebCore::isViewportConstrainedFixedOrStickyLayer):
548         (WebCore::isMainFrameScrollingOrOverflowScrolling):
549         (WebCore::RenderLayerCompositor::rootLayerAttachmentChanged):
550         (WebCore::RenderLayerCompositor::updateScrollCoordinatedStatus):
551         (WebCore::RenderLayerCompositor::removeFromScrollCoordinatedLayers):
552         (WebCore::nearestScrollCoordinatedAncestor):
553         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
554         (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer):
555         (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
556         (WebCore::RenderLayerCompositor::willRemoveScrollingLayer):
557         (WebCore::RenderLayerCompositor::didAddScrollingLayer):
558         * rendering/RenderLayerCompositor.h:
559
560 2014-02-26  Andy Estes  <aestes@apple.com>
561
562         [iOS] Support network state notification using CPNetworkObserver
563         https://bugs.webkit.org/show_bug.cgi?id=129358
564
565         Reviewed by Dan Bernstein.
566
567         Add iOS support for navigator.onLine and online/offline events. Since
568         it can be expensive to query CPNetworkObserver, wait to do so until
569         someone calls NetworkStateObserver::onLine() or
570         NetworkStateObserver::addNetworkStateChangeListener(). For clients that
571         don't wish to observe network reachability at all, add a global opt-out.
572         These clients will only pay the cost of CPNetworkObserver if they load
573         a page that explicitly accesses navigator.onLine.
574
575         No new tests. Covered by existing tests.
576
577         * WebCore.exp.in: Stopped exporting NetworkStateNotifier::setIsOnLine()
578         and started exporting Settings::gShouldOptOutOfNetworkStateObservation.
579         * WebCore.xcodeproj/project.pbxproj: Renamed NetworkStateNotifierIOS.cpp
580         to NetworkStateNotifierIOS.mm.
581         * page/Settings.cpp: Defaulted gShouldOptOutOfNetworkStateObservation
582         to false.
583         * page/Settings.h:
584         (WebCore::Settings::setShouldOptOutOfNetworkStateObservation):
585         (WebCore::Settings::shouldOptOutOfNetworkStateObservation):
586         * platform/network/NetworkStateNotifier.cpp:
587         (WebCore::NetworkStateNotifier::addNetworkStateChangeListener): Ignored
588         the listener if Settings::shouldOptOutOfNetworkStateObservation().
589         Called registerObserverIfNecessary() and added the listener otherwise.
590         (WebCore::NetworkStateNotifier::notifyNetworkStateChange): Const qualified.
591         * platform/network/NetworkStateNotifier.h
592         (NetworkStateNotifier::onLine):
593         * platform/network/ios/NetworkStateNotifierIOS.cpp: Removed.
594         * platform/network/ios/NetworkStateNotifierIOS.mm: Added.
595         (-[NetworkStateObserver initWithNotifier:WebCore::]): Registered self
596         as a network reachable observer on CPNetworkObserver.
597         (-[NetworkStateObserver dealloc]): Removed self as a network reachable
598         observer.
599         (-[NetworkStateObserver networkStateChanged:]): Called setOnLine() on
600         the web thread, passing the reachability value from the notification.
601         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
602         (WebCore::NetworkStateNotifier::~NetworkStateNotifier): Cleared
603         m_observer's pointer back to us.
604         (WebCore::NetworkStateNotifier::registerObserverIfNecessary): Initialized
605         m_observer if necessary.
606         (WebCore::NetworkStateNotifier::onLine): Called
607         registerObserverIfNecessary() and set an initial value for m_isOnLine
608         if m_isOnLineInitialized is false. Returned m_isOnLine.
609         (WebCore::setOnLine): Set m_isOnLine and called
610         notifyNetworkStateChange() if needed. Unconditionally set
611         m_isOnLineInitialized to true.
612
613 2014-02-26  Brian Burg  <bburg@apple.com>
614
615         Unreviewed build fix for !ENABLE(CONTEXT_MENUS).
616
617         I forgot to add guards to handleContextMenuEvent().
618
619         * replay/UserInputBridge.cpp:
620         * replay/UserInputBridge.h:
621
622 2014-02-26  Dean Jackson  <dino@apple.com>
623
624         [WebGL] Only skip context error retrieval if a pending context
625         https://bugs.webkit.org/show_bug.cgi?id=129397
626
627         Reviewed by Tim Horton.
628
629         A lost context should still ask the GC3D what the error is. Only
630         a pending context should return early.
631
632         * html/canvas/WebGLRenderingContext.cpp:
633         (WebCore::WebGLRenderingContext::getError):
634
635 2014-02-26  Brian Burg  <bburg@apple.com>
636
637         Web Replay: route through UserInputBridge when delivering user inputs to WebCore
638         https://bugs.webkit.org/show_bug.cgi?id=128150
639
640         Reviewed by Timothy Hatcher.
641
642         Add an UserInputBridge instance to each Page. WebKit2 routes a page's user inputs through
643         the WebCore page's user input bridge so that the inputs can be selectively captured, filtered,
644         and replayed using instrumentation inside the UserInputBridge.
645
646         For now, the routing methods of UserInputBridge have no replay-specific code paths, and just
647         put the input delivery code inside WebCore rather than its external clients. Replay-specific
648         code paths will be added once https://bugs.webkit.org/show_bug.cgi?id=128782 is fixed. However,
649         once complete the code will work as follows:
650
651         - When neither capturing or replaying, behavior is unchanged.
652
653         - When capturing user inputs, each external input is saved into a replay log as it crosses
654         the bridge from outside WebCore.
655
656         - When replaying, the bridge closes and user inputs from WebKit2 are not accepted. Instead,
657         the saved inputs from the replay log are re-dispatched as if they had crossed the bridge.
658
659         * CMakeLists.txt:
660         * GNUmakefile.am:
661         * GNUmakefile.list.am:
662         * WebCore.exp.in: Add symbols for input routing methods.
663         * WebCore.vcxproj/WebCore.vcxproj:
664         * WebCore.vcxproj/WebCore.vcxproj.filters:
665         * WebCore.xcodeproj/project.pbxproj:
666         * page/Page.cpp:
667         (WebCore::Page::Page): Initialize the owned UserInputBridge in the Page constructor.
668         * page/Page.h:
669         (WebCore::Page::inputBridge): Added a by-reference getter.
670         * replay/UserInputBridge.cpp: Added.
671         (WebCore::UserInputBridge::UserInputBridge):
672         (WebCore::UserInputBridge::~UserInputBridge):
673         (WebCore::UserInputBridge::handleContextMenuEvent):
674         (WebCore::UserInputBridge::handleMousePressEvent):
675         (WebCore::UserInputBridge::handleMouseReleaseEvent):
676         (WebCore::UserInputBridge::handleMouseMoveEvent):
677         (WebCore::UserInputBridge::handleMouseMoveOnScrollbarEvent):
678         (WebCore::UserInputBridge::handleKeyEvent):
679         (WebCore::UserInputBridge::handleAccessKeyEvent):
680         (WebCore::UserInputBridge::handleWheelEvent):
681         (WebCore::UserInputBridge::focusSetActive):
682         (WebCore::UserInputBridge::focusSetFocused):
683         (WebCore::UserInputBridge::scrollRecursively):
684         (WebCore::UserInputBridge::logicalScrollRecursively):
685         (WebCore::UserInputBridge::loadRequest):
686         (WebCore::UserInputBridge::reloadFrame):
687         (WebCore::UserInputBridge::stopLoadingFrame):
688         (WebCore::UserInputBridge::tryClosePage):
689         * replay/UserInputBridge.h: Added.
690
691 2014-02-26  Dean Jackson  <dino@apple.com>
692
693         [WebGL] Protect more WebGL entry points for pending contexts
694         https://bugs.webkit.org/show_bug.cgi?id=129386
695
696         Reviewed by Tim Horton.
697
698         There are entry points into a WebGLRenderingContext that don't
699         come from the web-exposed API directly, such as drawImage with
700         the WebGL canvas. Protect these by returning early if we're
701         a pending context.
702
703         Also a bunch of drive-by 0 -> nullptr changes.
704
705         * html/canvas/WebGLRenderingContext.cpp:
706         (WebCore::WebGLRenderingContext::markLayerComposited):
707         (WebCore::WebGLRenderingContext::paintRenderingResultsToCanvas):
708         (WebCore::WebGLRenderingContext::paintRenderingResultsToImageData):
709         (WebCore::WebGLRenderingContext::reshape):
710         (WebCore::WebGLRenderingContext::createBuffer):
711         (WebCore::WebGLRenderingContext::createFramebuffer):
712         (WebCore::WebGLRenderingContext::createTexture):
713         (WebCore::WebGLRenderingContext::createProgram):
714         (WebCore::WebGLRenderingContext::createRenderbuffer):
715         (WebCore::WebGLRenderingContext::createShader):
716         (WebCore::WebGLRenderingContext::getActiveAttrib):
717         (WebCore::WebGLRenderingContext::getActiveUniform):
718         (WebCore::WebGLRenderingContext::getContextAttributes):
719         (WebCore::WebGLRenderingContext::getError):
720         (WebCore::WebGLRenderingContext::getExtension):
721         (WebCore::WebGLRenderingContext::getShaderPrecisionFormat):
722         (WebCore::WebGLRenderingContext::getUniformLocation):
723         (WebCore::WebGLRenderingContext::drawImageIntoBuffer):
724         (WebCore::WebGLRenderingContext::videoFrameToImage):
725         (WebCore::WebGLRenderingContext::validateBufferDataParameters):
726         (WebCore::WebGLRenderingContext::LRUImageBufferCache::imageBuffer):
727
728 2014-02-26  Bem Jones-Bey  <bjonesbe@adobe.com>
729
730         [CSS Shapes] inset and inset-rectangle trigger assert with replaced element and large percentage dimension
731         https://bugs.webkit.org/show_bug.cgi?id=129060
732
733         Reviewed by Simon Fraser.
734
735         A bounds check was omitted when computing the width and height for inset
736         rectangles, making it possible for the width or height to end up being
737         negative. This patch adds in that check for both. It seems that only
738         replaced elements like iframe and img trigger this problem.
739
740         Tests: fast/shapes/shape-outside-floats/shape-outside-floats-img-inset-negative-width-crash.html
741                fast/shapes/shape-outside-floats/shape-outside-floats-img-inset-rectangle-negative-width-crash.html
742
743         * rendering/shapes/Shape.cpp:
744         (WebCore::Shape::createShape):
745
746 2014-02-26  Myles C. Maxfield  <mmaxfield@apple.com>
747
748         Underlines are too thick when zoomed in
749         https://bugs.webkit.org/show_bug.cgi?id=129352
750
751         Reviewed by Dean Jackson.
752
753         The input to the underline drawing code is in user-space, not device-space.
754         The underlines were getting scaled twice, once in InlineTextBox and the other
755         in GraphicsContext.
756
757         Test: fast/css3-text/css3-text-decoration/text-decoration-scaled.html
758
759         * rendering/InlineTextBox.cpp:
760         (WebCore::InlineTextBox::paintDecoration):
761
762 2014-02-26  Andreas Kling  <akling@apple.com>
763
764         Remove unused InspectorCounters.
765         <https://webkit.org/b/129367>
766
767         The InspectorCounters code was only used to implement two layout test
768         APIs (window.internals.numberOfLive{Nodes,Documents}) yet it had hooks
769         in crazy places like Node construction and destruction.
770
771         Rewrote the internals APIs to iterate over all live Documents instead,
772         totaling up their referencing Node count. Added a process-global
773         Document::allDocuments() HashSet to make this whole thing possible.
774
775         Reviewed by Sam Weinig.
776
777         * CMakeLists.txt:
778         * GNUmakefile.list.am:
779         * WebCore.exp.in:
780         * WebCore.vcxproj/WebCore.vcxproj:
781         * WebCore.vcxproj/WebCore.vcxproj.filters:
782         * WebCore.xcodeproj/project.pbxproj:
783         * bindings/js/JSEventListener.cpp:
784         * dom/Document.cpp:
785         (WebCore::Document::allDocuments):
786         (WebCore::Document::Document):
787         (WebCore::Document::~Document):
788         * dom/Document.h:
789         (WebCore::Node::Node):
790         * dom/Node.cpp:
791         (WebCore::Node::~Node):
792         * inspector/InspectorAllInOne.cpp:
793         * inspector/InspectorCounters.cpp: Removed.
794         * inspector/InspectorCounters.h: Removed.
795         * inspector/InspectorTimelineAgent.cpp:
796         (WebCore::InspectorTimelineAgent::start):
797         (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline):
798         (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
799         * inspector/InspectorTimelineAgent.h:
800         * inspector/protocol/Timeline.json:
801         * platform/ThreadGlobalData.cpp:
802         * testing/Internals.cpp:
803         (WebCore::Internals::numberOfLiveNodes):
804         (WebCore::Internals::numberOfLiveDocuments):
805         * testing/Internals.h:
806         * testing/Internals.idl:
807
808 2014-02-26  Joseph Pecoraro  <pecoraro@apple.com>
809
810         Web Inspector: Remove console.profiles from window.console API
811         https://bugs.webkit.org/show_bug.cgi?id=116883
812
813         Reviewed by Timothy Hatcher.
814
815         console.profiles has been removed or never implemented by other
816         browsers. We should remove it as well. However, since tests
817         rely on it, keep it as window.internals.consoleProfiles.
818
819         * WebCore.exp.in:
820         * page/Console.idl:
821         * testing/Internals.cpp:
822         (WebCore::Internals::consoleProfiles):
823         * testing/Internals.h:
824         * testing/Internals.idl:
825
826 2014-02-26  Martin Hock  <mhock@apple.com>
827
828         Create SessionID value-style class for session IDs.
829         https://bugs.webkit.org/show_bug.cgi?id=129141
830
831         Reviewed by Sam Weinig.
832
833         * GNUmakefile.list.am:
834         * WebCore.exp.in:
835         * WebCore.xcodeproj/project.pbxproj:
836         * page/Page.cpp: Add SessionID member.
837         (WebCore::Page::Page):
838         (WebCore::Page::sessionID): Retrieve sessionID or use settings if not set.
839         * page/Page.h:
840         (WebCore::Page::isSessionIDSet):
841         (WebCore::Page::setSessionID):
842         * page/SessionID.h: Session ID class consisting solely of its uint64_t session ID.
843         (WebCore::SessionID::SessionID):
844         (WebCore::SessionID::isValid): Not empty.
845         (WebCore::SessionID::isEphemeral):
846         (WebCore::SessionID::sessionID):
847         (WebCore::SessionID::operator==): Value-based equality.
848         (WebCore::SessionID::operator!=):
849         (WebCore::SessionID::emptySessionID): Zero value also used for HashTraits emptyValue.
850         (WebCore::SessionID::defaultSessionID):
851         (WebCore::SessionID::legacyPrivateSessionID):
852         * page/SessionIDHash.h:
853         (WTF::SessionIDHash::hash): Just the casted session ID (low order bytes)
854         (WTF::SessionIDHash::equal):
855         (WTF::HashTraits<WebCore::SessionID>::emptyValue): Equal to emptySessionID.
856         (WTF::HashTraits<WebCore::SessionID>::constructDeletedValue): -1 value.
857         (WTF::HashTraits<WebCore::SessionID>::isDeletedValue):
858
859 2014-02-26  Eric Carlson  <eric.carlson@apple.com>
860
861         Fix builds that don't define IMAGE_CONTROLS.
862
863         * page/ContextMenuContext.cpp:
864         (WebCore::ContextMenuContext::ContextMenuContext):
865
866 2014-02-26  Eric Carlson  <eric.carlson@apple.com>
867
868         Build fix for OS X after r164720.
869
870         * page/ContextMenuContext.cpp:
871
872 2014-02-26  Brady Eidson  <beidson@apple.com>
873
874         Pipe experimental image controls menu up to WebKit2
875         https://bugs.webkit.org/show_bug.cgi?id=129339
876
877         Reviewed by Simon Fraser.
878
879         Handle events for the image control, starting down the context menu code path if appropriate:
880         * html/shadow/mac/ImageControlsRootElementMac.cpp:
881         (WebCore::ImageControlsRootElementMac::defaultEventHandler):
882         * html/shadow/mac/ImageControlsRootElementMac.h:
883
884         Add a class to hold a HitTestResult and addition info about the current ContextMenu invocation:
885         * page/ContextMenuContext.cpp: Added.
886         (WebCore::ContextMenuContext::ContextMenuContext):
887         * page/ContextMenuContext.h: Added.
888         (WebCore::ContextMenuContext::hitTestResult):
889         (WebCore::ContextMenuContext::isImageControl):
890
891         Update ContextMenuController to work with ContextMenuContext instead of HitTestResult directly:
892         * page/ContextMenuController.cpp:
893         (WebCore::ContextMenuController::showContextMenu):
894         (WebCore::ContextMenuController::createContextMenu):
895         (WebCore::ContextMenuController::contextMenuItemSelected):
896         (WebCore::ContextMenuController::populate):
897         (WebCore::ContextMenuController::addInspectElementItem):
898         (WebCore::ContextMenuController::checkOrEnableIfNeeded):
899         (WebCore::ContextMenuController::showImageControlsMenu):
900         * page/ContextMenuController.h:
901         (WebCore::ContextMenuController::contextMenu):
902         (WebCore::ContextMenuController::setContextMenuContext):
903         (WebCore::ContextMenuController::context):
904         (WebCore::ContextMenuController::hitTestResult):
905
906         * CMakeLists.txt:
907         * GNUmakefile.list.am:
908         * WebCore.vcxproj/WebCore.vcxproj:
909         * WebCore.xcodeproj/project.pbxproj:
910
911 2014-02-26  Zan Dobersek  <zdobersek@igalia.com>
912
913         REGRESSION(r162947): Document::topDocument() returns an incorrect reference for cached Documents
914         https://bugs.webkit.org/show_bug.cgi?id=128175
915
916         Reviewed by Antti Koivisto.
917
918         * dom/Document.cpp:
919         (WebCore::Document::topDocument): Fall back to pre-r162947 way of determining the top document
920         when the Document is in page cache or is in the middle of having its render tree destroyed.
921         In the first case, the determined top document is actually the document currently loaded in the
922         Frame to which the cached document is still connected, which is obviously not desired. In the
923         second case the top document is similarly incorrectly deduced, leading to non-deletion of the
924         proper top document's AXObjectCache. Because of this AccessibilityRenderObjects are not detached
925         which results in assertions in RenderObject destructor where the objects are found to be still
926         flagged as in use by the AX cache.
927
928 2014-02-26  Mihnea Ovidenie  <mihnea@adobe.com>
929
930         [CSSRegions] Remove unused method RenderFlowThread::updateLayerToRegionMappings()
931         https://bugs.webkit.org/show_bug.cgi?id=129368
932
933         Reviewed by Andrei Bucur.
934
935         Remove unused code, no new tests.
936
937         * rendering/RenderFlowThread.h:
938
939 2014-02-26  Xabier Rodriguez Calvar  <calvaris@igalia.com>
940
941         [GTK] Regression when showing the captions menu
942         https://bugs.webkit.org/show_bug.cgi?id=129106
943
944         Reviewed by Martin Robinson.
945
946         In some cases, when clicking the captions button the menu was not
947         shown.
948
949         Updated test: media/video-controls-captions-trackmenu.html
950
951         * Modules/mediacontrols/mediaControlsGtk.js:
952         (ControllerGtk.prototype.buildCaptionMenu):
953         (ControllerGtk.prototype.showCaptionMenu): Specify sizes in
954         pixels.
955
956 2014-02-26  Ryosuke Niwa  <rniwa@webkit.org>
957
958         Avoid unnecessary HTML Collection invalidations for id and name attribute changes
959         https://bugs.webkit.org/show_bug.cgi?id=129361
960
961         Reviewed by Benjamin Poulain.
962
963         Before this patch, setting id and name attributes resulted in traversing all the ancestors to invalidate
964         HTML collections on those nodes whenever we had more than one HTMLCollection alive.
965
966         Avoid the traversal when HTMLCollections don't have any valid id and name map caches by making each
967         HTMLCollection explicitly call collectionCachedIdNameMap and collectionWillClearIdNameMap when it caches
968         or clears the id and name map.
969
970         Inspired by https://chromium.googlesource.com/chromium/blink/+/5b06b91b79098f7d42e480f85be32198315d2440
971
972         * dom/Document.cpp:
973         (WebCore::Document::registerCollection): Takes a boolean to indicate whether collection has a valid cache
974         for the id and name map.
975         (WebCore::Document::unregisterCollection): Ditto.
976         (WebCore::Document::collectionCachedIdNameMap): Added.
977         (WebCore::Document::collectionWillClearIdNameMap): Added.
978         * dom/Document.h:
979
980         * dom/NodeRareData.h:
981         (WebCore::NodeListsNodeData::adoptDocument): Call invalidateCache on HTML collections after, not before,
982         calling unregisterCollection and registerCollection since collections' owner nodes have already been
983         moved to the new document here and invalidateCache uses owner node's document to call
984         collectionWillClearIdNameMap. So calling invalidateCache before calling unregister/registerCollection
985         would result in collectionWillClearIdNameMap getting called on a wrong document.
986
987         * html/HTMLCollection.cpp:
988         (WebCore::HTMLCollection::HTMLCollection):
989         (WebCore::HTMLCollection::~HTMLCollection):
990         (WebCore::HTMLCollection::invalidateCache):
991         (WebCore::HTMLCollection::invalidateIdNameCacheMaps): Added the code to uncount itself from the number
992         of live node lists and HTML collections that need to be invalidated upon id and name attribute changes.
993         (WebCore::HTMLCollection::updateNameCache):
994
995         * html/HTMLCollection.h:
996         (WebCore::HTMLCollection::invalidateCache):
997         (WebCore::HTMLCollection::hasIdNameCache): Renamed from hasNameCache.
998         (WebCore::HTMLCollection::setHasIdNameCache): Renamed from setHasIdNameCache.
999
1000         * html/HTMLFormControlsCollection.cpp:
1001         (WebCore::HTMLFormControlsCollection::updateNameCache):
1002
1003 2014-02-25  Frédéric Wang  <fred.wang@free.fr>
1004
1005         Add support for minsize/maxsize attributes.
1006         https://bugs.webkit.org/show_bug.cgi?id=122567
1007
1008         Reviewed by Chris Fleizach.
1009
1010         This change implements the minsize/maxsize attributes of the mo element.
1011         We also switch stretch sizes from int to LayoutUnit to improve accuracy.
1012
1013         Tests: mathml/presentation/stretchy-minsize-maxsize-dynamic.html
1014                mathml/presentation/stretchy-minsize-maxsize.html
1015
1016         * rendering/mathml/RenderMathMLOperator.cpp:
1017         (WebCore::RenderMathMLOperator::SetOperatorProperties):
1018         (WebCore::RenderMathMLOperator::stretchTo):
1019         * rendering/mathml/RenderMathMLOperator.h:
1020         * rendering/mathml/RenderMathMLRow.cpp:
1021         (WebCore::RenderMathMLRow::layout):
1022
1023 2014-02-25  Mihnea Ovidenie  <mihnea@adobe.com>
1024
1025         [CSSRegions] Small clean-up of flow threads accelerated compositing code
1026         https://bugs.webkit.org/show_bug.cgi?id=129312
1027
1028         Reviewed by Andrei Bucur.
1029
1030         Some clean-up for the code used for regions in accelerated compositing functionality:
1031         1. Rename updateRenderFlowThreadLayersIfNeeded -> updateFlowThreadsLayerToRegionMappingsIfNeeded
1032         as the function updates the mapping between the flow threads layers and their corresponding regions
1033         2. Remove RenderLayerCompositor::updateRenderFlowThreadLayersIfNeeded and move the code in place
1034         at call site since the function body does not require a dedicated function.
1035
1036         No new functionality, no new tests.
1037
1038         * rendering/FlowThreadController.cpp:
1039         (WebCore::FlowThreadController::updateFlowThreadsLayerToRegionMappingsIfNeeded):
1040         Now that the regions are always layers, we do not need to iterate backwards.
1041         * rendering/FlowThreadController.h:
1042         * rendering/RenderLayerCompositor.cpp:
1043         (WebCore::RenderLayerCompositor::updateCompositingLayers):
1044         * rendering/RenderLayerCompositor.h:
1045
1046 2014-02-25  Zalan Bujtas  <zalan@apple.com>
1047
1048         Subpixel rendering: Ensure consistent border painting width.
1049         https://bugs.webkit.org/show_bug.cgi?id=129259
1050
1051         Reviewed by Simon Fraser.
1052
1053         Border edges are painted as (semi)independent rectangles. When snapping an edge rectangle
1054         to device pixels, its painted dimensions depend on its size and its fractional position.
1055         Specific combination of position and border width can result in painting edges sized differently.
1056         Using device snapped border width to calculate inner/outer rectangles helps to maintain
1057         uniform border width.
1058
1059         Currently not testable.
1060
1061         * rendering/RenderBoxModelObject.cpp:
1062         (WebCore::BorderEdge::BorderEdge):
1063         (WebCore::BorderEdge::shouldRender):
1064         (WebCore::BorderEdge::presentButInvisible):
1065         (WebCore::BorderEdge::widthForPainting):
1066         (WebCore::BorderEdge::getDoubleBorderStripeWidths):
1067         (WebCore::RenderBoxModelObject::paintOneBorderSide):
1068         (WebCore::calculateSideRect):
1069         (WebCore::RenderBoxModelObject::paintBorderSides):
1070         (WebCore::RenderBoxModelObject::paintBorder):
1071         (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
1072         (WebCore::calculateSideRectIncludingInner):
1073
1074 2014-02-25  Zalan Bujtas  <zalan@apple.com>
1075
1076         Subpixel layout: Remove explicit static_cast<LayoutUnit> conversions.
1077         https://bugs.webkit.org/show_bug.cgi?id=129359
1078
1079         Reviewed by Simon Fraser.
1080
1081         No testable change in behavior.
1082
1083         * css/LengthFunctions.cpp:
1084         (WebCore::minimumValueForLength):
1085         * page/FrameView.cpp:
1086         (WebCore::FrameView::forceLayoutForPagination):
1087         * rendering/InlineFlowBox.cpp:
1088         (WebCore::InlineFlowBox::paintFillLayer):
1089         * rendering/InlineFlowBox.h:
1090         (WebCore::InlineFlowBox::logicalLeftVisualOverflow):
1091         (WebCore::InlineFlowBox::logicalRightVisualOverflow):
1092         * rendering/InlineTextBox.cpp:
1093         (WebCore::InlineTextBox::isSelected):
1094         * rendering/RenderBlock.cpp:
1095         (WebCore::RenderBlock::computeColumnCountAndWidth):
1096         (WebCore::getBPMWidth):
1097         * rendering/RenderBlockFlow.cpp:
1098         (WebCore::RenderBlockFlow::adjustForBorderFit):
1099         * rendering/RenderDeprecatedFlexibleBox.cpp:
1100         (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):
1101         * rendering/RenderFieldset.cpp:
1102         (WebCore::RenderFieldset::paintBoxDecorations):
1103         * rendering/RenderTable.h:
1104         (WebCore::RenderTable::borderSpacingInRowDirection):
1105         * rendering/RenderTextControlMultiLine.cpp:
1106         (WebCore::RenderTextControlMultiLine::preferredContentLogicalWidth):
1107         * rendering/RenderTextControlSingleLine.cpp:
1108         (WebCore::RenderTextControlSingleLine::preferredContentLogicalWidth):
1109         * rendering/RootInlineBox.cpp:
1110         (WebCore::RootInlineBox::beforeAnnotationsAdjustment):
1111         (WebCore::RootInlineBox::ascentAndDescentForBox):
1112         * rendering/svg/RenderSVGRoot.cpp:
1113         (WebCore::resolveLengthAttributeForSVG):
1114
1115 2014-02-25  Anders Carlsson  <andersca@apple.com>
1116
1117         Build fixes.
1118
1119         * CMakeLists.txt:
1120         * GNUmakefile.list.am:
1121         * WebCore.vcxproj/WebCore.vcxproj:
1122         * WebCore.vcxproj/WebCore.vcxproj.filters:
1123
1124 2014-02-25  Benjamin Poulain  <bpoulain@apple.com>
1125
1126         Build fix for OS X after r164690
1127
1128         * WebCore.exp.in:
1129
1130 2014-02-25  Anders Carlsson  <andersca@apple.com>
1131
1132         Rename WebCore::VisitedLinkProvider to WebCore::VisitedLinkStore
1133         https://bugs.webkit.org/show_bug.cgi?id=129357
1134
1135         Reviewed by Sam Weinig.
1136
1137         * WebCore.exp.in:
1138         * WebCore.xcodeproj/project.pbxproj:
1139         * dom/VisitedLinkState.cpp:
1140         (WebCore::VisitedLinkState::determineLinkStateSlowCase):
1141         * loader/HistoryController.cpp:
1142         (WebCore::addVisitedLink):
1143         * page/DefaultVisitedLinkStore.cpp: Renamed from Source/WebCore/page/DefaultVisitedLinkProvider.cpp.
1144         (WebCore::DefaultVisitedLinkStore::create):
1145         (WebCore::DefaultVisitedLinkStore::DefaultVisitedLinkStore):
1146         (WebCore::DefaultVisitedLinkStore::~DefaultVisitedLinkStore):
1147         (WebCore::DefaultVisitedLinkStore::isLinkVisited):
1148         (WebCore::DefaultVisitedLinkStore::addVisitedLink):
1149         * page/DefaultVisitedLinkStore.h: Renamed from Source/WebCore/page/DefaultVisitedLinkProvider.h.
1150         * page/Page.cpp:
1151         (WebCore::Page::Page):
1152         (WebCore::Page::visitedLinkStore):
1153         * page/Page.h:
1154         * page/PageGroup.cpp:
1155         (WebCore::PageGroup::visitedLinkStore):
1156         * page/PageGroup.h:
1157         * page/VisitedLinkStore.cpp: Renamed from Source/WebCore/page/VisitedLinkProvider.cpp.
1158         (WebCore::VisitedLinkStore::VisitedLinkStore):
1159         (WebCore::VisitedLinkStore::~VisitedLinkStore):
1160         * page/VisitedLinkStore.h: Renamed from Source/WebCore/page/VisitedLinkProvider.h.
1161
1162 2014-02-25  Enrica Casucci  <enrica@apple.com>
1163
1164         [WebKit2] Form controls handling.
1165         https://bugs.webkit.org/show_bug.cgi?id=129344
1166         <rdar://problem/16053643>
1167
1168         Reviewed by Simon Fraser and Joseph Pecoraro.
1169
1170         Adding some exports.
1171         
1172         * WebCore.exp.in:
1173
1174 2014-02-25  Samuel White  <samuel_white@apple.com>
1175
1176         Add accessibility search predicate support for AXOutlines
1177         https://bugs.webkit.org/show_bug.cgi?id=123748
1178
1179         Reviewed by Chris Fleizach.
1180
1181         Added new AXOutlineSearchKey to support finding elements with aria role=tree.
1182
1183         No new tests, updated existing search-predicate.html test to cover AXOutlineSearchKey.
1184
1185         * accessibility/AccessibilityObject.cpp:
1186         (WebCore::AccessibilityObject::isAccessibilityObjectSearchMatchAtIndex):
1187         * accessibility/AccessibilityObject.h:
1188         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
1189         (createAccessibilitySearchKeyMap):
1190
1191 2014-02-25  Mark Lam  <mark.lam@apple.com>
1192
1193         Need to initialize VM stack data even when the VM is on an exclusive thread.
1194         <https://webkit.org/b/129265>
1195
1196         Not reviewed.
1197
1198         No new tests.
1199
1200         Relanding r164627 now that <https://webkit.org/b/129341> is fixed.
1201
1202         * bindings/js/JSDOMBinding.cpp:
1203         (WebCore::reportException):
1204         * bindings/js/JSDOMWindowBase.cpp:
1205         (WebCore::JSDOMWindowBase::commonVM):
1206
1207 2014-02-25  Mark Lam  <mark.lam@apple.com>
1208
1209         JSDOMPromise methods should acquire VM lock before calling into JS.
1210         <https://webkit.org/b/129341>
1211
1212         Reviewed by Geoffrey Garen.
1213
1214         No new tests.
1215
1216         * bindings/js/JSDOMPromise.h:
1217         (WebCore::DeferredWrapper::resolve):
1218         (WebCore::DeferredWrapper::reject):
1219         (WebCore::DeferredWrapper::resolve<String>):
1220         (WebCore::DeferredWrapper::resolve<bool>):
1221         (WebCore::char>>):
1222         (WebCore::DeferredWrapper::reject<String>):
1223
1224 2014-02-25  Anders Carlsson  <andersca@apple.com>
1225
1226         Simplify visited link style invalidation
1227         https://bugs.webkit.org/show_bug.cgi?id=129340
1228
1229         Reviewed by Dan Bernstein.
1230
1231         Get rid of the static Page::allVisitedStateChanged and Page::visitedStateChanged
1232         member functions and add functions to invalidate all styles on a single page or the style
1233         for a single link hash on a single page.
1234
1235         * WebCore.exp.in:
1236         * page/Page.cpp:
1237         (WebCore::Page::invalidateStylesForAllLinks):
1238         (WebCore::Page::invalidateStylesForLink):
1239         * page/Page.h:
1240         * page/PageGroup.cpp:
1241         (WebCore::PageGroup::addVisitedLink):
1242         (WebCore::PageGroup::removeVisitedLink):
1243         (WebCore::PageGroup::removeVisitedLinks):
1244
1245 2014-02-25  Andreas Kling  <akling@apple.com>
1246
1247         Remove unused ThreadSpecificInspectorCounters.
1248         <https://webkit.org/b/129337>
1249
1250         We were keeping count of all the JS event listeners in every thread
1251         to support an old Chromium feature that's no longer relevant.
1252
1253         Removing this gets rid of expensive thread-local storage lookups.
1254
1255         Reviewed by Anders Carlsson.
1256
1257         * bindings/js/JSEventListener.cpp:
1258         (WebCore::JSEventListener::JSEventListener):
1259         (WebCore::JSEventListener::~JSEventListener):
1260         * inspector/InspectorCounters.cpp:
1261         * inspector/InspectorCounters.h:
1262         * inspector/InspectorTimelineAgent.cpp:
1263         (WebCore::InspectorTimelineAgent::setDOMCounters):
1264         * inspector/protocol/Timeline.json:
1265         * platform/ThreadGlobalData.cpp:
1266         (WebCore::ThreadGlobalData::ThreadGlobalData):
1267         (WebCore::ThreadGlobalData::destroy):
1268         * platform/ThreadGlobalData.h:
1269
1270 2014-02-25  Laszlo Vidacs  <lvidacs.u-szeged@partner.samsung.com>
1271
1272         display:table with padding and/or borders in border-box calculates height incorrectly
1273         https://bugs.webkit.org/show_bug.cgi?id=126576
1274
1275         Reviewed by David Hyatt.
1276
1277         Based on blink issue https://codereview.chromium.org/25206002/
1278
1279         Tests: fast/box-sizing/css-table-collapse.html
1280                fast/box-sizing/css-table-no-collapse.html
1281                fast/box-sizing/table-collapse.html
1282                fast/box-sizing/table-no-collapse.html
1283
1284         * rendering/RenderBox.cpp:
1285         (WebCore::RenderBox::computePositionedLogicalHeightUsing):
1286
1287 2014-02-25  Anders Carlsson  <andersca@apple.com>
1288
1289         Get rid of VisitedLinkStrategy
1290         https://bugs.webkit.org/show_bug.cgi?id=129324
1291
1292         Reviewed by Dan Bernstein.
1293
1294         * GNUmakefile.list.am:
1295         * WebCore.vcxproj/WebCore.vcxproj:
1296         * WebCore.vcxproj/WebCore.vcxproj.filters:
1297         * WebCore.xcodeproj/project.pbxproj:
1298         * platform/PlatformStrategies.h:
1299         (WebCore::PlatformStrategies::PlatformStrategies):
1300         * platform/VisitedLinkStrategy.h: Removed.
1301
1302 2014-02-25  Alexey Proskuryakov  <ap@apple.com>
1303
1304         Rolling out http://trac.webkit.org/changeset/164611, because it broke
1305         WebKit2.PrivateBrowsingPushStateNoHistoryCallback API test
1306
1307         The change was for:
1308
1309         https://bugs.webkit.org/show_bug.cgi?id=129141
1310         Create SessionID class
1311
1312 2014-02-25  Commit Queue  <commit-queue@webkit.org>
1313
1314         Unreviewed, rolling out r164627.
1315         http://trac.webkit.org/changeset/164627
1316         https://bugs.webkit.org/show_bug.cgi?id=129325
1317
1318         Broke SubtleCrypto tests (Requested by ap on #webkit).
1319
1320         * bindings/js/JSDOMBinding.cpp:
1321         (WebCore::reportException):
1322         * bindings/js/JSDOMWindowBase.cpp:
1323         (WebCore::JSDOMWindowBase::commonVM):
1324
1325 2014-02-25  Anders Carlsson  <andersca@apple.com>
1326
1327         DefaultVisitedLinkProvider can just call into the page group directly
1328         https://bugs.webkit.org/show_bug.cgi?id=129320
1329
1330         Reviewed by Andreas Kling.
1331
1332         * page/DefaultVisitedLinkProvider.cpp:
1333         (WebCore::DefaultVisitedLinkProvider::isLinkVisited):
1334         (WebCore::DefaultVisitedLinkProvider::addVisitedLink):
1335
1336 2014-02-25  Commit Queue  <commit-queue@webkit.org>
1337
1338         Unreviewed, rolling out r164638.
1339         http://trac.webkit.org/changeset/164638
1340         https://bugs.webkit.org/show_bug.cgi?id=129321
1341
1342         Broke Windows build. (Requested by bfulgham on #webkit).
1343
1344         * dom/ContainerNode.h:
1345         (WebCore::ChildNodesLazySnapshot::takeSnapshot):
1346         (WebCore::ChildNodesLazySnapshot::hasSnapshot):
1347         * dom/Element.cpp:
1348         (WebCore::ensureAttrNodeListForElement):
1349         (WebCore::Element::attributes):
1350         * dom/ElementIteratorAssertions.h:
1351         (WebCore::ElementIteratorAssertions::ElementIteratorAssertions):
1352         * dom/ElementRareData.h:
1353         (WebCore::ElementRareData::create):
1354         (WebCore::ElementRareData::setAttributeMap):
1355         * dom/MutationObserverRegistration.cpp:
1356         (WebCore::MutationObserverRegistration::create):
1357         (WebCore::MutationObserverRegistration::observedSubtreeNodeWillDetach):
1358         (WebCore::MutationObserverRegistration::clearTransientRegistrations):
1359         (WebCore::MutationObserverRegistration::addRegistrationNodesToSet):
1360         * dom/MutationObserverRegistration.h:
1361         * dom/NamedNodeMap.h:
1362         (WebCore::NamedNodeMap::create):
1363         (WebCore::NamedNodeMap::NamedNodeMap):
1364         * dom/Node.cpp:
1365         (WebCore::Node::ensureRareData):
1366         (WebCore::Node::didMoveToNewDocument):
1367         (WebCore::Node::ensureEventTargetData):
1368         (WebCore::Node::mutationObserverRegistry):
1369         (WebCore::Node::registerMutationObserver):
1370         (WebCore::Node::unregisterMutationObserver):
1371         (WebCore::Node::notifyMutationObserversNodeWillDetach):
1372         * dom/Node.h:
1373         * dom/NodeRareData.h:
1374         (WebCore::NodeListsNodeData::create):
1375         (WebCore::NodeListsNodeData::NodeListsNodeData):
1376         (WebCore::NodeMutationObserverData::create):
1377         (WebCore::NodeMutationObserverData::NodeMutationObserverData):
1378         (WebCore::NodeRareData::create):
1379         (WebCore::NodeRareData::clearNodeLists):
1380         (WebCore::NodeRareData::ensureNodeLists):
1381         (WebCore::NodeRareData::ensureMutationObserverData):
1382         (WebCore::NodeRareData::NodeRareData):
1383         * dom/StyledElement.cpp:
1384         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
1385
1386 2014-02-25  Eric Carlson  <eric.carlson@apple.com>
1387
1388         [iOS] Show status image when playing video to external device
1389         https://bugs.webkit.org/show_bug.cgi?id=129277
1390
1391         Reviewed by Jer Noble.
1392
1393         * Modules/mediacontrols/mediaControlsApple.js:
1394         (Controller.prototype.handleEvent): Restructure the code so it is possible to handle events
1395             that target the video element which aren't in the HandledVideoEvents array.
1396
1397         * Modules/mediacontrols/mediaControlsiOS.js:
1398         (ControllerIOS.prototype.currentPlaybackTargetIsWireless): webkitCurrentPlaybackTargetIsWireless
1399             is an attribute, not a function.
1400         (ControllerIOS.prototype.updateWirelessPlaybackStatus): Fix style.
1401         (ControllerIOS.prototype.updateWirelessTargetAvailable): Ditto.
1402         (ControllerIOS.prototype.updateProgress): Ditto.
1403         (ControllerIOS.prototype.handleWrapperTouchStart): Show the controls if the wireless status
1404             display is touched.
1405         (ControllerIOS.prototype.handleFullscreenButtonClicked): Fix style
1406         (ControllerIOS.prototype.handleWirelessPlaybackChange): Ditto.
1407         (ControllerIOS.prototype.handleWirelessTargetAvailableChange):
1408         (ControllerIOS.prototype.handleWirelessPickerButtonClicked): Ditto. Stop even propagation.
1409
1410         Move "playback target" logic into HTMLMediaSession.
1411         * html/HTMLMediaElement.cpp:
1412         (WebCore::HTMLMediaElement::~HTMLMediaElement): Call media session.
1413         (WebCore::HTMLMediaElement::loadResource): Tell media session to apply media player
1414             restrictions now that it has a url.
1415         (WebCore::HTMLMediaElement::invalidateCachedTime): Only log when cached time is not 
1416             already invalie.
1417         (WebCore::HTMLMediaElement::webkitShowPlaybackTargetPicker): Call media session.
1418         (WebCore::HTMLMediaElement::webkitCurrentPlaybackTargetIsWireless): Ditto.
1419         (WebCore::HTMLMediaElement::mediaPlayerCurrentPlaybackTargetIsWirelessChanged): Ditto.
1420         (WebCore::HTMLMediaElement::addEventListener): Ditto.
1421         (WebCore::HTMLMediaElement::removeEventListen): Ditto.
1422         (WebCore::HTMLMediaElement::enqueuePlaybackTargetAvailabilityChangedEvent): Ditto.
1423         (WebCore::HTMLMediaElement::createMediaPlayer): Ditto.
1424
1425         * html/HTMLMediaSession.cpp:
1426         (WebCore::restrictionName): Log new WirelessVideoPlaybackDisabled restriction.
1427         (WebCore::HTMLMediaSession::showingPlaybackTargetPickerPermitted): Return false if there
1428             is no page, or if wireless playback is disabled.
1429         (WebCore::HTMLMediaSession::currentPlaybackTargetIsWireless): New, logic from HTMLMediaElement.
1430         (WebCore::HTMLMediaSession::showPlaybackTargetPicker): Ditto.
1431         (WebCore::HTMLMediaSession::hasWirelessPlaybackTargets): Ditto.
1432         (WebCore::HTMLMediaSession::wirelessVideoPlaybackDisabled): Ditto.
1433         (WebCore::HTMLMediaSession::setWirelessVideoPlaybackDisabled): Ditto.
1434         (WebCore::HTMLMediaSession::setHasPlaybackTargetAvailabilityListeners): Ditto.
1435         (WebCore::HTMLMediaSession::applyMediaPlayerRestrictions): New, apply media player specific
1436             restriction.
1437         * html/HTMLMediaSession.h:
1438
1439         Move "playback target" logic into HTMLMediaSession.
1440         * html/HTMLVideoElement.cpp:
1441         (WebCore::HTMLVideoElement::parseAttribute): Call media session.
1442         (WebCore::HTMLVideoElement::webkitWirelessVideoPlaybackDisabled): Call media session.
1443
1444         * platform/audio/MediaSessionManager.h:
1445         (WebCore::MediaSessionManager::showPlaybackTargetPicker): New method, does nothing in base class.
1446
1447         * platform/audio/ios/MediaSessionManagerIOS.h:
1448         * platform/audio/ios/MediaSessionManagerIOS.mm:
1449         (WebCore::MediaSessionManageriOS::showPlaybackTargetPicker): Add non-functional stub.
1450
1451         Implement wireless playback control and status API.
1452         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
1453         (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification): Dispatch TargetIsWirelessChanged.
1454         (WebCore::MediaPlayerPrivateAVFoundation::playbackTargetIsWirelessChanged): Pass through to
1455             media element.
1456         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
1457
1458         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
1459         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1460         (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize
1461             m_allowsWirelessVideoPlayback.
1462         (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad): Remove "externalPlaybackActive" observer.
1463         (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoLayer): Fix broken logging.
1464         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Add "externalPlaybackActive" observer,
1465             set initial wireless playback.
1466         (WebCore::MediaPlayerPrivateAVFoundationObjC::createPixelBuffer):  Fix broken logging.
1467         (WebCore::MediaPlayerPrivateAVFoundationObjC::languageOfPrimaryAudioTrack): Ditto.
1468         (WebCore::MediaPlayerPrivateAVFoundationObjC::isCurrentPlaybackTargetWireless): New.
1469         (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessVideoPlaybackDisabled): New.
1470         (WebCore::MediaPlayerPrivateAVFoundationObjC::setWirelessVideoPlaybackDisabled): New.
1471         (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackTargetIsWirelessDidChange): New.
1472         (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]): Deal with 
1473             externalPlaybackActive.
1474
1475 2014-02-24  Brent Fulgham  <bfulgham@apple.com>
1476
1477         [Win] Gracefully recover from missing 'naturalSize' parameter for media
1478         https://bugs.webkit.org/show_bug.cgi?id=129278
1479
1480         Reviewed by Eric Carlson.
1481
1482         * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h: Add declaration for
1483         missing function call.
1484         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
1485         (WebCore::MediaPlayerPrivateAVFoundationCF::assetStatus): Don't treat missing 'naturalSize'
1486         as a fatal error.
1487         (WebCore::MediaPlayerPrivateAVFoundationCF::tracksChanged): Handle case of asset track
1488         not being available yet. 
1489         (WebCore::MediaPlayerPrivateAVFoundationCF::sizeChanged): If the 'naturalSize' is empty,
1490         use the Player Item's 'presentationSize' instead.
1491         (WebCore::AVFWrapper::processNotification): Add missing handler for duration changed.
1492
1493 2014-02-25  Sergio Villar Senin  <svillar@igalia.com>
1494
1495         [CSS Grid Layout] Add ENABLE flag
1496         https://bugs.webkit.org/show_bug.cgi?id=129153
1497
1498         Reviewed by Simon Fraser.
1499
1500         Added ENABLE_CSS_GRID_LAYOUT feature flag.
1501
1502         * Configurations/FeatureDefines.xcconfig:
1503         * css/CSSComputedStyleDeclaration.cpp:
1504         (WebCore::isLayoutDependent):
1505         (WebCore::ComputedStyleExtractor::propertyValue):
1506         * css/CSSGridTemplateAreasValue.cpp:
1507         * css/CSSGridTemplateAreasValue.h:
1508         * css/CSSParser.cpp:
1509         (WebCore::CSSParserContext::CSSParserContext):
1510         (WebCore::operator==):
1511         (WebCore::isValidKeywordPropertyAndValue):
1512         (WebCore::isKeywordPropertyID):
1513         (WebCore::CSSParser::parseValue):
1514         * css/CSSParser.h:
1515         * css/CSSParserMode.h:
1516         * css/CSSPrimitiveValueMappings.h:
1517         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1518         * css/CSSPropertyNames.in:
1519         * css/CSSValue.cpp:
1520         (WebCore::CSSValue::equals):
1521         (WebCore::CSSValue::cssText):
1522         (WebCore::CSSValue::destroy):
1523         * css/DeprecatedStyleBuilder.cpp:
1524         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
1525         * css/StyleProperties.cpp:
1526         (WebCore::StyleProperties::getPropertyValue):
1527         * css/StylePropertyShorthand.cpp:
1528         (WebCore::shorthandForProperty):
1529         (WebCore::matchingShorthandsForLonghand):
1530         * css/StyleResolver.cpp:
1531         (WebCore::equivalentBlockDisplay):
1532         (WebCore::StyleResolver::adjustRenderStyle):
1533         (WebCore::StyleResolver::applyProperty):
1534         * css/StyleResolver.h:
1535         * dom/Document.cpp:
1536         * dom/Document.h:
1537         * rendering/RenderElement.cpp:
1538         (WebCore::RenderElement::createFor):
1539         * rendering/RenderGrid.cpp:
1540         * rendering/RenderGrid.h:
1541         * rendering/style/GridCoordinate.h:
1542         * rendering/style/GridLength.h:
1543         * rendering/style/GridPosition.h:
1544         * rendering/style/GridTrackSize.h:
1545         * rendering/style/RenderStyle.cpp:
1546         (WebCore::RenderStyle::changeRequiresLayout):
1547         * rendering/style/RenderStyle.h:
1548         * rendering/style/RenderStyleConstants.h:
1549         * rendering/style/StyleAllInOne.cpp:
1550         * rendering/style/StyleGridData.cpp:
1551         * rendering/style/StyleGridData.h:
1552         * rendering/style/StyleGridItemData.cpp:
1553         * rendering/style/StyleGridItemData.h:
1554         * rendering/style/StyleRareNonInheritedData.cpp:
1555         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1556         (WebCore::StyleRareNonInheritedData::operator==):
1557         * rendering/style/StyleRareNonInheritedData.h:
1558
1559 2014-02-25  Jer Noble  <jer.noble@apple.com>
1560
1561         [EME][Mac] Fix a few issues in CDMSessionMediaSourceAVFObjC.
1562         https://bugs.webkit.org/show_bug.cgi?id=129310
1563
1564         Reviewed by Eric Carlson.
1565
1566         Only send a 'keyerror' event if an actual error code was returned, not just
1567         when no key was added:
1568         * Modules/encryptedmedia/MediaKeySession.cpp:
1569         (WebCore::MediaKeySession::addKeyTimerFired):
1570
1571         The 'length' parameter to a typed ArrayBufferView is the number of entries
1572         in the array, not the byte length:
1573         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
1574         (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest):
1575
1576         The return value of streamingContentKeyRequestDataForApp:contentIdentifier:trackId:options:error
1577         is autoreleased; do not wrap it in an adoptNS:
1578         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
1579         (WebCore::CDMSessionMediaSourceAVFObjC::update):
1580
1581 2014-02-25  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
1582
1583         [MediaStream] Adding mock implementation of UserMediaClient
1584         https://bugs.webkit.org/show_bug.cgi?id=129274
1585
1586         Reviewed by Eric Carlson.
1587
1588         * platform/mock/UserMediaClientMock.h: Added.
1589         (WebCore::UserMediaClientRequestNotifier::UserMediaClientRequestNotifier):
1590         * testing/Internals.cpp:
1591         (WebCore::Internals::Internals):
1592
1593 2014-02-25  Ryosuke Niwa  <rniwa@webkit.org>
1594
1595         Tighten bitfields in live NodeLists and HTMLCollections
1596         https://bugs.webkit.org/show_bug.cgi?id=129300
1597
1598         Reviewed by Geoffrey Garen.
1599
1600         Reduce the number of bits used for m_rootType and m_type in LiveNodeList.
1601         Also use enum class for LiveNodeList types. We keep "Type" suffix not to
1602         confuse old-ish compilers.
1603
1604         * dom/ClassNodeList.cpp:
1605         (WebCore::ClassNodeList::ClassNodeList):
1606         * dom/ContainerNode.cpp:
1607         (WebCore::ContainerNode::getElementsByTagName):
1608         (WebCore::ContainerNode::getElementsByName):
1609         (WebCore::ContainerNode::getElementsByClassName):
1610         (WebCore::ContainerNode::radioNodeList):
1611         * dom/LiveNodeList.cpp:
1612         (WebCore::LiveNodeList::collectionFirst):
1613         (WebCore::LiveNodeList::collectionTraverseForward):
1614         * dom/LiveNodeList.h:
1615         (WebCore::LiveNodeList::LiveNodeList):
1616         * dom/NameNodeList.cpp:
1617         (WebCore::NameNodeList::NameNodeList):
1618         * dom/NameNodeList.h:
1619         (WebCore::NameNodeList::create):
1620         * dom/NodeRareData.h:
1621         (WebCore::NodeListsNodeData::namedNodeListKey):
1622         * dom/TagNodeList.cpp:
1623         (WebCore::HTMLTagNodeList::HTMLTagNodeList):
1624         * dom/TagNodeList.h:
1625         (WebCore::TagNodeList::create):
1626         (WebCore::HTMLTagNodeList::create):
1627         * html/HTMLCollection.h:
1628         * html/LabelableElement.cpp:
1629         (WebCore::LabelableElement::labels):
1630         * html/LabelsNodeList.cpp:
1631         (WebCore::LabelsNodeList::LabelsNodeList):
1632         * html/LabelsNodeList.h:
1633         * html/RadioNodeList.cpp:
1634         (WebCore::RadioNodeList::RadioNodeList):
1635         * html/RadioNodeList.h:
1636         (WebCore::RadioNodeList::create):
1637
1638 2014-02-24  Anders Carlsson  <andersca@apple.com>
1639
1640         Make it possible to set the visited link provider on a per page basis
1641         https://bugs.webkit.org/show_bug.cgi?id=129288
1642
1643         Reviewed by Andreas Kling.
1644
1645         * WebCore.exp.in:
1646         Export symbols needed by WebKit2.
1647
1648         * WebCore.xcodeproj/project.pbxproj:
1649         Make VisitedLinkProvider a private header.
1650
1651         * page/Page.cpp:
1652         (WebCore::Page::Page):
1653         Take the visited link provider from the PageClients object.
1654
1655         (WebCore::Page::visitedLinkProvider):
1656         If the page has a visited link provider set, return it.
1657
1658         * page/Page.h:
1659         Add VisitedLinkProvider to Page and PageClients.
1660
1661 2014-02-25  Morten Stenshorne  <mstensho@opera.com>
1662
1663         [New Multicolumn] -webkit-column-break-inside:avoid doesn't work
1664         https://bugs.webkit.org/show_bug.cgi?id=129299
1665
1666         Reviewed by Andrei Bucur.
1667
1668         adjustForUnsplittableChild() simply forgot to check whether we
1669         were inside flow thread based multicol.
1670
1671         Test: fast/multicol/newmulticol/avoid-column-break-inside.html
1672
1673         * rendering/RenderBlockFlow.cpp:
1674         (WebCore::RenderBlockFlow::adjustForUnsplittableChild):
1675
1676 2014-02-25  Mihnea Ovidenie  <mihnea@adobe.com>
1677
1678         [CSSRegions] Remove unused function RenderFlowThread::regionForCompositedLayer
1679         https://bugs.webkit.org/show_bug.cgi?id=129303
1680
1681         Reviewed by Andrei Bucur.
1682
1683         Cleanup, no funtionality change, no new tests.
1684
1685         * rendering/RenderFlowThread.h:
1686
1687 2014-02-25  Mihai Tica  <mitica@adobe.com>
1688
1689         [CSS Blending] -webkit-mix-blend-mode should force transform-style: flat.
1690         https://bugs.webkit.org/show_bug.cgi?id=126158
1691
1692         Reviewed by Mihnea Ovidenie.
1693
1694         As stated in the http://www.w3.org/TR/css3-transforms/#propdef-transform-style, an element with blending
1695         should force transform-style: flat.
1696
1697         Test: css3/compositing/blend-mode-transform-style.html
1698
1699         * css/StyleResolver.cpp:
1700         (WebCore::StyleResolver::adjustRenderStyle): If blending is detected, set transform-style to flat.
1701
1702 2014-02-25  Zan Dobersek  <zdobersek@igalia.com>
1703
1704         Move to using std::unique_ptr for Element, Node and related classes
1705         https://bugs.webkit.org/show_bug.cgi?id=129058
1706
1707         Reviewed by Anders Carlsson.
1708
1709         Replace uses of OwnPtr and PassOwnPtr in Element, Node and the related
1710         classes with std::unique_ptr and move semantics.
1711
1712         * dom/ContainerNode.h:
1713         (WebCore::ChildNodesLazySnapshot::takeSnapshot):
1714         (WebCore::ChildNodesLazySnapshot::hasSnapshot):
1715         * dom/Element.cpp:
1716         (WebCore::ensureAttrNodeListForElement):
1717         (WebCore::Element::attributes):
1718         * dom/ElementIteratorAssertions.h:
1719         (WebCore::ElementIteratorAssertions::ElementIteratorAssertions):
1720         * dom/ElementRareData.h:
1721         (WebCore::ElementRareData::setAttributeMap):
1722         * dom/MutationObserverRegistration.cpp:
1723         (WebCore::MutationObserverRegistration::observedSubtreeNodeWillDetach):
1724         (WebCore::MutationObserverRegistration::clearTransientRegistrations):
1725         (WebCore::MutationObserverRegistration::addRegistrationNodesToSet):
1726         * dom/MutationObserverRegistration.h:
1727         * dom/NamedNodeMap.h:
1728         (WebCore::NamedNodeMap::NamedNodeMap):
1729         * dom/Node.cpp:
1730         (WebCore::Node::ensureRareData):
1731         (WebCore::Node::didMoveToNewDocument):
1732         (WebCore::Node::ensureEventTargetData):
1733         (WebCore::Node::mutationObserverRegistry):
1734         (WebCore::Node::registerMutationObserver):
1735         (WebCore::Node::unregisterMutationObserver):
1736         (WebCore::Node::notifyMutationObserversNodeWillDetach):
1737         * dom/Node.h:
1738         * dom/NodeRareData.h:
1739         (WebCore::NodeListsNodeData::NodeListsNodeData):
1740         (WebCore::NodeRareData::NodeRareData):
1741         (WebCore::NodeRareData::clearNodeLists):
1742         (WebCore::NodeRareData::ensureNodeLists):
1743         (WebCore::NodeRareData::ensureMutationObserverData):
1744         * dom/StyledElement.cpp:
1745         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
1746
1747 2014-02-25  Andreas Kling  <akling@apple.com>
1748
1749         Prune dead code for Web Inspector memory instrumentation.
1750         <https://webkit.org/b/129286>
1751
1752         This was leftover code from Chromium's inspector. It's not used by
1753         today's WebKit inspector.
1754
1755         Reviewed by Sam Weinig.
1756
1757         * CMakeLists.txt:
1758         * DerivedSources.make:
1759         * GNUmakefile.am:
1760         * GNUmakefile.list.am:
1761         * WebCore.vcxproj/WebCore.vcxproj:
1762         * WebCore.vcxproj/WebCore.vcxproj.filters:
1763         * WebCore.xcodeproj/project.pbxproj:
1764         * inspector/InspectorAllInOne.cpp:
1765         * inspector/InspectorController.cpp:
1766         (WebCore::InspectorController::InspectorController):
1767         * inspector/InspectorController.h:
1768         * inspector/InspectorMemoryAgent.cpp: Removed.
1769         * inspector/InspectorMemoryAgent.h: Removed.
1770         * inspector/InspectorTimelineAgent.cpp:
1771         (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
1772         * inspector/InspectorTimelineAgent.h:
1773         * inspector/WorkerInspectorController.cpp:
1774         (WebCore::WorkerInspectorController::WorkerInspectorController):
1775         * inspector/protocol/Memory.json: Removed.
1776
1777 2014-02-24  Chris Fleizach  <cfleizach@apple.com>
1778
1779         AX: Support abbr, acronym
1780         https://bugs.webkit.org/show_bug.cgi?id=128860
1781
1782         Reviewed by Mario Sanchez Prada.
1783
1784         Expose the data in <abbr>, <acronym> and <th abbr=""> as an 
1785         alternateTextValue() parameter.
1786
1787         Test: platform/mac/accessibility/abbr-acronym-tags.html
1788
1789         * accessibility/AccessibilityObject.cpp:
1790         (WebCore::AccessibilityObject::hasTagName):
1791         * accessibility/AccessibilityObject.h:
1792         (WebCore::AccessibilityObject::alternateTextValue):
1793         (WebCore::AccessibilityObject::supportsAlternateTextValue):
1794         * accessibility/AccessibilityRenderObject.cpp:
1795         (WebCore::AccessibilityRenderObject::alternateTextValue):
1796         (WebCore::AccessibilityRenderObject::supportsAlternateTextValue):
1797         * accessibility/AccessibilityRenderObject.h:
1798         * accessibility/AccessibilityTableCell.cpp:
1799         (WebCore::AccessibilityTableCell::alternateTextValue):
1800         (WebCore::AccessibilityTableCell::supportsAlternateTextValue):
1801         * accessibility/AccessibilityTableCell.h:
1802         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
1803         (AXAttributeStringSetAlternateTextValue):
1804         (AXAttributedStringAppendText):
1805         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
1806         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
1807
1808 2014-02-24  Martin Robinson  <mrobinson@igalia.com>
1809
1810         [GTK] generate-gtkdoc should not generate documentation for source files for unbuilt source files
1811         https://bugs.webkit.org/show_bug.cgi?id=128417
1812
1813         Reviewed by Carlos Garcia Campos.
1814
1815         * bindings/gobject/GNUmakefile.am: Generate a config file for webkitdom documentation generation.
1816
1817 2014-02-24  Mark Lam  <mark.lam@apple.com>
1818
1819         Need to initialize VM stack data even when the VM is on an exclusive thread.
1820         <https://webkit.org/b/129265>
1821
1822         Reviewed by Geoffrey Garen.
1823
1824         No new tests.
1825
1826         * bindings/js/JSDOMBinding.cpp:
1827         (WebCore::reportException):
1828         - Added an assertion to ensure that we are holding the JSLock.
1829         * bindings/js/JSDOMWindowBase.cpp:
1830         (WebCore::JSDOMWindowBase::commonVM):
1831         - Updated to use the new VM::setExclusiveThread().
1832
1833 2014-02-24  Anders Carlsson  <andersca@apple.com>
1834
1835         Add a DefaultVisitedLinkProvider and route visited link actions through it
1836         https://bugs.webkit.org/show_bug.cgi?id=129285
1837
1838         Reviewed by Dan Bernstein.
1839
1840         DefaultVisitedLinkProvider currently just forwards everything to the visited link strategy,
1841         but will soon take over the responsibilities of visited link handling from PageGroup.
1842         
1843         * CMakeLists.txt:
1844         * GNUmakefile.list.am:
1845         * WebCore.vcxproj/WebCore.vcxproj:
1846         * WebCore.vcxproj/WebCore.vcxproj.filters:
1847         * WebCore.xcodeproj/project.pbxproj:
1848         * dom/VisitedLinkState.cpp:
1849         (WebCore::VisitedLinkState::determineLinkStateSlowCase):
1850         * loader/HistoryController.cpp:
1851         (WebCore::addVisitedLink):
1852         (WebCore::HistoryController::updateForStandardLoad):
1853         (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
1854         (WebCore::HistoryController::updateForClientRedirect):
1855         (WebCore::HistoryController::updateForSameDocumentNavigation):
1856         (WebCore::HistoryController::pushState):
1857         (WebCore::HistoryController::replaceState):
1858         * page/DefaultVisitedLinkProvider.cpp: Copied from Source/WebCore/page/VisitedLinkProvider.h.
1859         (WebCore::DefaultVisitedLinkProvider::create):
1860         (WebCore::DefaultVisitedLinkProvider::DefaultVisitedLinkProvider):
1861         (WebCore::DefaultVisitedLinkProvider::~DefaultVisitedLinkProvider):
1862         (WebCore::DefaultVisitedLinkProvider::isLinkVisited):
1863         (WebCore::DefaultVisitedLinkProvider::addVisitedLink):
1864         * page/DefaultVisitedLinkProvider.h: Copied from Source/WebCore/page/VisitedLinkProvider.h.
1865         * page/Page.cpp:
1866         (WebCore::Page::visitedLinkProvider):
1867         * page/Page.h:
1868         * page/PageGroup.cpp:
1869         (WebCore::PageGroup::PageGroup):
1870         (WebCore::PageGroup::visitedLinkProvider):
1871         * page/PageGroup.h:
1872         * page/VisitedLinkProvider.h:
1873
1874 2014-02-24  Jeremy Jones  <jeremyj@apple.com>
1875
1876         WK2 AVKit fullscreen doesn't display video.
1877         https://bugs.webkit.org/show_bug.cgi?id=128564
1878
1879         Reviewed by Simon Fraser.
1880
1881         * WebCore.exp.in:
1882         Export WebCore::PlatformCALayer::platformCALayer()
1883
1884         * platform/ios/WebVideoFullscreenInterface.h:
1885         * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
1886         Remove SetVideoLayerID(). 
1887
1888         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
1889         (WebVideoFullscreenInterfaceAVKit::setVideoLayer):
1890         Wrap make video layer look like an AVAVPlayerLayer with WebAVPlayerLayer
1891
1892         * platform/ios/WebVideoFullscreenModelMediaElement.mm:
1893         (WebVideoFullscreenModelMediaElement::setMediaElement):
1894         Pass along the videoLayer before borrowing it so the interface will be ready to
1895         catch the transaction that removes it.
1896
1897 2014-02-24  Samuel White  <samuel_white@apple.com>
1898
1899         AX: AccessibilityObject::findMatchingObjects should never include 'this' in results.
1900         https://bugs.webkit.org/show_bug.cgi?id=129243
1901
1902         Reviewed by Chris Fleizach.
1903
1904         Fix removes the container object from the search results when searching backwards. This
1905         makes backwards & forwards search results consistent with each other.
1906
1907         Test: platform/mac/accessibility/search-predicate-container-not-included.html
1908
1909         * accessibility/AccessibilityObject.cpp:
1910         (WebCore::AccessibilityObject::findMatchingObjects):
1911
1912 2014-02-24  Samuel White  <samuel_white@apple.com>
1913
1914         AX: findMatchingObjects backwards start position inconsistent with forwards start position when startObject == nullptr.
1915         https://bugs.webkit.org/show_bug.cgi?id=129266
1916
1917         Reviewed by Chris Fleizach.
1918
1919         When searching forward with no start object, the first thing considered is the first child of
1920         the container. However, when searching backwards with no start object nothing in the container
1921         is considered; this basically negates the search. This patch makes backwards searching without
1922         a start object start from the last child of the container to match forward search expectations.
1923
1924         Test: platform/mac/accessibility/search-predicate-start-not-specified.html
1925
1926         * accessibility/AccessibilityObject.cpp:
1927         (WebCore::AccessibilityObject::findMatchingObjects):
1928
1929 2014-02-24  Andreas Kling  <akling@apple.com>
1930
1931         Prune dead code for Web Inspector canvas instrumentation.
1932         <https://webkit.org/b/129269>
1933
1934         This was leftover code from Chromium's inspector. It's not used by
1935         today's WebKit inspector.
1936
1937         Reviewed by Timothy Hatcher.
1938
1939         * CMakeLists.txt:
1940         * DerivedSources.make:
1941         * GNUmakefile.am:
1942         * GNUmakefile.list.am:
1943         * WebCore.vcxproj/WebCore.vcxproj:
1944         * WebCore.vcxproj/WebCore.vcxproj.filters:
1945         * WebCore.xcodeproj/project.pbxproj:
1946         * bindings/js/JSHTMLCanvasElementCustom.cpp:
1947         (WebCore::JSHTMLCanvasElement::getContext):
1948         * inspector/InjectedScriptCanvasModule.cpp: Removed.
1949         * inspector/InjectedScriptCanvasModule.h: Removed.
1950         * inspector/InspectorAllInOne.cpp:
1951         * inspector/InspectorCanvasAgent.cpp: Removed.
1952         * inspector/InspectorCanvasAgent.h: Removed.
1953         * inspector/InspectorCanvasInstrumentation.h: Removed.
1954         * inspector/InspectorController.cpp:
1955         (WebCore::InspectorController::InspectorController):
1956         (WebCore::InspectorController::didBeginFrame):
1957         * inspector/InspectorInstrumentation.cpp:
1958         (WebCore::InspectorInstrumentation::frameDetachedFromParentImpl):
1959         (WebCore::InspectorInstrumentation::didCommitLoadImpl):
1960         * inspector/InspectorInstrumentation.h:
1961         * inspector/InstrumentingAgents.cpp:
1962         (WebCore::InstrumentingAgents::InstrumentingAgents):
1963         (WebCore::InstrumentingAgents::reset):
1964         * inspector/InstrumentingAgents.h:
1965
1966 2014-02-24  Zoltan Horvath  <zoltan@webkit.org>
1967
1968         [CSS Shapes] Adjust lineTop position to the next available wrapping location at shape-outsides
1969         https://bugs.webkit.org/show_bug.cgi?id=128693
1970
1971         Reviewed by David Hyatt.
1972
1973         When we don't have space next to the floating container, but we have space inside the floating-container next
1974         to the defined shape-outside, we should wrap around the shape-outside. This patch fixes the behavior both for
1975         cases when there is no space to fit at the first line, and for the additional lines cases.
1976
1977         Test: fast/shapes/shape-outside-floats/shape-outside-floats-linetop-adjustment.html
1978
1979         * rendering/line/BreakingContextInlineHeaders.h:
1980         (WebCore::BreakingContext::handleText):
1981         (WebCore::BreakingContext::commitAndUpdateLineBreakIfNeeded):
1982         * rendering/line/LineWidth.cpp:
1983         (WebCore::availableWidthAtOffset):
1984         (WebCore::LineWidth::updateLineDimension): Added new helper.
1985         (WebCore::isWholeLineFit): Added new helper.
1986         (WebCore::LineWidth::wrapNextToShapeOutside): Added new helper.
1987         (WebCore::LineWidth::fitBelowFloats): Add optional parameter for the function.
1988         * rendering/line/LineWidth.h:
1989
1990 2014-02-24  Martin Hock  <mhock@apple.com>
1991
1992         Create SessionID value-style class for session IDs.
1993         https://bugs.webkit.org/show_bug.cgi?id=129141
1994
1995         Reviewed by Brady Eidson.
1996
1997         * GNUmakefile.list.am:
1998         * WebCore.exp.in:
1999         * WebCore.xcodeproj/project.pbxproj:
2000         * page/Page.cpp: Add SessionID member.
2001         (WebCore::Page::Page):
2002         (WebCore::Page::sessionID): Retrieve sessionID or use settings if not set.
2003         * page/Page.h:
2004         (WebCore::Page::setSessionID):
2005         * page/SessionID.h: Session ID class consisting solely of its uint64_t session ID.
2006         (WebCore::SessionID::SessionID):
2007         (WebCore::SessionID::isValid): Not empty.
2008         (WebCore::SessionID::isEphemeral):
2009         (WebCore::SessionID::sessionID):
2010         (WebCore::SessionID::operator==): Value-based equality.
2011         (WebCore::SessionID::operator!=):
2012         (WebCore::SessionID::emptySessionID): Zero value also used for HashTraits emptyValue.
2013         (WebCore::SessionID::defaultSessionID):
2014         (WebCore::SessionID::legacyPrivateSessionID):
2015         * page/SessionIDHash.h:
2016         (WTF::SessionIDHash::hash): Just the casted session ID (low order bytes)
2017         (WTF::SessionIDHash::equal):
2018         (WTF::HashTraits<WebCore::SessionID>::emptyValue): Equal to emptySessionID.
2019         (WTF::HashTraits<WebCore::SessionID>::constructDeletedValue): -1 value.
2020         (WTF::HashTraits<WebCore::SessionID>::isDeletedValue):
2021
2022 2014-02-24  Javier Fernandez  <jfernandez@igalia.com>
2023
2024         [CSS Grid Layout] handle undefined RemainingSpace in computeUsedBreadthOfGridTracks algorithm
2025         https://bugs.webkit.org/show_bug.cgi?id=128372
2026
2027         Reviewed by David Hyatt.
2028
2029         From Blink r165692 by <svillar@igalia.com>
2030
2031         The spec defines a different code path for the computeUsedBreadthOfGridTracks algorithm
2032         http://dev.w3.org/csswg/css-grid/#function-ComputeUsedBreadthOfGridTracks.
2033
2034         Basically the track breadth is different when the available size is undefined and thus,
2035         cannot be taken into account during the computations.
2036         The available size is undefined whenever the height is auto or the grid element has a
2037         shrink-to-fit behavior.
2038
2039         It was also renamed the function to match the specs so the function name starts with
2040         'compute' instead of 'computed'.
2041
2042         No new tests, but added new cases to some of them.
2043
2044         * rendering/RenderGrid.cpp:
2045         (WebCore::RenderGrid::computeIntrinsicLogicalWidths):
2046         (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
2047         (WebCore::gridElementIsShrinkToFit):
2048         (WebCore::RenderGrid::computeNormalizedFractionBreadth):
2049         (WebCore::RenderGrid::layoutGridItems):
2050         * rendering/RenderGrid.h:
2051
2052 2014-02-24  Roger Fong  <roger_fong@apple.com>
2053
2054         [Windows] Unreviewed pre-emptive build fix.
2055
2056         * WebCore.vcxproj/WebCoreCommon.props: Add replay directory to include path.
2057
2058 2014-02-24  Brady Eidson  <beidson@apple.com>
2059
2060         Break out ImageControls style into an external stylesheet
2061         https://bugs.webkit.org/show_bug.cgi?id=129273
2062
2063         Reviewed by Jer Noble.
2064
2065         * DerivedSources.make:
2066         * WebCore.xcodeproj/project.pbxproj:
2067
2068         * css/CSSDefaultStyleSheets.cpp:
2069         (WebCore::CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement):
2070         * css/CSSDefaultStyleSheets.h:
2071
2072         * html/shadow/mac/ImageControlsRootElementMac.cpp:
2073         (WebCore::ImageControlsRootElementMac::maybeCreate):
2074
2075         * html/shadow/mac/imageControlsMac.css:
2076         (.x-webkit-imagemenu):
2077         (.x-webkit-imagemenu:hover):
2078
2079         * rendering/RenderTheme.h:
2080         (WebCore::RenderTheme::mediaControlsScript):
2081         (WebCore::RenderTheme::imageControlsStyleSheet):
2082         * rendering/RenderThemeMac.h:
2083         * rendering/RenderThemeMac.mm:
2084         (WebCore::RenderThemeMac::imageControlsStyleSheet):
2085
2086 2014-02-24  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
2087
2088         [WebRTC] Validating RTCConfiguration according to the spec
2089         https://bugs.webkit.org/show_bug.cgi?id=129182
2090
2091         Reviewed by Eric Carlson.
2092
2093         Spec states that:
2094             - iceServers should not be an empty list
2095             - the entry in the configuration dictionary is "urls", instead of "url"
2096             - urls can be either a list or a string
2097         Fixing all that in RTCConfiguration validation when creating a RTCPeerConnection
2098
2099         Existing tests were updated.
2100
2101         * Modules/mediastream/RTCPeerConnection.cpp:
2102         (WebCore::appendIceServer): Added.
2103         (WebCore::processIceServer): Added.
2104         (WebCore::RTCPeerConnection::parseConfiguration):
2105
2106 2014-02-24  Radu Stavila  <stavila@adobe.com>
2107
2108         [CSS Regions] Relative positioned elements overflowing the region do not get painted into the next tile
2109         https://bugs.webkit.org/show_bug.cgi?id=129254
2110
2111         Reviewed by Antti Koivisto.
2112
2113         The painting of the region's layer should not be aborted so early if the region's fragment shouldn't be painted
2114         because that would prevent all the layer's children from being painted.
2115
2116         Another problem this patch addresses is that clipping should also be performed when the clip rect is empty,
2117         which is what happens when painting in a tile in which the flowed element would normally be painted
2118         if it wasn't clipped by the region.
2119
2120         Test: fast/regions/content-relative-next-tile.html
2121
2122         * rendering/RenderLayer.cpp:
2123         (WebCore::RenderLayer::paintFlowThreadIfRegionForFragments):
2124
2125 2014-02-24  Renata Hodovan  <rhodovan.u-szeged@partner.samsung.com>
2126         
2127         Get rid of the unused 'immediate' parameters from repaint related functions
2128         https://bugs.webkit.org/show_bug.cgi?id=129111
2129
2130         Reviewed by Simon Fraser.
2131
2132         Removing the 'immediate' parameters from repaint related functions - accoring
2133         to the FIXME in RenderView::repaintViewRectangle() - since they have no effect.
2134
2135         No new tests are necessary because there is no behavior change
2136
2137         * dom/Element.cpp:
2138         (WebCore::Element::setActive):
2139         * loader/EmptyClients.h:
2140         * page/Chrome.cpp:
2141         (WebCore::Chrome::invalidateRootView):
2142         (WebCore::Chrome::invalidateContentsAndRootView):
2143         (WebCore::Chrome::invalidateContentsForSlowScroll):
2144         * page/Chrome.h:
2145         * page/ChromeClient.h:
2146         * page/Frame.cpp:
2147         (WebCore::Frame::tiledBackingStorePaintEnd):
2148         * page/FrameView.cpp:
2149         (WebCore::FrameView::invalidateRect):
2150         (WebCore::FrameView::scrollContentsFastPath):
2151         (WebCore::FrameView::repaintContentRectangle):
2152         (WebCore::FrameView::shouldUpdate):
2153         * page/FrameView.h:
2154         * platform/HostWindow.h:
2155         * platform/ScrollView.cpp:
2156         (WebCore::ScrollView::scrollContents):
2157         (WebCore::ScrollView::scrollContentsSlowPath):
2158         (WebCore::ScrollView::repaintContentRectangle):
2159         (WebCore::ScrollView::updateOverhangAreas):
2160         (WebCore::ScrollView::addPanScrollIcon):
2161         (WebCore::ScrollView::removePanScrollIcon):
2162         (WebCore::ScrollView::platformRepaintContentRectangle):
2163         * platform/ScrollView.h:
2164         * rendering/RenderBox.cpp:
2165         (WebCore::RenderBox::repaintLayerRectsForImage):
2166         * rendering/RenderFlowThread.cpp:
2167         (WebCore::RenderFlowThread::repaintRectangleInRegions):
2168         * rendering/RenderFlowThread.h:
2169         * rendering/RenderLayer.cpp:
2170         (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
2171         * rendering/RenderLayer.h:
2172         * rendering/RenderMultiColumnSet.cpp:
2173         (WebCore::RenderMultiColumnSet::repaintFlowThreadContent):
2174         * rendering/RenderMultiColumnSet.h:
2175         * rendering/RenderObject.cpp:
2176         (WebCore::RenderObject::repaintUsingContainer):
2177         (WebCore::RenderObject::repaint):
2178         (WebCore::RenderObject::repaintRectangle):
2179         (WebCore::RenderObject::repaintSlowRepaintObject):
2180         * rendering/RenderObject.h:
2181         * rendering/RenderRegion.cpp:
2182         (WebCore::RenderRegion::repaintFlowThreadContent):
2183         (WebCore::RenderRegion::repaintFlowThreadContentRectangle):
2184         * rendering/RenderRegion.h:
2185         * rendering/RenderView.cpp:
2186         (WebCore::RenderView::repaintViewRectangle):
2187         (WebCore::RenderView::flushAccumulatedRepaintRegion):
2188         (WebCore::RenderView::repaintRectangleInViewAndCompositedLayers):
2189         * rendering/RenderView.h:
2190         * svg/graphics/SVGImageChromeClient.h:
2191
2192 2014-02-24  Tamas Gergely  <tgergely.u-szeged@partner.samsung.com>
2193
2194         Code cleanup: remove leftover ENABLE(WORKERS) macros and support.
2195         https://bugs.webkit.org/show_bug.cgi?id=129255
2196
2197         Reviewed by Csaba Osztrogonác.
2198
2199         ENABLE_WORKERS macro was removed in r159679, but r161589 added back some occurrences.
2200         Support is now also removed from xcconfig files.
2201
2202         No new tests needed.
2203
2204         * Configurations/FeatureDefines.xcconfig:
2205         * platform/ThreadGlobalData.cpp:
2206         * platform/ThreadGlobalData.h:
2207         * platform/Timer.h:
2208         (WebCore::TimerBase::isActive):
2209         * platform/ios/wak/WebCoreThread.mm:
2210         (RunWebThread):
2211         (StartWebThread):
2212
2213 2014-02-24  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
2214
2215         [CMake] Get rid of "FIXME: The Blackberry port ..." from WebCore/CmakeLists.txt
2216         https://bugs.webkit.org/show_bug.cgi?id=129152
2217
2218         Reviewed by Gyuyoung Kim.
2219
2220         * CMakeLists.txt:
2221
2222 2014-02-24  David Kilzer  <ddkilzer@apple.com>
2223
2224         Remove redundant setting in FeatureDefines.xcconfig
2225
2226         * Configurations/FeatureDefines.xcconfig:
2227
2228 2014-02-24  Mihai Tica  <mitica@adobe.com>
2229
2230         [CSS Blending] An element having -webkit-mix-blend-mode should only blend with the contents of the parent stacking context
2231         https://bugs.webkit.org/show_bug.cgi?id=129154
2232
2233         Reviewed by Dean Jackson.
2234
2235         The blending operation of an element having -webkit-mix-blend-mode should be restricted to the parent stacking context.
2236         This change isolates blending, preventing it from blending with other underlying elements besides the parent stacking context.
2237
2238         Tests: css3/compositing/blend-mode-isolated-group-1.html
2239                css3/compositing/blend-mode-isolated-group-2.html
2240                css3/compositing/blend-mode-isolated-group-3.html
2241
2242         * rendering/RenderLayer.cpp:
2243         (WebCore::RenderLayer::RenderLayer): Initialize added members to false.
2244         (WebCore::RenderLayer::updateBlendMode): Check if a blend mode was set or unset. If so, set the m_updateParentStackingContextShouldIsolateBlendingDirty to true.
2245         (WebCore::RenderLayer::updateParentStackingContextShouldIsolateBlending): Traverse to the parent stacking context and update the
2246         m_isolatesBlending member accordingly.
2247         * rendering/RenderLayer.h:
2248         - Add isolatesBlending() as a condition for creating a transparency layer in the paintsWithTransparency method.
2249         - Add m_updateParentStackingContextShouldIsolateBlendingDirty member.
2250         - Add m_isolatesBlending member and getter.
2251         * rendering/RenderLayerCompositor.cpp:
2252         (WebCore::RenderLayerCompositor::computeCompositingRequirements): Call updateParentStackingContextShouldIsolateBlending. 
2253
2254 2014-02-24  Krzysztof Czech  <k.czech@samsung.com>
2255
2256         [ATK] Wrong selected element at a given index in a list box.
2257         https://bugs.webkit.org/show_bug.cgi?id=129039
2258
2259         Reviewed by Chris Fleizach.
2260
2261         Test: accessibility/select-element-at-index.html
2262
2263         The selected element at a given index was wrong. One should be considered among the
2264         all children of a list box, not only selected ones.
2265
2266         * accessibility/atk/WebKitAccessibleInterfaceSelection.cpp:
2267         (core):
2268         (listObjectForSelection):
2269         (optionFromList):
2270         (optionFromSelection):
2271         (webkitAccessibleSelectionRefSelection):
2272
2273 2014-02-23  Dean Jackson  <dino@apple.com>
2274
2275         [WebGL] Allow ANGLE to initialize unused varyings
2276         https://bugs.webkit.org/show_bug.cgi?id=129240
2277         <rdar://problem/15203342>
2278
2279         Reviewed by Sam Weinig.
2280
2281         Covered by: conformance/glsl/misc/shaders-with-varyings.html
2282
2283         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
2284         (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE):
2285         Add SH_INIT_VARYINGS_WITHOUT_STATIC_USE to compiler flags.
2286
2287 2014-02-23  Sam Weinig  <sam@webkit.org>
2288
2289         Update FeatureDefines.xcconfig
2290
2291         Rubber-stamped by Anders Carlsson.
2292
2293         * Configurations/FeatureDefines.xcconfig:
2294
2295 2014-02-23  Dean Jackson  <dino@apple.com>
2296
2297         Sort the project file with sort-Xcode-project-file.
2298
2299         Rubber-stamped by Sam Weinig.
2300
2301         * WebCore.xcodeproj/project.pbxproj:
2302
2303 2014-02-23  Sam Weinig  <sam@webkit.org>
2304
2305         Fix incorrectly commented out code.
2306
2307         * platform/TelephoneNumberDetector.h:
2308
2309 2014-02-23  Sam Weinig  <sam@webkit.org>
2310
2311         Extract platform specific parts of telephone number detection 
2312         https://bugs.webkit.org/show_bug.cgi?id=129238
2313
2314         Reviewed by Dean Jackson.
2315
2316         * WebCore.xcodeproj/project.pbxproj:
2317         Add new files.
2318
2319         * html/parser/HTMLTreeBuilder.cpp:
2320         (WebCore::HTMLTreeBuilder::linkifyPhoneNumbers):
2321         (WebCore::HTMLTreeBuilder::processCharacterBufferForInBody):
2322         * platform/TelephoneNumberDetector.h: Added.
2323         * platform/cocoa/TelephoneNumberDetectorCocoa.cpp: Added.
2324         (WebCore::TelephoneNumberDetector::phoneNumbersScanner):
2325         (WebCore::TelephoneNumberDetector::isSupported):
2326         (WebCore::TelephoneNumberDetector::find):
2327         Move code to TelephoneNumberDetector.
2328
2329 2014-02-23  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2330
2331         Change a url parameter type with URL in NavigatorContentUtils
2332         https://bugs.webkit.org/show_bug.cgi?id=129202
2333
2334         Reviewed by Sam Weinig.
2335
2336         It would be good if we use *URL* for url parameters instead of using String.
2337
2338         Merge from blink. https://src.chromium.org/viewvc/blink?view=rev&revision=165458.
2339
2340         * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
2341         (WebCore::verifyCustomHandlerURL):
2342         (WebCore::NavigatorContentUtils::registerProtocolHandler):
2343         (WebCore::NavigatorContentUtils::isProtocolHandlerRegistered):
2344         (WebCore::NavigatorContentUtils::unregisterProtocolHandler):
2345         * Modules/navigatorcontentutils/NavigatorContentUtilsClient.h:
2346
2347 2014-02-23  Dean Jackson  <dino@apple.com>
2348
2349         Update ANGLE to 836bd2176e5607b14846cf1fbc5932dbc91318f4
2350         https://bugs.webkit.org/show_bug.cgi?id=129232
2351
2352         Reviewed by Brent Fulgham.
2353
2354         New files added, derived sources compiled directly, and generated
2355         steps removed for both EFL and GTK, with much-needed help from
2356         Sergio Correia.
2357
2358         * CMakeLists.txt:
2359         * GNUMakefile.am:
2360
2361 2014-02-23  Sam Weinig  <sam@webkit.org>
2362
2363         Move RenderMathMLMenclose.h/cpp to the right place in the Xcode project and sort.
2364
2365         Rubber-stamped by Anders Carlsson.
2366
2367         * WebCore.xcodeproj/project.pbxproj:
2368
2369 2014-02-23  Sam Weinig  <sam@webkit.org>
2370
2371         Move telephone number detection behind its own ENABLE macro
2372         https://bugs.webkit.org/show_bug.cgi?id=129236
2373
2374         Reviewed by Dean Jackson.
2375
2376         * Configurations/FeatureDefines.xcconfig:
2377         Add ENABLE_TELEPHONE_NUMBER_DETECTION.
2378
2379         * dom/Document.cpp:
2380         (WebCore::Document::Document):
2381         * dom/Document.h:
2382         * html/parser/HTMLConstructionSite.h:
2383         * html/parser/HTMLTreeBuilder.cpp:
2384         (WebCore::HTMLTreeBuilder::processCharacterBufferForInBody):
2385         * html/parser/HTMLTreeBuilder.h:
2386         Use ENABLE(TELEPHONE_NUMBER_DETECTION).
2387
2388         * platform/mac/SoftLinking.h:
2389         Remove PLATOFORM(IOS) from SOFT_LINK_PRIVATE_FRAMEWORK_OPTIONAL, it is not iOS specific.
2390
2391 2014-02-23  Zalan Bujtas  <zalan@apple.com>
2392
2393         Subpixel rendering: Fix bleed avoidance subpixel calculation.
2394         https://bugs.webkit.org/show_bug.cgi?id=129225
2395
2396         Reviewed by Simon Fraser.
2397         
2398         static_cast<LayoutUnit>(int value) only produces the desired result when subpixel is off.
2399
2400         Currently not testable.
2401
2402         * rendering/RenderBoxModelObject.cpp:
2403         (WebCore::RenderBoxModelObject::getBackgroundRoundedRect):
2404         (WebCore::shrinkRectByOneDevicePixel):
2405         (WebCore::RenderBoxModelObject::borderInnerRectAdjustedForBleedAvoidance):
2406         (WebCore::RenderBoxModelObject::backgroundRoundedRectAdjustedForBleedAvoidance):
2407         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2408         * rendering/RenderBoxModelObject.h:
2409
2410 2014-02-23  Zalan Bujtas  <zalan@apple.com>
2411
2412         Subpixel rendering: Add devicepixel based computation to BorderEdge class.
2413         https://bugs.webkit.org/show_bug.cgi?id=129224
2414
2415         Reviewed by Simon Fraser.
2416
2417         To produce correct width (and type) results, BorderEdge class needs to take device pixel ratio into account.
2418
2419         Currently not testable.
2420
2421         * rendering/RenderBoxModelObject.cpp:
2422         (WebCore::BorderEdge::BorderEdge):
2423         (WebCore::BorderEdge::obscuresBackgroundEdge):
2424         (WebCore::BorderEdge::getDoubleBorderStripeWidths): this does not always produce the same
2425         result as before, but the sum of inner and outer is not different.
2426         (WebCore::BorderEdge::borderWidthInDevicePixel):
2427         (WebCore::RenderBoxModelObject::getBorderEdgeInfo):
2428
2429 2014-02-22  Dan Bernstein  <mitz@apple.com>
2430
2431         REGRESSION (r164507): Crash beneath JSGlobalObjectInspectorController::reportAPIException at facebook.com, twitter.com, youtube.com
2432         https://bugs.webkit.org/show_bug.cgi?id=129227
2433
2434         Reviewed by Eric Carlson.
2435
2436         Reverted r164507.
2437
2438         * bindings/js/JSDOMBinding.cpp:
2439         (WebCore::reportException):
2440         * inspector/InspectorResourceAgent.cpp:
2441         (WebCore::InspectorResourceAgent::buildInitiatorObject):
2442         * inspector/PageDebuggerAgent.cpp:
2443         (WebCore::PageDebuggerAgent::breakpointActionLog):
2444         * inspector/TimelineRecordFactory.cpp:
2445         (WebCore::TimelineRecordFactory::createGenericRecord):
2446         * page/Console.cpp:
2447         (WebCore::internalAddMessage):
2448         (WebCore::Console::profile):
2449         (WebCore::Console::profileEnd):
2450         (WebCore::Console::timeEnd):
2451         * page/ContentSecurityPolicy.cpp:
2452         (WebCore::gatherSecurityPolicyViolationEventData):
2453         (WebCore::ContentSecurityPolicy::reportViolation):
2454         * page/DOMWindow.cpp:
2455         (WebCore::DOMWindow::postMessage):
2456
2457 2014-02-22  Joseph Pecoraro  <pecoraro@apple.com>
2458
2459         Remove some unreachable code (-Wunreachable-code)
2460         https://bugs.webkit.org/show_bug.cgi?id=129220
2461
2462         Reviewed by Eric Carlson.
2463
2464         * html/parser/HTMLTreeBuilder.cpp:
2465         (WebCore::HTMLTreeBuilder::processCharacterBuffer):
2466         (WebCore::HTMLTreeBuilder::processEndTag):
2467         The only tricky case. Here there was a break inside the
2468         #if, but not the #else, and a break after the #endif.
2469         Remove the break inside the #if, and always use the
2470         break after the #endif.
2471
2472         * Modules/indexeddb/IDBTransaction.cpp:
2473         (WebCore::IDBTransaction::modeToString):
2474         * bindings/js/JSTrackCustom.cpp:
2475         (WebCore::toJS):
2476         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2477         (WebCore::functionForUniform):
2478         * css/SelectorChecker.cpp:
2479         (WebCore::SelectorChecker::checkOne):
2480         * html/HTMLMediaElement.cpp:
2481         (WebCore::HTMLMediaElement::parseAttribute):
2482         * page/CaptionUserPreferencesMediaAF.cpp:
2483         (WebCore::CaptionUserPreferencesMediaAF::captionDisplayMode):
2484
2485 2014-02-22  Dean Jackson  <dino@apple.com>
2486
2487         Letterpress effect disabled for synthetic italic
2488         https://bugs.webkit.org/show_bug.cgi?id=129218
2489         <rdar://problem/15997846>
2490
2491         Reviewed by Dan Bernstein.
2492
2493         There was no need to guard against synthetic italics and letterpress.
2494
2495         * platform/graphics/mac/FontMac.mm:
2496         (WebCore::Font::drawGlyphs): Remove !useLetterpressEffect from conditional.
2497
2498 2014-02-21  Sam Weinig  <sam@webkit.org>
2499
2500         Expose phase and momentum phase as SPI on DOMWheelEvent
2501         <rdar://problem/16110871>
2502         https://bugs.webkit.org/show_bug.cgi?id=129184
2503
2504         Reviewed by Anders Carlsson.
2505
2506         * WebCore.exp.in:
2507         Export core(DOMWheelEvent).
2508
2509         * WebCore.xcodeproj/project.pbxproj:
2510         Make DOMWheelEventInternal.h available in WebKit.
2511
2512         * dom/Element.cpp:
2513         (WebCore::Element::dispatchWheelEvent):
2514         * dom/WheelEvent.cpp:
2515         (WebCore::determineDeltaMode):
2516         (WebCore::WheelEvent::WheelEvent):
2517         (WebCore::WheelEvent::initWheelEvent):
2518         (WebCore::WheelEvent::initWebKitWheelEvent):
2519         Move PlatformWheelEvent -> DOMWheelEvent conversion to DOMWheelEvent.
2520
2521         * dom/WheelEvent.h:
2522         (WebCore::WheelEvent::create):
2523         (WebCore::WheelEvent::phase):
2524         (WebCore::WheelEvent::momentumPhase):
2525         Store phase and momentumPhase on the WheelEvent.
2526
2527 2014-02-22  Alexey Proskuryakov  <ap@apple.com>
2528
2529         Rename JWK key_ops values from wrap/unwrap to wrapKey/unwrapKey
2530         https://bugs.webkit.org/show_bug.cgi?id=129121
2531
2532         Reviewed by Sam Weinig.
2533
2534         * bindings/js/JSCryptoKeySerializationJWK.cpp:
2535         (WebCore::JSCryptoKeySerializationJWK::reconcileUsages): Updated to newer names.
2536         (WebCore::addUsagesToJSON): Ditto.
2537         (WebCore::JSCryptoKeySerializationJWK::serialize): rsa-oaep-key-manipulation test
2538         started ot fail, because RSA-OAEP with 2048 bit key and sha-1 can only encrypt
2539         214 bytes, and the new longer names made JSON serialization slightly longer.
2540         Compensate by not doing any indentation in JSON.
2541
2542 2014-02-22  Frédéric Wang  <fred.wang@free.fr>
2543
2544         Only skip stretchy operators when determining the stretch height.
2545         https://bugs.webkit.org/show_bug.cgi?id=126842
2546
2547         Reviewed by Chris Fleizach.
2548
2549         The MathML code only takes into account non-mo children for the computation of the stretch size. This change includes non-stretchy mo in that computation. A new test is added into mathml/presentation/stretchy-depth-height.html.
2550
2551         * rendering/mathml/RenderMathMLRow.cpp:
2552         (WebCore::RenderMathMLRow::layout):
2553
2554 2014-02-22  Frédéric Wang  <fred.wang@free.fr>
2555
2556         Implement asymmetric/symmetric stretching of vertical operators.
2557         https://bugs.webkit.org/show_bug.cgi?id=124827.
2558
2559         Reviewed by Chris Fleizach.
2560
2561         The MathML code stretches vertical operators asymmetrically by default. This patch takes into account the symmetric attribute or the symmetric property of the operator dictionary to stretch operators symmetrically.
2562
2563         Test: mathml/presentation/stretchy-depth-height-symmetric.html
2564
2565         * rendering/mathml/RenderMathMLOperator.cpp:
2566         (WebCore::RenderMathMLOperator::stretchTo):
2567         (WebCore::RenderMathMLOperator::updateFromElement):
2568         (WebCore::RenderMathMLOperator::updateStyle):
2569
2570 2014-02-22  Frédéric Wang  <fred.wang@free.fr>
2571
2572         Bug 119043 - Large stretch size error for MathML operators.
2573         https://bugs.webkit.org/show_bug.cgi?id=119043
2574
2575         Reviewed by Chris Fleizach.
2576
2577         The MathML code used some arbitrary gOperatorExpansion factor for the
2578         stretch size and 2/3 1/2 constants for the baseline. This change tries
2579         to consider height/depth of siblings of the stretchy operator so that
2580         the stretchy operator now matches its target.
2581
2582         Test: mathml/presentation/stretchy-depth-height.html
2583
2584         * rendering/RenderObject.h:
2585         (WebCore::RenderObject::isRenderMathMLTable):
2586         * rendering/mathml/RenderMathMLBlock.h:
2587         * rendering/mathml/RenderMathMLOperator.cpp:
2588         (WebCore::RenderMathMLOperator::RenderMathMLOperator):
2589         (WebCore::RenderMathMLOperator::stretchTo):
2590         (WebCore::RenderMathMLOperator::findAcceptableStretchyCharacter):
2591         (WebCore::RenderMathMLOperator::updateStyle):
2592         (WebCore::RenderMathMLOperator::firstLineBaseline):
2593         (WebCore::RenderMathMLOperator::computeLogicalHeight):
2594         * rendering/mathml/RenderMathMLOperator.h:
2595         * rendering/mathml/RenderMathMLRow.cpp:
2596         (WebCore::RenderMathMLRow::layout):
2597
2598 2014-02-22  Frédéric Wang  <fred.wang@free.fr>
2599
2600         Unreviewed, rolling out r164534.
2601         http://trac.webkit.org/changeset/164534
2602         https://bugs.webkit.org/show_bug.cgi?id=119043
2603
2604         missing tests
2605
2606         * rendering/RenderObject.h:
2607         * rendering/mathml/RenderMathMLBlock.h:
2608         * rendering/mathml/RenderMathMLOperator.cpp:
2609         (WebCore::RenderMathMLOperator::RenderMathMLOperator):
2610         (WebCore::RenderMathMLOperator::expandedStretchHeight):
2611         (WebCore::RenderMathMLOperator::stretchToHeight):
2612         (WebCore::RenderMathMLOperator::findAcceptableStretchyCharacter):
2613         (WebCore::RenderMathMLOperator::updateStyle):
2614         (WebCore::RenderMathMLOperator::firstLineBaseline):
2615         (WebCore::RenderMathMLOperator::computeLogicalHeight):
2616         * rendering/mathml/RenderMathMLOperator.h:
2617         * rendering/mathml/RenderMathMLRow.cpp:
2618         (WebCore::RenderMathMLRow::layout):
2619
2620 2014-02-22  Frédéric Wang  <fred.wang@free.fr>
2621
2622         Bug 119043 - Large stretch size error for MathML operators.
2623         https://bugs.webkit.org/show_bug.cgi?id=119043
2624
2625         Reviewed by Chris Fleizach.
2626
2627         The MathML code used some arbitrary gOperatorExpansion factor for the
2628         stretch size and 2/3 1/2 constants for the baseline. This change tries
2629         to consider height/depth of siblings of the stretchy operator so that
2630         the stretchy operator now matches its target.
2631
2632         Test: mathml/presentation/stretchy-depth-height.html
2633
2634         * rendering/RenderObject.h:
2635         (WebCore::RenderObject::isRenderMathMLTable):
2636         * rendering/mathml/RenderMathMLBlock.h:
2637         * rendering/mathml/RenderMathMLOperator.cpp:
2638         (WebCore::RenderMathMLOperator::RenderMathMLOperator):
2639         (WebCore::RenderMathMLOperator::stretchTo):
2640         (WebCore::RenderMathMLOperator::findAcceptableStretchyCharacter):
2641         (WebCore::RenderMathMLOperator::updateStyle):
2642         (WebCore::RenderMathMLOperator::firstLineBaseline):
2643         (WebCore::RenderMathMLOperator::computeLogicalHeight):
2644         * rendering/mathml/RenderMathMLOperator.h:
2645         * rendering/mathml/RenderMathMLRow.cpp:
2646         (WebCore::RenderMathMLRow::layout):
2647
2648 2014-02-21  Zalan Bujtas  <zalan@apple.com>
2649
2650         REGRESSION(r164412): Pixel cracks when zooming in to any web content.
2651         https://bugs.webkit.org/show_bug.cgi?id=129195
2652
2653         Reviewed by Simon Fraser.
2654
2655         Integral clipping of the repaint rect was prematurely removed in RenderLayerBacking::paintContents().
2656         Repaint rects needs a uniform, device pixel precise clipping across the painting flow including RenderLayer,
2657         RenderView and TileController.
2658
2659         * rendering/RenderLayerBacking.cpp:
2660         (WebCore::RenderLayerBacking::paintContents):
2661         (WebCore::RenderLayerBacking::compositedBoundsIncludingMargin):
2662
2663 2014-02-21  Jer Noble  <jer.noble@apple.com>
2664
2665         Unreviewed Mac build fix after r164529.
2666
2667         Replace the string-to-array algorithm with a archictecture-independant
2668         one.
2669
2670         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
2671         (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest):
2672
2673 2014-02-21  Jer Noble  <jer.noble@apple.com>
2674
2675         [EME] Add a CDMSession for MediaPlayerPrivateMediaSourceAVFObjC
2676         https://bugs.webkit.org/show_bug.cgi?id=129166
2677
2678         Reviewed by Eric Carlson.
2679
2680         Add a new CDMSession, cerated by MediaPlayerPrivateMediaSourceAVFObjC allowing
2681         media-source-backed media elements to play protected content.
2682
2683         Add a new CDMSessionMediaSourceAVFObjC class:
2684         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.h: Added.
2685         (WebCore::CDMSessionMediaSourceAVFObjC::~CDMSessionMediaSourceAVFObjC):
2686         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm: Added.
2687         (WebCore::CDMSessionMediaSourceAVFObjC::CDMSessionMediaSourceAVFObjC):
2688         (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest): Do not actually generate a
2689             key request until the certificate data has been added via update();
2690         (WebCore::CDMSessionMediaSourceAVFObjC::releaseKeys): No-op.
2691         (WebCore::CDMSessionMediaSourceAVFObjC::update): If no certificate data has yet been
2692             added, assume the incoming message contains it.
2693
2694         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
2695         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
2696         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::registerMediaEngine): Add supportsKeySystem.
2697         (WebCore::keySystemIsSupported): Use "com.apple.fps.2_0" to distinguish from the not-media-source scheme.
2698         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsType): Check the keySystem type.
2699         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsKeySystem): Added.
2700         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::createSession): Added, pass through to MediaSourcePrivate.
2701         * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
2702         * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
2703         (WebCore::MediaSourcePrivateAVFObjC::createSession): Added.
2704         (WebCore::MediaSourcePrivateAVFObjC::sourceBufferKeyNeeded): Pass through to MediaPlayer.
2705         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
2706         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
2707         (-[WebAVStreamDataParserListener streamDataParser:didProvideContentKeyRequestInitializationData:forTrackID:]):
2708             Added, pass through to SourceBufferPrivate.
2709         (WebCore::SourceBufferPrivateAVFObjC::SourceBufferPrivateAVFObjC):
2710         (WebCore::SourceBufferPrivateAVFObjC::didProvideContentKeyRequestInitializationDataForTrackID): Remember
2711             which track is requesting the key, and pass the request to MediaSourcePrivate.
2712
2713         Add new files to the project.
2714         * WebCore.xcodeproj/project.pbxproj:
2715
2716 2014-02-21  Alexey Proskuryakov  <ap@apple.com>
2717
2718         CryptoAlgorithmRSASSA_PKCS1_v1_5::platformVerify contains seemingly accidental unreachable code
2719         https://bugs.webkit.org/show_bug.cgi?id=129193
2720
2721         Reviewed by Joseph Pecoraro.
2722
2723         * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp:
2724         (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformVerify): Fix the accidental code.
2725
2726 2014-02-21  Brent Fulgham  <bfulgham@apple.com>
2727
2728         Extend media support for WebVTT sources
2729         https://bugs.webkit.org/show_bug.cgi?id=129156
2730
2731         Reviewed by Eric Carlson.
2732
2733         * Configurations/FeatureDefines.xcconfig: Add new feature define for AVF_CAPTIONS
2734         * html/HTMLMediaElement.cpp:
2735         (WebCore::HTMLMediaElement::outOfBandTrackSources): Added.
2736         * html/HTMLMediaElement.h:
2737         * platform/graphics/MediaPlayer.cpp:
2738         (WebCore::MediaPlayer::outOfBandTrackSources): Added.
2739         * platform/graphics/MediaPlayer.h:
2740         (WebCore::MediaPlayerClient::outOfBandTrackSources): Added.
2741         * platform/graphics/PlatformTextTrack.h:
2742         (WebCore::PlatformTextTrack::create): Update for new constructor signature.
2743         (WebCore::PlatformTextTrack::createOutOfBand): Added.
2744         (WebCore::PlatformTextTrack::url): Added.
2745         (WebCore::PlatformTextTrack::isDefault): Added.
2746         (WebCore::PlatformTextTrack::PlatformTextTrack): Revised to take new URL and
2747         'isDefault' arguments.
2748         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2749         (WebCore::mediaDescriptionForKind): Added.
2750         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Tell AVFoundation about any
2751         WebVTT tracks supplied by the web page.
2752         (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions): Filter out any out-of-band
2753         WebVTT tracks returned by the media engine to avoid double-counting tracks.
2754
2755 2014-02-21  Ryosuke Niwa  <rniwa@webkit.org>
2756
2757         Inner text element should not use -webkit-user-modify
2758         https://bugs.webkit.org/show_bug.cgi?id=129035
2759
2760         Reviewed by Andreas Kling.
2761
2762         To eliminate the internal use of -webkit-user-modify, use contenteditable attribute in the inner text elements
2763         instead of manually inspecting disabled-ness and readonly-ness in RenderTextControl.
2764
2765         Unfortunately, we still have to manually set UserModify value in RenderTextControl::adjustInnerTextStyle since
2766         RenderTextControl::styleDidChange creates RenderStyle for its inner text from scratch via createInnerTextStyle.    
2767
2768         * html/HTMLFieldSetElement.cpp:
2769         (WebCore::HTMLFieldSetElement::disabledStateChanged): Don't use childrenOfType iterator which asserts that DOM
2770         isn't mutated during the traversal since we now set contenteditable attribute inside disabledStateChanged via
2771         updateFromControlElementsAncestorDisabledStateUnder.
2772
2773         * html/HTMLFormControlElement.cpp:
2774         (WebCore::HTMLFormControlElement::parseAttribute): Extracted readOnlyAttributeChanged out of this function so
2775         that HTMLTextFormControl could override it to call updateInnerTextElementEditability.
2776         (WebCore::HTMLFormControlElement::readOnlyAttributeChanged): Ditto.
2777         * html/HTMLFormControlElement.h:
2778
2779         * html/HTMLInputElement.cpp:
2780         (WebCore::HTMLInputElement::didAddUserAgentShadowRoot): Call updateInnerTextElementEditability after creating
2781         shadow DOM for the current input type.
2782         (WebCore::HTMLInputElement::updateType): Ditto.
2783         (WebCore::HTMLInputElement::parseAttribute): Ditto.
2784
2785         * html/HTMLTextAreaElement.cpp:
2786         (WebCore::HTMLTextAreaElement::didAddUserAgentShadowRoot): Call updateInnerTextElementEditability.
2787
2788         * html/HTMLTextFormControlElement.cpp:
2789         (WebCore::HTMLTextFormControlElement::disabledStateChanged): Added to update contenteditable attribute since
2790         the editability of the inner text element depends on disabled-ness of the element.
2791         (WebCore::HTMLTextFormControlElement::readOnlyAttributeChanged): Ditto for the readonly-ness of the element.
2792         (WebCore::HTMLTextFormControlElement::updateInnerTextElementEditability): Added.
2793         * html/HTMLTextFormControlElement.h:
2794
2795         * rendering/RenderTextControl.cpp:
2796         (WebCore::RenderTextControl::adjustInnerTextStyle): Use the inner text element's presentationAttributeStyle() to
2797         compute the appropriate EUserModify value instead of hard-coding it here.
2798         * rendering/RenderTextControl.h:
2799
2800 2014-02-21  ChangSeok Oh  <changseok.oh@collabora.com>
2801
2802         [GTK] Support WEBGL_draw_buffers extension.
2803         https://bugs.webkit.org/show_bug.cgi?id=129143
2804
2805         Reviewed by Dean Jackson.
2806
2807         Support the WEBGL_draw_buffers WebGL extension for gtk port. Relevant opengl APIs
2808         are exposed for WebGLRenderingContext to access them properly.
2809
2810         Covered by fast/canvas/webgl/webgl-draw-buffers.html
2811
2812         * platform/graphics/OpenGLShims.cpp:
2813         (WebCore::initializeOpenGLShims):
2814         * platform/graphics/OpenGLShims.h:
2815         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
2816         (WebCore::Extensions3DOpenGL::supportsExtension):
2817         (WebCore::Extensions3DOpenGL::drawBuffersEXT):
2818
2819 2014-02-21  ChangSeok Oh  <changseok.oh@collabora.com>
2820
2821         Mac port uses ANGLE_instanced_arrays related apis through those in GraphicsContext3DCommon.cpp
2822         https://bugs.webkit.org/show_bug.cgi?id=128803
2823
2824         Reviewed by Dean Jackson.
2825
2826         Merge mac port implementation of ANGLE_instanced_arrays into common code.
2827
2828         No new tests, no functionality changed.
2829
2830         * platform/graphics/mac/GraphicsContext3DMac.mm:
2831         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
2832         (WebCore::Extensions3DOpenGL::drawArraysInstanced):
2833         (WebCore::Extensions3DOpenGL::drawElementsInstanced):
2834         (WebCore::Extensions3DOpenGL::vertexAttribDivisor):
2835         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
2836         (WebCore::GraphicsContext3D::vertexAttribDivisor):
2837
2838 2014-02-21  Myles C. Maxfield  <mmaxfield@apple.com>
2839
2840         After copy and paste, cursor may appear to be above the bottom of content
2841         https://bugs.webkit.org/show_bug.cgi?id=129167
2842
2843         Reviewed by Ryosuke Niwa.
2844
2845         Adding a clear:both to the end of content.
2846
2847         I can't handle the case of the cursor appearing above the bottom of
2848         absolutely positioned divs (of the case of floats inside absolutely
2849         positioned divs) because you can't know where the bottom of a div
2850         will end up being rendered (it is affected by things like browser
2851         window width and text size settings). Therefore, the only case I
2852         can handle is the case where there is a floating div in the same
2853         level as the document itself.
2854
2855         Test: editing/pasteboard/copy-paste-inserts-clearing-div.html
2856
2857         * editing/EditingStyle.cpp:
2858         (WebCore::EditingStyle::isFloating):
2859         * editing/EditingStyle.h:
2860         * editing/markup.cpp:
2861         (WebCore::StyledMarkupAccumulator::StyledMarkupAccumulator):
2862         (WebCore::StyledMarkupAccumulator::appendElement):
2863         (WebCore::createMarkupInternal):
2864
2865 2014-02-21  Dean Jackson  <dino@apple.com>
2866
2867         [iOS Media] Wireless target UI
2868         https://bugs.webkit.org/show_bug.cgi?id=129189
2869         <rdar://problem/15349928>
2870         <rdar://problem/16100060>
2871
2872         Reviewed by Eric Carlson.
2873
2874         Implement a prototype UI for wireless playback targets. The UI
2875         doesn't currently work, but can be simulated via a class variable
2876         in ControllerIOS.
2877
2878         * Modules/mediacontrols/mediaControlsiOS.css:
2879         (audio::-webkit-media-controls-panel button): Reset the default style of
2880         button elements, to avoid getting a border.
2881         (audio::-webkit-media-controls-wireless-playback-status): Holds the UI showing
2882         the user that the media is playing on another target.
2883         (audio::-webkit-media-controls-wireless-playback-status.hidden):
2884         (audio::-webkit-media-controls-wireless-playback-picker-button): The button to
2885         trigger selection of targets.
2886         (audio::-webkit-media-controls-wireless-playback-picker-button.active):
2887         (audio::-webkit-media-controls-panel): This needs to be position absolute for
2888         the wireless playback status to fill the viewport.
2889         * Modules/mediacontrols/mediaControlsiOS.js:
2890         (ControllerIOS): Check for targets.
2891         (ControllerIOS.prototype.addVideoListeners):
2892         (ControllerIOS.prototype.removeVideoListeners):
2893         (ControllerIOS.prototype.UIString): New method to return localized strings (with
2894         a FIXME).
2895         (ControllerIOS.prototype.shouldHaveAnyUI): Needs to display if there is a wireless
2896         target.
2897         (ControllerIOS.prototype.currentPlaybackTargetIsWireless):
2898         (ControllerIOS.prototype.updateWirelessPlaybackStatus): Create the status content,
2899         replacing the device name if it is available.
2900         (ControllerIOS.prototype.updateWirelessTargetAvailable):
2901         (ControllerIOS.prototype.createControls):
2902         (ControllerIOS.prototype.configureInlineControls):
2903         (ControllerIOS.prototype.handleWirelessPlaybackChange):
2904         (ControllerIOS.prototype.handleWirelessTargetAvailableChange):
2905         (ControllerIOS.prototype.handleWirelessPickerButtonClicked):
2906
2907 2014-02-21  Jer Noble  <jer.noble@apple.com>
2908
2909         Make a generic CDMPrivateMediaPlayer and move its CDMSession into platform/.
2910         https://bugs.webkit.org/show_bug.cgi?id=129164
2911
2912         Reviewed by Eric Carlson.
2913
2914         Move the session created by CDMPrivateAVFoundation into platform, and rename
2915         CDMPrivateAVFoundation to CDMPrivateMediaPlayer. Future media engines who want
2916         to support a keysystem from within the media engine can create their own
2917         CDMSession as part of the MediaPlayerPrivate interface.
2918
2919         * Modules/encryptedmedia/CDM.cpp:
2920         (WebCore::installedCDMFactories):
2921         (WebCore::CDM::createSession):
2922         * Modules/encryptedmedia/CDM.h:
2923         * Modules/encryptedmedia/CDMPrivate.h:
2924         * Modules/encryptedmedia/MediaKeySession.cpp:
2925         * Modules/encryptedmedia/MediaKeySession.h:
2926         * Modules/encryptedmedia/CDMPrivateAVFoundation.mm: Removed.
2927         * Modules/encryptedmedia/CDMPrivateMediaPlayer.cpp: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.cpp.
2928         (WebCore::CDMPrivateMediaPlayer::supportsKeySystem):
2929         (WebCore::CDMPrivateMediaPlayer::supportsKeySystemAndMimeType):
2930         (WebCore::CDMPrivateMediaPlayer::supportsMIMEType):
2931         (WebCore::CDMPrivateMediaPlayer::createSession):
2932         * Modules/encryptedmedia/CDMPrivateMediaPlayer.h: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.h.
2933         (WebCore::CDMPrivateMediaPlayer::create):
2934         (WebCore::CDMPrivateMediaPlayer::~CDMPrivateMediaPlayer):
2935         (WebCore::CDMPrivateMediaPlayer::cdm):
2936         (WebCore::CDMPrivateMediaPlayer::CDMPrivateMediaPlayer):
2937         * WebCore.xcodeproj/project.pbxproj:
2938         * platform/graphics/CDMSession.h: Extracted from CDMPrivateAVFoundation.h.
2939         (WebCore::CDMSessionClient::~CDMSessionClient):
2940         (WebCore::CDMSession::CDMSession):
2941         (WebCore::CDMSession::~CDMSession):
2942         * platform/graphics/MediaPlayer.cpp:
2943         (WebCore::MediaPlayer::createSession):
2944         * platform/graphics/MediaPlayer.h:
2945         * platform/graphics/MediaPlayerPrivate.h:
2946         (WebCore::MediaPlayerPrivateInterface::createSession):
2947         * platform/graphics/avfoundation/objc/CDMSessionAVFoundationObjC.h: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.h.
2948         (WebCore::CDMSessionAVFoundationObjC::~CDMSessionAVFoundationObjC):
2949         * platform/graphics/avfoundation/objc/CDMSessionAVFoundationObjC.mm: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.mm.
2950         (WebCore::CDMSessionAVFoundationObjC::CDMSessionAVFoundationObjC):
2951         (WebCore::CDMSessionAVFoundationObjC::generateKeyRequest):
2952         (WebCore::CDMSessionAVFoundationObjC::releaseKeys):
2953         (WebCore::CDMSessionAVFoundationObjC::update):
2954         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2955         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2956         (WebCore::MediaPlayerPrivateAVFoundationObjC::createSession):
2957         * testing/MockCDM.cpp:
2958         (WebCore::MockCDMSession::setClient):
2959         (WebCore::MockCDM::createSession):
2960         * testing/MockCDM.h:
2961
2962 2014-02-21  Jer Noble  <jer.noble@apple.com>
2963
2964         Add a supportsKeySystem media engine factory parameter.
2965         https://bugs.webkit.org/show_bug.cgi?id=129161
2966
2967         Reviewed by Eric Carlson.
2968
2969         Add a new parameter to the MediaPlayerFactory to allow registered media
2970         engines to be queried for keySystem support:
2971         * platform/graphics/MediaPlayer.cpp:
2972         (WebCore::MediaPlayerFactory::MediaPlayerFactory):
2973         (WebCore::MediaPlayer::supportsKeySystem):
2974         * platform/graphics/MediaPlayer.h:
2975
2976         Support this new field in MediaPlayerPrivateAVFoundationObjC:
2977         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2978         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2979         (WebCore::MediaPlayerPrivateAVFoundationObjC::registerMediaEngine):
2980         (WebCore::keySystemIsSupported):
2981         (WebCore::MediaPlayerPrivateAVFoundationObjC::supportsKeySystem):
2982         (WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource):
2983
2984         Add an empty field for SupportsKeySystem to the remaining media engines:
2985         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
2986         (WebCore::MediaPlayerPrivateAVFoundationCF::registerMediaEngine):
2987         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
2988         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::registerMediaEngine):
2989         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2990         (WebCore::MediaPlayerPrivateGStreamer::registerMediaEngine):
2991         * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
2992         (WebCore::MediaPlayerPrivateIOS::registerMediaEngine):
2993         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2994         (WebCore::MediaPlayerPrivateQTKit::registerMediaEngine):
2995         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
2996         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::registerMediaEngine):
2997         * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
2998         (WebCore::MockMediaPlayerMediaSource::registerMediaEngine):
2999
3000 2014-02-21  Benjamin Poulain  <bpoulain@apple.com>
3001
3002         Fix WebCore's internals after r164505
3003
3004         * testing/Internals.cpp:
3005         (WebCore::Internals::findEditingDeleteButton): The call became ambiguous after r164505.
3006
3007 2014-02-21  Joseph Pecoraro  <pecoraro@apple.com>
3008
3009         Web Inspector: JSContext inspection should report exceptions in the console
3010         https://bugs.webkit.org/show_bug.cgi?id=128776
3011
3012         Reviewed by Timothy Hatcher.
3013
3014         Include some clean up of ConsoleMessage and ScriptCallStack construction.
3015
3016         Covered by existing tests.
3017
3018         * bindings/js/JSDOMBinding.cpp:
3019         (WebCore::reportException):
3020         Simplify code now that createStackTraceFromException handles it.
3021
3022         * page/ContentSecurityPolicy.cpp:
3023         (WebCore::gatherSecurityPolicyViolationEventData):
3024         (WebCore::ContentSecurityPolicy::reportViolation):
3025         ScriptCallStack can give us the first non-native callframe.
3026
3027         * inspector/InspectorResourceAgent.cpp:
3028         (WebCore::InspectorResourceAgent::buildInitiatorObject):
3029         * inspector/PageDebuggerAgent.cpp:
3030         (WebCore::PageDebuggerAgent::breakpointActionLog):
3031         * inspector/TimelineRecordFactory.cpp:
3032         (WebCore::TimelineRecordFactory::createGenericRecord):
3033         * page/Console.cpp:
3034         (WebCore::internalAddMessage):
3035         (WebCore::Console::profile):
3036         (WebCore::Console::profileEnd):
3037         (WebCore::Console::timeEnd):
3038         * page/ContentSecurityPolicy.cpp:
3039         (WebCore::gatherSecurityPolicyViolationEventData):
3040         (WebCore::ContentSecurityPolicy::reportViolation):
3041         * page/DOMWindow.cpp:
3042         (WebCore::DOMWindow::postMessage):
3043
3044 2014-02-21  Benjamin Poulain  <benjamin@webkit.org>
3045
3046         jsDocumentPrototypeFunctionGetElementById should not create an AtomicString for the function argument
3047         https://bugs.webkit.org/show_bug.cgi?id=128893
3048
3049         Reviewed by Darin Adler.
3050
3051         The declaration of TreeScope::getElementById() was taking an AtomicString as the parameter.
3052         Because of this, all the call sites manipulating String were creating and keeping alive an AtomicString
3053         to make the call.
3054
3055         This had two negative consequences:
3056         -The call sites were ref-ing the ID's atomic string for no reason.
3057         -When there is no ID associated with the input string, an atomic string was created for the sole
3058          purpose of failing the query. Since IDs are stored as AtomicString, if there is not an existing
3059          AtomicString for the input, there is no reason to query anything.
3060
3061         * WebCore.exp.in:
3062         * bindings/js/JSDOMBinding.cpp:
3063         (WebCore::findAtomicString): Update this after the rename.
3064
3065         * bindings/scripts/CodeGeneratorObjC.pm:
3066         (GenerateImplementation):
3067         * bindings/scripts/IDLAttributes.txt:
3068         Now that there are two overloads for TreeScope::getElementById(), the conversion from NSString*
3069         is ambiguous. I add the keyword ObjCExplicitAtomicString to force an explicit conversion to AtomicString.
3070
3071         * dom/Document.idl:
3072         * dom/TreeScope.cpp:
3073         (WebCore::TreeScope::getElementById):
3074         When getting an AtomicString, the case of a empty string is not important, use isNull() instead.
3075         When getting a String, get the corresponding AtomicString if any and use that for getting the element.
3076
3077         * dom/TreeScope.h:
3078         * html/FTPDirectoryDocument.cpp:
3079         (WebCore::FTPDirectoryDocumentParser::loadDocumentTemplate):
3080         Solve the ambiguous call.
3081
3082         * svg/SVGAElement.cpp:
3083         (WebCore::SVGAElement::defaultEventHandler):
3084         This is a wonderful candidate for substringSharingImpl. The substring does not survive the call since
3085         the new getElementById never create any AtomicString.
3086
3087         * svg/SVGSVGElement.cpp:
3088         (WebCore::SVGSVGElement::getElementById):
3089         It looks like there are opportunities to get faster here, Ryosuke should have a look.
3090
3091         * svg/SVGSVGElement.h:
3092         * xml/XMLTreeViewer.cpp:
3093         (WebCore::XMLTreeViewer::transformDocumentToTreeView):
3094         Unrelated cleanup: noStyleMessage was useless.
3095
3096 2014-02-21  Daniel Bates  <dabates@apple.com>
3097
3098         COL element in table has 0 for offsetWidth
3099         https://bugs.webkit.org/show_bug.cgi?id=15277
3100
3101         Reviewed by David Hyatt.
3102
3103         Implements offset{Left, Top, Width, Height} for table columns and column groups
3104         per section Extensions to the HTMLElement Interface of the CSSOM View spec,
3105         <http://www.w3.org/TR/cssom-view/#extensions-to-the-htmlelement-interface> (Draft 17 December 2013).
3106
3107         For now, we fail almost all of the offset{Height, Top} sub-tests in the included test
3108         for the separate border model as we need to fix <https://bugs.webkit.org/show_bug.cgi?id=128988>.
3109
3110         Test: fast/table/col-and-colgroup-offsets.html
3111
3112         * rendering/RenderTable.cpp:
3113         (WebCore::RenderTable::RenderTable): Initialize cached column offset top and offset height.
3114         We cache these offsets since they are the same for all columns in the table.
3115         (WebCore::RenderTable::invalidateCachedColumns): Clear cached effective column index map.
3116         (WebCore::RenderTable::invalidateCachedColumnOffsets): Added.
3117         (WebCore::RenderTable::layout): Invalidate cached column offsets as the location or height
3118         of one or more sections may have changed.
3119         (WebCore::RenderTable::updateColumnCache): Modified to build effective column index map.
3120         (WebCore::RenderTable::effectiveIndexOfColumn): Added.
3121         (WebCore::RenderTable::offsetTopForColumn): Added.
3122         (WebCore::RenderTable::offsetLeftForColumn): Added.
3123         (WebCore::RenderTable::offsetWidthForColumn): Added.
3124         (WebCore::RenderTable::offsetHeightForColumn): Added.
3125         * rendering/RenderTable.h: Make isTableColumnGroupWithColumnChildren() const.
3126         * rendering/RenderTableCol.cpp:
3127         (WebCore::RenderTableCol::offsetLeft): Added; turns around and calls RenderTable::offsetLeftForColumn().
3128         (WebCore::RenderTableCol::offsetTop): Added; turns around and calls RenderTable::offsetTopForColumn().
3129         (WebCore::RenderTableCol::offsetWidth): Added; turns around and calls RenderTable::offsetWidthForColumn().
3130         (WebCore::RenderTableCol::offsetHeight): Added; turns around and calls RenderTable::offsetHeightForColumn().
3131         * rendering/RenderTableCol.h:
3132
3133 2014-02-21  Enrica Casucci  <enrica@apple.com>
3134
3135         Build fix for iOS after r164498.
3136
3137         Unreviewed.
3138
3139         * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
3140         (WebCore::MediaPlayerPrivateIOS::buffered):
3141
3142 2014-02-21  Ryosuke Niwa  <rniwa@webkit.org>
3143
3144         Disallow the use of -webkit-user-modify on shadow pseudo elements
3145         https://bugs.webkit.org/show_bug.cgi?id=129144
3146
3147         Reviewed by Geoffrey Garen.
3148
3149         Completely disallow -webkit-user-modify on user agent (builtin) pseudo elements.
3150
3151         We've already had rules to do this in html.css but just hard code it into the engine
3152         in order to eliminate the all uses of -webkit-user-modify in html.css.
3153
3154         * css/StyleResolver.cpp:
3155         (WebCore::StyleResolver::adjustRenderStyle):
3156         * css/html.css:
3157         (input::-webkit-textfield-decoration-container):
3158         (input::-webkit-clear-button):
3159         (input[type="search"]::-webkit-search-cancel-button):
3160         (input[type="search"]::-webkit-search-decoration):
3161         (input[type="search"]::-webkit-search-results-decoration):
3162         (input[type="search"]::-webkit-search-results-button):
3163         (input::-webkit-inner-spin-button):
3164         (input::-webkit-input-speech-button):
3165         (input::-webkit-input-placeholder, isindex::-webkit-input-placeholder):
3166         (input[type="file"]::-webkit-file-upload-button):
3167         (input[type="range"]::-webkit-slider-container, input[type="range"]::-webkit-media-slider-container):
3168         (input[type="range"]::-webkit-slider-runnable-track):
3169         (input[type="range"]::-webkit-slider-thumb, input[type="range"]::-webkit-media-slider-thumb):
3170         (input[type="color"]::-webkit-color-swatch-wrapper):
3171         (input[type="color"]::-webkit-color-swatch):
3172         (::-webkit-validation-bubble):
3173         (::-webkit-validation-bubble-message):
3174         (::-webkit-validation-bubble-text-block):
3175         (::-webkit-validation-bubble-heading):
3176         (::-webkit-validation-bubble-arrow):
3177         (::-webkit-validation-bubble-arrow-clipper):
3178         (meter::-webkit-meter-inner-element):
3179         (meter::-webkit-meter-bar):
3180         (meter::-webkit-meter-optimum-value):
3181         (meter::-webkit-meter-suboptimum-value):
3182         (meter::-webkit-meter-even-less-good-value):
3183         (progress::-webkit-progress-inner-element):
3184         (progress::-webkit-progress-bar):
3185         (progress::-webkit-progress-value):
3186
3187 2014-02-21  Eric Carlson  <eric.carlson@apple.com>
3188
3189         Fix TimeRanges layering violations
3190         https://bugs.webkit.org/show_bug.cgi?id=128717
3191
3192         Reviewed by Jer Noble.
3193
3194         No new tests, no functionality changed.
3195
3196         * CMakeLists.txt:
3197         * GNUmakefile.list.am: Add PlatformTimeRanges.
3198
3199         * Modules/mediasource/MediaSource.cpp:
3200         (WebCore::MediaSource::buffered): TimeRanges -> PlatformTimeRanges.
3201         * Modules/mediasource/MediaSource.h:
3202
3203         * Modules/mediasource/SourceBuffer.cpp:
3204         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): TimeRanges* -> TimeRanges&.
3205
3206         * WebCore.exp.in: Update for signature changes.
3207
3208         * WebCore.vcxproj/WebCore.vcxproj:
3209         * WebCore.vcxproj/WebCore.vcxproj.filters:
3210         * WebCore.xcodeproj/project.pbxproj: Add PlatformTimeRanges.
3211
3212         * html/HTMLMediaElement.cpp:
3213         (WebCore::HTMLMediaElement::percentLoaded): Create TimeRanges from PlatformTimeRanges.
3214         (WebCore::HTMLMediaElement::buffered): Ditto.
3215         (WebCore::HTMLMediaElement::seekable): Ditto.
3216
3217         * html/MediaController.cpp:
3218         (MediaController::buffered): TimeRanges* -> TimeRanges&.
3219         (MediaController::seekable): Ditto.
3220         (MediaController::played): Ditto.
3221
3222         Move all of the logic into PlatformTimeRanges. Change API to take TimeRanges& instead of TimeRanges*.
3223         * html/TimeRanges.cpp:
3224         (WebCore::TimeRanges::create): Move to .cpp from .h.
3225         (WebCore::TimeRanges::TimeRanges): Initialize the PlatformTimeRanges member variable.
3226         (WebCore::TimeRanges::start): Passthrough to PlatformTimeRanges.
3227         (WebCore::TimeRanges::end): Ditto.
3228         (WebCore::TimeRanges::invert): Ditto.
3229         (WebCore::TimeRanges::copy): Ditto.
3230         (WebCore::TimeRanges::intersectWith): Ditto.
3231         (WebCore::TimeRanges::unionWith): Ditto.
3232         (WebCore::TimeRanges::length): Ditto.
3233         (WebCore::TimeRanges::add): Ditto.
3234         (WebCore::TimeRanges::contain): Ditto.
3235         (WebCore::TimeRanges::find): Ditto.
3236         (WebCore::TimeRanges::nearest): Ditto.
3237         (WebCore::TimeRanges::totalDuration): Ditto.
3238         * html/TimeRanges.h:
3239
3240         * platform/graphics/MediaPlayer.cpp:
3241         (WebCore::NullMediaPlayerPrivate::buffered): TimeRanges -> PlatformTimeRanges.
3242         (WebCore::MediaPlayer::buffered): Ditto.
3243         (WebCore::MediaPlayer::seekable): Ditto.
3244         * platform/graphics/MediaPlayer.h:
3245         * platform/graphics/MediaPlayerPrivate.h:
3246
3247         * platform/graphics/MediaSourcePrivateClient.h:
3248
3249         * platform/graphics/PlatformTimeRanges.cpp: Added.
3250         * platform/graphics/PlatformTimeRanges.h: Added.
3251
3252         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
3253         (WebCore::MediaPlayerPrivateAVFoundation::buffered): TimeRanges -> PlatformTimeRanges.
3254         (WebCore::MediaPlayerPrivateAVFoundation::loadedTimeRangesChanged): Drive-by fix to log
3255             FunctionType notifications. ASSERT when passed an unknown notification.
3256
3257         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
3258         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3259         (WebCore::MediaPlayerPrivateAVFoundationCF::platformBufferedTimeRanges):  TimeRanges -> PlatformTimeRanges.
3260         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
3261         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
3262         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3263         (WebCore::MediaPlayerPrivateAVFoundationObjC::currentTime): Ditto.
3264         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformBufferedTimeRanges): Ditto.
3265
3266         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
3267         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
3268         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekable): Ditto.
3269         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered): Ditto.
3270
3271         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3272         (WebCore::MediaPlayerPrivateGStreamer::buffered): Ditto.
3273         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
3274
3275         * platform/graphics/ios/MediaPlayerPrivateIOS.h:
3276         * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
3277         (WebCore::MediaPlayerPrivateIOS::buffered): Ditto.
3278
3279         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3280         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3281         (WebCore::MediaPlayerPrivateQTKit::buffered): Ditto.
3282
3283         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
3284         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::buffered): Ditto.
3285         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
3286
3287         * platform/graphics/wince/MediaPlayerPrivateWinCE.h:
3288
3289         * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
3290         (WebCore::MockMediaPlayerMediaSource::buffered): Ditto.
3291         (WebCore::MockMediaPlayerMediaSource::advanceCurrentTime): Ditto.
3292         * platform/mock/mediasource/MockMediaPlayerMediaSource.h:
3293
3294 2014-02-21  Enrica Casucci  <enrica@apple.com>
3295
3296         Support WebSelections in WK2 on iOS.
3297         https://bugs.webkit.org/show_bug.cgi?id=127015
3298         <rdar://problem/15211964>
3299
3300         Reviewed by Benjamin Poulain.
3301
3302         Adding some exports.
3303
3304         * WebCore.exp.in:
3305
3306 2014-02-21  Benjamin Poulain  <bpoulain@apple.com>
3307
3308         'mouseenter' mouse compat event not fired when listeners for touch events
3309         https://bugs.webkit.org/show_bug.cgi?id=128534
3310
3311         Reviewed by Andreas Kling.
3312
3313         The code dispatching mouseenter and mouseleave events was making the assumption that
3314         only mouse move would cause Document::updateHoverActiveState.
3315
3316         This is not true in some cases. In the case of this bug, the first touch handler sets
3317         the hover state. From there, the code handling enter/leave is in an inconsistent state.
3318
3319         This patch changes the delivery of mouse enter/leave events to be done through the regular
3320         processing of mouse events. The update is done with the mouseover and mouseout events.
3321
3322         * dom/Document.cpp:
3323         (WebCore::Document::prepareMouseEvent):
3324         (WebCore::Document::updateHoverActiveState):
3325         * dom/Document.h:
3326         * page/EventHandler.cpp:
3327         (WebCore::nearestCommonHoverAncestor):
3328         (WebCore::hierarchyHasCapturingEventListeners):
3329         (WebCore::EventHandler::updateMouseEventTargetNode):
3330
3331 2014-02-21  Jon Honeycutt  <jhoneycutt@apple.com>
3332
3333         Crash reloading page with position: fixed content
3334         https://bugs.webkit.org/show_bug.cgi?id=129119
3335         <rdar://problem/16127090>
3336
3337         Reviewed by Brent Fulgham.
3338
3339         Test: platform/mac-wk2/tiled-drawing/crash-reloading-with-position-fixed-content.html
3340
3341         * page/scrolling/ScrollingTree.cpp:
3342         (WebCore::ScrollingTree::removeDestroyedNodes):
3343         Check the node's ID against the latched node's ID before the node is
3344         removed from the tree.
3345
3346 2014-02-21  Joseph Pecoraro  <pecoraro@apple.com>
3347
3348         Revert r164486, causing a number of test failures.
3349
3350         Unreviewed rollout.
3351
3352 2014-02-21  David Kilzer  <ddkilzer@apple.com>
3353
3354         StyleResolver::loadPendingImage() should take a reference to StylePendingImage
3355         <http://webkit.org/b/129021>
3356
3357         Reviewed by Brent Fulgham.
3358
3359         * css/StyleResolver.cpp:
3360         (WebCore::StyleResolver::loadPendingImage): Change pendingImage
3361         parameter to a reference.
3362         (WebCore::StyleResolver::loadPendingShapeImage): Update to use
3363         references.
3364         (WebCore::StyleResolver::loadPendingImages): Ditto.
3365         * css/StyleResolver.h:
3366         (WebCore::StyleResolver::loadPendingImage): Change pendingImage
3367         parameter to a reference.
3368
3369 2014-02-21  Joseph Pecoraro  <pecoraro@apple.com>
3370
3371         Web Inspector: JSContext inspection should report exceptions in the console
3372         https://bugs.webkit.org/show_bug.cgi?id=128776
3373
3374         Reviewed by Timothy Hatcher.
3375
3376         Include some clean up of ConsoleMessage and ScriptCallStack construction.
3377
3378         Covered by existing tests.
3379
3380         * bindings/js/JSDOMBinding.cpp:
3381         (WebCore::reportException):
3382         Simplify code now that createStackTraceFromException handles it.
3383
3384         * page/ContentSecurityPolicy.cpp:
3385         (WebCore::gatherSecurityPolicyViolationEventData):
3386         (WebCore::ContentSecurityPolicy::reportViolation):
3387         ScriptCallStack can give us the first non-native callframe.
3388
3389         * inspector/InspectorResourceAgent.cpp:
3390         (WebCore::InspectorResourceAgent::buildInitiatorObject):
3391         * inspector/PageDebuggerAgent.cpp:
3392         (WebCore::PageDebuggerAgent::breakpointActionLog):
3393         * inspector/TimelineRecordFactory.cpp:
3394         (WebCore::TimelineRecordFactory::createGenericRecord):
3395         * page/Console.cpp:
3396         (WebCore::internalAddMessage):
3397         (WebCore::Console::profile):
3398         (WebCore::Console::profileEnd):
3399         (WebCore::Console::timeEnd):
3400         * page/ContentSecurityPolicy.cpp:
3401         (WebCore::gatherSecurityPolicyViolationEventData):
3402         (WebCore::ContentSecurityPolicy::reportViolation):
3403         * page/DOMWindow.cpp:
3404         (WebCore::DOMWindow::postMessage):
3405
3406 2014-02-21  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
3407
3408         Fixing the !ENABLE(SVG_FONTS) build
3409         https://bugs.webkit.org/show_bug.cgi?id=129150
3410
3411         Reviewed by Anders Carlsson.
3412
3413         No new tests required.
3414
3415         * svg/SVGAltGlyphElement.cpp:
3416         * svg/SVGAltGlyphElement.h:
3417         * svg/svgtags.in:
3418
3419 2014-02-21  Radu Stavila  <stavila@adobe.com>
3420
3421         [CSS Regions] Use the named-flow-specific object RenderNamedFlowFragment instead of the generic RenderRegion whenever possible
3422         https://bugs.webkit.org/show_bug.cgi?id=128599
3423
3424         Reviewed by Andrei Bucur.
3425
3426         Use the named flow specific RenderNamedFlowFragment instead of the generic RenderRegion, whenever possible.
3427         Move named flow specific methods from RenderRegion to RenderNamedFlowFragment.
3428
3429         No new tests required.
3430
3431         * dom/Element.cpp:
3432         (WebCore::Element::renderNamedFlowFragment):
3433         (WebCore::Element::webkitRegionOverset):
3434         (WebCore::Element::webkitGetRegionFlowRanges):
3435         * dom/Element.h:
3436         * inspector/InspectorCSSAgent.cpp:
3437         (WebCore::InspectorCSSAgent::buildArrayForRegions):
3438         * rendering/PaintInfo.h:
3439         (WebCore::PaintInfo::PaintInfo):
3440         * rendering/RenderBlock.cpp:
3441         (WebCore::RenderBlock::paint):
3442         (WebCore::RenderBlock::paintObject):
3443         * rendering/RenderBox.cpp:
3444         (WebCore::RenderBox::paintBoxDecorations):
3445         (WebCore::RenderBox::pushContentsClip):
3446         (WebCore::RenderBox::layoutOverflowRectForPropagation):
3447         * rendering/RenderBox.h:
3448         * rendering/RenderBoxModelObject.cpp:
3449         (WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
3450         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
3451         * rendering/RenderBoxModelObject.h:
3452         * rendering/RenderInline.h:
3453         * rendering/RenderLayer.cpp:
3454         (WebCore::RenderLayer::paint):
3455         (WebCore::RenderLayer::paintLayer):
3456         (WebCore::RenderLayer::paintLayerContents):
3457         (WebCore::RenderLayer::paintLayerByApplyingTransform):
3458         (WebCore::RenderLayer::updatePaintingInfoForFragments):
3459         (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
3460         (WebCore::RenderLayer::paintBackgroundForFragments):
3461         (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
3462         (WebCore::RenderLayer::paintOutlineForFragments):
3463         (WebCore::RenderLayer::paintMaskForFragments):
3464         (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
3465         (WebCore::RenderLayer::calculateClipRects):
3466         * rendering/RenderLayer.h:
3467         * rendering/RenderNamedFlowFragment.cpp:
3468         (WebCore::RenderNamedFlowFragment::getRanges):
3469         * rendering/RenderNamedFlowFragment.h:
3470         * rendering/RenderNamedFlowThread.cpp:
3471         (WebCore::RenderNamedFlowThread::updateWritingMode):
3472         (WebCore::compareRenderNamedFlowFragments):
3473         (WebCore::addFragmentToList):
3474         (WebCore::RenderNamedFlowThread::addFragmentToNamedFlowThread):
3475         (WebCore::RenderNamedFlowThread::addRegionToThread):
3476         (WebCore::RenderNamedFlowThread::removeRegionFromThread):
3477         (WebCore::RenderNamedFlowThread::computeOversetStateForRegions):
3478         (WebCore::RenderNamedFlowThread::checkInvalidRegions):
3479         (WebCore::RenderNamedFlowThread::getRanges):
3480         (WebCore::RenderNamedFlowThread::checkRegionsWithStyling):
3481         (WebCore::RenderNamedFlowThread::clearRenderObjectCustomStyle):
3482         * rendering/RenderNamedFlowThread.h:
3483         * rendering/RenderRegion.cpp:
3484         * rendering/RenderRegion.h:
3485         * rendering/RenderReplaced.cpp:
3486         (WebCore::RenderReplaced::shouldPaint):
3487         * rendering/RenderReplica.cpp:
3488         (WebCore::RenderReplica::paint):
3489         * rendering/RootInlineBox.cpp:
3490         (WebCore::RootInlineBox::paint):
3491         * rendering/svg/RenderSVGRoot.cpp:
3492         (WebCore::RenderSVGRoot::paintReplaced):
3493
3494 2014-02-21  Andrei Bucur  <abucur@adobe.com>
3495
3496         [CSS Regions] Regions don't paint correctly in new-multicol elements
3497         https://bugs.webkit.org/show_bug.cgi?id=120711
3498
3499         Reviewed by David Hyatt.
3500
3501         This patch implements basic support for regions inside multi-column elements.
3502         Currently, the painting and hit-testing logic of CSS Regions is not aware of
3503         enclosing multi-column elements. The change is integrated at a layer level by
3504         making use of the pre-computed layer fragments during the painting and hit-testing
3505         phases for regions.
3506
3507         There are limitations such that self painting layers found inside the named flow
3508         thread layer will not be correctly processed because they don't go through the
3509         layer fragment collection step. This is not trivial to implement because the enclosing
3510         pagination layer provided by the multi-column element is not visibile from inside
3511         the named flow thread layer and they reside in different coordinate systems.
3512
3513         A side effect of this patch is the fix of regions incorrect clipping in certain
3514         cases (when both a region and its container clip their overflow, the region's
3515         content is visible outside the container).
3516
3517         Tests: fast/regions/region-clipping.html
3518                fast/regions/regions-in-multicol-bt.html
3519                fast/regions/regions-in-multicol-hover-overflow.html
3520                fast/regions/regions-in-multicol-hover.html
3521                fast/regions/regions-in-multicol-lr.html
3522                fast/regions/regions-in-multicol-rl.html
3523                fast/regions/regions-in-multicol.html
3524
3525         * rendering/RenderLayer.cpp:
3526         (WebCore::RenderLayer::paintLayerContents):
3527         (WebCore::RenderLayer::hitTestLayer):
3528         (WebCore::RenderLayer::paintFlowThreadIfRegionForFragments):
3529         (WebCore::RenderLayer::hitTestFlowThreadIfRegionForFragments):
3530         * rendering/RenderLayer.h:
3531
3532 2014-02-21  Mihai Tica  <mitica@adobe.com>
3533
3534         [CSS Blending] Refactor -webkit-blend-mode to -webkit-mix-blend-mode
3535         https://bugs.webkit.org/show_bug.cgi?id=128805
3536
3537         Reviewed by Dean Jackson.
3538
3539         The spec defines the mix-blend-mode property. This means that the
3540         prefixed version should be -webkit-mix-blend-mode, instead of
3541         -webkit-blend-mode.
3542
3543         * css/CSSComputedStyleDeclaration.cpp:
3544         (WebCore::ComputedStyleExtractor::propertyValue):
3545         * css/CSSParser.cpp:
3546         (WebCore::isValidKeywordPropertyAndValue):
3547         (WebCore::isKeywordPropertyID):
3548         (WebCore::CSSParser::parseValue):
3549         * css/CSSPropertyNames.in:
3550         * css/DeprecatedStyleBuilder.cpp:
3551         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
3552
3553 2014-02-21  Ryosuke Niwa  <rniwa@webkit.org>
3554
3555         Bindings tests rebaseline after r164473.
3556
3557         * bindings/scripts/test/ObjC/DOMTestObj.mm:
3558         (-[DOMTestObj mutablePoint]):
3559         (-[DOMTestObj immutablePoint]):
3560         (-[DOMTestObj mutablePointFunction]):
3561         (-[DOMTestObj immutablePointFunction]):
3562         * bindings/scripts/test/ObjC/DOMTestTypedefs.mm:
3563         (-[DOMTestTypedefs immutablePointFunction]):
3564
3565 2014-02-21  Tim Horton  <timothy_horton@apple.com>
3566
3567         Remove removed symbol from exports list.
3568
3569         * WebCore.exp.in:
3570
3571 2014-02-20  ChangSeok Oh  <changseok.oh@collabora.com>
3572
3573         Rename EXT_draw_buffers to WEBGL_draw_buffers
3574         https://bugs.webkit.org/show_bug.cgi?id=128894
3575
3576         Reviewed by Dean Jackson.
3577
3578         I noticed the related spec has changed. Accordingly chromium also changed its implementation
3579         to meet the spec. So here I'd like to apply it to webkit as well.
3580
3581         Merged from Blink (patch by bajones):
3582         https://src.chromium.org/viewvc/blink?revision=152065&view=revision
3583
3584         Test: fast/canvas/webgl/webgl-draw-buffers.html
3585
3586         * CMakeLists.txt:
3587         * DerivedSources.cpp:
3588         * DerivedSources.make:
3589         * GNUmakefile.list.am:
3590         * WebCore.vcxproj/WebCore.vcxproj:
3591         * WebCore.vcxproj/WebCore.vcxproj.filters:
3592         * WebCore.xcodeproj/project.pbxproj:
3593         * bindings/js/JSWebGLRenderingContextCustom.cpp:
3594         (WebCore::toJS):
3595         * html/canvas/EXTDrawBuffers.idl: Removed.
3596         * html/canvas/WebGLDrawBuffers.cpp: Renamed from Source/WebCore/html/canvas/EXTDrawBuffers.cpp.
3597         (WebCore::WebGLDrawBuffers::WebGLDrawBuffers):
3598         (WebCore::WebGLDrawBuffers::~WebGLDrawBuffers):
3599         (WebCore::WebGLDrawBuffers::getName):
3600         (WebCore::WebGLDrawBuffers::create):
3601         (WebCore::WebGLDrawBuffers::supported):
3602         (WebCore::WebGLDrawBuffers::drawBuffersWEBGL):
3603         (WebCore::WebGLDrawBuffers::satisfiesWebGLRequirements):
3604         * html/canvas/WebGLDrawBuffers.h: Renamed from Source/WebCore/html/canvas/EXTDrawBuffers.h.
3605         * html/canvas/WebGLDrawBuffers.idl: Added.
3606         * html/canvas/WebGLExtension.h:
3607         * html/canvas/WebGLFramebuffer.cpp:
3608         (WebCore::WebGLFramebuffer::drawBuffersIfNecessary):
3609         * html/canvas/WebGLRenderingContext.cpp:
3610         (WebCore::WebGLRenderingContext::getExtension):
3611         (WebCore::WebGLRenderingContext::getParameter):
3612         (WebCore::WebGLRenderingContext::getSupportedExtensions):
3613         (WebCore::WebGLRenderingContext::validateFramebufferFuncParameters):
3614         (WebCore::WebGLRenderingContext::supportsDrawBuffers):
3615         * html/canvas/WebGLRenderingContext.h:
3616
3617 2014-02-20  Ryosuke Niwa  <rniwa@webkit.org>
3618
3619         m_ancestorDisabledState should never be unknown
3620         https://bugs.webkit.org/show_bug.cgi?id=129084
3621
3622         Reviewed by Benjamin Poulain.
3623
3624         In order to resolve the bug 129035, a text form control elements needs to synchronously change
3625         its inner text element's editability by setting or unsetting contenteditable content attribute.
3626         Before this patch, we could not do this because editability of a text form control dependent on
3627         its disabled-ness which was only computed lazily via updateAncestorDisabledState().
3628
3629         This patch makes HTMLFieldSetElement and HTMLFormControlElement update this state synchronously.
3630         To avoid O(k) DOM traversal, where k is the depth of the tree, in insertedInto and removedFrom of
3631         HTMLFormControlElement on most pages, a new document-level flag, m_disabledFieldsetElementsCount,
3632         has been added to indicate whether the document contains any disabled fieldset or not.
3633
3634         Also renamed the misleadingly named disabledAttributeChanged to disabledStateChanged, and added
3635         new function of the same name (disabledAttributeChanged) to be used by HTMLFieldSetElement
3636         for keeping the document-level flag up-to-date upon disabled attribute changes.
3637
3638         Tests: fast/forms/fieldset/fieldset-disabled-2.html
3639
3640         * dom/Document.cpp:
3641         (WebCore::Document::Document): Initializes newly added m_disabledFieldsetElementsCount.
3642         (WebCore::Document::~Document): Assert that we've done house keeping right.
3643         * dom/Document.h:
3644         (WebCore::Document::hasDisabledFieldsetElement): Added.
3645         (WebCore::Document::addDisabledFieldsetElement): Added.
3646         (WebCore::Document::removeDisabledFieldsetElement): Added.
3647
3648         * html/HTMLFieldSetElement.cpp:
3649         (WebCore::HTMLFieldSetElement::~HTMLFieldSetElement): Removes itself from the owner document.
3650
3651         (WebCore::updateFromControlElementsAncestorDisabledStateUnder): Added. Updates startNode and
3652         its descendants' ancestor disabled flag. We don't update controls under another disabled
3653         fieldset element since disabled-ness of those controls aren't affected by startNode.
3654
3655         (WebCore::HTMLFieldSetElement::disabledAttributeChanged): Call addDisabledFieldsetElement and
3656         removeDisabledFieldsetElement to update the owner document's flag.
3657
3658         (WebCore::HTMLFieldSetElement::disabledStateChanged): Renamed from disabledAttributeChanged. 
3659         Enable form control elements under the first legend element and disable or enable other
3660         descendent form controls in accordance with the presence of disabled content attribute.
3661
3662         (WebCore::HTMLFieldSetElement::childrenChanged): Update disabled-ness of form controls under
3663         child legend elements because controls aren't disabled in the first legend element, and adding
3664         or removing child elements may have changed the first legend element.
3665
3666         (WebCore::HTMLFieldSetElement::didMoveToNewDocument): Update the flag on the owner document.
3667         * html/HTMLFieldSetElement.h:
3668
3669         * html/HTMLFormControlElement.cpp:
3670         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
3671         (WebCore::HTMLFormControlElement::computeIsDisabledByFieldsetAncestor): Returns boolean instead of
3672         updating m_ancestorDisabledState internally. Also renamed from updateAncestorDisabledState.
3673
3674         (WebCore::HTMLFormControlElement::setAncestorDisabled): Replaced ancestorDisabledStateWasChanged.
3675         This function updates m_disabledByAncestorFieldset and calls disabledAttributeChanged as needed.
3676
3677         (WebCore::HTMLFormControlElement::disabledAttributeChanged): Added. Calls disabledStateChanged.
3678         (WebCore::HTMLFormControlElement::disabledStateChanged): Renamed from disabledAttributeChanged.
3679
3680         (WebCore::HTMLFormControlElement::insertedInto): Update m_disabledByAncestorFieldset if there is
3681         a possibility (i.e. the document contains any disabled fieldset element) that this form control
3682         is inserted under a disabled fieldset element.
3683
3684         (WebCore::HTMLFormControlElement::removedFrom): If this form control element is not disabled by
3685         a fieldset ancestor, then there is nothing to do. If it is, then check to see if the element is
3686         still disabled now that we've lost some ancestors.
3687
3688         (WebCore::HTMLFormControlElement::isDisabledFormControl): No longer updates m_ancestorDisabledState
3689         lazily since m_disabledByAncestorFieldset is never ambiguous now.
3690
3691         * html/HTMLFormControlElement.h:
3692         (WebCore::HTMLFormControlElement::disabledByAncestorFieldset): Added.
3693
3694 2014-02-20  Zalan Bujtas  <zalan@apple.com>
3695
3696         Remove redundant deviceScaleFactor() functions and make callers use Document::deviceScaleFactor() when accessible.
3697         https://bugs.webkit.org/show_bug.cgi?id=129137
3698
3699         Reviewed by Simon Fraser.
3700
3701         No change in behavior.
3702
3703         * editing/DeleteButtonController.cpp:
3704         (WebCore::DeleteButtonController::createDeletionUI):
3705         * page/Page.cpp:
3706         * page/Page.h:
3707         * platform/graphics/GraphicsContext.cpp:
3708         (WebCore::GraphicsContext::GraphicsContext):
3709         * platform/graphics/GraphicsContext.h:
3710         * platform/graphics/cg/GraphicsContextCG.cpp:
3711         (WebCore::GraphicsContext::platformInit):
3712         * rendering/RenderBoxModelObject.cpp:
3713         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
3714         (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
3715         * rendering/RenderImage.cpp:
3716         (WebCore::RenderImage::imageSizeForError):
3717         (WebCore::RenderImage::paintReplaced):
3718         * rendering/RenderLayer.cpp:
3719         (WebCore::RenderLayer::drawPlatformResizerImage):
3720         * rendering/RenderObject.cpp:
3721         (WebCore::RenderObject::drawLineForBoxSide):
3722         * rendering/RenderThemeMac.mm:
3723         (WebCore::RenderThemeMac::paintProgressBar):
3724         * rendering/svg/SVGRenderingContext.cpp:
3725         (WebCore::SVGRenderingContext::calculateTransformationToOutermostCoordinateSystem):
3726
3727 2014-02-20  David Kilzer  <ddkilzer@apple.com>
3728
3729         Stop generating Objective-C bindings for the SVG DOM
3730         <http://webkit.org/b/129107>
3731
3732         Reviewed by Timothy Hatcher.
3733
3734         Bug 114076 stopped compiling the Objective-C bindings for the
3735         SVG DOM, but we continued to generate the header and source
3736         files after that landed in r147822.  This patch also stops
3737         generating the unused header and source files.
3738
3739         * DerivedSources.make:
3740         - Split BINDING_IDLS into NON_SVG_BINDING_IDLS and
3741           SVG_BINDING_IDLS so that they may operated on separately.
3742         - Define BINDING_IDLS again as the full list of IDL files.
3743         - Rename DOM_CLASSES to JS_DOM_CLASSES so that JavaScript
3744           bindings are still generated for all IDL files.
3745         - Add OBJC_DOM_CLASSES so that Objective-C bindings are only
3746           generated for non-SVG IDL files.
3747
3748         * bindings/scripts/CodeGeneratorObjC.pm:
3749         (GetBaseClass):
3750         (GetPropertyAttributes):
3751         (AddIncludesForType):
3752         (GenerateHeader):
3753         (GenerateImplementation):
3754         - Remove support for SVG classes.
3755
3756 2014-02-20  Simon Fraser  <simon.fraser@apple.com>
3757
3758         RenderBox::updateShapeOutsideInfoAfterStyleChange shows up on profiles
3759         https://bugs.webkit.org/show_bug.cgi?id=129075
3760
3761         Reviewed by Dean Jackson.
3762
3763         updateShapeOutsideInfoAfterStyleChange() showed up on profiles in content
3764         with no shapes. Avoid calling this if no style has shapeOutside().
3765
3766         * rendering/RenderBox.cpp:
3767         (WebCore::RenderBox::styleDidChange):
3768
3769 2014-02-20  ChangSeok Oh  <changseok.oh@collabora.com>
3770
3771         Remove unused chromium stuff in Extensions3D
3772         https://bugs.webkit.org/show_bug.cgi?id=129086
3773
3774         Reviewed by Anders Carlsson.
3775
3776         Remove GL_CHROMIUM_copy_texture and GL_CHROMIUM_flipy interfaces since they are used nowhere.
3777
3778         No new tests since no functionality changed.
3779
3780         * platform/graphics/Extensions3D.h:
3781         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
3782         * platform/graphics/opengl/Extensions3DOpenGL.h:
3783         * platform/graphics/opengl/Extensions3DOpenGLES.cpp:
3784         * platform/graphics/opengl/Extensions3DOpenGLES.h:
3785
3786 2014-02-20  Joseph Pecoraro  <pecoraro@apple.com>
3787
3788         [iOS] Assert / crash trying to draw empty checked input
3789         https://bugs.webkit.org/show_bug.cgi?id=129138
3790
3791         Reviewed by Simon Fraser.
3792
3793         Test: fast/forms/checkbox-empty-size.html
3794
3795         * rendering/RenderThemeIOS.mm:
3796         (WebCore::shortened):
3797         Avoid a divide by 0, but checking for the condition upfront.
3798
3799 2014-02-20  Benjamin Poulain  <bpoulain@apple.com>
3800
3801         Start fixing the view states driven by the WKScrollView
3802         https://bugs.webkit.org/show_bug.cgi?id=129140
3803
3804         Reviewed by Tim Horton and Simon Fraser.
3805
3806         * platform/graphics/ca/mac/TileController.mm:
3807         (WebCore::TileController::scaledExposedRect):
3808         That comment was more confusing than helping. FrameView-relative coordinates should not need
3809         scaling.
3810
3811 2014-02-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3812
3813         Start to use std::unique_ptr for DragImageLoader
3814         https://bugs.webkit.org/show_bug.cgi?id=129078
3815
3816         Reviewed by Ryosuke Niwa.
3817
3818         As a step to use std::unique_ptr, this patch replace uses of OwnPtr and PassOwnPtr
3819         in the DragImageLoader class with std::unique_ptr. Besides DragImageLoader is set to
3820         non-copyable class.
3821
3822         * dom/Clipboard.cpp:
3823         (WebCore::Clipboard::setDragImage):
3824         * dom/Clipboard.h:
3825
3826 2014-02-20  Brady Eidson  <beidson@apple.com>
3827
3828         Move the image controls setting to Settings.in
3829         https://bugs.webkit.org/show_bug.cgi?id=129126
3830
3831         Reviewed by Tim Horton.
3832
3833         * page/Settings.cpp:
3834         (WebCore::Settings::Settings):
3835         * page/Settings.h:
3836         * page/Settings.in:
3837
3838 2014-02-20  Brady Eidson  <beidson@apple.com>
3839
3840         Add very basic image control rendering
3841         https://bugs.webkit.org/show_bug.cgi?id=129080
3842
3843         Reviewed by Tim Horton.
3844
3845         Test: fast/images/image-controls-basic.html
3846
3847         This patch is groundwork that adds a very basic image control that can render on top of images.
3848
3849         * dom/Node.h:
3850         (WebCore::Node:: isImageControlsRootElement): Returns false, unless you are an ImageControls object.
3851         * html/HTMLAttributeNames.in:
3852
3853         Teach HTMLImageElement how to understand an experimental attribute to install controls,
3854         how to actually build the DOM to attach to the shadow root, how to tear that DOM down,
3855         and how to make sure that Renderers are created for that DOM:
3856         * html/HTMLImageElement.cpp:
3857         (WebCore::HTMLImageElement::HTMLImageElement):
3858         (WebCore::HTMLImageElement::parseAttribute):
3859         (WebCore::HTMLImageElement::didAttachRenderers):
3860         (WebCore::HTMLImageElement::updateImageControls):
3861         (WebCore::HTMLImageElement::createImageControls):
3862         (WebCore::HTMLImageElement::destroyImageControls):
3863         (WebCore::HTMLImageElement::hasImageControls):
3864         (WebCore::HTMLImageElement::childShouldCreateRenderer):
3865         * html/HTMLImageElement.h:
3866         (WebCore::HTMLImageElement::hasShadowControls): For RenderImage to query when it is constructed. 
3867
3868         Add a generic, platform independent ImageControls root element that does nothing:
3869         * html/shadow/ImageControlsRootElement.cpp: Added.
3870         (WebCore::ImageControlsRootElement::maybeCreate):
3871         (WebCore::ImageControlsRootElement::ImageControlsRootElement):
3872         (WebCore::ImageControlsRootElement::~ImageControlsRootElement):
3873         * html/shadow/ImageControlsRootElement.h: Added.
3874
3875         Add a Mac-specific ImageControls root element that renders a 20x20 red box (for now):
3876         * html/shadow/mac/ImageControlsRootElementMac.cpp: Added.
3877         (WebCore::ImageControlsRootElementMac::ImageControlsRootElementMac):
3878         (WebCore::ImageControlsRootElementMac::~ImageControlsRootElementMac):
3879         (WebCore::ImageControlsRootElement::maybeCreate):
3880         (WebCore::ImageControlsRootElementMac::maybeCreate):
3881         * html/shadow/mac/ImageControlsRootElementMac.h: Added.
3882
3883         Since much of the RenderMedia::layout() method is now required for RenderImage as well,
3884         move the logic to RenderImage. The extra work is controlled by a bool flag that will always
3885         be set for RenderMedias but will only be set for certain RenderImages:
3886         * rendering/RenderImage.cpp:
3887         (WebCore::RenderImage::RenderImage):
3888         (WebCore::RenderImage::canHaveChildren):
3889         (WebCore::RenderImage::layout):
3890         (WebCore::RenderImage::layoutShadowControls):
3891         * rendering/RenderImage.h:
3892         (WebCore::RenderImage::setHasShadowControls):
3893         (WebCore::RenderImage::shadowControlsNeedCustomLayoutMetrics):
3894
3895         * rendering/RenderMedia.cpp:
3896         (WebCore::RenderMedia::RenderMedia):
3897         * rendering/RenderMedia.h:
3898         (WebCore::RenderMedia::shadowControlsNeedCustomLayoutMetrics):
3899
3900         * WebCore.xcodeproj/project.pbxproj:
3901
3902 == Rolled over to ChangeLog-2014-02-20 ==