Unreviewed iOS build fix
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-10-23  Myles C. Maxfield  <mmaxfield@apple.com>
2
3         Unreviewed iOS build fix
4
5         * editing/FrameSelection.cpp:
6
7 2014-10-23  Chris Dumez  <cdumez@apple.com>
8
9         [Mac] Optimize URL::createCFURL() for the common case
10         https://bugs.webkit.org/show_bug.cgi?id=138030
11
12         Reviewed by Alexey Proskuryakov.
13
14         Optimize URL::createCFURL() for the common case by adding a fast path
15         for when the URL String is already 8-bit (common case).
16         When the string is 8-bit, we don't need to copy the bytes into a
17         temporary buffer and we can construct the CFURLRef directly from it.
18
19         This makes URL::createCFURL() ~34% faster on my machine.
20
21         No new tests, no behavior change.
22
23         * platform/mac/URLMac.mm:
24         (WebCore::URL::createCFURL):
25
26 2014-10-23  Myles C. Maxfield  <mmaxfield@apple.com>
27
28         Carets in GMail and iCloud compositions are the foreground text color
29         https://bugs.webkit.org/show_bug.cgi?id=138029
30
31         Reviewed by Simon Fraser.
32
33         Previously, we were only checking whether the background colors of the foreground and background
34         elements were the same, rather than taking validity and opacity into consideration.
35
36         Test: editing/caret/color-span-inside-editable-background.html
37
38         * editing/FrameSelection.cpp:
39         (WebCore::disappearsIntoBackground):
40         (WebCore::CaretBase::paintCaret):
41
42 2014-10-23  Joseph Pecoraro  <pecoraro@apple.com>
43
44         Web Inspector: Provide a way to have alternate inspector agents
45         https://bugs.webkit.org/show_bug.cgi?id=137901
46
47         Reviewed by Brian Burg.
48
49         * Configurations/FeatureDefines.xcconfig:
50
51 2014-10-23  Simon Fraser  <simon.fraser@apple.com>
52
53         Don't assume that style.overflowX() == style.overflowY()
54         https://bugs.webkit.org/show_bug.cgi?id=138028
55
56         Reviewed by Zalan Bujtas.
57
58         WebKit doesn't support independent overflow scroll/hidden on different axes,
59         but the RenderStyle does report the correct values. So check both overflowX()
60         and overflowY() in a couple of places where we need to.
61
62         * rendering/RenderLayerCompositor.cpp:
63         (WebCore::styleHasTouchScrolling):
64         (WebCore::styleChangeRequiresLayerRebuild):
65
66 2014-10-23  Chris Dumez  <cdumez@apple.com>
67
68         Get rid of unnecessary vtables in WebKit
69         https://bugs.webkit.org/show_bug.cgi?id=138024
70
71         Reviewed by Benjamin Poulain.
72
73         Get rid of unnecessary vtables in WebKit by de-virtualizing destructors
74         when possible and marking the class as final to make sure people don't
75         subclass it.
76
77         No new tests, no behavior change.
78
79         * WebCore.exp.in:
80         * css/WebKitCSSMatrix.h:
81         * css/WebKitCSSMatrix.idl:
82         * html/canvas/WebGLContextGroup.h:
83         * html/canvas/WebGLGetInfo.h:
84         * html/canvas/WebGLUniformLocation.h:
85         (WebCore::WebGLUniformLocation::~WebGLUniformLocation): Deleted.
86         * html/canvas/WebGLUniformLocation.idl:
87         * inspector/DOMPatchSupport.h:
88         * inspector/InspectorHistory.h:
89         * inspector/InspectorStyleSheet.h:
90         * page/WheelEventDeltaTracker.h:
91         * page/scrolling/ScrollLatchingState.h:
92         * platform/audio/Biquad.h:
93         * platform/graphics/Pattern.h:
94
95 2014-10-23  Chris Dumez  <cdumez@apple.com>
96
97         Clean up virtual functions in dom/
98         https://bugs.webkit.org/show_bug.cgi?id=138019
99
100         Reviewed by Benjamin Poulain.
101
102         Clean up virtual functions in dom/ by:
103         - Making virtual functions final when possible
104         - Making classes final when possible
105         - Using 'override' when appropriate
106         - Explicitly marking functions / destructors as virtual when they are
107           inherently virtual
108         - Making isXXX() virtual functions private on XXX classes to avoid
109           unnecessary type checks
110         - Dropping final for virtual functions in classes already marked as
111           final
112
113         No new tests, no behavior change.
114
115         * WebCore.exp.in:
116         * dom/AutocompleteErrorEvent.h:
117         * dom/BeforeLoadEvent.h:
118         (WebCore::BeforeLoadEventInit::BeforeLoadEventInit):
119         * dom/BeforeTextInsertedEvent.h:
120         * dom/ClipboardEvent.h:
121         * dom/CompositionEvent.h:
122         * dom/CustomEvent.h:
123         * dom/DeviceMotionController.h:
124         (WebCore::DeviceMotionController::~DeviceMotionController): Deleted.
125         * dom/DeviceMotionEvent.h:
126         * dom/DeviceOrientationController.h:
127         (WebCore::DeviceOrientationController::~DeviceOrientationController): Deleted.
128         * dom/DeviceOrientationEvent.h:
129         * dom/Document.h:
130         * dom/DocumentFragment.h:
131         * dom/ErrorEvent.h:
132         * dom/FocusEvent.h:
133         * dom/HashChangeEvent.h:
134         * dom/KeyboardEvent.h:
135         * dom/LiveNodeList.h:
136         * dom/MessageEvent.h:
137         * dom/MessagePort.h:
138         * dom/MouseEvent.h:
139         * dom/MouseRelatedEvent.h:
140         * dom/MutationEvent.h:
141         * dom/NamedFlowCollection.h:
142         * dom/OverflowEvent.h:
143         * dom/PageTransitionEvent.h:
144         * dom/PendingScript.h:
145         * dom/PopStateEvent.h:
146         * dom/RawDataDocumentParser.h:
147         (WebCore::RawDataDocumentParser::finish): Deleted.
148         (WebCore::RawDataDocumentParser::flush): Deleted.
149         (WebCore::RawDataDocumentParser::insert): Deleted.
150         (WebCore::RawDataDocumentParser::append): Deleted.
151         * dom/ScriptableDocumentParser.h:
152         * dom/SecurityPolicyViolationEvent.h:
153         * dom/TextEvent.h:
154         * dom/TouchEvent.h:
155         * dom/TransitionEvent.h:
156         * dom/UIEvent.h:
157         * dom/WebKitAnimationEvent.h:
158         * dom/WebKitTransitionEvent.h:
159         * dom/WheelEvent.h:
160         * page/DeviceController.h:
161         (WebCore::DeviceController::~DeviceController):
162
163 2014-10-23  Tim Horton  <timothy_horton@apple.com>
164
165         Add some SPI headers for NSExtension and NSSharingService{Picker}
166         https://bugs.webkit.org/show_bug.cgi?id=138027
167
168         Reviewed by Anders Carlsson.
169
170         * WebCore.xcodeproj/project.pbxproj:
171         * platform/spi/cocoa/NSExtensionSPI.h: Added.
172         * platform/spi/mac/NSSharingServicePickerSPI.h: Added.
173         * platform/spi/mac/NSSharingServiceSPI.h: Added.
174         Add modern SPI headers for NSExtension, and NSSharingService{Picker}.
175
176         * rendering/RenderThemeMac.mm:
177         Replace redefinitions with an SPI header #import.
178
179 2014-10-23  Eric Carlson  <eric.carlson@apple.com>
180
181         [Mac] don't update caption user style sheet during parsing
182         https://bugs.webkit.org/show_bug.cgi?id=137983
183         rdar://problem/18735366
184
185         Reviewed by Jer Noble.
186
187         No new tests, existing tests cover the changes.
188
189         * page/CaptionUserPreferencesMediaAF.cpp:
190         (WebCore::CaptionUserPreferencesMediaAF::CaptionUserPreferencesMediaAF): Initialize m_updateStyleSheetTimer.
191         (WebCore::CaptionUserPreferencesMediaAF::updateTimerFired): Call updateCaptionStyleSheetOveride.
192         (WebCore::CaptionUserPreferencesMediaAF::setInterestedInCaptionPreferenceChanges): Prime a timer to update 
193             the captions style sheet after a slight delay.
194
195 2014-10-23  Chris Dumez  <cdumez@apple.com>
196
197         Move remaining Length-type properties to the new StyleBuilder
198         https://bugs.webkit.org/show_bug.cgi?id=138012
199
200         Reviewed by Antti Koivisto.
201
202         Move remaining Length-type properties from DeprecatedStyleBuilder to
203         the new StyleBuilder so that they are now generated from
204         CSSPropertyNames.in as well. The patch introduces a couple of type
205         converters for those: "LengthSizing / LengthMaxSizing".
206
207         No new tests, no behavior change.
208
209         * css/CSSPropertyNames.in:
210         * css/DeprecatedStyleBuilder.cpp:
211         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
212         * css/StyleBuilderConverter.h:
213         (WebCore::StyleBuilderConverter::convertLengthSizing):
214         (WebCore::StyleBuilderConverter::convertLengthMaxSizing):
215
216 2014-10-23  Jer Noble  <jer.noble@apple.com>
217
218         [Mac] Safari cannot play 'audio/amr' content.
219         https://bugs.webkit.org/show_bug.cgi?id=137894
220
221         Reviewed by Eric Carlson.
222
223         Test: media/media-can-play-case-insensitive.html
224
225         Sites are returning 'video/amr' for AMR audio content, but the IANA spec says 'audio/AMR', which is also what
226         AVFoundation claims to support.  However, MIME types are supposed to be case-insensitive. When creating our
227         mime type cache, case-fold to lower all MIME types given to us by our media frameworks.
228
229         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
230         (WebCore::mimeTypeCache):
231         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
232         (WebCore::addFileTypesToCache):
233
234 2014-10-23  Chris Dumez  <cdumez@apple.com>
235
236         Move Length-type CSS properties from DeprecatedStyleBuilder to the new Style Builder
237         https://bugs.webkit.org/show_bug.cgi?id=138000
238
239         Reviewed by Andreas Kling.
240
241         Move most Length-type CSS properties from DeprecatedStyleBuilder to the
242         new Style Builder so that they are now generated. This patch adds
243         support for a "Converter" option in CSSPropertyNames.in that can be
244         used to specify a type converter function in
245         css/StyleBuilderConverter.h. This patch adds support for Length and
246         LengthOrAuto converters so that most Length-type properties can now be
247         generated.
248
249         Another converter (likely called "LengthSizing") will be needed to
250         generate the remaining Length-type properties. This will be taken care
251         of in a follow-up patch.
252
253         This patch is inspired by the following Blink revision by
254         <timloh@chromium.org>:
255         https://src.chromium.org/viewvc/blink?view=rev&revision=150500
256
257         No new tests, no behavior change.
258
259         * WebCore.xcodeproj/project.pbxproj:
260         * css/CSSPropertyNames.in:
261         * css/DeprecatedStyleBuilder.cpp:
262         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
263         * css/SVGCSSPropertyNames.in:
264         * css/StyleBuilder.h:
265         * css/StyleBuilderConverter.h: Added.
266         (WebCore::StyleBuilderConverter::convertLength):
267         (WebCore::StyleBuilderConverter::convertLengthOrAuto):
268         * css/StyleResolver.cpp:
269         (WebCore::StyleResolver::applyProperty):
270         * css/makeprop.pl:
271
272 2014-10-23  Zan Dobersek  <zdobersek@igalia.com>
273
274         Const-ify static s_resourceType members in RenderSVGResource* classes
275         https://bugs.webkit.org/show_bug.cgi?id=137911
276
277         Reviewed by Andreas Kling.
278
279         Make s_resourceType static members in RenderSVGResource* classes const.
280         Also update the resourceType() methods, where necessary, so that they
281         return the s_resourceType constant.
282
283         * rendering/svg/RenderSVGResourceClipper.cpp:
284         * rendering/svg/RenderSVGResourceClipper.h:
285         * rendering/svg/RenderSVGResourceFilter.cpp:
286         * rendering/svg/RenderSVGResourceFilter.h:
287         * rendering/svg/RenderSVGResourceLinearGradient.cpp:
288         * rendering/svg/RenderSVGResourceLinearGradient.h:
289         * rendering/svg/RenderSVGResourceMarker.cpp:
290         * rendering/svg/RenderSVGResourceMarker.h:
291         * rendering/svg/RenderSVGResourceMasker.cpp:
292         * rendering/svg/RenderSVGResourceMasker.h:
293         * rendering/svg/RenderSVGResourcePattern.cpp:
294         * rendering/svg/RenderSVGResourcePattern.h:
295         * rendering/svg/RenderSVGResourceRadialGradient.cpp:
296         * rendering/svg/RenderSVGResourceRadialGradient.h:
297         * rendering/svg/RenderSVGResourceSolidColor.cpp:
298         * rendering/svg/RenderSVGResourceSolidColor.h:
299
300 2014-10-23  Zan Dobersek  <zdobersek@igalia.com>
301
302         [TexMap] Clean up virtual method declarations in GraphicsLayerTextureMapper
303         https://bugs.webkit.org/show_bug.cgi?id=137957
304
305         Reviewed by Martin Robinson.
306
307         Added override notation to the GraphicsLayerTextureMapper methods that are
308         overriding the base methods from the GraphicsLayer class and don't have it yet.
309         Also reordered these methods to follow the order of declaration in the
310         GraphicsLayer class.
311
312         Removed ::setName() and ::willBeDestroyed() methods since they just called
313         the base class' methods.
314
315         Also removed the ::solidColor() and ::changeMask() methods. The first one was
316         only called in one place which can reference the m_solidColor member directly,
317         and the second one wasn't used at all.
318
319         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
320         (WebCore::GraphicsLayerTextureMapper::commitLayerChanges):
321         (WebCore::GraphicsLayerTextureMapper::setName): Deleted.
322         (WebCore::GraphicsLayerTextureMapper::willBeDestroyed): Deleted.
323         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
324         (WebCore::GraphicsLayerTextureMapper::solidColor): Deleted.
325         (WebCore::GraphicsLayerTextureMapper::usesContentsLayer): Deleted.
326         (WebCore::GraphicsLayerTextureMapper::platformLayer): Deleted.
327         (WebCore::GraphicsLayerTextureMapper::changeMask): Deleted.
328
329 2014-10-23  Krzysztof Czech  <k.czech@samsung.com>
330
331         AX: Do the early return when role is different than UnknownRole
332         https://bugs.webkit.org/show_bug.cgi?id=137880
333
334         Reviewed by Chris Fleizach.
335
336         We do not need to call ariaRoleAttribute() to check whether m_ariaRole is different than UnknownRole.
337         Just check m_ariaRole instead.
338
339         No new tests, no behavior change, just some cleanup
340
341         * accessibility/AccessibilityNodeObject.cpp:
342         (WebCore::AccessibilityNodeObject::determineAccessibilityRole):
343         * accessibility/AccessibilityRenderObject.cpp:
344         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
345         * accessibility/AccessibilityTableRow.cpp:
346         (WebCore::AccessibilityTableRow::determineAccessibilityRole):
347
348 2014-10-23  Yusuke Suzuki  <utatane.tea@gmail.com>
349
350         CSS JIT: Implement :matches
351         https://bugs.webkit.org/show_bug.cgi?id=137947
352
353         Reviewed by Benjamin Poulain.
354
355         Initial patch for supporting :matches in CSS JIT.
356         In this patch, we implement :matches
357         by leveraging the generalized nested backtracking implementation.
358
359         Tests: fast/selectors/matches-backtracking.html
360                fast/selectors/matches-complex.html
361
362         * cssjit/SelectorCompiler.cpp:
363         (WebCore::SelectorCompiler::addPseudoClassType):
364         (WebCore::SelectorCompiler::hasAnyCombinators):
365         (WebCore::SelectorCompiler::computeBacktrackingMemoryRequirements):
366         (WebCore::SelectorCompiler::computeBacktrackingInformation):
367         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
368         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesMatchesPseudoClass):
369
370 2014-10-23  Milan Crha  <mcrha@redhat.com>
371
372         RenderThemeGtk::mediaControlsScript() is not defined when VIDEO is disabled.
373         <https://webkit.org/b/137970>.
374
375         Reviewed by Carlos Garcia Campos.
376
377         * rendering/RenderThemeGtk.cpp:
378
379 2014-10-22  Milan Crha  <mcrha@redhat.com>
380
381         Do not include GraphicsContext3D.h when 3D_GRAPHICS is not used.
382         <https://webkit.org/b/137969>.
383
384         Reviewed by Carlos Garcia Campos.
385
386         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
387
388 2014-10-22  Milan Crha  <mcrha@redhat.com>
389
390         Do not build WidgetBackingStoreGtkX11 when not used.
391         <https://webkit.org/b/137972>.
392
393         Reviewed by Carlos Garcia Campos.
394
395         * platform/gtk/WidgetBackingStoreGtkX11.cpp:
396         * platform/gtk/WidgetBackingStoreGtkX11.h:
397
398 2014-10-22  Simon Fraser  <simon.fraser@apple.com>
399
400         [iOS] Toggling overflow:scroll to hidden on element with -webkit-overflow-scrolling:touch can cause children to disappear
401         https://bugs.webkit.org/show_bug.cgi?id=137999
402         rdar://problem/18425550
403
404         Reviewed by Zalan Bujtas.
405         
406         When toggling overflow from scroll to hidden on an element with -webkit-overflow-scrolling:touch,
407         we'd fail to do a compositing layer rebuild, which caused various issues like unparented
408         descendants, and misplaced and unrepainted content.
409         
410         This happened because we'd get to RenderLayerBacking::updateConfiguration() via styleChanged
411         with the view needing layout, so never hit the updateScrollingLayers() code, and the subsequent
412         updateCompositingLayers() would be a no-op.
413         
414         Fix by explicitly triggering a layer rebuild when style changes such that the touch-scrollability
415         of an element changes, as we do for changes in clip.
416
417         Test: compositing/scrolling/touch-scroll-to-clip.html
418
419         * rendering/RenderLayerCompositor.cpp:
420         (WebCore::isScrollableOverflow):
421         (WebCore::styleHasTouchScrolling):
422         (WebCore::styleChangeRequiresLayerRebuild):
423
424 2014-10-22  Chris Dumez  <cdumez@apple.com>
425
426         Clean up virtual functions in rendering/
427         https://bugs.webkit.org/show_bug.cgi?id=137984
428
429         Reviewed by Darin Adler.
430
431         Clean up virtual functions in rendering/ by:
432         - Making virtual functions final when possible
433         - Making classes final when possible
434         - Using 'override' when appropriate
435         - Explicitly marking functions / destructors as virtual when they are
436           inherently virtual
437         - Dropping virtual destructors when the class does not have subclasses
438           and mark the class as final, to get rid of unnecessary vtables
439         - Making isXXX() virtual functions private on XXX classes to avoid
440           unnecessary type checks
441         - De-virtualizing some functions that do not need to be virtual
442         - Dropping final for virtual functions in classes already marked as
443           final
444
445         No new tests, no behavior change.
446
447         * html/shadow/SliderThumbElement.cpp:
448         * rendering/AutoTableLayout.h:
449         * rendering/ClipPathOperation.h:
450         (WebCore::ClipPathOperation::type):
451         (WebCore::ClipPathOperation::isSameType):
452         * rendering/EllipsisBox.h:
453         * rendering/FixedTableLayout.h:
454         * rendering/InlineElementBox.h:
455         * rendering/RenderBlockFlow.h:
456         * rendering/RenderCombineText.h:
457         * rendering/RenderCounter.h:
458         * rendering/RenderDeprecatedFlexibleBox.h:
459         * rendering/RenderFlexibleBox.h:
460         * rendering/RenderFullScreen.h:
461         * rendering/RenderGrid.h:
462         * rendering/RenderLayer.h:
463         * rendering/RenderLayerBacking.h:
464         * rendering/RenderLayerCompositor.h:
465         * rendering/RenderLayerFilterInfo.h:
466         * rendering/RenderLineBreak.h:
467         * rendering/RenderMarquee.h:
468         * rendering/RenderMediaControlElements.h:
469         * rendering/RenderMultiColumnFlowThread.h:
470         * rendering/RenderMultiColumnSet.h:
471         * rendering/RenderMultiColumnSpannerPlaceholder.h:
472         * rendering/RenderNamedFlowFragment.h:
473         * rendering/RenderNamedFlowThread.h:
474         * rendering/RenderQuote.h:
475         * rendering/RenderRegion.h:
476         (WebCore::RenderRegion::renderName): Deleted.
477         * rendering/RenderReplica.h:
478         * rendering/RenderRubyBase.h:
479         * rendering/RenderRubyRun.h:
480         * rendering/RenderScrollbar.h:
481         * rendering/RenderScrollbarPart.h:
482         * rendering/RenderScrollbarTheme.h:
483         (WebCore::RenderScrollbarTheme::~RenderScrollbarTheme): Deleted.
484         (WebCore::RenderScrollbarTheme::scrollbarThickness): Deleted.
485         (WebCore::RenderScrollbarTheme::buttonsPlacement): Deleted.
486         (WebCore::RenderScrollbarTheme::supportsControlTints): Deleted.
487         (WebCore::RenderScrollbarTheme::shouldCenterOnThumb): Deleted.
488         (WebCore::RenderScrollbarTheme::initialAutoscrollTimerDelay): Deleted.
489         (WebCore::RenderScrollbarTheme::autoscrollTimerDelay): Deleted.
490         (WebCore::RenderScrollbarTheme::registerScrollbar): Deleted.
491         (WebCore::RenderScrollbarTheme::unregisterScrollbar): Deleted.
492         * rendering/RenderSnapshottedPlugIn.h:
493         * rendering/RenderTextControlMultiLine.h:
494         * rendering/RenderTextFragment.h:
495         * rendering/RenderThemeGtk.h:
496         * rendering/RenderThemeIOS.h:
497         * rendering/RenderThemeWin.h:
498         * rendering/RenderVideo.h:
499         * rendering/TextAutosizer.h:
500         * rendering/TrailingFloatsRootInlineBox.h:
501         * rendering/mathml/RenderMathMLBlock.h:
502         * rendering/mathml/RenderMathMLMenclose.h:
503         * rendering/mathml/RenderMathMLOperator.h:
504         * rendering/mathml/RenderMathMLRadicalOperator.h:
505         * rendering/mathml/RenderMathMLRoot.h:
506         * rendering/mathml/RenderMathMLRow.h:
507         * rendering/mathml/RenderMathMLScripts.h:
508         * rendering/mathml/RenderMathMLToken.h:
509         * rendering/mathml/RenderMathMLUnderOver.h:
510         * rendering/shapes/BoxShape.h:
511         * rendering/shapes/PolygonShape.h:
512         * rendering/shapes/RasterShape.h:
513         * rendering/shapes/RectangleShape.h:
514         * rendering/style/BasicShapes.h:
515         * rendering/style/StylePendingImage.h:
516         (WebCore::StylePendingImage::computeIntrinsicDimensions): Deleted.
517         * rendering/svg/RenderSVGBlock.h:
518         * rendering/svg/RenderSVGContainer.h:
519         * rendering/svg/RenderSVGEllipse.h:
520         * rendering/svg/RenderSVGForeignObject.h:
521         * rendering/svg/RenderSVGImage.h:
522         * rendering/svg/RenderSVGPath.h:
523         * rendering/svg/RenderSVGRect.h:
524         * rendering/svg/RenderSVGResourceClipper.h:
525         * rendering/svg/RenderSVGResourceFilter.h:
526         * rendering/svg/RenderSVGResourceFilterPrimitive.h:
527         * rendering/svg/RenderSVGResourceLinearGradient.h:
528         * rendering/svg/RenderSVGResourceMarker.h:
529         * rendering/svg/RenderSVGResourceMasker.h:
530         * rendering/svg/RenderSVGResourcePattern.h:
531         * rendering/svg/RenderSVGResourceRadialGradient.h:
532         * rendering/svg/RenderSVGRoot.h:
533         * rendering/svg/RenderSVGTSpan.h:
534         * rendering/svg/RenderSVGText.h:
535         * rendering/svg/RenderSVGTransformableContainer.h:
536         * rendering/svg/RenderSVGViewportContainer.h:
537         * rendering/svg/SVGInlineTextBox.h:
538         * rendering/svg/SVGRootInlineBox.h:
539
540 2014-10-22  Jer Noble  <jer.noble@apple.com>
541
542         REGRESSION(r175000): Crash in SourceBufferPrivateAVFObjC::destroyParser()
543         https://bugs.webkit.org/show_bug.cgi?id=137990
544
545         Reviewed by Alexey Proskuryakov.
546
547         NULL-check m_mediaSource before using.
548
549         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
550         (WebCore::SourceBufferPrivateAVFObjC::destroyParser):
551
552 2014-10-22  Said Abou-Hallawa  <sabouhallawa@apple.com>
553
554         SVG loaded through html <img> can't request to load any external resources.
555         https://bugs.webkit.org/show_bug.cgi?id=137762.
556
557         Reviewed by Daniel Bates.
558
559         SVG images have unique security rules that prevent them from loading any external
560         resources. This patch enforces these rules in CachedResourceLoader::canRequest for
561         all non-data-uri resources.
562
563         The fix and the tests are ported but modified a little from the chromium fix:
564         http://src.chromium.org/viewvc/blink?view=rev&rev=176084
565
566         Test: http/tests/security/svg-image-with-cached-remote-image.html
567               http/tests/security/svg-image-with-css-cross-domain.html
568
569         For the SVG image, prevent loading any external sub-resource except for data urls.
570         * loader/cache/CachedResourceLoader.cpp:
571         (WebCore::CachedResourceLoader::canRequest):
572
573 2014-10-21  Ada Chan  <adachan@apple.com>
574
575         MediaPlayerPrivateAVFoundation::hasAudio() returns false even when there is an audible AVMediaSelectionOption selected
576         https://bugs.webkit.org/show_bug.cgi?id=137935
577
578         Reviewed by Eric Carlson.
579
580         Set hasAudio to true if there's a selected audible AVMediaSelectionOption
581         after the call to updateAudioTracks(). Ditto for video.
582
583         Test: http/tests/media/hls/hls-audio-tracks-has-audio.html
584
585         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
586         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged):
587
588         * testing/Internals.cpp:
589         (WebCore::Internals::mediaElementHasCharacteristic):
590         * testing/Internals.h:
591         * testing/Internals.idl:
592         Add internals.mediaElementHasCharacteristic for the new test.
593
594 2014-10-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
595
596         Remove WidgetBackingStoreCairo::create() factory function
597         https://bugs.webkit.org/show_bug.cgi?id=137943
598
599         Reviewed by Darin Adler.
600
601         WidgetBackingStoreCairo::create() can be replaced by std::make_unique<>.
602         Thus this patch removes it, then use std::make_unique<>|std::unique_ptr<>.
603
604         No new tests, no behavior changes.
605
606         * platform/cairo/WidgetBackingStoreCairo.cpp:
607         (WebCore::WidgetBackingStoreCairo::create): Deleted.
608         * platform/cairo/WidgetBackingStoreCairo.h:
609         * platform/gtk/WidgetBackingStoreGtkX11.cpp:
610         (WebCore::WidgetBackingStoreGtkX11::create): Deleted.
611         * platform/gtk/WidgetBackingStoreGtkX11.h:
612
613 2014-10-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
614
615         Remove TextCheckerEnchant::create() factory function
616         https://bugs.webkit.org/show_bug.cgi?id=137944
617
618         Reviewed by Darin Adler.
619
620         TextCheckerEnchant::create() can be replaced by std::make_unique<> and std::unique_ptr<>.
621
622         No new tests, no behavior change.
623
624         * platform/text/enchant/TextCheckerEnchant.h:
625         (WebCore::TextCheckerEnchant::create): Deleted.
626
627 2014-10-22  Chris Dumez  <cdumez@apple.com>
628
629         Avoid confusion between AccessibilityObject::isTable() / isAccessibilityTable()
630         https://bugs.webkit.org/show_bug.cgi?id=137899
631
632         Reviewed by Darin Adler.
633
634         Avoid confusion between AccessibilityObject::isTable() and
635         isAccessibilityTable(). isTable() is equivalent to
636         is<AccessibilityTable>(), while isAccessibilityTable() is an
637         AccessibilityTable that is exposed as an AccessibilityTable to the
638         platform.
639
640         This patch is renaming isAccessibilityTable() to
641         isExposableThroughAccessibility(), makes it non-virtual and defines it
642         on AccessibilityTable only, for clarity.
643
644         This patch also renames isTableExposableThroughAccessibility() to
645         computeIisTableExposableThroughAccessibility() as it is called only
646         once to initialize the m_isExposableThroughAccessibility data member.
647
648         No new tests, no behavior change.
649
650         * accessibility/AccessibilityARIAGrid.cpp:
651         (WebCore::AccessibilityARIAGrid::addChildren):
652         * accessibility/AccessibilityARIAGrid.h:
653         * accessibility/AccessibilityARIAGridCell.cpp:
654         (WebCore::AccessibilityARIAGridCell::parentTable):
655         (WebCore::AccessibilityARIAGridCell::rowIndexRange):
656         (WebCore::AccessibilityARIAGridCell::columnIndexRange):
657         * accessibility/AccessibilityARIAGridRow.cpp:
658         (WebCore::AccessibilityARIAGridRow::disclosedRows):
659         (WebCore::AccessibilityARIAGridRow::disclosedByRow):
660         (WebCore::AccessibilityARIAGridRow::parentTable):
661         * accessibility/AccessibilityNodeObject.cpp:
662         (WebCore::shouldUseAccessiblityObjectInnerText):
663         * accessibility/AccessibilityObject.cpp:
664         (WebCore::AccessibilityObject::isAccessibilityObjectSearchMatchAtIndex):
665         (WebCore::appendChildrenToArray):
666         * accessibility/AccessibilityObject.h:
667         (WebCore::AccessibilityObject::isAccessibilityTable): Deleted.
668         * accessibility/AccessibilityRenderObject.cpp:
669         (WebCore::AccessibilityRenderObject::ariaSelectedRows):
670         * accessibility/AccessibilityTable.cpp:
671         (WebCore::AccessibilityTable::AccessibilityTable):
672         (WebCore::AccessibilityTable::init):
673         (WebCore::AccessibilityTable::isExposableThroughAccessibility):
674         (WebCore::AccessibilityTable::computeIsTableExposableThroughAccessibility):
675         (WebCore::AccessibilityTable::addChildren):
676         (WebCore::AccessibilityTable::tableLevel):
677         (WebCore::AccessibilityTable::roleValue):
678         (WebCore::AccessibilityTable::computeAccessibilityIsIgnored):
679         (WebCore::AccessibilityTable::title):
680         (WebCore::AccessibilityTable::isAccessibilityTable): Deleted.
681         (WebCore::AccessibilityTable::isTableExposableThroughAccessibility): Deleted.
682         * accessibility/AccessibilityTable.h:
683         * accessibility/AccessibilityTableCell.cpp:
684         (WebCore::AccessibilityTableCell::isTableCell):
685         * accessibility/AccessibilityTableColumn.cpp:
686         (WebCore::AccessibilityTableColumn::headerObject):
687         (WebCore::AccessibilityTableColumn::addChildren):
688         * accessibility/AccessibilityTableHeaderContainer.cpp:
689         (WebCore::AccessibilityTableHeaderContainer::addChildren):
690         * accessibility/AccessibilityTableRow.cpp:
691         (WebCore::AccessibilityTableRow::isTableRow):
692         (WebCore::AccessibilityTableRow::parentTable):
693         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
694         (webkitAccessibleGetNChildren):
695         (webkitAccessibleRefChild):
696         (webkitAccessibleGetAttributes):
697         * accessibility/mac/AXObjectCacheMac.mm:
698         (WebCore::AXObjectCache::postPlatformNotification):
699         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
700         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
701         (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):
702         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
703         (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
704         (-[WebAccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
705         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
706
707 2014-10-22  Chris Dumez  <cdumez@apple.com>
708
709         Avoid repeated is<MutableStyleProperties>() checks in StyleProperties
710         https://bugs.webkit.org/show_bug.cgi?id=137978
711
712         Reviewed by Andreas Kling.
713
714         Reduce the amount of is<MutableStyleProperties>() checks in
715         StyleProperties by:
716         - Removing the checks in each method of StyleProperties::PropertyReference,
717           and replace them by a single check in StyleProperties::propertyAt().
718         - Providing faster propertyCount() / propertyAt() / isEmpty() methods on
719           MutableStyleProperties / ImmutableStyleProperties as a lot of callers use
720           tight typing.
721         - Using tighter typing at call sites whenever possible.
722
723         Ideally, we could be able to use iterators instead of propertyCount() /
724         propertyAt() but this is not trivial to do efficiently as the
725         representation in memory is fundamentally different for MutableStyleProperties
726         / ImmutableStyleProperties. We may be able to do better longer term, but
727         this is already more efficient short term at least.
728
729         No new tests, no behavior change.
730
731         * css/StyleProperties.cpp:
732         (WebCore::MutableStyleProperties::MutableStyleProperties):
733         (WebCore::StyleProperties::PropertyReference::cssText):
734         * css/StyleProperties.h:
735         (WebCore::StyleProperties::PropertyReference::PropertyReference):
736         (WebCore::StyleProperties::PropertyReference::id):
737         (WebCore::StyleProperties::PropertyReference::shorthandID):
738         (WebCore::StyleProperties::PropertyReference::isImportant):
739         (WebCore::StyleProperties::PropertyReference::isInherited):
740         (WebCore::StyleProperties::PropertyReference::isImplicit):
741         (WebCore::StyleProperties::PropertyReference::value):
742         (WebCore::StyleProperties::PropertyReference::toCSSProperty):
743         (WebCore::StyleProperties::isEmpty):
744         (WebCore::ImmutableStyleProperties::isEmpty):
745         (WebCore::MutableStyleProperties::isEmpty):
746         (WebCore::ImmutableStyleProperties::propertyAt):
747         (WebCore::MutableStyleProperties::propertyAt):
748         (WebCore::StyleProperties::propertyAt):
749         (WebCore::StyleProperties::propertyCount):
750         (WebCore::StyleProperties::PropertyReference::propertyMetadata): Deleted.
751         (WebCore::StyleProperties::PropertyReference::propertyValue): Deleted.
752         * editing/EditingStyle.cpp:
753         (WebCore::removePropertiesInStyle):
754         (WebCore::EditingStyle::removePropertiesInElementDefaultStyle):
755
756 2014-10-22  Eric Carlson  <eric.carlson@apple.com>
757
758         [Mac][MediaStream] clean up bit rot
759         https://bugs.webkit.org/show_bug.cgi?id=137976
760
761         Reviewed by Jer Noble.
762
763         No new tests, this just gets the Mac port compiling again.
764
765         * Modules/mediastream/MediaStream.h: Add a virtual destructor to Observer since it has 
766             a virtual method.
767
768         * WebCore.exp.in: Export RTCPeerConnectionHandler::create and RTCPeerConnectionHandlerMock::create(WebCore::RTCPeerConnectionHandlerClient*),
769             they are both use by Internals for testing.
770
771         * WebCore.xcodeproj/project.pbxproj: Add RTC and MediaStream files.
772
773         * html/HTMLMediaElement.h: Forward declare MediaStream instead of including MediaStream.h.
774
775         * platform/mediastream/RTCPeerConnectionHandler.h: EXPORT the create method.
776
777         * platform/mock/MediaConstraintsMock.cpp:
778         (WebCore::isSupported): Make static.
779         (WebCore::isValid): Ditto.
780
781         * platform/mock/RTCPeerConnectionHandlerMock.h: EXPORT the create method.
782
783 2014-10-22  Chris Dumez  <cdumez@apple.com>
784
785         [Mac][WK2] Fix applicationIsSafari() detection
786         https://bugs.webkit.org/show_bug.cgi?id=137893
787
788         Reviewed by Alexey Proskuryakov.
789
790         I noticed when profiling Safari on Mac that we were exercising a code
791         path we shouldn't because it is meant for other applications that
792         Safari.
793
794         The detection relies on the applicationIsSafari() function in
795         RuntimeApplicationChecks.cpp. This was in some cases returning false on
796         my machine even though I was running Safari so I investigated a bit and
797         noticed that the check relies on the main bundle identifier string and
798         is doing:
799         isSafari = mainBundleIsEqualTo("com.apple.Safari")
800             || mainBundleIsEqualTo("com.apple.WebProcess");
801
802         This WebProcess detection is very unreliable because:
803         - It matches other apps than Safari's WebProcesses
804         - The bundle name for the WebProcess is sometimes
805         "com.apple.WebKit.WebContent" or
806         "com.apple.WebKit.WebContent.Development".
807
808         The solution used in this patch is to move the applicationIsSafari()
809         check to the UIProcess so that the check actually succeeds reliably.
810         The call site for applicationIsSafari() was in
811         ResourceRequest::useQuickLookResourceCachingQuirks(). This match
812         removes that logic from ResourceRequest and move it to
813         FrameLoaderClient as only the FrameLoader is interested in this
814         information. The logic to determine if we should use QuickLook
815         resource caching quirks is moved to a new QuickLook class under
816         platform/ as the code needs to be shared between WebKit and WebKit2.
817         On WebKit2, we make use that code on the UIProcess side and pass
818         the flag as a parameter when constructing the WebProcess. The flag
819         is then stored on the WebProcess and queried by WebFrameLoaderClient.
820
821         Previously, we would spend ~1% of the WebProcess cpu time (when loading
822         apple.com) trying to detect if we should use QuickLook resource caching
823         quirks even though that check was supposed to be disabled and return
824         early when running Safari.
825
826         No new tests, not easily testable.
827
828         * WebCore.exp.in:
829         * WebCore.xcodeproj/project.pbxproj:
830         * loader/EmptyClients.h:
831         * loader/FrameLoader.cpp:
832         (WebCore::FrameLoader::subresourceCachePolicy):
833         * loader/FrameLoaderClient.h:
834         * platform/RuntimeApplicationChecks.cpp:
835         (WebCore::applicationIsSafari):
836         Remove "com.apple.WebProcess" bundle name matching as this causes false
837         positives (matches other applications than Safari's WebProcesses) and
838         it is no longer needed now that applicationIsSafari() is always called
839         from the UIProcess.
840
841         * platform/mac/QuickLookMac.h: Added.
842         * platform/mac/QuickLookMac.mm: Copied from Source/WebCore/platform/network/mac/ResourceRequestMac.mm.
843         (WebCore::QuickLookMac::computeNeedsQuickLookResourceCachingQuirks):
844         * platform/network/cf/ResourceRequest.h:
845         * platform/network/ios/ResourceRequestIOS.mm:
846         (WebCore::ResourceRequest::useQuickLookResourceCachingQuirks): Deleted.
847         * platform/network/mac/ResourceRequestMac.mm:
848         (WebCore::initQuickLookResourceCachingQuirks): Deleted.
849         (WebCore::ResourceRequest::useQuickLookResourceCachingQuirks): Deleted.
850
851 2014-10-22  Shivakumar JM  <shiva.jm@samsung.com>
852
853         XMLHttpRequest should support attribute responseURL as per latest XHR spec.
854         https://bugs.webkit.org/show_bug.cgi?id=136938
855
856         Reviewed by Alexey Proskuryakov.
857
858         Tests: http/tests/xmlhttprequest/basic-auth-responseURL.html
859                http/tests/xmlhttprequest/cross-origin-redirect-responseURL.html
860                http/tests/xmlhttprequest/redirect-credentials-responseURL.html
861                http/tests/xmlhttprequest/xmlhttprequest-responseURL.html
862
863         XMLHttpRequest should support attribute responseURL
864
865         * xml/XMLHttpRequest.cpp:
866         (WebCore::XMLHttpRequest::responseURL):
867         * xml/XMLHttpRequest.h:
868         * xml/XMLHttpRequest.idl:
869
870 2014-10-22  Chris Dumez  <cdumez@apple.com>
871
872         Add initial support for generating the StyleBuilder from CSSPropertyNames.in
873         https://bugs.webkit.org/show_bug.cgi?id=137910
874
875         Reviewed by Andreas Kling.
876
877         Add initial support for generating the StyleBuilder from
878         CSSPropertyNames.in. This is a first step towards getting rid of the
879         legacy DeprecatedStyleBuilder class and having everything defined in one
880         place (CSSPropertyNames.in).
881
882         This patch updates makeprop.pl script to generate a StyleBuilder.cpp
883         file that generate a the StyleBuilder::applyProperty() method
884         implementation using a huge switch statement for all the CSS
885         properties. With this patch, we are now generating the new StyleBuilder
886         code for all the "simple" CSS properties (i.e. those that were using
887         ApplyPropertyDefault<> in DeprecatedStyleBuilder.cpp). I am using a
888         "NewStyleBuilder" option in CSSPropertyNames.in for properties that
889         we generate to help with improving incrementally the generator. Once
890         we are able to generate all properties, this transition option will
891         do away and become the default.
892
893         By default, the generator will make an educated guess for the type
894         name, the getter, the setter and the initial function of each property.
895         For example, for the border-collapse property, it will use:
896         - TypeName: EBorderCollapse (i.e. 'E' + PropertyId)
897         - Getter: borderCollapse() (i.e. PropertyId with first letter lowercased)
898         - Setter: setBorderCollapse() (i.e. 'set' + PropertyId)
899         - Initial: initialBorderCollapse() (i.e. 'initial' + PropertyId)
900
901         This works for most properties. For properties that need
902         special-casing, developers can use the following options in
903         CSSPropertyNames.in:
904         - TypeName: Overrides the type name
905         - Getter: Overrides the getter name
906         - Setter: Overrides the setter name
907         - Initial: Overrides the initial function name
908         - NameForMethods: Overrides the Getter / Setter / Initial function
909           names. For e.g. "NameForMethods=OverflowWrap" will use
910           "overflowWrap() / setOverflowWrap() / initialOverflowWrap()".
911
912         The patch is inspired by the following Blink revision by
913         <timloh@chromium.org>:
914         https://src.chromium.org/viewvc/blink?view=rev&revision=150424
915
916         No new tests, no behavior change.
917
918         * CMakeLists.txt:
919         * DerivedSources.make:
920         * WebCore.vcxproj/WebCore.vcxproj:
921         * WebCore.vcxproj/WebCore.vcxproj.filters:
922         * WebCore.xcodeproj/project.pbxproj:
923         * css/CSSPropertyNames.in:
924         * css/DeprecatedStyleBuilder.cpp:
925         (WebCore::ApplyPropertyVerticalAlign::createHandler):
926         (WebCore::ApplyPropertyDisplay::applyInitialValue):
927         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
928         * css/StyleBuilder.h: Added.
929         * css/StyleResolver.cpp:
930         (WebCore::StyleResolver::adjustRenderStyle):
931         (WebCore::StyleResolver::applyProperty):
932         * css/makeprop.pl:
933         * rendering/style/RenderStyle.h:
934         Move the initialXXX() methods that were in NonInheritedFlags to
935         RenderStyle class, with the other initialXXX() methods to facilitate
936         code generation.
937
938         * rendering/style/StyleMultiColData.cpp:
939         (WebCore::StyleMultiColData::StyleMultiColData):
940         * rendering/style/StyleRareNonInheritedData.cpp:
941         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
942
943 2014-10-22  Carlos Garcia Campos  <cgarcia@igalia.com>
944
945         Unreviewed. Fix GStreamer debug build after r175050.
946
947         Explicitly include wtf/MainThread.h.
948
949         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
950
951 2014-10-22  Carlos Garcia Campos  <cgarcia@igalia.com>
952
953         [GStreamer] Do not use CachedResourceLoader, SecurityOrigin, ResourceBuffer and other WebCore types
954         https://bugs.webkit.org/show_bug.cgi?id=137064
955
956         Reviewed by Philippe Normand.
957
958         Move the media resource loader to a new class in WebCore/loader
959         that inherits from a PlatformMediaResourceLoader class defined in
960         the platform layer. The platform specific behaviour is implemented
961         using a client also defined in the platform layer, implemented by
962         every media backend, and used by the WebCore MediaResourceLoader.
963
964         * CMakeLists.txt: Add new files to compilation.
965         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
966         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
967         * WebCore.xcodeproj/project.pbxproj: Ditto.
968         * html/HTMLMediaElement.cpp:
969         (WebCore::HTMLMediaElement::mediaPlayerCreateResourceLoader):
970         Create a MediaResourceLoader.
971         (WebCore::HTMLMediaElement::mediaPlayerCORSMode): Deleted. This is
972         no longer used.
973         * html/HTMLMediaElement.h:
974         * loader/MediaResourceLoader.cpp: Added.
975         (WebCore::MediaResourceLoader::MediaResourceLoader):
976         (WebCore::MediaResourceLoader::~MediaResourceLoader):
977         (WebCore::MediaResourceLoader::start): Start a new load for the
978         given request and load options.
979         (WebCore::MediaResourceLoader::stop): Stop the load if needed.
980         (WebCore::MediaResourceLoader::setDefersLoading):
981         (WebCore::MediaResourceLoader::responseReceived): Handle CORS
982         access check and notify the client about the response.
983         (WebCore::MediaResourceLoader::dataReceived): Notify the client.
984         (WebCore::MediaResourceLoader::notifyFinished): Ditto.
985         (WebCore::MediaResourceLoader::getOrCreateReadBuffer): Ask the
986         client to create the read buffer.
987         * loader/MediaResourceLoader.h: Added.
988         * platform/graphics/MediaPlayer.cpp:
989         (WebCore::MediaPlayer::createResourceLoader): Call
990         mediaPlayerCreateResourceLoader() if there's a client.
991         * platform/graphics/MediaPlayer.h:
992         (WebCore::MediaPlayerClient::mediaPlayerCreateResourceLoader):
993         (WebCore::MediaPlayerClient::mediaPlayerCORSMode): Deleted.
994         * platform/graphics/PlatformMediaResourceLoader.h: Added.
995         (WebCore::PlatformMediaResourceLoaderClient::responseReceived):
996         (WebCore::PlatformMediaResourceLoaderClient::dataReceived):
997         (WebCore::PlatformMediaResourceLoaderClient::bufferReceived):
998         (WebCore::PlatformMediaResourceLoaderClient::accessControlCheckFailed):
999         (WebCore::PlatformMediaResourceLoaderClient::loadFailed):
1000         (WebCore::PlatformMediaResourceLoaderClient::loadFinished):
1001         (WebCore::PlatformMediaResourceLoaderClient::getOrCreateReadBuffer):
1002         (WebCore::PlatformMediaResourceLoader::~PlatformMediaResourceLoader):
1003         (WebCore::PlatformMediaResourceLoader::stop):
1004         (WebCore::PlatformMediaResourceLoader::setDefersLoading):
1005         (WebCore::PlatformMediaResourceLoader::didPassAccessControlCheck):
1006         (WebCore::PlatformMediaResourceLoader::PlatformMediaResourceLoader):
1007         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
1008         (webKitWebSrcStop): Also delete the PlatformMediaResourceLoader.
1009         (webKitWebSrcStart): Create a new resource loader using
1010         MediaPlayer::createResourceLoader() with a new
1011         CachedResourceStreamingClient as client.
1012         (webKitWebSrcNeedDataMainCb): Call setDefersLoading() for the
1013         resource loader if there's one.
1014         (webKitWebSrcEnoughDataMainCb): Ditto.
1015         (webKitSrcPassedCORSAccessCheck): Return didPassAccessControlCheck.
1016         (StreamingClient::handleResponseReceived): Remove the CORS check
1017         result parameter since that's now handled by MediaResourceLoader.
1018         (CachedResourceStreamingClient::CachedResourceStreamingClient):
1019         (CachedResourceStreamingClient::~CachedResourceStreamingClient):
1020         (CachedResourceStreamingClient::getOrCreateReadBuffer):
1021         (CachedResourceStreamingClient::responseReceived): Update didPassAccessControlCheck.
1022         (CachedResourceStreamingClient::dataReceived):
1023         (CachedResourceStreamingClient::accessControlCheckFailed): Log the
1024         error and stop the load.
1025         (CachedResourceStreamingClient::loadFailed): Log the error if it
1026         was not a cancellation.
1027         (CachedResourceStreamingClient::loadFinished):
1028         (ResourceHandleStreamingClient::didReceiveResponse):
1029         (CachedResourceStreamingClient::setDefersLoading): Deleted.
1030         (CachedResourceStreamingClient::notifyFinished): Deleted.
1031
1032 2014-10-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1033
1034         [GTK] Move GtkInputMethodFilter from Platform to WebKit2
1035         https://bugs.webkit.org/show_bug.cgi?id=137884
1036
1037         Reviewed by Gustavo Noronha Silva.
1038
1039         Remove GtkInputMethodFilter.
1040
1041         * PlatformGTK.cmake:
1042         * platform/gtk/GtkInputMethodFilter.cpp: Removed.
1043         * platform/gtk/GtkInputMethodFilter.h: Removed.
1044
1045 2014-10-22  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
1046
1047         Match spec for font-weight: bolder|lighter
1048         https://bugs.webkit.org/show_bug.cgi?id=137919
1049
1050         Reviewed by Andreas Kling.
1051
1052         This patch is a merge of Blink's
1053         https://chromiumcodereview.appspot.com/15994009
1054         
1055         Currently, bolder and lighter change font-weight in a non-compliant way.
1056         The spec (http://www.w3.org/TR/css3-fonts/#bolderlighter) defines
1057         exactly what the computed values should be given the inherited weight values,
1058         so we should match those.
1059         
1060         The removed FIXME's for selecting the next lightest/heaviest weight from
1061         the used font family seems to refer to behaviour from
1062         CSS1 (http://www.w3.org/TR/CSS1/#font-weight), while this is replaced
1063         with a simpler procedure for resolving bolder and lighter in font weights
1064         in CSS2 (http://www.w3.org/TR/CSS2/fonts.html#propdef-font-weight) and CSS3 (link above).
1065         
1066         and https://codereview.chromium.org/137813004
1067         
1068         According to http://dev.w3.org/csswg/css-fonts/#font-weight-prop, the computed
1069         weight of 'lighter' and 'bolder' are based on the inherited 'font-weight', so set
1070         that inherited weight before calculating 'lighter' and 'bolder'.
1071
1072         Tests: css3/font-weight-multiple-selectors.html
1073                css3/font-weight.html
1074
1075         * css/DeprecatedStyleBuilder.cpp:
1076         (WebCore::ApplyPropertyFontWeight::applyValue):
1077         * platform/graphics/FontDescription.cpp:
1078         (WebCore::FontDescription::lighterWeight):
1079         (WebCore::FontDescription::bolderWeight):
1080
1081 2014-10-22  Rohit Kumar  <kumar.rohit@samsung.com>
1082
1083         [GTK]: Fix unused parameter build warnings in WebCore/platform module
1084         https://bugs.webkit.org/show_bug.cgi?id=137921
1085
1086         Reviewed by Carlos Garcia Campos.
1087
1088         * platform/ScrollAnimatorNone.cpp:
1089         (WebCore::ScrollAnimatorNone::PerAxisData::PerAxisData):
1090         (WebCore::ScrollAnimatorNone::animationTimerFired):
1091
1092 2014-10-22  Dhi Aurrahman  <diorahman@rockybars.com>
1093
1094         Add relList to the anchor, area and link elements
1095         https://bugs.webkit.org/show_bug.cgi?id=137860
1096
1097         Reviewed by Darin Adler and Chris Dumez.
1098
1099         Add relList to reflect the rel content attribute for anchor[1],
1100         area[2] and link[3] elements.
1101
1102         [1] https://html.spec.whatwg.org/multipage/semantics.html#dom-a-rellist 
1103         [2] https://html.spec.whatwg.org/multipage/embedded-content.html#dom-area-rellist
1104         [3] https://html.spec.whatwg.org/multipage/semantics.html#dom-link-rellist
1105
1106         Tests: fast/dom/rel-list-gc.html
1107                fast/dom/rel-list.html
1108                perf/rel-list-remove.html
1109
1110         * CMakeLists.txt:
1111         * WebCore.vcxproj/WebCore.vcxproj:
1112         * WebCore.vcxproj/WebCore.vcxproj.filters:
1113         * WebCore.xcodeproj/project.pbxproj:
1114         * dom/SpaceSplitString.cpp:
1115         (WebCore::SpaceSplitString::set):
1116         * html/HTMLAnchorElement.cpp:
1117         (WebCore::HTMLAnchorElement::parseAttribute):
1118         (WebCore::HTMLAnchorElement::relList):
1119         (WebCore::HTMLAnchorElement::setRel): Deleted.
1120         * html/HTMLAnchorElement.h:
1121         * html/HTMLAnchorElement.idl:
1122         * html/HTMLAreaElement.idl:
1123         * html/HTMLLinkElement.cpp:
1124         (WebCore::HTMLLinkElement::parseAttribute):
1125         (WebCore::HTMLLinkElement::relList):
1126         * html/HTMLLinkElement.h:
1127         * html/HTMLLinkElement.idl:
1128         * html/RelList.cpp: Added.
1129         (WebCore::RelList::RelList):
1130         (WebCore::RelList::ref):
1131         (WebCore::RelList::deref):
1132         (WebCore::RelList::length):
1133         (WebCore::RelList::item):
1134         (WebCore::RelList::element):
1135         (WebCore::RelList::updateRelAttribute):
1136         (WebCore::RelList::containsInternal):
1137         (WebCore::RelList::value):
1138         (WebCore::RelList::setValue):
1139         * html/RelList.h: Added.
1140
1141 2014-10-21  Andy Estes  <aestes@apple.com>
1142
1143         One more iOS build fix after r175013.
1144
1145         * platform/graphics/ios/FontCacheIOS.mm:
1146         (WebCore::FontCache::createFontPlatformData):
1147
1148 2014-10-21  Benjamin Poulain  <bpoulain@apple.com>
1149
1150         CSS Rule features are ignored for nested CSS Selector lists
1151         https://bugs.webkit.org/show_bug.cgi?id=137908
1152
1153         Reviewed by Andreas Kling.
1154
1155         When Rule feature sets were collected, any selector list nested inside an other
1156         selector list was ignored when collecting properties of the CSS Selector.
1157
1158         As a result, style was not invalidated properly when any property listed in
1159         the nested selectors.
1160
1161         This patch fixes the issue by make RuleFeatureSet::collectFeaturesFromSelector()
1162         recursive, evaluating every chain of every selector lists.
1163
1164         Tests: fast/css/class-style-invalidation-optimization.html
1165                fast/css/direct-adjacent-style-sharing-1.html
1166                fast/css/direct-adjacent-style-sharing-2.html
1167                fast/css/direct-adjacent-style-sharing-3.html
1168                fast/css/id-style-invalidation-optimization.html
1169                fast/selectors/class-style-update-with-not.html
1170                fast/selectors/class-style-update-with-nth-child-of.html
1171                fast/selectors/class-style-update.html
1172
1173         * css/RuleFeature.cpp:
1174         (WebCore::recursivelyCollectFeaturesFromSelector):
1175         (WebCore::RuleFeatureSet::collectFeaturesFromSelector):
1176         * css/RuleFeature.h:
1177         * css/RuleSet.cpp:
1178         (WebCore::collectFeaturesFromRuleData):
1179
1180 2014-10-21  Tim Horton  <timothy_horton@apple.com>
1181
1182         Try to fix the iOS build after r175013.
1183
1184         * platform/graphics/ios/FontCacheIOS.mm:
1185         (WebCore::FontCache::createFontPlatformData):
1186
1187 2014-10-21  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1188
1189         Use std::unique_ptr | std::make_unique in FontCacheFoo
1190         https://bugs.webkit.org/show_bug.cgi?id=137905
1191
1192         Reviewed by Darin Adler.
1193
1194         Clean up PassOwnPtr|OwnPtr using std::unique_ptr|std::make_unique.
1195
1196         No new tests, no behavior changes.
1197
1198         * platform/graphics/FontCache.cpp:
1199         (WebCore::FontCache::getCachedFontPlatformData):
1200         * platform/graphics/FontCache.h:
1201         * platform/graphics/freetype/FontCacheFreeType.cpp:
1202         (WebCore::FontCache::createFontPlatformData):
1203         * platform/graphics/ios/FontCacheIOS.mm:
1204         (WebCore::FontCache::createFontPlatformData):
1205         * platform/graphics/mac/FontCacheMac.mm:
1206         (WebCore::FontCache::createFontPlatformData):
1207         * platform/graphics/win/FontCacheWin.cpp:
1208         (WebCore::FontCache::createFontPlatformData):
1209
1210 2014-10-21  Ada Chan  <adachan@apple.com>
1211
1212         Calling WebCore::Page::setMediaVolume(0) does not mute videos as expected.
1213         https://bugs.webkit.org/show_bug.cgi?id=137305
1214
1215         Reviewed by Darin Adler.
1216
1217         This was broken in http://trac.webkit.org/changeset/154970. To fix this (but not break
1218         GStreamer), remove the "if (m_volumeInitialized)" check before updating the MediaPlayer's
1219         volume to the value multiplied with the Page's mediaVolume. This should not affect GStreamer's
1220         behavior because MediaPlayerPrivateGStreamerBase::setStreamVolumeElement does nothing unless
1221         m_volumeInitialized is true.
1222
1223         * html/HTMLMediaElement.cpp:
1224         (WebCore::HTMLMediaElement::updateVolume):
1225
1226 2014-10-21  Jer Noble  <jer.noble@apple.com>
1227
1228         [EME][Mac] Update to match new AVStreamSession API and requirements.
1229         https://bugs.webkit.org/show_bug.cgi?id=137923
1230
1231         Reviewed by Eric Carlson.
1232
1233         The session identifier has moved from AVStreamDataParser to -[AVStreamSession contentProtectionSessionIdentifier]
1234         and the property is no longer KVObservable. A new notification key has been added in place of KVO.
1235
1236         Additionally, the requirements for using AVStreamDataParser with AVStreamSession have changed. It is now
1237         required that AVStreamDataParsers be added to an AVStreamSession before the 
1238         -streamSession:didProvideContentKeyRequestInitializationData:forTrackID delegate method is called. A
1239         -streamParserWillProvideContentKeyRequestInitializationData:forTrackID delegate has been added, and
1240         an AVStreamSession must be created and the AVStreamDataParser added to it during the scope of that delegate
1241         method.
1242
1243         To facilitate this, the MediaPlayerPrivateMediaSourceAVFObjC object will lazily create and own a AVStreamSession
1244         object when requested. The SourceBufferPrivateAVFObjC object will listen for the -willProvide delegate call
1245         and will add its AVStreamDataParser to that AVStreamSession when called.
1246
1247         The CDMSessionMediaSourceAVFObjC object is no longer responsible for creating the AVStreamSession, and because
1248         the session identifier has moved from many AVStreamDataParsers to a single AVStreamSession, the
1249         CDMSessionMediaSourceAVFObjCObserver class can become much simpler, as it only has to observe a single object.
1250
1251         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.h:
1252         * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
1253         (-[CDMSessionMediaSourceAVFObjCObserver dealloc]): Deleted.
1254         (-[CDMSessionMediaSourceAVFObjCObserver beginObserving:]): Deleted.
1255         (-[CDMSessionMediaSourceAVFObjCObserver stopObserving:]): Deleted.
1256         (-[CDMSessionMediaSourceAVFObjCObserver invalidate]): Deleted.
1257         (-[CDMSessionMediaSourceAVFObjCObserver observeValueForKeyPath:ofObject:change:context:]): Deleted.
1258         (-[CDMSessionMediaSourceAVFObjCObserver contentProtectionSessionIdentifierChanged:]): Added.
1259         (WebCore::CDMSessionMediaSourceAVFObjC::~CDMSessionMediaSourceAVFObjC): Call setStreamSession(nullptr).
1260         (WebCore::CDMSessionMediaSourceAVFObjC::releaseKeys): The sessionId is now a value in the dictionary, not the key.
1261         (WebCore::CDMSessionMediaSourceAVFObjC::update): No longer create an AVStreamSession.
1262         (WebCore::CDMSessionMediaSourceAVFObjC::setStreamSession): Add and remove observers as appropriate.
1263         (WebCore::CDMSessionMediaSourceAVFObjC::addSourceBuffer): No longer add or remove parsers from AVStreamSessions.
1264         (WebCore::CDMSessionMediaSourceAVFObjC::removeSourceBuffer): Ditto.
1265         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
1266         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1267         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::hasStreamSession): Simple getter.
1268         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::streamSession): Lazy initializing getter.
1269         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setCDMSession): Call setStreamSession().
1270         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
1271         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
1272         (-[WebAVStreamDataParserListener streamParserWillProvideContentKeyRequestInitializationData:forTrackID:]): Synchronously pass to SourceBufferPrivateAVFObjC.
1273         (WebCore::SourceBufferPrivateAVFObjC::willProvideContentKeyRequestInitializationDataForTrackID): Add the parser to an AVStreamSession.
1274         (WebCore::SourceBufferPrivateAVFObjC::didProvideContentKeyRequestInitializationDataForTrackID): Check the trackId.
1275         * platform/mac/SoftLinking.h:
1276
1277 2014-10-21  Jaehun Lim  <ljaehun.lim@samsung.com>
1278
1279         'true' isn't a valid value for justify-self
1280         https://bugs.webkit.org/show_bug.cgi?id=137913
1281
1282         Reviewed by Andreas Kling.
1283
1284         Merged from Blink (patch by dstockwell):
1285         <https://src.chromium.org/viewvc/blink?view=rev&revision=174638>
1286
1287         CSS Box Alignment Module Level 3:
1288         http://dev.w3.org/csswg/css-align/#justify-self-property
1289
1290         No new tests, modify existing test case.
1291
1292         * css/CSSParser.cpp:
1293         (WebCore::CSSParser::parseJustifySelf):
1294
1295 2014-10-21  Michael Saboff  <msaboff@apple.com>
1296
1297         Add operator==(PropertyName, const char*)
1298         https://bugs.webkit.org/show_bug.cgi?id=137925
1299
1300         Reviewed by Mark Lam.
1301
1302         Use new == operator to compare a PropertyName with a string literal.
1303
1304         * bindings/js/JSHTMLDocumentCustom.cpp:
1305         (WebCore::JSHTMLDocument::getOwnPropertySlot):
1306
1307 2014-10-21  Chris Dumez  <cdumez@apple.com>
1308
1309         Unreviewed iOS build fix after r174921.
1310
1311         Export new symbol after function rename.
1312
1313         * WebCore.exp.in:
1314         * WebCore.order:
1315
1316 2014-10-21  Chris Dumez  <cdumez@apple.com>
1317
1318         Unreviewed iOS build fix after r174921.
1319
1320         Remove symbol from export files that no longer exists.
1321
1322         * WebCore.exp.in:
1323         * WebCore.order:
1324
1325 2014-10-21  peavo@outlook.com  <peavo@outlook.com>
1326
1327         [Curl] Optimization; avoid string reallocation.
1328         https://bugs.webkit.org/show_bug.cgi?id=137920
1329
1330         Reviewed by Brent Fulgham.
1331
1332         Profiling reveals that the cookiesForDOM function is spending time on removing a character from a string.
1333
1334         * platform/network/curl/CookieJarCurl.cpp:
1335         (WebCore::domainMatch):
1336         (WebCore::addMatchingCurlCookie):
1337
1338 2014-10-21  Joanmarie Diggs  <jdiggs@igalia.com>
1339
1340         AX: [ATK] CSS-generated text content not exposed to assistive technologies
1341         https://bugs.webkit.org/show_bug.cgi?id=137669
1342
1343         Reviewed by Chris Fleizach.
1344
1345         Do not use a text iterator to get the text for elements which include
1346         pseudo elements.
1347
1348         Test: accessibility/css-content-attribute.html
1349
1350         * accessibility/AccessibilityRenderObject.cpp:
1351         (WebCore::AccessibilityRenderObject::textUnderElement):
1352
1353 2014-10-21  Chris Dumez  <cdumez@apple.com>
1354
1355         REGRESSION(r174676): It broke the !ENABLE(VIDEO) build
1356         https://bugs.webkit.org/show_bug.cgi?id=137916
1357
1358         Reviewed by Csaba Osztrogon√°c.
1359
1360         Fix the !ENABLE(VIDEO) build by adding an #if ENABLE(VIDEO) where
1361         needed.
1362
1363         * rendering/RenderLayerBacking.cpp:
1364         (WebCore::RenderLayerBacking::isDirectlyCompositedImage):
1365
1366 2014-10-21  Zalan Bujtas  <zalan@apple.com>
1367
1368         REGRESSION: Google Search (mobile) video thumbnails are too large.
1369         https://bugs.webkit.org/show_bug.cgi?id=137895
1370
1371         Reviewed by Simon Fraser.
1372
1373         This patch fixes layer clipping when an ancestor layer has border-radius clipping.
1374
1375         In cases, where the current layer has non-radius cliprect, while an ancestor layer
1376         has border-radius clipping, we only use the border-radius rect to clip.
1377
1378         Test: fast/clip/overflow-hidden-with-border-radius-overflow-clipping-parent.html
1379
1380         * rendering/RenderLayer.cpp:
1381         (WebCore::RenderLayer::clipToRect):
1382         (WebCore::RenderLayer::restoreClip):
1383         (WebCore::RenderLayer::collectFragments):
1384         (WebCore::RenderLayer::calculateClipRects):
1385         * rendering/RenderLayer.h:
1386         (WebCore::ClipRect::ClipRect):
1387         (WebCore::ClipRect::effectedByRadius):
1388         (WebCore::ClipRect::setEffectedByRadius):
1389         (WebCore::ClipRect::operator==):
1390         (WebCore::ClipRect::operator!=):
1391         (WebCore::ClipRect::intersect):
1392         (WebCore::ClipRect::hasRadius): Deleted.
1393         (WebCore::ClipRect::setHasRadius): Deleted.
1394
1395 2014-10-20  Michael Saboff  <msaboff@apple.com>
1396
1397         Don't create cached functions for HTMLDocument.write*()
1398         https://bugs.webkit.org/show_bug.cgi?id=137906
1399
1400         Reviewed by Darin Adler.
1401
1402         Made it so that JSHTMLDocument::write() and ::writeln() are always created for every prototype.
1403         This is similar to the change in r174847.
1404
1405         This change is alread covered by the tests:
1406         LayoutTests/http/tests/security/aboutBlank/security-context-grandchildren-write-lexical.html
1407         LayoutTests/http/tests/security/aboutBlank/security-context-grandchildren-writeln-lexical.html
1408         LayoutTests/http/tests/security/aboutBlank/security-context-write.html
1409         LayoutTests/http/tests/security/aboutBlank/security-context-writeln.html
1410         LayoutTests/http/tests/xmlhttprequest/request-from-popup.html
1411         LayoutTests/http/tests/navigation/new-window-redirect-history.html
1412         LayoutTests/http/tests/misc/window-open-then-write.html
1413
1414         * bindings/js/JSHTMLDocumentCustom.cpp:
1415         (WebCore::JSHTMLDocument::getOwnPropertySlot):
1416         * html/HTMLDocument.idl:
1417
1418 2014-10-21  Chris Dumez  <cdumez@apple.com>
1419
1420         REGRESSION(r174676): It broke the !ENABLE(VIDEO) build
1421         https://bugs.webkit.org/show_bug.cgi?id=137916
1422
1423         Unreviewed build fix. Add missing header include.
1424
1425         * rendering/RenderLayerBacking.cpp:
1426
1427 2014-10-21  Jer Noble  <jer.noble@apple.com>
1428
1429         REGRESSION (r170808): Volume slider in built-in media controls only changes volume when thumb is released, not while dragging
1430         https://bugs.webkit.org/show_bug.cgi?id=137805
1431
1432         Reviewed by Dan Bernstein.
1433
1434         Test: media/video-volume-slider-drag.html
1435
1436         Respond to the 'input' event rather than the 'change' event for the volume slider, so that
1437         volume changes are continuous during drag operations.
1438
1439         Also listen for both 'input' and 'change' events for the timeline slider, doing fastSeek()
1440         during 'input' and setting an explicit currentTime during 'change'. This is the same behavior
1441         as current, but using 'change' instead of 'mouseup' to do the final currentTime change.
1442
1443         * Modules/mediacontrols/mediaControlsApple.js:
1444         (Controller.prototype.createControls):
1445         (Controller.prototype.handleTimelineInput):
1446         (Controller.prototype.handleTimelineChange):
1447         (Controller.prototype.handleTimelineMouseUp):
1448         (Controller.prototype.handleVolumeSliderInput):
1449         (Controller.prototype.handlePlayButtonClicked): Deleted.
1450         (Controller.prototype.handleMaxButtonClicked): Deleted.
1451
1452 2014-10-21  Manuel Rego Casasnovas  <rego@igalia.com>
1453
1454         ASSERTION FAILED: !gridWasPopulated() in WebCore::RenderGrid::placeItemsOnGrid
1455         https://bugs.webkit.org/show_bug.cgi?id=136939
1456
1457         Reviewed by Darin Adler.
1458
1459         In some particular situations computeIntrinsicLogicalWidths() is called
1460         in the middle of layoutGridItems(). In these cases we do not need to
1461         populate the grid again, so we should avoid calling placeItemsOnGrid().
1462         In addition, we do not need to clean the grid either, as that will be
1463         done later by layoutGridItems().
1464
1465         Test: fast/css-grid-layout/grid-was-populated-assert.html
1466
1467         * rendering/RenderGrid.cpp:
1468         (WebCore::RenderGrid::computeIntrinsicLogicalWidths): Avoid calls to
1469         placeItemsOnGrid() and clearGrid() if the grid was already populated.
1470         * rendering/RenderGrid.h: Move gridWasPopulated() header out of the
1471         debug ifdefs.
1472
1473 2014-10-21  Zan Dobersek  <zdobersek@igalia.com>
1474
1475         [Cairo] Make dashPattern, dotPattern in GraphicsContext::setPlatformStrokeStyle() const
1476         https://bugs.webkit.org/show_bug.cgi?id=137912
1477
1478         Reviewed by Carlos Garcia Campos.
1479
1480         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1481         (WebCore::GraphicsContext::setPlatformStrokeStyle): Make the two static variables
1482         constants since their value doesn't change after initialization.
1483
1484 2014-10-21  Carlos Garcia Campos  <cgarcia@igalia.com>
1485
1486         [GTK] Several labels are white instead of black
1487         https://bugs.webkit.org/show_bug.cgi?id=137803
1488
1489         Reviewed by Martin Robinson.
1490
1491         Recent GTK+ versions require to explicitly set the state before
1492         getting a color.
1493
1494         * rendering/RenderThemeGtk.cpp:
1495         (WebCore::styleColor): Helper function to get a color from a
1496         GtkStylecontext that explicitly sets the state before getting the color.
1497         (WebCore::RenderThemeGtk::platformActiveSelectionBackgroundColor): Use styleColor().
1498         (WebCore::RenderThemeGtk::platformInactiveSelectionBackgroundColor): Ditto.
1499         (WebCore::RenderThemeGtk::platformActiveSelectionForegroundColor): Ditto.
1500         (WebCore::RenderThemeGtk::platformInactiveSelectionForegroundColor): Ditto.
1501         (WebCore::RenderThemeGtk::platformActiveListBoxSelectionBackgroundColor): Ditto.
1502         (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionBackgroundColor): Ditto.
1503         (WebCore::RenderThemeGtk::platformActiveListBoxSelectionForegroundColor): Ditto.
1504         (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionForegroundColor): Ditto.
1505         (WebCore::RenderThemeGtk::systemColor): Ditto.
1506
1507 2014-10-20  YongGeol Jung  <yg48.jung@samsung.com>
1508
1509         [Coordinated Graphics] '-webkit-mask-image: -webkit-gradient' doesn't work for AC layer.
1510         https://bugs.webkit.org/show_bug.cgi?id=125326
1511
1512         Reviewed by Gyuyoung Kim.
1513
1514         Mask layer hasn't requested to synchronize with AC layer in CoordinatedGraphics so far.
1515         That's why the mask layer isn't shown under CoordinatedGraphics.
1516         Thus this patch lets the mask layer synchronize with the AC layer whenever AC layer is updated.
1517
1518         Below layout test case is related to this issue when --pixel test is enabled.
1519         Unfortunately EFL WebKitTestRunner doesn't support AC mode yet.
1520         When EFL test framework supports AC mode, the test will be passed.
1521
1522         Test: compositing/masks/mask-of-clipped-layer.html
1523
1524         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
1525         (WebCore::CoordinatedGraphicsLayer::syncPendingStateChangesIncludingSubLayers):
1526
1527 2014-10-17  Jeffrey Pfau  <jpfau@apple.com>
1528
1529         Ensure attached frame count doesn't exceed the maximum allowed frames
1530         https://bugs.webkit.org/show_bug.cgi?id=136457
1531
1532         Reviewed by Alexey Proskuryakov.
1533
1534         Test: fast/frames/exponential-frames.html
1535
1536         * html/HTMLFrameElementBase.cpp:
1537         (WebCore::HTMLFrameElementBase::isURLAllowed):
1538
1539 2014-10-20  Chris Dumez  <cdumez@apple.com>
1540
1541         ResourceRequest deserialization unnecessarily calls partitionName() on encoded cache partition
1542         https://bugs.webkit.org/show_bug.cgi?id=137797
1543
1544         Reviewed by Darin Adler.
1545
1546         ResourceRequest deserialization was unnecessarily calling partitionName()
1547         on the decoded cache partition. In the deserialization case, we already
1548         know the cache partition is a valid partition name so we can bypass the
1549         call to partitionName() (which is fairly expensive) for performance.
1550
1551         This patch adds a setDomainForCachePartion() method to ResourceRequest
1552         that calls partitionName() on the domain argument, and moves all the
1553         callers of setCachedPartition() to this new setter, except
1554         ArgumentCoder<ResourceRequest>::decode().
1555
1556         This patch updates the setCachedPartition() to merely set the
1557         m_cachePartition member, without calling partitionName() on the
1558         argument. There is also a new assertion in place to make sure the
1559         argument is a valid partition name.
1560
1561         No new tests, no behavior change.
1562
1563         * html/DOMURL.cpp:
1564         (WebCore::DOMURL::revokeObjectURL):
1565         * inspector/InspectorPageAgent.cpp:
1566         (WebCore::InspectorPageAgent::cachedResource):
1567         * inspector/InspectorResourceAgent.cpp:
1568         (WebCore::InspectorResourceAgent::replayXHR):
1569         * loader/FrameLoader.cpp:
1570         (WebCore::FrameLoader::loadURL):
1571         * loader/archive/cf/LegacyWebArchive.cpp:
1572         (WebCore::LegacyWebArchive::create):
1573         * loader/cache/CachedResourceLoader.cpp:
1574         (WebCore::CachedResourceLoader::requestUserCSSStyleSheet):
1575         (WebCore::CachedResourceLoader::requestResource):
1576         * loader/cache/MemoryCache.cpp:
1577         (WebCore::MemoryCache::addImageToCache):
1578         (WebCore::MemoryCache::removeImageFromCache):
1579         * loader/cache/MemoryCache.h:
1580         * page/SecurityOrigin.cpp:
1581         (WebCore::SecurityOrigin::domainForCachePartition):
1582         (WebCore::SecurityOrigin::cachePartition): Deleted.
1583         Rename cachePartition() getter to domainForCachePartition() to make it
1584         clear it returns a domain and not a partition name. As such, the caller
1585         should then use ResourceRequest::setDomainForCachePartition(), not
1586         setCachePartition().
1587
1588         * page/SecurityOrigin.h:
1589         * platform/network/cf/ResourceRequest.h:
1590         (WebCore::ResourceRequest::setCachePartition):
1591         (WebCore::ResourceRequest::setDomainForCachePartition):
1592
1593 2014-10-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1594
1595         Tighten XMLHttpRequest setRequestHeader value check
1596         https://bugs.webkit.org/show_bug.cgi?id=128593
1597
1598         Reviewed by Darin Adler.
1599
1600         Test: http/tests/xmlhttprequest/set-bad-headervalue.html
1601
1602         * platform/network/HTTPParsers.cpp:
1603         (WebCore::isValidHTTPHeaderValue): Updated header values check according RFC 7230.
1604         (WebCore::isValidHTTPToken): Renamed variable name and updated RFC related comment.
1605
1606 2014-10-20  Michael Saboff  <msaboff@apple.com>
1607
1608         Make post checkin suggested changes to r174847
1609         https://bugs.webkit.org/show_bug.cgi?id=137885
1610
1611         Reviewed by Mark Lam.
1612
1613         Eliminated the creation of a temporary Identifier when comparing propertyName to "open".
1614         Made the suggested post checkin change to put the declaration of "entry" into the if.
1615
1616         * bindings/js/JSHTMLDocumentCustom.cpp:
1617         (WebCore::JSHTMLDocument::getOwnPropertySlot):
1618
1619 2014-10-20  Chris Dumez  <cdumez@apple.com>
1620
1621         Use is<>() / downcast<>() for SpinButtonElement
1622         https://bugs.webkit.org/show_bug.cgi?id=137896
1623
1624         Reviewed by Gyuyoung Kim.
1625
1626         Use is<>() / downcast<>() for SpinButtonElement instead of
1627         isSpinButtonElement() / static_cast for consistency with the rest of
1628         the code and for safety.
1629
1630         No new tests, no behavior change.
1631
1632         * accessibility/AccessibilityRenderObject.cpp:
1633         (WebCore::AccessibilityRenderObject::addTextFieldChildren):
1634         * html/shadow/SpinButtonElement.h:
1635         (isType):
1636         * rendering/RenderTheme.cpp:
1637         (WebCore::RenderTheme::isSpinUpButtonPartPressed):
1638         (WebCore::RenderTheme::isHovered):
1639         (WebCore::RenderTheme::isSpinUpButtonPartHovered):
1640
1641 2014-10-20  Roger Fong  <roger_fong@apple.com>
1642
1643         Use glFlush instead of glFinish when drawing WebGL output to screen.
1644         https://bugs.webkit.org/show_bug.cgi?id=137897.
1645         <rdar://problem/15846550>
1646
1647         Reviewed by Brent Fulgham.
1648
1649         Passes all conformance tests.
1650         Performance tested by http://threejs.org/examples/#webgl_performance and Unity WebGL performance tests.
1651
1652         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
1653         (WebCore::GraphicsContext3D::prepareTexture):
1654         Use glFlush instead of glFinish. glFinish is a blocking operation pushed out queued up WebGL operations and then waits until 
1655         every operation has completed before returning and every pixel has been updated. This causes severe performance problems,
1656         about a 10 fps difference on http://threejs.org/examples/#webgl_performance. glFlush, like glFinish,
1657         forces all queued WebGL operations to take place, but returns immediately. Switching to glFlush does not seem
1658         make our rendering quality any worse for the handful of sites I've tested and makes our performance on WebGL much better.
1659         However, we should continue to be on the watch for any potential rendering issues after this lands.
1660
1661 2014-10-20  Benjamin Poulain  <bpoulain@apple.com>
1662
1663         Generalize the compilation of :not() to support arbitrary selector lists
1664         https://bugs.webkit.org/show_bug.cgi?id=137843
1665
1666         Reviewed by Andreas Kling.
1667
1668         This builds :not() on top of the code created for :nth-child(An+B of selectorList)
1669         to support any selector list.
1670
1671         The tests for the JIT were added previously:
1672         -not-boundaries.html
1673         -not-backtracking.html
1674
1675         * cssjit/SelectorCompiler.cpp:
1676         (WebCore::SelectorCompiler::addPseudoClassType):
1677         Any :not() of a selector is handled through a simple selector list. Cases like
1678         :not(foo, bar) simply generate not([fragmentFoo, bragmentBar]).
1679
1680         Old cases like :not(foo):not(bar) simply add those cases to the selector list,
1681         generating not([fragmentFoo, bragmentBar]).
1682
1683         (WebCore::SelectorCompiler::minimumRegisterRequirements):
1684         Register pressure is now tracked through computeBacktrackingMemoryRequirements.
1685
1686         (WebCore::SelectorCompiler::hasAnyCombinators):
1687         (WebCore::SelectorCompiler::computeBacktrackingMemoryRequirements):
1688         (WebCore::SelectorCompiler::computeBacktrackingInformation):
1689         Abstract the code creating Selector Lists from :nth-child(of). Use that for :not()
1690         and  :nth-child(of).
1691
1692         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesNotPseudoClass):
1693
1694 2014-10-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1695
1696         Use std::unique_ptr<>|make_unique<> in PluginView::scheduleRequest()
1697         https://bugs.webkit.org/show_bug.cgi?id=137874
1698
1699         Reviewed by Andreas Kling.
1700
1701         No new tests, no behavior change.
1702
1703         * plugins/PluginView.cpp:
1704         (WebCore::PluginView::requestTimerFired):
1705         (WebCore::PluginView::scheduleRequest): Replace PassOwnPtr with std::unique_ptr.
1706         (WebCore::PluginView::load): Create PluginRequest using std::make_unique.
1707         * plugins/PluginView.h:
1708
1709 2014-10-20  Beth Dakin  <bdakin@apple.com>
1710
1711         Speculative build fix.
1712
1713         * platform/spi/mac/NSViewSPI.h:
1714
1715 2014-10-20  Beth Dakin  <bdakin@apple.com>
1716
1717         Add support for action menus
1718         https://bugs.webkit.org/show_bug.cgi?id=137891
1719         rdar://problem/18451638
1720         rdar://problem/18694470
1721
1722         Reviewed by Anders Carlsson.
1723
1724         New SPI that is needed for this.
1725         * WebCore.exp.in:
1726         * WebCore.xcodeproj/project.pbxproj:
1727         * platform/spi/mac: Added.
1728         * platform/spi/mac/NSViewSPI.h: Added.
1729
1730 2014-10-20  Dean Jackson  <dino@apple.com>
1731
1732         [Mac] Support "inverted-colors" and "monochrome" media feature.
1733         https://bugs.webkit.org/show_bug.cgi?id=137535
1734         <rdar://problem/18586398>
1735
1736         Rolling out the Windows part of this to fix the build.
1737
1738         * platform/win/PlatformScreenWin.cpp:
1739         (WebCore::screenHasInvertedColors): Revert to a stub function.
1740
1741 2014-10-20  Chris Dumez  <cdumez@apple.com>
1742
1743         Unreviewed EFL / GTK build fix after r174898.
1744
1745         Add missing header include.
1746
1747         * accessibility/AccessibilityARIAGrid.cpp:
1748
1749 2014-10-20  Dean Jackson  <dino@apple.com>
1750
1751         [Mac] Support "inverted-colors" and "monochrome" media feature.
1752         https://bugs.webkit.org/show_bug.cgi?id=137535
1753         <rdar://problem/18586398>
1754
1755         Reviewed by Brent Fulgham.
1756
1757         Add a new media query from CSS Level 4, "inverted-colors", and
1758         implement the Apple backends for the "monochrome" media query.
1759
1760         The platform code went into PlatformScreenMac, which already
1761         had a screenIsMonochrome method. This now calls into Core
1762         Graphics via SPI. I added a screenHasInvertedColors
1763         method which tests for inversion. On iOS, there is public API
1764         for both queries. On Windows, we try to use CoreGraphics.
1765
1766         At the moment neither of these media queries re-evaluate
1767         automatically if the user changes their mode. The page will
1768         need to be reloaded. It is possible to detect a change on iOS,
1769         but not OS X.
1770         https://bugs.webkit.org/show_bug.cgi?id=137868
1771
1772         I decided to not add an ENABLE flag for this, mostly because it
1773         is such an isolated feature and seems very unlikely to be
1774         controversial. I don't expect the syntax to change. (I'm sure
1775         this comment will come back to haunt me.)
1776
1777         Testing this automatically is slightly tricky. We'd need
1778         to expose SPI to invert the user's screen, but then we get
1779         inverted images from our testing which could interfere with concurrent
1780         operations. Instead I've included some tests that exercise
1781         the "false" parts of the media query, with explanations as
1782         to why they would fail if the display is inverted.
1783
1784         Tests: fast/media/mq-inverted-colors.html
1785                fast/media/mq-monochrome.html
1786
1787         * css/CSSValueKeywords.in: Add the "inverted" keyword for "inverted-colors".
1788         * css/MediaFeatureNames.h: Add the "inverted-colors" feature name.
1789         * css/MediaQueryEvaluator.cpp:
1790         (WebCore::inverted_colorsMediaFeatureEval): Implementation of the new media query.
1791         * css/MediaQueryExp.cpp:
1792         (WebCore::featureWithCSSValueID): The new query takes an id...
1793         (WebCore::featureWithoutValue): ... or no value.
1794         * platform/PlatformScreen.h: Add "screenHasInvertedColors".
1795         * platform/efl/PlatformScreenEfl.cpp:
1796         (WebCore::screenHasInvertedColors): Stub implementation.
1797         * platform/gtk/PlatformScreenGtk.cpp:
1798         (WebCore::screenHasInvertedColors): Ditto.
1799         * platform/ios/PlatformScreenIOS.mm:
1800         (WebCore::screenHasInvertedColors): Call into the platform accessibility API.
1801         (WebCore::screenIsMonochrome): Ditto.
1802         * platform/mac/PlatformScreenMac.mm:
1803         (WebCore::screenIsMonochrome): Call into the CoreGraphics SPI.
1804         (WebCore::screenHasInvertedColors): Call into the CoreGraphics SPI.
1805         * platform/win/PlatformScreenWin.cpp:
1806         (WebCore::screenHasInvertedColors): Call into CoreGraphics if we're using it.
1807
1808 2014-10-20  Chris Dumez  <cdumez@apple.com>
1809
1810         Use is<>() / downcast<>() for Accessibility objects
1811         https://bugs.webkit.org/show_bug.cgi?id=137286
1812
1813         Reviewed by Darin Adler.
1814
1815         Use is<>() / downcast<>() for Accessibility objects and clean up the
1816         surrounding code.
1817
1818         No new tests, no behavior change.
1819
1820         * accessibility/AXObjectCache.cpp:
1821         (WebCore::AXObjectCache::focusedImageMapUIElement):
1822         (WebCore::AXObjectCache::notificationPostTimerFired):
1823         * accessibility/AccessibilityARIAGrid.cpp:
1824         (WebCore::AccessibilityARIAGrid::addTableCellChild):
1825         (WebCore::AccessibilityARIAGrid::addChildren):
1826         * accessibility/AccessibilityARIAGridCell.cpp:
1827         (WebCore::AccessibilityARIAGridCell::parentTable):
1828         (WebCore::AccessibilityARIAGridCell::rowIndexRange):
1829         * accessibility/AccessibilityARIAGridRow.cpp:
1830         (WebCore::AccessibilityARIAGridRow::disclosedRows):
1831         (WebCore::AccessibilityARIAGridRow::disclosedByRow):
1832         (WebCore::AccessibilityARIAGridRow::parentTable):
1833         * accessibility/AccessibilityARIAGridRow.h:
1834         * accessibility/AccessibilityImageMapLink.cpp:
1835         (WebCore::AccessibilityImageMapLink::imageMapLinkRenderer):
1836         * accessibility/AccessibilityImageMapLink.h:
1837         * accessibility/AccessibilityList.h:
1838         * accessibility/AccessibilityListBox.cpp:
1839         (WebCore::AccessibilityListBox::setSelectedChildren):
1840         (WebCore::AccessibilityListBox::selectedChildren):
1841         (WebCore::AccessibilityListBox::listBoxOptionAccessibilityObject):
1842         * accessibility/AccessibilityListBox.h:
1843         * accessibility/AccessibilityListBoxOption.h:
1844         * accessibility/AccessibilityMenuList.cpp:
1845         (WebCore::AccessibilityMenuList::addChildren):
1846         (WebCore::AccessibilityMenuList::didUpdateActiveOption):
1847         * accessibility/AccessibilityMenuList.h:
1848         * accessibility/AccessibilityMenuListOption.h:
1849         * accessibility/AccessibilityMenuListPopup.cpp:
1850         (WebCore::AccessibilityMenuListPopup::menuListOptionAccessibilityObject):
1851         * accessibility/AccessibilityMenuListPopup.h:
1852         * accessibility/AccessibilityMockObject.h:
1853         * accessibility/AccessibilityNodeObject.cpp:
1854         (WebCore::AccessibilityNodeObject::textUnderElement):
1855         * accessibility/AccessibilityNodeObject.h:
1856         * accessibility/AccessibilityObject.cpp:
1857         (WebCore::appendChildrenToArray):
1858         (WebCore::AccessibilityObject::scrollViewAncestor):
1859         * accessibility/AccessibilityObject.h:
1860         * accessibility/AccessibilityRenderObject.cpp:
1861         (WebCore::AccessibilityRenderObject::getDocumentLinks):
1862         (WebCore::AccessibilityRenderObject::handleActiveDescendantChanged):
1863         (WebCore::AccessibilityRenderObject::inheritsPresentationalRole):
1864         (WebCore::AccessibilityRenderObject::addImageMapChildren):
1865         (WebCore::AccessibilityRenderObject::addTextFieldChildren):
1866         (WebCore::AccessibilityRenderObject::remoteSVGRootElement):
1867         (WebCore::AccessibilityRenderObject::ariaSelectedRows):
1868         * accessibility/AccessibilityRenderObject.h:
1869         * accessibility/AccessibilitySVGRoot.h:
1870         * accessibility/AccessibilityScrollView.cpp:
1871         (WebCore::AccessibilityScrollView::addChildScrollbar):
1872         * accessibility/AccessibilityScrollView.h:
1873         * accessibility/AccessibilityScrollbar.h:
1874         * accessibility/AccessibilitySlider.cpp:
1875         (WebCore::AccessibilitySlider::addChildren):
1876         * accessibility/AccessibilitySlider.h:
1877         * accessibility/AccessibilitySpinButton.cpp:
1878         (WebCore::AccessibilitySpinButton::addChildren):
1879         (WebCore::AccessibilitySpinButtonPart::press):
1880         * accessibility/AccessibilitySpinButton.h:
1881         * accessibility/AccessibilityTable.cpp:
1882         (WebCore::AccessibilityTable::addChildren):
1883         (WebCore::AccessibilityTable::addChildrenFromSection):
1884         (WebCore::AccessibilityTable::headerContainer):
1885         (WebCore::AccessibilityTable::columnHeaders):
1886         (WebCore::AccessibilityTable::rowHeaders):
1887         (WebCore::AccessibilityTable::cellForColumnAndRow):
1888         * accessibility/AccessibilityTable.h:
1889         Make isAccessibilityTable() public and mark as final so that callers
1890         can benefit from tighter typing, as isAccessibilityTable() is
1891         stricter than isTable(). isTable() indicates that the object is an
1892         AccessibilityTable and is equivalent to is<AccessibilityTable>(object).
1893         isAccessibilityTable() is equivalent to "isTable() && renderer()".
1894
1895         * accessibility/AccessibilityTableCell.cpp:
1896         (WebCore::AccessibilityTableCell::parentTable):
1897         * accessibility/AccessibilityTableCell.h:
1898         * accessibility/AccessibilityTableColumn.cpp:
1899         (WebCore::AccessibilityTableColumn::headerObject):
1900         (WebCore::AccessibilityTableColumn::addChildren):
1901         * accessibility/AccessibilityTableColumn.h:
1902         * accessibility/AccessibilityTableHeaderContainer.cpp:
1903         (WebCore::AccessibilityTableHeaderContainer::addChildren):
1904         * accessibility/AccessibilityTableRow.cpp:
1905         (WebCore::AccessibilityTableRow::parentTable):
1906         (WebCore::AccessibilityTableRow::headerObject):
1907         * accessibility/AccessibilityTableRow.h:
1908         * accessibility/atk/WebKitAccessibleInterfaceSelection.cpp:
1909         (webkitAccessibleSelectionClearSelection):
1910         (webkitAccessibleSelectionSelectAllSelection):
1911         * accessibility/atk/WebKitAccessibleInterfaceTable.cpp:
1912         (core):
1913         (cell):
1914         (cellAtIndex):
1915         (webkitAccessibleTableGetIndexAt):
1916         (webkitAccessibleTableGetNColumns):
1917         (webkitAccessibleTableGetNRows):
1918         (webkitAccessibleTableGetColumnHeader):
1919         (webkitAccessibleTableGetRowHeader):
1920         * accessibility/atk/WebKitAccessibleInterfaceTableCell.cpp:
1921         (webkitAccessibleTableCellGetColumnHeaderCells):
1922         (webkitAccessibleTableCellGetRowHeaderCells):
1923         (webkitAccessibleTableCellGetColumnSpan):
1924         (webkitAccessibleTableCellGetRowSpan):
1925         (webkitAccessibleTableCellGetPosition):
1926         * accessibility/ios/AccessibilityObjectIOS.mm:
1927         (WebCore::AccessibilityObject::accessibilityPasswordFieldLength):
1928         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
1929         (-[WebAccessibilityObjectWrapper convertPointToScreenSpace:]):
1930         (-[WebAccessibilityObjectWrapper convertRectToScreenSpace:]):
1931         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
1932         (AXAttributeStringSetElement):
1933         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
1934         (-[WebAccessibilityObjectWrapper convertPointToScreenSpace:]):
1935         (-[WebAccessibilityObjectWrapper subrole]):
1936         (-[WebAccessibilityObjectWrapper roleDescription]):
1937         (-[WebAccessibilityObjectWrapper scrollViewParent]):
1938         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
1939         (-[WebAccessibilityObjectWrapper accessibilityShowContextMenu]):
1940         (-[WebAccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
1941         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
1942         * inspector/InspectorDOMAgent.cpp:
1943         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
1944         * rendering/RenderMenuList.cpp:
1945         (RenderMenuList::didUpdateActiveOption):
1946
1947 2014-10-20  Joseph Pecoraro  <pecoraro@apple.com>
1948
1949         Web Inspector: Generate all Inspector domains together in JavaScriptCore
1950         https://bugs.webkit.org/show_bug.cgi?id=137748
1951
1952         Reviewed by Brian Burg.
1953
1954         After moving the json files into JavaScriptCore update the includes,
1955         and names of functions that were previously prefixed.
1956
1957         * CMakeLists.txt:
1958         * DerivedSources.make:
1959         * ForwardingHeaders/inspector/InspectorBackendDispatchers.h: Added.
1960         * ForwardingHeaders/inspector/InspectorFrontendDispatchers.h: Added.
1961         * ForwardingHeaders/inspector/InspectorJSBackendDispatchers.h: Removed.
1962         * ForwardingHeaders/inspector/InspectorJSFrontendDispatchers.h: Removed.
1963         * ForwardingHeaders/inspector/InspectorJSProtocolTypes.h: Removed.
1964         * ForwardingHeaders/inspector/InspectorProtocolTypesBase.h: Added.
1965         * WebCore.vcxproj/WebCore.vcxproj:
1966         * WebCore.vcxproj/WebCore.vcxproj.filters:
1967         * WebCore.vcxproj/copyForwardingHeaders.cmd:
1968         * WebCore.xcodeproj/project.pbxproj:
1969         * inspector/CommandLineAPIHost.cpp:
1970         * inspector/InspectorApplicationCacheAgent.cpp:
1971         * inspector/InspectorApplicationCacheAgent.h:
1972         * inspector/InspectorCSSAgent.cpp:
1973         * inspector/InspectorCSSAgent.h:
1974         * inspector/InspectorController.cpp:
1975         * inspector/InspectorDOMAgent.cpp:
1976         (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
1977         * inspector/InspectorDOMAgent.h:
1978         * inspector/InspectorDOMDebuggerAgent.cpp:
1979         * inspector/InspectorDOMDebuggerAgent.h:
1980         * inspector/InspectorDOMStorageAgent.cpp:
1981         * inspector/InspectorDOMStorageAgent.h:
1982         * inspector/InspectorDatabaseAgent.cpp:
1983         * inspector/InspectorDatabaseAgent.h:
1984         * inspector/InspectorDatabaseResource.cpp:
1985         * inspector/InspectorDatabaseResource.h:
1986         * inspector/InspectorFrontendClientLocal.cpp:
1987         * inspector/InspectorIndexedDBAgent.cpp:
1988         * inspector/InspectorIndexedDBAgent.h:
1989         * inspector/InspectorLayerTreeAgent.cpp:
1990         * inspector/InspectorLayerTreeAgent.h:
1991         * inspector/InspectorPageAgent.cpp:
1992         * inspector/InspectorPageAgent.h:
1993         * inspector/InspectorReplayAgent.cpp:
1994         * inspector/InspectorReplayAgent.h:
1995         * inspector/InspectorResourceAgent.cpp:
1996         * inspector/InspectorResourceAgent.h:
1997         * inspector/InspectorStyleSheet.cpp:
1998         * inspector/InspectorStyleSheet.h:
1999         * inspector/InspectorTimelineAgent.cpp:
2000         (WebCore::InspectorTimelineAgent::addRecordToTimeline):
2001         * inspector/InspectorTimelineAgent.h:
2002         * inspector/InspectorWorkerAgent.cpp:
2003         * inspector/InspectorWorkerAgent.h:
2004         * inspector/PageRuntimeAgent.h:
2005         * inspector/TimelineRecordFactory.cpp:
2006         * inspector/WorkerInspectorController.cpp:
2007
2008 2014-10-20  Andy Estes  <aestes@apple.com>
2009
2010         Fix the GTK build.
2011
2012         * dom/RenderedDocumentMarker.h:
2013
2014 2014-10-19  Antti Koivisto  <antti@apple.com>
2015
2016         Avoid unnecessary NSURLResponse construction for QuickLook on iOS
2017         https://bugs.webkit.org/show_bug.cgi?id=137876
2018
2019         Reviewed by Andy Estes.
2020
2021         QuickLook specific code path creates NSURLResponse in the web process for every response.
2022         It is rarely needed so this is unnecessary work.
2023
2024         * WebCore.exp.in:
2025         * platform/network/ios/QuickLook.h:
2026         * platform/network/ios/QuickLook.mm:
2027         (WebCore::isMainResourceLoader):
2028         (WebCore::QuickLookHandle::shouldCreateForMIMEType):
2029
2030             Separate function for testing if QuickLookHandle is needed.
2031
2032         (WebCore::QuickLookHandle::create):
2033
2034             Switch the interface to take ResourceResponse.
2035
2036 2014-10-20  Andy Estes  <aestes@apple.com>
2037
2038         Fix the iOS build.
2039
2040         * WebCore.xcodeproj/project.pbxproj:
2041         * dom/RenderedDocumentMarker.h:
2042         * page/ios/FrameIOS.mm:
2043         (WebCore::Frame::interpretationsForCurrentRoot):
2044
2045 2014-10-20  Benjamin Poulain  <benjamin@webkit.org>
2046
2047         Update the <link>'s link status
2048         https://bugs.webkit.org/show_bug.cgi?id=137861
2049
2050         Reviewed by Chris Dumez.
2051
2052         In the latest HTML spec, <link> has the link status
2053         if it has a 'href' attribute, exactly like <a> and <area>:
2054             https://html.spec.whatwg.org/multipage/scripting.html#selector-link
2055
2056         This patch updates WebKit accordingly.
2057
2058         Tests: fast/css/link-basics.html
2059                fast/selectors/link-basics-xhtml.xhtml
2060                fast/selectors/link-basics.html
2061                fast/selectors/webkit-any-link-basics.html
2062
2063         * html/HTMLLinkElement.cpp:
2064         (WebCore::HTMLLinkElement::parseAttribute):
2065
2066 2014-10-20  Chris Dumez  <cdumez@apple.com>
2067
2068         [Mac] Optimize cookiesForDOM() by filtering and serializing cookies in a single pass
2069         https://bugs.webkit.org/show_bug.cgi?id=137869
2070
2071         Reviewed by Darin Adler.
2072
2073         Optimize cookiesForDOM() by filtering and serializing in 1 pass instead of 2.
2074
2075         Previously, when accessing document.cookie, we ended up doing the following:
2076         1. Call wkHTTPCookiesForURL() to get an NSArray of NSHTTPCookies.
2077         2. Call filterCookies() to filter out cookies that are httpOnly or with an
2078            empty name, thus allocating a new NSMutableArray.
2079         3. Call NSHTTPCookie's requestHeaderFieldsWithCookies() to serialize the
2080            cookies
2081         4. Construct a WTF::String from the NSString*
2082
2083         There were several inefficiencies here:
2084         1. We needed to pre-filter the cookies and allocate a new NSMutableArray
2085            before calling requestHeaderFieldsWithCookies()
2086         2. requestHeaderFieldsWithCookies() does more things that we actually need.
2087            It constructs a Dictionary of header fields, of which we query the
2088            "Cookie" field, even though we merely want a ';'-separated string
2089            representation of the cookies in "key=value" form.
2090
2091         With this patch, we now take care of the string serialization ourselves,
2092         using a StringBuilder as it is trivial to do. This also allows us to filter
2093         out the httpOnly/invalid cookies as we do the serialization instead of
2094         having a first pass to do so.
2095
2096         When scrolling the http://www.apple.com/iphone/ entire page down, then up,
2097         se were spending ~13.1% of the NetworkProcess time in cookiesForDOM()
2098         (~96ms) on my machine. With the patch, we spend ~23% less time in
2099         cookiesForDOM() (~74ms).
2100
2101         No new tests, no behavior change.
2102
2103         * platform/network/mac/CookieJarMac.mm:
2104         (WebCore::cookiesForSession):
2105         (WebCore::cookiesForDOM):
2106         (WebCore::cookieRequestHeaderFieldValue):
2107
2108 2014-10-19  Chris Dumez  <cdumez@apple.com>
2109
2110         Kill toRenderedDocumentMarker() by using tighter typing
2111         https://bugs.webkit.org/show_bug.cgi?id=137858
2112
2113         Reviewed by Darin Adler.
2114
2115         Kill toRenderedDocumentMarker() by using tighter typing. This method
2116         was doing no type validation, just a static_cast<>().
2117
2118         No new tests, no behavior change.
2119
2120         * dom/DocumentMarkerController.cpp:
2121         (WebCore::DocumentMarkerController::addTextMatchMarker):
2122         (WebCore::DocumentMarkerController::markersFor):
2123         (WebCore::DocumentMarkerController::markersInRange):
2124         (DocumentMarkerController::hasMarkers):
2125         * dom/DocumentMarkerController.h:
2126         * dom/RenderedDocumentMarker.h:
2127         (WebCore::toRenderedDocumentMarker): Deleted.
2128         * editing/AlternativeTextController.cpp:
2129         (WebCore::markersHaveIdenticalDescription):
2130         (WebCore::AlternativeTextController::respondToChangedSelection):
2131         (WebCore::AlternativeTextController::recordSpellcheckerResponseForModifiedCorrection):
2132         (WebCore::AlternativeTextController::processMarkersOnTextToBeReplacedByResult):
2133         (WebCore::AlternativeTextController::applyDictationAlternative):
2134         * editing/CompositeEditCommand.cpp:
2135         (WebCore::copyMarkers):
2136         (WebCore::CompositeEditCommand::replaceTextInNodePreservingMarkers):
2137         * editing/DeleteSelectionCommand.cpp:
2138         (WebCore::DeleteSelectionCommand::originalStringForAutocorrectionAtBeginningOfSelection):
2139         * editing/Editor.cpp:
2140         (WebCore::Editor::updateMarkersForWordsAffectedByEditing):
2141         (WebCore::Editor::selectionStartHasMarkerFor):
2142         * rendering/InlineTextBox.cpp:
2143         (WebCore::InlineTextBox::paintDocumentMarker):
2144         (WebCore::InlineTextBox::paintTextMatchMarker):
2145         (WebCore::InlineTextBox::computeRectForReplacementMarker):
2146         (WebCore::InlineTextBox::paintDocumentMarkers):
2147         * rendering/InlineTextBox.h:
2148         * rendering/svg/SVGInlineFlowBox.cpp:
2149         (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
2150         * testing/Internals.cpp:
2151         (WebCore::Internals::markerAt):
2152         (WebCore::Internals::markerRangeForNode):
2153         (WebCore::Internals::markerDescriptionForNode):
2154         * testing/Internals.h:
2155
2156 2014-10-19  Chris Dumez  <cdumez@apple.com>
2157
2158         Use is<>() / downcast<>() for all remaining RenderObject subclasses
2159         https://bugs.webkit.org/show_bug.cgi?id=137845
2160
2161         Reviewed by Darin Adler.
2162
2163         Use is<>() / downcast<>() for all remaining RenderObject subclasses and
2164         clean up the surrounding code.
2165
2166         No new tests, no behavior change.
2167
2168         * accessibility/AccessibilityProgressIndicator.cpp:
2169         (WebCore::AccessibilityProgressIndicator::progressElement):
2170         (WebCore::AccessibilityProgressIndicator::meterElement):
2171         * accessibility/AccessibilityRenderObject.cpp:
2172         (WebCore::AccessibilityRenderObject::layoutCount):
2173         (WebCore::AccessibilityRenderObject::widgetForAttachmentView):
2174         (WebCore::AccessibilityRenderObject::visiblePositionForPoint):
2175         * dom/Document.cpp:
2176         (WebCore::widgetForElement):
2177         * dom/Position.cpp:
2178         (WebCore::Position::getInlineBoxAndOffset):
2179         * dom/WebKitNamedFlow.cpp:
2180         (WebCore::WebKitNamedFlow::overset):
2181         (WebCore::WebKitNamedFlow::firstEmptyRegionIndex):
2182         (WebCore::WebKitNamedFlow::getRegionsByContent):
2183         (WebCore::WebKitNamedFlow::getRegions):
2184         * editing/FrameSelection.cpp:
2185         (WebCore::isFrameElement):
2186         * html/HTMLEmbedElement.cpp:
2187         (WebCore::findWidgetRenderer):
2188         * html/HTMLFrameOwnerElement.cpp:
2189         (WebCore::HTMLFrameOwnerElement::HTMLFrameOwnerElement):
2190         (WebCore::HTMLFrameOwnerElement::renderWidget):
2191         * html/HTMLMediaElement.cpp:
2192         (WebCore::HTMLMediaElement::parseAttribute):
2193         * html/HTMLMeterElement.cpp:
2194         (WebCore::HTMLMeterElement::renderMeter):
2195         * html/HTMLPlugInElement.cpp:
2196         (WebCore::HTMLPlugInElement::supportsFocus):
2197         * html/HTMLPlugInImageElement.cpp:
2198         (WebCore::HTMLPlugInImageElement::renderEmbeddedObject):
2199         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn):
2200         * html/HTMLProgressElement.cpp:
2201         (WebCore::HTMLProgressElement::renderProgress):
2202         * html/PluginDocument.cpp:
2203         (WebCore::PluginDocument::pluginWidget):
2204         * html/shadow/MediaControlElements.cpp:
2205         (WebCore::MediaControlTimelineElement::defaultEventHandler):
2206         (WebCore::MediaControlTextTrackContainerElement::updateSizes):
2207         (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
2208         * inspector/InspectorLayerTreeAgent.cpp:
2209         (WebCore::InspectorLayerTreeAgent::gatherLayersUsingRenderObjectHierarchy):
2210         * inspector/InspectorOverlay.cpp:
2211         (WebCore::buildObjectForElementInfo):
2212         * loader/SubframeLoader.cpp:
2213         (WebCore::SubframeLoader::loadSubframe):
2214         * page/Frame.cpp:
2215         (WebCore::Frame::ownerRenderer):
2216         * page/FrameView.cpp:
2217         (WebCore::FrameView::layout):
2218         * page/gtk/EventHandlerGtk.cpp:
2219         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
2220         * page/ios/EventHandlerIOS.mm:
2221         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
2222         (WebCore::EventHandler::passSubframeEventToSubframe):
2223         * page/mac/EventHandlerMac.mm:
2224         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
2225         (WebCore::EventHandler::passSubframeEventToSubframe):
2226         (WebCore::widgetForEventTarget):
2227         * platform/efl/RenderThemeEfl.cpp:
2228         (WebCore::RenderThemeEfl::applyEdjeRTLState):
2229         * rendering/InlineTextBox.cpp:
2230         (WebCore::fontToUse):
2231         (WebCore::InlineTextBox::emphasisMarkExistsAndIsAbove):
2232         (WebCore::InlineTextBox::paint):
2233         * rendering/LayoutState.cpp:
2234         (WebCore::LayoutState::LayoutState):
2235         * rendering/RenderBlock.cpp:
2236         (WebCore::RenderBlock::collapseAnonymousBoxChild):
2237         (WebCore::RenderBlock::simplifiedLayout):
2238         (WebCore::RenderBlock::paintObject):
2239         (WebCore::RenderBlock::selectionGaps):
2240         (WebCore::RenderBlock::nodeAtPoint):
2241         * rendering/RenderBlockFlow.cpp:
2242         (WebCore::RenderBlockFlow::layoutBlock):
2243         (WebCore::RenderBlockFlow::hitTestFloats):
2244         (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
2245         * rendering/RenderBlockLineLayout.cpp:
2246         (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForSegment):
2247         * rendering/RenderBox.cpp:
2248         (WebCore::RenderBox::scroll):
2249         (WebCore::RenderBox::nodeAtPoint):
2250         (WebCore::RenderBox::repaintLayerRectsForImage):
2251         (WebCore::RenderBox::mapLocalToContainer):
2252         (WebCore::RenderBox::containingBlockLogicalWidthForPositioned):
2253         * rendering/RenderCombineText.h:
2254         * rendering/RenderElement.cpp:
2255         (WebCore::RenderElement::adjustStyleDifference):
2256         (WebCore::addLayers):
2257         (WebCore::RenderElement::removeLayers):
2258         (WebCore::RenderElement::moveLayers):
2259         (WebCore::RenderElement::setNeedsPositionedMovementLayout):
2260         (WebCore::RenderElement::renderNamedFlowThreadWrapper):
2261         * rendering/RenderEmbeddedObject.h:
2262         * rendering/RenderFlowThread.cpp:
2263         (WebCore::RenderFlowThread::validateRegions):
2264         (WebCore::RenderFlowThread::hasCompositingRegionDescendant):
2265         (WebCore::RenderFlowThread::regionForCompositedLayer):
2266         (WebCore::RenderFlowThread::clearRenderBoxRegionInfoAndCustomStyle):
2267         (WebCore::RenderFlowThread::initializeRegionsComputedAutoHeight):
2268         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
2269         (WebCore::RenderFlowThread::addForcedRegionBreak):
2270         (WebCore::RenderFlowThread::addRegionsOverflowFromChild):
2271         * rendering/RenderFlowThread.h:
2272         * rendering/RenderLayer.cpp:
2273         (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
2274         (WebCore::transparencyClipBox):
2275         (WebCore::accumulateOffsetTowardsAncestor):
2276         (WebCore::RenderLayer::collectFragments):
2277         (WebCore::RenderLayer::hitTest):
2278         (WebCore::RenderLayer::isFlowThreadCollectingGraphicsLayersUnderRegions):
2279         (WebCore::RenderLayer::calculateClipRects):
2280         * rendering/RenderLayerBacking.cpp:
2281         (WebCore::RenderLayerBacking::updateAfterWidgetResize):
2282         (WebCore::RenderLayerBacking::updateConfiguration):
2283         (WebCore::isRestartedPlugin):
2284         (WebCore::isCompositedPlugin):
2285         (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
2286         (WebCore::RenderLayerBacking::containsPaintedContent):
2287         * rendering/RenderLayerCompositor.cpp:
2288         (WebCore::RenderLayerCompositor::updateBacking):
2289         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
2290         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
2291         (WebCore::RenderLayerCompositor::requiresCompositingLayer):
2292         (WebCore::RenderLayerCompositor::reasonsForCompositing):
2293         (WebCore::RenderLayerCompositor::requiresCompositingForVideo):
2294         (WebCore::RenderLayerCompositor::requiresCompositingForPlugin):
2295         (WebCore::RenderLayerCompositor::requiresCompositingForFrame):
2296         * rendering/RenderLayerModelObject.h:
2297         * rendering/RenderLineBreak.h:
2298         * rendering/RenderMeter.h:
2299         * rendering/RenderMultiColumnFlowThread.cpp:
2300         (WebCore::RenderMultiColumnFlowThread::firstMultiColumnSet):
2301         (WebCore::RenderMultiColumnFlowThread::lastMultiColumnSet):
2302         (WebCore::RenderMultiColumnFlowThread::layout):
2303         (WebCore::RenderMultiColumnFlowThread::addRegionToThread):
2304         (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantInserted):
2305         (WebCore::RenderMultiColumnFlowThread::flowThreadRelativeWillBeRemoved):
2306         (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantBoxLaidOut):
2307         (WebCore::RenderMultiColumnFlowThread::setPageBreak):
2308         (WebCore::RenderMultiColumnFlowThread::updateMinimumPageHeight):
2309         (WebCore::RenderMultiColumnFlowThread::setRegionRangeForBox):
2310         (WebCore::RenderMultiColumnFlowThread::addForcedRegionBreak):
2311         (WebCore::RenderMultiColumnFlowThread::physicalTranslationOffsetFromFlowToRegion):
2312         * rendering/RenderMultiColumnFlowThread.h:
2313         * rendering/RenderMultiColumnSet.cpp:
2314         (WebCore::RenderMultiColumnSet::nextSiblingMultiColumnSet):
2315         (WebCore::RenderMultiColumnSet::previousSiblingMultiColumnSet):
2316         * rendering/RenderMultiColumnSet.h:
2317         * rendering/RenderMultiColumnSpannerPlaceholder.h:
2318         * rendering/RenderNamedFlowFragment.cpp:
2319         (WebCore::RenderNamedFlowFragment::checkRegionStyle):
2320         (WebCore::RenderNamedFlowFragment::namedFlowThread):
2321         * rendering/RenderNamedFlowFragment.h:
2322         * rendering/RenderNamedFlowThread.cpp:
2323         (WebCore::RenderNamedFlowThread::updateWritingMode):
2324         (WebCore::addFragmentToList):
2325         (WebCore::RenderNamedFlowThread::addRegionToThread):
2326         (WebCore::RenderNamedFlowThread::removeRegionFromThread):
2327         (WebCore::RenderNamedFlowThread::fragmentFromRenderBoxAsRenderBlock):
2328         (WebCore::RenderNamedFlowThread::fragmentFromAbsolutePointAndBox):
2329         (WebCore::RenderNamedFlowThread::checkInvalidRegions):
2330         (WebCore::RenderNamedFlowThread::checkRegionsWithStyling):
2331         (WebCore::RenderNamedFlowThread::clearRenderObjectCustomStyle):
2332         * rendering/RenderNamedFlowThread.h:
2333         * rendering/RenderObject.cpp:
2334         (WebCore::scheduleRelayoutForSubtree):
2335         (WebCore::RenderObject::setLayerNeedsFullRepaint):
2336         (WebCore::RenderObject::setLayerNeedsFullRepaintForPositionedMovementLayout):
2337         (WebCore::RenderObject::repaintUsingContainer):
2338         (WebCore::RenderObject::selectionRoot):
2339         (WebCore::RenderObject::shouldUseTransformFromContainer):
2340         (WebCore::RenderObject::getTransformFromContainer):
2341         (WebCore::RenderObject::isRooted):
2342         (WebCore::RenderObject::willBeDestroyed):
2343         (WebCore::RenderObject::isComposited):
2344         (WebCore::RenderObject::currentRenderNamedFlowFragment):
2345         * rendering/RenderObject.h:
2346         * rendering/RenderProgress.h:
2347         * rendering/RenderRuby.cpp:
2348         (WebCore::lastRubyRun):
2349         * rendering/RenderRubyBase.cpp:
2350         (WebCore::RenderRubyBase::rubyRun):
2351         * rendering/RenderRubyRun.cpp:
2352         (WebCore::RenderRubyRun::removeChild):
2353         * rendering/RenderRubyRun.h:
2354         * rendering/RenderSlider.h:
2355         * rendering/RenderText.cpp:
2356         (WebCore::RenderText::widthFromCache):
2357         * rendering/RenderThemeGtk.cpp:
2358         (WebCore::RenderThemeGtk::calculateProgressRect):
2359         * rendering/RenderThemeIOS.mm:
2360         (WebCore::RenderThemeIOS::paintProgressBar):
2361         * rendering/RenderThemeMac.mm:
2362         (WebCore::RenderThemeMac::paintMeter):
2363         (WebCore::RenderThemeMac::paintProgressBar):
2364         * rendering/RenderThemeSafari.cpp:
2365         (WebCore::RenderThemeSafari::paintMeter):
2366         * rendering/RenderThemeWin.cpp:
2367         (WebCore::RenderThemeWin::paintMeter):
2368         * rendering/RenderTreeAsText.cpp:
2369         (WebCore::writeRenderRegionList):
2370         (WebCore::writeLayers):
2371         * rendering/RenderVideo.h:
2372         * rendering/RenderView.cpp:
2373         (WebCore::SelectionIterator::checkForSpanner):
2374         (WebCore::isComposited):
2375         * rendering/RenderView.h:
2376         * rendering/RenderWidget.h:
2377         * rendering/line/BreakingContextInlineHeaders.h:
2378         (WebCore::BreakingContext::handleText):
2379         * rendering/line/LineBreaker.cpp:
2380         (WebCore::LineBreaker::skipLeadingWhitespace):
2381         * testing/Internals.cpp:
2382         (WebCore::Internals::isPluginUnavailabilityIndicatorObscured):
2383
2384 2014-10-19  Chris Dumez  <cdumez@apple.com>
2385
2386         Use SPECIALIZE_TYPE_TRAITS_*() macro for RenderScrollbar
2387         https://bugs.webkit.org/show_bug.cgi?id=137854
2388
2389         Reviewed by Darin Adler.
2390
2391         Use SPECIALIZE_TYPE_TRAITS_*() macro for RenderScrollbar instead of a
2392         custom toRenderScrollbar() function, for consistency.
2393
2394         No new tests, no behavior change.
2395
2396         * rendering/RenderScrollbar.h:
2397         (isType):
2398         (WebCore::toRenderScrollbar): Deleted.
2399         * rendering/RenderScrollbarTheme.cpp:
2400         (WebCore::RenderScrollbarTheme::minimumThumbLength):
2401         (WebCore::RenderScrollbarTheme::backButtonRect):
2402         (WebCore::RenderScrollbarTheme::forwardButtonRect):
2403         (WebCore::RenderScrollbarTheme::trackRect):
2404         (WebCore::RenderScrollbarTheme::constrainTrackRectToTrackPieces):
2405         (WebCore::RenderScrollbarTheme::willPaintScrollbar):
2406         (WebCore::RenderScrollbarTheme::didPaintScrollbar):
2407         (WebCore::RenderScrollbarTheme::paintScrollbarBackground):
2408         (WebCore::RenderScrollbarTheme::paintTrackBackground):
2409         (WebCore::RenderScrollbarTheme::paintTrackPiece):
2410         (WebCore::RenderScrollbarTheme::paintButton):
2411         (WebCore::RenderScrollbarTheme::paintThumb):
2412
2413 2014-10-19  Carlos Garcia Campos  <cgarcia@igalia.com>
2414
2415         [GTK] Move GtkDragAndDropHelper from Platform to WebKit2
2416         https://bugs.webkit.org/show_bug.cgi?id=137422
2417
2418         Reviewed by Martin Robinson.
2419
2420         Remove ClipboardUtilitiesGtk and GtkDragAndDropHelper.
2421
2422         * PlatformGTK.cmake:
2423         * platform/gtk/ClipboardUtilitiesGtk.cpp: Removed.
2424         * platform/gtk/ClipboardUtilitiesGtk.h: Removed.
2425         * platform/gtk/GtkDragAndDropHelper.cpp: Removed.
2426         * platform/gtk/GtkDragAndDropHelper.h: Removed.
2427
2428 2014-10-19  Roger Fong  <roger_fong@apple.com>
2429
2430         Unreviewed. Style fix following r174855.
2431
2432         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
2433         (WebCore::GraphicsContext3D::readPixelsAndConvertToBGRAIfNecessary):
2434
2435 2014-10-18  Antti Koivisto  <antti@apple.com>
2436
2437         REGRESSION (r173356): Safari can't install a profile, gets 'Download Failed error
2438         https://bugs.webkit.org/show_bug.cgi?id=137855
2439
2440         Reviewed by Dan Bernstein.
2441
2442         We lose the sniffed MIME type for the response when synthesizing an NSURLResponse. Sniffing requires
2443         backchannel data that the synthesized response doesn't have.
2444
2445         Test: http/tests/mime/mime-type-sniff.html
2446
2447         * platform/network/mac/ResourceResponseMac.mm:
2448         (WebCore::ResourceResponse::initNSURLResponse):
2449
2450             When synthesizing NSURLResponse explicitly set the Content-type header to the sniffed type.
2451
2452 2014-10-18  Chris Dumez  <cdumez@apple.com>
2453
2454         [Mac] Use Fast enumeration consistently in WebFontCache.mm
2455         https://bugs.webkit.org/show_bug.cgi?id=137791
2456
2457         Reviewed by Darin Adler.
2458
2459         Use fast enumeration consistently in WebFontCache.mm as this results in
2460         more efficient, concise and safer code.
2461
2462         No new tests, no behavior change.
2463
2464         * platform/mac/WebFontCache.mm:
2465         (+[WebFontCache getTraits:inFamily:]):
2466         Reserve Vector capacity before the loop as we know how many traits we
2467         are going to append. Also use uncheckedAppend() for performance.
2468
2469         (+[WebFontCache internalFontWithFamily:traits:weight:size:]):
2470
2471 2014-10-18  Chris Fleizach  <cfleizach@apple.com>
2472
2473         AX: Tables with <colgroups> are not reporting table column headers
2474         https://bugs.webkit.org/show_bug.cgi?id=137846
2475
2476         Reviewed by Mario Sanchez Prada.
2477
2478         The code to search for header objects was getting stuck on anonymous RenderTableSections.
2479         We also need to check more rows for headers, in case the first row or more is not visible or is empty.
2480
2481         Test: accessibility/table-column-headers-with-captions.html
2482
2483         * accessibility/AccessibilityTableColumn.cpp:
2484         (WebCore::AccessibilityTableColumn::headerObject):
2485         (WebCore::AccessibilityTableColumn::headerObjectForSection):
2486
2487 2014-10-18  KwangHyuk Kim  <hyuki.kim@samsung.com>
2488
2489         [EFL] build break occurs on webkit efl build.
2490         https://bugs.webkit.org/show_bug.cgi?id=137844
2491
2492         Reviewed by Gyuyoung Kim.
2493
2494         As local variable elementAddressRegisterIndex is assigned but not used, there is build break for the webkit efl.
2495
2496         No new tests because it's just to fix build break.
2497
2498         * cssjit/SelectorCompiler.cpp:
2499         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesSelectorList):
2500
2501 2014-10-17  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2502
2503         Apply std::unique_ptr to FooFont classes
2504         https://bugs.webkit.org/show_bug.cgi?id=137769
2505
2506         Reviewed by Andreas Kling.
2507
2508         As a step to use std::unique_ptr, this patch applies std::unique_ptr to Font classes.
2509
2510         No new tests, no behavior changes.
2511
2512         * platform/graphics/Font.cpp:
2513         (WebCore::retrieveOrAddCachedFontGlyphs):
2514         (WebCore::Font::createLayout):
2515         * platform/graphics/SimpleFontData.cpp:
2516         (WebCore::SimpleFontData::DerivedFontData::create):
2517         * platform/graphics/SimpleFontData.h:
2518         Remove create() factory function because public ctor and std::make_unique<> can replace it.
2519         * platform/graphics/mac/ComplexTextController.cpp:
2520         (WebCore::Font::createLayout):
2521
2522 2014-10-17  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2523
2524         Use std::unique_ptr in WebCore/bindings
2525         https://bugs.webkit.org/show_bug.cgi?id=137808
2526
2527         Reviewed by Andreas Kling.
2528
2529         Clean up PassOwnPtr|OwnPtr in WebCore/bindings by using std::unique_ptr, std::make_unique
2530         and WTF::move.
2531
2532         No new tests, no behavior changes.
2533
2534         * bindings/generic/ActiveDOMCallback.h:
2535         * bindings/js/JSMessageEventCustom.cpp:
2536         (WebCore::handleInitMessageEvent):
2537         * bindings/js/SerializedScriptValue.cpp:
2538         (WebCore::SerializedScriptValue::SerializedScriptValue):
2539         (WebCore::SerializedScriptValue::transferArrayBuffers):
2540         (WebCore::SerializedScriptValue::create):
2541         * bindings/js/SerializedScriptValue.h:
2542         * bindings/js/WorkerScriptDebugServer.cpp:
2543         (WebCore::WorkerScriptDebugServer::interruptAndRunTask):
2544         * bindings/js/WorkerScriptDebugServer.h:
2545         * inspector/WorkerDebuggerAgent.cpp:
2546         (WebCore::WorkerDebuggerAgent::interruptAndDispatchInspectorCommands):
2547
2548 2014-10-16  Roger Fong  <roger_fong@apple.com>
2549
2550         Calling glReadPixels with BGRA format on an NVIDIA machine with an opaque context returns the wrong alpha values.
2551         https://bugs.webkit.org/show_bug.cgi?id=137793.
2552         <rdar://problem/15408133>
2553
2554         Reviewed by Dean Jackson.
2555
2556         This fixes conformance test context/context-attribute-preserve-drawing-buffer.html.
2557
2558         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
2559         (WebCore::GraphicsContext3D::readPixelsAndConvertToBGRAIfNecessary):
2560         On an NVIDIA machine, when the context has alpha turned off, call glReadPixels with RGBA format and then convert to RGBA.
2561
2562 2014-10-17  Chris Dumez  <cdumez@apple.com>
2563
2564         Use is<>() / downcast<>() for all SVG RenderObjects
2565         https://bugs.webkit.org/show_bug.cgi?id=137840
2566
2567         Reviewed by Benjamin Poulain.
2568
2569         Use is<>() / downcast<>() for all SVG RenderObjects and clean up the
2570         surrounding code.
2571
2572         No new tests, no behaviro change.
2573
2574         * accessibility/AccessibilityRenderObject.cpp:
2575         (WebCore::AccessibilityRenderObject::supportsPath):
2576         (WebCore::AccessibilityRenderObject::elementPath):
2577         * page/FrameView.cpp:
2578         (WebCore::FrameView::applyOverflowToViewport):
2579         (WebCore::FrameView::forceLayoutParentViewIfNeeded):
2580         * rendering/RenderLayerFilterInfo.cpp:
2581         (WebCore::RenderLayer::FilterInfo::removeReferenceFilterClients):
2582         * rendering/svg/RenderSVGGradientStop.cpp:
2583         (WebCore::RenderSVGGradientStop::styleDidChange):
2584         * rendering/svg/RenderSVGImage.h:
2585         * rendering/svg/RenderSVGInlineText.h:
2586         * rendering/svg/RenderSVGResourceContainer.cpp:
2587         (WebCore::RenderSVGResourceContainer::markAllClientsForInvalidation):
2588         * rendering/svg/RenderSVGResourceContainer.h:
2589         * rendering/svg/RenderSVGRoot.cpp:
2590         (WebCore::RenderSVGRoot::addResourceForClientInvalidation):
2591         * rendering/svg/RenderSVGRoot.h:
2592         * rendering/svg/RenderSVGShape.h:
2593         * rendering/svg/RenderSVGText.cpp:
2594         (WebCore::collectLayoutAttributes):
2595         (WebCore::RenderSVGText::subtreeChildWillBeRemoved):
2596         (WebCore::RenderSVGText::subtreeTextDidChange):
2597         (WebCore::updateFontInAllDescendants):
2598         * rendering/svg/RenderSVGText.h:
2599         * rendering/svg/SVGInlineTextBox.h:
2600         * rendering/svg/SVGRenderSupport.cpp:
2601         (WebCore::SVGRenderSupport::mapLocalToContainer):
2602         (WebCore::SVGRenderSupport::pushMappingToContainer):
2603         (WebCore::SVGRenderSupport::computeContainerBoundingBoxes):
2604         * rendering/svg/SVGRenderTreeAsText.cpp:
2605         (WebCore::writeStyle):
2606         * rendering/svg/SVGRenderingContext.cpp:
2607         (WebCore::SVGRenderingContext::bufferForeground):
2608         * rendering/svg/SVGResourcesCycleSolver.cpp:
2609         (WebCore::SVGResourcesCycleSolver::resolveCycles):
2610         * rendering/svg/SVGRootInlineBox.cpp:
2611         (WebCore::SVGRootInlineBox::renderSVGText):
2612         (WebCore::SVGRootInlineBox::computePerCharacterLayoutInformation):
2613         * svg/SVGCircleElement.cpp:
2614         (WebCore::SVGCircleElement::svgAttributeChanged):
2615         * svg/SVGElement.cpp:
2616         (WebCore::SVGElement::svgAttributeChanged):
2617         * svg/SVGEllipseElement.cpp:
2618         (WebCore::SVGEllipseElement::svgAttributeChanged):
2619         * svg/SVGImageElement.cpp:
2620         (WebCore::SVGImageElement::svgAttributeChanged):
2621         (WebCore::SVGImageElement::didAttachRenderers):
2622         * svg/SVGLineElement.cpp:
2623         (WebCore::SVGLineElement::svgAttributeChanged):
2624         * svg/SVGPolyElement.cpp:
2625         (WebCore::SVGPolyElement::svgAttributeChanged):
2626         * svg/SVGRectElement.cpp:
2627         (WebCore::SVGRectElement::svgAttributeChanged):
2628         * svg/SVGSVGElement.cpp:
2629         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
2630         (WebCore::SVGSVGElement::currentViewBoxRect):
2631         * svg/graphics/SVGImage.cpp:
2632         (WebCore::SVGImage::setContainerSize):
2633         (WebCore::SVGImage::containerSize):
2634
2635 2014-10-17  Chris Dumez  <cdumez@apple.com>
2636
2637         Avoid unnecessary isSVGFont() check in SimpleFontData::applyTransforms()
2638         https://bugs.webkit.org/show_bug.cgi?id=137836
2639
2640         Reviewed by Andreas Kling.
2641
2642         Avoid unnecessary isSVGFont() check in SimpleFontData::applyTransforms().
2643         This function is only called from WidthIterator::applyFontTransforms(),
2644         which already makes sure to call applyTransforms() if isSVGFont()
2645         returns false. This patch replaces the check with a simple assertion.
2646
2647         No new tests, no behavior change.
2648
2649         * platform/graphics/SimpleFontData.h:
2650         * svg/SVGFontData.h:
2651
2652 2014-10-17  Michael Saboff  <msaboff@apple.com>
2653
2654         Don't create cached functions that access lexicalGlobalObject()
2655         https://bugs.webkit.org/show_bug.cgi?id=137839
2656
2657         Reviewed by Geoffrey Garen.
2658
2659         Made it so that all the JSDOMWindow special functions blur(), close(), focus() and postMessage()
2660         are always created as needed for every prototype.  Made it so that JSHTMLDocument does
2661         the same for open().  Updated test to account for these methods not being cached
2662
2663         Updated tests accordingly.
2664
2665         * bindings/js/JSDOMWindowCustom.cpp: 
2666         (WebCore::JSDOMWindow::getOwnPropertySlot): Updated to always create cached versions of the
2667         special functions.
2668         * bindings/js/JSHTMLDocumentCustom.cpp:
2669         (WebCore::JSHTMLDocument::getOwnPropertySlot): Added to create an uncached open() method when
2670         it is first accessed.
2671         * html/HTMLDocument.idl: Added CustomGetOwnPropertySlot and implemented it in JSHTMLDocumentCustom.cpp.
2672
2673 2014-10-17  Simon Fraser  <simon.fraser@apple.com>
2674
2675         [iOS] Speculative fix for a crash under RenderLayerCompositor::updateScrollCoordinatedLayer()
2676         https://bugs.webkit.org/show_bug.cgi?id=137837
2677         rdar://problem/18545452
2678
2679         Reviewed by Tim Horton.
2680
2681         Crash logs suggest that an iframe's RenderView's RenderLayer's backing can be null
2682         in a call to updateScrollCoordinatedLayer(), so add an assertion (to help find a reproducible case)
2683         and a null check.
2684
2685         * rendering/RenderLayerCompositor.cpp:
2686         (WebCore::RenderLayerCompositor::attachScrollingNode):
2687
2688 2014-10-17  Andreas Kling  <akling@apple.com>
2689
2690         Re-arrange parentheses for compilation purposes.
2691
2692         * cssjit/SelectorCompiler.cpp:
2693         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesSelectorList):
2694
2695 2014-10-17  Andreas Kling  <akling@apple.com>
2696
2697         Unreviewed build fix after r174838.
2698
2699         Use StackAllocator::addressOf() instead of the old way of grabbing at a stack reference.
2700
2701         * cssjit/SelectorCompiler.cpp:
2702         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesSelectorList):
2703
2704 2014-10-17  Chris Dumez  <cdumez@apple.com>
2705
2706         Use is<>() / downcast<>() for RenderBox
2707         https://bugs.webkit.org/show_bug.cgi?id=137804
2708
2709         Reviewed by Andreas Kling.
2710
2711         Use is<>() / downcast<>() for RenderBox and clean up the surrounding
2712         code.
2713
2714         No new tests, no behavior change.
2715
2716         * accessibility/AccessibilityRenderObject.cpp:
2717         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
2718         (WebCore::AccessibilityRenderObject::accessibilityHitTest):
2719         (WebCore::AccessibilityRenderObject::getScrollableAreaIfScrollable):
2720         (WebCore::AccessibilityRenderObject::scrollTo):
2721         * bindings/objc/DOMHTML.mm:
2722         (-[DOMHTMLElement scrollYOffset]):
2723         (-[DOMHTMLElement setScrollXOffset:scrollYOffset:adjustForIOSCaret:]):
2724         * bindings/objc/DOMUIKitExtensions.mm:
2725         (-[DOMNode borderRadii]):
2726         * css/CSSComputedStyleDeclaration.cpp:
2727         (WebCore::sizingBox):
2728         (WebCore::computedTransform):
2729         (WebCore::zoomAdjustedPaddingOrMarginPixelValue):
2730         (WebCore::ComputedStyleExtractor::propertyValue):
2731         * dom/ContainerNode.cpp:
2732         (WebCore::ContainerNode::getLowerRightCorner):
2733         * dom/Document.cpp:
2734         (WebCore::Document::webkitWillEnterFullScreenForElement):
2735         * dom/Element.cpp:
2736         (WebCore::Element::scrollByUnits):
2737         * dom/Node.cpp:
2738         (WebCore::Node::defaultEventHandler):
2739         * dom/Position.cpp:
2740         (WebCore::endsOfNodeAreVisuallyDistinctPositions):
2741         * editing/DeleteButtonController.cpp:
2742         (WebCore::isDeletableElement):
2743         * editing/EditorCommand.cpp:
2744         (WebCore::verticalScrollDistance):
2745         * editing/FrameSelection.cpp:
2746         (WebCore::CaretBase::paintCaret):
2747         * editing/TextIterator.cpp:
2748         (WebCore::fullyClipsContents):
2749         (WebCore::shouldEmitExtraNewlineForNode):
2750         * editing/htmlediting.cpp:
2751         (WebCore::absoluteBoundsForLocalCaretRect):
2752         * html/HTMLFormControlElement.cpp:
2753         (WebCore::HTMLFormControlElement::isFocusable):
2754         * html/HTMLPlugInImageElement.cpp:
2755         (WebCore::HTMLPlugInImageElement::checkSizeChangeForSnapshotting):
2756         * html/HTMLSelectElement.cpp:
2757         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
2758         * html/shadow/SliderThumbElement.cpp:
2759         (WebCore::SliderThumbElement::setPositionFromPoint):
2760         * inspector/InspectorOverlay.cpp:
2761         (WebCore::buildObjectForElementInfo):
2762         * page/AutoscrollController.cpp:
2763         (WebCore::AutoscrollController::updateAutoscrollRenderer):
2764         * page/EventHandler.cpp:
2765         (WebCore::EventHandler::startPanScrolling):
2766         * page/FrameView.cpp:
2767         (WebCore::FrameView::embeddedContentBox):
2768         * page/GestureTapHighlighter.cpp:
2769         * page/SpatialNavigation.cpp:
2770         (WebCore::isScrollableNode):
2771         * page/animation/CSSPropertyAnimation.cpp:
2772         (WebCore::blendFunc):
2773         * platform/efl/RenderThemeEfl.cpp:
2774         (WebCore::RenderThemeEfl::baselinePosition):
2775         * plugins/PluginView.cpp:
2776         (WebCore::PluginView::invalidateWindowlessPluginRect):
2777         * rendering/InlineBox.cpp:
2778         (WebCore::InlineBox::logicalHeight):
2779         (WebCore::InlineBox::adjustPosition):
2780         * rendering/InlineElementBox.cpp:
2781         (WebCore::InlineElementBox::deleteLine):
2782         (WebCore::InlineElementBox::extractLine):
2783         (WebCore::InlineElementBox::attachLine):
2784         (WebCore::InlineElementBox::paint):
2785         (WebCore::InlineElementBox::nodeAtPoint):
2786         * rendering/InlineFlowBox.cpp:
2787         (WebCore::InlineFlowBox::addToLine):
2788         (WebCore::InlineFlowBox::addReplacedChildOverflow):
2789         * rendering/LayoutState.cpp:
2790         (WebCore::LayoutState::LayoutState):
2791         * rendering/RenderBlock.cpp:
2792         (WebCore::RenderBlock::simplifiedNormalFlowLayout):
2793         (WebCore::RenderBlock::markFixedPositionObjectForLayoutIfNeeded):
2794         (WebCore::RenderBlock::clearPercentHeightDescendantsFrom):
2795         (WebCore::RenderBlock::computeBlockPreferredLogicalWidths):
2796         (WebCore::RenderBlock::addFocusRingRects):
2797         * rendering/RenderBlockFlow.cpp:
2798         (WebCore::RenderBlockFlow::rebuildFloatingObjectSetFromIntrudingFloats):
2799         (WebCore::RenderBlockFlow::positionForPointWithInlineChildren):
2800         * rendering/RenderBlockLineLayout.cpp:
2801         (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForLine):
2802         (WebCore::RenderBlockFlow::layoutLineBoxes):
2803         * rendering/RenderBox.cpp:
2804         (WebCore::RenderBox::findAutoscrollable):
2805         (WebCore::computeBlockStaticDistance):
2806         (WebCore::RenderBox::positionForPoint):
2807         (WebCore::RenderBox::layoutOverflowRectForPropagation):
2808         * rendering/RenderBox.h:
2809         (WebCore::RenderBox::previousSiblingBox):
2810         (WebCore::RenderBox::nextSiblingBox):
2811         (WebCore::RenderBox::parentBox):
2812         (WebCore::RenderBox::firstChildBox):
2813         (WebCore::RenderBox::lastChildBox):
2814         * rendering/RenderBoxModelObject.cpp:
2815         (WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
2816         (WebCore::RenderBoxModelObject::computeStickyPositionConstraints):
2817         (WebCore::RenderBoxModelObject::constrainingRectForStickyPosition):
2818         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2819         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
2820         * rendering/RenderElement.cpp:
2821         (WebCore::RenderElement::removeChildInternal):
2822         (WebCore::RenderElement::styleWillChange):
2823         (WebCore::RenderElement::repaintAfterLayoutIfNeeded):
2824         * rendering/RenderEmbeddedObject.cpp:
2825         (WebCore::RenderEmbeddedObject::layout):
2826         * rendering/RenderFieldset.cpp:
2827         (WebCore::RenderFieldset::findLegend):
2828         * rendering/RenderFlowThread.cpp:
2829         (WebCore::RenderFlowThread::adjustedPositionRelativeToOffsetParent):
2830         (WebCore::RenderFlowThread::currentActiveRenderBox):
2831         * rendering/RenderFlowThread.h:
2832         * rendering/RenderFullScreen.cpp:
2833         (WebCore::RenderFullScreen::unwrapRenderer):
2834         * rendering/RenderImage.cpp:
2835         (WebCore::RenderImage::layoutShadowControls):
2836         (WebCore::RenderImage::computeIntrinsicRatioInformation):
2837         * rendering/RenderInline.cpp:
2838         (WebCore::RenderInline::absoluteRects):
2839         (WebCore::RenderInline::addFocusRingRects):
2840         * rendering/RenderLayer.cpp:
2841         (WebCore::RenderLayer::updateLayerPosition):
2842         (WebCore::RenderLayer::perspectiveTransform):
2843         (WebCore::RenderLayer::perspectiveOrigin):
2844         (WebCore::parentLayerCrossFrame):
2845         (WebCore::RenderLayer::enclosingScrollableLayer):
2846         (WebCore::RenderLayer::resize):
2847         (WebCore::RenderLayer::scrollsOverflow):
2848         (WebCore::computeReferenceBox):
2849         (WebCore::RenderLayer::calculateClipRects):
2850         * rendering/RenderLayer.h:
2851         * rendering/RenderLayerBacking.cpp:
2852         (WebCore::RenderLayerBacking::updateTransform):
2853         (WebCore::RenderLayerBacking::updateGeometry):
2854         (WebCore::RenderLayerBacking::resetContentsRect):
2855         (WebCore::RenderLayerBacking::positionOverflowControlsLayers):
2856         (WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundImage):
2857         (WebCore::RenderLayerBacking::contentsBox):
2858         (WebCore::RenderLayerBacking::backgroundBoxForPainting):
2859         (WebCore::RenderLayerBacking::startAnimation):
2860         (WebCore::RenderLayerBacking::startTransition):
2861         * rendering/RenderLineBoxList.cpp:
2862         (WebCore::RenderLineBoxList::rangeIntersectsRect):
2863         * rendering/RenderMediaControlElements.cpp:
2864         (WebCore::RenderMediaVolumeSliderContainer::layout):
2865         * rendering/RenderMultiColumnFlowThread.cpp:
2866         (WebCore::RenderMultiColumnFlowThread::firstColumnSetOrSpanner):
2867         (WebCore::RenderMultiColumnFlowThread::nextColumnSetOrSpannerSiblingOf):
2868         (WebCore::RenderMultiColumnFlowThread::previousColumnSetOrSpannerSiblingOf):
2869         (WebCore::RenderMultiColumnFlowThread::resolveMovedChild):
2870         (WebCore::isValidColumnSpanner):
2871         (WebCore::RenderMultiColumnFlowThread::handleSpannerRemoval):
2872         * rendering/RenderNamedFlowThread.cpp:
2873         (WebCore::RenderNamedFlowThread::getRanges):
2874         * rendering/RenderObject.cpp:
2875         (WebCore::RenderObject::computeRectForRepaint):
2876         (WebCore::RenderObject::showRegionsInformation):
2877         (WebCore::RenderObject::showRenderObject):
2878         (WebCore::RenderObject::mapLocalToContainer):
2879         (WebCore::RenderObject::pushMappingToContainer):
2880         (WebCore::RenderObject::mapAbsoluteToLocalPoint):
2881         (WebCore::RenderObject::addAnnotatedRegions):
2882         * rendering/RenderTable.cpp:
2883         (WebCore::RenderTable::nodeAtPoint):
2884         * rendering/RenderTextControlMultiLine.cpp:
2885         (WebCore::RenderTextControlMultiLine::layoutSpecialExcludedChild):
2886         * rendering/RenderTheme.cpp:
2887         (WebCore::RenderTheme::baselinePosition):
2888         * rendering/RenderThemeGtk.cpp:
2889         (WebCore::RenderThemeGtk::baselinePosition):
2890         (WebCore::centerRectVerticallyInParentInputElement):
2891         * rendering/RenderThemeIOS.mm:
2892         (WebCore::RenderThemeIOS::baselinePosition):
2893         * rendering/RenderThemeSafari.cpp:
2894         (WebCore::RenderThemeSafari::baselinePosition):
2895         * rendering/RenderThemeWin.cpp:
2896         (WebCore::RenderThemeWin::paintSearchFieldCancelButton):
2897         (WebCore::RenderThemeWin::paintSearchFieldResultsDecorationPart):
2898         (WebCore::RenderThemeWin::paintSearchFieldResultsButton):
2899         * rendering/RenderTreeAsText.cpp:
2900         (WebCore::RenderTreeAsText::writeRenderObject):
2901         (WebCore::externalRepresentation):
2902         * rendering/RenderView.cpp:
2903         (WebCore::RenderView::paintBoxDecorations):
2904         * rendering/RootInlineBox.cpp:
2905         (WebCore::RootInlineBox::setLineBreakInfo):
2906         * rendering/line/BreakingContextInlineHeaders.h:
2907         (WebCore::BreakingContext::handleOutOfFlowPositioned):
2908         (WebCore::BreakingContext::handleFloat):
2909         (WebCore::BreakingContext::handleReplaced):
2910         * rendering/line/LineBreaker.cpp:
2911         (WebCore::LineBreaker::skipTrailingWhitespace):
2912         (WebCore::LineBreaker::skipLeadingWhitespace):
2913         * rendering/mathml/RenderMathMLUnderOver.cpp:
2914         (WebCore::RenderMathMLUnderOver::layout):
2915         * svg/graphics/SVGImage.cpp:
2916         (WebCore::SVGImage::embeddedContentBox):
2917
2918 2014-10-17  Andreas Kling  <akling@apple.com>
2919
2920         Get rid of wrapperContext() in DOM bindings.
2921         <https://webkit.org/b/137834>
2922
2923         Reviewed by Chris Dumez.
2924
2925         The "wrapper context" is always the DOMWrapperWorld, and since we're passing that around
2926         already, we don't need a separate mechanism to get at the context.
2927
2928         The context is extra data stored in the DOM object's JSC::Weak (the wrapper GC object.)
2929
2930         * bindings/js/JSDOMBinding.h:
2931         (WebCore::setInlineCachedWrapper):
2932         (WebCore::cacheWrapper):
2933         (WebCore::wrapperContext): Deleted.
2934         * bindings/scripts/CodeGeneratorJS.pm:
2935         (GenerateHeader):
2936
2937 2014-10-17  Benjamin Poulain  <benjamin@webkit.org>
2938
2939         Make a better use of the available registers when compiling nested selector lists
2940         https://bugs.webkit.org/show_bug.cgi?id=137802
2941
2942         Reviewed by Andreas Kling.
2943
2944         Previously, when compiling a nested selector list, the compiler would start by pushing all
2945         the allocated registers to the stack to free them for the compiled selector list.
2946         While neat to ensure register allocation is correct, this is very inefficient.
2947
2948         This patch brings the first step for reducing the overhead. Instead of pushing everything
2949         to the stack, we just push as many registers as we need for compiling the selector list.
2950
2951         In most cases, we have so many registers that we don't even need to push anything to the stack.
2952
2953         Test: fast/selectors/nth-child-of-register-requirement.html
2954
2955         * cssjit/SelectorCompiler.cpp:
2956         Add an explicit type for SelectorList to keep information aggregated from all
2957         SelectorFragmentList inside it.
2958
2959         SelectorFragmentList is also extended to include its register and stack requirements.
2960         This information is then used to create a SelectorList and to compile the SelectorFragmentList.
2961
2962         (WebCore::SelectorCompiler::hasAnyCombinators):
2963         We only change the elementAddressRegister when moving over combinators. This is used to detect
2964         if a selector list clobber the elementAddressRegister or leave it untouched.
2965
2966         (WebCore::SelectorCompiler::computeBacktrackingMemoryRequirements):
2967         (WebCore::SelectorCompiler::computeBacktrackingInformation):
2968         Instead of returning a BacktrackingMemoryRequirements, update the SelectorFragmentList and SelectorList directly.
2969
2970         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesSelectorList):
2971         This is where the fun happen.
2972         First step is keep the input untouched. For now it is simply pushed on the stack. This can be improved later.
2973
2974         Then we find how many allocated registers we need to save to compile the input selector list. We push those registers
2975         to the stack and give them back to the register allocator.
2976
2977         With enough registers we can now compile the nested selector list. The code has changed a bit for efficiency. Instead
2978         of creating a shortcut for success case, the code now exit on error and proceed on success. This is the general pattern
2979         of SelectorCompiler and it is quite a bit more efficient in the common cases.
2980
2981         Finally, we reallocate the registers and get their values back from the stack. The "tail" is duplicated but that's fine
2982         because in the vast majority of cases it is 1 or 2 pop.
2983
2984         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
2985         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChildOf):
2986         * cssjit/StackAllocator.h:
2987         (WebCore::StackAllocator::push):
2988
2989 2014-10-17  Chris Dumez  <cdumez@apple.com>
2990
2991         Use is<>() / downcast<>() for StyleImage
2992         https://bugs.webkit.org/show_bug.cgi?id=137824
2993
2994         Reviewed by Andreas Kling.
2995
2996         Use is<>() / downcast<>() for StyleImage and clean up the surrouding
2997         code.
2998
2999         No new tests, no behavior change.
3000
3001         * css/CSSCursorImageValue.cpp:
3002         (WebCore::CSSCursorImageValue::detachPendingImage):
3003         (WebCore::CSSCursorImageValue::cachedImage):
3004         (WebCore::CSSCursorImageValue::cachedImageURL):
3005         * css/CSSImageSetValue.cpp:
3006         (WebCore::CSSImageSetValue::detachPendingImage):
3007         (WebCore::CSSImageSetValue::~CSSImageSetValue):
3008         (WebCore::CSSImageSetValue::cachedImageSet):
3009         (WebCore::CSSImageSetValue::hasFailedOrCanceledSubresources):
3010         * css/CSSImageValue.cpp:
3011         (WebCore::CSSImageValue::detachPendingImage):
3012         (WebCore::CSSImageValue::cachedImage):
3013         (WebCore::CSSImageValue::hasFailedOrCanceledSubresources):
3014         * css/StyleResolver.cpp:
3015         (WebCore::StyleResolver::loadPendingShapeImage):
3016         (WebCore::StyleResolver::loadPendingImages):
3017         * page/PageSerializer.cpp:
3018         (WebCore::PageSerializer::retrieveResourcesForProperties):
3019         * page/animation/CSSPropertyAnimation.cpp:
3020         (WebCore::blendFunc):
3021         * rendering/style/StyleCachedImage.h:
3022         * rendering/style/StyleCachedImageSet.h:
3023         * rendering/style/StyleGeneratedImage.h:
3024         * rendering/style/StyleImage.h:
3025         * rendering/style/StylePendingImage.h:
3026
3027 2014-10-17  Dean Jackson  <dino@apple.com>
3028
3029         [Media] Always update controls for <audio> since they are always visible
3030         https://bugs.webkit.org/show_bug.cgi?id=137829
3031         <rdar://problem/18693987>
3032
3033         Reviewed by Brent Fulgham.
3034
3035         Revision 174756 made a change to only update the display of the controls
3036         while they are visible. However, <audio> elements didn't detect visibility
3037         the same way, since their controls do not auto-hide.
3038
3039         Change controlsAreHidden to check if we're an audio element.
3040
3041         * Modules/mediacontrols/mediaControlsApple.js:
3042         (Controller.prototype.controlsAreHidden): Audio elements do not auto-hide their controls.
3043
3044 2014-10-17  peavo@outlook.com  <peavo@outlook.com>
3045
3046         [WinCairo] Accelerated compositing is not implemented.
3047         https://bugs.webkit.org/show_bug.cgi?id=137345
3048
3049         Reviewed by Brent Fulgham.
3050
3051         This patch is based on GTK, and the texture mapper graphics layer type.
3052
3053         * WebCore.vcxproj/copyForwardingHeaders.cmd: Copy texmap headers.
3054         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp: Added method and flag indicating whether animation has started.
3055         (WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
3056         (WebCore::GraphicsLayerTextureMapper::addAnimation):
3057         * platform/graphics/texmap/GraphicsLayerTextureMapper.h: Ditto.
3058         (WebCore::GraphicsLayerTextureMapper::startedAnimation):
3059         * platform/graphics/texmap/TextureMapperShaderProgram.cpp: Use same precision for uniform in vertex shader as in fragment shader.
3060         Otherwise glLinkProgram() will fail, and nothing will be rendered.
3061
3062 2014-10-17  Alexey Proskuryakov  <ap@apple.com>
3063
3064         [iOS] Crash when load is canceled while waiting for the user to type HTTP authentication credentials
3065         https://bugs.webkit.org/show_bug.cgi?id=137826
3066         rdar://problem/17329599
3067
3068         Reviewed by Brady Eidson.
3069
3070         No new tests, as we don't have a way to simulate details of user interaction with
3071         an auth dialog.
3072
3073         * platform/network/cf/ResourceHandleCFNet.cpp:
3074         (WebCore::ResourceHandle::receivedCredential):
3075         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential):
3076         (WebCore::ResourceHandle::receivedRequestToPerformDefaultHandling):
3077         (WebCore::ResourceHandle::receivedChallengeRejection):
3078         Added null checks before passing m_connection for CFNetwork functions, making this
3079         match what Mac code does when sending a message to a nil receiver.
3080
3081 2014-10-17  Simon Fraser  <simon.fraser@apple.com>
3082
3083         Fix the iOS build.
3084
3085         * platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.mm:
3086         (WebCore::AVTrackPrivateAVFObjCImpl::languageForAVMediaSelectionOption):
3087
3088 2014-10-16  Jer Noble  <jer.noble@apple.com>
3089
3090         [Mac] Represent AVMediaSelectionOptions as AudioTracks
3091         https://bugs.webkit.org/show_bug.cgi?id=137474
3092
3093         Reviewed by Brent Fulgham.
3094
3095         Test: http/tests/media/hls/hls-audio-tracks.html
3096
3097         Support selecting audio "tracks" in HLS streams by exposing AVMediaSelectionOptions
3098         as entries in the video's AudioTrackList.
3099
3100         AVMediaSessionGroups and AVPlayerItems don't have KVO or notifications to track when options
3101         are selected and deselected, so wrap AVMediaSessionGroup and AVMediaSessionOption in C++
3102         wrappers. Each AVMediaSelectionGroup can have only one AVMediaSelectionOption selected at a
3103         time, so the wrapper will take care of answering which AVMediaSelectionOption is currently
3104         selected, as without KVO notifications, asking the AVMediaSelectionGroup directly is
3105         inconsistent. Because setting the selected option multiple times in the same run-loop can
3106         cause flakiness, coalesce calls to setSelectedOption() by setting a one-shot timer to do
3107         the actual selection in the next run-loop.
3108
3109         * platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.h: Added.
3110         (WebCore::MediaSelectionOptionAVFObjC::avMediaSelectionOption):
3111         (WebCore::MediaSelectionOptionAVFObjC::clearGroup): Clear backpointer to group from option.
3112         (WebCore::MediaSelectionGroupAVFObjC::selectedOption): Simple accessor.
3113         (WebCore::MediaSelectionGroupAVFObjC::options):  Simple accessor.
3114         (WebCore::MediaSelectionGroupAVFObjC::avMediaSelectionGroup): Simple accessor.
3115         * platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.mm: Added.
3116         (WebCore::MediaSelectionOptionAVFObjC::create): Simple factory method.
3117         (WebCore::MediaSelectionOptionAVFObjC::MediaSelectionOptionAVFObjC): Simple constructor.
3118         (WebCore::MediaSelectionOptionAVFObjC::setSelected): Pass through to MediaSelectionGroupAVFObjC.
3119         (WebCore::MediaSelectionOptionAVFObjC::selected): Ditto.
3120         (WebCore::MediaSelectionOptionAVFObjC::index): Return index of this object in the group's object.
3121         (WebCore::MediaSelectionGroupAVFObjC::create):
3122         (WebCore::MediaSelectionGroupAVFObjC::MediaSelectionGroupAVFObjC):
3123         (WebCore::MediaSelectionGroupAVFObjC::~MediaSelectionGroupAVFObjC):
3124         (WebCore::MediaSelectionGroupAVFObjC::updateOptions): Discover added or removed options.
3125         (WebCore::MediaSelectionGroupAVFObjC::setSelectedOption): Set a one shot timer to coalesce multiple calls.
3126         (WebCore::MediaSelectionGroupAVFObjC::selectionTimerFired): Set the selected AVSelectionOption.
3127
3128         Modify AVTrackPrivateAVFObjCImpl to support both AVPlayerItemTracks and these new
3129         MediaSelectionOptionAVFObjC objects.
3130
3131         * platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.h:
3132         (WebCore::AVTrackPrivateAVFObjCImpl::mediaSelectionOption): Simple accessor.
3133         * platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.mm:
3134         (WebCore::AVTrackPrivateAVFObjCImpl::AVTrackPrivateAVFObjCImpl):  Simple constructor.
3135         (WebCore::AVTrackPrivateAVFObjCImpl::~AVTrackPrivateAVFObjCImpl): Simple destructor.
3136         (WebCore::AVTrackPrivateAVFObjCImpl::enabled): Use MediaSelectionOptionAVFObjC, if present.
3137         (WebCore::AVTrackPrivateAVFObjCImpl::setEnabled): Ditto.
3138         (WebCore::AVTrackPrivateAVFObjCImpl::audioKind): Ditto.
3139         (WebCore::AVTrackPrivateAVFObjCImpl::videoKind): Ditto.
3140         (WebCore::AVTrackPrivateAVFObjCImpl::index): Ditto.
3141         (WebCore::AVTrackPrivateAVFObjCImpl::id): Ditto.
3142         (WebCore::AVTrackPrivateAVFObjCImpl::label): Ditto.
3143         (WebCore::AVTrackPrivateAVFObjCImpl::language): Ditto.
3144         (WebCore::AVTrackPrivateAVFObjCImpl::languageForAVMediaSelectionOption): Ditto.
3145         (WebCore::AVTrackPrivateAVFObjCImpl::trackID): Ditto.
3146
3147         Allow AudioTrackPrivateAVFObjC and VideoTrackPrivateAVFObjC to be created with
3148         a MediaSelectionOptionAVFObjC.
3149
3150         * platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.h:
3151         (WebCore::AudioTrackPrivateAVFObjC::create): Takes a MediaSelectionOptionAVFObjC.
3152         * platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm:
3153         (WebCore::AudioTrackPrivateAVFObjC::AudioTrackPrivateAVFObjC): Simple constructor.
3154         (WebCore::AudioTrackPrivateAVFObjC::setMediaSelectionOption): Create a new AVTrackPrivateAVFObjCImpl.
3155         (WebCore::AudioTrackPrivateAVFObjC::mediaSelectionOption): Simple accessor.
3156         * platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.cpp:
3157         (WebCore::VideoTrackPrivateAVFObjC::VideoTrackPrivateAVFObjC): Simple constructor.
3158         (WebCore::VideoTrackPrivateAVFObjC::setMediaSelectonOption): Create a new AVTrackPrivateAVFObjCImpl.
3159         (WebCore::VideoTrackPrivateAVFObjC::mediaSelectionOption): Simple accessor.
3160         * platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.h:
3161
3162         Because IDs are not necessarily unique across AVPlayerItemTracks and AVMediaSelectionOptions,
3163         use the index of the track or option instead of it's self-declared ID for ordering for the
3164         trackIndex.
3165
3166         * platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm:
3167         (WebCore::AudioTrackPrivateAVFObjC::resetPropertiesFromTrack):
3168         * platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.mm:
3169         (WebCore::VideoTrackPrivateMediaSourceAVFObjC::resetPropertiesFromTrack):
3170
3171         Rather than making allowing the AVPlayerItem to automatically select the "best"
3172         AVMediaSelectionOption, select the automatic options when creating the AVPlayerItem
3173         and thereafter allow the users manual selections "stick".
3174
3175         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
3176         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3177         (WebCore::MediaPlayerPrivateAVFoundationObjC::ensureAVPlayer):
3178         (WebCore::MediaPlayerPrivateAVFoundationObjC::ensureAVPlayerItem):
3179
3180         Determine whether any MediaSelectionOptionsAVFObjC have been added or removed and send trackChange events accordingly.
3181
3182         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3183         (WebCore::determineChangedTracksFromNewTracksAndOldItems): Added.
3184         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateAudioTracks): Search for updated selection options.
3185         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoTracks): Ditto.
3186         (WebCore::MediaPlayerPrivateAVFoundationObjC::safeMediaSelectionGroupForAudibleMedia): Return selection group, if available.
3187         (WebCore::MediaPlayerPrivateAVFoundationObjC::safeMediaSelectionGroupForVisualMedia): Ditto.
3188         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksDidChange): Filter out AVPlayerItemTracks without
3189             AVAssetTracks, as these will be represented by MediaSelectionGroupObjCs instead.
3190         
3191         Add new files to project.
3192         * WebCore.xcodeproj/project.pbxproj:
3193
3194 2014-10-17  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
3195
3196         [EFL] window.screen.width returns wrong value if more displays are available
3197         https://bugs.webkit.org/show_bug.cgi?id=137778
3198
3199         Reviewed by Gyuyoung Kim.
3200
3201         ecore_x_screen_size_get() retrieves the size of Ecore_X_Screen, for example,
3202         having two displays of 1680x1050, it will return 3360x1050.
3203
3204         Unlike EFL's MiniBrowser, Firefox and Chrome return screen of the current display.
3205
3206         No new tests. Hardware specific bug including multiple displays.
3207
3208         * platform/efl/PlatformScreenEfl.cpp:
3209         (WebCore::screenRect):
3210         Use ecore's xrandr to determine the screen on which browser window is displayed.
3211
3212 2014-10-17  Carlos Garcia Campos  <cgarcia@igalia.com>
3213
3214         [GLIB] Add API to GMainLoopSource to schedule sources after a delay in microseconds
3215         https://bugs.webkit.org/show_bug.cgi?id=137782
3216
3217         Reviewed by Sergio Villar Senin.
3218
3219         * platform/gtk/SharedTimerGtk.cpp:
3220         (WebCore::setSharedTimerFireInterval): Use microseconds instead of
3221         milliseconds.
3222
3223 2014-10-17  Carlos Garcia Campos  <cgarcia@igalia.com>
3224
3225         [GTK] Move touch events handling from Platform to WebKit2
3226         https://bugs.webkit.org/show_bug.cgi?id=137735
3227
3228         Reviewed by Sergio Villar Senin.
3229
3230         Remove GtkTouchContextHelper.
3231
3232         * PlatformGTK.cmake:
3233         * platform/gtk/GtkTouchContextHelper.cpp: Removed.
3234         * platform/gtk/GtkTouchContextHelper.h: Removed.
3235
3236 2014-10-17  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3237
3238         Remove unused function in WorkerThreadableLoader.h 
3239         https://bugs.webkit.org/show_bug.cgi?id=137811
3240
3241         Reviewed by Csaba Osztrogon√°c.
3242
3243         mainThreadCreateLoader() isn't used anywhere. Even there is no implementation.
3244
3245         * loader/WorkerThreadableLoader.h:
3246
3247 2014-10-15  Yusuke Suzuki  <utatane.tea@gmail.com>
3248
3249         CSS Selectors Level 4: Implement :matches in SelectorChecker
3250         https://bugs.webkit.org/show_bug.cgi?id=137393
3251
3252         Reviewed by Benjamin Poulain.
3253
3254         In this patch, we introduce initial :matches implementation.
3255         In this current implementation, we don't consider pseudo elements.
3256
3257         Test: fast/selectors/querySelector-matches.html
3258
3259         * css/SelectorChecker.cpp:
3260         (WebCore::SelectorChecker::checkOne):
3261
3262 2014-10-16  Yusuke Suzuki  <utatane.tea@gmail.com>
3263
3264         CSS JIT: Introduce StackAllocator::addressOf
3265         https://bugs.webkit.org/show_bug.cgi?id=137771
3266
3267         Reviewed by Benjamin Poulain.
3268
3269         Introduce StackAllocator::addressOf and drop offsetToStackReference, it's too primitive.
3270
3271         * cssjit/SelectorCompiler.cpp:
3272         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
3273         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateParentElementTreeWalker):
3274         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
3275         (WebCore::SelectorCompiler::SelectorCodeGenerator::loadCheckingContext):
3276         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAdjacentBacktrackingTail):
3277         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDescendantBacktrackingTail):
3278         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstLink):
3279         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateStoreLastVisitedElement):
3280         * cssjit/StackAllocator.h:
3281         (WebCore::StackAllocator::addressOf):
3282         (WebCore::StackAllocator::offsetToStackReference):
3283
3284 2014-10-16  Alexey Proskuryakov  <ap@apple.com>
3285
3286         REGRESSION (r169024): Undetermined text is not displayed in the search field of Adobe Help Website
3287         https://bugs.webkit.org/show_bug.cgi?id=137679
3288         rdar://problem/18450335
3289
3290         Reviewed by Enrica Casucci.
3291
3292         Test: platform/mac/editing/input/selected-composed-text-painting.html
3293
3294         * rendering/InlineTextBox.cpp: (WebCore::InlineTextBox::paint): We do not paint
3295         selection beckground for unconfirmed text with underlines, so we should use a regular
3296         style for text painting, as well.
3297
3298 2014-10-16  Chris Dumez  <cdumez@apple.com>
3299
3300         Use is<>() / downcast<>() for BasicShape subclasses
3301         https://bugs.webkit.org/show_bug.cgi?id=137766
3302
3303         Reviewed by Andreas Kling.
3304
3305         Use is<>() / downcast<>() for BasicShape subclasses and clean up the
3306         surrounding code.
3307
3308         No new tests, no behavior change.
3309
3310         * css/BasicShapeFunctions.cpp:
3311         (WebCore::valueForBasicShape):
3312         (WebCore::basicShapeForValue):
3313         * css/BasicShapeFunctions.h:
3314         * css/CSSComputedStyleDeclaration.cpp:
3315         (WebCore::shapePropertyValue):
3316         * page/animation/CSSPropertyAnimation.cpp:
3317         (WebCore::blendFunc):
3318         * rendering/ClipPathOperation.h:
3319         (WebCore::ShapeClipPathOperation::create):
3320         Take a PassRef<BasicShape> in argument to make it obvious it is never
3321         null.
3322
3323         (WebCore::ShapeClipPathOperation::basicShape):
3324         Return a reference instead of a pointer as it can never return null.
3325
3326         (WebCore::ShapeClipPathOperation::windRule):
3327         (WebCore::ShapeClipPathOperation::pathForReferenceRect):
3328         Make it non-const due to the const-correctness of Ref::get().
3329
3330         (WebCore::ShapeClipPathOperation::ShapeClipPathOperation):
3331         * rendering/RenderBlock.cpp:
3332         (WebCore::RenderBlock::nodeAtPoint):
3333         * rendering/RenderLayer.cpp:
3334         (WebCore::RenderLayer::setupClipPath):
3335         * rendering/shapes/Shape.cpp:
3336         (WebCore::Shape::createShape):
3337         * rendering/shapes/Shape.h:
3338         * rendering/shapes/ShapeOutsideInfo.cpp:
3339         (WebCore::ShapeOutsideInfo::computedShape):
3340         * rendering/style/BasicShapes.cpp:
3341         (WebCore::BasicShape::canBlend):
3342         (WebCore::BasicShapeCircle::blend):
3343         (WebCore::BasicShapeEllipse::blend):
3344         (WebCore::BasicShapePolygon::blend):
3345         (WebCore::BasicShapeInset::blend):
3346         * rendering/style/BasicShapes.h:
3347         * rendering/svg/SVGRenderingContext.cpp:
3348         (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
3349
3350 2014-10-16  Chris Dumez  <cdumez@apple.com>
3351
3352         Leverage the new RenderElement::m_isCSSAnimating flag in more places
3353         https://bugs.webkit.org/show_bug.cgi?id=137786
3354
3355         Reviewed by Simon Fraser.
3356
3357         Leverage the new RenderElement::m_isCSSAnimating flag that was introduced
3358         in r174703 in more places, for performance. This avoids doing extra work
3359         for renderers on which we are not running animations on. This patch also
3360         updates the API a bit to use more references instead of pointers, making
3361         it clear the RenderElement cannot be null and thus avoiding unnecessary
3362         null checks.
3363
3364         No new tests, no behavior change.
3365
3366         * css/CSSComputedStyleDeclaration.cpp:
3367         (WebCore::computeRenderStyleForProperty):
3368         * page/animation/AnimationController.cpp:
3369         (WebCore::AnimationControllerPrivate::ensureCompositeAnimation):
3370         (WebCore::AnimationControllerPrivate::clear):
3371         (WebCore::AnimationControllerPrivate::updateAnimationTimerForRenderer):
3372         (WebCore::AnimationControllerPrivate::isRunningAnimationOnRenderer):
3373         (WebCore::AnimationControllerPrivate::isRunningAcceleratedAnimationOnRenderer):
3374         (WebCore::AnimationControllerPrivate::pauseAnimationAtTime):
3375         (WebCore::AnimationControllerPrivate::pauseTransitionAtTime):
3376         (WebCore::AnimationControllerPrivate::getAnimatedStyleForRenderer):
3377         (WebCore::AnimationController::cancelAnimations):
3378         (WebCore::AnimationController::updateAnimations):
3379         (WebCore::AnimationController::getAnimatedStyleForRenderer):
3380         (WebCore::AnimationController::notifyAnimationStarted):
3381         (WebCore::AnimationController::isRunningAnimationOnRenderer):
3382         (WebCore::AnimationController::isRunningAcceleratedAnimationOnRenderer):
3383         * page/animation/AnimationController.h:
3384         * page/animation/AnimationControllerPrivate.h:
3385         * rendering/RenderElement.cpp:
3386         (WebCore::RenderElement::willBeDestroyed):
3387         * rendering/RenderLayer.cpp:
3388         (WebCore::RenderLayer::currentTransform):
3389         * rendering/RenderLayerBacking.cpp:
3390         (WebCore::RenderLayerBacking::updateGeometry):
3391         (WebCore::RenderLayerBacking::notifyAnimationStarted):
3392         * rendering/RenderLayerCompositor.cpp:
3393         (WebCore::RenderLayerCompositor::requiresCompositingForAnimation):
3394         (WebCore::RenderLayerCompositor::isRunningAcceleratedTransformAnimation):
3395
3396 2014-10-16  Adrien Destugues  <pulkomandy@gmail.com>
3397
3398         Missing RefPtr.release() calls in TextureMapper
3399         https://bugs.webkit.org/show_bug.cgi?id=137777
3400
3401         Reviewed by Chris Dumez.
3402
3403         No new tests: no functional change, cleanup/optimization.
3404
3405         Avoids useless ref/deref cycle when returning from functions.
3406
3407         * platform/graphics/texmap/TextureMapper.cpp:
3408         (WebCore::TextureMapper::acquireTextureFromPool):
3409         * platform/graphics/texmap/TextureMapperLayer.cpp:
3410         (WebCore::TextureMapperLayer::paintIntoSurface):
3411
3412 2014-10-16  Chris Dumez  <cdumez@apple.com>
3413
3414         Use is<>() / downcast<>() for ContentData subclasses
3415         https://bugs.webkit.org/show_bug.cgi?id=137768
3416
3417         Reviewed by Andreas Kling.
3418
3419         Use is<>() / downcast<>() for ContentData subclasses.
3420
3421         No new tests, no behavior change.
3422
3423         * css/CSSComputedStyleDeclaration.cpp:
3424         (WebCore::contentToCSSValue):
3425         * css/StyleResolver.cpp:
3426         (WebCore::StyleResolver::loadPendingImages):
3427         * rendering/RenderElement.cpp:
3428         (WebCore::RenderElement::createFor):
3429         * rendering/style/ContentData.h:
3430         (WebCore::operator==):
3431         * rendering/style/RenderStyle.cpp:
3432         (WebCore::RenderStyle::setContent):
3433
3434 2014-10-16  Commit Queue  <commit-queue@webkit.org>
3435
3436         Unreviewed, rolling out r174744.
3437         https://bugs.webkit.org/show_bug.cgi?id=137790
3438
3439         Caused another WebGL conformance test to fail (Requested by
3440         rfong on #webkit).
3441
3442         Reverted changeset:
3443