Media Controls stop updating after hovering for a few seconds.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2015-05-20  Roger Fong  <roger_fong@apple.com>
2
3         Media Controls stop updating after hovering for a few seconds.
4         https://bugs.webkit.org/show_bug.cgi?id=144770.
5         <rdar://problem/19823121>
6
7         Reviewed by Jer Noble.
8
9         * Modules/mediacontrols/mediaControlsApple.js:
10         (Controller.prototype.createBase):
11         We should never hide controls immediately as a result of mousing out of the controls.
12         It should only happen when the mouse leaves the video entirely.
13         (Controller.prototype.updateTimelineMetricsIfNeeded):
14         Don’t update if controls are hidden, timeline dimensions will be 0.
15         (Controller.prototype.handlePanelTransitionEnd): 
16         Instead of adjusting visibility via adding and removing classes,
17         remove controls entirely from the tree.
18         (Controller.prototype.showControls):
19         Add controls back into the tree when showing controls.
20         (Controller.prototype.updateForShowingControls):
21         Helper method for showControls.
22         (Controller.prototype.controlsAreHidden):
23         Controls also hidden if removed from tree.
24
25         Remove forceUpdate logic, no longer necessary.
26         (Controller.prototype.handleDurationChange): 
27         (Controller.prototype.updateProgress):
28         (Controller.prototype.updateTime):
29
30         Override methods to use add and remove panelContainer for iOS.
31         * Modules/mediacontrols/mediaControlsiOS.js:
32         (ControllerIOS.prototype.handlePanelTransitionEnd):
33         (ControllerIOS.prototype.showControls):
34         (ControllerIOS.prototype.controlsAreHidden):
35
36 2015-05-20  Eric Carlson  <eric.carlson@apple.com>
37
38         [Mac] inform media session of all state changes
39         https://bugs.webkit.org/show_bug.cgi?id=145222
40
41         Reviewed by Dean Jackson.
42
43         * html/HTMLMediaElement.cpp:
44         (WebCore::HTMLMediaElement::~HTMLMediaElement): Call updateMediaState.
45         (WebCore::HTMLMediaElement::mediaPlayerEngineUpdated): Ditto.
46         (WebCore::HTMLMediaElement::mediaPlayerFirstVideoFrameAvailable): Ditto.
47         (WebCore::HTMLMediaElement::removeEventListener): Ditto.
48         (WebCore::HTMLMediaElement::enqueuePlaybackTargetAvailabilityChangedEvent): Ditto.
49
50 2015-05-20  Daniel Bates  <dabates@apple.com>
51
52         AX: AutoFill button is not accessible with VoiceOver
53         https://bugs.webkit.org/show_bug.cgi?id=145200
54         <rdar://problem/20507480>
55
56         Reviewed by Chris Fleizach.
57
58         Add ARIA label and role attributes to the AutoFill button markup so that VoiceOver
59         can identify and interact with it.
60
61         Test: accessibility/input-auto-fill-button.html
62
63         * English.lproj/Localizable.strings: Add placeholder localized string for AutoFill button.
64         * html/TextFieldInputType.cpp:
65         (WebCore::TextFieldInputType::createAutoFillButton): Add ARIA label and role attributes.
66         * platform/LocalizedStrings.cpp:
67         (WebCore::AXAutoFillButtonText): Added; returns the localized string for the AutoFill button.
68         * platform/LocalizedStrings.h:
69         * platform/efl/LocalizedStringsEfl.cpp:
70         (WebCore::AXAutoFillButtonText): Ditto.
71         * platform/gtk/LocalizedStringsGtk.cpp:
72         (WebCore::AXAutoFillButtonText): Ditto.
73
74 2015-05-20  Dean Jackson  <dino@apple.com>
75
76         Label text for default buttons don’t have the correct white color
77         https://bugs.webkit.org/show_bug.cgi?id=145221
78         <rdar://problem/20985817>
79
80         Reviewed by Tim Horton.
81
82         Use a 85% solid white for the active text color on buttons.
83
84         As has been disappointingly pointed out in other patches, we don't
85         have a good way to test ActiveButtonText since it only applies at
86         paint time.
87
88         * rendering/RenderThemeMac.mm:
89         (WebCore::RenderThemeMac::systemColor): Move to an 85% solid white.
90
91 2015-05-20  Alexey Proskuryakov  <ap@apple.com>
92
93         ThreadableLoaderOptions::isolatedCopy() doesn't produce a copy that is safe for sending to another thread
94         https://bugs.webkit.org/show_bug.cgi?id=145217
95
96         Reviewed by Anders Carlsson.
97
98         Caught by existing tests, rarely. I don't know how to catch such bugs more reliably.
99
100         * loader/ThreadableLoader.cpp: (WebCore::ThreadableLoaderOptions::isolatedCopy):
101         * loader/ThreadableLoader.h:
102
103 2015-05-20  Tim Horton  <timothy_horton@apple.com>
104
105         Add a mechanism to opt-out of the automatic scaling applied to not-really-responsive sites
106         https://bugs.webkit.org/show_bug.cgi?id=144760
107
108         Reviewed by Darin Adler.
109
110         Add a new viewport property, shrink-to-fit, which can be used to disable
111         the automatic scaling introduced in r181400. This provides sites with a
112         way to tell WebKit that they're really sure they want to be laid out at
113         window-width/height, even if they fail to fit within that size.
114
115         * dom/ViewportArguments.cpp:
116         (WebCore::ViewportArguments::resolve):
117         (WebCore::findBooleanValue):
118         (WebCore::setViewportFeature):
119         * dom/ViewportArguments.h:
120         (WebCore::ViewportArguments::ViewportArguments):
121         (WebCore::ViewportArguments::operator==):
122         * page/ViewportConfiguration.cpp:
123         (WebCore::ViewportConfiguration::shouldIgnoreHorizontalScalingConstraints):
124         (WebCore::ViewportConfiguration::shouldIgnoreVerticalScalingConstraints):
125         (WebCore::ViewportConfiguration::webpageParameters):
126         (WebCore::ViewportConfiguration::textDocumentParameters):
127         (WebCore::ViewportConfiguration::imageDocumentParameters):
128         (WebCore::ViewportConfiguration::testingParameters):
129         (WebCore::booleanViewportArgumentIsSet):
130         (WebCore::ViewportConfiguration::updateConfiguration):
131         (WebCore::ViewportConfigurationTextStream::operator<<):
132         (WebCore::viewportArgumentUserZoomIsSet): Deleted.
133         * page/ViewportConfiguration.h:
134         (WebCore::ViewportConfiguration::Parameters::Parameters):
135         Plumb the shrink-to-fit viewport property through.
136         If shrink-to-fit is set to yes, or not set, we behave as usual; if it is
137         set to no, we will bail from shouldIgnore[Horizontal|Vertical]ScalingConstraints,
138         effectively disabling the automatic scaling introduced in r181400.
139
140 2015-05-20  Antti Koivisto  <antti@apple.com>
141
142         Assertion failure in WebCore::BidiRun::BidiRun()
143         https://bugs.webkit.org/show_bug.cgi?id=145203
144         rdar://problem/20958973
145
146         Reviewed by Andreas Kling.
147
148         Test: fast/text/text-combine-crash.html
149
150         * rendering/line/BreakingContext.h:
151         (WebCore::BreakingContext::handleText):
152
153             Renove !isCombined() check. RenderCombineText::combineText() doesn't
154             do any work unless needed and text may become uncombined too.
155
156         * rendering/line/LineBreaker.cpp:
157         (WebCore::LineBreaker::skipLeadingWhitespace):
158
159             Same here.
160
161 2015-05-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>
162
163         AudioContext resume/close/suspend should reject promises with a DOM exception in lieu of throwing exceptions
164         https://bugs.webkit.org/show_bug.cgi?id=145064
165
166         Reviewed by Darin Adler.
167
168         Rejecting resume/suspend/close promises with InvalidStateError values in case context is offline.
169         Removed unneeded calls to postTask for resolving/rejecting promises.
170         Adding promise rejection of DOM Exception values, 0 being equivalent of no error passed to reject callback.
171
172         Test: webaudio/audiocontext-promise-throwing.html
173
174         * Modules/webaudio/AudioContext.cpp:
175         (WebCore::AudioContext::suspendContext): Rejecting promise in lieu of throwing exception.
176         (WebCore::AudioContext::resumeContext): Ditto.
177         (WebCore::AudioContext::closeContext): Ditto.
178         * Modules/webaudio/AudioContext.h:
179         * bindings/js/JSAudioContextCustom.cpp:
180         (WebCore::JSAudioContext::suspend): Removing ExceptionCode handling.
181         (WebCore::JSAudioContext::resume): Ditto.
182         (WebCore::JSAudioContext::close): Ditto.
183         * bindings/js/JSDOMBinding.cpp:
184         (WebCore::createDOMException): Splitting DOM exception creation from throwing.
185         (WebCore::setDOMException): Ditto.
186         * bindings/js/JSDOMBinding.h: Adding createDOMException prototype.
187         * bindings/js/JSDOMPromise.h:
188         (WebCore::DeferredWrapper::reject<ExceptionCode>):
189
190 2015-05-20  Commit Queue  <commit-queue@webkit.org>
191
192         Unreviewed, rolling out r184645.
193         https://bugs.webkit.org/show_bug.cgi?id=145220
194
195         Broken build (Requested by jacob_nielsen on #webkit).
196
197         Reverted changeset:
198
199         "AX: AutoFill button is not accessible with VoiceOver"
200         https://bugs.webkit.org/show_bug.cgi?id=145200
201         http://trac.webkit.org/changeset/184645
202
203 2015-05-20  Daniel Bates  <dabates@apple.com>
204
205         AX: AutoFill button is not accessible with VoiceOver
206         https://bugs.webkit.org/show_bug.cgi?id=145200
207         <rdar://problem/20507480>
208
209         Reviewed by Chris Fleizach.
210
211         Add ARIA label and role attributes to the AutoFill button markup so that VoiceOver
212         can identify and interact with it.
213
214         Test: accessibility/input-auto-fill-button.html
215
216         * English.lproj/Localizable.strings: Add placeholder localized string for AutoFill button.
217         * html/TextFieldInputType.cpp:
218         (WebCore::TextFieldInputType::createAutoFillButton): Add ARIA label and role attributes.
219         * platform/LocalizedStrings.cpp:
220         (WebCore::AXAutoFillButtonText): Added; returns the localized string for the AutoFill button.
221         * platform/LocalizedStrings.h:
222         * platform/efl/LocalizedStringsEfl.cpp:
223         (WebCore::AXAutoFillButtonText): Ditto.
224         * platform/gtk/LocalizedStringsGtk.cpp:
225         (WebCore::AXAutoFillButtonText): Ditto.
226
227 2015-05-20  Alex Christensen  <achristensen@webkit.org>
228
229         [Content Extensions] Relax restrictions on triggers that match everything.
230         https://bugs.webkit.org/show_bug.cgi?id=145069
231
232         Reviewed by Benjamin Poulain.
233
234         Added API tests that cover the new functionality and test for correctness in behavior.
235
236         * contentextensions/CompiledContentExtension.cpp:
237         (WebCore::ContentExtensions::CompiledContentExtension::globalDisplayNoneSelectors):
238         * contentextensions/ContentExtensionCompiler.cpp:
239         (WebCore::ContentExtensions::addUniversalActionsToDFA):
240         (WebCore::ContentExtensions::compileRuleList):
241         Put universalActionsWithoutDomains into the DFA from filtersWithoutDomains and
242         put universalActionsWithDomains into the DFA from filtersWithDomains.        
243         * contentextensions/ContentExtensionError.cpp:
244         (WebCore::ContentExtensions::contentExtensionErrorCategory):
245         * contentextensions/ContentExtensionError.h:
246         Remove error codes for errors that are not errors any more.
247         * contentextensions/ContentExtensionsBackend.cpp:
248         (WebCore::ContentExtensions::ContentExtensionsBackend::actionsForResourceLoad):
249         * contentextensions/ContentExtensionsBackend.h:
250         * contentextensions/DFABytecode.h:
251         (WebCore::ContentExtensions::instructionSizeWithArguments):
252         * contentextensions/DFABytecodeCompiler.cpp:
253         (WebCore::ContentExtensions::set32Bits):
254         (WebCore::ContentExtensions::DFABytecodeCompiler::emitAppendAction):
255         (WebCore::ContentExtensions::DFABytecodeCompiler::emitJump):
256         (WebCore::ContentExtensions::DFABytecodeCompiler::emitCheckValue):
257         (WebCore::ContentExtensions::DFABytecodeCompiler::emitCheckValueRange):
258         (WebCore::ContentExtensions::DFABytecodeCompiler::compileNode):
259         (WebCore::ContentExtensions::DFABytecodeCompiler::compile):
260         (WebCore::ContentExtensions::DFABytecodeCompiler::emitTestFlagsAndAppendAction): Deleted.
261         * contentextensions/DFABytecodeCompiler.h:
262         * contentextensions/DFABytecodeInterpreter.cpp:
263         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretAppendAction):
264         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretTestFlagsAndAppendAction):
265         (WebCore::ContentExtensions::DFABytecodeInterpreter::actionsForDefaultStylesheetFromDFARoot):
266         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpret):
267         (WebCore::ContentExtensions::DFABytecodeInterpreter::actionsFromDFARoot): Deleted.
268         * contentextensions/DFABytecodeInterpreter.h:
269         Add a new bytecode AppendActionDefaultStylesheet to mark actions that are css-display-none
270         that need to be put in the default stylesheet to be ignored or not as a whole.
271         css-display-none actions with flags or domain rules and css-display-none actions 
272         after ignore-previous-rules actions are not to be in this precompiled stylesheet, but
273         they will be applied as needed per page.  The precompiled stylesheet is already applied
274         if no ignore-previous-rules action is triggered.
275         * loader/ResourceLoadInfo.h:
276
277 2015-05-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>
278
279         JS binding generator should create a member variable for each Promise attribute of an interface
280         https://bugs.webkit.org/show_bug.cgi?id=145056
281
282         Reviewed by Darin Adler.
283
284         For each attribute XXX whose type is Promise, a member m_XXXPromiseDeferred is created, its type being a JSC::Strong of JSPromiseDeferred.
285         The purpose is to enable custom getters to create the JSPromiseDeferred and store ino the class member to ensure the same promise is returned each time
286         the custom getter is called.
287         This patch will enable simplifying ReadableStreamReader custom binding.
288
289         Covered by added attribute in TestObj.idl.
290
291         * bindings/scripts/CodeGeneratorJS.pm:
292         (GenerateHeader):
293         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
294         (webkit_dom_test_obj_get_property):
295         (webkit_dom_test_obj_class_init):
296         (webkit_dom_test_obj_get_test_promise_attr):
297         (webkit_dom_test_obj_set_nullable_string_value): Deleted.
298         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
299         * bindings/scripts/test/JS/JSTestObj.cpp:
300         (WebCore::jsTestObjTestPromiseAttr):
301         (WebCore::jsTestObjAttributeWithReservedEnumType): Deleted.
302         * bindings/scripts/test/JS/JSTestObj.h:
303         * bindings/scripts/test/ObjC/DOMTestObj.h:
304         * bindings/scripts/test/ObjC/DOMTestObj.mm:
305         (-[DOMTestObj testPromiseAttr]):
306         (-[DOMTestObj attribute]): Deleted.
307         * bindings/scripts/test/TestObj.idl:
308
309 2015-05-20  Youenn Fablet  <youenn.fablet@crf.canon.fr>
310
311         AudioContext suspend/resume/close should resolve promises immediately when state is already suspended/active/closed
312         https://bugs.webkit.org/show_bug.cgi?id=145164
313
314         Reviewed by Jer Noble.
315
316         Test: webaudio/audiocontext-promise.html
317
318         * Modules/webaudio/AudioContext.cpp:
319         (WebCore::AudioContext::suspendContext): Immediatly call callbacks whenever possible to resolve/reject promises.
320         (WebCore::AudioContext::resumeContext): Ditto.
321         (WebCore::AudioContext::closeContext): Ditto
322
323 2015-05-20  Carlos Garcia Campos  <cgarcia@igalia.com>
324
325         REGRESSION(r184420): [GTK] webkit_dom_html_element_get_children has been removed
326         https://bugs.webkit.org/show_bug.cgi?id=145174
327
328         Reviewed by Philippe Normand.
329
330         children property has been moved to Element, Document and
331         DocumentFragment to match the spec, so we need to expose the new
332         get_children and bring back webkit_dom_html_element_get_children()
333         as deprecated.
334
335         * bindings/gobject/WebKitDOMDeprecated.cpp:
336         (webkit_dom_html_element_get_children):
337         * bindings/gobject/WebKitDOMDeprecated.h:
338         * bindings/gobject/WebKitDOMDeprecated.symbols:
339         * bindings/gobject/webkitdom.symbols:
340
341 2015-05-20  Hunseop Jeong  <hs85.jeong@samsung.com>
342
343         nullptr cleanup in WebCore/xml.
344         https://bugs.webkit.org/show_bug.cgi?id=145165
345
346         Reviewed by Csaba Osztrogonác.
347
348         No new tests, no behavior changes
349
350         * xml/XMLHttpRequest.cpp:
351         (WebCore::XMLHttpRequest::responseXML):
352         (WebCore::XMLHttpRequest::internalAbort):
353         (WebCore::XMLHttpRequest::clearResponseBuffers):
354         (WebCore::XMLHttpRequest::clearRequest):
355         (WebCore::XMLHttpRequest::didFinishLoading):
356         * xml/XMLHttpRequestProgressEventThrottle.cpp:
357         (WebCore::XMLHttpRequestProgressEventThrottle::flushProgressEvent):
358         * xml/XSLImportRule.cpp:
359         (WebCore::XSLImportRule::XSLImportRule):
360         (WebCore::XSLImportRule::~XSLImportRule):
361         (WebCore::XSLImportRule::setXSLStyleSheet):
362         (WebCore::XSLImportRule::loadSheet):
363         * xml/XSLStyleSheet.h:
364         * xml/XSLStyleSheetLibxslt.cpp:
365         (WebCore::XSLStyleSheet::XSLStyleSheet):
366         (WebCore::XSLStyleSheet::~XSLStyleSheet):
367         (WebCore::XSLStyleSheet::clearDocuments):
368         * xml/XSLTProcessorLibxslt.cpp:
369         (WebCore::saveResultToString):
370         (WebCore::xsltParamArrayFromParameterMap):
371         (WebCore::xmlDocPtrFromNode):
372         (WebCore::XSLTProcessor::transformToString):
373         * xml/parser/XMLDocumentParser.cpp:
374         (WebCore::XMLDocumentParser::clearCurrentNodeStack):
375         (WebCore::XMLDocumentParser::exitText):
376         (WebCore::XMLDocumentParser::notifyFinished):
377         * xml/parser/XMLDocumentParser.h:
378         * xml/parser/XMLDocumentParserLibxml2.cpp:
379         (WebCore::openFunc):
380         (WebCore::XMLDocumentParser::XMLDocumentParser):
381         * xml/parser/XMLDocumentParserScope.cpp:
382         * xml/parser/XMLDocumentParserScope.h:
383
384 2015-05-19  Carlos Garcia Campos  <cgarcia@igalia.com>
385
386         [SOUP] Network Cache: Implement ShareableResource for Soup and enable it for GTK platform
387         https://bugs.webkit.org/show_bug.cgi?id=144380
388
389         Reviewed by Antti Koivisto.
390
391         Add a soup implementation of SharedBuffer::tryReplaceContentsWithPlatformBuffer().
392
393         Covered by http/tests/cache/disk-cache/ tests.
394
395         * loader/cache/CachedResource.cpp: Define
396         CachedResource::tryReplaceEncodedData() also for Soup.
397         * loader/cache/CachedResource.h: Ditto.
398         * platform/soup/SharedBufferSoup.cpp:
399         (WebCore::SharedBuffer::tryReplaceContentsWithPlatformBuffer):
400
401 2015-05-17  Sam Weinig  <sam@webkit.org>
402
403         Organize event handlers a bit
404         https://bugs.webkit.org/show_bug.cgi?id=145106
405
406         Reviewed by Darin Adler.
407
408         - Add GlobalEventHandlers.idl (from https://html.spec.whatwg.org/multipage/webappapis.html#globaleventhandlers)
409           and move all event handlers shared by Element, Document and DOMWindow there. Put all the standard defined
410           event handlers at the top (commenting out the ones that aren't implemented yet) and the non-standard ones
411           at the bottom.
412
413           There is one change in behavior here. Previously, the media related event handlers where only exposed on
414           Element and DOMWindow. The spec says they should also be on Document, so this adds support for that (this
415           is tested in fast/dom/event-handler-attributes.html).
416
417         - Add WindowEventHandlers.idl (from https://html.spec.whatwg.org/multipage/webappapis.html#windoweventhandlers)
418           and move all event handlers shared by DOMWindow, HTMLBodyElement and HTMLFrameSetElement there. Put all the 
419           standard defined event handlers at the top (commenting out the ones that aren't implemented yet) and the 
420           non-standard ones at the bottom.
421
422         - Group remaining event handlers in Element, Document, DOMWindow, HTMLBodyElement and HTMLFrameSetElement by
423           their grouping, and add some FIXMEs for future cleaning.
424
425         * CMakeLists.txt:
426         * DerivedSources.make:
427         * WebCore.xcodeproj/project.pbxproj:
428         - Add GlobalEventHandlers.idl and WindowEventHandlers.idl.
429
430         * bindings/scripts/CodeGeneratorJS.pm:
431         (GenerateImplementation):
432         Add special cases for WindowEventHandler when used on DOMWindow and DocumentEventHandler when used on Document
433         so that event handlers using those extended attributes can be set on shared interfaces. This is used to allow
434         DOMWindow to implement WindowEventHandlers.
435
436         * dom/Document.idl:
437         Move event handlers to GlobalEventHandlers and have Document implement it. Group remaining event handlers.
438
439         * dom/Element.idl:
440         Move event handlers to GlobalEventHandlers and have Element implement it. Group remaining event handlers.
441
442         * dom/GlobalEventHandlers.idl:
443         Added.
444
445         * html/HTMLBodyElement.idl:
446         Move event handlers to WindowEventHandlers and have HTMLBodyElement implement it. Group remaining event handlers.
447         
448         * html/HTMLFrameSetElement.idl:
449         Move event handlers to WindowEventHandlers and have HTMLFrameSetElement implement it. Group remaining event handlers.
450
451         * page/DOMWindow.idl:
452         Move event handlers to GlobalEventHandlers and WindowEventHandlers and have DOMWindow implement both of them. Group 
453         remaining event handlers.
454
455         * page/WindowEventHandlers.idl:
456         Added.
457
458 2015-05-19  Antti Koivisto  <antti@apple.com>
459
460         Crash under WebCore::invalidateStyleRecursively
461         https://bugs.webkit.org/show_bug.cgi?id=145186
462         rdar://problem/19736838
463
464         Reviewed by Andreas Kling
465
466         We have seen crashes where we run out of stack under invalidateStyleRecursively in StyleInvalidationAnalysis
467         on some devices.
468
469         Switch to iterative algorithm.
470
471         * css/StyleInvalidationAnalysis.cpp:
472         (WebCore::StyleInvalidationAnalysis::StyleInvalidationAnalysis):
473         (WebCore::invalidateIfNeeded):
474         (WebCore::invalidateStyleForTree):
475         (WebCore::StyleInvalidationAnalysis::invalidateStyle):
476         (WebCore::invalidateStyleRecursively): Deleted.
477
478 2015-05-19  Yusuke Suzuki  <utatane.tea@gmail.com>
479
480         Move AtomicStringImpl table related operations from AtomicString to AtomicStringImpl
481         https://bugs.webkit.org/show_bug.cgi?id=145109
482
483         Reviewed by Darin Adler.
484
485         * dom/TreeScope.cpp:
486         (WebCore::TreeScope::getElementById):
487
488 2015-05-19  Jon Lee  <jonlee@apple.com>
489
490         [iOS] Optimized fullscreen placeholder is incorrectly sized
491         https://bugs.webkit.org/show_bug.cgi?id=145196
492         rdar://problem/21031188
493
494         Reviewed by Dean Jackson.
495
496         Add a new media part UI for the placeholder text when entering optimized fullscreen,
497         and use it as part of the title text in the placeholder. Now the wireless playback status
498         div serves as a multi-purpose placeholder.
499
500         * Modules/mediacontrols/MediaControlsHost.cpp:
501         (WebCore::MediaControlsHost::mediaUIImageData): Return the placeholder text.
502         * Modules/mediacontrols/MediaControlsHost.idl: Add a new UI part for placeholder text.
503         * Modules/mediacontrols/mediaControlsApple.js: Add a new "optimized" ClassName when
504         the presentation mode is set to optimized.
505
506         * Modules/mediacontrols/mediaControlsiOS.css:
507         (audio::-webkit-media-controls-wireless-playback-status): The text should be at
508         medium weight, not light weight.
509         (audio::-webkit-media-controls-wireless-playback-text-top): The title text should be
510         white for both wireless playback and optimized fullscreen. It matches the style
511         when taking a video fullscreen.
512
513         Add new CSS rules when the placard is used for optimized fullscreen.
514         (audio::-webkit-media-controls-wireless-playback-status.optimized): Accommodate the
515         size of the graphic, and position appropriately.
516         (audio::-webkit-media-controls-wireless-playback-text-top.optimized): One line is
517         needed, so use this one, and place it where the bottom one is since more room is
518         needed to accommodate the graphic.
519         (audio::-webkit-media-controls-wireless-playback-text-bottom.optimized): One line is
520         needed, so hide this one.
521         * Modules/mediacontrols/mediaControlsiOS.js:
522         (ControllerIOS.prototype.createControls): Several of the container divs are already
523         created in Controller.prototype.createControls(). Fly-by fix to avoid creation of
524         those divs. Only the panelContainer is new for the iOS controls. Fly-by fix of a
525         missing semicolon.
526         (ControllerIOS.prototype.handlePresentationModeChange): When the presentation mode
527         changes do several things:
528             1- Update the background image. Clear the inline background image when going back
529                to inline or in wireless playback.
530             2- Add the "optimized" ClassName to the placeholder container, and the two text
531                divs when entering optimized fullscreen. Remove them in other cases.
532             3- Set -webkit-media-controls-wireless-playback-text-top to the placeholder text.
533                This is better than embedding it inside the graphic. Clear the -bottom text.
534         * platform/ios/WebCoreSystemInterfaceIOS.h: Add a new enum to obtain the placeholder
535         text.
536
537 2015-05-19  Ryuan Choi  <ryuan.choi@navercorp.com>
538
539         [EFL] Use GSimpleProxyResolver instead of custom SoupProxyResolver
540         https://bugs.webkit.org/show_bug.cgi?id=145154
541
542         Reviewed by Gyuyoung Kim.
543
544         SoupProxyResolver was deprecated since libsoup 2.42.
545         So, this patch refactors the custom SoupProxyResolver to GSimpleProxyResolver
546         which provides same functionality in gio.
547
548         No new tests, because there is not behavior change.
549
550         * PlatformEfl.cmake:
551         * WebCore.vcxproj/WebCore.vcxproj:
552         * WebCore.vcxproj/WebCore.vcxproj.filters:
553         * platform/network/soup/ProxyResolverSoup.cpp: Removed.
554         * platform/network/soup/ProxyResolverSoup.h: Removed.
555         * platform/network/soup/SoupNetworkSession.cpp:
556         (WebCore::SoupNetworkSession::setHTTPProxy): Moved to private member.
557         (WebCore::SoupNetworkSession::httpProxy): Deleted because nobody calls it.
558         * platform/network/soup/SoupNetworkSession.h:
559
560 2015-05-19  Commit Queue  <commit-queue@webkit.org>
561
562         Unreviewed, rolling out r184595.
563         https://bugs.webkit.org/show_bug.cgi?id=145197
564
565         Introduced a crash in 15 layout tests on Mavericks on #webkit
566         (Requested by rniwa on #webkit).
567
568         Reverted changeset:
569
570         "Media Controls stop updating after hovering for a few
571         seconds."
572         https://bugs.webkit.org/show_bug.cgi?id=144770
573         http://trac.webkit.org/changeset/184595
574
575 2015-05-19  Carlos Alberto Lopez Perez  <clopez@igalia.com>
576
577         REGRESSION(r181571): Build broken when USE(OPENGL_ES_2) is defined.
578         https://bugs.webkit.org/show_bug.cgi?id=145156
579
580         Reviewed by Alex Christensen.
581
582         No new tests, no behavior changes.
583
584         Vertex Array Objects are not available in OpenGLESv2.
585         Add guards to avoid using this when building with GLESv2.
586
587         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
588         (WebCore::GraphicsContext3D::createVertexArray):
589         (WebCore::GraphicsContext3D::deleteVertexArray):
590         (WebCore::GraphicsContext3D::isVertexArray):
591         (WebCore::GraphicsContext3D::bindVertexArray):
592
593 2015-05-19  Roger Fong  <roger_fong@apple.com>
594
595         Upper half of volume control should be filled, not hollow.
596         https://bugs.webkit.org/show_bug.cgi?id=145187.
597         <rdar://problem/21021970>
598
599         Reviewed by Dean Jackson.
600
601         * Modules/mediacontrols/mediaControlsApple.js:
602         (Controller.prototype.drawVolumeBackground):
603
604 2015-05-19  Michael Saboff  <msaboff@apple.com>
605
606         REGRESSION(183787): JIT is enabled for all builds
607         https://bugs.webkit.org/show_bug.cgi?id=145179
608
609         Reviewed by Geoffrey Garen.
610
611         Eliminated the setting of ENABLE_JIT, as wtf/Platform.h has appropriate logic to
612         set it depending on OS and CPU type.
613
614         Only changed the way build options are initialized.
615
616         * Configurations/FeatureDefines.xcconfig:
617
618 2015-05-19  Chris Dumez  <cdumez@apple.com>
619
620         [Mac] Font lookups are flakey due to caching
621         https://bugs.webkit.org/show_bug.cgi?id=145180
622         <rdar://problem/21012406>
623
624         Reviewed by Darin Adler.
625
626         Font lookups were flakey on Mac due to the cache in fontWithFamily().
627         The reason is that the "desired family" to "available family" mapping
628         is sometimes dependent on the desired traits. However, our cache was
629         only using the "desired family" as key.
630
631         This patch now uses a std::pair as key containing both the "desired
632         family" and the "desired traits" for correctness. I also updated the
633         cache to use WTF types instead of NS types.
634
635         Test: platform/mac/fast/text/font-weights.html
636
637         * platform/graphics/mac/FontCacheMac.mm:
638         (WebCore::desiredFamilyToAvailableFamilyMap):
639         (WebCore::hasDesiredFamilyToAvailableFamilyMapping):
640         (WebCore::rememberDesiredFamilyToAvailableFamilyMapping):
641         (WebCore::fontWithFamily):
642         (WebCore::invalidateFontCache):
643         (WebCore::desiredFamilyToAvailableFamilyDictionary): Deleted.
644
645 2015-05-19  Brady Eidson  <beidson@apple.com>
646
647         X-Frame-Options headers not respected when loading from application cache.
648         <rdar://problem/14877623> and https://bugs.webkit.org/show_bug.cgi?id=131800
649
650         Reviewed by Alexey Proskuryakov.
651
652         Test: http/tests/appcache/x-frame-options-prevents-framing.php
653
654         This patch updates SubstituteData to hold on to a ResourceResponse instead of just a URL.
655         
656         It also updates all users of SubstituteData to reflect this.
657         
658         Finally it updates ApplicationCacheHost to put the full response (including x-frame-options header)
659         in the SubstituteData so they can be checked at the appropriate times.
660         
661         * loader/DocumentLoader.cpp:
662         (WebCore::DocumentLoader::handleSubstituteDataLoadNow):
663         (WebCore::DocumentLoader::responseReceived): Update an ASSERT to reflect that it's okay to not have
664           a main resource as long as you have a substitute identifier for it.
665         (WebCore::DocumentLoader::documentURL):
666         (WebCore::DocumentLoader::contentFilterDidDecide):
667         
668         * loader/FrameLoader.cpp:
669         (WebCore::FrameLoader::loadArchive):
670         (WebCore::FrameLoader::defaultSubstituteDataForURL):
671
672         * loader/SubstituteData.h:
673         (WebCore::SubstituteData::SubstituteData):
674         (WebCore::SubstituteData::shouldRevealToSessionHistory):
675         (WebCore::SubstituteData::mimeType):
676         (WebCore::SubstituteData::textEncoding):
677         (WebCore::SubstituteData::response):
678         (WebCore::SubstituteData::responseURL): Deleted.
679
680         * loader/appcache/ApplicationCacheHost.cpp:
681         (WebCore::ApplicationCacheHost::maybeLoadMainResource): Put the full ResourceResponse here, which 
682           includes x-frame-options headers sent back when the resources was initially loaded from the network.
683
684         * platform/network/ResourceResponseBase.h:
685
686 2015-05-19  Brent Fulgham  <bfulgham@apple.com>
687
688         REGRESSION(142590): Part 2: Scroll-snap points are improperly snapping to earlier index values (Scrolling Thread) 
689         https://bugs.webkit.org/show_bug.cgi?id=145175
690         <rdar://problem/21023785>
691
692         Reviewed by Beth Dakin.
693
694         Extend the main-thread scrolling changes done in Bug 145140 to also handle Scrolling Thread snapping.
695         The post-layout fixup (needed to handle window resize and device orientation changes) should not fire
696         while Scrolling Thread scroll-snap animations are running, since these animations will most likely
697         move the scroll view into the proper position. If we attempt to 'fix up' the scroll position before
698         these animations finish, we get an ugly 'jump' in the display.
699
700         * page/FrameView.cpp:
701         (WebCore::FrameView::isScrollSnapInProgress): New method based on isRubberBandInProgress, which considers
702         both the ScrollAnimator (main thread) scrolling, as well as the ScrollingCoordinator (Scrolling Thread)
703         scrolling operations. Returns true if a scroll-snap animation is still active.
704         * page/FrameView.h:
705         * page/scrolling/AsyncScrollingCoordinator.cpp:
706         (WebCore::AsyncScrollingCoordinator::isScrollSnapInProgress): Added. Returns scrolling tree's
707         'isScrollSnapInProgress' state.
708         * page/scrolling/AsyncScrollingCoordinator.h:
709         * page/scrolling/ScrollingCoordinator.h:
710         (WebCore::ScrollingCoordinator::isScrollSnapInProgress): Added default 'false' stub.
711         * page/scrolling/ScrollingTree.cpp:
712         (WebCore::ScrollingTree::ScrollingTree): Use modern C++11 initializers.
713         (WebCore::ScrollingTree::isScrollSnapInProgress): Added.
714         (WebCore::ScrollingTree::setMainFrameIsScrollSnapping): Added.
715         * page/scrolling/ScrollingTree.h:
716         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
717         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
718         (WebCore::ScrollingTreeFrameScrollingNodeMac::handleWheelEvent): Update scrolling tree state to match the
719         ScrollController's scroll-snap state.
720         (WebCore::ScrollingTreeFrameScrollingNodeMac::startScrollSnapTimer): Added. When starting a scroll snap timer,
721         always set the scrolling tree scroll-snapping state to true.
722         (WebCore::ScrollingTreeFrameScrollingNodeMac::stopScrollSnapTimer): Added. When ending a scroll snap timer,
723         only set the scrolling tree scroll-snapping state to false if the other axis animator is inactive.
724         * platform/ScrollableArea.cpp:
725         (WebCore::ScrollableArea::updateScrollSnapState): Revise implementation to use its 'isScrollSnapInProgress'
726         method, rather than only looking at the ScrollAnimator (main thread) state.
727         * platform/ScrollableArea.h:
728         (WebCore::ScrollableArea::isScrollSnapInProgress): Added.
729         * platform/cocoa/ScrollController.h:
730         * platform/cocoa/ScrollController.mm:
731         (WebCore::ScrollController::hasActiveScrollSnapTimerForAxis): Added. Reports if the scroll snap animation
732         timer on the requested axis is running or not.
733         * rendering/RenderLayer.cpp:
734         (WebCore::RenderLayer::isScrollSnapInProgress): Added.
735         * rendering/RenderLayer.h:
736
737 2015-05-19  Roger Fong  <roger_fong@apple.com>
738
739         Media Controls stop updating after hovering for a few seconds.
740         https://bugs.webkit.org/show_bug.cgi?id=144770.
741         <rdar://problem/19823121>
742
743         Reviewed by Jer Noble.
744
745         * Modules/mediacontrols/mediaControlsApple.js:
746         (Controller.prototype.createBase):
747         We should never hide controls immediately as a result of mousing out of the controls.
748         It should only happen when the mouse leaves the video entirely.
749         (Controller.prototype.updateTimelineMetricsIfNeeded):
750         Don’t update if controls are hidden, timeline dimensions will be 0.
751         (Controller.prototype.handlePanelTransitionEnd): 
752         Instead of adjusting visibility via adding and removing classes,
753         remove controls entirely from the tree.
754         (Controller.prototype.showControls):
755         Add controls back into the tree when showing controls.
756         (Controller.prototype.updateForShowingControls):
757         Helper method for showControls.
758         (Controller.prototype.controlsAreHidden):
759         Controls also hidden if removed from tree.
760
761         Remove forceUpdate logic, no longer necessary.
762         (Controller.prototype.handleDurationChange): 
763         (Controller.prototype.updateProgress):
764         (Controller.prototype.updateTime):
765
766         Override methods to use add and remove panelContainer for iOS.
767         * Modules/mediacontrols/mediaControlsiOS.js:
768         (ControllerIOS.prototype.handlePanelTransitionEnd):
769         (ControllerIOS.prototype.showControls):
770         (ControllerIOS.prototype.controlsAreHidden):
771
772 2015-05-19  Brent Fulgham  <bfulgham@apple.com>
773
774         Scroll-snap animations should not start on axes with zero-delta
775         https://bugs.webkit.org/show_bug.cgi?id=145148
776
777         Reviewed by Dean Jackson.
778
779         Don't begin a scroll snap animation on an axis that had no change in position (on that axis)
780         during the gesture.
781
782         * platform/cocoa/ScrollController.mm:
783         (WebCore::ScrollController::processWheelEventForScrollSnapOnAxis): Don't begin a scroll snap
784         animation if no movement on this axis was ever made.
785
786 2015-05-19  Youenn Fablet  <youenn.fablet@crf.canon.fr>
787
788         AudioContext should resolve promises with jsUndefined() and not jsNull()
789         https://bugs.webkit.org/show_bug.cgi?id=145063
790
791         Reviewed by Sam Weinig.
792
793         Covered by updated test.
794
795         * bindings/js/JSDOMPromise.h:
796         (WebCore::DeferredWrapper::resolve): resolving std::nullptr_t as jsUndefined() and not jsNull()
797
798 2015-05-19  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet <youenn.fablet@crf.canon.fr>
799
800         [Streams API] Migrate closed promise handling from ReadableStreamReader to ReadableStream
801         https://bugs.webkit.org/show_bug.cgi?id=145110
802
803         Reviewed by Darin Adler.
804
805         Reader is now just checking whether it is the reader locking the stream or not.
806         If not and stream is readable, it resolves the closed promise.
807         Otherwise, it delegates the promise handling to its stream.
808
809         No change in behavior.
810
811         * Modules/streams/ReadableStream.cpp:
812         (WebCore::ReadableStream::cleanCallbacks): Cleaning of closed callbacks.
813         (WebCore::ReadableStream::changeStateToClosed): Resolving closed promise if set.
814         (WebCore::ReadableStream::changeStateToErrored): Rejecting closed promise if set.
815         (WebCore::ReadableStream::getReader): Removed reader state notification.
816         (WebCore::ReadableStream::closed): Moved from reader to stream.
817         * Modules/streams/ReadableStream.h:
818         (WebCore::ReadableStream::reader): Added to allow reader to check whether it is locking its stream or not.
819         (WebCore::ReadableStream::isReadable): Added as an improvement over internalState which is removed.
820         (WebCore::ReadableStream::internalState): Deleted.
821         * Modules/streams/ReadableStreamReader.cpp:
822         (WebCore::ReadableStreamReader::closed):
823         * Modules/streams/ReadableStreamReader.h: Removed state and closed promise callbacks.
824         * bindings/js/JSReadableStreamControllerCustom.cpp:
825         (WebCore::JSReadableStreamController::close): Refactoring of internalState to isReadable.
826         (WebCore::JSReadableStreamController::error): Ditto.
827         * bindings/js/JSReadableStreamReaderCustom.cpp:
828         (WebCore::JSReadableStreamReader::closed): Refactoring to have the promise value as callback parameter.
829
830 2015-05-19  Jeremy Jones  <jeremyj@apple.com>
831
832         Remove use of deprecated AVKit SPI cancelOptimizedFullscreen.
833         https://bugs.webkit.org/show_bug.cgi?id=145159
834
835         Reviewed by Eric Carlson.
836
837         Remove cancelOptimizedFullscreen, and use stopOptimizedFullscreen instead.
838
839         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
840         (WebVideoFullscreenInterfaceAVKit::cleanupFullscreenInternal):
841         * platform/spi/cocoa/AVKitSPI.h: remove declaration.
842
843 2015-05-19  Zalan Bujtas  <zalan@apple.com>
844
845         Merged anonymous blocks should invalidate simple line layout path.
846         https://bugs.webkit.org/show_bug.cgi?id=145104
847         rdar://problem/20980930
848
849         Reviewed by Antti Koivisto.
850
851         When anonymous blocks are merged together, it's not guaranteed that the final block can use simple line layout.
852         This patch ensures that the flow block, where the other block's content gets moved to, is no longer on simple line layout path.
853         Whether the final flow block ends up using inline boxes or simple line layout will be determined during the next layout.
854
855         Test: fast/block/crash-when-anonymous-blocks-are-merged-with-simple-line-layout.html
856
857         * rendering/RenderElement.cpp:
858         (WebCore::RenderElement::insertChildInternal):
859
860 2015-05-19  Beth Dakin  <bdakin@apple.com>
861
862         Crash in WebCore::RenderLayer::updateScrollbarsAfterLayout
863         https://bugs.webkit.org/show_bug.cgi?id=145142
864
865         Reviewed by Simon Fraser.
866
867         I have not been able to reproduce this crash, but according to symbolication 
868         m_vBar is null. It seems like this crash was probably caused by 
869         http://trac.webkit.org/changeset/173668 which made it so that overflow:scroll 
870         behaves like overflow:auto when the scrollbars are overlay. I can see how you 
871         could encounter this crash with that change if the layout caused 
872         styleRequiresScrollbar() to return true when it used to return false. Then this 
873         code, by failing to null-check the scrollbars, assumes that 
874         styleRequiresScrollbar() could not have changed based on a layout. But it could 
875         change if the css changed the scrollbars to be custom or if the user managed 
876         switch to legacy style scrollbars at just the wrong time. Or I suppose it could 
877         also happen if the user has legacy scrollbars and the style switched from auto to 
878         scroll during the layout.
879
880         Anyway, we should null-check  the scrollbars. This is a speculative fix.
881         * rendering/RenderLayer.cpp:
882         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
883
884 2015-05-19  Hunseop Jeong  <hs85.jeong@samsung.com>
885
886         Use modern for-loops in WebCore/xml.
887         https://bugs.webkit.org/show_bug.cgi?id=145046
888
889         Reviewed by Chris Dumez.
890
891         No new tests, no new tests.
892
893         * xml/XMLHttpRequest.cpp:
894         (WebCore::XMLHttpRequest::uppercaseKnownHTTPMethod):
895         * xml/XPathExpressionNode.cpp:
896         (WebCore::XPath::Expression::setSubexpressions):
897         * xml/XPathFunctions.cpp:
898         (WebCore::XPath::FunSum::evaluate):
899         (WebCore::XPath::populateFunctionMap):
900         * xml/XPathNodeSet.cpp:
901         (WebCore::XPath::NodeSet::traversalSort):
902         * xml/XPathParser.cpp:
903         (WebCore::XPath::populateAxisNamesMap):
904         * xml/XPathPath.cpp:
905         (WebCore::XPath::Filter::evaluate):
906         (WebCore::XPath::LocationPath::evaluate):
907         * xml/XPathPredicate.cpp:
908         (WebCore::XPath::EqTestOp::compare):
909         (WebCore::XPath::Union::evaluate):
910         * xml/XPathStep.cpp:
911         (WebCore::XPath::Step::optimize):
912         (WebCore::XPath::Step::predicatesAreContextListInsensitive):
913         (WebCore::XPath::Step::evaluate):
914         (WebCore::XPath::nodeMatches):
915         * xml/XSLStyleSheetLibxslt.cpp:
916         (WebCore::XSLStyleSheet::~XSLStyleSheet):
917         (WebCore::XSLStyleSheet::isLoading):
918         (WebCore::XSLStyleSheet::clearDocuments):
919         (WebCore::XSLStyleSheet::locateStylesheetSubResource):
920         * xml/XSLTProcessorLibxslt.cpp:
921         (WebCore::xsltParamArrayFromParameterMap):
922
923 2015-05-19  Jon Lee  <jonlee@apple.com>
924
925         Improve text rendering of placeholder
926         https://bugs.webkit.org/show_bug.cgi?id=145135
927
928         Reviewed by Eric Carlson.
929
930         * Modules/mediacontrols/mediaControlsApple.css: The <p> elements of the wireless playback
931         text are being popped out into separate layers, causing the text to render antialiased, which
932         looks bad on non-retina machines. Explicitly set the background color (which is ok since the
933         container element for the placeholder is also black). Also extend the height out 1pt to prevent
934         clipping of descenders.
935         (audio::-webkit-media-controls-wireless-playback-text-top): Set background color to black and add
936         1 to the height.
937         (audio::-webkit-media-controls-wireless-playback-text-bottom): Ditto.
938
939 2015-05-19  Jon Lee  <jonlee@apple.com>
940
941         [iOS] Current time display should be right-aligned
942         https://bugs.webkit.org/show_bug.cgi?id=145163
943         rdar://problem/21014339
944
945         Reviewed by Eric Carlson.
946
947         * Modules/mediacontrols/mediaControlsiOS.css: Use flex-start and flex-end
948         instead of right and left, similar to the Mac controls.
949         (video::-webkit-media-controls-current-time-display):
950         (video::-webkit-media-controls-time-remaining-display):
951
952 2015-05-14  Chris Fleizach  <cfleizach@apple.com>
953
954         AX: Select text mechanism returns results outside of text control regions
955         https://bugs.webkit.org/show_bug.cgi?id=145041
956
957         Reviewed by Mario Sanchez Prada.
958
959         The behavior of the select text mechanism (inside accessibility) should make sure that results
960         returned stay within text control elements if the search was initiated inside a text control element.
961
962         Test: platform/mac/accessibility/select-text-stays-inside-text-controls.html
963
964         * accessibility/AccessibilityObject.cpp:
965         (WebCore::rangeClosestToRange):
966         (WebCore::AccessibilityObject::selectText):
967
968 2015-05-19  Chris Dumez  <cdumez@apple.com>
969
970         Mark static variables as const when possible
971         https://bugs.webkit.org/show_bug.cgi?id=145161
972
973         Reviewed by Andreas Kling.
974
975         * Modules/mediasession/WebMediaSessionManager.cpp:
976         * Modules/mediasource/SourceBuffer.cpp:
977         * Modules/webdatabase/SQLException.cpp:
978         * dom/DOMCoreException.cpp:
979         * inspector/NetworkResourcesData.cpp:
980         * loader/icon/IconDatabase.cpp:
981         (WebCore::urlForLogging):
982         * page/AutoscrollController.cpp:
983         * page/Page.cpp:
984         * platform/RuntimeApplicationChecksIOS.mm:
985         (WebCore::applicationIsAdSheet):
986         (WebCore::applicationIsMobileMail):
987         (WebCore::applicationIsMobileSafari):
988         (WebCore::applicationIsDumpRenderTree):
989         (WebCore::applicationIsWebApp):
990         (WebCore::applicationIsOkCupid):
991         (WebCore::applicationIsFacebook):
992         (WebCore::applicationIsEpicurious):
993         (WebCore::applicationIsDaijisenDictionary):
994         (WebCore::applicationIsNASAHD):
995         (WebCore::applicationIsMASH):
996         (WebCore::applicationIsTheEconomistOnIPhone):
997         (WebCore::applicationIsWebProcess):
998         (WebCore::applicationIsIBooksOnIOS):
999         * platform/audio/HRTFElevation.cpp:
1000         * platform/audio/mac/AudioHardwareListenerMac.cpp:
1001         (WebCore::processIsRunningPropertyDescriptor):
1002         (WebCore::outputDevicePropertyDescriptor):
1003         * platform/graphics/avfoundation/AudioSourceProviderAVFObjC.mm:
1004         * platform/graphics/ca/GraphicsLayerCA.cpp:
1005         * platform/graphics/mac/FontCacheMac.mm:
1006         (WebCore::toCoreTextFontWeight):
1007         (WebCore::toAppKitFontWeight):
1008         (WebCore::toNSFontWeight):
1009         * platform/mac/ScrollAnimatorMac.mm:
1010         (supportsUIStateTransitionProgress):
1011         (supportsExpansionTransitionProgress):
1012         (supportsContentAreaScrolledInDirection):
1013         * platform/mac/ScrollbarThemeMac.mm:
1014         * platform/mac/WebCoreNSURLExtras.mm:
1015         (WebCore::dataForURLComponentType):
1016         * platform/mock/ScrollbarThemeMock.cpp:
1017         * platform/text/icu/UTextProviderLatin1.cpp:
1018         * platform/text/ios/LocalizedDateCache.mm:
1019         (WebCore::LocalizedDateCache::calculateMaximumWidth):
1020         * rendering/RenderBlockLineLayout.cpp:
1021         (WebCore::RenderBlockFlow::matchedEndLine):
1022         * rendering/RenderBoxModelObject.cpp:
1023         (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
1024         * rendering/RenderFrameBase.cpp:
1025         (WebCore::shouldExpandFrame):
1026         * rendering/RenderTableSection.cpp:
1027         * rendering/RenderThemeIOS.mm:
1028         (WebCore::getInsetGradient):
1029         (WebCore::getShineGradient):
1030         (WebCore::getShadeGradient):
1031         (WebCore::getConvexGradient):
1032         (WebCore::getConcaveGradient):
1033         (WebCore::getSliderTrackGradient):
1034         (WebCore::getReadonlySliderTrackGradient):
1035         (WebCore::getSliderThumbOpaquePressedGradient):
1036         (WebCore::RenderThemeIOS::paintCheckboxDecorations):
1037         (WebCore::RenderThemeIOS::paintRadioDecorations):
1038         * rendering/RenderThemeMac.mm:
1039         (WebCore::toFontWeight):
1040         (WebCore::TopGradientInterpolate):
1041         (WebCore::BottomGradientInterpolate):
1042         (WebCore::MainGradientInterpolate):
1043         (WebCore::TrackGradientInterpolate):
1044
1045 2015-05-18  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
1046
1047         Use Ref instead of PassRefPtr in WebCore/bindings
1048         https://bugs.webkit.org/show_bug.cgi?id=144981
1049
1050         Reviewed by Darin Adler.
1051
1052         As a step to purge PassRefPtr, remove PassRefPtr in WebCore/bindings.
1053
1054         No new tests, no behavior changes.
1055
1056         * bindings/gobject/GObjectNodeFilterCondition.h:
1057         (WebCore::GObjectNodeFilterCondition::create):
1058         * bindings/gobject/GObjectXPathNSResolver.h:
1059         (WebCore::GObjectXPathNSResolver::create):
1060         * bindings/js/JSCustomXPathNSResolver.cpp:
1061         (WebCore::JSCustomXPathNSResolver::create):
1062         * bindings/js/JSCustomXPathNSResolver.h:
1063         * bindings/js/JSDOMGlobalObjectTask.cpp:
1064         * bindings/js/JSErrorHandler.h:
1065         (WebCore::JSErrorHandler::create):
1066         * bindings/js/JSLazyEventListener.cpp:
1067         (WebCore::JSLazyEventListener::createForNode):
1068         (WebCore::JSLazyEventListener::createForDOMWindow):
1069         * bindings/js/JSLazyEventListener.h:
1070         * bindings/js/JSMutationCallback.h:
1071         (WebCore::JSMutationCallback::create):
1072         * bindings/js/JSNodeFilterCondition.h:
1073         (WebCore::JSNodeFilterCondition::create):
1074         * bindings/js/SerializedScriptValue.cpp:
1075         (WebCore::SerializedScriptValue::create):
1076         (WebCore::SerializedScriptValue::numberValue):
1077         (WebCore::SerializedScriptValue::undefinedValue):
1078         (WebCore::SerializedScriptValue::nullValue):
1079         * bindings/js/SerializedScriptValue.h:
1080         * bindings/objc/ObjCEventListener.h:
1081         * bindings/objc/ObjCEventListener.mm:
1082         (WebCore::ObjCEventListener::wrap):
1083         * bindings/objc/ObjCNodeFilterCondition.h:
1084         (WebCore::ObjCNodeFilterCondition::create):
1085
1086 2015-05-18  Csaba Osztrogonác  <ossy@webkit.org>
1087
1088         Fix uninitialized warnings in RealtimeMediaSourceCenterOwr.cpp
1089         https://bugs.webkit.org/show_bug.cgi?id=145119
1090
1091         Reviewed by Gyuyoung Kim.
1092
1093         * platform/mediastream/openwebrtc/RealtimeMediaSourceCenterOwr.cpp:
1094         (WebCore::RealtimeMediaSourceCenterOwr::validateRequestConstraints):
1095         (WebCore::RealtimeMediaSourceCenterOwr::mediaSourcesAvailable):
1096
1097 2015-05-18  Michael Catanzaro  <mcatanzaro@igalia.com>
1098
1099         [CMake] Ignore warnings in system headers
1100         https://bugs.webkit.org/show_bug.cgi?id=144747
1101
1102         Reviewed by Darin Adler.
1103
1104         Separate include directories into WebKit project includes and system includes. Suppress all
1105         warnings from headers in system include directories using the SYSTEM argument to
1106         the include_directories command.
1107
1108         * CMakeLists.txt:
1109         * PlatformEfl.cmake:
1110         * PlatformGTK.cmake:
1111         * PlatformMac.cmake:
1112
1113 2015-05-18  Myles C. Maxfield  <mmaxfield@apple.com>
1114
1115         Addressing post-review comments on r184353
1116         https://bugs.webkit.org/show_bug.cgi?id=145146
1117
1118         Reviewed by Benjamin Poulain.
1119
1120         See per-file comments.
1121
1122         No new tests because there is no behavior change.
1123
1124         * platform/graphics/mac/FontCacheMac.mm:
1125         (WebCore::fontWithFamilySpecialCase): Use equalIgnoringASCIICase() AtomicString overload.
1126         * rendering/RenderThemeMac.mm:
1127         (WebCore::RenderThemeMac::updateCachedSystemFontDescription): Implement Ben's ideas for
1128         cheaply constructing AtomicStrings only when necessary.
1129
1130 2015-05-18  Skachkov Alexandr  <gskachkov@gmail.com>
1131
1132         [ES6] Arrow function syntax. Feature flag for arrow function
1133         https://bugs.webkit.org/show_bug.cgi?id=145108
1134
1135         Reviewed by Ryosuke Niwa.
1136
1137         Added feature flag ENABLE_ES6_ARROWFUNCTION_SYNTAX for arrow function
1138
1139         * Configurations/FeatureDefines.xcconfig:
1140
1141 2015-05-18  Brent Fulgham  <bfulgham@apple.com>
1142
1143         REGRESSION(142590): Scroll-snap points are improperly snapping to earlier index values
1144         https://bugs.webkit.org/show_bug.cgi?id=145140
1145         <rdar://problem/21006738>
1146
1147         Reviewed by Beth Dakin.
1148
1149         The new "nearestActiveSnapPoint" logic is firing while scroll snap animations are running. We need
1150         to add an "isScrollSnapInProgress" predicate, much like the existing "isRubberBandInProgress" to avoid
1151         certain "fix-up" logic that we don't want running while we are in the process of moving to a new position.
1152
1153         * platform/ScrollAnimator.h:
1154         (WebCore::ScrollAnimator::ScrollAnimator::isScrollSnapInProgress): Added.
1155         * platform/ScrollableArea.cpp:
1156         (WebCore::ScrollableArea::updateScrollSnapState): If we are in the midst of a scroll snap operation,
1157         do not attempt to reset position to the current active snap point.
1158         * platform/cocoa/ScrollController.h:
1159         * platform/cocoa/ScrollController.mm:
1160         (WebCore::ScrollController::isScrollSnapInProgress): Added.
1161         * platform/mac/ScrollAnimatorMac.h:
1162         * platform/mac/ScrollAnimatorMac.mm:
1163         (WebCore::ScrollAnimatorMac::isScrollSnapInProgress): Added.
1164
1165 2015-05-17  Manuel Rego Casasnovas  <rego@igalia.com>
1166
1167         [CSS Grid Layout] Add scrollbar width in intrinsic logical widths computation
1168         https://bugs.webkit.org/show_bug.cgi?id=145021
1169
1170         Like for flexboxes we've to take into account the scrollbar logical
1171         width while computing the intrinsic min and max logical widths.
1172
1173         Reviewed by Sergio Villar Senin.
1174
1175         Test: fast/css-grid-layout/compute-intrinsic-widths-scrollbar.html
1176
1177         * rendering/RenderGrid.cpp:
1178         (WebCore::RenderGrid::computeIntrinsicLogicalWidths): Add scrollbar
1179         logical width.
1180
1181 2015-05-17  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet <youenn.fablet@crf.canon.fr>
1182
1183         [Streams API] Delegate ReadableStreamReader reference counting to ReadableStream
1184         https://bugs.webkit.org/show_bug.cgi?id=144907
1185
1186         Reviewed by Darin Adler.
1187
1188         Changed the link between readadable stream and reader.
1189         Controller ref()/deref() now increments/decrements its stream ref counter, similarly to ReadableStreamController.
1190         This ensures that even if JS scripts do not keep track of the readable stream,
1191         the readable stream will not be disposed as long as the JS script has access to its reader.
1192
1193         All readers of a given stream are kept by the stream, either in an array (for released readers) 
1194         or and in ReadableStream::m_reader for the active reader.
1195         This removes the need for the code synchronizing stream and reader.
1196
1197         As a reader can now already count on its stream, the reader no longer needs to store the error in errored state.
1198         Removal of ReadableJSStream::Reader as closed promise rejection error is directly retrieved from the ReadableStream.
1199         Moved the creation of reader directly in ReadableStream.
1200
1201         Next step should be to remove ReadableStreamReader::m_state and to delegate the handling of ReadableStreamReader closed promise callbacks to ReadableStream.
1202
1203         No change in behavior.
1204
1205         * Modules/streams/ReadableStream.cpp:
1206         (WebCore::ReadableStream::changeStateToClosed):
1207         (WebCore::ReadableStream::changeStateToErrored):
1208         (WebCore::ReadableStream::getReader):
1209         * Modules/streams/ReadableStream.h:
1210         (WebCore::ReadableStream::reader):
1211         * Modules/streams/ReadableStreamReader.cpp:
1212         (WebCore::ReadableStreamReader::clean):
1213         (WebCore::ReadableStreamReader::ref):
1214         (WebCore::ReadableStreamReader::deref):
1215         (WebCore::ReadableStreamReader::closed):
1216         (WebCore::ReadableStreamReader::changeStateToClosed):
1217         (WebCore::ReadableStreamReader::changeStateToErrored):
1218         * Modules/streams/ReadableStreamReader.h:
1219         (WebCore::ReadableStreamReader::ReadableStreamReader):
1220         * Modules/streams/ReadableStreamReader.idl:
1221         * bindings/js/JSReadableStreamCustom.cpp:
1222         (WebCore::JSReadableStream::getReader):
1223         * bindings/js/JSReadableStreamReaderCustom.cpp:
1224         (WebCore::JSReadableStreamReader::closed):
1225         (WebCore::constructJSReadableStreamReader):
1226         * bindings/js/ReadableJSStream.cpp:
1227         (WebCore::ReadableJSStream::storeError):
1228         (WebCore::ReadableJSStream::ReadableJSStream): Deleted.
1229         * bindings/js/ReadableJSStream.h:
1230
1231 2015-05-17  Alexey Proskuryakov  <ap@apple.com>
1232
1233         Crash when uploading huge files to YouTube or Google Drive
1234         https://bugs.webkit.org/show_bug.cgi?id=145083
1235         rdar://problem/15468529
1236
1237         Reviewed by Darin Adler.
1238
1239         This fixes the crash, but uploading will fail.
1240
1241         * fileapi/FileReaderLoader.cpp:
1242         (WebCore::FileReaderLoader::start): Tell SubresourceLoader to not store a copy of
1243         all received data, FileReaderLoader has its own buffer.
1244         (WebCore::FileReaderLoader::didReceiveResponse): Fixed a bounds check - not every
1245         64-bit value that doesn't fit into 32 bits is negative. With this, FileReader fails
1246         on huge files right away, as intended.
1247         (WebCore::FileReaderLoader::didReceiveData): Fixed multiple bugs in code that's
1248         executed when size is not available upfront. This is the code that used to crash,
1249         but with the above fix, it's not executed by YouTube.
1250         Not only overflow was handled incorrectly, but even simply growing a buffer for
1251         append was buggy.
1252
1253 2015-05-16  Zalan Bujtas  <zalan@apple.com>
1254
1255         REGRESSION (Subpixel): Dashed underline is missing when box is positioned at subpixels.
1256         https://bugs.webkit.org/show_bug.cgi?id=145097
1257         rdar://problem/18588415
1258
1259         Reviewed by Simon Fraser.
1260
1261         Dashed and dotted border painting needs clipping in order to properly display corners.
1262         Similarly to solid border's quad calculation, we pixelsnap the border positions before computing the clipping quad values.
1263
1264         Test: fast/borders/dashed-border-on-subpixel-position.html
1265               fast/borders/dotted-border-on-subpixel-position.html
1266
1267         * rendering/RenderBoxModelObject.cpp:
1268         (WebCore::RenderBoxModelObject::clipBorderSidePolygon):
1269
1270 2015-05-16  Sungmann Cho  <sungmann.cho@navercorp.com>
1271
1272         Remove styleText() and applyStyleText() from InspectorStyle.
1273         https://bugs.webkit.org/show_bug.cgi?id=145093
1274
1275         Reviewed by Darin Adler.
1276
1277         styleText() and applyStyleText() in InspectorStyle are private aliases for the public
1278         accessors in the same class but are rarely used. I think it would be better off removing
1279         these aliases and updating all the current call sites to use the public accessors directly
1280         as noted in InspectorStyleSheet.h.
1281
1282         No new tests, no behavior change.
1283
1284         * inspector/InspectorStyleSheet.cpp:
1285         (WebCore::InspectorStyle::populateAllProperties):
1286         * inspector/InspectorStyleSheet.h:
1287
1288 2015-05-16  Sungmann Cho  <sungmann.cho@navercorp.com>
1289
1290         Remove MessageType variant of addMessageToConsole() from ChromeClient.
1291         https://bugs.webkit.org/show_bug.cgi?id=145095
1292
1293         Reviewed by Darin Adler.
1294
1295         All addMessageToConsole() in ChromeClient are exactly the same thing.
1296         So there is no reason to keep all this methods.
1297
1298         No new tests, no behavior change.
1299
1300         * page/ChromeClient.h:
1301         * page/PageConsoleClient.cpp:
1302         (WebCore::PageConsoleClient::messageWithTypeAndLevel):
1303
1304 2015-05-15  Sam Weinig  <sam@webkit.org>
1305
1306         Add getElementById to DocumentFragment
1307         https://bugs.webkit.org/show_bug.cgi?id=145094
1308
1309         Reviewed by Alexey Proskuryakov.
1310
1311         Match the latest DOM standard and other browsers by adding getElementById
1312         to DocumentFragment in addition to Document and SVGSVGElement. Add NonElementParentNode
1313         interface that the DOM standard defines.
1314
1315         Test: fast/dom/DocumentFragment/getElementById.html
1316
1317         * DerivedSources.make:
1318         * WebCore.xcodeproj/project.pbxproj:
1319         Add NonElementParentNode.idl
1320
1321         * dom/Document.idl:
1322         Mark Document as implementing NonElementParentNode and remove now redundant getElementById
1323         declaration.
1324
1325         * dom/DocumentFragment.cpp:
1326         (WebCore::DocumentFragment::getElementById):
1327         * dom/DocumentFragment.h:
1328         Add implementation of getElementById for DocumentFragments. Add a fast path for ShadowRoots
1329         which can take advantage of the fact that they are TreeScopes to use the elements by id cache
1330         in TreeScrope.
1331
1332         * dom/DocumentFragment.idl:
1333         Mark DocumentFragment as implementing NonElementParentNode.
1334
1335         * dom/NonElementParentNode.idl: Copied from Source/WebCore/dom/NonDocumentTypeChildNode.idl.
1336         Added.
1337
1338         * svg/SVGSVGElement.cpp:
1339         (WebCore::SVGSVGElement::getElementById):
1340         * svg/SVGSVGElement.h:
1341         * svg/SVGSVGElement.idl:
1342         Convert to taking an AtomicString to match other getElementByIds.
1343
1344 2015-05-15  Antti Koivisto  <antti@apple.com>
1345
1346         When redirecting to data URL use HTTP response for same origin policy checks
1347         https://bugs.webkit.org/show_bug.cgi?id=145054
1348         rdar://problem/20299050
1349
1350         Reviewed by Alexey Proskuryakov.
1351
1352         Test: http/tests/security/canvas-remote-read-data-url-image-redirect.html
1353
1354         * dom/ScriptElement.cpp:
1355         (WebCore::ScriptElement::notifyFinished):
1356         * dom/ScriptExecutionContext.cpp:
1357         (WebCore::ScriptExecutionContext::sanitizeScriptError):
1358         * html/canvas/CanvasRenderingContext.cpp:
1359         (WebCore::CanvasRenderingContext::wouldTaintOrigin):
1360         * loader/ImageLoader.cpp:
1361         (WebCore::ImageLoader::notifyFinished):
1362         * loader/MediaResourceLoader.cpp:
1363         (WebCore::MediaResourceLoader::responseReceived):
1364         * loader/TextTrackLoader.cpp:
1365         (WebCore::TextTrackLoader::notifyFinished):
1366         * loader/cache/CachedImage.cpp:
1367         (WebCore::CachedImage::isOriginClean):
1368         * loader/cache/CachedResource.cpp:
1369         (WebCore::CachedResource::passesAccessControlCheck):
1370         (WebCore::CachedResource::passesSameOriginPolicyCheck):
1371
1372             Factor repeatedly used same origin policy test into a function.
1373
1374         (WebCore::CachedResource::redirectReceived):
1375
1376             When redirecting to a data URL save the redirect response.
1377
1378         (WebCore::CachedResource::responseForSameOriginPolicyChecks):
1379
1380             In case we got redirected to data use that response instead of the final data response for policy checks.
1381
1382         * loader/cache/CachedResource.h:
1383
1384 2015-05-16  Jon Lee  <jonlee@apple.com>
1385
1386         [iOS] wireless playback picker button is drawn incorrectly
1387         https://bugs.webkit.org/show_bug.cgi?id=145057
1388         rdar://problem/20877518
1389
1390         Reviewed by Jer Noble.
1391
1392         * Modules/mediacontrols/mediaControlsiOS.js:
1393         (ControllerIOS.prototype.updateWirelessTargetPickerButton): This method is
1394         defined in Controller, but is only meant to run on Macs. Override it with
1395         an empty function for iOS.
1396
1397 2015-05-15  Simon Fraser  <simon.fraser@apple.com>
1398
1399         REGRESSION (r183300): Background missing on top links on apple.com
1400         https://bugs.webkit.org/show_bug.cgi?id=145079
1401         rdar://problem/20914252
1402
1403         Reviewed by Tim Horton.
1404         
1405         Re-land r184421 with a fix to check against rects.coverageRect
1406         rather than the stale m_coverageRect.
1407
1408         Test: compositing/visible-rect/backing-change-height-from-zero.html
1409
1410         * platform/graphics/ca/GraphicsLayerCA.cpp:
1411         (WebCore::GraphicsLayerCA::setVisibleAndCoverageRects):
1412         * rendering/RenderLayerBacking.cpp:
1413         (WebCore::RenderLayerBacking::shouldSkipLayerInDump):
1414
1415 2015-05-15  Matt Baker  <mattbaker@apple.com>
1416
1417         Web Inspector: REGRESSION (r181625): Timeline recording started from console.profile is always empty
1418         https://bugs.webkit.org/show_bug.cgi?id=144882
1419
1420         Reviewed by Joseph Pecoraro.
1421
1422         A timeline recording will always be stopped before the end of the current run loop is observed. Before
1423         dispatching the recording stopped event, any events that are currently in progress should be considered
1424         complete and sent to the frontend.
1425
1426         * inspector/InspectorTimelineAgent.cpp:
1427         (WebCore::InspectorTimelineAgent::internalStop):
1428
1429 2015-05-15  Commit Queue  <commit-queue@webkit.org>
1430
1431         Unreviewed, rolling out r184421.
1432         https://bugs.webkit.org/show_bug.cgi?id=145087
1433
1434         Introduced 42 layout test failures (Requested by rniwa on
1435         #webkit).
1436
1437         Reverted changeset:
1438
1439         "REGRESSION (r183300): Background missing on top links on
1440         apple.com"
1441         https://bugs.webkit.org/show_bug.cgi?id=145079
1442         http://trac.webkit.org/changeset/184421
1443
1444 2015-05-15  Simon Fraser  <simon.fraser@apple.com>
1445
1446         REGRESSION (r183300): Background missing on top links on apple.com
1447         https://bugs.webkit.org/show_bug.cgi?id=145079
1448         rdar://problem/20914252
1449
1450         Reviewed by Tim Horton.
1451
1452         GraphicsLayerCA::setVisibleAndCoverageRects() only set the m_intersectsCoverageRect
1453         flag if the coverage rect changed, but it doesn't if you simply change the size of
1454         the layer.
1455
1456         Instead, always re-evaluate the intersection, and set the CoverageRectChanged bit
1457         if it changes.
1458
1459         Test: compositing/visible-rect/backing-change-height-from-zero.html
1460
1461         * platform/graphics/ca/GraphicsLayerCA.cpp:
1462         (WebCore::GraphicsLayerCA::setVisibleAndCoverageRects):
1463         * rendering/RenderLayerBacking.cpp:
1464         (WebCore::RenderLayerBacking::shouldSkipLayerInDump): Don't skip any layers in a
1465         debug layer dump, to assist debugging.
1466
1467 2015-05-15  Sam Weinig  <sam@webkit.org>
1468
1469         Move HTMLElement's children property to ParentNode
1470         https://bugs.webkit.org/show_bug.cgi?id=145072
1471
1472         Reviewed by Chris Dumez.
1473
1474         Match the latest DOM standard and other browsers by moving the children property
1475         to ParentNode, thus exposing it on Element, Document and DocumentFragment.
1476
1477         Test: fast/dom/ParentNode-children.html
1478
1479         * dom/ContainerNode.cpp:
1480         (WebCore::ContainerNode::children):
1481         Moved implementation from HTMLElement to here.
1482
1483         (WebCore::ContainerNode::ensureCachedHTMLCollection):
1484         (WebCore::ContainerNode::cachedHTMLCollection):
1485         Moved implementation from Element to here so that ContainerNode::children
1486         can use it.
1487
1488         (WebCore::ContainerNode::firstElementChild):
1489         (WebCore::ContainerNode::lastElementChild):
1490         (WebCore::ContainerNode::childElementCount):
1491         Remove unnecessary assertions.
1492
1493         * dom/ContainerNode.h:
1494         Moved declarations from HTMLElement and Element to here.
1495
1496         * dom/Element.cpp:
1497         (WebCore::Element::ensureCachedHTMLCollection): Deleted.
1498         (WebCore::Element::cachedHTMLCollection): Deleted.
1499         * dom/Element.h:
1500         Moved to ContainerNode.
1501
1502         * dom/Node.cpp:
1503         (WebCore::Node::previousElementSibling):
1504         (WebCore::Node::nextElementSibling):
1505         Remove unnecessary assertions.
1506
1507         * dom/ParentNode.idl:
1508         Moved the children property here from HTMLElement.
1509
1510         * html/HTMLElement.cpp:
1511         (WebCore::HTMLElement::children): Deleted.
1512         * html/HTMLElement.h:
1513         Moved to ContainerNode.
1514
1515         * html/HTMLElement.idl:
1516         Get rid of the children property for all bindings except Objective-C which needs
1517         to keep it to avoid changing the public API.
1518
1519 2015-05-15  Zalan Bujtas  <zalan@apple.com>
1520
1521         WebCore ASan debug build fails. ERROR: WebCore has a weak external symbol in it.
1522         https://bugs.webkit.org/show_bug.cgi?id=145070
1523
1524         Reviewed by David Kilzer.
1525
1526         Build fix.
1527
1528         * Configurations/WebCore.unexp:
1529
1530 2015-05-15  Beth Dakin  <bdakin@apple.com>
1531
1532         Prefix force on MouseEvent and add constants for click and force click values
1533         https://bugs.webkit.org/show_bug.cgi?id=145065
1534         -and corresponding-
1535         rdar://problem/20770052
1536
1537         Reviewed by Tim Horton.
1538
1539         (WebCore::MouseEvent::webkitForce):
1540         * dom/MouseEvent.idl:
1541
1542 2015-05-15  Jer Noble  <jer.noble@apple.com>
1543
1544         [MediaControls] Refactor media controls & bring improvements made to iOS controls to Mac.
1545         https://bugs.webkit.org/show_bug.cgi?id=144973
1546
1547         Reviewed by Dean Jackson.
1548
1549         Pull improvements made to the iOS media controls back into the Mac controls by moving
1550         code from mediaControlsiOS.js into MediaControlsApple.js.
1551
1552         The largest refactored feature is the ability to drop individual controls from the media
1553         controls when the video is too small to contain them. To allow these controls to resize
1554         dynamically, a new "resize" event is fired inside the media element's shadow DOM.
1555
1556         * Modules/mediacontrols/mediaControlsApple.css:
1557         (audio::-webkit-media-controls-panel .dropped): Added; sets "display: none".
1558         * Modules/mediacontrols/mediaControlsApple.js:
1559         (Controller): Set defaults for new variables.
1560         (Controller.prototype.updateControls): Update the controls width; moved from iOS.js.
1561         (Controller.prototype.handleReadyStateChange): Update the controls; moved from iOS.js.
1562         (Controller.prototype.handleTimeUpdate): Update the progress; moved from iOS.js.
1563         (Controller.prototype.handleTimelineInput): Pause if scrubbing; moved from iOS.js.
1564         (Controller.prototype.handleTimelineChange): Update the progress; moved from iOS.js.
1565         (Controller.prototype.showControls): Update the controls width; moved from iOS.js.
1566         (Controller.prototype.hideControls): Removed _potentiallyScrubbing check; not needed due to changes
1567             to controlsAlwaysVisible().
1568         (Controller.prototype.scheduleUpdateLayoutForDisplayedWidth): Moved from iOS.js.
1569         (Controller.prototype.isControlVisible): Added; checks whether control is parented & not hidden.
1570         (Controller.prototype.updateLayoutForDisplayedWidth): Moved from iOS.js and refactored.
1571         (Controller.prototype.controlsAlwaysVisible): Return true if scrubbing.
1572         (Controller.prototype.updateHasAudio): Check currentPlaybackTargetIsWireless(); moved from iOS.js.
1573         (Controller.prototype.get scrubbing): Simple getter for _scrubbing.
1574         (Controller.prototype.set scrubbing): Check play state if scrubbing; start playback (if necessary)
1575             if not scrubbing.
1576         (Controller.prototype.get pageScaleFactor): Moved from iOS.js.
1577         (Controller.prototype.set pageScaleFactor): Ditto.
1578         (Controller.prototype.handleRootResize): Schedule an update of the contrtols width.
1579
1580         Remove a bunch of newly unnecessary code from the iOS media controls:
1581
1582         * Modules/mediacontrols/mediaControlsiOS.js:
1583         (ControllerIOS):
1584         (ControllerIOS.prototype.createControls): Remove ivars moved into Apple.js.
1585         (ControllerIOS.prototype.configureInlineControls): Remove spacer; made unnecessary.
1586         (ControllerIOS.prototype.showControls): Deleted.
1587         (ControllerIOS.prototype.updateTime): Deleted.
1588         (ControllerIOS.prototype.handleTimelineTouchStart): Just call "scrubbing = true", handled in Apple.js.
1589         (ControllerIOS.prototype.handleTimelineTouchEnd): Just call "scrubbing = false", handled in Apple.js.
1590         (ControllerIOS.prototype.handleReadyStateChange): Deleted.
1591         (ControllerIOS.prototype.setPlaying): Don't check _timelineIsHidden; not needed.
1592         (ControllerIOS.prototype.get pageScaleFactor): Deleted.
1593         (ControllerIOS.prototype.set pageScaleFactor): Deleted.
1594         (ControllerIOS.prototype.scheduleUpdateLayoutForDisplayedWidth): Deleted.
1595         (ControllerIOS.prototypeupdateLayoutForDisplayedWidth): Deleted.
1596
1597         Fire a "resize" event at the shadow DOM root when layout results in a size change.
1598
1599         * html/HTMLMediaElement.cpp:
1600         (WebCore::HTMLMediaElement::layoutSizeChanged): Fire the "resize" event at the shadow DOM.
1601         * html/HTMLMediaElement.h:
1602         * rendering/RenderMedia.cpp:
1603         (WebCore::RenderMedia::layout): Trigger layoutSizeChanged()
1604         * rendering/RenderMedia.h:
1605
1606         Drive-by fixes:
1607
1608         * Modules/mediacontrols/mediaControlsApple.js:
1609         (Controller.prototype.createControls): aria-label text is totally wrong; removed.
1610         (Controller.prototype.updateWirelessPlaybackStatus): Use class-names to hide controls, not inline styles.
1611
1612 2015-05-15  Alex Christensen  <achristensen@webkit.org>
1613
1614         [Content Extensions] Fail to load old content extension files
1615         https://bugs.webkit.org/show_bug.cgi?id=145027
1616
1617         Reviewed by Eric Carlson.
1618
1619         * contentextensions/DFABytecode.h:
1620
1621 2015-05-15  Eric Carlson  <eric.carlson@apple.com>
1622
1623         Unreviewed build fix.
1624
1625         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: Add clang pragmas to ignore
1626         deprecation warnings.
1627
1628 2015-05-15  Jeremy Jones  <jeremyj@apple.com>
1629
1630         Limit alternate fullscreen with linked on or after.
1631         https://bugs.webkit.org/show_bug.cgi?id=144894
1632
1633         Reviewed by Dean Jackson.
1634
1635         * platform/ios/WebCoreSystemInterfaceIOS.h: add new wkIOSSystemVersion
1636
1637 2015-05-15  Roger Fong  <roger_fong@apple.com>
1638
1639         Unreviewed. Revert part of r184361.
1640
1641         * Modules/mediacontrols/mediaControlsApple.js:
1642         (Controller.prototype.configureInlineControls):
1643         HI wants the buttons flipped.
1644
1645 2015-05-15  Sungmann Cho  <sungmann.cho@navercorp.com>
1646
1647         Fix trivial typo in TextEncodingDetectorICU.cpp.
1648         https://bugs.webkit.org/show_bug.cgi?id=145055
1649
1650         Reviewed by Alexey Proskuryakov.
1651
1652         No new tests, no behavior change..
1653
1654         * platform/text/TextEncodingDetectorICU.cpp:
1655         (WebCore::detectTextEncoding):
1656
1657 2015-05-15  Alexey Proskuryakov  <ap@apple.com>
1658
1659         Cyrillic top-level domains are displayed as punycode
1660         https://bugs.webkit.org/show_bug.cgi?id=145024
1661         rdar://problem/17747133
1662         rdar://problem/14116594
1663
1664         Reviewed by Tim Horton.
1665
1666         Handling each TLD in code is annoying, but we can probably survive like this
1667         for a few more years, and maybe we'll think of an entirely different way to deal
1668         with non-ASCII domain labels in the meanwhile.
1669
1670         * platform/mac/WebCoreNSURLExtras.mm:
1671         (WebCore::isSecondLevelDomainNameAllowedByTLDRules):
1672         (WebCore::allCharactersAllowedByTLDRules):
1673
1674 2015-05-15  Roger Fong  <roger_fong@apple.com>
1675
1676         Cursor is displayed after full screen video controls fade away.
1677         https://bugs.webkit.org/show_bug.cgi?id=145034.
1678         <rdar://problem/20458604>
1679
1680         Reviewed by Jer Noble.
1681
1682         * Modules/mediacontrols/mediaControlsApple.css:
1683         (video::-webkit-media-controls-panel):
1684         Unnecessary cursor style is on the control panel while hidden but
1685         the cursor will already be hidden anyways from being auto-hidden.
1686         Causes style to change when controls are hidden,
1687         which causes the cursor to reappear.
1688
1689 2015-05-15  Roger Fong  <roger_fong@apple.com>
1690
1691         Checkmark on OFF option of captions sometimes does not appear.
1692         https://bugs.webkit.org/show_bug.cgi?id=145060.
1693         <rdar://problem/19388333>
1694
1695         Reviewed by Eric Carlson.
1696
1697         * Modules/mediacontrols/mediaControlsApple.js:
1698         (Controller.prototype.buildCaptionMenu):
1699         Audio tracks don’t have an OFF option.
1700         Remove related code to allow OFF option for subtitles to work properly.
1701
1702 2015-05-15  Zalan Bujtas  <zalan@apple.com>
1703
1704         White edge on animating panel on http://rokkosunnyvale.com
1705         https://bugs.webkit.org/show_bug.cgi?id=144986
1706         rdar://problem/20907683
1707
1708         Reviewed by Simon Fraser.
1709
1710         Background image geometry calculation needs to be based on the final painting size of the container
1711         in order to accurately compute tile sizes, repeating positions etc.
1712         The container's size is pixelsnapped at painting using absolute coordinates. This patch
1713         ensures that we snap to the same size while computing background geometry.
1714
1715         Test: fast/images/background-image-size-changes-fractional-position.html
1716
1717         * rendering/InlineFlowBox.cpp:
1718         (WebCore::InlineFlowBox::paintBoxDecorations):
1719         * rendering/RenderBox.cpp:
1720         (WebCore::RenderBox::paintBoxDecorations):
1721         (WebCore::RenderBox::paintBackground):
1722         (WebCore::RenderBox::getBackgroundPaintedExtent):
1723         (WebCore::RenderBox::computeBackgroundIsKnownToBeObscured):
1724         (WebCore::RenderBox::maskClipRect):
1725         (WebCore::RenderBox::repaintLayerRectsForImage): unable to get absolute coords.
1726         * rendering/RenderBox.h:
1727         * rendering/RenderBoxModelObject.cpp:
1728         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1729         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
1730         (WebCore::RenderBoxModelObject::getGeometryForBackgroundImage):
1731         (WebCore::RenderBoxModelObject::boxShadowShouldBeAppliedToBackground):
1732         * rendering/RenderBoxModelObject.h:
1733         * rendering/RenderFieldset.cpp:
1734         (WebCore::RenderFieldset::paintBoxDecorations):
1735         * rendering/RenderImage.cpp:
1736         (WebCore::RenderImage::boxShadowShouldBeAppliedToBackground):
1737         (WebCore::RenderImage::computeBackgroundIsKnownToBeObscured):
1738         * rendering/RenderImage.h:
1739         * rendering/RenderLayer.cpp: unable to get absolute coords.
1740         (WebCore::RenderLayer::calculateClipRects):
1741         * rendering/RenderLayerBacking.cpp:
1742         (WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundImage): currently not used.
1743         * rendering/RenderObject.h:
1744         (WebCore::RenderObject::computeBackgroundIsKnownToBeObscured):
1745         (WebCore::RenderObject::backgroundIsKnownToBeObscured):
1746         * rendering/RenderTable.cpp:
1747         (WebCore::RenderTable::paintBoxDecorations):
1748         * rendering/RenderTableCell.cpp:
1749         (WebCore::RenderTableCell::boxShadowShouldBeAppliedToBackground):
1750         * rendering/RenderTableCell.h:
1751
1752 2015-05-15  Jer Noble  <jer.noble@apple.com>
1753
1754         Crash in RenderFlowThread::popFlowThreadLayoutState() due to mismatched push/pop count
1755         https://bugs.webkit.org/show_bug.cgi?id=145042
1756
1757         Reviewed by David Hyatt.
1758
1759         RenderFlowThread previously used a ListHashSet to store its stack of active objects. This
1760         is problematic because, if the same object is pushed twice, only a single entry of that
1761         object is added to the stack. After this occurs, a matching number of pushes will pop too
1762         many items off the stack, causing a crash when popping a stack with zero items. This
1763         specifically happens in FrameView::layout(), which will push its root renderer on the stack
1764         of active items, and then ask the root to layout(), which will attempt to push itself on the
1765         stack of active items.
1766
1767         Instead of a ListHashSet, use a Vector, which has similar memory characteristics and no 
1768         uniqueness requirements.
1769
1770         * rendering/RenderFlowThread.cpp:
1771         (WebCore::RenderFlowThread::pushFlowThreadLayoutState):
1772         (WebCore::RenderFlowThread::popFlowThreadLayoutState):
1773         * rendering/RenderFlowThread.h:
1774
1775 2015-05-15  Per Arne Vollan  <peavo@outlook.com>
1776
1777         [Curl] WebSocket platform part is not implemented.
1778         https://bugs.webkit.org/show_bug.cgi?id=144628
1779
1780         Reviewed by Darin Adler.
1781
1782         Add Curl platform code implementation for WebSockets.
1783
1784         * platform/network/curl/SocketStreamHandle.h:
1785         (WebCore::SocketStreamHandle::create):
1786         (WebCore::SocketStreamHandle::SocketData::SocketData):
1787         * platform/network/curl/SocketStreamHandleCurl.cpp:
1788         (WebCore::SocketStreamHandle::SocketStreamHandle):
1789         (WebCore::SocketStreamHandle::~SocketStreamHandle):
1790         (WebCore::SocketStreamHandle::platformSend):
1791         (WebCore::SocketStreamHandle::platformClose):
1792         (WebCore::SocketStreamHandle::readData):
1793         (WebCore::SocketStreamHandle::sendData):
1794         (WebCore::SocketStreamHandle::waitForAvailableData):
1795         (WebCore::SocketStreamHandle::startThread):
1796         (WebCore::SocketStreamHandle::stopThread):
1797         (WebCore::SocketStreamHandle::didReceiveData):
1798         (WebCore::SocketStreamHandle::didOpenSocket):
1799         (WebCore::SocketStreamHandle::createCopy):
1800
1801 2015-05-14  Carlos Garcia Campos  <cgarcia@igalia.com>
1802
1803         REGRESSION(r183861): [SOUP] Downloads are broken when using the Network Process
1804         https://bugs.webkit.org/show_bug.cgi?id=144738
1805
1806         Reviewed by Alexey Proskuryakov.
1807
1808         Add ResourceHandle::releaseForDownload() that releases the current
1809         handle to be used as a download.
1810
1811         * platform/network/ResourceHandle.h:
1812         * platform/network/soup/ResourceHandleSoup.cpp:
1813         (WebCore::ResourceHandle::releaseForDownload):
1814
1815 2015-05-15  Zan Dobersek  <zdobersek@igalia.com>
1816
1817         [GTK] Fix PlatformDisplayWayland construction error, implement the destructor
1818         https://bugs.webkit.org/show_bug.cgi?id=144997
1819
1820         Reviewed by Carlos Garcia Campos.
1821
1822         The PlatformDisplayWayland constructor is private, so we can't use
1823         std::make_unique<>() to construct an object of this class.
1824
1825         Implement the PlatformDisplayWayland destructor, cleaning out all
1826         the Wayland resources, if present.
1827
1828         * platform/graphics/wayland/PlatformDisplayWayland.cpp:
1829         (WebCore::PlatformDisplayWayland::create):
1830         (WebCore::PlatformDisplayWayland::PlatformDisplayWayland):
1831         (WebCore::PlatformDisplayWayland::~PlatformDisplayWayland):
1832
1833 2015-05-14  Zalan Bujtas  <zalan@apple.com>
1834
1835         Images on www.fitstylelife.com jiggle on hover.
1836         https://bugs.webkit.org/show_bug.cgi?id=145020
1837         rdar://problem/20885337
1838
1839         Reviewed by Simon Fraser.
1840
1841         This patch ensures that the clipping layer of a composited content is pixel snapped properly.
1842
1843         Tests: compositing/composited-parent-clipping-layer-on-subpixel-position.html
1844                compositing/parent-clipping-layer-on-subpixel-position.html
1845
1846         * rendering/RenderLayerBacking.cpp:
1847         (WebCore::RenderLayerBacking::updateGeometry):
1848
1849 2015-05-14  Chris Dumez  <cdumez@apple.com>
1850
1851         Have DOMWindow::createWindow() take references to frames
1852         https://bugs.webkit.org/show_bug.cgi?id=145037
1853
1854         Reviewed by Gyuyoung Kim.
1855
1856         Have DOMWindow::createWindow() take references to frames instead of
1857         pointers as they are expected to be non-null. Also return a RefPtr
1858         instead of a PassRefPtr.
1859
1860         * inspector/InspectorFrontendClientLocal.cpp:
1861         (WebCore::InspectorFrontendClientLocal::openInNewTab):
1862         * loader/FrameLoader.cpp:
1863         (WebCore::createWindow):
1864         * loader/FrameLoader.h:
1865         * page/DOMWindow.cpp:
1866         (WebCore::DOMWindow::createWindow):
1867         (WebCore::DOMWindow::open):
1868         (WebCore::DOMWindow::showModalDialog):
1869         * page/DOMWindow.h:
1870
1871 2015-05-14  Simon Fraser  <simon.fraser@apple.com>
1872
1873         REGRESSION (r183794): Garbage tiles when body background switches to fixed
1874         https://bugs.webkit.org/show_bug.cgi?id=145032
1875         rdar://problem/20963679
1876
1877         Reviewed by Dean Jackson.
1878         
1879         After r183794 (or possibly an earlier commit), we failed to dynamically update
1880         the configuration of layers that handled fixed background attachment on the root.
1881         
1882         This would result in unpainted tiles, and non-fixed-background behavior.
1883         
1884         Fix by calling RenderLayerCompositor::rootOrBodyStyleChanged() whenever the
1885         style changes on the root or body renderers, and triggering a compositing update
1886         if the fixedness of the background changes. It calls the existing rootBackgroundTransparencyChanged()
1887         if the color changes.
1888
1889         Test: platform/mac-wk2/tiled-drawing/toggle-to-fixed-background.html
1890
1891         * rendering/RenderBox.cpp:
1892         (WebCore::RenderBox::styleDidChange):
1893         * rendering/RenderLayerCompositor.cpp:
1894         (WebCore::RenderLayerCompositor::rootOrBodyStyleChanged):
1895         (WebCore::RenderLayerCompositor::rootBackgroundTransparencyChanged):
1896         * rendering/RenderLayerCompositor.h:
1897
1898 2015-05-14  Commit Queue  <commit-queue@webkit.org>
1899
1900         Unreviewed, rolling out r184359 and r184362.
1901         https://bugs.webkit.org/show_bug.cgi?id=145035
1902
1903         Introduced a crash in six media element tests (Requested by
1904         rniwa on #webkit).
1905
1906         Reverted changesets:
1907
1908         "[MediaControls] Refactor media controls & bring improvements
1909         made to iOS controls to Mac."
1910         https://bugs.webkit.org/show_bug.cgi?id=144973
1911         http://trac.webkit.org/changeset/184359
1912
1913         "Unreviewed build fix after r184359; typo."
1914         http://trac.webkit.org/changeset/184362
1915
1916 2015-05-14  Jer Noble  <jer.noble@apple.com>
1917
1918         Unreviewed build fix after r184359; typo.
1919
1920         * html/HTMLMediaElement.cpp:
1921         (WebCore::HTMLMediaElement::layoutSizeChanged):
1922
1923 2015-05-14  Roger Fong  <roger_fong@apple.com>
1924
1925         Adjust button CSS and positioning in preparation.
1926         https://bugs.webkit.org/show_bug.cgi?id=144973.
1927         <rdar://problem/20306227>
1928
1929         Reviewed by Dean Jackson.
1930
1931         The only visual change here is the swapping of the rewind and play button positions.
1932         Also, position buttons based off of both left and right margins instead of just one of the two.
1933         This allows the controls drop off to work without having to use a spacer element to take the place
1934         of the timeline if the controls are too small.
1935         * Modules/mediacontrols/mediaControlsApple.css:
1936         (audio::-webkit-media-controls-rewind-button):
1937         (audio::-webkit-media-controls-play-button):
1938         (audio::-webkit-media-controls-panel .mute-box):
1939         (audio::-webkit-media-controls-wireless-playback-picker-button):
1940         (audio::-webkit-media-controls-toggle-closed-captions-button):
1941         (audio::-webkit-media-controls-fullscreen-button):
1942         (audio::-webkit-media-controls-fullscreen-button.exit):
1943         (audio::-webkit-media-controls-time-remaining-display):
1944         (audio:-webkit-full-screen::-webkit-media-controls-toggle-closed-captions-button):
1945         (audio:-webkit-full-screen::-webkit-media-controls-wireless-playback-picker-button):
1946         * Modules/mediacontrols/mediaControlsApple.js:
1947         (Controller.prototype.configureInlineControls):
1948
1949 2015-05-14  Dean Jackson  <dino@apple.com>
1950
1951         MediaControls: controls are live even when invisible
1952         https://bugs.webkit.org/show_bug.cgi?id=145029
1953         <rdar://problem/20865442>
1954
1955         Reviewed by Jer Noble.
1956
1957         When the controls are invisible they should ignore touch/mouse
1958         events.
1959
1960         * Modules/mediacontrols/mediaControlsiOS.css: Add pointer-events: none where appropriate.
1961         (video::-webkit-media-controls-panel-container):
1962         (video::-webkit-media-controls-panel-background):
1963         (video::-webkit-media-controls-panel):
1964         (video::-webkit-media-controls-panel.paused):
1965
1966 2015-05-14  Jer Noble  <jer.noble@apple.com>
1967
1968         [MediaControls] Refactor media controls & bring improvements made to iOS controls to Mac.
1969         https://bugs.webkit.org/show_bug.cgi?id=144973
1970
1971         Reviewed by Dean Jackson.
1972
1973         Pull improvements made to the iOS media controls back into the Mac controls by moving
1974         code from mediaControlsiOS.js into MediaControlsApple.js.
1975
1976         The largest refactored feature is the ability to drop individual controls from the media
1977         controls when the video is too small to contain them. To allow these controls to resize
1978         dynamically, a new "resize" event is fired inside the media element's shadow DOM.
1979
1980         * Modules/mediacontrols/mediaControlsApple.css:
1981         (audio::-webkit-media-controls-panel .dropped): Added; sets "display: none".
1982         * Modules/mediacontrols/mediaControlsApple.js:
1983         (Controller): Set defaults for new variables.
1984         (Controller.prototype.updateControls): Update the controls width; moved from iOS.js.
1985         (Controller.prototype.handleReadyStateChange): Update the controls; moved from iOS.js.
1986         (Controller.prototype.handleTimeUpdate): Update the progress; moved from iOS.js.
1987         (Controller.prototype.handleTimelineInput): Pause if scrubbing; moved from iOS.js.
1988         (Controller.prototype.handleTimelineChange): Update the progress; moved from iOS.js.
1989         (Controller.prototype.showControls): Update the controls width; moved from iOS.js.
1990         (Controller.prototype.hideControls): Removed _potentiallyScrubbing check; not needed due to changes
1991             to controlsAlwaysVisible().
1992         (Controller.prototype.scheduleUpdateLayoutForDisplayedWidth): Moved from iOS.js.
1993         (Controller.prototype.isControlVisible): Added; checks whether control is parented & not hidden.
1994         (Controller.prototype.updateLayoutForDisplayedWidth): Moved from iOS.js and refactored.
1995         (Controller.prototype.controlsAlwaysVisible): Return true if scrubbing.
1996         (Controller.prototype.updateHasAudio): Check currentPlaybackTargetIsWireless(); moved from iOS.js.
1997         (Controller.prototype.get scrubbing): Simple getter for _scrubbing.
1998         (Controller.prototype.set scrubbing): Check play state if scrubbing; start playback (if necessary)
1999             if not scrubbing.
2000         (Controller.prototype.get pageScaleFactor): Moved from iOS.js.
2001         (Controller.prototype.set pageScaleFactor): Ditto.
2002         (Controller.prototype.handleRootResize): Schedule an update of the contrtols width.
2003
2004         Remove a bunch of newly unnecessary code from the iOS media controls:
2005
2006         * Modules/mediacontrols/mediaControlsiOS.js:
2007         (ControllerIOS):
2008         (ControllerIOS.prototype.createControls): Remove ivars moved into Apple.js.
2009         (ControllerIOS.prototype.configureInlineControls): Remove spacer; made unnecessary.
2010         (ControllerIOS.prototype.showControls): Deleted.
2011         (ControllerIOS.prototype.updateTime): Deleted.
2012         (ControllerIOS.prototype.handleTimelineTouchStart): Just call "scrubbing = true", handled in Apple.js.
2013         (ControllerIOS.prototype.handleTimelineTouchEnd): Just call "scrubbing = false", handled in Apple.js.
2014         (ControllerIOS.prototype.handleReadyStateChange): Deleted.
2015         (ControllerIOS.prototype.setPlaying): Don't check _timelineIsHidden; not needed.
2016         (ControllerIOS.prototype.get pageScaleFactor): Deleted.
2017         (ControllerIOS.prototype.set pageScaleFactor): Deleted.
2018         (ControllerIOS.prototype.scheduleUpdateLayoutForDisplayedWidth): Deleted.
2019         (ControllerIOS.prototypeupdateLayoutForDisplayedWidth): Deleted.
2020
2021         Fire a "resize" event at the shadow DOM root when layout results in a size change.
2022
2023         * html/HTMLMediaElement.cpp:
2024         (WebCore::HTMLMediaElement::layoutSizeChanged): Fire the "resize" event at the shadow DOM.
2025         * html/HTMLMediaElement.h:
2026         * rendering/RenderMedia.cpp:
2027         (WebCore::RenderMedia::layout): Trigger layoutSizeChanged()
2028         * rendering/RenderMedia.h:
2029
2030         Drive-by fixes:
2031
2032         * Modules/mediacontrols/mediaControlsApple.js:
2033         (Controller.prototype.createControls): aria-label text is totally wrong; removed.
2034         (Controller.prototype.updateWirelessPlaybackStatus): Use class-names to hide controls, not inline styles.
2035
2036 2015-05-13  Ryosuke Niwa  <rniwa@webkit.org>
2037
2038         Crash in ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline
2039         https://bugs.webkit.org/show_bug.cgi?id=119068
2040
2041         Reviewed by Enrica Casucci.
2042
2043         The bug was caused by makeInsertedContentRoundTrippableWithHTMLTreeBuilder not updating
2044         nodes kept tracked by insertedNodes and moveNodeOutOfAncestor stumbling upon it.
2045
2046         Fixed the bug by updating insertedNodes in makeInsertedContentRoundTrippableWithHTMLTreeBuilder.
2047
2048         Test: editing/inserting/insert-table-in-paragraph-crash.html
2049
2050         * editing/ReplaceSelectionCommand.cpp:
2051         (WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
2052         (WebCore::ReplaceSelectionCommand::moveNodeOutOfAncestor):
2053         * editing/ReplaceSelectionCommand.h:
2054
2055 2015-05-14  Myles C. Maxfield  <mmaxfield@apple.com>
2056
2057         [Mac] Expose more font weights for -apple-system
2058         https://bugs.webkit.org/show_bug.cgi?id=144707
2059
2060         Reviewed by Simon Fraser.
2061
2062         Previously, when we parsed a CSS declaration of the form font: keyword; where keyword
2063         is one of caption, icon, menu, message-box, small-caption, -webkit-mini-control, -webkit-small-control,
2064         or -webkit-control (which html.css does for form controls), we would ask the system what the appropriate
2065         system font is, get that font's family name, and synthesize a font-family CSS property for the element.
2066         Then, later when we actually go to look up the font, we would look up the font by family name using this
2067         information. However, this round-tripping of a font through a family name is actually lossy, and is not
2068         guaranteed to preserve system-font-ness (which we use for various things including metrics calculations).
2069
2070         This patch modifies this logic to specify a token family name instead, which the font lookup code special
2071         cases (and reacts by making the appropriate system-font lookup call). This approach is currently how iOS
2072         handles these system fonts; this patch simply brings this approach to OS X.
2073
2074         There is also an added progression here. We used to simply call [NSFont fontWithName:size:] on the system
2075         font family name (which the parser found for us) which entirely disregards weight. This means that we
2076         used to be getting synthesized bold in form controls which ask for a heavy weight. Migrating to this
2077         system-font aware call means that we get the real bold font instead of synthesized bold.
2078
2079         Once this system-font-ness is guaranteed to be preserved between parsing time and font lookup time, we
2080         can safely migrate to using [NSFont systemFontOfSize:weight] instead of [NSFont systemFontOfSize:] on
2081         platforms which support it.
2082
2083         Tests: fast/text/systemFont.html
2084                fast/css/css2-system-fonts.html
2085                fast/forms/select/optgroup-rendering.html
2086                fast/forms/validation-message-appearance.html
2087
2088         * css/CSSParser.cpp:
2089         (WebCore::CSSParser::parseSystemFont): Add a comment regarding why we are bothering with expanding out
2090         the font property in the first place.
2091         * platform/graphics/cocoa/FontCascadeCocoa.mm:
2092         (WebCore::FontCascade::primaryFontIsSystemFont): Update to use new system font tokens.
2093         * platform/graphics/mac/FontCacheMac.mm:
2094         (WebCore::toNSFontWeight): New static method to map font weights to NSFontWeight constants available on
2095         Yosemite and later.
2096         (WebCore::fontWithFamilySpecialCase): Pull all these special-case font token name handling into a
2097         separate function, which returns an Optional.
2098         (WebCore::fontWithFamily):
2099         * platform/mac/ThemeMac.mm:
2100         (WebCore::ThemeMac::controlFont): Use the font token name instead of the generated system font family
2101         name.
2102         * platform/spi/mac/NSFontSPI.h: Add [NSFont systemFontWithSize:weight:] and the proper NSFontWeight
2103         constants.
2104         * rendering/RenderThemeMac.mm:
2105         (WebCore::RenderThemeMac::updateCachedSystemFontDescription): Use the font token names instead of the
2106         generated system font family name.
2107         (WebCore::RenderThemeMac::setFontFromControlSize): Ditto.
2108
2109 2015-05-14  Roger Fong  <roger_fong@apple.com>
2110
2111         Add internals setting to disable wireless playback availability for layout tests
2112         https://bugs.webkit.org/show_bug.cgi?id=145012.
2113         <rdar://problem/20946504>
2114
2115         Reviewed by Eric Carlson.
2116
2117         * testing/InternalSettings.cpp:
2118         (WebCore::InternalSettings::resetToConsistentState):
2119         (WebCore::InternalSettings::setWirelessPlaybackDisabled):
2120         * testing/InternalSettings.idl:
2121
2122 2015-05-14  Beth Dakin  <bdakin@apple.com>
2123
2124         Change range of possible forces for mouseforcechanged DOM event
2125         https://bugs.webkit.org/show_bug.cgi?id=144987
2126         -and corresponding-
2127         rdar://problem/20472802
2128
2129         Reviewed by Tim Horton.
2130
2131         Change to a 0-3 range.
2132         * platform/PlatformMouseEvent.h:
2133         * platform/mac/PlatformEventFactoryMac.mm:
2134         (WebCore::PlatformMouseEventBuilder::PlatformMouseEventBuilder):
2135
2136 2015-05-14  Manuel Rego Casasnovas  <rego@igalia.com>
2137
2138         Fix typo in RenderBox::instrinsicScrollbarLogicalWidth()
2139         https://bugs.webkit.org/show_bug.cgi?id=144999
2140
2141         Reviewed by Sergio Villar Senin.
2142
2143         Rename RenderBox::instrinsicScrollbarLogicalWidth() to
2144         RenderBox::intrinsicScrollbarLogicalWidth().
2145
2146         No new tests, no behavior changes.
2147
2148         * rendering/RenderBlock.cpp:
2149         (WebCore::RenderBlock::computeIntrinsicLogicalWidths):
2150         * rendering/RenderBlockFlow.cpp:
2151         (WebCore::RenderBlockFlow::computeIntrinsicLogicalWidths):
2152         * rendering/RenderBox.cpp:
2153         (WebCore::RenderBox::intrinsicScrollbarLogicalWidth):
2154         (WebCore::RenderBox::instrinsicScrollbarLogicalWidth): Deleted.
2155         * rendering/RenderBox.h:
2156         * rendering/RenderDeprecatedFlexibleBox.cpp:
2157         (WebCore::RenderDeprecatedFlexibleBox::computeIntrinsicLogicalWidths):
2158         * rendering/RenderFlexibleBox.cpp:
2159         (WebCore::RenderFlexibleBox::computeIntrinsicLogicalWidths):
2160
2161 2015-05-14  Youenn Fablet  <youenn.fablet@crf.canon.fr>
2162
2163         SharedBuffer::createWithContentsOfFile should use map file routines
2164         https://bugs.webkit.org/show_bug.cgi?id=144192
2165
2166         Reviewed by Darin Adler.
2167
2168         Made use of mmap routines within SharedBuffer::createWithContentsOfFile for EFL, GTK and Mac ports.
2169         If mapping is failing, it falls back to the previous version of SharedBuffer::createWithContentsOfFile renamed as
2170         SharedBuffer::createFromReadingFile (using open/read method).
2171         File content is mapped until SharedBuffer is cleared, destroyed or additional content is appended to the SharedBuffer.
2172
2173         A helper class, MappedFileData, is introduced to handle mapped files through calls to open/mmap/munmap/close.
2174
2175         Patch covered by existing layout tests and added unit tests.
2176
2177         * platform/FileSystem.cpp:
2178         (WebCore::MappedFileData::MappedFileData):
2179         (WebCore::MappedFileData::operator=):
2180         (WebCore::MappedFileData::~MappedFileData):
2181         * platform/FileSystem.h:
2182         (WebCore::MappedFileData::MappedFileData):
2183         (WebCore::MappedFileData::operator bool):
2184         (WebCore::MappedFileData::data):
2185         (WebCore::MappedFileData::size):
2186         * platform/SharedBuffer.cpp:
2187         (WebCore::SharedBuffer::SharedBuffer):
2188         (WebCore::SharedBuffer::createWithContentsOfFile): Making use of MappedFileData before using createFromReadingFile.
2189         (WebCore::SharedBuffer::size): Checking whether data is coming from a MappedFileData.
2190         (WebCore::SharedBuffer::data): Ditto.
2191         (WebCore::SharedBuffer::append): Ditto.
2192         (WebCore::SharedBuffer::clear): Clearing MappedFileData if needed.
2193         (WebCore::SharedBuffer::copy): Transferring mapped data to buffer if needed.
2194         (WebCore::SharedBuffer::getSomeData):
2195         (WebCore::SharedBuffer::maybeTransferMappedFileData):
2196         * platform/SharedBuffer.h:
2197         * platform/gtk/SharedBufferGtk.cpp:
2198         (WebCore::SharedBuffer::createFromReadingFile): renamed from createWithContentsOfFile.
2199         * platform/mac/SharedBufferMac.mm:
2200         (WebCore::SharedBuffer::createFromReadingFile): Dito.
2201         * platform/posix/SharedBufferPOSIX.cpp:
2202         (WebCore::SharedBuffer::createFromReadingFile): Ditto.
2203         * platform/win/SharedBufferWin.cpp:
2204         (WebCore::SharedBuffer::createFromReadingFile): Ditto.
2205
2206 2015-05-13  Simon Fraser  <simon.fraser@apple.com>
2207
2208         Get the ScriptController from the correct frame for media elements and plug-ins
2209         https://bugs.webkit.org/show_bug.cgi?id=144983
2210         rdar://problem/20692642&19943135
2211
2212         Reviewed by Sam Weinig.
2213
2214         HTMLMediaElement, QuickTimePluginReplacement and HTMLPlugInImageElement were
2215         getting the main frame's ScriptController instead of the one for their frame.
2216         This caused media controls JS to be running in the context of the main frame,
2217         which broke media controls which use getCSSCanvasContext() and -webkit-canvas.
2218         
2219         Fix by getting the frame via the element's document.
2220         
2221         Also undo r180584 which was working around this bug.
2222
2223         * Modules/mediacontrols/mediaControlsiOS.js:
2224         (ControllerIOS.prototype.drawTimelineBackground):
2225         * Modules/plugins/QuickTimePluginReplacement.mm:
2226         (WebCore::QuickTimePluginReplacement::ensureReplacementScriptInjected):
2227         (WebCore::QuickTimePluginReplacement::installReplacement):
2228         * html/HTMLMediaElement.cpp:
2229         (WebCore::HTMLMediaElement::updateCaptionContainer):
2230         (WebCore::HTMLMediaElement::ensureMediaControlsInjectedScript):
2231         (WebCore::HTMLMediaElement::didAddUserAgentShadowRoot):
2232         (WebCore::HTMLMediaElement::pageScaleFactorChanged):
2233         * html/HTMLPlugInImageElement.cpp:
2234         (WebCore::HTMLPlugInImageElement::didAddUserAgentShadowRoot):
2235
2236 2015-05-13  Sungmann Cho  <sungmann.cho@navercorp.com>
2237
2238         Fix trivial typos in ApplyBlockElementCommand
2239         https://bugs.webkit.org/show_bug.cgi?id=144984
2240
2241         Reviewed by Alexey Proskuryakov.
2242
2243         No new tests, no behavior change.
2244
2245         * editing/ApplyBlockElementCommand.cpp:
2246         (WebCore::ApplyBlockElementCommand::formatSelection):
2247         (WebCore::ApplyBlockElementCommand::endOfNextParagraphSplittingTextNodesIfNeeded):
2248         (WebCore::ApplyBlockElementCommand::endOfNextParagrahSplittingTextNodesIfNeeded): Deleted.
2249         * editing/ApplyBlockElementCommand.h:
2250
2251 2015-05-13  David Kilzer  <ddkilzer@apple.com>
2252
2253         REGRESION (r179958): Crash in WebCore::DocumentLoader::detachFromFrame when -[id<WebPolicyDelegate> decidePolicyForMIMEType:request:frame:decisionListener:] fails to call -[id<WebPolicyDecisionListener> download|ignore|use]
2254         <http://webkit.org/b/144975>
2255
2256         Reviewed by Andy Estes.
2257
2258         This change reverts r179958.  It changes RELEASE_ASSERT*()
2259         statements back to Debug-only ASSERT*() statements.
2260
2261         * loader/DocumentLoader.cpp:
2262         (WebCore::DocumentLoader::~DocumentLoader):
2263         (WebCore::DocumentLoader::continueAfterContentPolicy):
2264         (WebCore::DocumentLoader::detachFromFrame):
2265
2266 2015-05-13  Antti Koivisto  <antti@apple.com>
2267
2268         Cached CSS image resources don't show up after reloading <http://nightly.webkit.org/start/>
2269         https://bugs.webkit.org/show_bug.cgi?id=144952
2270         rdar://problem/13387307
2271
2272         Reviewed by Oliver Hunt.
2273
2274         This is a symptom of a general problem that we don't revalidate subresources of cached parsed stylesheets.
2275
2276         Fix by tightening the check we perform when choosing to used the cached sheet. If there are expired subresources
2277         we reparse the sheet.
2278
2279         Test: http/tests/cache/stylesheet-sharing.html
2280
2281         * css/CSSCrossfadeValue.cpp:
2282         (WebCore::CSSCrossfadeValue::traverseSubresources):
2283         (WebCore::CSSCrossfadeValue::hasFailedOrCanceledSubresources): Deleted.
2284
2285             Replace hasFailedOrCanceledSubresources with general purpose subresource traversal functions.
2286
2287         * css/CSSCrossfadeValue.h:
2288         * css/CSSFilterImageValue.cpp:
2289         (WebCore::CSSFilterImageValue::traverseSubresources):
2290         (WebCore::CSSFilterImageValue::hasFailedOrCanceledSubresources): Deleted.
2291         * css/CSSFilterImageValue.h:
2292         * css/CSSFontFaceSrcValue.cpp:
2293         (WebCore::CSSFontFaceSrcValue::traverseSubresources):
2294         (WebCore::CSSFontFaceSrcValue::hasFailedOrCanceledSubresources): Deleted.
2295         * css/CSSFontFaceSrcValue.h:
2296         * css/CSSImageSetValue.cpp:
2297         (WebCore::CSSImageSetValue::traverseSubresources):
2298         (WebCore::CSSImageSetValue::hasFailedOrCanceledSubresources): Deleted.
2299         * css/CSSImageSetValue.h:
2300         * css/CSSImageValue.cpp:
2301         (WebCore::CSSImageValue::traverseSubresources):
2302         (WebCore::CSSImageValue::hasFailedOrCanceledSubresources): Deleted.
2303         * css/CSSImageValue.h:
2304         * css/CSSValue.cpp:
2305         (WebCore::CSSValue::traverseSubresources):
2306         (WebCore::CSSValue::hasFailedOrCanceledSubresources): Deleted.
2307         * css/CSSValue.h:
2308         * css/CSSValueList.cpp:
2309         (WebCore::CSSValueList::traverseSubresources):
2310         (WebCore::CSSValueList::hasFailedOrCanceledSubresources): Deleted.
2311         * css/CSSValueList.h:
2312         * css/StyleProperties.cpp:
2313         (WebCore::StyleProperties::traverseSubresources):
2314         (WebCore::StyleProperties::hasFailedOrCanceledSubresources): Deleted.
2315         * css/StyleProperties.h:
2316         * css/StyleSheetContents.cpp:
2317         (WebCore::traverseSubresourcesInRules):
2318         (WebCore::StyleSheetContents::traverseSubresources):
2319         (WebCore::StyleSheetContents::subresourcesAllowReuse):
2320
2321             Disallow reuse if there are expired subresources.
2322
2323         (WebCore::StyleSheetContents::isLoadingSubresources):
2324
2325             Testing support.
2326
2327         (WebCore::childRulesHaveFailedOrCanceledSubresources): Deleted.
2328         (WebCore::StyleSheetContents::hasFailedOrCanceledSubresources): Deleted.
2329         * css/StyleSheetContents.h:
2330         (WebCore::StyleSheetContents::loadCompleted):
2331         * html/HTMLLinkElement.cpp:
2332         (WebCore::HTMLLinkElement::setCSSStyleSheet):
2333         * loader/cache/CachedCSSStyleSheet.cpp:
2334         (WebCore::CachedCSSStyleSheet::restoreParsedStyleSheet):
2335         * loader/cache/CachedCSSStyleSheet.h:
2336         * loader/cache/CachedImage.cpp:
2337         (WebCore::CachedImage::makeRevalidationDecision):
2338         (WebCore::CachedImage::mustRevalidateDueToCacheHeaders): Deleted.
2339
2340             Move the logging code out from this function (it requires frame access this function doesn't otherwise need)
2341             and refactor to return a decision enum.
2342
2343         * loader/cache/CachedImage.h:
2344         * loader/cache/CachedResource.cpp:
2345         (WebCore::CachedResource::makeRevalidationDecision):
2346         (WebCore::logResourceRevalidationReason): Deleted.
2347         (WebCore::CachedResource::mustRevalidateDueToCacheHeaders): Deleted.
2348         * loader/cache/CachedResource.h:
2349         (WebCore::CachedResource::loadFailedOrCanceled):
2350         * loader/cache/CachedResourceLoader.cpp:
2351         (WebCore::logRevalidation):
2352         (WebCore::logResourceRevalidationDecision):
2353         (WebCore::CachedResourceLoader::determineRevalidationPolicy):
2354
2355             Move logging here.
2356
2357         * testing/Internals.cpp:
2358         (WebCore::Internals::isSharingStyleSheetContents):
2359         (WebCore::Internals::isStyleSheetLoadingSubresources):
2360         * testing/Internals.h:
2361         * testing/Internals.idl:
2362
2363 2015-05-13  Ryuan Choi  <ryuan.choi@navercorp.com>
2364
2365         [CoordinatedGraphics] Remove scaleFactor from SurfaceUpdateInfo
2366         https://bugs.webkit.org/show_bug.cgi?id=144935
2367
2368         Reviewed by Darin Adler.
2369
2370         The members of SurfaceUpdateInfo are only used to update tile except scaleFactor.
2371         So, this patch removes scaleFactor from SurfaceUpdateInfo.
2372         In addition, removes unnecessary parameters in createTile() 
2373
2374         No new tests because there is no behavior change.
2375
2376         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
2377         (WebCore::CoordinatedGraphicsLayer::createTile):
2378         * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
2379         * platform/graphics/texmap/coordinated/CoordinatedTile.cpp:
2380         (WebCore::CoordinatedTile::updateBackBuffer):
2381         * platform/graphics/texmap/coordinated/CoordinatedTile.h:
2382         * platform/graphics/texmap/coordinated/SurfaceUpdateInfo.h:
2383
2384 2015-05-13  Sam Weinig  <sam@webkit.org>
2385
2386         Modernize ContainerNode::childElementCount
2387         https://bugs.webkit.org/show_bug.cgi?id=144930
2388
2389         Reviewed by Darin Adler.
2390
2391         * dom/ContainerNode.cpp:
2392         (WebCore::ContainerNode::childElementCount):
2393         Use std::distance to compute the number of child elements.
2394
2395         * dom/ElementChildIterator.h:
2396         Add typedefs to make the child element iterators conform STL standards.
2397
2398 2015-05-13  Ryosuke Niwa  <rniwa@webkit.org>
2399
2400         REGRESSION(r183770): Crash inside WebEditorClient::shouldApplyStyle when applying underline
2401         https://bugs.webkit.org/show_bug.cgi?id=144949
2402         <rdar://problem/20895753>
2403
2404         Reviewed by Darin Adler.
2405
2406         The crash was caused by the variant of applyStyleToSelection that takes EditingStyle passing
2407         a null pointer to shouldApplyStyle when we're only applying text decoration changes so that
2408         m_mutableStyle in the editing style is null. This didn't reproduce in execCommand since we
2409         wouldn't call shouldApplyStyle in that case. It didn't reproduce in my manual testing because
2410         font panel also sets text shadow, which ends up filling up m_mutableStyle.
2411
2412         Fixed the bug by creating a mutable style properties when one is not provided by EditingStyle.
2413         Also fixed the "FIXME" in the function by converting text decoration changes to a corresponding
2414         text decoration value. The values passed to shouldApplyStyle now matches the old behavior prior
2415         to r183770.
2416
2417         Test: editing/style/underline-by-user.html
2418
2419         * editing/EditingStyle.cpp:
2420         (WebCore::EditingStyle::styleWithResolvedTextDecorations): Added.
2421         * editing/EditingStyle.h:
2422         * editing/Editor.cpp:
2423         (WebCore::Editor::applyStyleToSelection): Use styleWithResolvedTextDecorations to avoid the crash.
2424
2425 2015-05-13  Eric Carlson  <eric.carlson@apple.com>
2426
2427         Work around HTMLMediaElement::documentDidResumeFromPageCache being called twice
2428         https://bugs.webkit.org/show_bug.cgi?id=144969
2429
2430         Reviewed by Alexey Proskuryakov.
2431
2432         * dom/Document.cpp:
2433         (WebCore::Document::addPlaybackTargetPickerClient): Replace ASSERT with early 
2434         return to work around https://webkit.org/b/144970.
2435
2436 2015-05-13  Timothy Horton  <timothy_horton@apple.com>
2437
2438         Going back after resizing causes scroll knob to appear in the middle of the page
2439         https://bugs.webkit.org/show_bug.cgi?id=144968
2440         <rdar://problem/18299827>
2441
2442         Reviewed by Beth Dakin.
2443
2444         * history/CachedPage.cpp:
2445         (WebCore::CachedPage::restore):
2446         (WebCore::CachedPage::clear):
2447         * history/CachedPage.h:
2448         (WebCore::CachedPage::markForContentsSizeChanged):
2449         * history/PageCache.cpp:
2450         (WebCore::PageCache::markPagesForContentsSizeChanged):
2451         * history/PageCache.h:
2452         Add a flag that will cause us to call updateContentsSize() after a page
2453         comes out of the page cache, if necessary.
2454
2455         * page/FrameView.cpp:
2456         (WebCore::FrameView::setContentsSize):
2457         * page/FrameView.h:
2458         Mark all cached pages for this frame as needing updateContentsSize()
2459         when setContentsSize happens. This will ensure that scrollbar layers
2460         are repositioned when coming out of the page cache.
2461
2462 2015-05-13  Beth Dakin  <bdakin@apple.com>
2463
2464         Need SPI to set the overlay scroll bar style
2465         https://bugs.webkit.org/show_bug.cgi?id=144928
2466         -and corresponding-
2467         rdar://problem/20143614
2468
2469         Reviewed by Anders Carlsson.
2470
2471         New ChromeClient function preferredScrollbarOverlayStyle() will fetch the 
2472         scrollbar style that was set via the new SPI.
2473         * page/ChromeClient.h:
2474
2475         If the preferredScrollbarOverlayStyle() is anything but None, then use it. None is 
2476         used to indicate that the normal heuristic should compute the appropriate color.
2477         * page/FrameView.cpp:
2478         (WebCore::FrameView::recalculateScrollbarOverlayStyle):
2479         * page/FrameView.h:
2480
2481 2015-05-13  Brent Fulgham  <bfulgham@apple.com>
2482
2483         Scrollbars in overflow regions are not vanishing after scrolling with scroll snap points
2484         https://bugs.webkit.org/show_bug.cgi?id=142521
2485         <rdar://problem/20100706>
2486
2487         Reviewed by Darin Adler.
2488
2489         The scrollbars were not being dismissed because they were not being notified that the wheel
2490         gesture was finished. This was happening because the wheel event 'ended' state has zero
2491         deltaX and deltaY. If the region did not allow stretching, it would exit early, never passing
2492         through the 'handleWheelEventPhase' code that would notify the scrollbar controller that
2493         the gesture had ended.
2494
2495         * platform/ScrollableArea.cpp:
2496         (WebCore::ScrollableArea::mouseExitedContentArea): The wrong ScrollAnimator method was being
2497         called when the mouse exited the content area.
2498         * platform/mac/ScrollAnimatorMac.mm:
2499         (WebCore::ScrollAnimatorMac::handleWheelEvent): Do not early return when the wheel event has
2500         no change in X or Y coordinate.
2501
2502 2015-05-12  David Hyatt  <hyatt@apple.com>
2503
2504         Don't compute selection painting info when we don't have selection.
2505         https://bugs.webkit.org/show_bug.cgi?id=144920
2506         <rdar://problem/20919920>
2507
2508         Reviewed by Simon Fraser.
2509
2510         * rendering/InlineTextBox.cpp:
2511         (WebCore::InlineTextBox::paint):
2512
2513         Just set the selection paint style to the text paint style when we don't have a selection
2514         at all. Computing the selection style takes time in the case where a ::selection pseudo is
2515         used on the page, so we don't want to waste time computing that info unless it's actually
2516         needed.
2517
2518 2015-05-13  Joseph Pecoraro  <pecoraro@apple.com>
2519
2520         Pass String as reference in more places
2521         https://bugs.webkit.org/show_bug.cgi?id=144769
2522
2523         Reviewed by Daniel Bates.
2524
2525         * bindings/js/SerializedScriptValue.cpp:
2526         (WebCore::CloneSerializer::dumpString):
2527         (WebCore::CloneSerializer::dumpStringObject):
2528         * dom/DocumentMarkerController.cpp:
2529         (WebCore::DocumentMarkerController::addMarker):
2530         * dom/DocumentMarkerController.h:
2531         * inspector/InspectorApplicationCacheAgent.cpp:
2532         (WebCore::InspectorApplicationCacheAgent::assertFrameWithDocumentLoader):
2533         * inspector/InspectorApplicationCacheAgent.h:
2534         * inspector/InspectorNodeFinder.cpp:
2535         (WebCore::stripCharacters):
2536         (WebCore::InspectorNodeFinder::InspectorNodeFinder):
2537         * inspector/InspectorNodeFinder.h:
2538
2539 2015-05-13  Timothy Horton  <timothy_horton@apple.com>
2540
2541         View scale changes are temporarily lost after restoring a page from the page cache
2542         https://bugs.webkit.org/show_bug.cgi?id=144934
2543
2544         Reviewed by Brady Eidson.
2545
2546         * history/CachedPage.cpp:
2547         (WebCore::CachedPage::CachedPage):
2548         (WebCore::CachedPage::restore):
2549         (WebCore::CachedPage::clear):
2550         * history/CachedPage.h:
2551         (WebCore::CachedPage::markForDeviceOrPageScaleChanged): Renamed.
2552         * history/PageCache.cpp:
2553         (WebCore::PageCache::markPagesForDeviceOrPageScaleChanged): Renamed.
2554         * history/PageCache.h:
2555         Rename PageCache/CachedPage methods to make it more clear that they
2556         will eventually result in calling deviceOrPageScaleFactorChanged().
2557         Also, use modern initialization for CachedPage members.
2558
2559         * loader/HistoryController.cpp:
2560         (WebCore::HistoryController::saveScrollPositionAndViewStateToItem):
2561         (WebCore::HistoryController::restoreScrollPositionAndViewState):
2562         Store the pageScaleFactor on HistoryItem with the view scale factored out,
2563         because the view scale can change while the page is in the page cache, and
2564         WebCore needs a way - without consulting with WebKit2 - to apply the changed
2565         view scale to the cached page scale.
2566
2567         * page/Page.cpp:
2568         (WebCore::Page::setViewScaleFactor):
2569         (WebCore::Page::setDeviceScaleFactor):
2570         * page/Page.h:
2571         (WebCore::Page::viewScaleFactor):
2572         Keep track of the viewScaleFactor, and mark all pages in the page cache
2573         as needing to call deviceOrPageScaleFactorChanged and do a full style recalc
2574         when they come back from the page cache.
2575
2576         For now, we expect all callers of setPageScaleFactor (including WebKit2 and
2577         HistoryController) to multiply the viewScale in manually, to avoid the
2578         significant amount of change in WebCore that would be required to keep them
2579         totally separately.
2580
2581 2015-05-12  Zan Dobersek  <zdobersek@igalia.com>
2582
2583         Reduce TransformationMatrix copies in MatrixTransformOperation, Matrix3DTransformOperation
2584         https://bugs.webkit.org/show_bug.cgi?id=144797
2585
2586         Reviewed by Darin Adler.
2587
2588         Using std::swap() on TransformationMatrix objects which don't
2589         provide move constructors will result in copies.
2590
2591         Instead, use a helper function in both MatrixTransformOperation
2592         and Matrix3DTransformOperation that calls TransformationMatrix::blend()
2593         and returns the new Matrix(3D)TransformOperation object, and call it
2594         with fromT and toT arguments switched when blending to identity.
2595
2596         * platform/graphics/transforms/Matrix3DTransformOperation.cpp:
2597         (WebCore::createOperation):
2598         (WebCore::Matrix3DTransformOperation::blend):
2599         * platform/graphics/transforms/Matrix3DTransformOperation.h: No need
2600         to copy the m_matrix member, it won't change when passed to
2601         TransformationMatrix::multiply().
2602         * platform/graphics/transforms/MatrixTransformOperation.cpp:
2603         (WebCore::createOperation):
2604         (WebCore::MatrixTransformOperation::blend):
2605
2606 2015-05-12  Carlos Garcia Campos  <cgarcia@igalia.com>
2607
2608         [EGL][X11] XPixmap created in GLContextEGL::createPixmapContext() is leaked
2609         https://bugs.webkit.org/show_bug.cgi?id=144909
2610
2611         Reviewed by Sergio Villar Senin and Žan Doberšek.
2612
2613         The pixmap is created and passed to eglCreatePixmapSurface(), but
2614         never released. eglCreatePixmapSurface() doesn't take the
2615         ownership of the pixmap, so we should explicitly free it when the
2616         GLContextEGL is destroyed.
2617
2618         * platform/graphics/egl/GLContextEGL.cpp:
2619         (WebCore::GLContextEGL::createPixmapContext): Use XUniquePixmap
2620         and transfer the ownership to the context by using the new
2621         constructor that receives a XUniquePixmap&&.
2622         (WebCore::GLContextEGL::createContext): createPixmapContext() is
2623         now only defined for X11.
2624         (WebCore::GLContextEGL::GLContextEGL): New constructor that
2625         receives a XUniquePixmap&&.
2626         * platform/graphics/egl/GLContextEGL.h: Add new constructor and
2627         initialize the cairo device when defined to simplify constructors.
2628
2629 2015-05-12  Sungmann Cho  <sungmann.cho@navercorp.com>
2630
2631         Reindent DIBPixelData.h for consistency.
2632         https://bugs.webkit.org/show_bug.cgi?id=144942
2633
2634         Reviewed by Darin Adler.
2635
2636         No new tests, no behavior change.
2637
2638         * platform/graphics/win/DIBPixelData.h:
2639         (WebCore::DIBPixelData::DIBPixelData):
2640         (WebCore::DIBPixelData::buffer):
2641         (WebCore::DIBPixelData::bufferLength):
2642         (WebCore::DIBPixelData::size):
2643         (WebCore::DIBPixelData::bytesPerRow):
2644         (WebCore::DIBPixelData::bitsPerPixel):
2645
2646 2015-05-12  Commit Queue  <commit-queue@webkit.org>
2647
2648         Unreviewed, rolling out r184224.
2649         https://bugs.webkit.org/show_bug.cgi?id=144946
2650
2651         Made inspector/page/main-frame-resource.html assert every time
2652         (Requested by ap on #webkit).
2653
2654         Reverted changeset:
2655
2656         "Web Inspector: REGRESSION (r181625): Timeline recording
2657         started from console.profile is always empty"
2658         https://bugs.webkit.org/show_bug.cgi?id=144882
2659         http://trac.webkit.org/changeset/184224
2660
2661 2015-05-12  Jer Noble  <jer.noble@apple.com>
2662
2663         [Mac] Hang in MediaPlayerPrivateAVFoundationObjC::audioSourceProvider() - 'tracks' property not yet loaded
2664         https://bugs.webkit.org/show_bug.cgi?id=144937
2665
2666         Reviewed by Eric Carlson.
2667
2668         Querying for the -[AVAsset tracks] property blocks for network loading; and could
2669         block forever if the asset in question is not reachable. Add a "safe" mechanism for
2670         querying the list of audible tracks, and use that when providing the audioSourceProvider()
2671         with an audible track.
2672
2673         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2674         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2675         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem):
2676         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged):
2677         (WebCore::MediaPlayerPrivateAVFoundationObjC::audioSourceProvider):
2678         (WebCore::MediaPlayerPrivateAVFoundationObjC::processLegacyClosedCaptionsTracks):
2679         (WebCore::MediaPlayerPrivateAVFoundationObjC::safeAVAssetTracksForAudibleMedia):
2680
2681 2015-05-12  Ryosuke Niwa  <rniwa@webkit.org>
2682
2683         Mac build fix after r184228.
2684
2685         * bindings/scripts/CodeGeneratorJS.pm:
2686
2687 2015-05-12  Simon Fraser  <simon.fraser@apple.com>
2688
2689         Turn antialiased font dilation off by default
2690         https://bugs.webkit.org/show_bug.cgi?id=144940
2691         rdar://problem/20923031
2692
2693         Reviewed by Sam Weinig.
2694
2695         Turn antialised font dilation off by default.
2696
2697         * page/Settings.cpp:
2698         (WebCore::Settings::Settings):
2699         * platform/graphics/FontCascade.cpp:
2700
2701 2015-05-12  Alex Christensen  <achristensen@webkit.org>
2702
2703         Don't export all JS bindings classes.
2704         https://bugs.webkit.org/show_bug.cgi?id=144932
2705
2706         Reviewed by Dan Bernstein.
2707
2708         This change is good if it compiles and links successfully.
2709
2710         * bindings/scripts/CodeGeneratorJS.pm:
2711         (ExportLabelForClass):
2712         Add a list of the JS bindings classes that need WEBCORE_EXPORT to prevent exporting too many symbols from WebCore.
2713         * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
2714         * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
2715         * bindings/scripts/test/JS/JSTestEventConstructor.h:
2716         * bindings/scripts/test/JS/JSTestEventTarget.h:
2717         * bindings/scripts/test/JS/JSTestException.h:
2718         * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
2719         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
2720         * bindings/scripts/test/JS/JSTestNamedConstructor.h:
2721         * bindings/scripts/test/JS/JSTestNode.h:
2722         * bindings/scripts/test/JS/JSTestNondeterministic.h:
2723         * bindings/scripts/test/JS/JSTestObj.h:
2724         * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
2725         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
2726         * bindings/scripts/test/JS/JSTestTypedefs.h:
2727         * bindings/scripts/test/JS/JSattribute.h:
2728         * bindings/scripts/test/JS/JSreadonly.h:
2729         Update bindings tests to remove WEBCORE_EXPORT from most of the tests,
2730         but keep one test with WEBCORE_EXPORT and one test with WEBCORE_TESTSUPPORT_EXPORT.
2731
2732 2015-05-12  Brent Fulgham  <bfulgham@apple.com>
2733
2734         [Win] Update DXSDK_DIR settings for build system.
2735
2736         Unreviewed build fix.
2737
2738         * WebCore.vcxproj/WebCore.proj: Add DXSDK_DIR definition for builder.
2739
2740 2015-05-12  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
2741
2742         Return Ref instead of PassRefPtr in create() factory functions of WebCore/dom
2743         https://bugs.webkit.org/show_bug.cgi?id=144904
2744
2745         Reviewed by Andreas Kling.
2746
2747         We return Ref when we're sure if pointer can't be null. If not, we use RefPtr instead PassRefPtr.
2748
2749         No new tests, no behavior changes.
2750
2751         * dom/AutocompleteErrorEvent.h:
2752         * dom/DOMNamedFlowCollection.h:
2753         (WebCore::DOMNamedFlowCollection::create):
2754         * dom/MessageChannel.h:
2755         (WebCore::MessageChannel::create):
2756         * dom/MessagePort.h:
2757         * dom/MutationObserver.cpp:
2758         (WebCore::MutationObserver::create):
2759         * dom/MutationObserver.h:
2760         * dom/NamedFlowCollection.h:
2761         * dom/NodeFilter.h:
2762         (WebCore::NodeFilter::create):
2763         * dom/NodeIterator.h:
2764         (WebCore::NodeIterator::create):
2765         * dom/ProcessingInstruction.cpp:
2766         (WebCore::ProcessingInstruction::create):
2767         * dom/ProcessingInstruction.h:
2768         * dom/ScriptedAnimationController.h:
2769         (WebCore::ScriptedAnimationController::create):
2770         * dom/SecurityPolicyViolationEvent.h:
2771         * dom/StaticNodeList.h:
2772         * dom/TemplateContentDocumentFragment.h:
2773         * dom/Touch.cpp:
2774         (WebCore::Touch::cloneWithNewTarget):
2775         * dom/Touch.h:
2776         (WebCore::Touch::create):
2777         * dom/TouchEvent.h:
2778         * dom/TouchList.h:
2779         (WebCore::TouchList::create):
2780         * dom/TreeWalker.h:
2781         (WebCore::TreeWalker::create):
2782         * dom/WebKitNamedFlow.cpp:
2783         (WebCore::WebKitNamedFlow::create):
2784         * dom/WebKitNamedFlow.h:
2785         * dom/default/PlatformMessagePortChannel.cpp:
2786         (WebCore::PlatformMessagePortChannel::create):
2787         * dom/default/PlatformMessagePortChannel.h:
2788         (WebCore::PlatformMessagePortChannel::MessagePortQueue::create):
2789
2790 2015-05-12  Matt Baker  <mattbaker@apple.com>
2791
2792         Web Inspector: REGRESSION (r181625): Timeline recording started from console.profile is always empty
2793         https://bugs.webkit.org/show_bug.cgi?id=144882
2794
2795         Reviewed by Brian Burg.
2796
2797         A timeline recording will always be stopped before the end of the current run loop is observed. Before
2798         dispatching the recording stopped event, the last run loop record must be completed and sent to the frontend
2799         to prevent it from being discarded.
2800
2801         * inspector/InspectorTimelineAgent.cpp:
2802         (WebCore::InspectorTimelineAgent::internalStop):
2803
2804 2015-05-12  Zalan Bujtas  <zalan@apple.com>
2805
2806         REGRESSION(r175617): Some text doesn't render on internationalculinarycenter.com
2807         https://bugs.webkit.org/show_bug.cgi?id=144917
2808         rdar://problem/20545878
2809
2810         Reviewed by Andreas Kling.
2811
2812         This patch ensures that text stroke width value is taken into account while
2813         calculating visual overflow for simple line layout.
2814         Ceiling the text stroke width value matches the normal text layout behaviour.
2815
2816         Test: fast/text/simple-line-layout-text-stroke-width.html
2817
2818         * rendering/SimpleLineLayoutFunctions.cpp:
2819         (WebCore::SimpleLineLayout::paintFlow):
2820         (WebCore::SimpleLineLayout::collectFlowOverflow):
2821
2822 2015-05-12  Alexey Proskuryakov  <ap@apple.com>
2823
2824         Build fix.
2825
2826         * platform/spi/cf/CFNetworkSPI.h:
2827
2828 2015-05-12  Brent Fulgham  <bfulgham@apple.com>
2829
2830         ROLLOUT [Win] Unreviewed build fix for older DirectX build environments.
2831
2832         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
2833
2834 2015-05-12  Joanmarie Diggs  <jdiggs@igalia.com>
2835
2836         AX: [ATK] ARIA menu items should not have anonymous block children
2837         https://bugs.webkit.org/show_bug.cgi?id=144653
2838
2839         Reviewed by Chris Fleizach.
2840
2841         Exclude anonymous block children of menu items from the accessible tree
2842         for ATK. Exclude list markers from the accessibility tree if the parent
2843         is not being exposed as an accessible list item.
2844
2845         No new tests. Instead, modified the existing tests to reflect the correct
2846         behavior.
2847
2848         * accessibility/AccessibilityRenderObject.cpp:
2849         (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
2850         * accessibility/atk/AccessibilityObjectAtk.cpp:
2851         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
2852
2853 2015-05-08  Alexey Proskuryakov  <ap@apple.com>
2854
2855         [Mac] Share cookie storage between UI process and secondary processes
2856         https://bugs.webkit.org/show_bug.cgi?id=144820
2857         rdar://problem/20572830
2858
2859         Reviewed by Darin Adler.
2860
2861         * platform/network/mac/CookieJarMac.mm:
2862         * platform/spi/cf/CFNetworkSPI.h:
2863         Moved SPIs into an SPI header, so that WebKit2 could use them too without duplication.
2864
2865 2015-05-12  Chris Dumez  <cdumez@apple.com>
2866
2867         [WK2] Log using diagnostic logging how far back in history we navigate
2868         https://bugs.webkit.org/show_bug.cgi?id=144919
2869         <rdar://problem/20920043>
2870
2871         Reviewed by Gavin Barraclough.
2872
2873         Add diagnostic logging keys for logging back history navigation delta.
2874
2875         * page/DiagnosticLoggingKeys.cpp:
2876         (WebCore::DiagnosticLoggingKeys::deltaKey):
2877         (WebCore::DiagnosticLoggingKeys::backNavigationKey):
2878         * page/DiagnosticLoggingKeys.h:
2879
2880 2015-05-12  Yoav Weiss  <yoav@yoav.ws>
2881
2882         Avoid CSSPrimitiveValue allocation when parsing sizes
2883         https://bugs.webkit.org/show_bug.cgi?id=144910
2884
2885         Reviewed by Darin Adler.
2886
2887         Turn non-calc length calculation logic into a static method,
2888         so that it can be called without a CSSPrimitiveValue object.
2889         Then, call that method to calculate the default source-size length.
2890
2891         No new tests, since no functionality change.
2892
2893         * css/CSSPrimitiveValue.cpp:
2894         (WebCore::CSSPrimitiveValue::computeLengthDouble): Split out the logic for everything that's not calc into a static method.
2895         (WebCore::CSSPrimitiveValue::computeNonCalcLengthDouble): Static length computation logic for everything that is not calc.
2896         * css/CSSPrimitiveValue.h:
2897         (WebCore::CSSPrimitiveValue::isFontRelativeLength): Turn into static.
2898         * css/SourceSizeList.cpp:
2899         (WebCore::defaultLength): Use the new static method to compute the length.
2900         (WebCore::computeLength): Use the calc length computation methods directly.
2901
2902 2015-05-12  Brent Fulgham  <bfulgham@apple.com>
2903
2904         [Win] Unreviewed build fix for older DirectX build environments.
2905
2906         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp: Switch back to our
2907         d3d stub header to avoid build failures on July 2004 DXSDK build environments.
2908
2909 2015-05-12  Eric Carlson  <eric.carlson@apple.com>
2910
2911         [Mac] Refine media playback target client configuration
2912         https://bugs.webkit.org/show_bug.cgi?id=144892
2913
2914         Reviewed by Brent Fulgham.
2915
2916         Client and target picker state changes fequently happen several times in quick succession, so
2917         don't react to immediately so we can batch callbacks to the web process. 
2918         * Modules/mediasession/WebMediaSessionManager.cpp:
2919         (WebCore::ClientState::ClientState): Store the client as a reference rather than a pointer
2920         because it can never be NULL.
2921         (WebCore::ClientState::operator == ): New.
2922         (WebCore::WebMediaSessionManager::addPlaybackTargetPickerClient): Schedule the initial client 
2923         configuration and a target configuration check.
2924         (WebCore::WebMediaSessionManager::removePlaybackTargetPickerClient): Schedule a target monitoring
2925         update, and a target configuration check.
2926         (WebCore::WebMediaSessionManager::removeAllPlaybackTargetPickerClients): Ditto.
2927         (WebCore::WebMediaSessionManager::showPlaybackTargetPicker): Schedule a target monitoring update.
2928         (WebCore::WebMediaSessionManager::clientStateDidChange): If the client whose state has changed
2929         can play to a target, tell it to start using the target even if it isn't playing as long as
2930         no other client is actively using a target.
2931         (WebCore::WebMediaSessionManager::setPlaybackTarget): Configure clients after a pause.
2932         (WebCore::WebMediaSessionManager::configureNewClients): New, do new client configuration.
2933         (WebCore::WebMediaSessionManager::configurePlaybackTargetClients): New, configure target clients.
2934         (WebCore::WebMediaSessionManager::scheduleDelayedTask): Schedule the timer.
2935         (WebCore::WebMediaSessionManager::taskTimerFired): Execute delayed tasks.
2936         (WebCore::WebMediaSessionManager::find): 
2937         * Modules/mediasession/WebMediaSessionManager.h:
2938
2939         * html/HTMLMediaElement.cpp:
2940         (WebCore::HTMLMediaElement::setMuted): Call updateMediaState.
2941         (WebCore::HTMLMediaElement::setPlaying): Ditto.
2942         (WebCore::HTMLMediaElement::mediaPlayerCurrentPlaybackTargetIsWirelessChanged): Ditto.
2943         (WebCore::HTMLMediaElement::enqueuePlaybackTargetAvailabilityChangedEvent): Expand logging.
2944         (WebCore::HTMLMediaElement::updateMediaState): New, don't broadcast a media state change
2945         unless something actually changed.
2946         * html/HTMLMediaElement.h:
2947
2948         * html/HTMLMediaSession.cpp:
2949         (WebCore::HTMLMediaSession::externalOutputDeviceAvailableDidChange): Update logging.
2950         (WebCore::HTMLMediaSession::setShouldPlayToPlaybackTarget): Ditto.
2951         (WebCore::HTMLMediaSession::mediaEngineUpdated): Cleanup.
2952
2953         * platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.mm:
2954         (WebCore::MediaPlaybackTargetPickerMac::showPlaybackTargetPicker): Remove the call to
2955         deprecated API and the "-Wdeprecated-declarations".
2956
2957 2015-05-12  Joanmarie Diggs  <jdiggs@igalia.com>
2958
2959         AX: [GTK] Defer to WebCore Accessibility for table exposure
2960         https://bugs.webkit.org/show_bug.cgi?id=144896
2961
2962         Reviewed by Chris Fleizach.
2963
2964         Stop unconditionally exposing all HTMLTableElement nodes as AccessibilityTables
2965         for WebKitGtk.
2966
2967         No new tests. Several existing tests already cover table exposure. They have
2968         been updated accordingly.
2969
2970         * accessibility/AccessibilityTable.cpp:
2971         (WebCore::AccessibilityTable::computeIsTableExposableThroughAccessibility):
2972
2973 2015-05-12  Joanmarie Diggs  <jdiggs@igalia.com>
2974
2975         [GTK][WK2] rowAtIndex is not implemented in DRT/WKTR
2976         https://bugs.webkit.org/show_bug.cgi?id=116971
2977
2978         Reviewed by Chris Fleizach.
2979
2980         Because ATK lacks API to directly get an accessible row via its index,
2981         the implementation of rowAtIndex gets a cell in the indexed row and
2982         returns the parent row. The failing test continued to fail because
2983         AccessibilityARIAGridCell::parentTable called parentObjectUnignored at
2984         most twice, the second call in place to handle rows which are included
2985         in the tree. However, given a well-formed ARIA grid with a rowgroup that
2986         is interactive, that rowgroup also needs to be in the tree necessitating
2987         parentObjectUnignored be called a third time to get to the grid. Given a
2988         poorly-formed ARIA grid, there may additional objects which pass the test
2989         for inclusion standing in between the cell and grid necessitating more
2990         calls still. Therefore, ascend the hierarchy to find the parent grid.
2991
2992         No new tests. The failing test now passes.
2993
2994         * accessibility/AccessibilityARIAGridCell.cpp:
2995         (WebCore::AccessibilityARIAGridCell::parentTable):
2996
2997 2015-05-08  Carlos Garcia Campos  <cgarcia@igalia.com>
2998
2999         [X11] Add XUniquePtr and XUniqueResource to automatically free X resources
3000         https://bugs.webkit.org/show_bug.cgi?id=144521
3001
3002         Reviewed by Darin Adler.
3003
3004         Add XUniquePtr as a template alias of std:unique_ptr to handle X
3005         resources using pointers and XUniqueResource as a new class to
3006         handle X resources using a long unsigned identifier. This
3007         simplifies the code and makes it more difficult to leak X resources.
3008
3009         * PlatformEfl.cmake: Add new files to compilation.
3010         * PlatformGTK.cmake: Ditto.
3011         * platform/graphics/cairo/BackingStoreBackendCairoX11.cpp:
3012         (WebCore::BackingStoreBackendCairoX11::BackingStoreBackendCairoX11):
3013         Remove the display member, and use XUnique for Pixmap and GC.
3014         (WebCore::BackingStoreBackendCairoX11::~BackingStoreBackendCairoX11):
3015         Remove code to explicitly free Pixmap and GC.
3016         (WebCore::BackingStoreBackendCairoX11::scroll):
3017         * platform/graphics/cairo/BackingStoreBackendCairoX11.h:
3018         * platform/graphics/glx/GLContextGLX.cpp:
3019         (WebCore::GLContextGLX::createWindowContext): Use XUnique and the
3020         new constructor that receives a XID, since there's no longer
3021         conflict with the one receiving a Pbuffer.
3022         (WebCore::GLContextGLX::createPbufferContext): Use XUnique and the
3023         new constructor that receives a XUniqueGLXPbuffer&&.
3024         (WebCore::GLContextGLX::createPixmapContext):
3025         (WebCore::GLContextGLX::createContext):
3026         (WebCore::GLContextGLX::GLContextGLX):
3027         (WebCore::GLContextGLX::~GLContextGLX): Remove code to explicitly
3028         free X resources.
3029         (WebCore::GLContextGLX::makeContextCurrent):
3030         (WebCore::GLContextGLX::cairoDevice):
3031         (WebCore::GLContextGLX::platformContext):
3032         * platform/graphics/glx/GLContextGLX.h:
3033         * platform/graphics/surfaces/egl/EGLXSurface.cpp:
3034         (WebCore::EGLXTransportSurfaceClient::EGLXTransportSurfaceClient):
3035         (WebCore::EGLXTransportSurfaceClient::destroy):
3036         (WebCore::EGLXTransportSurfaceClient::prepareTexture):
3037         * platform/graphics/surfaces/egl/EGLXSurface.h:
3038         * platform/graphics/surfaces/glx/GLXConfigSelector.h:
3039         (WebCore::GLXConfigSelector::findMatchingConfig): Use XUnique
3040         instead of the custom std::unique X11Deleter.
3041         (WebCore::GLXConfigSelector::findMatchingConfigWithVisualId): Ditto.
3042         * platform/graphics/surfaces/glx/GLXSurface.cpp:
3043         (WebCore::GLXTransportSurface::GLXTransportSurface): Ditto.
3044         (WebCore::GLXOffScreenSurface::initialize):
3045         * platform/graphics/surfaces/glx/X11Helper.cpp:
3046         (WebCore::X11Helper::createOffScreenWindow): Ditto.
3047         (WebCore::X11Helper::createPixmap): Ditto.
3048         * platform/graphics/surfaces/glx/X11Helper.h:
3049         * platform/graphics/x11/XUniquePtr.h: Remove X11Deleter.
3050         (WebCore::XPtrDeleter::operator()):
3051         * platform/graphics/x11/XUniqueResource.cpp: Added.
3052         (WebCore::XUniqueResource<XResource::Colormap>::deleteXResource):
3053         (WebCore::XUniqueResource<XResource::Damage>::deleteXResource):
3054         (WebCore::XUniqueResource<XResource::Pixmap>::deleteXResource):
3055         (WebCore::XUniqueResource<XResource::Window>::deleteXResource):
3056         (WebCore::XUniqueResource<XResource::GLXPbuffer>::deleteXResource):
3057         (WebCore::XUniqueResource<XResource::GLXPixmap>::deleteXResource):
3058         * platform/graphics/x11/XUniqueResource.h: Added.
3059         (WebCore::XUniqueResource::XUniqueResource):
3060         (WebCore::XUniqueResource::operator=):
3061         (WebCore::XUniqueResource::~XUniqueResource):
3062         (WebCore::XUniqueResource::get):
3063         (WebCore::XUniqueResource::release):
3064         (WebCore::XUniqueResource::reset):
3065         (WebCore::XUniqueResource::operator!):
3066         (WebCore::XUniqueResource::operator UnspecifiedBoolType*):
3067
3068 2015-05-12  Zan Dobersek  <zdobersek@igalia.com>
3069
3070         Move TransformOperation-based classes off of PassRefPtr
3071         https://bugs.webkit.org/show_bug.cgi?id=144876
3072
3073         Reviewed by Darin Adler.
3074
3075         Remove uses of PassRefPtr from the TransformOperation class and its
3076         derivatives, operating on Ref and RefPtr objects instead.
3077
3078         * platform/graphics/transforms/IdentityTransformOperation.h:
3079         * platform/graphics/transforms/Matrix3DTransformOperation.cpp:
3080         (WebCore::Matrix3DTransformOperation::blend):
3081         * platform/graphics/transforms/Matrix3DTransformOperation.h:
3082         * platform/graphics/transforms/MatrixTransformOperation.cpp:
3083         (WebCore::MatrixTransformOperation::blend):
3084         * platform/graphics/transforms/MatrixTransformOperation.h:
3085         * platform/graphics/transforms/PerspectiveTransformOperation.cpp:
3086         (WebCore::PerspectiveTransformOperation::blend):
3087         * platform/graphics/transforms/PerspectiveTransformOperation.h:
3088         * platform/graphics/transforms/RotateTransformOperation.cpp:
3089         (WebCore::RotateTransformOperation::blend):
3090         * platform/graphics/transforms/RotateTransformOperation.h:
3091         * platform/graphics/transforms/ScaleTransformOperation.cpp:
3092         (WebCore::ScaleTransformOperation::blend):
3093         * platform/graphics/transforms/ScaleTransformOperation.h:
3094         * platform/graphics/transforms/SkewTransformOperation.cpp:
3095         (WebCore::SkewTransformOperation::blend):
3096         * platform/graphics/transforms/SkewTransformOperation.h:
3097         * platform/graphics/transforms/TransformOperation.h:
3098         * platform/graphics/transforms/TransformOperations.cpp:
3099         (WebCore::TransformOperations::blendByMatchingOperations):
3100         * platform/graphics/transforms/TranslateTransformOperation.cpp:
3101         (WebCore::TranslateTransformOperation::blend):
3102         * platform/graphics/transforms/TranslateTransformOperation.h:
3103
3104 2015-05-12  Xabier Rodriguez Calvar  <calvaris@igalia.com> and Youenn Fablet <youenn.fablet@crf.canon.fr>
3105
3106         [Streams API] ReadableStream reader should not be disposable when having pending promises
3107         https://bugs.webkit.org/show_bug.cgi?id=144869
3108
3109         Reviewed by Darin Adler.
3110
3111         Made error promise callback to take a ref to the reader so that the reader is not disposed as long as the promise callback is not resolved.
3112
3113         Covered by tests added to streams/readable-stream-gc.html.
3114
3115         * Modules/streams/ReadableStreamReader.cpp:
3116         (WebCore::ReadableStreamReader::ReadableStreamReader): Moved initialize() call outside constructor as it can ref/unref.
3117         (WebCore::ReadableStreamReader::releaseStreamAndClean): Added protector.
3118         * Modules/streams/ReadableStreamReader.h:
3119         * bindings/js/JSReadableStreamReaderCustom.cpp:
3120         (WebCore::JSReadableStreamReader::closed): Lambda for error now takes a ref to the reader.
3121         * bindings/js/ReadableJSStream.cpp:
3122         (WebCore::ReadableJSStream::Reader::create): Calling initialize() after adoptRef().
3123
3124 2015-05-11  Zan Dobersek  <zdobersek@igalia.com>
3125
3126         Clean up redundant resources in case of failure in GLContextEGL context creation methods
3127         https://bugs.webkit.org/show_bug.cgi?id=144878
3128
3129         Reviewed by Martin Robinson.
3130
3131         GLContextEGL::createWindowContext() and GLContextEGL::createPixmapContext() methods
3132         should clean up the freshly-created resources when prematurely returning due to a
3133         failure.
3134
3135         * platform/graphics/egl/GLContextEGL.cpp:
3136         (WebCore::GLContextEGL::createWindowContext):
3137         (WebCore::GLContextEGL::createPixmapContext):
3138
3139 2015-05-11  Dan Bernstein  <mitz@apple.com>
3140
3141         WebCore part of <rdar://problem/20878075> Trying to navigate to an invalid URL loads about:blank, but -[WKWebView URL] returns the invalid URL
3142
3143         Reviewed by Alexey Proskuryakov.
3144
3145         Test: TestWebKitAPI/Tests/WebKit2Cocoa/ProvisionalURLChange.mm
3146
3147         In some cases, trying to navigate to an invalid URL results in navigation to about:blank.
3148         When the about:blank load is committed, the UI process still thinks that the provisional
3149         URL is the original, invalid URL, and updates its state to reflect that that’s the URL that
3150         has been committed.
3151
3152         The provisional URL changes (1) when a provisional load begins, (2) when a server redirect
3153         happens, (3) when the client changes the request in willSendRequest, and (4) in this
3154         about:blank case. For (1) and (2), there are frame loader client callbacks. (3) is client-
3155         initiated. So this patch addresses (4).
3156
3157         * loader/DocumentLoader.cpp:
3158         (WebCore::DocumentLoader::maybeLoadEmpty): If our request URL is changing to about:blank and
3159         while loading the main resource, call FrameLoaderClient::dispatchDidChangeProvisionalURL.
3160         * loader/FrameLoaderClient.h: Added dispatchDidChangeProvisionalURL with an empty
3161         implementation.
3162
3163 2015-05-11  Zalan Bujtas  <zalan@apple.com>
3164
3165         Text is misplaced when custom font does not have space glyph.
3166         https://bugs.webkit.org/show_bug.cgi?id=144879
3167
3168         Reviewed by Myles C. Maxfield
3169
3170         This patch ensures that we use fallback font for the missing space glyph only when the rendered text has space in it.
3171
3172         If a font does not provide all the glyphs required to render the associated text, we initiate fallback fonts. It is done while
3173         measuring the text at layout time. However due to the fact that we always pre-measure space, a font with no space glyph in it is never sufficient.
3174         (even when the text does not require space at all)
3175         Fallback fonts impact line positions through ascent/descent calculation.
3176
3177         Test: fast/text/font-with-no-space-glyph.html
3178
3179         * rendering/RenderText.cpp:
3180         (WebCore::RenderText::computePreferredLogicalWidths):
3181         * rendering/line/BreakingContext.h:
3182         (WebCore::WordTrailingSpace::WordTrailingSpace):
3183         (WebCore::WordTrailingSpace::width):
3184         (WebCore::BreakingContext::handleText):
3185
3186 2015-05-11  Simon Fraser  <simon.fraser@apple.com>
3187
3188         Small tidyup in animations code
3189         https://bugs.webkit.org/show_bug.cgi?id=144893
3190
3191         Reviewed by Eric Carlson.
3192
3193         Reading progress(1, 0, 0) in callers of AnimationBase::progress() was confusing,
3194         particularly as the last parameter is a TimingFunction*. Put default values 
3195         in the header (with nullptr) and fix the callers. Also fix variable names in
3196         the implementation.
3197
3198         * page/animation/AnimationBase.cpp:
3199         (WebCore::AnimationBase::progress):
3200         * page/animation/AnimationBase.h:
3201         * page/animation/ImplicitAnimation.cpp:
3202         (WebCore::ImplicitAnimation::animate):
3203         (WebCore::ImplicitAnimation::getAnimatedStyle):
3204         (WebCore::ImplicitAnimation::blendPropertyValueInStyle):
3205
3206 2015-05-11  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
3207
3208         Purge PassRefPtr in WebCore/rendering
3209         https://bugs.webkit.org/show_bug.cgi?id=144872
3210
3211         Reviewed by Darin Adler.
3212
3213         As a step to remove PassRefPtr, this patch replaces PassRefPtr with Ref in WebCore/rendering.
3214
3215         No new tests, no behavior changes.
3216
3217         * rendering/HitTestingTransformState.h:
3218         (WebCore::HitTestingTransformState::create):
3219         * rendering/RenderLayer.cpp:
3220         (WebCore::ClipRects::create):
3221         * rendering/RenderThemeGtk.cpp:
3222         (WebCore::RenderThemeGtk::create):
3223         (WebCore::RenderTheme::themeForPage):
3224         * rendering/RenderThemeGtk.h:
3225         * rendering/RenderThemeIOS.h:
3226         * rendering/RenderThemeIOS.mm:
3227         (WebCore::RenderTheme::themeForPage):
3228         (WebCore::RenderThemeIOS::create):
3229         * rendering/RenderThemeMac.h:
3230         * rendering/RenderThemeMac.mm:
3231         (WebCore::RenderTheme::themeForPage):
3232         (WebCore::RenderThemeMac::create):
3233         * rendering/RenderThemeSafari.cpp:
3234         (WebCore::RenderThemeSafari::create):
3235         (WebCore::RenderTheme::themeForPage):
3236         * rendering/RenderThemeSafari.h:
3237         * rendering/RenderThemeWin.cpp:
3238         (WebCore::RenderThemeWin::create):
3239         (WebCore::RenderTheme::themeForPage):
3240         * rendering/RenderThemeWin.h:
3241         * rendering/TextAutoSizing.h:
3242         (WebCore::TextAutoSizingValue::create):
3243         * rendering/style/ShapeValue.h:
3244         (WebCore::ShapeValue::createShapeValue):
3245         (WebCore::ShapeValue::createBoxShapeValue):
3246         (WebCore::ShapeValue::createImageValue):
3247         * rendering/style/StyleCachedImage.h:
3248         * rendering/style/StyleCachedImageSet.h:
3249         * rendering/style/StyleGeneratedImage.h:
3250         * rendering/style/StylePendingImage.h:
3251         * rendering/style/StyleReflection.h:
3252         (WebCore::StyleReflection::create):
3253
3254 2015-05-11  Eric Carlson  <eric.carlson@apple.com>
3255
3256         [Mac] Update device picker icon when video tracks change
3257         https://bugs.webkit.org/show_bug.cgi?id=144889
3258         <rdar://problem/20907253>
3259
3260         Reviewed by Brent Fulgham.
3261
3262         * Modules/mediacontrols/mediaControlsApple.js:
3263         (Controller.prototype.updateHasVideo):
3264
3265 2015-05-11  Brent Fulgham  <bfulgham@apple.com>
3266
3267         Scroll snap logic should be triggered when resizing the WebView
3268         https://bugs.webkit.org/show_bug.cgi?id=142590
3269         <rdar://problem/20125088>
3270
3271         Reviewed by Simon Fraser.
3272
3273         Tests coming in a second patch.
3274
3275         Resizing of the main frame or overflow regions was properly recalculating the scroll snap points,
3276         but there was no code to honor these values when window resizing was occurring. The correction was
3277         handled in two ways:
3278         1. Scrolling thread operations that moved to new snap points needed to notify the main thread that
3279            it had shifted to a new snap point, so that the resize code (which happens on the main thread)
3280            could ensure that we stayed clamped to the correct 'tile' in the snap region.
3281         2. Main thread (overflow) resizes were likewise missing code to honor the current snap position
3282            after resizing calculations were complete.
3283
3284         This change also required the addition of two indices to the scrollable area to track which scroll
3285         snap point was currently being used. We don't bother with a 'none' case because you cannot have a
3286         'none' state when you have an active set of scroll snap points, and we do not execute this code
3287         if the scroll snap points are null.
3288
3289         The FrameView code was computing updated snap offsets after it had dispatched frame view layout
3290         information to the scrolling thread, which was wrong. This was also corrected.
3291
3292         I think it might be possible to track all of this state inside the ScrollController, but the current
3293         scroll snap architecture destroys and recreates the state each time a new set of interactions starts.
3294         This should be fixed in the future, which would allow us to remove some of this local state.
3295
3296         * page/FrameView.cpp:
3297         (WebCore::FrameView::performPostLayoutTasks): Make sure 'updateSnapOffsets' is called prior to
3298         calling 'frameViewLayoutUpdated' so the scrolling thread gets correct updated points. Add a new
3299         call to 'scrollToNearestActiveSnapPoint', which will keep us on our current snap point during
3300         resize (if appropriate).
3301         * page/scrolling/AsyncScrollingCoordinator.cpp:
3302         (WebCore::AsyncScrollingCoordinator::updateScrollSnapOffsetIndices): Added. This finds and notifies
3303         the correct scroll region when a new snap position (index) has been selected by user interaction on
3304         the scrolling thread.
3305         (WebCore::AsyncScrollingCoordinator::deferTestsForReason): Added an assertion for 'isMainThread'.
3306         (WebCore::AsyncScrollingCoordinator::removeTestDeferralForReason): Ditto.
3307         * page/scrolling/AsyncScrollingCoordinator.h:
3308         * page/scrolling/AxisScrollSnapOffsets.h:
3309         (WebCore::closestSnapOffset): Modified to also return the selected snap point index so we can track
3310         it to handle resize operations.
3311         * page/scrolling/ScrollingTree.h:
3312         (WebCore::ScrollingTree::updateScrollSnapOffsetIndices):
3313         * page/scrolling/ThreadedScrollingTree.cpp:
3314         (WebCore::ThreadedScrollingTree::updateScrollSnapOffsetIndices): Added method to dispatch the active
3315         horizontal and vertical scroll snap indices back to the main thread.
3316         * page/scrolling/ThreadedScrollingTree.h:
3317         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
3318         (WebCore::ScrollingTreeFrameScrollingNodeMac::handleWheelEvent): After the scroll controller processes
3319         the current event, notify the main thread of any change in the active scroll snap index.
3320         * platform/ScrollAnimator.cpp:
3321         (WebCore::ScrollAnimator::activeScrollSnapOffsetIndexDidChange): Added method to allow ScrollAnimator
3322         clients to find out about the current scroll snap state, which is only known by the ScrollController.
3323         (WebCore::ScrollAnimator::activeScrollSnapOffsetIndexForAxis): Ditto.
3324         * platform/ScrollAnimator.h:
3325         * platform/ScrollView.cpp:
3326         (WebCore::ScrollView::scrollToNearestActiveSnapPoint): Added method that allows us to set scroll position
3327         to one of our active scroll snap offsets.
3328         * platform/ScrollView.h:
3329         * platform/ScrollableArea.cpp:
3330         (WebCore::ScrollableArea::handleWheelEvent): If the active scroll snap offset has changed, make sure we
3331         keep track of the new values for potential resize operations.
3332         (WebCore::ScrollableArea::clearHorizontalSnapOffsets): Make sure to also clear out the current snap index.
3333         (WebCore::ScrollableArea::clearVerticalSnapOffsets): Ditto.
3334         (WebCore::ScrollableArea::nearestActiveSnapPoint): New method that returns an updated IntPoint reflecting
3335         the proper scroll position based on the active scroll snap offset.
3336         * platform/ScrollableArea.h:
3337         (WebCore::ScrollableArea::currentHorizontalSnapPointIndex): Added.
3338         (WebCore::ScrollableArea::setCurrentHorizontalSnapPointIndex): Added.
3339         (WebCore::ScrollableArea::currentVerticalSnapPointIndex): Added.
3340         (WebCore::ScrollableArea::setCurrentVerticalSnapPointIndex): Added.
3341         (WebCore::ScrollableArea::scrollToNearestActiveSnapPoint): Added.
3342         * platform/cocoa/ScrollController.h:
3343         (WebCore::ScrollControllerClient::activeScrollOffsetIndex): Added new method for clients to implement.
3344         (WebCore::ScrollController::activeScrollSnapOffsetIndexDidChange): Added.
3345         (WebCore::ScrollController::setScrollSnapOffsetIndexDidChange): Added.
3346         * platform/cocoa/ScrollController.mm:
3347         (WebCore::ScrollController::activeScrollSnapOffsetIndexForAxis): Helper method to return current active
3348         index (if applicable).
3349         (WebCore::ScrollController::setActiveScrollSnapOffsetIndexForAxis): Helper function to safely set
3350         the current active index.
3351         (WebCore::ScrollController::beginScrollSnapAnimation): Updated to keep track of the new active scroll snap
3352         index, as well as whether the current animation actually changed the active snap point offset.
3353         * platform/cocoa/ScrollSnapAnimatorState.h: Revise to use modern C++ initializers, and to track a new index
3354         that represents the current scroll snap offset.
3355         * platform/cocoa/ScrollSnapAnimatorState.mm:
3356         (WebCore::ScrollSnapAnimatorState::ScrollSnapAnimatorState): Update for modern C++ syntax.
3357         * rendering/RenderLayer.cpp:
3358         (WebCore::RenderLayer::scrollToNearestActiveSnapPoint): New method to set scroll position to be one of our
3359         active scroll snap points.
3360         (WebCore::RenderLayer::updateScrollInfoAfterLayout): Add a new call to 'scrollToNearestActiveSnapPoint' so that
3361         we stay on the current scroll snap offset during resizing.
3362         * rendering/RenderLayer.h:
3363
3364 2015-05-11  Myles C. Maxfield  <mmaxfield@apple.com>
3365
3366         Addressing post-review comments after r184037.
3367
3368         Unreviewed.
3369
3370         No new tests because there is no behavior change.
3371
3372         * rendering/SimpleLineLayoutTextFragmentIterator.cpp:
3373         (WebCore::SimpleLineLayout::TextFragmentIterator::runWidth):
3374
3375 2015-05-11  Brent Fulgham  <bfulgham@apple.com>
3376
3377         [Win] Move Windows build target to Windows 7 (or newer)
3378         https://bugs.webkit.org/show_bug.cgi?id=144890
3379         <rdar://problem/20707307>
3380
3381         Reviewed by Anders Carlsson.
3382
3383         Update linked SDK and minimal Windows level to be compatible with
3384         Windows 7 or newer.
3385
3386         * WebCore.vcxproj/WebCore.vcxproj:
3387         * WebCore.vcxproj/WebCoreGenerated.vcxproj:
3388         * WebCore.vcxproj/WebCoreTestSupport.vcxproj:
3389         * WebCorePrefix.h:
3390         * config.h:
3391         * testing/js/WebCoreTestSupportPrefix.h:
3392
3393 2015-05-11  Joanmarie Diggs  <jdiggs@igalia.com>
3394
3395         AX: [ATK] Always include rows in the tree of accessible tables
3396         https://bugs.webkit.org/show_bug.cgi?id=144885
3397
3398         Reviewed by Chris Fleizach.
3399
3400         Remove the code that excluded rows from the tree of accessible tables for
3401         Gtk and Efl, the latter of which inherited the exclusion from the former.
3402
3403         No new tests. We already have several tests which cover table hierarchy.
3404         The associated expectations have been updated as part of this fix.
3405
3406         * accessibility/AccessibilityTable.cpp:
3407         (WebCore::AccessibilityTable::addChildrenFromSection):
3408         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
3409         (webkitAccessibleGetParent):
3410
3411 2015-05-11  Matt Baker  <mattbaker@apple.com>
3412
3413         Web Inspector: REGRESSION (r175203): No profile information is shown in Inspector
3414         https://bugs.webkit.org/show_bug.cgi?id=144808
3415
3416         Reviewed by Darin Adler.
3417
3418         Profiles started from the console should always use the Inspector environment's shared stopwatch.
3419
3420         * inspector/InspectorTimelineAgent.cpp:
3421         (WebCore::InspectorTimelineAgent::startFromConsole):
3422
3423 2015-05-11  Alex Christensen  <achristensen@webkit.org>
3424
3425         [Content Extensions] Support domain-specific rules and exceptions.
3426         https://bugs.webkit.org/show_bug.cgi?id=144833
3427
3428         Reviewed by Darin Adler.
3429
3430         Test: http/tests/contentextensions/domain-rules.html
3431         (And lots of API tests)
3432
3433         This patch adds if-domain and unless-domain to the trigger in the JSON format.
3434         if-domain makes the rule apply only to domains in the list.
3435         unless-domain makes the rule apply to domains that are not in the list.
3436         
3437         All rules without if-domain or unless-domain are compiled into a set of DFAs.  This behavior is unchanged.
3438         All rules with if-domain or unless-domain are compiled into a separate set of DFAs.
3439         The domains are also compiled into another set of DFAs.  This makes 3 arrays of DFA bytecode instead of 1.
3440         
3441         If there are no domain specific rules, there is no change in behavior.
3442         If there are domain specific rules, the URL will be checked for matches in both
3443         filtersWithoutDomainsBytecode and filtersWithDomainsBytecode.  If there are matches from 
3444         filtersWithDomainsBytecode then the domain of the main document will be checked with 
3445         domainFiltersBytecode to see which of the matches applies to this domain.
3446
3447         * contentextensions/CombinedURLFilters.cpp:
3448         (WebCore::ContentExtensions::CombinedURLFilters::isEmpty):
3449         (WebCore::ContentExtensions::CombinedURLFilters::addDomain):
3450         * contentextensions/CombinedURLFilters.h:
3451         Added addDomain, which adds characters from a domain to the prefix tree directly without using YARR.
3452         * contentextensions/CompiledContentExtension.cpp:
3453         (WebCore::ContentExtensions::CompiledContentExtension::globalDisplayNoneSelectors):
3454         * contentextensions/CompiledContentExtension.h:
3455         * contentextensions/ContentExtensionCompiler.cpp:
3456         (WebCore::ContentExtensions::serializeActions):
3457         (WebCore::ContentExtensions::compileRuleList):
3458         Separate the rules into rules with domains and rules without domains and compile to bytecode.
3459         * contentextensions/ContentExtensionCompiler.h:
3460         Updated compiler interface to reflect the slightly more complicated structure.
3461         * contentextensions/ContentExtensionError.cpp:
3462         (WebCore::ContentExtensions::contentExtensionErrorCategory):
3463         * contentextensions/ContentExtensionError.h:
3464         Added new parsing errors.
3465         * contentextensions/ContentExtensionParser.cpp:
3466         (WebCore::ContentExtensions::getDomainList):
3467         (WebCore::ContentExtensions::loadTrigger):
3468         (WebCore::ContentExtensions::loadEncodedRules):
3469         * contentextensions/ContentExtensionRule.h:
3470         (WebCore::ContentExtensions::Trigger::operator==):
3471         Parse the new domain structures from JSON into the Trigger structure.
3472         * contentextensions/ContentExtensionsBackend.cpp:
3473         (WebCore::ContentExtensions::ContentExtensionsBackend::actionsForResourceLoad):
3474         Interpret as much bytecode as necessary to determine which rules apply to this URL and domain.
3475         * contentextensions/DFABytecode.h:
3476         (WebCore::ContentExtensions::instructionSizeWithArguments):
3477         * contentextensions/DFABytecodeCompiler.cpp:
3478         (WebCore::ContentExtensions::DFABytecodeCompiler::emitAppendAction):
3479         (WebCore::ContentExtensions::DFABytecodeCompiler::emitTestFlagsAndAppendAction):
3480         (WebCore::ContentExtensions::DFABytecodeCompiler::compileNode):
3481         * contentextensions/DFABytecodeCompiler.h:
3482         * contentextensions/DFABytecodeInterpreter.cpp:
3483         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretAppendAction):
3484         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretTestFlagsAndAppendAction):
3485         (WebCore::ContentExtensions::DFABytecodeInterpreter::actionsFromDFARoot):
3486         (WebCore::ContentExtensions::DFABytecodeInterpreter::interpret):
3487         * contentextensions/DFABytecodeInterpreter.h:
3488         * loader/ResourceLoadInfo.h:
3489         Keep track of which actions have an if-domain trigger.  If an action is in the 
3490         filtersWithDomainsBytecode, then it either has an if-domain or an unless-domain in its trigger.
3491         This requires additional information in the bytecode, so there are two new bytecode types.
3492
3493 2015-05-11  Yoav Weiss  <yoav@yoav.ws>
3494
3495         Add srcset, sizes and picture to the features json
3496         https://bugs.webkit.org/show_bug.cgi?id=144862
3497
3498         Reviewed by Benjamin Poulain.
3499
3500         Add the srcset w descriptor and sizes attribute as a new feature in the JSON file,
3501         as well as adding the picture element and srcset's x descriptor as seperate features.
3502
3503         No new tests, since no new functionality added.
3504
3505         * features.json:
3506
3507 2015-05-11  Chris Dumez  <cdumez@apple.com>
3508
3509         Fix checkingLogicalHeight initialization in Document::updateLayoutIfDimensionsOutOfDate()
3510         https://bugs.webkit.org/show_bug.cgi?id=144873
3511
3512         Reviewed by Simon Fraser.
3513
3514         Fix checkingLogicalHeight initialization in Document::updateLayoutIfDimensionsOutOfDate().
3515         checkingLogicalHeight should only be initialized to true when
3516         "dimensionsCheck & WidthDimensionsCheck" if isVertical is true.
3517
3518         * dom/Document.cpp:
3519         (WebCore::Document::updateLayoutIfDimensionsOutOfDate):
3520
3521 2015-05-11  Daniel Bates  <dabates@apple.com>
3522
3523         [iOS] Close all open databases in expiration handler of process assertion
3524         https://bugs.webkit.org/show_bug.cgi?id=144661
3525         <rdar://problem/20845052>
3526
3527         Reviewed by Darin Adler.
3528
3529         Expose functionality in WebCore to close all open databases. Closing a SQLite database
3530         will interrupt any in-progress database transactions.
3531
3532         * Modules/webdatabase/AbstractDatabaseServer.h:
3533         * Modules/webdatabase/DatabaseManager.cpp:
3534         (WebCore::DatabaseManager::closeAllDatabases): Added; turns around and calls DatabaseServer::closeAllDatabases().
3535         * Modules/webdatabase/DatabaseManager.h: Export DatabaseManager::closeAllDatabases() so that
3536         we can call in from WebKit2.
3537         * Modules/webdatabase/DatabaseServer.cpp:
3538         (WebCore::DatabaseServer::closeAllDatabases): Added; turns around and calls DatabaseTracker::closeAllDatabases().
3539         * Modules/webdatabase/DatabaseServer.h:
3540         * Modules/webdatabase/DatabaseTracker.cpp:
3541         (WebCore::DatabaseTracker::closeAllDatabases): Added; closes all open databases.
3542         * Modules/webdatabase/DatabaseTracker.h: Export DatabaseTracker::closeAllDatabases() so that
3543         we can call in from Legacy WebKit.
3544
3545 2015-05-11  Antti Koivisto  <antti@apple.com>
3546
3547         WebContent crash under com.apple.WebCore: WebCore::WebKitCSSResourceValue::isCSSValueNone const + 6
3548         https://bugs.webkit.org/show_bug.cgi?id=144870
3549         rdar://problem/20727702
3550
3551         Reviewed by Simon Fraser.
3552
3553         No repro but we are seeing null pointer crashes like this:
3554
3555         Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
3556         0   com.apple.WebCore   0x00007fff92da5706 WebCore::WebKitCSSResourceValue::isCSSValueNone() const + 6
3557         1   com.apple.WebCore   0x00007fff93382b48 WebCore::MaskImageOperation::isCSSValueNone() const + 24
3558         2   com.apple.WebCore   0x00007fff92e0475e WebCore::FillLayer::hasNonEmptyMaskImage() const + 30
3559
3560         * platform/graphics/MaskImageOperation.cpp:
3561         (WebCore::MaskImageOperation::MaskImageOperation):
3562         (WebCore::MaskImageOperation::isCSSValueNone):
3563
3564             This would crash like this if both m_styleImage and m_cssMaskImageValue are null.
3565             There are no obvious guarantees that this doesn't happen. Two of the constructor variants allow it
3566             and there is setImage which may turn m_styleImage null later too.
3567
3568             Fix by making null m_cssMaskImageValue always signify CSSValueNone.
3569
3570         (WebCore::MaskImageOperation::cssValue):
3571
3572 2015-05-11  Chris Fleizach  <cfleizach@apple.com>
3573
3574         AX: Crash at WebCore::AccessibilityMenuList::addChildren()
3575         https://bugs.webkit.org/show_bug.cgi?id=144860
3576
3577         Reviewed by Mario Sanchez Prada.
3578
3579         There were some unsafe pointer accesses in AccessibilityMenuList code that needed to be cleaned up.
3580
3581         Test: accessibility/menu-list-crash2.html
3582
3583         * accessibility/AccessibilityMenuList.cpp:
3584         (WebCore::AccessibilityMenuList::addChildren):
3585
3586 2015-05-11  Przemyslaw Szymanski  <p.szymanski3@samsung.com>
3587
3588         [WebGL] Unnecessary condition check in the while loop
3589         https://bugs.webkit.org/show_bug.cgi?id=125001
3590
3591         Reviewed by Csaba Osztrogonác.
3592
3593         While loop in this case needs to be optimized a little.
3594         For now a conditional statement in while will execute two
3595         times at begin. do-while loop avoids to check first statement.
3596
3597         No new tests. No behaviour changed.
3598
3599         * html/canvas/WebGLFramebuffer.cpp:
3600         (WebCore::WebGLFramebuffer::removeAttachmentFromBoundFramebuffer):
3601
3602 2015-05-11  Joonghun Park  <jh718.park@samsung.com>
3603
3604         [GTK] Reorder Performance class's member initialization sequence
3605         https://bugs.webkit.org/show_bug.cgi?id=144858
3606
3607         Reviewed by Csaba Osztrogonác.
3608
3609         No new tests, no new behaviors.
3610
3611         * page/Performance.cpp:
3612         (WebCore::Performance::Performance):
3613
3614 2015-05-11  Zan Dobersek  <zdobersek@igalia.com>
3615
3616         Reduce TransformationMatrix copies in WebKitCSSMatrix operations
3617         https://bugs.webkit.org/show_bug.cgi?id=144795
3618
3619         Reviewed by Darin Adler.
3620
3621         Instead of copying the TransformationMatrix member, performing
3622         the operation on it and then copying it again when creating
3623         the new WebKitCSSMatrix object, copy it just once by first
3624         creating the new WebKitCSSMatrix object and then performing
3625         the operation on that object's TransformationMatrix directly.
3626
3627         * css/WebKitCSSMatrix.cpp:
3628         (WebCore::WebKitCSSMatrix::multiply):
3629         (WebCore::WebKitCSSMatrix::translate):
3630         (WebCore::WebKitCSSMatrix::scale):
3631         (WebCore::WebKitCSSMatrix::rotate):
3632         (WebCore::WebKitCSSMatrix::rotateAxisAngle):
3633         (WebCore::WebKitCSSMatrix::skewX):
3634         (WebCore::WebKitCSSMatrix::skewY):
3635
3636 2015-05-11  Zan Dobersek  <zdobersek@igalia.com>
3637
3638         Add missing vtable override specifiers under Source/WebCore/loader, Source/WebCore/xml
3639         https://bugs.webkit.org/show_bug.cgi?id=144793
3640
3641         Reviewed by Darin Adler.
3642
3643         Update virtual method overrides under Source/WebCore/loader
3644         and Source/WebCore/dom which are missing the override specifier.
3645
3646         * loader/DocumentThreadableLoader.h:
3647         (WebCore::DocumentThreadableLoader::refThreadableLoader):
3648         (WebCore::DocumentThreadableLoader::derefThreadableLoader):
3649         * loader/cache/CachedRawResource.h:
3650         * xml/parser/XMLDocumentParser.h:
3651
3652 2015-05-11  Zan Dobersek  <zdobersek@igalia.com>
3653
3654         Add missing vtable override specifiers under Source/WebCore/accessibility, Source/WebCore/dom
3655         https://bugs.webkit.org/show_bug.cgi?id=144792
3656
3657         Reviewed by Darin Adler.
3658
3659         Update virtual method overrides under Source/WebCore/accessibility
3660         and Source/WebCore/dom which are missing the override specifier.
3661
3662         * accessibility/AccessibilityMockObject.h:
3663         (WebCore::AccessibilityMockObject::isDetachedFromParent): Deleted.
3664         * accessibility/AccessibilityRenderObject.h:
3665         * dom/DecodedDataDocumentParser.h:
3666         * dom/TouchEvent.h:
3667
3668 2015-05-10  Zan Dobersek  <zdobersek@igalia.com>
3669
3670         Have MediaStream::getAudioTracks(), MediaStream::getVideoTracks() return const references
3671         https://bugs.webkit.org/show_bug.cgi?id=144794
3672
3673         Reviewed by Philippe Normand.
3674
3675         * Modules/mediastream/MediaStream.h: getAudioTracks() and getVideoTracks()
3676         should return a const reference to the member variables, instead of
3677         copying the objects on every call.
3678
3679 2015-05-10  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
3680
3681         Use Ref instead of PassRefPtr in WebCore/page
3682         https://bugs.webkit.org/show_bug.cgi?id=144841
3683
3684         Reviewed by Darin Adler.
3685
3686         To kill PassRefPtr, this patch replaces PassRefPtr with Ref or RefPtr
3687         in WebCore/page.
3688
3689         No new tests, no behavior changes.
3690
3691         * page/DebugPageOverlays.cpp:
3692         * page/EventSource.cpp:
3693         (WebCore::EventSource::create):
3694         * page/EventSource.h:
3695         * page/History.h:
3696         (WebCore::History::create):
3697         * page/Location.h:
3698         (WebCore::Location::create):
3699         * page/MainFrame.cpp:
3700         (WebCore::MainFrame::create):
3701         * page/MainFrame.h:
3702         * page/Navigator.h:
3703         (WebCore::Navigator::create):
3704         * page/PageOverlay.cpp:
3705         (WebCore::PageOverlay::create):
3706         * page/PageOverlay.h:
3707         * page/Performance.h:
3708         * page/PerformanceEntryList.h:
3709         (WebCore::PerformanceEntryList::create):
3710         * page/PerformanceMark.h:
3711         (WebCore::PerformanceMark::create):
3712         * page/PerformanceMeasure.h:
3713         (WebCore::PerformanceMeasure::create):
3714         * page/PerformanceNavigation.h:
3715         (WebCore::PerformanceNavigation::create):
3716         * page/PerformanceResourceTiming.h:
3717         (WebCore::PerformanceResourceTiming::create):
3718         * page/PerformanceTiming.h:
3719         (WebCore::PerformanceTiming::create):
3720         * page/PerformanceUserTiming.h:
3721         (WebCore::UserTiming::create):
3722         * page/Screen.h:
3723         * page/Settings.cpp:
3724         (WebCore::Settings::create):
3725         * page/Settings.h:
3726         * page/TextIndicator.cpp:
3727         (WebCore::TextIndicator::create):
3728         * page/TextIndicator.h:
3729         * page/UserContentController.cpp:
3730         (WebCore::UserContentController::create):
3731         * page/UserContentController.h:
3732         * page/UserMessageHandlerDescriptor.h:
3733         (WebCore::UserMessageHandlerDescriptor::create):
3734         * page/UserMessageHandlersNamespace.h:
3735         * page/VisitedLinkStore.h:
3736         * page/WebKitNamespace.h:
3737         (WebCore::WebKitNamespace::create):
3738         * page/WebKitPoint.h:
3739         (WebCore::WebKitPoint::create):
3740         * page/WorkerNavigator.h:
3741         (WebCore::WorkerNavigator::create):
3742         * page/animation/ImplicitAnimation.h:
3743         (WebCore::ImplicitAnimation::create):
3744         * page/animation/KeyframeAnimation.h:
3745         * page/mac/ServicesOverlayController.h:
3746         * page/mac/ServicesOverlayController.mm:
3747         (WebCore::ServicesOverlayController::Highlight::createForSelection):
3748         (WebCore::ServicesOverlayController::Highlight::createForTelephoneNumber):
3749         * page/scrolling/ScrollingCoordinator.cpp:
3750         (WebCore::ScrollingCoordinator::create):
3751         * page/scrolling/ScrollingCoordinator.h:
3752         * page/scrolling/ScrollingStateFixedNode.cpp:
3753         (WebCore::ScrollingStateFixedNode::create):
3754         (WebCore::ScrollingStateFixedNode::clone):
3755         * page/scrolling/ScrollingStateFixedNode.h:
3756         * page/scrolling/ScrollingStateFrameScrollingNode.cpp:
3757         (WebCore::ScrollingStateFrameScrollingNode::create):
3758         (WebCore::ScrollingStateFrameScrollingNode::clone):
3759         * page/scrolling/ScrollingStateFrameScrollingNode.h:
3760         * page/scrolling/ScrollingStateNode.h:
3761         * page/scrolling/ScrollingStateOverflowScrollingNode.cpp:
3762         (WebCore::ScrollingStateOverflowScrollingNode::create):
3763         (WebCore::ScrollingStateOverflowScrollingNode::clone):
3764         * page/scrolling/ScrollingStateOverflowScrollingNode.h:
3765         * page/scrolling/ScrollingStateStickyNode.cpp:
3766         (WebCore::ScrollingStateStickyNode::create):
3767         (WebCore::ScrollingStateStickyNode::clone):
3768         * page/scrolling/ScrollingStateStickyNode.h:
3769         * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
3770         (WebCore::ScrollingCoordinator::create):
3771         * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.h:
3772         * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm:
3773         (WebCore::ScrollingTreeFrameScrollingNodeIOS::create):
3774         * page/scrolling/ios/ScrollingTreeIOS.cpp:
3775         (WebCore::ScrollingTreeIOS::create):
3776         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
3777         (WebCore::ScrollingCoordinator::create):
3778         * page/scrolling/mac/ScrollingTreeFixedNode.h:
3779         * page/scrolling/mac/ScrollingTreeFixedNode.mm:
3780         (WebCore::ScrollingTreeFixedNode::create):
3781         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
3782         * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
3783         (WebCore::ScrollingTreeFrameScrollingNodeMac::create):
3784         * page/scrolling/mac/ScrollingTreeMac.cpp:
3785         (ScrollingTreeMac::create):
3786         * page/scrolling/mac/ScrollingTreeMac.h:
3787         * page/scrolling/mac/ScrollingTreeStickyNode.h:
3788         * page/scrolling/mac/ScrollingTreeStickyNode.mm:
3789         (WebCore::ScrollingTreeStickyNode::create):
3790
3791 2015-05-10  Simon Fraser  <simon.fraser@apple.com>
3792
3793         background-position sometimes doesn't work properly with background-attachment: fixed
3794         https://bugs.webkit.org/show_bug.cgi?id=103757
3795         rdar://problem/18749925
3796
3797         Reviewed by Darin Adler.
3798         
3799         Fix sizing issues with fixed backgrounds when top content inset (blurred toolbar) is in
3800         effect.
3801         
3802         The primary issue was that positioningAreaSize was including the top content inset
3803         height, and should not have been, but there were also issues with the "fixedBackgroundPaintsInLocalCoordinates"
3804         code path, which kicks in when the root background is fixed.
3805
3806         Tests: platform/mac-wk2/tiled-drawing/top-content-inset-fixed-attachment-cover-local.html
3807                platform/mac-wk2/tiled-drawing/top-content-inset-fixed-attachment-cover.html
3808                platform/mac-wk2/tiled-drawing/top-content-inset-fixed-attachment-local.html
3809                platform/mac-wk2/tiled-drawing/top-content-inset-fixed-attachment-positioned.html
3810
3811         * rendering/RenderBoxModelObject.cpp:
3812         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
3813
3814 2015-05-10  Sungmann Cho  <sungmann.cho@navercorp.com>
3815
3816         Get rid of the public item accessors in BackForwardClient
3817         https://bugs.webkit.org/show_bug.cgi?id=144827
3818
3819         Reviewed by Darin Adler.
3820
3821         Remove backItem(), currentItem(), and forwardItem() from BackForwardClient.
3822         We can still use these functionalities through BackForwardController.
3823
3824         No new tests, no behavior change.
3825
3826         * history/BackForwardClient.h:
3827         (WebCore::BackForwardClient::backItem): Deleted.
3828         (WebCore::BackForwardClient::currentItem): Deleted.
3829         (WebCore::BackForwardClient::forwardItem): Deleted.
3830
3831 2015-05-10  Sungmann Cho  <sungmann.cho@navercorp.com>
3832
3833         Rename Length::isPercent() and Length::isPercentNotCalculated().
3834         https://bugs.webkit.org/show_bug.cgi?id=144791
3835
3836         Reviewed by Darin Adler.
3837
3838         1. Rename these methods as below for consistency and clarity.
3839
3840         Length::isPercentNotCalculated() => Length::isPercent()
3841         Length::isPercent() => Length::isPercentOrCalculated()
3842
3843         2. Simplify the condition check of length type in SVGLengthContext::valueForLength().
3844
3845         "length.isPercent() && !length.isCalculated()" => "length.isPercent()"
3846
3847         No new tests, no behavior change.
3848
3849         * css/CSSComputedStyleDeclaration.cpp:
3850         (WebCore::valueForImageSliceSide):
3851         (WebCore::valueForReflection):
3852         (WebCore::percentageOrZoomAdjustedValue):
3853         (WebCore::lineHeightFromStyle):
3854         (WebCore::ComputedStyleExtractor::propertyValue):
3855         * html/HTMLPlugInImageElement.cpp:
3856         (WebCore::is100Percent):
3857         * page/animation/AnimationBase.cpp:
3858         (WebCore::AnimationBase::computeTransformedExtentViaTransformList):
3859         * platform/Length.h:
3860         (WebCore::Length::percent):
3861         (WebCore::Length::isPercent):
3862         (WebCore::Length::isPercentOrCalculated):
3863         (WebCore::Length::isSpecified):
3864         (WebCore::Length::isPercentNotCalculated): Deleted.
3865         * platform/graphics/transforms/TranslateTransformOperation.h:
3866         * rendering/AutoTableLayout.cpp:
3867         (WebCore::AutoTableLayout::recalcColumn):
3868         (WebCore::AutoTableLayout::fullRecalc):
3869         (WebCore::shouldScaleColumns):
3870         (WebCore::AutoTableLayout::computeIntrinsicLogicalWidths):
3871         (WebCore::AutoTableLayout::calcEffectiveLogicalWidth):
3872         (WebCore::AutoTableLayout::layout):
3873         * rendering/FixedTableLayout.cpp:
3874         (WebCore::FixedTableLayout::calcWidthArray):
3875         (WebCore::FixedTableLayout::applyPreferredLogicalWidthQuirks):
3876         (WebCore::FixedTableLayout::layout):
3877         * rendering/RenderBlock.cpp:
3878         (WebCore::RenderBlock::isSelfCollapsingBlock):
3879         (WebCore::RenderBlock::textIndentOffset):
3880         * rendering/RenderBox.cpp:
3881         (WebCore::RenderBox::needsPreferredWidthsRecalculation):
3882         (WebCore::RenderBox::computeLogicalHeight):
3883         (WebCore::RenderBox::computeContentAndScrollbarLogicalHeightUsing):
3884         (WebCore::RenderBox::computePercentageLogicalHeight):
3885         (WebCore::RenderBox::computeReplacedLogicalWidthRespectingMinMaxWidth):
3886         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
3887         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
3888         (WebCore::RenderBox::availableLogicalHeightUsing):
3889         (WebCore::logicalWidthIsResolvable):
3890         (WebCore::RenderBox::percentageLogicalHeightIsResolvableFromBlock):
3891         (WebCore::RenderBox::hasUnsplittableScrollingOverflow):
3892         (WebCore::RenderBox::layoutOverflowRectForPropagation):
3893         * rendering/RenderBoxModelObject.cpp:
3894         (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight):
3895         (WebCore::RenderBoxModelObject::relativePositionOffset):
3896         (WebCore::RenderBoxModelObject::computedCSSPadding):
3897         (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
3898         (WebCore::RenderBoxModelObject::calculateFillTileSize):
3899         * rendering/RenderDeprecatedFlexibleBox.cpp:
3900         (WebCore::RenderDeprecatedFlexibleBox::applyLineClamp):
3901         (WebCore::RenderDeprecatedFlexibleBox::clearLineClamp):
3902         * rendering/RenderElement.cpp:
3903         (WebCore::mustRepaintFillLayers):
3904         * rendering/RenderFileUploadControl.cpp:
3905         (WebCore::RenderFileUploadControl::computeIntrinsicLogicalWidths):
3906         * rendering/RenderFrameSet.cpp:
3907         (WebCore::RenderFrameSet::layOutAxis):
3908         * rendering/RenderImage.cpp:
3909         (WebCore::RenderImage::repaintOrMarkForLayout):
3910         * rendering/RenderInline.cpp:
3911         (WebCore::computeMargin):
3912         * rendering/RenderListBox.cpp:
3913         (WebCore::RenderListBox::computeIntrinsicLogicalWidths):
3914         * rendering/RenderMenuList.cpp:
3915         (RenderMenuList::computeIntrinsicLogicalWidths):
3916         * rendering/RenderObject.cpp:
3917         (WebCore::objectIsRelayoutBoundary):
3918         * rendering/RenderReplaced.cpp:
3919         (WebCore::RenderReplaced::computePreferredLogicalWidths):
3920         * rendering/RenderSlider.cpp:
3921         (WebCore::RenderSlider::computeIntrinsicLogicalWidths):
3922         * rendering/RenderTable.cpp:
3923         (WebCore::RenderTable::convertStyleLogicalHeightToComputedHeight):
3924         * rendering/RenderTableSection.cpp:
3925         (WebCore::RenderTableSection::layoutRows):
3926         * rendering/RenderTextControl.cpp:
3927         (WebCore::RenderTextControl::computeIntrinsicLogicalWidths):
3928         * rendering/RenderView.cpp:
3929         (WebCore::RenderView::layout):
3930         * rendering/RootInlineBox.cpp:
3931         (WebCore::RootInlineBox::verticalPositionForBox):
3932         * rendering/style/GridLength.h:
3933         (WebCore::GridLength::isPercentage):
3934         * rendering/style/GridTrackSize.h:
3935         (WebCore::GridTrackSize::isPercentage):
3936         * rendering/style/RenderStyle.cpp:
3937         (WebCore::RenderStyle::computedLineHeight):
3938         * rendering/svg/RenderSVGRoot.cpp:
3939         (WebCore::RenderSVGRoot::hasRelativeDimensions):
3940         * svg/SVGLengthContext.cpp:
3941         (WebCore::SVGLengthContext::valueForLength):
3942         * svg/graphics/SVGImage.cpp:
3943         (WebCore::SVGImage::hasRelativeWidth):
3944         (WebCore::SVGImage::hasRelativeHeight):
3945
3946 2015-05-10  Sungmann Cho  <sungmann.cho@navercorp.com>
3947
3948         Remove unnecessary semicolons.
3949         https://bugs.webkit.org/show_bug.cgi?id=144844
3950
3951         Reviewed by Darin Adler.
3952
3953         No new tests, no behavior change.
3954
3955         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3956         (WebCore::MediaPlayerPrivateAVFoundationObjC::supportsType):
3957         * platform/ios/PasteboardIOS.mm:
3958         (WebCore::Pasteboard::readString):
3959         * platform/mediastream/RealtimeMediaSourceCapabilities.h:
3960         (WebCore::RealtimeMediaSourceCapabilities::setHasVideoSource):
3961         * platform/network/mac/ResourceErrorMac.mm:
3962         (WebCore::ResourceError::nsError):
3963         * rendering/RenderThemeIOS.mm:
3964         (WebCore::getSharedFunctionRef):
3965
3966 2015-05-10  Sungmann Cho  <sungmann.cho@navercorp.com>
3967
3968         Remove unnecessary forward declarations in StyleProperties.h
3969         https://bugs.webkit.org/show_bug.cgi?id=144843
3970
3971         Reviewed by Darin Adler.
3972
3973         No new tests, no behavior change.        
3974
3975         * css/StyleProperties.h:
3976
3977 2015-05-10  Darin Adler  <darin@apple.com>
3978
3979         [Cocoa] Fix paths and resort WebCore project file
3980         https://bugs.webkit.org/show_bug.cgi?id=144838
3981
3982         Reviewed by Dan Bernstein.
3983
3984         * We