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