6e1df60f90cee2c3e8cc604d09ae7c7be9eccf30
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-06-30  Brent Fulgham  <bfulgham@apple.com>
2
3         [Win] Unreviewed gardening.
4
5         * WebCore.vcxproj/WebCore.vcxproj: Do not compile JSFileException
6         and JSFileReaderSync multiple times.
7
8 2014-06-30  Daniel Bates  <dabates@apple.com>
9
10         Avoid copying function object in lambda function in ScrollingThread::dispatchBarrier(); actually use move semantics
11         https://bugs.webkit.org/show_bug.cgi?id=134470
12
13         Reviewed by Anders Carlsson.
14
15         Currently we always copy construct the captured std::function object when calling callOnMainThread()
16         in the lambda function created in ScrollingThread::dispatchBarrier() because captured variables are
17         const in a lambda expression's body by default. That is, the std::function object is captured as const.
18         Instead, we should mark this lambda expression as mutable so the captured std::function object is
19         non-const and hence we can use move semantics when passing it to callOnMainThread().
20
21         * page/scrolling/ScrollingThread.cpp:
22         (WebCore::ScrollingThread::dispatchBarrier):
23
24 2014-06-30  Anders Carlsson  <andersca@apple.com>
25
26         Adopt the legacy session decoding inside WebPage::restoreSession for now
27         https://bugs.webkit.org/show_bug.cgi?id=134465
28
29         Reviewed by Sam Weinig.
30
31         * WebCore.exp.in:
32
33 2014-06-30  Commit Queue  <commit-queue@webkit.org>
34
35         Unreviewed, rolling out r170578.
36         https://bugs.webkit.org/show_bug.cgi?id=134462
37
38         causes assertions loading nytimes.com on iOS (Requested by
39         smfr on #webkit).
40
41         Reverted changeset:
42
43         "Create NSURLRequest lazily when USE(CFNETWORK) is enabled"
44         https://bugs.webkit.org/show_bug.cgi?id=134441
45         http://trac.webkit.org/changeset/170578
46
47 2014-06-30  Alex Christensen  <achristensen@webkit.org>
48
49         Reduce dynamic memory allocation in css jit.
50         https://bugs.webkit.org/show_bug.cgi?id=134416
51
52         Reviewed by Benjamin Poulain.
53
54         * cssjit/FunctionCall.h:
55         (WebCore::FunctionCall::FunctionCall):
56         (WebCore::FunctionCall::saveAllocatedCallerSavedRegisters):
57         * cssjit/RegisterAllocator.h:
58         * cssjit/SelectorCompiler.cpp:
59         (WebCore::SelectorCompiler::addPseudoClassType):
60         (WebCore::SelectorCompiler::SelectorCodeGenerator::generatePrologue):
61         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
62         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
63         Use inlineCapacity template parameter to reduce malloc calls.
64         I use 16 and 32 as the inline capacity for non-register related vectors because that
65         is probably big enough for the selector compiler, and if it is not then a malloc
66         call will not be significant because the selector is very complex.
67         * cssjit/StackAllocator.h:
68         (WebCore::StackAllocator::push):
69         Pass a vector of stack references to match calls to pop and to avoid a call to appendVector.
70
71 2014-06-30  Alex Christensen  <achristensen@webkit.org>
72
73         Use non-thumb registers in armv7 css jit.
74         https://bugs.webkit.org/show_bug.cgi?id=134450
75
76         Reviewed by Geoff Garen.
77
78         * cssjit/RegisterAllocator.h:
79         (WebCore::RegisterAllocator::isValidRegister):
80         (WebCore::RegisterAllocator::isCallerSavedRegister):
81         Use additional general purpose registers.
82         * cssjit/SelectorCompiler.cpp:
83         (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
84         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
85         Always succeed when compiling css selectors.
86
87 2014-06-30  Myles C. Maxfield  <mmaxfield@apple.com>
88
89         Tiles on bottom of screen are not always allocated when necessary
90         https://bugs.webkit.org/show_bug.cgi?id=134272
91
92         Reviewed by Simon Fraser.
93
94         The initial visibleRect is in the coordinate of the root layer, so its origin
95         is at the top left of the view. The initial rect we were using doesn't
96         include the contents inset, so it was too short, which was causing tiles near
97         the bottom of the screen to not always be allocated if the tile threshold was
98         close to the bottom of the view. Instead, we want to include the contents
99         inset size so the visible rect includes the entire view.
100         GraphicsLayerCA::recursiveCommitChanges() takes care of mapping and cropping
101         the visible rect into the tiled layer's coordinate system, at which point it
102         is used for visible tile logic.
103
104         Test: platform/mac-wk2/tiled-drawing/visible-rect-content-inset.html
105
106         * platform/graphics/ca/TileCoverageMap.cpp:
107         (WebCore::TileCoverageMap::update):
108         * rendering/RenderLayerCompositor.cpp:
109         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
110
111 2014-06-30  Brent Fulgham  <bfulgham@apple.com>
112
113         [Win] Unreviewed project gardening.
114
115         * WebCore.vcxproj/WebCore.vcxproj: Clean up path information so
116         files appear in appropriate places in project view.
117         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
118
119 2014-06-30  Zalan Bujtas  <zalan@apple.com>
120
121         Remove redundant repaintCompositedLayers() parameter and its dependencies.
122         https://bugs.webkit.org/show_bug.cgi?id=134431
123
124         Reviewed by Darin Adler.
125
126         No change in functionality.
127
128         * rendering/RenderLayer.cpp:
129         (WebCore::RenderLayer::convertToPixelSnappedLayerCoords): Deleted.
130         (WebCore::RenderLayer::convertToLayerCoords): Deleted.
131         * rendering/RenderLayer.h:
132         * rendering/RenderLayerCompositor.cpp:
133         (WebCore::RenderLayerCompositor::repaintCompositedLayers):
134         (WebCore::RenderLayerCompositor::recursiveRepaintLayer):
135         * rendering/RenderLayerCompositor.h:
136
137 2014-06-30  Alex Christensen  <achristensen@webkit.org>
138
139         Remove webkit prefix from pointer lock.
140         https://bugs.webkit.org/show_bug.cgi?id=134312
141
142         Reviewed by Dean Jackson.
143
144         * dom/Document.cpp:
145         (WebCore::Document::exitPointerLock):
146         (WebCore::Document::pointerLockElement):
147         (WebCore::Document::webkitExitPointerLock): Deleted.
148         (WebCore::Document::webkitPointerLockElement): Deleted.
149         * dom/Document.h:
150         * dom/Document.idl:
151         * dom/Element.cpp:
152         (WebCore::Element::requestPointerLock):
153         (WebCore::Element::webkitRequestPointerLock): Deleted.
154         * dom/Element.h:
155         * dom/Element.idl:
156         * dom/EventNames.h:
157         * dom/MouseEvent.idl:
158         * dom/MouseRelatedEvent.h:
159         (WebCore::MouseRelatedEvent::movementX):
160         (WebCore::MouseRelatedEvent::movementY):
161         (WebCore::MouseRelatedEvent::webkitMovementX): Deleted.
162         (WebCore::MouseRelatedEvent::webkitMovementY): Deleted.
163         * page/PointerLockController.cpp:
164         (WebCore::PointerLockController::PointerLockController):
165         Initialize all data members.
166         (WebCore::PointerLockController::requestPointerLock):
167         (WebCore::PointerLockController::didAcquirePointerLock):
168         (WebCore::PointerLockController::didNotAcquirePointerLock):
169         (WebCore::PointerLockController::didLosePointerLock):
170
171 2014-06-30  Myles C. Maxfield  <mmaxfield@apple.com>
172
173         U16_IS_SURROGATE should not be called with a UChar32
174         https://bugs.webkit.org/show_bug.cgi?id=134440
175
176         Reviewed by Darin Adler.
177
178         No new tests because there is no behavior change.
179
180         * platform/graphics/mac/ComplexTextController.cpp:
181         (WebCore::advanceByCombiningCharacterSequence):
182
183 2014-06-30  Ryuan Choi  <ryuan.choi@samsung.com>
184
185         [EFL] Remove m_evasObject from Widget
186         https://bugs.webkit.org/show_bug.cgi?id=134442
187
188         Reviewed by Gyuyoung Kim.
189
190         Since WebKit1/EFL was dropped, we don't need to keep the m_evasObject
191         in the Widget.cpp because it's not used for WebKit2/Efl.
192
193         * platform/Widget.h:
194         (WebCore::Widget::evasObject): Deleted.
195         * platform/efl/ScrollbarEfl.cpp:
196         Removed WebKit1/Efl specific code which uses m_evasObject.
197         It will be a dummy until WebKit2/Efl support proper scrollbar implementation.
198         (WebCore::ScrollbarEfl::ScrollbarEfl):
199         (WebCore::ScrollbarEfl::~ScrollbarEfl):
200         (WebCore::ScrollbarEfl::setParent):
201         (WebCore::ScrollbarEfl::frameRectsChanged):
202         (WebCore::ScrollbarEfl::invalidate):
203         (ScrollbarEfl::ScrollbarEfl): Deleted.
204         (ScrollbarEfl::~ScrollbarEfl): Deleted.
205         (scrollbarEflEdjeMessage): Deleted.
206         (ScrollbarEfl::setParent): Deleted.
207         (ScrollbarEfl::updateThumbPosition): Deleted.
208         (ScrollbarEfl::updateThumbProportion): Deleted.
209         (ScrollbarEfl::updateThumbPositionAndProportion): Deleted.
210         (ScrollbarEfl::frameRectsChanged): Deleted.
211         (ScrollbarEfl::invalidate): Deleted.
212         * platform/efl/ScrollbarEfl.h:
213         Removed unnecessary methods. In addition, applied final, override keyword.
214         (WebCore::ScrollbarEfl::handleMouseMoveEvent): Deleted.
215         (WebCore::ScrollbarEfl::handleMouseOutEvent): Deleted.
216         (WebCore::ScrollbarEfl::handleMousePressEvent): Deleted.
217         (WebCore::ScrollbarEfl::handleMouseReleaseEvent): Deleted.
218         * platform/efl/WidgetEfl.cpp:
219         (WebCore::Widget::Widget):
220         (WebCore::Widget::setEvasObject): Deleted.
221
222 2014-06-30  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
223
224         Fix deprecated warning with bison 3
225         https://bugs.webkit.org/show_bug.cgi?id=133791
226
227         Reviewed by Csaba Osztrogonác.
228
229         No new tests because no functional changes.
230
231         * css/CSSGrammar.y.in:
232         * xml/XPathGrammar.y:
233
234 2014-06-30  Jaehun Lim  <ljaehun.lim@samsung.com>
235
236         Remove HarfBuzzShaper::setDrawRange()
237         https://bugs.webkit.org/show_bug.cgi?id=134243
238
239         Reviewed by Gyuyoung Kim.
240
241         setDrawRange() is not used anywhere. Remove it.
242         And m_fromIndex and m_toIndex are changed by only setDrawRange().
243         So remove them too and use the default values instead of them.
244
245         No new tests, no behavior changes.
246
247         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
248         (WebCore::HarfBuzzShaper::HarfBuzzShaper):
249         (WebCore::HarfBuzzShaper::fillGlyphBufferFromHarfBuzzRun):
250             currentCharacterIndex is unsigned, always greater than 0. Clean up if statements.
251         (WebCore::HarfBuzzShaper::setDrawRange): Deleted.
252         * platform/graphics/harfbuzz/HarfBuzzShaper.h:
253
254 2014-06-29  Pratik Solanki  <psolanki@apple.com>
255
256         Create NSURLRequest lazily when USE(CFNETWORK) is enabled
257         https://bugs.webkit.org/show_bug.cgi?id=134441
258
259         Reviewed by Sam Weinig.
260
261         No new tests. Should be covered by exsting tests.
262
263         * platform/network/cf/ResourceRequest.h:
264         (WebCore::ResourceRequest::ResourceRequest):
265         * platform/network/cf/ResourceRequestCFNet.cpp:
266         (WebCore::ResourceRequest::doUpdatePlatformRequest):
267         (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
268         (WebCore::ResourceRequest::setStorageSession):
269         * platform/network/cocoa/ResourceRequestCocoa.mm:
270         (WebCore::ResourceRequest::nsURLRequest):
271
272 2014-06-29  Ryuan Choi  <ryuan.choi@samsung.com>
273
274         [EFL] Remove netscape plugin implementation from WebCore
275         https://bugs.webkit.org/show_bug.cgi?id=134438
276
277         Reviewed by Gyuyoung Kim.
278
279         Because WebKit1/Efl was dropped, PluginPackageEfl.cpp and PluginViewEfl.cpp are not necessary.
280
281         * PlatformEfl.cmake:
282         * plugins/efl/PluginPackageEfl.cpp: Removed.
283         * plugins/efl/PluginViewEfl.cpp: Removed.
284         * plugins/x11/PluginViewX11.cpp: Removed.
285         This file is to share common code between WebKit1/Efl and WebKit1/GTk.
286         Now, both ports are dropped WebKit1 support and the GTK port already removed the related files at r167016.
287
288 2014-06-29  Yoav Weiss  <yoav@yoav.ws>
289
290         Add support for HTMLImageElement's sizes attribute
291         https://bugs.webkit.org/show_bug.cgi?id=133620
292
293         Reviewed by Dean Jackson.
294
295         Tests: fast/dom/HTMLImageElement/sizes/image-sizes-1x.html
296                fast/dom/HTMLImageElement/sizes/image-sizes-2x.html
297                fast/dom/HTMLImageElement/sizes/image-sizes-js-change.html
298                fast/dom/HTMLImageElement/sizes/image-sizes-js-innerhtml.html
299                http/tests/loading/sizes/preload-image-sizes-2x.html
300                http/tests/loading/sizes/preload-image-sizes.html
301
302         This patch adds support for HTMLImageElement's sizes attribute and the
303         related srcset extended syntax as defined in
304         http://picture.responsiveimages.org/.
305         This sizes attribute syntax is added to the CSSGrammar and parsed by
306         the CSSParser.
307         The SourceSizeList class is generated by the parser, and used to get
308         the final source size.
309         HTMLImageElement and HTMLPreloadScanner send this value to
310         HTMLSrcsetParser.
311         HTMLSrcsetParser uses this value in order to pick the right resource.
312
313         * CMakeLists.txt: Added css/SourceSizeList.cpp.
314         * Configurations/FeatureDefines.xcconfig: Added the PICTURE_SIZES flag.
315         * WebCore.vcxproj/WebCore.vcxproj: Added css/SourceSizeList.*.
316         * WebCore.vcxproj/WebCore.vcxproj.filters: Added css/SourceSizeList.*.
317         * WebCore.xcodeproj/project.pbxproj: Added css/SourceSizeList.*.
318         * css/CSSGrammar.y.in: Added 4 grammar rules that define a Media condition,
319         Source size list, Source size length and source size.
320         * css/CSSParser.cpp:
321         (WebCore::CSSParser::parseSizesAttribute): Parse the sizes attribute.
322         (WebCore::CSSParser::detectAtToken): Set the token to SIZESATTR.
323         * css/CSSParser.h:
324         * css/SourceSizeList.cpp: Added. Defined the SourceSize and SourceSizeList classes.
325         (WebCore::SourceSize::match):
326         (WebCore::computeLength):
327         (WebCore::defaultValue):
328         (WebCore::SourceSize::length):
329         (WebCore::SourceSizeList::parseSizesAttribute):
330         (WebCore::SourceSizeList::getEffectiveSize):
331         * css/SourceSizeList.h: Added.
332         (WebCore::SourceSize::SourceSize):
333         (WebCore::SourceSizeList::append):
334         * html/HTMLImageElement.cpp: Integrated sizes attribute parsing and added currentSrc.
335         (WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
336         (WebCore::HTMLImageElement::parseAttribute):
337         (WebCore::HTMLImageElement::currentSrc):
338         * html/HTMLImageElement.h:
339         * html/HTMLImageElement.idl:
340         * html/parser/HTMLDocumentParser.cpp: Added information required for sizes parsing to
341         HTMLPreloadScanner calls.
342         (WebCore::HTMLDocumentParser::pumpTokenizer):
343         (WebCore::HTMLDocumentParser::insert):
344         (WebCore::HTMLDocumentParser::append):
345         (WebCore::HTMLDocumentParser::appendCurrentInputStreamToPreloadScannerAndScan):
346         * html/parser/HTMLPreloadScanner.cpp: Integrated sizes attribute parsing.
347         (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
348         (WebCore::TokenPreloadScanner::StartTagScanner::processAttribute):
349         (WebCore::TokenPreloadScanner::scan):
350         (WebCore::HTMLPreloadScanner::scan):
351         * html/parser/HTMLPreloadScanner.h:
352         * html/parser/HTMLSrcsetParser.cpp: Added 'w' descriptor parsing sizes based normalization.
353         (WebCore::parseDescriptors):
354         (WebCore::pickBestImageCandidate):
355         (WebCore::bestFitSourceForImageAttributes):
356         * html/parser/HTMLSrcsetParser.h:
357
358 2014-06-29  Andreas Kling  <akling@apple.com>
359
360         No need to lazily initialize ResourceResponse internals when accessing timing data.
361         <https://webkit.org/b/134437>
362         <rdar://problem/17499876>
363
364         When building with ENABLE(WEB_TIMING), the last thing that would happen when
365         serializing a ResourceResponse in the network process is that we'd retrieve
366         the ResourceLoadTiming to encode it as part of the response. Doing so would
367         trigger the lazy instantiation of ResourceResponse's internal data structures.
368
369         Since timing data is not actually lazily instantiated, we can just not do that.
370
371         This shaves off ~550ms of network process main thread time on PLT, reducing
372         response latency by not doing unnecessary stuff before letting the web process
373         look at the downloaded data.
374
375         Reviewed by Gavin Barraclough.
376
377         * WebCore.exp.in:
378         * platform/network/ResourceResponseBase.cpp:
379         (WebCore::ResourceResponseBase::adopt):
380         (WebCore::ResourceResponseBase::resourceLoadTiming): Deleted.
381         (WebCore::ResourceResponseBase::setResourceLoadTiming): Deleted.
382         * platform/network/ResourceResponseBase.h:
383         (WebCore::ResourceResponseBase::resourceLoadTiming):
384
385 2014-06-29  Pratik Solanki  <pratik.solanki@gmail.com>
386
387         Refactor ResourceRequest into Cocoa and iOS specific files
388         https://bugs.webkit.org/show_bug.cgi?id=134430
389
390         Reviewed by Andreas Kling.
391
392         No new tests because no functional changes.
393
394         * WebCore.xcodeproj/project.pbxproj:
395         * platform/network/cf/ResourceRequestCFNet.cpp:
396         (WebCore::ResourceRequest::applyWebArchiveHackForMail): Deleted.
397         * platform/network/cocoa/ResourceRequestCocoa.mm: Copied from Source/WebCore/platform/network/mac/ResourceRequestMac.mm.
398         (WebCore::ResourceRequest::nsURLRequest):
399         (WebCore::ResourceRequest::cfURLRequest):
400         (WebCore::ResourceRequest::doUpdateResourceRequest):
401         (WebCore::ResourceRequest::doUpdateResourceHTTPBody):
402         (WebCore::ResourceRequest::doUpdatePlatformRequest):
403         (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
404         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties):
405         (WebCore::ResourceRequest::applyWebArchiveHackForMail):
406         (WebCore::ResourceRequest::setStorageSession):
407         * platform/network/ios/ResourceRequestIOS.mm: Added.
408         (WebCore::ResourceRequest::useQuickLookResourceCachingQuirks):
409         (WebCore::ResourceRequest::ResourceRequest):
410         (WebCore::ResourceRequest::updateNSURLRequest):
411         * platform/network/mac/ResourceRequestMac.mm:
412         (WebCore::initQuickLookResourceCachingQuirks):
413         (WebCore::ResourceRequest::useQuickLookResourceCachingQuirks):
414         (WebCore::ResourceRequest::ResourceRequest):
415         (WebCore::ResourceRequest::updateNSURLRequest):
416         (WebCore::ResourceRequest::applyWebArchiveHackForMail):
417         (WebCore::ResourceRequest::nsURLRequest): Deleted.
418         (WebCore::ResourceRequest::cfURLRequest): Deleted.
419         (WebCore::ResourceRequest::doUpdateResourceRequest): Deleted.
420         (WebCore::ResourceRequest::doUpdateResourceHTTPBody): Deleted.
421         (WebCore::ResourceRequest::doUpdatePlatformRequest): Deleted.
422         (WebCore::ResourceRequest::doUpdatePlatformHTTPBody): Deleted.
423         (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Deleted.
424         (WebCore::ResourceRequest::setStorageSession): Deleted.
425
426 2014-06-29  Youenn Fablet  <youenn.fablet@crf.canon.fr>
427
428         TextCodecICU::encode turns the whole string as yen signs if there is any backslash in it
429         https://bugs.webkit.org/show_bug.cgi?id=133678
430
431         Reviewed by Alexey Proskuryakov.
432
433         Test: fast/encoding/backslash-encoding-jp.html
434
435         * platform/text/TextCodecICU.cpp:
436         (WebCore::TextCodecICU::encode): fixed the copy of characters other than backslash.
437
438 2014-06-28  Dean Jackson  <dino@apple.com>
439
440         [iOS] Pinching into a video (fullscreen gesture) leaves page zoomed in
441         https://bugs.webkit.org/show_bug.cgi?id=134433
442         <rdar://problem/16630794>
443
444         Reviewed by Eric Carlson.
445
446         Detect the number of target touches (those directly on the
447         video element) and disable the page zoom if it looks
448         like the user is trying to trigger fullscreen.
449
450         * Modules/mediacontrols/mediaControlsiOS.js:
451         (ControllerIOS.prototype.handleBaseGestureStart): If we are seeing
452         two touches in this video element, don't trigger fullscreen. The
453         exception is if we haven't yet started playback.
454         (ControllerIOS.prototype.handleBaseGestureChange): Don't allow fullscreen
455         if we haven't started playback (iOS 7 behaviour).
456         (ControllerIOS.prototype.handleWrapperTouchStart): Keep track of the
457         number of targetted touches.
458
459 2014-06-27  Simon Fraser  <simon.fraser@apple.com>
460
461         [iOS WK2] position:fixed inside accelerated overflow:scroll is jumpy
462         https://bugs.webkit.org/show_bug.cgi?id=134426
463         <rdar://problem/17474523>
464
465         Reviewed by Tim Horton.
466
467         After committing a new layer tree (with possibly stale position:fixed layer
468         positions), we need the scrolling tree to update those positions based on
469         the current scroll offset.
470         
471         Give ScrollingTreeScrollingNode an implementation of updateLayersAfterAncestorChange()
472         which is required to update fixed/sticky child nodes.
473
474         * WebCore.exp.in:
475         * page/scrolling/ScrollingTreeScrollingNode.cpp:
476         (WebCore::ScrollingTreeScrollingNode::updateLayersAfterAncestorChange):
477         * page/scrolling/ScrollingTreeScrollingNode.h:
478
479 2014-06-28  Juan A. Suarez Romero  <jasuarez@igalia.com>  and  Carlos Garcia Campos  <cgarcia@igalia.com>
480
481         [GTK] Use public getter/setter in GObject DOM bindings properties implementation.
482         https://bugs.webkit.org/show_bug.cgi?id=134390.
483
484         Reviewed by Carlos Garcia Campos.
485
486         The current GObject DOM bindings generator is duplicating code when
487         implementing the get/set_property methods and the public
488         getters/setters, instead of making one invoking the other.
489         
490         This commit changes this behaviour so the code is not duplicated,
491         making it easier to maintain.
492
493         No new tests needed.
494
495         * bindings/scripts/CodeGeneratorGObject.pm:
496         (GenerateProperty):
497         (GenerateProperties):
498         (WriteData):
499         (GetCoreObject): Deleted.
500         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
501         (webkit_dom_test_active_dom_object_get_property):
502         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
503         (webkit_dom_test_event_constructor_get_property):
504         * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
505         (webkit_dom_test_exception_get_property):
506         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
507         (webkit_dom_test_interface_set_property):
508         (webkit_dom_test_interface_get_property):
509         * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.cpp:
510         (webkit_dom_test_nondeterministic_set_property):
511         (webkit_dom_test_nondeterministic_get_property):
512         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
513         (webkit_dom_test_obj_set_property):
514         (webkit_dom_test_obj_get_property):
515         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
516         (webkit_dom_test_serialized_script_value_interface_get_property):
517         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
518         (webkit_dom_test_typedefs_set_property):
519         (webkit_dom_test_typedefs_get_property):
520         * bindings/scripts/test/GObject/WebKitDOMattribute.cpp:
521         (webkit_dom_test_exception_get_property):
522         (webkit_dom_attribute_get_property):
523
524 2014-06-28  Radu Stavila  <stavila@adobe.com>
525
526         [New Multicolumn] Elements with rounded corners and overflow:hidden do not properly clip their content
527         https://bugs.webkit.org/show_bug.cgi?id=133941
528
529         Reviewed by Darin Adler.
530
531         When having a multicol element inside an element with overflow:hidden and border-radius,
532         the fragments representing the columns need to have the border radius set also, to ensure
533         proper clipping.
534
535         Test: fast/multicol/newmulticol/multicol-clip-rounded-corners.html
536
537         * rendering/RenderLayer.cpp:
538         (WebCore::RenderLayer::collectFragments):
539
540 2014-06-27  Zalan Bujtas  <zalan@apple.com>
541
542         Subpixel rendering: Background clipping with subpixel behaves differently when composited.
543         https://bugs.webkit.org/show_bug.cgi?id=134422
544
545         Reviewed by Simon Fraser.
546
547         Adjust cliprect with the subpixel offset from the graphics layer the same way we do it for painting.
548         It ensures that cliprect starts from the right position when graphics layer is not on the same
549         coordinates as the associated render layer.
550
551         Test: compositing/hidpi-compositing-layer-with-subpixel-offset-accumulation-clipping.html
552
553         * rendering/RenderLayer.cpp:
554         (WebCore::RenderLayer::clipToRect):
555         (WebCore::RenderLayer::paintLayer):
556         (WebCore::RenderLayer::applyFilters):
557         (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
558         (WebCore::RenderLayer::paintBackgroundForFragments):
559         (WebCore::RenderLayer::paintForegroundForFragments):
560         (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
561         (WebCore::RenderLayer::paintOutlineForFragments):
562         (WebCore::RenderLayer::paintMaskForFragments):
563         (WebCore::RenderLayer::paintOverflowControlsForFragments):
564         (WebCore::RenderLayer::calculateClipRects):
565         * rendering/RenderLayer.h:
566
567 2014-06-27  Brent Fulgham  <bfulgham@apple.com>
568
569         [Win] Implement parts of the AVFOUNDATION_LOADER_DELEGATE logic for Windows
570         https://bugs.webkit.org/show_bug.cgi?id=134418
571
572         Reviewed by Eric Carlson.
573
574         Land an initial implementation of AVFOUNDATION_LOADER_DELEGATE for
575         Windows.
576
577         * DerivedSources.cpp: Add new IDL files
578         * DerivedSources.make: Add check for AVFOUNDATION_LOADER_DELEGATE.
579         * Modules/encryptedmedia/CDMPrivateMediaPlayer.cpp: Added (ported from
580         Objective C.)
581         * WebCore.vcxproj/WebCore.vcxproj: Update for new files.
582         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
583         * WebCore.vcxproj/WebCoreCommon.props: Add new search paths.
584         * WebCore.vcxproj/WebCoreTestSupport.vcxproj: Update for new files.
585         * WebCore.vcxproj/WebCoreTestSupport.vcxproj.filters: Ditto.
586         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
587         (WebCore::MediaPlayerPrivateAVFoundation::extractKeyURIKeyIDAndCertificateFromInitData):
588         Moved from MediaPlayerPrivateAVFoundationObjC.
589         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
590         * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h:
591         Update for new API calls.
592         * platform/graphics/avfoundation/cf/CDMSessionAVFoundationCF.cpp: Added.
593         * platform/graphics/avfoundation/cf/CDMSessionAVFoundationCF.h: Added.
594         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
595         Updated for new AVFOUNDATION_LOADER_DELEGATE methods.
596         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
597         * platform/graphics/avfoundation/cf/WebCoreAVCFResourceLoader.cpp: Added.
598         * platform/graphics/avfoundation/cf/WebCoreAVCFResourceLoader.h: Added.
599         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
600         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
601         Remove method that was moved to base class.
602
603 2014-06-27  Benjamin Poulain  <benjamin@webkit.org>
604
605         Remove BufferForAppendingHyphen
606         https://bugs.webkit.org/show_bug.cgi?id=134376
607
608         Reviewed by Darin Adler.
609
610         It is legacy, from a time when that code was using a Vector.
611
612         The problem is that StringBuilder's memory was also implicitly used to keep
613         the string alive for the lifespan of the TextRun. That seems quite dangerous
614         as changes in StringBuilder could have changed that.
615
616         To fix the lifetime issue, my first idea was to make it explicit by passing
617         a String reference to hold the memory alive, and a boolean to say if the text
618         need an hyphen. The problem with that is this code is very hot and I made things
619         worse.
620
621         The solution with this patch is to just pass a pointer to a String to do both
622         the buffer reference, and the decision to add the hyphen. Having a single
623         argument with 2 meanings is not pretty but that's not worse than the old buffer.
624
625         * editing/TextIterator.cpp:
626         * rendering/InlineTextBox.cpp:
627         (WebCore::InlineTextBox::localSelectionRect):
628         (WebCore::InlineTextBox::paint):
629         (WebCore::InlineTextBox::paintSelection):
630         (WebCore::InlineTextBox::constructTextRun):
631         (WebCore::adjustCharactersAndLengthForHyphen): Deleted.
632         * rendering/InlineTextBox.h:
633         (WebCore::BufferForAppendingHyphen::BufferForAppendingHyphen): Deleted.
634         * rendering/RenderText.cpp:
635
636 2014-06-27  Jeremy Jones  <jeremyj@apple.com>
637
638         Lazily link frameworks in WebVideoFullscreenInterfaceAVKit.
639         https://bugs.webkit.org/show_bug.cgi?id=134407
640
641         Reviewed by Eric Carlson.
642
643         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
644         (-[WebAVPlayerController init]):
645         Load AVPlayerController on use.
646         (WebVideoFullscreenInterfaceAVKit::WebVideoFullscreenInterfaceAVKit):
647         Remove loading on construction.
648         (WebVideoFullscreenInterfaceAVKit::setCurrentTime): Load AVValueTiming on use.
649         (WebVideoFullscreenInterfaceAVKit::setupFullscreen): Load several classes on use.
650         (WebVideoFullscreenInterfaceAVKit::exitFullscreen): Load UIColor on use.
651
652 2014-06-27  Alex Christensen  <achristensen@webkit.org>
653
654         Remove extra operations from 64-bit or on armv7.
655         https://bugs.webkit.org/show_bug.cgi?id=134408
656
657         Reviewed by Geoffrey Garen.
658
659         * cssjit/SelectorCompiler.cpp:
660         (WebCore::SelectorCompiler::SelectorCodeGenerator::addFlagsToElementStyleFromContext):
661         Only do or operations if it would change values.
662         Often we're only setting one flag, so half the operations are not necessary.
663
664 2014-06-27  Beth Dakin  <bdakin@apple.com>
665
666         ScrollView::rootViewToTotalContents() needs to take topContentInset into account
667         https://bugs.webkit.org/show_bug.cgi?id=134415
668         -and corresponding-
669         <rdar://problem/17473633>
670
671         Reviewed by Simon Fraser.
672
673         This affects hit testing in headers aka PageBanners.
674
675         The root view will be anchored above the start of the total contents if there is a 
676         topContentInset, so the inset value should be subtracted to get into the right 
677         coordinate space here.
678         * platform/ScrollView.cpp:
679         (WebCore::ScrollView::rootViewToTotalContents):
680
681 2014-06-27  Antti Koivisto  <antti@apple.com>
682
683         Flush throttling with remote layers
684         https://bugs.webkit.org/show_bug.cgi?id=134398
685
686         Reviewed by Darin Adler.
687
688         With remote layer trees the flush scheduling lives in the WebKit2 layer. The throttling code
689         needs to live there as well.
690         
691         Add the required callbacks and disable the existing throttling code in RenderLayerCompositor
692         when remote layers are in use. Later we can get rid of the RenderLayerCompositor throttling code.
693
694         * WebCore.xcodeproj/project.pbxproj:
695         * loader/FrameLoader.cpp:
696         (WebCore::FrameLoader::loadProgressingStatusChanged):
697         * page/ChromeClient.h:
698         (WebCore::ChromeClient::adjustLayerFlushThrottling):
699         * page/FrameView.cpp:
700         (WebCore::FrameView::disableLayerFlushThrottlingTemporarilyForInteraction):
701         (WebCore::FrameView::loadProgressingStatusChanged):
702         
703             Factor the progress status change activities to a function.
704
705         (WebCore::FrameView::updateLayerFlushThrottling):
706         (WebCore::FrameView::setExposedRect):
707         
708             Move the call to adjustTiledBackingCoverage from WebKit to here.
709
710         (WebCore::FrameView::updateLayerFlushThrottlingInAllFrames): Deleted.
711         * page/FrameView.h:
712         * page/LayerFlushThrottleState.h: Added.
713         * rendering/RenderLayerCompositor.cpp:
714         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
715
716 2014-06-27  Brady Eidson  <beidson@apple.com>
717
718         The user pressing a button on a gamepad should cause gamepads to become visible to all NavigatorGamepads.
719         https://bugs.webkit.org/show_bug.cgi?id=134375
720
721         Reviewed by Darin Adler.
722
723         No new tests (Not yet a tested config)
724
725         * Modules/gamepad/GamepadManager.cpp:
726         (WebCore::GamepadManager::platformGamepadConnected): Also call to makeGamepadsVisibileToBlindNavigators.
727         (WebCore::GamepadManager::platformGamepadDisconnected):
728         (WebCore::GamepadManager::platformGamepadInputActivity): Call makeGamepadsVisibileToBlindNavigators.
729         (WebCore::GamepadManager::makeGamepadsVisibileToBlindNavigators): Walk through each blind navigator
730           notifying it of each connected Gamepad.
731         (WebCore::GamepadManager::registerNavigator): Also add to the blind navigator set.
732         (WebCore::GamepadManager::unregisterNavigator): Also remove from the blind navigator set.
733         * Modules/gamepad/GamepadManager.h:
734
735         * platform/GamepadProviderClient.h: Added platformGamepadInputActivity.
736
737         * platform/mac/HIDGamepadProvider.cpp:
738         (WebCore::HIDGamepadProvider::HIDGamepadProvider):
739         (WebCore::HIDGamepadProvider::valuesChanged): Set the input notification timer which will notify the clients
740           that a button was pressed.
741         (WebCore::HIDGamepadProvider::inputNotificationTimerFired): Perform that notification.
742         * platform/mac/HIDGamepadProvider.h:
743
744 2014-06-27  Brady Eidson  <beidson@apple.com>
745
746         HIDGamepads should populate themselves with initial input values
747         https://bugs.webkit.org/show_bug.cgi?id=134381
748
749         Reviewed by Darin Adler.
750
751         No new tests (Not yet a tested config)
752
753         * platform/mac/HIDGamepad.cpp:
754         (WebCore::HIDGamepad::getCurrentValueForElement):
755         (WebCore::HIDGamepad::initElements):  Loop through all the saved elements to get current values.
756         (WebCore::HIDGamepad::maybeAddButton):
757         (WebCore::HIDGamepad::maybeAddAxis):
758         * platform/mac/HIDGamepad.h:
759         (WebCore::HIDGamepadElement::HIDGamepadElement):
760         (WebCore::HIDGamepadButton::HIDGamepadButton):
761         (WebCore::HIDGamepadAxis::HIDGamepadAxis):
762
763 2014-06-27  Peyton Randolph  <prandolph@apple.com>
764
765         Add feature flag for link long-press gesture.
766         https://bugs.webkit.org/show_bug.cgi?id=134262
767
768         Reviewed by Enrica Casucci.
769
770         * Configurations/FeatureDefines.xcconfig:
771         Add ENABLE_LINK_LONG_PRESS.
772
773 2014-06-26  Brady Eidson  <beidson@apple.com>
774
775         HIDGamepadProvider should only be active when someone is interested in Gamepads.
776         https://bugs.webkit.org/show_bug.cgi?id=134374
777
778         Reviewed by Darin Adler.
779
780         No new tests (Not yet a tested config)
781
782         * Modules/gamepad/GamepadManager.cpp:
783         (WebCore::GamepadManager::registerNavigator): Add some logging.
784         (WebCore::GamepadManager::unregisterNavigator): Ditto.
785
786         * platform/mac/HIDGamepadProvider.cpp:
787         (WebCore::HIDGamepadProvider::HIDGamepadProvider):
788         (WebCore::HIDGamepadProvider::connectionDelayTimerFired): Stop suppressing connection callbacks
789         (WebCore::HIDGamepadProvider::openAndScheduleManager):
790         (WebCore::HIDGamepadProvider::closeAndUnscheduleManager): Stop listening for gamepad events, and clear
791           all current gamepads.
792         (WebCore::HIDGamepadProvider::startMonitoringGamepads): If the first client, call openAndScheduleManager
793         (WebCore::HIDGamepadProvider::stopMonitoringGamepads): If the last client, call closeAndUnscheduleManager
794         (WebCore::HIDGamepadProvider::deviceAdded): If this callback came while we were suppressing connection
795           callbacks, it is a startup event for already-connected gamepads. Stop suppressing callbacks in a later
796           spin of the runloop.
797         (WebCore::HIDGamepadProvider::deviceRemoved):
798         * platform/mac/HIDGamepadProvider.h:
799         (WebCore::HIDGamepadProvider::setShouldDispatchCallbacks): Deleted.
800
801 2014-06-27  Alex Christensen  <achristensen@webkit.org>
802
803         Prevent unnecessary register saving in css jit.
804         https://bugs.webkit.org/show_bug.cgi?id=133955
805
806         Reviewed by Geoff Garen.
807
808         * cssjit/FunctionCall.h:
809         (WebCore::FunctionCall::prepareAndCall):
810         (WebCore::FunctionCall::cleanupPostCall):
811         (WebCore::FunctionCall::saveAllocatedCallerSavedRegisters):
812         (WebCore::FunctionCall::restoreAllocatedCallerSavedRegisters):
813         (WebCore::FunctionCall::saveAllocatedRegisters): Renamed to saveAllocatedCallerSavedRegisters.
814         (WebCore::FunctionCall::restoreAllocatedRegisters): Renamed to restoreAllocatedCallerSavedRegisters.
815         Only push caller saved registers before function calls.
816         * cssjit/RegisterAllocator.h:
817         (WebCore::RegisterAllocator::isValidRegister):
818         Corrected register ranges.
819         (WebCore::RegisterAllocator::isCallerSavedRegister): Added.
820
821 2014-06-27  Beth Dakin  <bdakin@apple.com>
822
823         Custom scrollbars should not create ScrollbarPainters on Mac
824         https://bugs.webkit.org/show_bug.cgi?id=134406
825         -and corresponding-
826         <rdar://problem/16178301>
827
828         Reviewed by Tim Horton.
829
830         The solution here is to return early in ScrollbarThemeMac::registerScrollbar() if 
831         the scrollbar is custom. However, since this function is called during the 
832         RenderScrollbar and Scrollbar constructor, we need to re-implement 
833         Scrollbar::isCustomScrollbar() to return a member variable that is passed into the 
834         constructor. Otherwise, we will get Scrollbar’s implementation is 
835         isCustomScrollbar() wrongfully returning false since instead of the derived
836         class’s implementation. 
837
838         Scrollbar constructor now has an option parameter isCustomScrollbar that defaults 
839         to false. That value is returned by isCustomScrollbar()
840         * platform/Scrollbar.cpp:
841         (WebCore::Scrollbar::Scrollbar):
842         * platform/Scrollbar.h:
843
844         Return early if this is a custom scrollbar since the rest of the function deals 
845         with creating a native scrollbar and getting it in the right state.
846         * platform/mac/ScrollbarThemeMac.mm:
847         (WebCore::ScrollbarThemeMac::registerScrollbar):
848
849         Send true to the Scrollbar constructor to indicate that this is a custom 
850         scrollbar.
851         * rendering/RenderScrollbar.cpp:
852         (WebCore::RenderScrollbar::RenderScrollbar):
853         * rendering/RenderScrollbar.h:
854
855 2014-06-27  Eric Carlson  <eric.carlson@apple.com>
856
857         [Mac] AVMetadataKeySpaceISOUserData not defined on 10.8
858         https://bugs.webkit.org/show_bug.cgi?id=134401
859
860         Reviewed by Jer Noble.
861
862         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
863         (WebCore::metadataType): Use SOFT_LINK_POINTER_OPTIONAL for AVMetadataKeySpaceISOUserData
864             so we don't have problems on OS versions where it isn't defined.
865
866 2014-06-27  Martin Hodovan  <mhodovan.u-szeged@partner.samsung.com>
867
868         REGRESSION (r168685): css calc() expression fails 
869         https://bugs.webkit.org/show_bug.cgi?id=134059
870
871         The expression 'calc((100% - 20px) / 3' did not work properly after r168685,
872         because primitiveType() function in CSSCalculationValue.cpp has handled
873         CalcPercentLength and CalcPercentNumber categories as if they were angles.
874         The patch fixes this incorrect behavior.
875
876         Reviewed by Simon Fraser.
877
878         Test: fast/css/calc-percentage-pixel.html
879
880         * css/CSSCalculationValue.cpp:
881
882 2014-06-27  Jer Noble  <jer.noble@apple.com>
883
884         [MSE] http/tests/media/media-source/mediasource-append-buffer.html is failing
885         https://bugs.webkit.org/show_bug.cgi?id=134389
886
887         Reviewed by Eric Carlson.
888
889         Two subtests in mediasource-append-buffer.html are failing. Bring setDuration() up to spec
890         by throwing an exception if the duration is called while any SourceBuffer is updating. Do
891         not cancel pending events when a SourceBuffer is removed from its MediaSource. And mark the
892         SourceBuffer as having pending activity if there are pending events to be fired.
893
894         * Modules/mediasource/MediaSource.cpp:
895         (WebCore::MediaSource::setDuration):
896         * Modules/mediasource/SourceBuffer.cpp:
897         (WebCore::SourceBuffer::removedFromMediaSource):
898         (WebCore::SourceBuffer::hasPendingActivity):
899
900 2014-06-26  Simon Fraser  <simon.fraser@apple.com>
901
902         [iOS WK2] Fix touch-scrollable elements with overflow:scroll on just one axis, and RTL scrolling
903         https://bugs.webkit.org/show_bug.cgi?id=134377
904         <rdar://problem/16762224>
905
906         Reviewed by Tim Horton.
907         
908         Make -webkit-overflow-scrolling:touch scrolling work correctly when one axis
909         has overflow:scroll and the other overflow:hidden. Also fix scrolling in RTL
910         contexts.
911         
912         An RTL scroller with overflow-x:hidden will have a non-zero scroll origin,
913         and needs to truncate the scrolled content on the left side. To pass the
914         correct geometry to the UI process, we need to introduce the concept of
915         "reachable" size as well as total content size; normally these are the same,
916         but will differ when scrolling is only allowed on one axis but there is overflow
917         on both axes.
918         
919         To get the reachable size, add RenderLayer::scrollableContentsSize().
920         
921         RenderLayer::visibleSize() was wrong; the function should return the size of the 
922         scrollable portion, but used layer size which includes borders. Fix to use pixelSnappedClientWidth()/Height(),
923         which is what we use for scrollbar computations.
924
925         * WebCore.exp.in:
926         * page/scrolling/AsyncScrollingCoordinator.cpp:
927         (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
928         (WebCore::AsyncScrollingCoordinator::updateFrameScrollingNode):
929         (WebCore::AsyncScrollingCoordinator::updateOverflowScrollingNode):
930         * page/scrolling/ScrollingCoordinator.h:
931         * page/scrolling/ScrollingStateScrollingNode.cpp:
932         (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
933         (WebCore::ScrollingStateScrollingNode::setReachableContentsSize):
934         * page/scrolling/ScrollingStateScrollingNode.h:
935         (WebCore::ScrollingStateScrollingNode::reachableContentsSize):
936         * page/scrolling/ScrollingTreeScrollingNode.cpp:
937         (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
938         * page/scrolling/ScrollingTreeScrollingNode.h:
939         (WebCore::ScrollingTreeScrollingNode::reachableContentsSize):
940         * rendering/RenderLayer.cpp:
941         (WebCore::RenderLayer::visibleSize):
942         (WebCore::RenderLayer::scrollableContentsSize):
943         * rendering/RenderLayer.h:
944         * rendering/RenderLayerCompositor.cpp:
945         (WebCore::updateScrollingLayerWithClient):
946         (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
947
948 2014-06-27  Bear Travis  <betravis@adobe.com>
949
950         [Feature Queries] Fix feature queries build on Mac
951         https://bugs.webkit.org/show_bug.cgi?id=134359
952
953         Reviewed by Antti Koivisto.
954
955         Update the XCode project and Feature Queries code to build on Mac.
956
957         There are existing tests for supports in the LayoutTests/css3 directory.
958
959         * WebCore.xcodeproj/project.pbxproj: Add the Feature Queries files
960         to the XCode project.
961         * css/CSSGrammar.y.in: Update CSSParserExpression to CSSParserValueList.
962         * css/DOMWindowCSS.idl: Add ImplementationLacksVTable metadata.
963
964 2014-06-27  Jer Noble  <jer.noble@apple.com>
965
966         [MSE] media/media-source/media-source-tracks.html is crashy
967         https://bugs.webkit.org/show_bug.cgi?id=134385
968
969         Reviewed by Eric Carlson.
970
971         Fix the refactoring error (self assignment) introduced by r170488.
972
973         * Modules/mediasource/SourceBuffer.cpp:
974         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):
975
976 2014-06-27  Mark Hahnenberg  <mhahnenberg@apple.com>
977
978         XHR should keep attributes on instance
979         https://bugs.webkit.org/show_bug.cgi?id=134363
980
981         Reviewed by Sam Weinig.
982
983         Test: js/dom/xhr-prototype-define-property.html
984
985         Having them on the prototype broke some sites due to the fact that these DOM attributes are currently 
986         not configurable. Once we make them configurable, we can move XHR attributes back to the prototype.
987
988         * bindings/scripts/CodeGeneratorJS.pm:
989         (InterfaceRequiresAttributesOnInstanceForCompatibility):
990
991 2014-06-27  Jeremy Jones  <jeremyj@apple.com>
992
993         removeCodedFrames should modify ref to TrackBuffer no a copy.
994         https://bugs.webkit.org/show_bug.cgi?id=134380
995
996         Reviewed by Daniel Bates.
997
998         * Modules/mediasource/SourceBuffer.cpp:
999         (WebCore::SourceBuffer::removeCodedFrames):
1000         Iterate with a reference.
1001
1002 2014-06-27  Zalan Bujtas  <zalan@apple.com>
1003
1004         Set cliprect radius unconditionally in RenderLayer.
1005         https://bugs.webkit.org/show_bug.cgi?id=134396
1006
1007         Reviewed by Simon Fraser.
1008
1009         No change in functionality.
1010
1011         * rendering/RenderLayer.cpp:
1012         (WebCore::RenderLayer::calculateClipRects):
1013
1014 2014-06-27  Manuel Rego Casasnovas  <rego@igalia.com>
1015
1016         [CSS Grid Layout] Interaction between auto-placement and column / row spanning
1017         https://bugs.webkit.org/show_bug.cgi?id=110633
1018
1019         Reviewed by Sergio Villar Senin.
1020
1021         Modify auto-placement algorithm in order to support span in both
1022         definite and automatic positions.
1023
1024         This patch fixes examples like:
1025         grid-row: auto;
1026         grid-column: 2 / span 3;
1027
1028         And also:
1029         grid-row: auto;
1030         grid-column: span 3;
1031
1032         Tests: fast/css-grid-layout/grid-item-auto-placement-automatic-span.html
1033                fast/css-grid-layout/grid-item-auto-placement-definite-span.html
1034
1035         * rendering/RenderGrid.cpp:
1036         (WebCore::RenderGrid::GridIterator::isEmptyAreaEnough): New method that
1037         checks if a grid area is or not empty.
1038         (WebCore::RenderGrid::GridIterator::nextEmptyGridArea): Updated method
1039         that now receives two arguments with the span value in both directions.
1040         (WebCore::RenderGrid::ensureGridSize): Renamed from gridRow(). Adapted
1041         method to grow in both directions at the same time if needed. It ensures
1042         that the grid is big enough to insert a new item.
1043         (WebCore::RenderGrid::insertItemIntoGrid): Only leave the method that
1044         receives a GridCoordinate. It uses ensureGridSize() before inserting the
1045         item in the grid.
1046         (WebCore::RenderGrid::populateExplicitGridAndOrderIterator): Ensure that
1047         the grid is big enough to place the largest span for auto-positioned
1048         items.
1049         (WebCore::RenderGrid::createEmptyGridAreaAtSpecifiedPositionsOutsideGrid):
1050         New method that returns a GridCoordinate outside current grid with the
1051         requested dimensions.
1052         (WebCore::RenderGrid::placeSpecifiedMajorAxisItemsOnGrid): Adapted
1053         method to calculate the item's span and use the new version of
1054         nextEmptyGridArea(). If an empty area is not found it uses
1055         createEmptyGridAreaAtSpecifiedPositionsOutsideGrid() to place the item.
1056         (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid): Ditto.
1057         (WebCore::RenderGrid::growGrid): Renamed to ensureGridSize().
1058         * rendering/RenderGrid.h: Modify methods headers and add new method
1059         signature.
1060         * rendering/style/GridCoordinate.h:
1061         (WebCore::GridSpan::integerSpan): Add new simple method to return the
1062         span value of a position.
1063         * rendering/style/GridResolvedPosition.cpp:
1064         (WebCore::GridResolvedPosition::resolveGridPositionsFromAutoPlacementPosition):
1065         Implement method to take into account span in auto-placement algorithm.
1066         (WebCore::GridResolvedPosition::adjustGridPositionsFromStyle): Add new
1067         checks related with named grid line spans in auto-positioned items,
1068         which is not allowed according to the spec.
1069         * rendering/style/GridResolvedPosition.h: Update method header.
1070
1071 2014-06-27  Mahesh Kulkarni  <mahesh.kk@samsung.com>
1072
1073         [XHR] open method must uppercase only standard method types
1074         https://bugs.webkit.org/show_bug.cgi?id=134264
1075
1076         Reviewed by Darin Adler.
1077
1078         As per step-5 of http://xhr.spec.whatwg.org/#the-open()-method only
1079         DELETE, PUT, GET, POST, OPTIONS, HEAD are standard. Use other methods as is without case change.
1080         All tests from w3c-test suite pass http://w3c-test.org/XMLHttpRequest/open-method-case-sensitive.htm.
1081         This merges blink changes from r176592.
1082
1083         Tests: http/tests/xmlhttprequest/xmlhttprequest-open-method-allowed.html
1084                http/tests/xmlhttprequest/xmlhttprequest-open-method-case-insensitive.html
1085
1086         * xml/XMLHttpRequest.cpp:
1087         (WebCore::XMLHttpRequest::uppercaseKnownHTTPMethod):
1088
1089 2014-06-27  Andre Moreira Magalhaes   <andre.magalhaes@collabora.co.uk>
1090
1091         Increase priority on SharedTimer source.
1092         http://bugs.webkit.org/show_bug.cgi?id=134109
1093
1094         While running webkit on a Debian virtual machine I stumbled upon an issue where JS
1095         setTimeout callbacks were not being properly invoked due to machine limitations and the
1096         usage of a low priority on setTimeout timers.
1097
1098         This patch increases the SharedTimer source priority to use the default glib priority which
1099         fixes the issue, making setTimeout JS calls work properly on the test environment.
1100
1101         Reviewed by Gustavo Noronha Silva.
1102
1103         * platform/gtk/SharedTimerGtk.cpp:
1104         (WebCore::setSharedTimerFireInterval):
1105
1106 2014-06-27  Zalan Bujtas  <zalan@apple.com>
1107
1108         Remove redundant offsetFromAncestor() call from RenderLayer::localClipRect().
1109         https://bugs.webkit.org/show_bug.cgi?id=134378
1110
1111         Reviewed by Simon Fraser.
1112
1113         No change in functionality.
1114
1115         * rendering/RenderLayer.cpp:
1116         (WebCore::RenderLayer::calculateClipRects):
1117
1118 2014-06-27  Philippe Normand  <pnormand@igalia.com>
1119
1120         [GTK] 8tracks.com triggers annoying pop-up window/installation of "About protocol source plugin" (GStreamer?)
1121         https://bugs.webkit.org/show_bug.cgi?id=133605
1122
1123         Reviewed by Carlos Garcia Campos.
1124
1125         Don't attempt to load blank URLs with the GStreamer media
1126         player. Those URLs trigger the codec installer which is useless in
1127         this scenario. This patch also renames some of the variables of
1128         the ::load method, as suggested by Carlos.
1129
1130         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1131         (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
1132         Check video-sink validity before disconnecting its signal handlers.
1133         (WebCore::MediaPlayerPrivateGStreamer::load): Don't load blank
1134         URLs (about:blank).
1135         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
1136         (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
1137         Disconnect repaint handler only if it's valid.
1138
1139 2014-06-26  Carlos Garcia Campos  <cgarcia@igalia.com>
1140
1141         [GTK] Expose getter and setter functions for attributes named type
1142         https://bugs.webkit.org/show_bug.cgi?id=134300
1143
1144         Reviewed by Martin Robinson.
1145
1146         We skip those because the getter conflicts with the get_type()
1147         function of all GObjects. We should use a different name for them. As
1148         a general rule we use the last word of the class name, something like:
1149
1150           webkit_dom_blob_get_type() -> webkit_dom_blob_get_blob_type()
1151           webkit_dom_event_get_type() -> webkit_dom_event_get_event_type()
1152
1153         It's consistent with other existing DOM methods like
1154         webkit_dom_xpath_result_get_result_type() or webkit_dom_css_value_get_css_value_type().
1155         This patch also adds some exceptions for particular cases.
1156
1157         * bindings/gobject/webkitdom.symbols: Add new public symbols.
1158         * bindings/scripts/CodeGeneratorGObject.pm:
1159         (GetFunctionSigName): Helper function to return the function name
1160         that takes into account all exceptions when generating getters and
1161         setters of attributes named type. Otherwise the name is returned unmodified.
1162         (GenerateFunction): Use GetFunctionSigName().
1163         (GenerateFunctions): Do not skip functions for type attributes.
1164
1165 2014-06-27  Sungmann Cho  <sungmann.cho@navercorp.com>
1166
1167         Remove unnecessary #include in HistoryController
1168         https://bugs.webkit.org/show_bug.cgi?id=134369
1169
1170         Reviewed by Daniel Bates.
1171
1172         After the landing of https://webkit.org/b/130099, HistoryController doesn't need
1173         WebCore::Settings class. So we can remove the related header.
1174
1175         * loader/HistoryController.cpp:
1176
1177 2014-06-26  Jeongeun Kim  <je_julie.kim@samsung.com>
1178
1179         REGRESSION (r170287): SVGDocumentExtensions::rebuildElements() called on removed element
1180         https://bugs.webkit.org/show_bug.cgi?id=134304
1181
1182         Reviewed by Daniel Bates.
1183
1184         Roll out <http://trac.webkit.org/170287> (https://bugs.webkit.org/show_bug.cgi?id=134186)
1185         as it led to SVGDocumentExtensions::rebuildElements() being called on an element(s) that
1186         may no longer be in the document.
1187
1188         * dom/ContainerNode.cpp:
1189         (WebCore::ContainerNode::removeChild):
1190         (WebCore::ContainerNode::removeChildren):
1191         * dom/Document.cpp:
1192         (WebCore::Document::commonTeardown):
1193         (WebCore::Document::implicitClose):
1194         * history/CachedFrame.cpp:
1195         (WebCore::CachedFrameBase::restore):
1196         * svg/SVGDocumentExtensions.cpp:
1197         (WebCore::SVGDocumentExtensions::startAnimations):
1198         (WebCore::SVGDocumentExtensions::pauseAnimations):
1199         (WebCore::SVGDocumentExtensions::unpauseAnimations):
1200         (WebCore::SVGDocumentExtensions::dispatchSVGLoadEventToOutermostSVGElements):
1201         (WebCore::SVGDocumentExtensions::rebuildElements):
1202         * svg/SVGDocumentExtensions.h:
1203
1204 2014-06-26  Tim Horton  <timothy_horton@apple.com>
1205
1206         [WK2] Pinch-zoom shadows can overlap headers and footers
1207         https://bugs.webkit.org/show_bug.cgi?id=134372
1208         <rdar://problem/16004095>
1209
1210         Reviewed by Simon Fraser.
1211
1212         * WebCore.exp.in:
1213         * rendering/RenderLayerCompositor.cpp:
1214         (WebCore::RenderLayerCompositor::updateLayerForHeader):
1215         (WebCore::RenderLayerCompositor::updateLayerForFooter):
1216         Put header/footer layers in front of the root content layer instead of behind.
1217         Ideally nothing would ever overlap them, but this will give them precedence regardless.
1218
1219 2014-06-26  David Kilzer  <ddkilzer@apple.com>
1220
1221         [Win] Always NULL-terminate the string in createUTF8String()
1222         <http://webkit.org/b/134353>
1223         <rdar://problem/17471783>
1224
1225         Reviewed by Brent Fulgham.
1226
1227         * plugins/PluginView.cpp:
1228         (WebCore::createUTF8String): Pull out CString length into local
1229         variable.  Switch to use memcpy.  Always NULL-terminate the
1230         string.
1231
1232 2014-06-26  Jer Noble  <jer.noble@apple.com>
1233
1234         [MSE][Mac] Crash in WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered const + 13
1235         https://bugs.webkit.org/show_bug.cgi?id=134367
1236
1237         Reviewed by Darin Adler.
1238
1239         Add a couple of null-checks to protect against methods being called in the brief time
1240         between when the object is created and when it's asked to load.
1241
1242         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1243         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::durationDouble):
1244         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered):
1245
1246 2014-06-26  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1247
1248         Rearrange conditions to find invalid protocol in NavigatorContentUtils::verifyProtocolHandlerScheme()
1249         https://bugs.webkit.org/show_bug.cgi?id=134289
1250
1251         Reviewed by Darin Adler.
1252
1253         If we do early return when there is invalid protocol, we're able to avoid unnecessary call flow.
1254
1255         No new tests, covered by existing tests.
1256
1257         * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
1258         (WebCore::verifyProtocolHandlerScheme):
1259
1260 2014-06-26  Benjamin Poulain  <bpoulain@apple.com>
1261
1262         [WK1] Use native touch event's timestamp for DOM touch event
1263         https://bugs.webkit.org/show_bug.cgi?id=134326
1264
1265         Reviewed by Enrica Casucci.
1266
1267         * platform/ios/PlatformEventFactoryIOS.mm:
1268         (WebCore::PlatformTouchEventBuilder::PlatformTouchEventBuilder):
1269         Use device event timestamp to get more accurate timing information. This also removes
1270         the variance introduced by WebKit when computing velocity/acceleration/etc.
1271
1272 2014-06-26  Balazs Kelemen  <b.kelemen@samsung.com>
1273
1274         Memcache migth not be pruned when it should for https pages
1275         https://bugs.webkit.org/show_bug.cgi?id=134361
1276
1277         Reviewed by Geoffrey Garen.
1278
1279         There is no reason we should not try to prune in case of a https resource.
1280
1281         No observable change in behavior, no tests.
1282
1283         * loader/cache/CachedResource.cpp:
1284         (WebCore::CachedResource::removeClient):
1285         Call prune unconditionally and remove an unnecessary branch.
1286
1287 2014-06-26  Alexey Proskuryakov  <ap@apple.com>
1288
1289         REGRESSION: Mountain Lion: Gmail's "in new window" view of mail threads is very slow to load its content
1290         https://bugs.webkit.org/show_bug.cgi?id=133882
1291         <rdar://problem/17271965>
1292
1293         Reviewed by Brady Eidson.
1294
1295         This goes to pre-r161796 behavior on 10.8 and 10.9. We schedule the requests internally,
1296         and only give 6 of them to CFNetwork at a time. Except for synchronous requests,
1297         which still use the improved approach, and don't count against 6 connections.
1298
1299         * loader/ResourceLoadScheduler.cpp:
1300         (WebCore::ResourceLoadScheduler::scheduleLoad):
1301         * platform/network/cf/ResourceRequest.h:
1302         (WebCore::ResourceRequest::resourcePrioritiesEnabled):
1303         * platform/network/cf/ResourceRequestCFNet.cpp:
1304         (WebCore::ResourceRequest::doUpdatePlatformRequest):
1305         (WebCore::ResourceRequest::doUpdateResourceRequest):
1306         (WebCore::initializeMaximumHTTPConnectionCountPerHost): Deleted.
1307         * platform/network/mac/ResourceRequestMac.mm:
1308         (WebCore::ResourceRequest::doUpdateResourceRequest):
1309         (WebCore::ResourceRequest::doUpdatePlatformRequest):
1310
1311 2014-06-26  Brady Eidson  <beidson@apple.com>
1312
1313         Remove use of PlatformStrategies for Gamepad API.
1314         https://bugs.webkit.org/show_bug.cgi?id=134348
1315
1316         Reviewed by Dean Jackson.
1317
1318         No new tests (Not yet a tested config)
1319
1320         Introduce a virtual GamepadProvider with a process-global shared provider.
1321         The base implementation of the GamepadProvider does nothing.
1322         * platform/GamepadProvider.cpp: Renamed from Source/WebKit/mac/WebCoreSupport/WebHIDGamepadController.h.
1323         (WebCore::GamepadProvider::shared):
1324         (WebCore::GamepadProvider::setSharedProvider):
1325         (WebCore::GamepadProvider::startMonitoringGamepads):
1326         (WebCore::GamepadProvider::stopMonitoringGamepads):
1327         (WebCore::GamepadProvider::platformGamepads):
1328         * platform/GamepadProvider.h: Renamed from Source/WebCore/platform/GamepadStrategy.h.
1329         (WebCore::GamepadProvider::~GamepadProvider):
1330
1331         * platform/GamepadProviderClient.h: Renamed from Source/WebCore/platform/GamepadStrategyClient.h.
1332         (WebCore::GamepadProviderClient::~GamepadProviderClient):
1333
1334         GamepadManager is now a GamepadProviderClient:
1335         * Modules/gamepad/GamepadManager.cpp:
1336         (WebCore::GamepadManager::GamepadManager):
1337         (WebCore::GamepadManager::registerNavigator):
1338         (WebCore::GamepadManager::unregisterNavigator):
1339         * Modules/gamepad/GamepadManager.h:
1340
1341         Remove the GamepadStrategy altogether:
1342         * platform/PlatformStrategies.h:
1343         (WebCore::PlatformStrategies::PlatformStrategies):
1344         (WebCore::PlatformStrategies::gamepadStrategy): Deleted.
1345
1346         Call to the shared GamepadProvider instead of the strategy:
1347         * Modules/gamepad/NavigatorGamepad.cpp:
1348         (WebCore::NavigatorGamepad::gamepads):
1349         (WebCore::NavigatorGamepad::gamepadsBecameVisible):
1350         (WebCore::NavigatorGamepad::gamepadConnected):
1351
1352         HIDGamepadListener is now a subclass of GamepadProvider that implements the HID based management.
1353         LegacyWebKit on Mac will install the shared HIDGamepadProvider instead of the default GamepadProvider:
1354         * platform/mac/HIDGamepadProvider.cpp: Renamed from Source/WebCore/platform/mac/HIDGamepadListener.cpp.
1355         (WebCore::deviceMatchingDictionary):
1356         (WebCore::deviceAddedCallback):
1357         (WebCore::deviceRemovedCallback):
1358         (WebCore::deviceValuesChangedCallback):
1359         (WebCore::HIDGamepadProvider::shared):
1360         (WebCore::HIDGamepadProvider::HIDGamepadProvider):
1361         (WebCore::HIDGamepadProvider::indexForNewlyConnectedDevice):
1362         (WebCore::HIDGamepadProvider::startMonitoringGamepads):
1363         (WebCore::HIDGamepadProvider::stopMonitoringGamepads):
1364         (WebCore::HIDGamepadProvider::deviceAdded):
1365         (WebCore::HIDGamepadProvider::deviceRemoved):
1366         (WebCore::HIDGamepadProvider::valuesChanged):
1367         (WebCore::HIDGamepadProvider::removeGamepadForDevice):
1368         * platform/mac/HIDGamepadProvider.h: Renamed from Source/WebCore/platform/mac/HIDGamepadListener.h.
1369         (WebCore::HIDGamepadProvider::platformGamepads):
1370         (WebCore::HIDGamepadProvider::setShouldDispatchCallbacks):
1371
1372         * WebCore.exp.in:
1373         * WebCore.xcodeproj/project.pbxproj:
1374
1375         * platform/mac/HIDGamepad.h: Fix incorrect comment
1376
1377 2014-06-26  Andreas Kling  <akling@apple.com>
1378
1379         Skip memcmp()ing fully downloaded resources after they become mmap()able.
1380         <https://webkit.org/b/134362>
1381
1382         When we receive word that a downloaded resource is now available for mmap()ing
1383         from the file system, we don't need to compare against the buffered data,
1384         since even if there were a mismatch, the cached version should be the canonical one.
1385
1386         This was added as belt-and-suspenders while the supporting mechanism was being
1387         developed in CFNetwork, and there's no evidence of a race today. This change
1388         turns the runtime checks into debug-only assertions.
1389
1390         Saves ~300ms of main thread time on PLT.
1391
1392         Reviewed by Geoff Garen.
1393
1394         * loader/cache/CachedResource.cpp:
1395         (WebCore::CachedResource::tryReplaceEncodedData):
1396
1397 2014-06-26  Jer Noble  <jer.noble@apple.com>
1398
1399         [MSE] Refactoring: Use C++11 for-loops in SourceBuffer.
1400         https://bugs.webkit.org/show_bug.cgi?id=134352
1401
1402         Reviewed by Darin Adler.
1403
1404         Use C++11 style for-loops where appropriate in SourceBuffer now that the
1405         SampleMap ordered objects support them.
1406
1407         * Modules/mediasource/SourceBuffer.cpp:
1408         (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime):
1409         (WebCore::SourceBuffer::sourceBufferPrivateFastSeekTimeForMediaTime):
1410         (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete):
1411         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):
1412         (WebCore::SourceBuffer::validateInitializationSegment):
1413         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
1414
1415 2014-06-25  Joseph Pecoraro  <pecoraro@apple.com>
1416  
1417         [iOS]: Tapping <button> outside of a form is no longer working
1418         https://bugs.webkit.org/show_bug.cgi?id=134319
1419         <rdar://problem/17213346>
1420
1421         Reviewed by Daniel Bates.
1422
1423         Restore behavior of allowing <button> clicks outside of <form>.
1424         This used to be iOS behavior before it was removed in favor of the
1425         OpenSource (Android?) behavior. Now, willRespondToMouseClickEvents
1426         is only used by iOS, so lets restore the iOS behavior.
1427
1428         * html/HTMLButtonElement.cpp:
1429         (WebCore::HTMLButtonElement::willRespondToMouseClickEvents):
1430
1431 2014-06-26  Jer Noble  <jer.noble@apple.com>
1432
1433         Unreviewed build-fix. Remove unintentionial rename of MediaTime.h -> MediaTimeHash.h.
1434
1435         * Modules/mediasource/SampleMap.h:
1436
1437 2014-06-26  Eric Carlson  <eric.carlson@apple.com>
1438
1439         [iOS] no need to deactivate audio session
1440         https://bugs.webkit.org/show_bug.cgi?id=134350
1441
1442         Reviewed by Jer Noble.
1443
1444         * platform/audio/mac/MediaSessionManagerMac.cpp:
1445         (MediaSessionManager::updateSessionState): Don't bother calling 
1446             AudioSession::setActive(false), WebCore's audio session will be deactivated 
1447             automatically if another application begins playing audio.
1448
1449 2014-06-26  Jer Noble  <jer.noble@apple.com>
1450
1451         [MSE] Refactoring: Differentiate between SampleMap decode and presentation order methods
1452         https://bugs.webkit.org/show_bug.cgi?id=134349
1453
1454         Reviewed by Geoffrey Garen.
1455
1456         Refactor SampleMap to clarify the distinction between methods which return decode-order
1457         iterators and ones which retun presentation-order iterators.
1458
1459         Add two classes, PresentationOrderSampleMap and DecodeOrderSampleMap, to contain the actual
1460         MediaTime-to-Sample maps, and move the methods returning presentation-order and decode-order
1461         iterators to each, respectively.  Rename the {presentation,decode}{Begin,End}() methods to
1462         begin() and end() so the objects can be used in C++11 for-loops.
1463
1464         Update all the call sites in SourceBuffer to use the new ordered objects.
1465
1466         * Modules/mediasource/SampleMap.cpp:
1467         (WebCore::SampleIsLessThanMediaTimeComparator::operator()): Use new ordered objects.
1468         (WebCore::SampleIsGreaterThanMediaTimeComparator::operator()): Ditto.
1469         (WebCore::SampleMap::clear): Ditto.
1470         (WebCore::SampleMap::addSample): Ditto.
1471         (WebCore::SampleMap::removeSample): Ditto.
1472         (WebCore::PresentationOrderSampleMap::findSampleContainingPresentationTime): Renamed from SampleMap version.
1473         (WebCore::PresentationOrderSampleMap::findSampleAfterPresentationTime): Ditto.
1474         (WebCore::DecodeOrderSampleMap::findSampleWithDecodeTime): Ditto.
1475         (WebCore::PresentationOrderSampleMap::reverseFindSampleContainingPresentationTime): Ditto.
1476         (WebCore::PresentationOrderSampleMap::reverseFindSampleBeforePresentationTime): Ditto.
1477         (WebCore::DecodeOrderSampleMap::reverseFindSampleWithDecodeTime): Ditto.
1478         (WebCore::DecodeOrderSampleMap::findSyncSamplePriorToPresentationTime): Ditto.
1479         (WebCore::DecodeOrderSampleMap::findSyncSamplePriorToDecodeIterator): Ditto.
1480         (WebCore::DecodeOrderSampleMap::findSyncSampleAfterPresentationTime): Ditto.
1481         (WebCore::DecodeOrderSampleMap::findSyncSampleAfterDecodeIterator): Ditto.
1482         (WebCore::PresentationOrderSampleMap::findSamplesBetweenPresentationTimes): Ditto.
1483         (WebCore::PresentationOrderSampleMap::findSamplesWithinPresentationRange): Ditto.
1484         (WebCore::DecodeOrderSampleMap::findDependentSamples): Ditto.
1485         * Modules/mediasource/SampleMap.h:
1486         (WebCore::PresentationOrderSampleMap::begin): Renamed from presentationBegin().
1487         (WebCore::PresentationOrderSampleMap::end): Renamed from presentationEnd().
1488         (WebCore::PresentationOrderSampleMap::rbegin): Renamed from reversePresentationBegin().
1489         (WebCore::PresentationOrderSampleMap::rend): Renamed from reversePresentationEnd().
1490         (WebCore::DecodeOrderSampleMap::begin): Renamed from decodeBegin().
1491         (WebCore::DecodeOrderSampleMap::end): Renamed from decodeEnd().
1492         (WebCore::DecodeOrderSampleMap::rbegin): Renamed from reverseDecodeBegin().
1493         (WebCore::DecodeOrderSampleMap::rend): Renamed from reverseDecodeEnd().
1494         (WebCore::SampleMap::SampleMap): Create new ordered objects.
1495         (WebCore::SampleMap::sizeInBytes): Use new ordered objects.
1496         (WebCore::SampleMap::decodeOrder): Simple accessor.
1497         (WebCore::SampleMap::presentationOrder): Simple accessor.
1498         * Modules/mediasource/SourceBuffer.cpp:
1499         (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime): Use new ordered objects.
1500         (WebCore::SourceBuffer::sourceBufferPrivateFastSeekTimeForMediaTime): Ditto.
1501         (WebCore::SourceBuffer::removeCodedFrames): Ditto.
1502         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto.
1503         (WebCore::SourceBuffer::bufferedSamplesForTrackID): Ditto.
1504
1505 2014-06-26  Chris Fleizach  <cfleizach@apple.com>
1506
1507         Add an undo group for each dictated utterance in WebKit
1508         https://bugs.webkit.org/show_bug.cgi?id=134086
1509
1510         Applied review comments from Sam Weinig.
1511
1512         Move the associated USE #define into Platform.h.
1513  
1514         * WebCore.xcodeproj/project.pbxproj:
1515         * editing/mac/TextUndoInsertionMarkup.h: Removed.
1516         * editing/mac/TextUndoInsertionMarkupMac.h:
1517
1518 2014-06-26  Shivakumar JM  <shiva.jm@samsung.com>
1519
1520         [EFL][WK2] Fix Debug Build Error in Webcore module.
1521         https://bugs.webkit.org/show_bug.cgi?id=134345
1522
1523         Reviewed by Zalan Bujtas.
1524
1525         Use static cast to change the type of variable to fix error
1526
1527         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
1528         (WebCore::HarfBuzzShaper::setDrawRange):
1529
1530 2014-06-26  Eric Carlson  <eric.carlson@apple.com>
1531
1532         [Mac] allow host application to canonicalize media urls
1533         https://bugs.webkit.org/show_bug.cgi?id=134329
1534
1535         Reviewed by Dean Jackson.
1536
1537         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1538         (WebCore::canonicalURL): New, use NSURLProtocol to canonicalize a URL.
1539         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Call canonicalURL.
1540
1541 2014-06-26  Carlos Garcia Campos  <cgarcia@igalia.com>
1542
1543         [GTK] Add padding for future expansion to WebKitDOMEventTargetIface
1544         https://bugs.webkit.org/show_bug.cgi?id=134298
1545
1546         Reviewed by Martin Robinson.
1547
1548         * bindings/gobject/WebKitDOMEventTarget.h:
1549
1550 2014-06-25  Carlos Garcia Campos  <cgarcia@igalia.com>
1551
1552         [GTK] Add support for constants in GObject DOM bindings
1553         https://bugs.webkit.org/show_bug.cgi?id=133983
1554
1555         Reviewed by Martin Robinson.
1556
1557         * bindings/gobject/webkitdom.symbols: Add stable constants.
1558         * bindings/scripts/CodeGeneratorGObject.pm:
1559         (GenerateHeader): Add constants to the header.
1560         (Generate): Pass the interface object to GenerateHeader to get the constants
1561         (IsInterfaceSymbol): Helper function that returns whether the given
1562         symbol belongs to the interface. Check also constants now.
1563         (ReadStableSymbols): Use IsInterfaceSymbol().
1564         * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
1565         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
1566
1567 2014-06-26  Manuel Rego Casasnovas  <rego@igalia.com>
1568
1569         [CSS Grid Layout] Properly support for z-index on grid items
1570         https://bugs.webkit.org/show_bug.cgi?id=103329
1571
1572         Reviewed by Benjamin Poulain.
1573
1574         From Blink r157620 by <jchaffraix@chromium.org> and r172402 by
1575         <wangxianzhu@chromium.org>.
1576
1577         The specification says that grid should match flexbox and force
1578         grid items to be stacking context if z-index is set, regardless
1579         of 'position'. After this change, this is what happens.
1580
1581         Previously z-index changes of static positioned objects were ignored.
1582         However, z-index is applicable for some static positioned objects,
1583         such as grid items. Ignoring them makes the object not to be properly
1584         painted on z-index change.
1585
1586         As StyleResolver has ensured that z-index is non-auto only if
1587         applicable, RenderStyle::changeRequiresLayerRepaint() should not check
1588         again (with inconsistent conditions).
1589
1590         Tests: fast/css-grid-layout/grid-item-z-index-change-repaint.html
1591                fast/css-grid-layout/grid-item-z-index-stacking-context.html
1592                fast/css-grid-layout/grid-item-z-index-support.html
1593
1594         * css/StyleResolver.cpp:
1595         (WebCore::isDisplayFlexibleOrGridBox): Add new method to check if parent
1596         display is flexbox or grid.
1597         (WebCore::StyleResolver::adjustRenderStyle): Use new method in z-index
1598         condition.
1599         * rendering/style/RenderStyle.cpp:
1600         (WebCore::RenderStyle::changeRequiresLayerRepaint): Move z-index checks
1601         out of non-static positioned objects if.
1602
1603 2014-06-25  Dean Jackson  <dino@apple.com>
1604
1605         HIDGamepad should use CFIndex when looping
1606         https://bugs.webkit.org/show_bug.cgi?id=134337
1607
1608         Reviewed by Dan Bernstein.
1609
1610         * platform/mac/HIDGamepad.cpp:
1611         (WebCore::HIDGamepad::initElementsFromArray): Replace int with CFIndex, and use
1612         a local variable for CFArrayCount.
1613
1614 2014-06-25  Ryosuke Niwa  <rniwa@webkit.org>
1615
1616         Build fix attempt after r170465.
1617
1618         * platform/mac/HIDGamepad.cpp:
1619         (WebCore::HIDGamepad::initElementsFromArray):
1620
1621 2014-06-25  Dean Jackson  <dino@apple.com>
1622
1623         [Mac] Radio buttons and checkboxes vanish when redrawn
1624         https://bugs.webkit.org/show_bug.cgi?id=134335
1625
1626         Reviewed by Dan Bernstein.
1627
1628         I screwed up when landing r170343 by moving some code around
1629         which broke the logic. We need to query the animation
1630         state for controls after we draw (both statically and animated).
1631
1632         * platform/mac/ThemeMac.mm:
1633         (WebCore::paintToggleButton): We need to check the state of animation again, after
1634         we draw.
1635
1636 2014-06-25  Brady Eidson  <beidson@apple.com>
1637
1638         Add HID-based gamepad implementation for Mac
1639         https://bugs.webkit.org/show_bug.cgi?id=134324
1640
1641         Reviewed by Dean Jackson.
1642
1643         No new tests (Not yet a tested config)
1644
1645         * Modules/gamepad/Gamepad.cpp:
1646         (WebCore::Gamepad::Gamepad):
1647         (WebCore::Gamepad::updateFromPlatformGamepad): Update the Gamepad’s data from the passed-in PlatformGamepad.
1648         * Modules/gamepad/Gamepad.h:
1649
1650         * Modules/gamepad/GamepadButton.h:
1651         (WebCore::GamepadButton::create): Change to use Ref instead of RefPtr.
1652
1653         GamepadManager is a GamepadStrategyClient that receives notifications from the platform gamepad implementation
1654         and forwards them to NavigatorGamepad objects. In the future it will also handle event dispatch and exposing
1655         gamepads to the API layer when a button is pressed:
1656         * Modules/gamepad/GamepadManager.cpp: Added.
1657         (WebCore::GamepadManager::shared):
1658         (WebCore::GamepadManager::GamepadManager):
1659         (WebCore::GamepadManager::platformGamepadConnected):
1660         (WebCore::GamepadManager::platformGamepadDisconnected):
1661         (WebCore::GamepadManager::registerNavigator):
1662         (WebCore::GamepadManager::unregisterNavigator):
1663         * Modules/gamepad/GamepadManager.h:
1664
1665         The NavigatorGamepad supplement actually manages visibility of Gamepads on a per-DOMWindow basis:
1666         * Modules/gamepad/NavigatorGamepad.cpp:
1667         (WebCore::NavigatorGamepad::NavigatorGamepad):
1668         (WebCore::NavigatorGamepad::~NavigatorGamepad):
1669         (WebCore::NavigatorGamepad::from):
1670         (WebCore::NavigatorGamepad::gamepads):
1671         (WebCore::NavigatorGamepad::gamepadsBecameVisible):
1672         (WebCore::NavigatorGamepad::gamepadConnected):
1673         (WebCore::NavigatorGamepad::gamepadDisconnected):
1674         * Modules/gamepad/NavigatorGamepad.h:
1675         (WebCore::NavigatorGamepad::navigationStart):
1676
1677         HIDGamepad is a PlatformGamepad that wraps an IOHIDDeviceRef and keeps input values updated:
1678         * platform/mac/HIDGamepad.cpp: Added.
1679         (WebCore::HIDGamepad::HIDGamepad):
1680         (WebCore::HIDGamepad::initElements):
1681         (WebCore::HIDGamepad::initElementsFromArray):
1682         (WebCore::HIDGamepad::maybeAddButton):
1683         (WebCore::HIDGamepad::maybeAddAxis):
1684         (WebCore::HIDGamepad::valueChanged):
1685         * platform/mac/HIDGamepad.h: Added.
1686         (WebCore::HIDGamepadElement::HIDGamepadElement):
1687         (WebCore::HIDGamepadElement::~HIDGamepadElement):
1688         (WebCore::HIDGamepadElement::isButton):
1689         (WebCore::HIDGamepadElement::isAxis):
1690         (WebCore::HIDGamepadButton::HIDGamepadButton):
1691         (WebCore::HIDGamepadAxis::HIDGamepadAxis):
1692         (WebCore::HIDGamepad::hidDevice):
1693
1694         HIDGamepadListener wraps an IOHIDManagerRef and continuously listens for changes to Gamepad-type
1695         devices plugged in to the system:
1696         * platform/mac/HIDGamepadListener.cpp: Added.
1697         (WebCore::deviceMatchingDictionary):
1698         (WebCore::deviceAddedCallback):
1699         (WebCore::deviceRemovedCallback):
1700         (WebCore::deviceValuesChangedCallback):
1701         (WebCore::HIDGamepadListener::shared):
1702         (WebCore::HIDGamepadListener::HIDGamepadListener):
1703         (WebCore::HIDGamepadListener::indexForNewlyConnectedDevice):
1704         (WebCore::HIDGamepadListener::deviceAdded):
1705         (WebCore::HIDGamepadListener::deviceRemoved):
1706         (WebCore::HIDGamepadListener::valuesChanged):
1707         (WebCore::HIDGamepadListener::removeGamepadForDevice):
1708         * platform/mac/HIDGamepadListener.h: Copied from Source/WebCore/Modules/gamepad/NavigatorGamepad.cpp.
1709         (WebCore::HIDGamepadListenerClient::~HIDGamepadListenerClient):
1710         (WebCore::HIDGamepadListener::setClient):
1711         (WebCore::HIDGamepadListener::platformGamepads):
1712         (WebCore::HIDGamepadListener::setShouldDispatchCallbacks):
1713
1714         * WebCore.exp.in:
1715         * WebCore.xcodeproj/project.pbxproj:
1716
1717 2014-06-25  Ryosuke Niwa  <rniwa@webkit.org>
1718
1719         WebProgressTracker updates progress too frequently
1720         https://bugs.webkit.org/show_bug.cgi?id=134185
1721
1722         Reviewed by Tim Horton.
1723
1724         The old code throttled the progress update to when either 100ms has passed or the delta is at least 2%
1725         but this was still not enough in pages that loaded in sub-seconds. The new code always throttles it at 200ms.
1726
1727         * loader/ProgressTracker.cpp:
1728         (WebCore::ProgressTracker::ProgressTracker):
1729         (WebCore::ProgressTracker::incrementProgress):
1730         * loader/ProgressTracker.h:
1731
1732 2014-06-25  Simon Fraser  <simon.fraser@apple.com>
1733
1734         [iOS WK2] Fixed position elements jump around when zooming
1735         https://bugs.webkit.org/show_bug.cgi?id=134328
1736         <rdar://problem/17447048>
1737
1738         Reviewed by Zalan Bujtas.
1739
1740         If a given remote layer tree commit contains changes of layers for viewport-constrained
1741         objects, then the associated scrolling tree also needs to show that the layers changed,
1742         since we need to re-run the "viewport changed" logic in the UI process to get the
1743         layers correctly positioned for the current zoom level.
1744         
1745         The bug was that page scale changes resulted in small "pixel alignment" position
1746         changes which touched layers, but we didn't commit any scrolling tree changes. So
1747         the scrolling tree commit would result in visibly stale layer positions, with no scrolling tree
1748         update to adjust them for the current transient zoom.
1749
1750         Fix by making use of the existing "alignment offset" field in the ViewportConstraints
1751         data, and having RemoteScrollingCoordinatorProxy::connectStateNodeLayers() note that
1752         fixed or sticky layers changed if any properties of fixed or sticky scrolling tree
1753         nodes were updated.
1754
1755         * page/scrolling/ScrollingConstraints.h:
1756         (WebCore::StickyPositionViewportConstraints::operator==):
1757         * platform/graphics/GraphicsLayer.h:
1758         (WebCore::GraphicsLayer::pixelAlignmentOffset):
1759         * platform/graphics/ca/GraphicsLayerCA.cpp:
1760         (WebCore::GraphicsLayerCA::updateGeometry):
1761         * platform/graphics/ca/GraphicsLayerCA.h:
1762         * rendering/RenderLayerCompositor.cpp:
1763         (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
1764         (WebCore::RenderLayerCompositor::computeStickyViewportConstraints):
1765
1766 2014-06-25  Simon Fraser  <simon.fraser@apple.com>
1767
1768         [iOS WK2] Tweak the logic used to choose the scale at which position:fixed gets pushed out of view
1769         https://bugs.webkit.org/show_bug.cgi?id=134323
1770
1771         Reviewed by Benjamin Poulain.
1772
1773         Previously we used a fixed scale (1.2x) at which we'd start pushing position:fixed elements
1774         out of the viewport. This worked well on iPad, but terribly on iPhone. Instead, choose a scale
1775         relative to how much of the page is visible width-wise, the threshold being 2/3 of the page width.
1776         The width is clamped to get reasonable behavior on wide pages.
1777
1778         * page/FrameView.cpp:
1779         (WebCore::FrameView::rectForViewportConstrainedObjects):
1780
1781 2014-06-25  Brady Eidson  <beidson@apple.com>
1782
1783         Add new platform gamepad abstractions
1784         https://bugs.webkit.org/show_bug.cgi?id=134325
1785
1786         Reviewed by Dean Jackson.
1787
1788         No new tests (Not yet a tested config)
1789
1790         - GamepadStrategy lets ports customize the 3 basic behaviors needed for a gamepad
1791           implementation to feed the API in WebCore.
1792         - GamepadStrategyClient gives arbitrary objects in WebCore the ability to register
1793           for callbacks with the GamepadStrategy.
1794         - PlatformGamepad is a platform-agnostic object that represents the data that
1795           feeds into the Gamepad object that is exposed to web content.
1796
1797         The code in this patch is dead as-is, but https://bugs.webkit.org/show_bug.cgi?id=134324
1798         will contain an immediate follow-up patch that uses it.
1799
1800         Makes sense to review them separately.
1801
1802         * WebCore.xcodeproj/project.pbxproj:
1803
1804         * platform/GamepadStrategy.h: Added.
1805         (WebCore::GamepadStrategy::~GamepadStrategy):
1806
1807         * platform/GamepadStrategyClient.h: Added.
1808         (WebCore::GamepadStrategyClient::~GamepadStrategyClient):
1809
1810         * platform/PlatformGamepad.h: Added.
1811         (WebCore::PlatformGamepad::~PlatformGamepad):
1812         (WebCore::PlatformGamepad::id):
1813         (WebCore::PlatformGamepad::lastUpdateTime):
1814         (WebCore::PlatformGamepad::connectTime):
1815         (WebCore::PlatformGamepad::PlatformGamepad):
1816
1817         * platform/PlatformStrategies.h:
1818         (WebCore::PlatformStrategies::gamepadStrategy):
1819         (WebCore::PlatformStrategies::PlatformStrategies):
1820
1821 2014-06-25  Zalan Bujtas  <zalan@apple.com>
1822
1823         Assertion failed: CGPathAddRoundedRect asserts on non-renderable rounded rectangle.
1824         https://bugs.webkit.org/show_bug.cgi?id=134288
1825
1826         Reviewed by Simon Fraser.
1827
1828         Speculative fix. This changeset attempts to address a possible mantissa overflow of radius
1829         when checking whether the rounded rectangle is renderable.
1830         We convert both the radius and the rectangle values to CGFloat(float/double) to perform
1831         this renderable check, instead of always using float.
1832
1833         * platform/graphics/FloatRoundedRect.cpp:
1834         (WebCore::FloatRoundedRect::Radii::scale): Move scale(float, float) from RoundedRect to FloatRoundedRect.
1835         (WebCore::FloatRoundedRect::isRenderable): Add check if radius is >= 0.
1836         * platform/graphics/FloatRoundedRect.h:
1837         * platform/graphics/RoundedRect.cpp:
1838         (WebCore::RoundedRect::Radii::scale):
1839         (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting): use FloatRoundeRect::Radii.
1840         * platform/graphics/RoundedRect.h:
1841         * platform/graphics/cg/PathCG.cpp:
1842         (WebCore::Path::platformAddPathForRoundedRect): use epsilon() to ensure width/height is always >= even with mantissa overflow. 
1843
1844 2014-06-25  Jer Noble  <jer.noble@apple.com>
1845
1846         [MSE] removeCodedFrames() can remove more than it should
1847         https://bugs.webkit.org/show_bug.cgi?id=134320
1848
1849         Reviewed by Geoff Garen.
1850
1851         removeCodedFrames() can remove more samples than it should because it compares an iterator
1852         in presentation timespace to one in decode timespace. Clean up this code by removing frames
1853         in decode order. Rename variables and add comments to make explicit which timespace defines
1854         the iterators being used.
1855
1856         * Modules/mediasource/SourceBuffer.cpp:
1857         (WebCore::SourceBuffer::removeCodedFrames):
1858
1859 2014-06-25  Beth Dakin  <bdakin@apple.com>
1860
1861         Crash in ScrollingTree::isRubberBandInProgress()
1862         https://bugs.webkit.org/show_bug.cgi?id=134316
1863         -and corresponding-
1864         <rdar://problem/16247911>
1865
1866         Reviewed by Geoffrey Garen.
1867
1868         This crash appears to have been caused by http://trac.webkit.org/changeset/161276 
1869         which moved the ScrollingNode creation code from ScrollingTree over to 
1870         ScrollingCoordinator. This creates a thread safety issue. In the crashing case, we 
1871         believe that the ScrollingCoordinator's ScrollingTree pointer had been null-ed out
1872         even though the ScrollingTree was kept alive by the bind call to propagate 
1873         commitNewTreeState() over to the scrolling thread. The fix is to move node 
1874         creation back to the ScrollingTree and to use the this pointer to create new
1875         nodes rather than the ScrollingCoordinator's ScrollingTree pointer.
1876
1877         Don't allow ScrollingCoordinator to handle ScrollingTreeNode creation.
1878         * page/scrolling/AsyncScrollingCoordinator.h:
1879
1880         Re-name createNode to createScrollingTreeNode(). 
1881         * page/scrolling/ScrollingTree.cpp:
1882         (WebCore::ScrollingTree::updateTreeFromStateNode):
1883         * page/scrolling/ScrollingTree.h:
1884
1885         Remove this implementation of createNode that called into the 
1886         ScrollingCoordinator.
1887         * page/scrolling/ThreadedScrollingTree.cpp:
1888         (WebCore::ThreadedScrollingTree::createNode): Deleted.
1889         * page/scrolling/ThreadedScrollingTree.h:
1890
1891         Don't allow ScrollingCoordinator to handle ScrollingTreeNode creation.
1892         * page/scrolling/ios/ScrollingCoordinatorIOS.h:
1893         * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
1894         (WebCore::ScrollingCoordinatorIOS::createScrollingTreeNode): Deleted.
1895
1896         Re-name createNode to createScrollingTreeNode, and actually create the nodes here.
1897         * page/scrolling/ios/ScrollingTreeIOS.cpp:
1898         (WebCore::ScrollingTreeIOS::createScrollingTreeNode):
1899         (WebCore::ScrollingTreeIOS::createNode): Deleted.
1900         * page/scrolling/ios/ScrollingTreeIOS.h:
1901
1902         Don't allow ScrollingCoordinator to handle ScrollingTreeNode creation.
1903         * page/scrolling/mac/ScrollingCoordinatorMac.h:
1904         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
1905         (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode): Deleted.
1906
1907         Add the implementation of createScrollingTreeNode() for the Mac to 
1908         ScrollingTreeMac since it can create Mac-specific nodes.
1909         * page/scrolling/mac/ScrollingTreeMac.cpp:
1910         (ScrollingTreeMac::createScrollingTreeNode):
1911         * page/scrolling/mac/ScrollingTreeMac.h:
1912
1913 2014-06-25  Enrica Casucci  <enrica@apple.com>
1914
1915         iOS build fix after http://trac.webkit.org/changeset/170447.
1916         Unreviewed.
1917
1918         * editing/mac/TextUndoInsertionMarkup.h:
1919
1920 2014-06-25  Chris Fleizach  <cfleizach@apple.com>
1921
1922         Add an undo group for each dictated utterance in WebKit
1923         https://bugs.webkit.org/show_bug.cgi?id=134086
1924
1925         Reviewed by Enrica Casucci.
1926
1927         Provide a mechanism for ending the current undo group on a text insertion.
1928         This allows a stream of text, that is normally part of one undo group, to be
1929         broken up so that subsequent undo commands will only undo portions of the text stream.
1930
1931         * WebCore.exp.in:
1932         * WebCore.xcodeproj/project.pbxproj:
1933         * editing/mac/TextUndoInsertionMarkup.h: Added.
1934         * editing/mac/TextUndoInsertionMarkup.mm: Added.
1935         (WebCore::shouldRegisterInsertionUndoGroup):
1936         (WebCore::registerInsertionUndoGrouping):
1937
1938 2014-06-25  Joseph Pecoraro  <pecoraro@apple.com>
1939
1940         [iOS]: WK2 Inspector Node Search
1941         https://bugs.webkit.org/show_bug.cgi?id=134279
1942
1943         Reviewed by Benjamin Poulain.
1944
1945         * WebCore.exp.in:
1946         Export Node::inspect for WebKit2.
1947
1948 2014-06-25  Dana Burkart  <dburkart@apple.com>
1949
1950         Add support for 5-tuple versioning.
1951
1952         Reviewed by David Farler.
1953
1954         * Configurations/Version.xcconfig:
1955
1956 2014-06-25  Jer Noble  <jer.noble@apple.com>
1957
1958         [MSE][Mac] REGRESSION(r170336) - zero tolerance seeks are ignored.
1959         https://bugs.webkit.org/show_bug.cgi?id=134310
1960
1961         Reviewed by Brent Fulgham.
1962
1963         Tests for zero tolerance seeks were inadvertantly reversed in r170336.
1964
1965         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1966         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
1967
1968 2014-06-25  Jer Noble  <jer.noble@apple.com>
1969
1970         [MSE][Mac] Pause playback when readyState drops below HAVE_FUTURE_DATA, and do not complete seek until it rises above HAVE_METADATA.
1971         https://bugs.webkit.org/show_bug.cgi?id=134306
1972
1973         Reviewed by Eric Carlson.
1974
1975         Pause the synchronizer before seeking, and do not resume the synchronizer until it both reports that the seek completed,
1976         and that the readyState rises above HAVE_METADATA. In every other location where we change the rate of the synchronizer,
1977         gate that rate change on the above.
1978
1979         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
1980         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1981         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC): Check shouldBePlaying().
1982         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::playInternal): Ditto.
1983         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekWithTolerance): Unset m_seekCompleted.
1984         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal): Pause the synchronizer.
1985         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setRateDouble): Check shouldBePlaying().
1986         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::shouldBePlaying): Test m_seeking, !m_seekCompleted, and the readyState.
1987         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setReadyState): Set m_seekCompleted; check shouldBePlaying() and play if appropriate.
1988
1989 2014-06-25  Jer Noble  <jer.noble@apple.com>
1990
1991         [MSE] Update monitorSourceBuffers to match recent spec changes
1992         https://bugs.webkit.org/show_bug.cgi?id=134305
1993
1994         Reviewed by Eric Carlson.
1995
1996         In W3C bug #24347, the text for the third clause of Source Buffer Monitoring was updated. Update our
1997         implementation to match the new text.
1998
1999         * Modules/mediasource/MediaSource.cpp:
2000         (WebCore::MediaSource::monitorSourceBuffers):
2001
2002 2014-06-25  Alex Christensen  <achristensen@webkit.org>
2003             And peavo@outlook.com  <peavo@outlook.com>
2004
2005         Use references instead of pointers in RenderTheme.
2006         https://bugs.webkit.org/show_bug.cgi?id=134261
2007
2008         Reviewed by Zalan Bujtas.
2009
2010         * css/StyleResolver.cpp:
2011         (WebCore::StyleResolver::adjustRenderStyle):
2012         * html/TextFieldInputType.cpp:
2013         (WebCore::TextFieldInputType::shouldHaveSpinButton):
2014         * html/shadow/SliderThumbElement.cpp:
2015         (WebCore::RenderSliderThumb::updateAppearance):
2016         * platform/efl/RenderThemeEfl.cpp:
2017         (WebCore::RenderThemeEfl::adjustSizeConstraints):
2018         (WebCore::RenderThemeEfl::applyEdjeRTLState):
2019         (WebCore::RenderThemeEfl::isControlStyled):
2020         (WebCore::RenderThemeEfl::paintThemePart):
2021         (WebCore::RenderThemeEfl::supportsFocusRing):
2022         (WebCore::RenderThemeEfl::adjustSliderTrackStyle):
2023         (WebCore::RenderThemeEfl::adjustSliderThumbStyle):
2024         (WebCore::RenderThemeEfl::adjustSliderThumbSize):
2025         (WebCore::RenderThemeEfl::adjustCheckboxStyle):
2026         (WebCore::RenderThemeEfl::adjustRadioStyle):
2027         (WebCore::RenderThemeEfl::adjustButtonStyle):
2028         (WebCore::RenderThemeEfl::adjustMenuListStyle):
2029         (WebCore::RenderThemeEfl::adjustMenuListButtonStyle):
2030         (WebCore::RenderThemeEfl::adjustTextFieldStyle):
2031         (WebCore::RenderThemeEfl::adjustTextAreaStyle):
2032         (WebCore::RenderThemeEfl::adjustSearchFieldResultsButtonStyle):
2033         (WebCore::RenderThemeEfl::adjustSearchFieldResultsDecorationPartStyle):
2034         (WebCore::RenderThemeEfl::adjustSearchFieldCancelButtonStyle):
2035         (WebCore::RenderThemeEfl::adjustSearchFieldStyle):
2036         (WebCore::RenderThemeEfl::adjustInnerSpinButtonStyle):
2037         (WebCore::RenderThemeEfl::adjustProgressBarStyle):
2038         (WebCore::RenderThemeEfl::animationRepeatIntervalForProgressBar):
2039         (WebCore::RenderThemeEfl::animationDurationForProgressBar):
2040         * platform/efl/RenderThemeEfl.h:
2041         * platform/gtk/RenderThemeGtk.cpp:
2042         (WebCore::RenderThemeGtk::supportsFocusRing):
2043         (WebCore::RenderThemeGtk::adjustButtonStyle):
2044         (WebCore::RenderThemeGtk::adjustMenuListStyle):
2045         (WebCore::RenderThemeGtk::adjustMenuListButtonStyle):
2046         (WebCore::RenderThemeGtk::adjustSearchFieldResultsButtonStyle):
2047         (WebCore::adjustSearchFieldIconStyle):
2048         (WebCore::RenderThemeGtk::adjustSearchFieldResultsDecorationPartStyle):
2049         (WebCore::RenderThemeGtk::adjustSearchFieldCancelButtonStyle):
2050         (WebCore::RenderThemeGtk::adjustSearchFieldStyle):
2051         (WebCore::RenderThemeGtk::adjustSliderTrackStyle):
2052         (WebCore::RenderThemeGtk::adjustSliderThumbStyle):
2053         (WebCore::borderRadiiFromStyle):
2054         (WebCore::RenderThemeGtk::paintMediaSliderTrack):
2055         (WebCore::RenderThemeGtk::paintMediaSliderThumb):
2056         (WebCore::RenderThemeGtk::paintMediaVolumeSliderTrack):
2057         (WebCore::RenderThemeGtk::adjustProgressBarStyle):
2058         (WebCore::RenderThemeGtk::animationRepeatIntervalForProgressBar):
2059         (WebCore::RenderThemeGtk::animationDurationForProgressBar):
2060         (WebCore::RenderThemeGtk::calculateProgressRect):
2061         * platform/gtk/RenderThemeGtk.h:
2062         * platform/gtk/RenderThemeGtk2.cpp:
2063         (WebCore::setToggleSize):
2064         (WebCore::RenderThemeGtk::setCheckboxSize):
2065         (WebCore::RenderThemeGtk::setRadioSize):
2066         (WebCore::RenderThemeGtk::comboBoxArrowSize):
2067         (WebCore::RenderThemeGtk::getComboBoxPadding):
2068         (WebCore::RenderThemeGtk::popupInternalPaddingLeft):
2069         (WebCore::RenderThemeGtk::popupInternalPaddingRight):
2070         (WebCore::RenderThemeGtk::popupInternalPaddingTop):
2071         (WebCore::RenderThemeGtk::popupInternalPaddingBottom):
2072         (WebCore::RenderThemeGtk::paintMenuList):
2073         (WebCore::RenderThemeGtk::adjustSliderThumbSize):
2074         (WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
2075         * platform/gtk/RenderThemeGtk3.cpp:
2076         (WebCore::setToggleSize):
2077         (WebCore::RenderThemeGtk::setCheckboxSize):
2078         (WebCore::RenderThemeGtk::setRadioSize):
2079         (WebCore::getComboBoxMetrics):
2080         (WebCore::RenderThemeGtk::popupInternalPaddingLeft):
2081         (WebCore::RenderThemeGtk::popupInternalPaddingRight):
2082         (WebCore::RenderThemeGtk::popupInternalPaddingTop):
2083         (WebCore::RenderThemeGtk::popupInternalPaddingBottom):
2084         (WebCore::RenderThemeGtk::adjustSliderThumbSize):
2085         (WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
2086         * rendering/RenderButton.cpp:
2087         (WebCore::RenderButton::layout):
2088         * rendering/RenderInline.cpp:
2089         (WebCore::RenderInline::paintOutline):
2090         * rendering/RenderMediaControls.cpp:
2091         (WebCore::RenderMediaControls::adjustMediaSliderThumbSize):
2092         * rendering/RenderMediaControls.h:
2093         * rendering/RenderMenuList.cpp:
2094         (WebCore::RenderMenuList::adjustInnerStyle):
2095         (RenderMenuList::computeIntrinsicLogicalWidths):
2096         (RenderMenuList::menuStyle):
2097         * rendering/RenderMeter.cpp:
2098         (WebCore::RenderMeter::updateLogicalWidth):
2099         (WebCore::RenderMeter::computeLogicalHeight):
2100         * rendering/RenderObject.cpp:
2101         (WebCore::RenderObject::paintOutline):
2102         * rendering/RenderProgress.cpp:
2103         (WebCore::RenderProgress::updateAnimationState):
2104         * rendering/RenderTextControlSingleLine.cpp:
2105         (WebCore::RenderTextControlSingleLine::layout):
2106         * rendering/RenderTheme.cpp:
2107         (WebCore::RenderTheme::adjustStyle):
2108         (WebCore::RenderTheme::isControlStyled):
2109         (WebCore::RenderTheme::supportsFocusRing):
2110         (WebCore::RenderTheme::stateChanged):
2111         (WebCore::RenderTheme::adjustCheckboxStyle):
2112         (WebCore::RenderTheme::adjustRadioStyle):
2113         (WebCore::RenderTheme::adjustButtonStyle):
2114         (WebCore::RenderTheme::adjustInnerSpinButtonStyle):
2115         (WebCore::RenderTheme::adjustTextFieldStyle):
2116         (WebCore::RenderTheme::adjustTextAreaStyle):
2117         (WebCore::RenderTheme::adjustMenuListStyle):
2118         (WebCore::RenderTheme::adjustInputFieldSpeechButtonStyle):
2119         (WebCore::RenderTheme::adjustMeterStyle):
2120         (WebCore::RenderTheme::meterSizeForBounds):
2121         (WebCore::RenderTheme::animationRepeatIntervalForProgressBar):
2122         (WebCore::RenderTheme::animationDurationForProgressBar):
2123         (WebCore::RenderTheme::adjustProgressBarStyle):
2124         (WebCore::RenderTheme::shouldHaveSpinButton):
2125         (WebCore::RenderTheme::adjustMediaControlStyle):
2126         (WebCore::RenderTheme::adjustSliderTrackStyle):
2127         (WebCore::RenderTheme::adjustSliderThumbStyle):
2128         (WebCore::RenderTheme::adjustSliderThumbSize):
2129         (WebCore::RenderTheme::adjustSearchFieldStyle):
2130         (WebCore::RenderTheme::adjustSearchFieldCancelButtonStyle):
2131         (WebCore::RenderTheme::adjustSearchFieldDecorationPartStyle):
2132         (WebCore::RenderTheme::adjustSearchFieldResultsDecorationPartStyle):
2133         (WebCore::RenderTheme::adjustSearchFieldResultsButtonStyle):
2134         * rendering/RenderTheme.h:
2135         (WebCore::RenderTheme::supportsHover):
2136         (WebCore::RenderTheme::minimumMenuListSize):
2137         (WebCore::RenderTheme::popupInternalPaddingLeft):
2138         (WebCore::RenderTheme::popupInternalPaddingRight):
2139         (WebCore::RenderTheme::popupInternalPaddingTop):
2140         (WebCore::RenderTheme::popupInternalPaddingBottom):
2141         (WebCore::RenderTheme::popupMenuSize):
2142         (WebCore::RenderTheme::setCheckboxSize):
2143         (WebCore::RenderTheme::setRadioSize):
2144         (WebCore::RenderTheme::setButtonSize):
2145         * rendering/RenderThemeIOS.h:
2146         * rendering/RenderThemeIOS.mm:
2147         (WebCore::RenderThemeIOS::adjustCheckboxStyle):
2148         (WebCore::RenderThemeIOS::isControlStyled):
2149         (WebCore::RenderThemeIOS::adjustRadioStyle):
2150         (WebCore::RenderThemeIOS::popupInternalPaddingRight):
2151         (WebCore::RenderThemeIOS::adjustRoundBorderRadius):
2152         (WebCore::RenderThemeIOS::adjustMenuListButtonStyle):
2153         (WebCore::RenderThemeIOS::adjustSliderTrackStyle):
2154         (WebCore::RenderThemeIOS::adjustSliderThumbSize):
2155         (WebCore::RenderThemeIOS::animationRepeatIntervalForProgressBar):
2156         (WebCore::RenderThemeIOS::animationDurationForProgressBar):
2157         (WebCore::RenderThemeIOS::adjustSearchFieldStyle):
2158         (WebCore::RenderThemeIOS::adjustButtonStyle):
2159         (WebCore::RenderThemeIOS::setButtonSize):
2160         (WebCore::RenderThemeIOS::shouldHaveSpinButton):
2161         * rendering/RenderThemeMac.h:
2162         * rendering/RenderThemeMac.mm:
2163         (WebCore::RenderThemeMac::isControlStyled):
2164         (WebCore::RenderThemeMac::controlSizeForFont):
2165         (WebCore::RenderThemeMac::sizeForFont):
2166         (WebCore::RenderThemeMac::sizeForSystemFont):
2167         (WebCore::RenderThemeMac::setSizeFromFont):
2168         (WebCore::RenderThemeMac::setFontFromControlSize):
2169         (WebCore::RenderThemeMac::controlSizeForSystemFont):
2170         (WebCore::RenderThemeMac::adjustTextFieldStyle):
2171         (WebCore::RenderThemeMac::adjustTextAreaStyle):
2172         (WebCore::RenderThemeMac::paintMenuList):
2173         (WebCore::RenderThemeMac::meterSizeForBounds):
2174         (WebCore::RenderThemeMac::paintMeter):
2175         (WebCore::RenderThemeMac::levelIndicatorFor):
2176         (WebCore::RenderThemeMac::progressBarRectForBounds):
2177         (WebCore::RenderThemeMac::minimumProgressBarHeight):
2178         (WebCore::RenderThemeMac::animationRepeatIntervalForProgressBar):
2179         (WebCore::RenderThemeMac::animationDurationForProgressBar):
2180         (WebCore::RenderThemeMac::adjustProgressBarStyle):
2181         (WebCore::RenderThemeMac::paintProgressBar):
2182         (WebCore::RenderThemeMac::adjustMenuListStyle):
2183         (WebCore::RenderThemeMac::popupInternalPaddingLeft):
2184         (WebCore::RenderThemeMac::popupInternalPaddingRight):
2185         (WebCore::RenderThemeMac::popupInternalPaddingTop):
2186         (WebCore::RenderThemeMac::popupInternalPaddingBottom):
2187         (WebCore::RenderThemeMac::popupMenuSize):
2188         (WebCore::RenderThemeMac::minimumMenuListSize):
2189         (WebCore::RenderThemeMac::adjustSliderTrackStyle):
2190         (WebCore::RenderThemeMac::adjustSliderThumbStyle):
2191         (WebCore::RenderThemeMac::setSearchCellState):
2192         (WebCore::RenderThemeMac::setSearchFieldSize):
2193         (WebCore::RenderThemeMac::adjustSearchFieldStyle):
2194         (WebCore::RenderThemeMac::adjustSearchFieldCancelButtonStyle):
2195         (WebCore::RenderThemeMac::adjustSearchFieldDecorationPartStyle):
2196         (WebCore::RenderThemeMac::adjustSearchFieldResultsDecorationPartStyle):
2197         (WebCore::RenderThemeMac::adjustSearchFieldResultsButtonStyle):
2198         (WebCore::RenderThemeMac::adjustSliderThumbSize):
2199         * rendering/RenderThemeSafari.cpp:
2200         (WebCore::RenderThemeSafari::isControlStyled):
2201         (WebCore::RenderThemeSafari::adjustRepaintRect):
2202         (WebCore::RenderThemeSafari::baselinePosition):
2203         (WebCore::RenderThemeSafari::controlSizeForFont):
2204         (WebCore::RenderThemeSafari::sizeForFont):
2205         (WebCore::RenderThemeSafari::sizeForSystemFont):
2206         (WebCore::RenderThemeSafari::setSizeFromFont):
2207         (WebCore::RenderThemeSafari::setFontFromControlSize):
2208         (WebCore::RenderThemeSafari::controlSizeForSystemFont):
2209         (WebCore::RenderThemeSafari::paintCheckbox):
2210         (WebCore::RenderThemeSafari::setCheckboxSize):
2211         (WebCore::RenderThemeSafari::paintRadio):
2212         (WebCore::RenderThemeSafari::setRadioSize):
2213         (WebCore::RenderThemeSafari::setButtonPaddingFromControlSize):
2214         (WebCore::RenderThemeSafari::adjustButtonStyle):
2215         (WebCore::RenderThemeSafari::setButtonSize):
2216         (WebCore::RenderThemeSafari::adjustTextFieldStyle):
2217         (WebCore::RenderThemeSafari::adjustTextAreaStyle):
2218         (WebCore::RenderThemeSafari::paintMenuList):
2219         (WebCore::RenderThemeSafari::adjustMenuListStyle):
2220         (WebCore::RenderThemeSafari::popupInternalPaddingLeft):
2221         (WebCore::RenderThemeSafari::popupInternalPaddingRight):
2222         (WebCore::RenderThemeSafari::popupInternalPaddingTop):
2223         (WebCore::RenderThemeSafari::popupInternalPaddingBottom):
2224         (WebCore::RenderThemeSafari::adjustMenuListButtonStyle):
2225         (WebCore::RenderThemeSafari::minimumMenuListSize):
2226         (WebCore::RenderThemeSafari::adjustSliderThumbStyle):
2227         (WebCore::RenderThemeSafari::adjustSliderThumbSize):
2228         (WebCore::RenderThemeSafari::setSearchFieldSize):
2229         (WebCore::RenderThemeSafari::adjustSearchFieldStyle):
2230         (WebCore::RenderThemeSafari::adjustSearchFieldCancelButtonStyle):
2231         (WebCore::RenderThemeSafari::adjustSearchFieldDecorationPartStyle):
2232         (WebCore::RenderThemeSafari::adjustSearchFieldResultsDecorationPartStyle):
2233         (WebCore::RenderThemeSafari::adjustSearchFieldResultsButtonStyle):
2234         (WebCore::RenderThemeSafari::adjustMeterStyle):
2235         (WebCore::RenderThemeSafari::meterSizeForBounds):
2236         (WebCore::RenderThemeSafari::paintMeter):
2237         * rendering/RenderThemeSafari.h:
2238         * rendering/RenderThemeWin.cpp:
2239         (WebCore::RenderThemeWin::supportsHover):
2240         (WebCore::RenderThemeWin::supportsFocusRing):
2241         (WebCore::RenderThemeWin::adjustInnerSpinButtonStyle):
2242         (WebCore::RenderThemeWin::setCheckboxSize):
2243         (WebCore::RenderThemeWin::paintTextField):
2244         (WebCore::RenderThemeWin::paintMenuList):
2245         (WebCore::RenderThemeWin::adjustMenuListStyle):
2246         (WebCore::RenderThemeWin::adjustMenuListButtonStyle):
2247         (WebCore::RenderThemeWin::adjustSliderThumbSize):
2248         (WebCore::RenderThemeWin::adjustSearchFieldStyle):
2249         (WebCore::RenderThemeWin::adjustSearchFieldCancelButtonStyle):
2250         (WebCore::RenderThemeWin::adjustSearchFieldDecorationPartStyle):
2251         (WebCore::RenderThemeWin::adjustSearchFieldResultsDecorationPartStyle):
2252         (WebCore::RenderThemeWin::adjustSearchFieldResultsButtonStyle):
2253         (WebCore::RenderThemeWin::adjustMeterStyle):
2254         (WebCore::RenderThemeWin::meterSizeForBounds):
2255         (WebCore::RenderThemeWin::paintMeter):
2256         * rendering/RenderThemeWin.h:
2257         (WebCore::RenderThemeWin::paintCheckbox):
2258         (WebCore::RenderThemeWin::paintRadio):
2259         (WebCore::RenderThemeWin::setRadioSize):
2260         (WebCore::RenderThemeWin::paintTextArea):
2261         (WebCore::RenderThemeWin::popupOptionSupportsTextIndent):
2262         (WebCore::RenderThemeWin::paintSearchFieldDecorationPart):
2263         (WebCore::RenderThemeWin::adjustButtonStyle):
2264         (WebCore::RenderThemeWin::adjustTextFieldStyle):
2265         (WebCore::RenderThemeWin::adjustTextAreaStyle):
2266         (WebCore::RenderThemeWin::shouldShowPlaceholderWhenFocused):
2267
2268 2014-06-25  Benjamin Poulain  <benjamin@webkit.org>
2269
2270         [Mac] Update the time base of event's timestamp when the system time changes
2271         https://bugs.webkit.org/show_bug.cgi?id=134293
2272
2273         Reviewed by Anders Carlsson.
2274
2275         * platform/mac/PlatformEventFactoryMac.mm:
2276         (WebCore::cachedStartupTimeIntervalSince1970): Since events timestamps are absolute time, they also
2277         need to be updated if the system clock changes.
2278
2279 2014-06-25  Dirk Schulze  <krit@webkit.org>
2280
2281         Add all blend modes to feBlend
2282
2283         feBlend should support all blend modes from CSS and Canvas
2284         https://bugs.webkit.org/show_bug.cgi?id=134296
2285
2286         Reviewed by Dean Jackson.
2287
2288         Add all blend modes to <feBlend> (the SVG filter primitive) that are also
2289         supported by HTML Canvas and CSS.
2290
2291         In addition, add "normal" blend mode to HTML Canvas as requested by the
2292         CSS Compositing and Blending specification. (Referenced from HTML Canvas.)
2293         With this change, SVG, CSS and Canvas truly share the same blend modes and
2294         even the same keywords. This is much easier to for web authors.
2295
2296         http://www.w3.org/TR/2014/CR-compositing-1-20140220/#ltblendmodegt
2297
2298         Test: svg/filters/feBlend-all-blendmodes.svg
2299
2300         * platform/graphics/GraphicsTypes.cpp: Reorder blend mode text streams to match
2301             enumeration order. Add a new function to parse blend modes independent of
2302             compositing modes. Add a string "normal" that is supported by CSS, feBlend and
2303             HTML Canvas now.
2304         (WebCore::parseBlendMode):
2305         (WebCore::parseCompositeAndBlendOperator):
2306         * platform/graphics/GraphicsTypes.h: Reorder BlendMode enumeration values to match
2307          the SVG JS enumeration for blend modes.
2308         * platform/graphics/cpu/arm/filters/FEBlendNEON.h: Move all software code that is no
2309             longer required by the software path but still used by NEON here.
2310         (WebCore::FEBlend::platformApplySoftware):
2311         (WebCore::FEBlend::platformApplyNEON):
2312         * platform/graphics/filters/FEBlend.cpp:
2313             Use drawImageBuffer() to blend the results of previous filter primitives. This
2314             allows removing more than 60% of the code.
2315         (WebCore::FEBlend::FEBlend):
2316         (WebCore::FEBlend::create):
2317         (WebCore::FEBlend::blendMode):
2318         (WebCore::FEBlend::setBlendMode):
2319         (WebCore::FEBlend::platformApplySoftware):
2320         (WebCore::FEBlend::dump):
2321         (WebCore::FEBlend::externalRepresentation):
2322         (WebCore::feBlendNormal): Deleted.
2323         (WebCore::feBlendMultiply): Deleted.
2324         (WebCore::feBlendScreen): Deleted.
2325         (WebCore::feBlendDarken): Deleted.
2326         (WebCore::feBlendLighten): Deleted.
2327         (WebCore::feBlendUnknown): Deleted.
2328         (WebCore::platformApply): Deleted.
2329         (WebCore::FEBlend::platformApplyGeneric): Deleted.
2330         (WebCore::operator<<): Deleted.
2331         * platform/graphics/filters/FEBlend.h:
2332         * svg/SVGAnimatedEnumeration.cpp: Use the global BlendMode enumeration.
2333         (WebCore::enumerationValueForTargetAttribute):
2334         * svg/SVGFEBlendElement.cpp:
2335         (WebCore::SVGFEBlendElement::SVGFEBlendElement): Use the global BlendMode enumeration.
2336             No new enumeration values added or exposed to SVG DOM as requested by SVG WG.
2337         (WebCore::SVGFEBlendElement::parseAttribute):
2338         * svg/SVGFEBlendElement.h: Replace BlendModeType with global BlendMode enumeration. Remove
2339             blend mode parsing code and use the code in GraphicsTypes instead.
2340         (WebCore::SVGPropertyTraits<BlendMode>::highestEnumValue):
2341         (WebCore::SVGPropertyTraits<BlendMode>::toString):
2342         (WebCore::SVGPropertyTraits<BlendModeType>::highestEnumValue): Deleted.
2343         (WebCore::SVGPropertyTraits<BlendModeType>::toString): Deleted.
2344         (WebCore::SVGPropertyTraits<BlendModeType>::fromString): Deleted.
2345
2346 2014-06-25  Zalan Bujtas  <zalan@apple.com>
2347
2348         Unreviewed iOS build fix after r170425.
2349
2350         * accessibility/AccessibilityProgressIndicator.cpp:
2351         * accessibility/AccessibilityProgressIndicator.h:
2352
2353 2014-06-25  Chris Fleizach  <cfleizach@apple.com>
2354
2355         AX: Crash at com.apple.WebCore: WebCore::AlternativeTextController::removeDictationAlternativesForMarker + 43
2356         https://bugs.webkit.org/show_bug.cgi?id=134226
2357
2358         Reviewed by Enrica Casucci.
2359
2360         Unchecked access of details pointer in the Document marker led to the crash.
2361         It seems erroneous to allow creation of a DocumentMarker without details when one is expected, because it
2362         carries the dictation context (not just the description).
2363         Also, add in ASSERTs to catch scenarios where a nullptr might be passed in.
2364
2365         Test: platform/mac/editing/input/crash-for-empty-text-alternative.html
2366
2367         * dom/DocumentMarker.cpp:
2368         (WebCore::DocumentMarker::DocumentMarker):
2369         * editing/AlternativeTextController.cpp:
2370         (WebCore::AlternativeTextController::removeDictationAlternativesForMarker):
2371
2372 2014-06-25  Laszlo Gombos  <l.gombos@samsung.com>
2373
2374         Remove build guard for progress element
2375         https://bugs.webkit.org/show_bug.cgi?id=134292
2376
2377         Reviewed by Benjamin Poulain.
2378
2379         The build flag is no longer needed as it is always on.
2380
2381         No new tests as there is no new behaviour.
2382
2383         * Configurations/FeatureDefines.xcconfig:
2384         * DerivedSources.make:
2385         * accessibility/AXObjectCache.cpp:
2386         (WebCore::createFromRenderer):
2387         * accessibility/AccessibilityProgressIndicator.cpp:
2388         (WebCore::AccessibilityProgressIndicator::create):
2389         (WebCore::AccessibilityProgressIndicator::valueForRange):
2390         (WebCore::AccessibilityProgressIndicator::maxValueForRange):
2391         (WebCore::AccessibilityProgressIndicator::minValueForRange):
2392         (WebCore::AccessibilityProgressIndicator::progressElement):
2393         * accessibility/AccessibilityProgressIndicator.h:
2394         * css/CSSPrimitiveValueMappings.h:
2395         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2396         * css/StyleResolver.cpp:
2397         (WebCore::StyleResolver::sharingCandidateHasIdenticalStyleAffectingAttributes):
2398         * css/html.css:
2399         (progress::-webkit-progress-value):
2400         * html/HTMLProgressElement.cpp:
2401         * html/HTMLProgressElement.h:
2402         * html/HTMLProgressElement.idl:
2403         * html/HTMLTagNames.in:
2404         * html/shadow/ProgressShadowElement.cpp:
2405         * html/shadow/ProgressShadowElement.h:
2406         * platform/efl/DefaultTheme/CMakeLists.txt:
2407         * platform/efl/DefaultTheme/default.edc:
2408         * platform/efl/RenderThemeEfl.cpp:
2409         (WebCore::toEdjeGroup):
2410         (WebCore::RenderThemeEfl::applyEdjeRTLState):
2411         (WebCore::RenderThemeEfl::paintProgressBar):
2412         * platform/efl/RenderThemeEfl.h:
2413         * platform/gtk/RenderThemeGtk.cpp:
2414         (WebCore::RenderThemeGtk::calculateProgressRect):
2415         * platform/gtk/RenderThemeGtk.h:
2416         * platform/gtk/RenderThemeGtk2.cpp:
2417         (WebCore::RenderThemeGtk::paintProgressBar):
2418         * platform/gtk/RenderThemeGtk3.cpp:
2419         (WebCore::RenderThemeGtk::paintProgressBar):
2420         * rendering/RenderObject.h:
2421         (WebCore::RenderObject::isSnapshottedPlugIn):
2422         (WebCore::RenderObject::isProgress):
2423         * rendering/RenderProgress.cpp:
2424         * rendering/RenderProgress.h:
2425         * rendering/RenderTheme.cpp:
2426         (WebCore::RenderTheme::adjustStyle):
2427         (WebCore::RenderTheme::paint):
2428         (WebCore::RenderTheme::paintBorderOnly):
2429         (WebCore::RenderTheme::paintDecorations):
2430         (WebCore::RenderTheme::progressBarRectForBounds):
2431         * rendering/RenderTheme.h:
2432         (WebCore::RenderTheme::paintProgressBar):
2433         * rendering/RenderThemeIOS.h:
2434         * rendering/RenderThemeIOS.mm:
2435         (WebCore::RenderThemeIOS::paintProgressBar):
2436         * rendering/RenderThemeMac.h:
2437         * rendering/RenderThemeMac.mm:
2438         (WebCore::RenderThemeMac::paintProgressBar):
2439
2440 2014-06-25  Carlos Garcia Campos  <cgarcia@igalia.com>
2441
2442         Unreviewed. Update GObject DOM bindings test results after r170422.
2443
2444         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
2445         (WebKit::wrapTestActiveDOMObject):
2446         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
2447         (WebKit::wrapTestCallback):
2448         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
2449         (WebKit::wrapTestCustomNamedGetter):
2450         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
2451         (WebKit::wrapTestEventConstructor):
2452         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
2453         (WebKit::wrapTestEventTarget):
2454         * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
2455         (WebKit::wrapTestException):
2456         * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.cpp:
2457         (WebKit::wrapTestGenerateIsReachable):
2458         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
2459         (WebKit::wrapTestInterface):
2460         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
2461         (WebKit::wrapTestMediaQueryListListener):
2462         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
2463         (WebKit::wrapTestNamedConstructor):
2464         * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
2465         (WebKit::wrapTestNode):
2466         * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.cpp:
2467         (WebKit::wrapTestNondeterministic):
2468         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
2469         (WebKit::wrapTestObj):
2470         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.cpp:
2471         (WebKit::wrapTestOverloadedConstructors):
2472         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
2473         (WebKit::wrapTestSerializedScriptValueInterface):
2474         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
2475         (WebKit::wrapTestTypedefs):
2476         * bindings/scripts/test/GObject/WebKitDOMattribute.cpp:
2477         (WebKit::wrapattribute):
2478         * bindings/scripts/test/GObject/WebKitDOMreadonly.cpp:
2479         (WebKit::wrapreadonly):
2480
2481 2014-06-24  Tomas Popela  <tpopela@redhat.com>
2482
2483         [GTK] Some of DOM bindings macros are misnamed
2484         https://bugs.webkit.org/show_bug.cgi?id=121543
2485
2486         Reviewed by Carlos Garcia Campos.
2487
2488         As we are using WebKitDOM as a namespace we should unify all type macros
2489         to have WEBKIT_DOM_TYPE prefix instead of WEBKIT_TYPE_DOM. Also add
2490         more exceptions to decamelize function in GObject bindings generator
2491         to fix the names of bindings for BR, HR, UL, OL, DL and LI elements.
2492
2493         * bindings/gobject/GObjectEventListener.cpp:
2494         (WebCore::GObjectEventListener::handleEvent):
2495         * bindings/gobject/WebKitDOMEventTarget.h:
2496         * bindings/gobject/WebKitDOMNodeFilter.h:
2497         * bindings/gobject/WebKitDOMObject.h:
2498         * bindings/gobject/webkitdom.symbols:
2499         * bindings/scripts/CodeGeneratorGObject.pm:
2500         (decamelize):
2501         (GetParentGObjType):
2502         (GenerateProperty):
2503         (GenerateHeader):
2504         (GenerateCFile):
2505         (GenerateEventTargetIface):
2506         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
2507         (WebKit::wrapFloat64Array):
2508         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.h:
2509         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
2510         (WebKit::wrapTestActiveDOMObject):
2511         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
2512         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
2513         (WebKit::wrapTestCallback):
2514         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
2515         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
2516         (WebKit::wrapTestCustomNamedGetter):
2517         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
2518         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
2519         (WebKit::wrapTestEventConstructor):
2520         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.h:
2521         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
2522         (WebKit::wrapTestEventTarget):
2523         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
2524         * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
2525         (WebKit::wrapTestException):
2526         * bindings/scripts/test/GObject/WebKitDOMTestException.h:
2527         * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.cpp:
2528         (WebKit::wrapTestGenerateIsReachable):
2529         * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.h:
2530         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
2531         (WebKit::wrapTestInterface):
2532         (webkit_dom_test_interface_class_init):
2533         * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
2534         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
2535         (WebKit::wrapTestMediaQueryListListener):
2536         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.h:
2537         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
2538         (WebKit::wrapTestNamedConstructor):
2539         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.h:
2540         * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
2541         (WebKit::wrapTestNode):
2542         * bindings/scripts/test/GObject/WebKitDOMTestNode.h:
2543         * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.cpp:
2544         (WebKit::wrapTestNondeterministic):
2545         * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.h:
2546         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
2547         (WebKit::wrapTestObj):
2548         (webkit_dom_test_obj_class_init):
2549         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
2550         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.cpp:
2551         (WebKit::wrapTestOverloadedConstructors):
2552         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.h:
2553         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
2554         (WebKit::wrapTestSerializedScriptValueInterface):
2555         (webkit_dom_test_serialized_script_value_interface_class_init):
2556         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h:
2557         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
2558         (WebKit::wrapTestTypedefs):
2559         (webkit_dom_test_typedefs_class_init):
2560         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:
2561         * bindings/scripts/test/GObject/WebKitDOMattribute.cpp:
2562         (WebKit::wrapattribute):
2563         * bindings/scripts/test/GObject/WebKitDOMattribute.h:
2564         * bindings/scripts/test/GObject/WebKitDOMreadonly.cpp:
2565         (WebKit::wrapreadonly):
2566         * bindings/scripts/test/GObject/WebKitDOMreadonly.h:
2567
2568 2014-06-24  Commit Queue  <commit-queue@webkit.org>
2569
2570         Unreviewed, rolling out r170414.
2571         https://bugs.webkit.org/show_bug.cgi?id=134291
2572
2573         the patch added a test that fails on almost every Mac tester
2574         (Requested by rniwa on #webkit).
2575
2576         Reverted changeset:
2577
2578         "Tiles on bottom of screen are not always allocated when
2579         necessary"
2580         https://bugs.webkit.org/show_bug.cgi?id=134272
2581         http://trac.webkit.org/changeset/170414
2582
2583 2014-06-24  Myles C. Maxfield  <mmaxfield@apple.com>
2584
2585         Tiles on bottom of screen are not always allocated when necessary
2586         https://bugs.webkit.org/show_bug.cgi?id=134272
2587
2588         Reviewed by Simon Fraser.
2589
2590         The initial visibleRect is in the coordinate of the root layer, so its origin
2591         is at the top left of the view. The initial rect we were using doesn't
2592         include the contents inset, so it was too short, which was causing tiles near
2593         the bottom of the screen to not always be allocated if the tile threshold was
2594         close to the bottom of the view. Instead, we want to include the contents
2595         inset size so the visible rect includes the entire view.
2596         GraphicsLayerCA::recursiveCommitChanges() takes care of mapping and cropping
2597         the visible rect into the tiled layer's coordinate system, at which point it
2598         is used for visible tile logic.
2599
2600         Test: platform/mac-wk2/tiled-drawing/visible-rect-content-inset.html
2601
2602         * platform/graphics/ca/TileCoverageMap.cpp:
2603         (WebCore::TileCoverageMap::update):
2604         * rendering/RenderLayerCompositor.cpp:
2605         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
2606
2607 2014-06-24  Myles C. Maxfield  <mmaxfield@apple.com>
2608
2609         InlineTextBox's m_len can be an unsigned (rather than an unsigned short)
2610         https://bugs.webkit.org/show_bug.cgi?id=134173
2611
2612         Reviewed by Daniel Bates.
2613
2614         After Zalan's talks with Kling, it seems that the simple line layout code
2615         might alleviate the need for the space savings in InlineTextBox. Given this,
2616         it would be beneficial to be a little more safe by using unsigneds throughout.
2617
2618         For example, we have code like "void setLen(unsigned len) { m_len = len; }"
2619         which might silently break if given particular inputs.
2620
2621         No new tests because there is no behavior change.
2622
2623         * rendering/InlineTextBox.cpp:
2624         (WebCore::InlineTextBox::isSelected):
2625         (WebCore::InlineTextBox::localSelectionRect):
2626         (WebCore::InlineTextBox::paint):
2627         (WebCore::InlineTextBox::selectionStartEnd):
2628         (WebCore::InlineTextBox::paintSelection):
2629         (WebCore::InlineTextBox::paintCompositionBackground):
2630         (WebCore::InlineTextBox::paintDocumentMarker):
2631         (WebCore::InlineTextBox::paintTextMatchMarker):
2632         (WebCore::InlineTextBox::computeRectForReplacementMarker):
2633         * rendering/InlineTextBox.h:
2634         (WebCore::InlineTextBox::truncation):
2635         * rendering/RenderTextLineBoxes.cpp:
2636         (WebCore::ellipsisRectForBox):
2637
2638 2014-06-24  Ryosuke Niwa  <rniwa@webkit.org>
2639
2640         Speculative 32-bit Mac build fix after r170402.
2641
2642         * platform/graphics/mac/ComplexTextController.cpp:
2643         (WebCore::advanceByCombiningCharacterSequence):
2644
2645 2014-06-24  Joseph Pecoraro  <pecoraro@apple.com>
2646
2647         [iOS]: WK2 Inspector Node Highlighting
2648         https://bugs.webkit.org/show_bug.cgi?id=134257
2649
2650         Reviewed by Timothy Hatcher.
2651
2652         Some clients want to get highlights with the scroll applied,
2653         others do not. Provide a CoordinateSpace param to be used for
2654         getting a highlight (only used on iOS).
2655
2656         * WebCore.exp.in:
2657         * inspector/InspectorController.cpp:
2658         (WebCore::InspectorController::getHighlight):
2659         * inspector/InspectorController.h:
2660         * inspector/InspectorOverlay.cpp:
2661         (WebCore::InspectorOverlay::getHighlight):
2662         (WebCore::buildObjectForRendererFragments):
2663         * inspector/InspectorOverlay.h:
2664         (WebCore::Highlight::Highlight):
2665         * testing/Internals.cpp:
2666         (WebCore::Internals::inspectorHighlightRects):
2667
2668 2014-06-24  Jer Noble  <jer.noble@apple.com>
2669
2670         [MSE][Mac] Uncaught exception when deallocating AVSampleBufferDisplayLayer
2671         https://bugs.webkit.org/show_bug.cgi?id=134281
2672
2673         Reviewed by Brent Fulgham.
2674
2675         AVSampleBufferDisplayLayer is throwing an exception from its -dealloc method because KVO observers exist
2676         at the time of dealloc. Remove the observer for outputObscuredDueToInsufficientExternalProtection inside
2677         -stopObservingLayer.
2678
2679         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
2680         (-[WebAVSampleBufferErrorListener stopObservingLayer:]):
2681
2682 2014-06-24  Mark Rowe  <mrowe@apple.com>
2683
2684         WKContextHistoryClient::didNavigateWithNavigationData is passed incorrect URL when history.pushState is used
2685         <https://webkit.org/b/134271> / <rdar://problem/16270167>
2686
2687         Reviewed by Brady Eidson.
2688
2689         Tests: http/tests/globalhistory/history-delegate-pushstate.html
2690                http/tests/globalhistory/history-delegate-replacestate.html
2691
2692         * page/History.cpp:
2693         (WebCore::History::stateObjectAdded): Call HistoryController after updating the document's URL so that the
2694         URL will reflect the destination of the navigation when FrameLoaderClient::updateGlobalHistory is called.
2695
2696 2014-06-24  Myles C. Maxfield  <mmaxfield@apple.com>
2697
2698         advanceByCombiningCharacterSequence() can be simplified
2699         https://bugs.webkit.org/show_bug.cgi?id=133591
2700
2701         Reviewed by Dean Jackson.
2702
2703         Use U16_NEXT() because it already does what we're trying to do.
2704
2705         No new tests because there is no behavior change.
2706
2707         * platform/graphics/mac/ComplexTextController.cpp:
2708         (WebCore::advanceByCombiningCharacterSequence):
2709
2710 2014-06-24  Brady Eidson  <beidson@apple.com>
2711
2712         Enable GAMEPAD in the Mac build, but disabled at runtime.
2713         https://bugs.webkit.org/show_bug.cgi?id=134255
2714
2715         Reviewed by Dean Jackson.
2716
2717         No new tests (No changes to a tested config).
2718
2719         * bindings/scripts/CodeGeneratorJS.pm:
2720         (GenerateImplementation): Add the ability to have a function be EnabledAtRuntime by
2721           removing such functions from the prototype if they are disabled.
2722
2723         Change the three new objects and the one new function to be EnabledAtRuntime
2724         * Modules/gamepad/Gamepad.idl:
2725         * Modules/gamepad/GamepadButton.idl:
2726         * Modules/gamepad/GamepadEvent.idl:
2727         * Modules/gamepad/NavigatorGamepad.idl:
2728
2729         Add a RuntimeEnabledFeature for Gamepads:
2730         * bindings/generic/RuntimeEnabledFeatures.cpp:
2731         (WebCore::RuntimeEnabledFeatures::RuntimeEnabledFeatures):
2732         * bindings/generic/RuntimeEnabledFeatures.h:
2733         (WebCore::RuntimeEnabledFeatures::setGamepadsEnabled):
2734         (WebCore::RuntimeEnabledFeatures::gamepadsEnabled):
2735
2736         * Configurations/FeatureDefines.xcconfig:
2737
2738 2014-06-24  Yusuke Suzuki  <utatane.tea@gmail.com>
2739
2740         CSS JIT: Add positionInRootFragments to SelectorFragment
2741         https://bugs.webkit.org/show_bug.cgi?id=133609
2742
2743         Reviewed by Benjamin Poulain.
2744
2745         Some non-backtrack-related predicates use relationToRightFragment information
2746         to decide whether checkingContext->elementStyle should be refered.
2747         To make it works correctly, add the positionInRootFragments field to SelectorFragment.
2748         When positionInRootFragments == Rightmost and relationToRightFragment == Rightmost,
2749         we should see checkingContext->elementStyle.
2750
2751         Test: fast/selectors/first-child-update-with-renderer.html
2752
2753         * cssjit/SelectorCompiler.cpp:
2754         (WebCore::SelectorCompiler::shouldUseRenderStyleFromCheckingContext):
2755         (WebCore::SelectorCompiler::addPseudoClassType):
2756         (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
2757         (WebCore::SelectorCompiler::constructFragments):
2758         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsActive):
2759         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
2760         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsHovered):
2761         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLastChild):
2762         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsOnlyChild):
2763         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
2764
2765 2014-06-24  Jer Noble  <jer.noble@apple.com>
2766
2767         [Fullscreen][Mac] WKView is not firstResponder after entering fullscreen mode
2768         https://bugs.webkit.org/show_bug.cgi?id=134270
2769
2770         Reviewed by Jon Honeycutt.
2771
2772         The WebCoreFullScreenWindow's firstResponder is reset when the full screen animation completes and
2773         the window's style is changed to a fullscreen style. Save the firstResponder, and if it's still in
2774         the window's view hierarchy after the style changes, reset it to the firstResponder.
2775
2776         * platform/mac/WebCoreFullScreenWindow.mm:
2777         (-[WebCoreFullScreenWindow setStyleMask:]):
2778
2779 2014-06-24  Jer Noble  <jer.noble@apple.com>
2780
2781         [MSE][Mac] Pass AVSampleBufferDisplayLayer HDCP status through to EME
2782         https://bugs.webkit.org/show_bug.cgi?id=134221
2783
2784         Reviewed by Eric Carlson.
2785
2786         Pass the outputObscuredDueToInsufficientExternalProtection property of AVSampleBufferDisplayLayer
2787         as an error to the associated MediaKeySession object.
2788
2789         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
2790         (-[WebAVSampleBufferErrorListener invalidate]):
2791         (-[WebAVSampleBufferErrorListener beginObservingLayer:]):
2792         (-[WebAVSampleBufferErrorListener observeValueForKeyPath:ofObject:change:context:]):
2793
2794 2014-06-20  Myles C. Maxfield  <mmaxfield@apple.com>
2795
2796         Use unsigneds instead of ints for indexes into a string in text layout code
2797         https://bugs.webkit.org/show_bug.cgi?id=133592
2798
2799         Reviewed by Zalan Bujtas.
2800
2801         Migrate much of the text-handling code to use unsigneds for indexes into a string.
2802
2803         No new tests because there is no behavior change.
2804
2805         * WebCore.exp.in:
2806         * platform/graphics/Font.cpp:
2807         (WebCore::Font::drawText):
2808         (WebCore::Font::drawEmphasisMarks):
2809         (WebCore::Font::adjustSelectionRectForText):
2810         (WebCore::computeUnderlineType):
2811         * platform/graphics/Font.h:
2812         * platform/graphics/FontFastPath.cpp:
2813         (WebCore::Font::getGlyphsAndAdvancesForSimpleText):
2814         (WebCore::Font::drawSimpleText):
2815         (WebCore::Font::drawEmphasisMarksForSimpleText):
2816         (WebCore::Font::drawGlyphBuffer):
2817         (WebCore::Font::drawEmphasisMarks):
2818         (WebCore::Font::adjustSelectionRectForSimpleText):
2819         * platform/graphics/GlyphBuffer.h:
2820         (WebCore::GlyphBuffer::size):
2821         (WebCore::GlyphBuffer::glyphs):
2822         (WebCore::GlyphBuffer::advances):
2823         (WebCore::GlyphBuffer::fontDataAt):
2824         (WebCore::GlyphBuffer::advanceAt):
2825         (WebCore::GlyphBuffer::offsetAt):
2826         (WebCore::GlyphBuffer::reverse):
2827         (WebCore::GlyphBuffer::offsetInString):
2828         (WebCore::GlyphBuffer::swap):
2829         * platform/graphics/GraphicsContext.cpp:
2830         (WebCore::TextRunIterator::atEnd):
2831         * platform/graphics/Latin1TextIterator.h:
2832         (WebCore::Latin1TextIterator::Latin1TextIterator):
2833         (WebCore::Latin1TextIterator::currentCharacter):
2834         * platform/graphics/SimpleFontData.h:
2835         * platform/graphics/SurrogatePairAwareTextIterator.cpp:
2836         (WebCore::SurrogatePairAwareTextIterator::SurrogatePairAwareTextIterator):
2837         * platform/graphics/SurrogatePairAwareTextIterator.h:
2838         (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
2839         * platform/graphics/TextRun.h:
2840         (WebCore::TextRun::length):
2841         (WebCore::TextRun::charactersLength):
2842         * platform/graphics/WidthIterator.cpp:
2843         (WebCore::WidthIterator::glyphDataForCharacter):
2844         (WebCore::applyFontTransforms):
2845         (WebCore::WidthIterator::advanceInternal):
2846         (WebCore::WidthIterator::advance):
2847         (WebCore::WidthIterator::advanceOneCharacter):
2848         * platform/graphics/WidthIterator.h:
2849         * platform/graphics/cairo/FontCairo.cpp:
2850         (WebCore::Font::drawGlyphs):
2851         * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
2852         (WebCore::Font::drawComplexText):
2853         (WebCore::Font::drawEmphasisMarksForComplexText):
2854         (WebCore::Font::adjustSelectionRectForComplexText):
2855         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
2856         (WebCore::HarfBuzzShaper::setNormalizedBuffer):
2857         * platform/graphics/mac/FontComplexTextMac.cpp:
2858         (WebCore::Font::adjustSelectionRectForComplexText):
2859         (WebCore::Font::getGlyphsAndAdvancesForComplexText):
2860         (WebCore::Font::drawComplexText):
2861         (WebCore::Font::drawEmphasisMarksForComplexText):
2862         * platform/graphics/mac/FontMac.mm:
2863         (WebCore::Font::drawGlyphs):
2864         * platform/graphics/win/FontCGWin.cpp:
2865         (WebCore::Font::drawGlyphs):
2866         * platform/graphics/win/FontWin.cpp:
2867         (WebCore::Font::adjustSelectionRectForComplexText):
2868         (WebCore::Font::getGlyphsAndAdvancesForComplexText):
2869         (WebCore::Font::drawComplexText):
2870         (WebCore::Font::drawEmphasisMarksForComplexText):
2871         * platform/graphics/wince/FontWinCE.cpp:
2872         (WebCore::Font::drawGlyphs):
2873         (WebCore::Font::drawComplexText):
2874         (WebCore::Font::drawEmphasisMarksForComplexText):
2875         (WebCore::Font::selectionRectForComplexText):
2876         * rendering/InlineTextBox.cpp:
2877         (WebCore::InlineTextBox::isSelected):
2878         (WebCore::InlineTextBox::selectionState):
2879         (WebCore::adjustCharactersAndLengthForHyphen):
2880         (WebCore::InlineTextBox::localSelectionRect):
2881         (WebCore::InlineTextBox::paint):
2882         (WebCore::InlineTextBox::selectionStartEnd):
2883         (WebCore::InlineTextBox::paintSelection):
2884         (WebCore::InlineTextBox::paintCompositionBackground):
2885         (WebCore::InlineTextBox::paintDocumentMarker):
2886         (WebCore::InlineTextBox::paintTextMatchMarker):
2887         (WebCore::InlineTextBox::computeRectForReplacementMarker):
2888         (WebCore::InlineTextBox::paintCompositionUnderline):
2889         (WebCore::InlineTextBox::positionForOffset):
2890         (WebCore::InlineTextBox::constructTextRun):
2891         * rendering/InlineTextBox.h:
2892         * rendering/RenderCombineText.cpp:
2893         (WebCore::RenderCombineText::getStringToRender):
2894         * rendering/RenderCombineText.h:
2895         * rendering/svg/SVGInlineFlowBox.cpp:
2896         (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
2897         * rendering/svg/SVGInlineTextBox.cpp:
2898         (WebCore::SVGInlineTextBox::positionForOffset):
2899         (WebCore::SVGInlineTextBox::localSelectionRect):
2900         (WebCore::SVGInlineTextBox::paintSelectionBackground):
2901         (WebCore::SVGInlineTextBox::mapStartEndPositionsIntoFragmentCoordinates):
2902         (WebCore::SVGInlineTextBox::paintText):
2903         * rendering/svg/SVGInlineTextBox.h:
2904         * rendering/svg/SVGTextMetricsBuilder.cpp:
2905         (WebCore::SVGTextMetricsBuilder::currentCharacterStartsSurrogatePair):
2906         (WebCore::SVGTextMetricsBuilder::advance):
2907         * rendering/svg/SVGTextQuery.cpp:
2908         (WebCore::SVGTextQuery::mapStartEndPositionsIntoFragmentCoordinates):
2909         (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures):
2910         (WebCore::SVGTextQuery::subStringLengthCallback):
2911         (WebCore::SVGTextQuery::startPositionOfCharacterCallback):
2912         (WebCore::SVGTextQuery::endPositionOfCharacterCallback):
2913         (WebCore::SVGTextQuery::rotationOfCharacterCallback):
2914         (WebCore::SVGTextQuery::extentOfCharacterCallback):
2915         (WebCore::SVGTextQuery::characterNumberAtPositionCallback):
2916         * rendering/svg/SVGTextQuery.h:
2917         * rendering/svg/SVGTextRunRenderingContext.cpp:
2918         (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
2919         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
2920         * rendering/svg/SVGTextRunRenderingContext.h:
2921         * svg/SVGFontData.cpp:
2922         (WebCore::SVGFontData::applySVGGlyphSelection):
2923         * svg/SVGFontData.h:
2924
2925 2014-06-24  Eric Carlson  <eric.carlson@apple.com>
2926
2927         Unreviewed build fix.
2928
2929         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
2930         (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): Cast variadic argument to int.
2931
2932 2014-06-24  Brent Fulgham  <bfulgham@apple.com>
2933
2934         [Win] MSVC mishandles enums in bitfields
2935         https://bugs.webkit.org/show_bug.cgi?id=134237
2936
2937         Reviewed by Michael Saboff.
2938
2939         Replace uses of enum types in bit fields with unsigned to
2940         avoid losing a bit to hold the sign value. This can result
2941         in Windows interpreting the value of the field improperly.
2942
2943         * loader/ResourceLoaderOptions.h:
2944         * platform/network/ResourceRequestBase.h:
2945         * platform/network/cf/ResourceResponse.h:
2946         * rendering/RenderLayer.h:
2947         * rendering/RenderMarquee.h:
2948
2949 2014-06-24  Antti Koivisto  <antti@apple.com>
2950
2951         Try to fix build.
2952
2953         * WebCore.exp.in: Remove duplicate export, this should be in the iOS section only.
2954
2955 2014-06-24  Eric Carlson  <eric.carlson@apple.com>
2956
2957         [Mac] process raw VTT in-band captions
2958         https://bugs.webkit.org/show_bug.cgi?id=134178
2959
2960         Reviewed by Jer Noble.
2961
2962         * CMakeLists.txt: Add ISOVTTCue.cpp|h.
2963         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
2964         * WebCore.xcodeproj/project.pbxproj: Ditto.
2965
2966         * html/track/BufferedLineReader.h:
2967         (WebCore::BufferedLineReader::reset): New, empty the input buffer.
2968
2969         Make it possible to process WebVTT captions. 
2970         * html/track/InbandGenericTextTrack.cpp:
2971         (WebCore::InbandGenericTextTrack::parser): Allocate, if necessary, and return a WebVTT parser.
2972         (WebCore::InbandGenericTextTrack::parseWebVTTCueData): Pass a cue to the parser.
2973         (WebCore::InbandGenericTextTrack::parseWebVTTFileHeader): Pass a VTT file header to the parser.
2974         (WebCore::InbandGenericTextTrack::newCuesParsed): Parser callback.
2975         (WebCore::InbandGenericTextTrack::newRegionsParsed): Ditto.
2976         (WebCore::InbandGenericTextTrack::fileFailedToParse): Ditto.
2977         * html/track/InbandGenericTextTrack.h:
2978
2979         * html/track/InbandTextTrack.h:
2980
2981         * html/track/InbandWebVTTTextTrack.cpp:
2982         (WebCore::InbandWebVTTTextTrack::parser): New, parser accessor.
2983         (WebCore::InbandWebVTTTextTrack::parseWebVTTCueData): New, parse VTT data in an ISOWebVTTCue
2984             object.
2985         (WebCore::InbandWebVTTTextTrack::newCuesParsed): Cleanup.
2986         (WebCore::InbandWebVTTTextTrack::newRegionsParsed): Implement.
2987         (WebCore::InbandWebVTTTextTrack::fileFailedToParse): Change the error message.
2988         * html/track/InbandWebVTTTextTrack.h:
2989
2990         * html/track/TextTrackCueGeneric.cpp:
2991         (WebCore::TextTrackCueGenericBoxElement::TextTrackCueGenericBoxElement): Change cue parameter
2992             from a pointer to a reference.
2993         (WebCore::TextTrackCueGeneric::createDisplayTree): Ditto.
2994
2995         * html/track/VTTCue.cpp:
2996         (WebCore::VTTCueBox::create): Change cue parameter from a pointer to a reference.
2997         (WebCore::VTTCueBox::VTTCueBox): Ditto.
2998         (WebCore::VTTCueBox::getCue): Return a reference.
2999         (WebCore::VTTCueBox::applyCSSProperties): m_cue is a reference, not a pointer.
3000         (WebCore::VTTCue::create): New, create a VTTCue from WebVTTCueData.
3001         (WebCore::VTTCue::VTTCue): New, internal constructor that takes a WebVTTCueData.
3002         (WebCore::VTTCue::initialize): New, shared constructor initialization.
3003         (WebCore::VTTCue::createDisplayTree): m_cue is a reference, not a pointer.
3004         (WebCore::VTTCue::markFutureAndPastNodes): Ditto.
3005         (WebCore::VTTCue::setCueSettings): Ditto.
3006         * html/track/VTTCue.h:
3007         (WebCore::VTTCueBox::create): Deleted.
3008         (WebCore::VTTCue::create): Deleted.
3009
3010         * html/track/WebVTTParser.cpp:
3011         (WebCore::WebVTTParser::parseFileHeader): New. Reset the line reader buffer and parser state, 
3012             call the parser.
3013         (WebCore::WebVTTParser::parseCueData): Create a cue from ISOWebVTTCue.
3014         (WebCore::WebVTTParser::collectTimingsAndSettings): Return immediately if the string is empty.
3015         (WebCore::WebVTTParser::collectTimeStamp): Ditto.
3016         * html/track/WebVTTParser.h:
3017         (WebCore::WebVTTCueData::originalStartTime): New.
3018         (WebCore::WebVTTCueData::setOriginalStartTime): New.
3019         (WebCore::WebVTTCueData::WebVTTCueData):
3020
3021         * loader/TextTrackLoader.cpp:
3022         (WebCore::TextTrackLoader::getNewCues): Cleanup, use the new VTTCue::create.
3023
3024         Parse ISO WebVTT cue boxes.
3025         * platform/graphics/ISOVTTCue.cpp: Added.
3026         (WebCore::ISOBox::ISOBox):
3027         (WebCore::ISOBox::peekType):
3028         (WebCore::ISOBox::peekLength):
3029         (WebCore::ISOBox::peekString):
3030         (WebCore::vttCueBoxType):
3031         (WebCore::vttIdBoxType):
3032         (WebCore::vttSettingsBoxType):
3033         (WebCore::vttPayloadBoxType):
3034         (WebCore::vttCurrentTimeBoxType):
3035         (WebCore::vttCueSourceIDBoxType):
3036         (WebCore::ISOWebVTTCue::boxType):
3037         (WebCore::ISOWebVTTCue::ISOWebVTTCue):
3038         * platform/graphics/ISOVTTCue.h: Added.
3039         (WebCore::ISOBox::boxHeaderSize):
3040         (WebCore::ISOBox::length):
3041         (WebCore::ISOBox::type):
3042         (WebCore::ISOWebVTTCue::presentationTime):
3043         (WebCore::ISOWebVTTCue::duration):
3044         (WebCore::ISOWebVTTCue::sourceID):
3045         (WebCore::ISOWebVTTCue::id):
3046         (WebCore::ISOWebVTTCue::originalStartTime):
3047         (WebCore::ISOWebVTTCue::settings):
3048         (WebCore::ISOWebVTTCue::cueText):
3049
3050         * platform/graphics/InbandTextTrackPrivateClient.h:
3051         (WebCore::InbandTextTrackPrivateClient::parseWebVTTFileHeader): New.
3052
3053         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
3054         (WebCore::InbandTextTrackPrivateAVF::InbandTextTrackPrivateAVF): Add a cue format parameter.
3055         (WebCore::InbandTextTrackPrivateAVF::processCue): Call processNativeSamples.
3056         (WebCore::InbandTextTrackPrivateAVF::processAttributedStrings): Add logging. Minor cleanup.
3057         (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): New, process an array of 
3058             CMSampleBuffers, create ISOWebVTTCue from the sample data.
3059         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
3060
3061         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.cpp:
3062         (WebCore::InbandTextTrackPrivateAVCF::InbandTextTrackPrivateAVCF):
3063         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.h:
3064         (WebCore::InbandTextTrackPrivateAVCF::create):
3065         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3066         (WebCore::MediaPlayerPrivateAVFoundationCF::processMediaSelectionOptions):
3067         (WebCore::LegibleOutputData::LegibleOutputData):
3068         (WebCore::AVFWrapper::processCue):
3069         (WebCore::AVFWrapper::legibleOutputCallback):
3070
3071         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
3072         (WebCore::InbandTextTrackPrivateAVFObjC::create): Add a cue format parameter.
3073         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
3074         (WebCore::InbandTextTrackPrivateAVFObjC::InbandTextTrackPrivateAVFObjC): Ditto.
3075
3076         * platform/graphics/avfoundation/InbandTextTrackPrivateLegacyAVFObjC.cpp:
3077         (WebCore::InbandTextTrackPrivateLegacyAVFObjC::InbandTextTrackPrivateLegacyAVFObjC): Pass cue
3078             format to base class.
3079
3080         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
3081         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3082         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Improve logging.
3083         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Don't leak an NSDictionary.
3084         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Don't process media selection
3085             options until we have tracks.
3086         (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions): 
3087         (WebCore::MediaPlayerPrivateAVFoundationObjC::processCue): Pass native samples as well as 
3088             attributed strings to track.
3089         (-[WebCoreAVFMovieObserver legibleOutput:didOutputAttributedStrings:nativeSampleBuffers:forItemTime:]):
3090         * platform/graphics/avfoundation/objc/OutOfBandTextTrackPrivateAVF.h:
3091         (WebCore::OutOfBandTextTrackPrivateAVF::OutOfBandTextTrackPrivateAVF):
3092
3093         * platform/graphics/avfoundation/objc/OutOfBandTextTrackPrivateAVF.h:
3094         (WebCore::OutOfBandTextTrackPrivateAVF::OutOfBandTextTrackPrivateAVF):
3095
3096 2014-06-24  Antti Koivisto  <antti@apple.com>
3097
3098         Only flush layers when the exposed rect actually changes
3099         https://bugs.webkit.org/show_bug.cgi?id=134248
3100
3101         Reviewed by Anders Carlsson.
3102
3103         * WebCore.exp.in:
3104
3105 2014-06-24  Brady Eidson  <beidson@apple.com>
3106
3107         Remove references to "Shader.h" which doesn't currently exist in the project.
3108
3109         Rubberstamped by Andreas Kling.
3110
3111         * WebCore.xcodeproj/project.pbxproj:
3112
3113 2014-06-24  Martin Hock  <mhock@apple.com>
3114
3115         [iOS] DOMWindow::outerWidth and outerHeight don't return useful values, so return 0.
3116         Also, revert r169281.
3117         https://bugs.webkit.org/show_bug.cgi?id=134233
3118         <rdar://problem/17060183>
3119
3120         Reviewed by Benjamin Poulain.
3121
3122         * page/DOMWindow.cpp:
3123         (WebCore::DOMWindow::outerHeight):
3124         (WebCore::DOMWindow::outerWidth):
3125
3126 2014-06-24  Jeremy Jones  <jeremyj@apple.com>
3127
3128         Don't set AudioSession active while interrupted.
3129         https://bugs.webkit.org/show_bug.cgi?id=134239
3130
3131         Reviewed by Eric Carlson.
3132
3133         To activate the AudioSession there must be a session with audio or video
3134         and being playing or paused.
3135
3136         * platform/audio/MediaSessionManager.cpp:
3137         (WebCore::MediaSessionManager::hasActive): added
3138         (WebCore::MediaSessionManager::beginInterruption): updateSessionState
3139         (WebCore::MediaSessionManager::sessionWillBeginPlayback): updateSessionState
3140         * platform/audio/MediaSessionManager.h: declare hasActive()
3141         * platform/audio/mac/MediaSessionManagerMac.cpp:
3142         (MediaSessionManager::updateSessionState): use hasActive()
3143
3144 2014-06-24  Jer Noble  <jer.noble@apple.com>
3145
3146         REGRESSION(r170336): Crash in HTMLMediaElement::seekTimerFired()
3147         https://bugs.webkit.org/show_bug.cgi?id=134253
3148
3149         Rubber-stamped by Eric Carlson.
3150
3151         Now that seekWithTolerance() has been split up into an asyncronous section, the null-checks in seekWithTolerance()
3152         need to be re-performed in seekTimerFired(), in case the m_player has been cleared between when the seek was initiated
3153         and when the asynchronous section is performed.
3154
3155         * html/HTMLMediaElement.cpp:
3156         (WebCore::HTMLMediaElement::seekTimerFired):
3157
3158 2014-06-24  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
3159
3160         Fix unused parameter warnings if inspector is disabled
3161         https://bugs.webkit.org/show_bug.cgi?id=134244
3162
3163         Reviewed by Zalan Bujtas.
3164
3165         No new tests, no behavior change.
3166
3167         * inspector/InspectorConsoleInstrumentation.h:
3168         (WebCore::InspectorInstrumentation::startProfiling):
3169         (WebCore::InspectorInstrumentation::stopProfiling):
3170         * inspector/InspectorInstrumentation.h:
3171         (WebCore::InspectorInstrumentation::didFinishXHRLoading):
3172         * loader/cache/CachedResourceLoader.cpp:
3173         (WebCore::CachedResourceLoader::shouldContinueAfterNotifyingLoadedFromMemoryCache):
3174
3175 2014-06-24  Jer Noble  <jer.noble@apple.com>
3176
3177         [MSE] Add null-check in sourceBufferPrivateAppendComplete().
3178         https://bugs.webkit.org/show_bug.cgi?id=133230
3179
3180         Reviewed by Eric Carlson.
3181
3182         * Modules/mediasource/SourceBuffer.cpp:
3183         (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete): Bail early if the 
3184             SourceBuffer has been removed from the MediaSource.
3185
3186 2014-06-24  Commit Queue  <commit-queue@webkit.org>
3187
3188         Unreviewed, rolling out r170337.
3189         https://bugs.webkit.org/show_bug.cgi?id=134250
3190
3191         caused 3 layout tests to crash on debug. (Requested by zalan
3192         on #webkit).
3193
3194         Reverted changeset:
3195
3196         "Use unsigneds instead of ints for indexes into a string in
3197         text layout code"
3198         https://bugs.webkit.org/show_bug.cgi?id=133592
3199         http://trac.webkit.org/changeset/170337
3200
3201 2014-06-24  Jarek Czekalski  <jarekczek@poczta.onet.pl>
3202
3203         [ATK] Don't ignore links rendered as blocks.
3204         https://bugs.webkit.org/show_bug.cgi?id=130941
3205
3206         Reviewed by Mario Sanchez Prada.
3207
3208         * /m/usr/src/webkit-trunk/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
3209         (WebCore::AccessibilityObject::objectFocusedAndCaretOffsetUnignored): Don't ignore links
3210         when they are renderered with display:block.
3211
3212 2014-06-24  Carlos Garcia Campos  <cgarcia@igalia.com>
3213
3214         Unreviewed. Update GObject DOM bindings test results after r170351.
3215
3216         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
3217         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:
3218
3219 2014-06-24  Carlos Garcia Campos  <cgarcia@igalia.com>
3220
3221         Unreviewed. Fix GTK+ build after r170309.
3222
3223         Skip functions returning arrays in GObject DOM bindings.
3224
3225         * bindings/scripts/CodeGeneratorGObject.pm:
3226         (SkipFunction):
3227
3228 2014-06-23  Ryuan Choi  <ryuan.choi@samsung.com>
3229
3230         [EFL] Replace RefPtr<Evas_Object> with UniquePtrEfl
3231         https://bugs.webkit.org/show_bug.cgi?id=134236
3232
3233         Reviewed by Gyuyoung Kim.
3234
3235         * platform/efl/RenderThemeEfl.cpp:
3236         (WebCore::RenderThemeEfl::ThemePartCacheEntry::create):
3237         (WebCore::RenderThemeEfl::loadTheme):
3238         (WebCore::RenderThemeEfl::applyPartDescriptionsFrom):
3239         * platform/efl/RenderThemeEfl.h:
3240         * platform/graphics/efl/CairoUtilitiesEfl.cpp:
3241         (WebCore::evasObjectFromCairoImageSurface):
3242         * platform/graphics/efl/CairoUtilitiesEfl.h:
3243         * platform/graphics/efl/ImageEfl.cpp:
3244         (WebCore::BitmapImage::getEvasObject):
3245
3246 2014-06-23  Jeremy Jones  <jeremyj@apple.com>
3247
3248         Chapter forward/backward should seek to beginning/end.
3249         https://bugs.webkit.org/show_bug.cgi?id=134225
3250
3251         Reviewed by Eric Carlson.
3252
3253         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
3254         (-[WebAVPlayerController seekChapterBackward:]): forwards to -seekToBeginning
3255         (-[WebAVPlayerController seekChapterForward:]): forwards to -seekToEnd
3256
3257 2014-06-23  Dean Jackson  <dino@apple.com>
3258
3259         [Mac] Don't draw focus rings if we are animating controls
3260         https://bugs.webkit.org/show_bug.cgi?id=134232
3261         <rdar://problem/17381121>
3262
3263         Reviewed by Tim Horton.
3264
3265         Controls in native apps do not draw their focus rings as they
3266         animate (in Yosemite). Turn this off for WebKit too. It turns
3267         out that when we were drawing them, they were in the wrong
3268         place anyway.
3269
3270         Since we don't animate controls when testing, we can't really test this.
3271
3272         * platform/mac/ThemeMac.mm:
3273         (WebCore::paintToggleButton): Only draw the focus ring if the
3274         NSButtonCell is not animating.
3275
3276 2014-06-23  Krzysztof Czech  <k.czech@samsung.com>
3277
3278         [ATK] Remove some unnecessary code from WebKitAccessibleWrapperAtk
3279         https://bugs.webkit.org/show_bug.cgi?id=134193
3280
3281         Reviewed by Gyuyoung Kim.
3282
3283         It was used along with DRT. Since we have stopped support WK1/DRT, it won't be needed.
3284
3285         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
3286         (webkitAccessibleGetFocusedElement): Deleted.
3287         * accessibility/atk/WebKitAccessibleWrapperAtk.h:
3288
3289 2014-06-20  Myles C. Maxfield  <mmaxfield@apple.com>
3290
3291         Use unsigneds instead of ints for indexes into a string in text layout code
3292         https://bugs.webkit.org/show_bug.cgi?id=133592
3293
3294         Reviewed by Zalan Bujtas.
3295
3296         Migrate much of the text-handling code to use unsigneds for indexes into a string.
3297
3298         No new tests because there is no behavior change.
3299
3300         * WebCore.exp.in:
3301         * platform/graphics/Font.cpp:
3302         (WebCore::Font::drawText):
3303         (WebCore::Font::drawEmphasisMarks):
3304         (WebCore::Font::adjustSelectionRectForText):
3305         (WebCore::computeUnderlineType):
3306         * platform/graphics/Font.h:
3307         * platform/graphics/FontFastPath.cpp:
3308         (WebCore::Font::getGlyphsAndAdvancesForSimpleText):
3309         (WebCore::Font::drawSimpleText):
3310         (WebCore::Font::drawEmphasisMarksForSimpleText):
3311         (WebCore::Font::drawGlyphBuffer):
3312         (WebCore::Font::drawEmphasisMarks):
3313         (WebCore::Font::adjustSelectionRectForSimpleText):
3314         * platform/graphics/GlyphBuffer.h:
3315         (WebCore::GlyphBuffer::size):
3316         (WebCore::GlyphBuffer::glyphs):
3317         (WebCore::GlyphBuffer::advances):
3318         (WebCore::GlyphBuffer::fontDataAt):
3319         (WebCore::GlyphBuffer::advanceAt):
3320         (WebCore::GlyphBuffer::offsetAt):
3321         (WebCore::GlyphBuffer::reverse):
3322         (WebCore::GlyphBuffer::offsetInString):
3323         (WebCore::GlyphBuffer::swap):
3324         * platform/graphics/GraphicsContext.cpp:
3325         (WebCore::TextRunIterator::atEnd):
3326         * platform/graphics/Latin1TextIterator.h:
3327         (WebCore::Latin1TextIterator::Latin1TextIterator):
3328         (WebCore::Latin1TextIterator::currentCharacter):
3329         * platform/graphics/SimpleFontData.h:
3330         * platform/graphics/SurrogatePairAwareTextIterator.cpp:
3331         (WebCore::SurrogatePairAwareTextIterator::SurrogatePairAwareTextIterator):
3332         * platform/graphics/SurrogatePairAwareTextIterator.h:
3333         (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
3334         * platform/graphics/TextRun.h:
3335         (WebCore::TextRun::length):
3336         (WebCore::TextRun::charactersLength):
3337         * platform/graphics/WidthIterator.cpp:
3338         (WebCore::WidthIterator::glyphDataForCharacter):
3339         (WebCore::applyFontTransforms):
3340         (WebCore::WidthIterator::advanceInternal):
3341         (WebCore::WidthIterator::advance):
3342         (WebCore::WidthIterator::advanceOneCharacter):
3343         * platform/graphics/WidthIterator.h:
3344         * platform/graphics/cairo/FontCairo.cpp:
3345         (WebCore::Font::drawGlyphs):
3346         * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
3347         (WebCore::Font::drawComplexText):
3348         (WebCore::Font::drawEmphasisMarksForComplexText):
3349         (WebCore::Font::adjustSelectionRectForComplexText):
3350         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
3351         (WebCore::HarfBuzzShaper::setNormalizedBuffer):
3352         * platform/graphics/mac/FontComplexTextMac.cpp:
3353         (WebCore::Font::adjustSelectionRectForComplexText):
3354         (WebCore::Font::getGlyphsAndAdvancesForComplexText):
3355         (WebCore::Font::drawComplexText):
3356         (WebCore::Font::drawEmphasisMarksForComplexText):
3357         * platform/graphics/mac/FontMac.mm:
3358         (WebCore::Font::drawGlyphs):
3359         * platform/graphics/win/FontCGWin.cpp:
3360         (WebCore::Font::drawGlyphs):
3361         * platform/graphics/win/FontWin.cpp:
3362         (WebCore::Font::adjustSelectionRectForComplexText):
3363         (WebCore::Font::getGlyphsAndAdvancesForComplexText):
3364         (WebCore::Font::drawComplexText):
3365         (WebCore::Font::drawEmphasisMarksForComplexText):
3366         * platform/graphics/wince/FontWinCE.cpp:
3367         (WebCore::Font::drawGlyphs):
3368         (WebCore::Font::drawComplexText):
3369         (WebCore::Font::drawEmphasisMarksForComplexText):
3370         (WebCore::Font::selectionRectForComplexText):
3371         * rendering/InlineTextBox.cpp:
3372         (WebCore::InlineTextBox::isSelected):
3373         (WebCore::InlineTextBox::selectionState):
3374         (WebCore::adjustCharactersAndLengthForHyphen):
3375         (WebCore::InlineTextBox::localSelectionRect):
3376         (WebCore::InlineTextBox::paint):
3377         (WebCore::InlineTextBox::selectionStartEnd):
3378         (WebCore::InlineTextBox::paintSelection):
3379         (WebCore::InlineTextBox::paintCompositionBackground):
3380         (WebCore::InlineTextBox::paintDocumentMarker):
3381         (WebCore::InlineTextBox::paintTextMatchMarker):
3382         (WebCore::InlineTextBox::computeRectForReplacementMarker):
3383         (WebCore::InlineTextBox::paintCompositionUnderline):
3384         (WebCore::InlineTextBox::positionForOffset):
3385         (WebCore::InlineTextBox::constructTextRun):
3386         * rendering/InlineTextBox.h:
3387         * rendering/RenderCombineText.cpp:
3388         (WebCore::RenderCombineText::getStringToRender):
3389         * rendering/RenderCombineText.h:
3390         * rendering/svg/SVGInlineFlowBox.cpp:
3391         (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
3392         * rendering/svg/SVGInlineTextBox.cpp:
3393         (WebCore::SVGInlineTextBox::positionForOffset):
3394         (WebCore::SVGInlineTextBox::localSelectionRect):
3395         (WebCore::SVGInlineTextBox::paintSelectionBackground):
3396         (WebCore::SVGInlineTextBox::mapStartEndPositionsIntoFragmentCoordinates):
3397         (WebCore::SVGInlineTextBox::paintText):
3398         * rendering/svg/SVGInlineTextBox.h:
3399         * rendering/svg/SVGTextMetricsBuilder.cpp:
3400         (WebCore::SVGTextMetricsBuilder::currentCharacterStartsSurrogatePair):
3401         (WebCore::SVGTextMetricsBuilder::advance):
3402         * rendering/svg/SVGTextQuery.cpp:
3403         (WebCore::SVGTextQuery::mapStartEndPositionsIntoFragmentCoordinates):
3404         (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures):
3405         (WebCore::SVGTextQuery::subStringLengthCallback):
3406         (WebCore::SVGTextQuery::startPositionOfCharacterCallback):
3407         (WebCore::SVGTextQuery::endPositionOfCharacterCallback):
3408         (WebCore::SVGTextQuery::rotationOfCharacterCallback):
3409         (WebCore::SVGTextQuery::extentOfCharacterCallback):
3410         (WebCore::SVGTextQuery::characterNumberAtPositionCallback):
3411         * rendering/svg/SVGTextQuery.h:
3412         * rendering/svg/SVGTextRunRenderingContext.cpp:
3413         (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
3414         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
3415         * rendering/svg/SVGTextRunRenderingContext.h:
3416         * svg/SVGFontData.cpp:
3417         (WebCore::SVGFontData::applySVGGlyphSelection):
3418         * svg/SVGFontData.h:
3419
3420 2014-06-20  Jer Noble  <jer.noble@apple.com>
3421
3422         HTMLMediaElement seek algorithm should allow cancelling previous seeks.
3423         https://bugs.webkit.org/show_bug.cgi?id=134116
3424
3425         Reviewed by Eric Carlson.
3426
3427         Test: media/video-seek-double.html
3428
3429         Fulfill the requirement of the §4.7.14.9 seeking algorithm to do steps 5+ asynchronously and cancel
3430         previous instances of the algorithm.
3431
3432         For the html/ parts of the algorithm, implement this by adding a seek timer, which when fired will
3433         issue steps 5-12. MediaPlayerPrivateAVFoundation will already coalesce multiple seek operations, so nothing
3434         additional needs be done there.  However, MediaPlayerPrivateMediaSourceAVFObjC needs to implement the same
3435         pending seek logic in case additional seeks were issued after the html/ algorithm reached step 12.
3436
3437         * html/HTMLMediaElement.cpp:
3438         (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize the new m_seekTimer.
3439         (WebCore::HTMLMediaElement::parseAttribute): Clear the seek timer.
3440         (WebCore::HTMLMediaElement::seekInternal): Differentiate between DOM seeks and internal seeks.
3441         (WebCore::HTMLMediaElement::seekWithTolerance:) Split into the seekTimerFired() method.
3442         (WebCore::HTMLMediaElement::seekTimerFired:) Added, split from seekWithTolerance().
3443         * html/HTMLMediaElement.h:
3444         * html/MediaController.cpp:
3445         (MediaController::bringElementUpToSpeed): Call seekInternal().
3446         (WebCore::HTMLMediaElement::PendingSeek::PendingSeek): Added convenience struct for storing seek requests.
3447         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
3448         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::PendingSeek::PendingSeek): Ditto.
3449         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
3450         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC): Modify the time jumped
3451             handler to not clear the m_seeking flag if another seek request is pending.
3452         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekWithTolerance):
3453         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
3454
3455 2014-06-23  Timothy Horton  <timothy_horton@apple.com>
3456
3457         [WK2] Use the page background color instead of white when swipe snapshots were purged (134218)
3458         https://bugs.webkit.org/show_bug.cgi?id=134218
3459         <rdar://problem/17426454>
3460
3461         Reviewed by Benjamin Poulain.
3462
3463         * WebCore.exp.in:
3464
3465 2014-06-23  Eric Carlson  <eric.carlson@apple.com>
3466
3467         [iOS] remove InbandTextTrackPrivateAVFIOS
3468         https://bugs.webkit.org/show_bug.cgi?id=134220
3469
3470         Reviewed by Benjamin Poulain.
3471
3472         * WebCore.xcodeproj/project.pbxproj: Remove references to InbandTextTrackPrivateAVFIOS.
3473
3474         * platform/graphics/ios/InbandTextTrackPrivateAVFIOS.h: Removed.
3475         * platform/graphics/ios/InbandTextTrackPrivateAVFIOS.mm: Removed.
3476
3477 2014-06-23  Commit Queue  <commit-queue@webkit.org>
3478
3479         Unreviewed, rolling out r170323.
3480         https://bugs.webkit.org/show_bug.cgi?id=134224
3481
3482         lots of build breakage (Requested by bradeeoh on #webkit).
3483
3484         Reverted changeset:
3485
3486         "[Mac] process raw VTT in-band captions"
3487         https://bugs.webkit.org/show_bug.cgi?id=134178
3488         http://trac.webkit.org/changeset/170323
3489
3490 2014-06-23  Jeffrey Pfau  <jpfau@apple.com>
3491
3492         Fix release build
3493
3494         * Modules/indexeddb/IDBTransactionCoordinator.cpp:
3495         (WebCore::IDBTransactionCoordinator::canRunTransaction):
3496
3497 2014-06-19  Jeffrey Pfau  <jpfau@apple.com>
3498
3499         Database process crashes when multiple transactions attempt to run at once
3500         https://bugs.webkit.org/show_bug.cgi?id=134139
3501
3502         Reviewed by David Kilzer.
3503
3504         Ensure that only one transaction can be running at a time.
3505
3506         Test: storage/indexeddb/transaction-overlapping.html
3507
3508         * Modules/indexeddb/IDBTransactionCoordinator.cpp:
3509         (WebCore::IDBTransactionCoordinator::canRunTransaction):
3510
3511 2014-06-23  Benjamin Poulain  <bpoulain@apple.com>
3512
3513         [iOS][WK2] Make the state restore from HistoryItem more precise and reliable
3514         https://bugs.webkit.org/show_bug.cgi?id=134150
3515
3516         Reviewed by Tim Horton.
3517
3518         The two biggest changes for WebCore are:
3519         -Store everything we need to handle changes of ViewportConfiguration on HistoryItem.
3520         -Store the exposedRect with floating point coordinates.
3521
3522         * WebCore.exp.in:
3523         * history/CachedPage.cpp:
3524         (WebCore::CachedPage::restore):
3525         We cannot determine a good scroll position from the WebProcess because the obscured insets can change
3526         arbitrarily in the UIProcess. When we scroll here from the WebProcess, we would force an invalid position
3527         to the UIProcess with the next layer tree update.
3528
3529         To avoid any problem, we prohibit scrolling when restoring the focus appearance.
3530
3531         * history/HistoryItem.cpp:
3532         (WebCore::encodeRect):
3533         (WebCore::encodeSize):
3534         (WebCore::HistoryItem::encodeBackForwardTreeNode):
3535         (WebCore::decodeRect):
3536         (WebCore::decodeSize):
3537         (WebCore::HistoryItem::decodeBackForwardTree):
3538         * history/HistoryItem.h:
3539         (WebCore::HistoryItem::exposedContentRect):
3540         (WebCore::HistoryItem::setExposedContentRect):
3541         (WebCore::HistoryItem::unobscuredContentRect):
3542         (WebCore::HistoryItem::setUnobscuredContentRect):
3543         (WebCore::HistoryItem::minimumLayoutSizeInScrollViewCoordinates):
3544         (WebCore::HistoryItem::setMinimumLayoutSizeInScrollViewCoordinates):
3545         (WebCore::HistoryItem::contentSize):
3546         (WebCore::HistoryItem::setContentSize):
3547         (WebCore::HistoryItem::exposedContentPosition): Deleted.
3548         (WebCore::HistoryItem::setExposedContentPosition): Deleted.
3549         * loader/HistoryController.cpp:
3550         (WebCore::HistoryController::saveScrollPositionAndViewStateToItem):
3551         * page/FrameView.h:
3552         * platform/ScrollView.h:
3553         * platform/ios/ScrollViewIOS.mm:
3554         (WebCore::ScrollView::exposedContentRect):
3555         (WebCore::ScrollView::setExposedContentRect):
3556         * rendering/RenderLayerCompositor.cpp:
3557         (WebCore::RenderLayerCompositor::didChangeVisibleRect):
3558
3559 2014-06-23  Eric Carlson  <eric.carlson@apple.com>
3560
3561         [Mac] process raw VTT in-band captions
3562         https://bugs.webkit.org/show_bug.cgi?id=134178
3563
3564         Reviewed by Jer Noble.
3565
3566         * CMakeLists.txt: Add ISOVTTCue.cpp|h.
3567         * WebCore.vcxproj/WebCore.vcxproj: Ditto.
3568         * WebCore.xcodeproj/project.pbxproj: Ditto.
3569
3570         * html/track/BufferedLineReader.h:
3571         (WebCore::BufferedLineReader::reset): New, empty the input buffer.
3572
3573         Make it possible to process WebVTT captions. 
3574         * html/track/InbandGenericTextTrack.cpp:
3575         (WebCore::InbandGenericTextTrack::parser): Allocate, if necessary, and return a WebVTT parser.
3576         (WebCore::InbandGenericTextTrack::parseWebVTTCueData): Pass a cue to the parser.
3577         (WebCore::InbandGenericTextTrack::parseWebVTTFileHeader): Pass a VTT file header to the parser.
3578         (WebCore::InbandGenericTextTrack::newCuesParsed): Parser callback.
3579         (WebCore::InbandGenericTextTrack::newRegionsParsed): Ditto.
3580         (WebCore::InbandGenericTextTrack::fileFailedToParse): Ditto.
3581         * html/track/InbandGenericTextTrack.h:
3582
3583         * html/track/InbandTextTrack.h:
3584
3585         * html/track/InbandWebVTTTextTrack.cpp:
3586         (WebCore::InbandWebVTTTextTrack::parser): New, parser accessor.
3587         (WebCore::InbandWebVTTTextTrack::parseWebVTTCueData): New, parse VTT data in an ISOWebVTTCue
3588             object.
3589         (WebCore::InbandWebVTTTextTrack::newCuesParsed): Cleanup.
3590         (WebCore::InbandWebVTTTextTrack::newRegionsParsed): Implement.
3591         (WebCore::InbandWebVTTTextTrack::fileFailedToParse): Change the error message.
3592         * html/track/InbandWebVTTTextTrack.h:
3593
3594         * html/track/TextTrackCueGeneric.cpp:
3595         (WebCore::TextTrackCueGenericBoxElement::TextTrackCueGenericBoxElement): Change cue parameter
3596             from a pointer to a reference.
3597         (WebCore::TextTrackCueGeneric::createDisplayTree): Ditto.
3598
3599         * html/track/VTTCue.cpp:
3600         (WebCore::VTTCueBox::create): Change cue parameter from a pointer to a reference.
3601         (WebCore::VTTCueBox::VTTCueBox): Ditto.
3602         (WebCore::VTTCueBox::getCue): Return a reference.
3603         (WebCore::VTTCueBox::applyCSSProperties): m_cue is a reference, not a pointer.
3604         (WebCore::VTTCue::create): New, create a VTTCue from WebVTTCueData.
3605         (WebCore::VTTCue::VTTCue): New, internal constructor that takes a WebVTTCueData.
3606         (WebCore::VTTCue::initialize): New, shared constructor initialization.
3607         (WebCore::VTTCue::createDisplayTree): m_cue is a reference, not a pointer.
3608         (WebCore::VTTCue::markFutureAndPastNodes): Ditto.
3609         (WebCore::VTTCue::setCueSettings): Ditto.
3610         * html/track/VTTCue.h:
3611         (WebCore::VTTCueBox::create): Deleted.
3612         (WebCore::VTTCue::create): Deleted.
3613
3614         * html/track/WebVTTParser.cpp:
3615         (WebCore::WebVTTParser::parseFileHeader): New. Reset the line reader buffer and parser state, 
3616             call the parser.
3617         (WebCore::WebVTTParser::parseCueData): Create a cue from ISOWebVTTCue.
3618         (WebCore::WebVTTParser::collectTimingsAndSettings): Return immediately if the string is empty.
3619         (WebCore::WebVTTParser::collectTimeStamp): Ditto.
3620         * html/track/WebVTTParser.h:
3621         (WebCore::WebVTTCueData::originalStartTime): New.
3622         (WebCore::WebVTTCueData::setOriginalStartTime): New.
3623         (WebCore::WebVTTCueData::WebVTTCueData):
3624
3625         * loader/TextTrackLoader.cpp:
3626         (WebCore::TextTrackLoader::getNewCues): Cleanup, use the new VTTCue::create.
3627
3628         * platform/graphics/InbandTextTrackPrivateClient.h:
3629         (WebCore::InbandTextTrackPrivateClient::parseWebVTTFileHeader): New.
3630
3631         Parse ISO WebVTT cue boxes.
3632         * platform/graphics/ISOVTTCue.cpp: Added.
3633         (WebCore::ISOBox::ISOBox):
3634         (WebCore::ISOBox::peekType):
3635         (WebCore::ISOBox::peekLength):
3636         (WebCore::ISOBox::peekString):
3637         (WebCore::vttCueBoxType):
3638         (WebCore::vttIdBoxType):
3639         (WebCore::vttSettingsBoxType):
3640         (WebCore::vttPayloadBoxType):
3641         (WebCore::vttCurrentTimeBoxType):
3642         (WebCore::vttCueSourceIDBoxType):
3643         (WebCore::ISOWebVTTCue::boxType):
3644         (WebCore::ISOWebVTTCue::ISOWebVTTCue):
3645         * platform/graphics/ISOVTTCue.h: Added.
3646         (WebCore::ISOBox::boxHeaderSize):
3647         (WebCore::ISOBox::length):
3648         (WebCore::ISOBox::type):
3649         (WebCore::ISOWebVTTCue::presentationTime):
3650         (WebCore::ISOWebVTTCue::duration):
3651         (WebCore::ISOWebVTTCue::sourceID):
3652         (WebCore::ISOWebVTTCue::id):
3653         (WebCore::ISOWebVTTCue::originalStartTime):
3654         (WebCore::ISOWebVTTCue::settings):
3655         (WebCore::ISOWebVTTCue::cueText):
3656
3657         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
3658         (WebCore::InbandTextTrackPrivateAVF::InbandTextTrackPrivateAVF): Add a cue format parameter.
3659         (WebCore::InbandTextTrackPrivateAVF::processCue): Call processNativeSamples.
3660         (WebCore::InbandTextTrackPrivateAVF::processAttributedStrings): Add logging. Minor cleanup.
3661         (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): New, process an array of 
3662             CMSampleBuffers, create ISOWebVTTCue from the sample data.
3663         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
3664
3665         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
3666         (WebCore::InbandTextTrackPrivateAVFObjC::create): Add a cue format parameter.
3667         * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
3668         (WebCore::InbandTextTrackPrivateAVFObjC::InbandTextTrackPrivateAVFObjC): Ditto.
3669
3670         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
3671         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3672         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Improve logging.
3673         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Don't leak an NSDictionary.
3674         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Don't process media selection
3675             options until we have tracks.
3676         (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions): 
3677         (WebCore::MediaPlayerPrivateAVFoundationObjC::processCue): Pass native samples as well as 
3678             attributed strings to track.
3679         (-[WebCoreAVFMovieObserver legibleOutput:didOutputAttributedStrings:nativeSampleBuffers:forItemTime:]):
3680         * platform/graphics/avfoundation/objc/OutOfBandTextTrackPrivateAVF.h:
3681         (WebCore::OutOfBandTextTrackPrivateAVF::OutOfBandTextTrackPrivateAVF):
3682
3683         * platform/graphics/avfoundation/InbandTextTrackPrivateLegacyAVFObjC.cpp:
3684         (WebCore::InbandTextTrackPrivateLegacyAVFObjC::InbandTextTrackPrivateLegacyAVFObjC): Pass cue
3685             format to base class.
3686
3687         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.cpp:
3688         (WebCore::InbandTextTrackPrivateAVCF::InbandTextTrackPrivateAVCF): Ditto.
3689         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.h:
3690
3691 2014-06-23  Jer Noble  <jer.noble@apple.com>
3692
3693         [MSE][Mac] Crash in SourceBuffer::sourceBufferPrivateDidReceiveRenderingError()
3694         https://bugs.webkit.org/show_bug.cgi?id=134211
3695
3696         Reviewed by Eric Carlson.
3697
3698         Null-check m_source before dereferencing, as the SourceBuffer may have been removed
3699         from its MediaSource before this error was received.
3700
3701         * Modules/mediasource/SourceBuffer.cpp:
3702         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveRenderingError):
3703
3704 2014-06-23  Joseph Pecoraro  <pecoraro@apple.com>
3705
3706         Reduce synchronous layout triggered by JavaScript-based media controls
3707         https://bugs.webkit.org/show_bug.cgi?id=134208
3708
3709         Reviewed by Eric Carlson.
3710
3711         Avoid always querying the offsetWidth and offsetHeight of the timeline
3712         by only calculating these values when the timeline may change size.
3713         Also avoid doing work in a few cases where properties did not
3714         actually change.
3715
3716         * Modules/mediacontrols/mediaControlsApple.js:
3717         (Controller):
3718
3719         (Controller.prototype.setNeedsTimelineMetricsUpdate):
3720         (Controller.prototype.updateTimelineMetricsIfNeeded):
3721         Only update the timeline metrics when they may have changed.
3722
3723         (Controller.prototype.updateControls):
3724         (Controller.prototype.handleTimelineMouseMove):
3725         (Controller.prototype.progressFillStyle):
3726         (Controller.prototype.showControls):
3727         (Controller.prototype.addControls):
3728         Mark timeline metrics need update based on various UI changes.
3729
3730         (Controller.prototype.setStatusHidden):
3731         Only do work if the hidden status changed.
3732         Mark timeline metrics need update if the timeline is changed.
3733
3734         (Controller.prototype.updateProgress):
3735         Use cached timeline metrics instead of always querying offsetWidth/offsetHeight.
3736
3737         * Modules/mediacontrols/mediaControlsiOS.js:
3738         (ControllerIOS):
3739         (ControllerIOS.prototype.updateControls):
3740
3741         (ControllerIOS.prototype.updateProgress):
3742         Use cached timeline metrics instead of always querying offsetWidth/offsetHeight.
3743
3744         (ControllerIOS.prototype.handleWirelessPlaybackChange):
3745         Mark timeline metrics need update as button may have changed.
3746
3747         (ControllerIOS.prototype.handleWirelessTargetAvailableChange):
3748         Only do work if the availability changed.
3749         Mark timeline metrics need update as a new button may have appeared.
3750
3751         (ControllerIOS.prototype.set pageScaleFactor):
3752         Only do work if the page scale factor changed.
3753
3754 2014-06-23  Brady Eidson  <beidson@apple.com>
3755
3756         Add skeleton code for updated Gamepad API
3757         https://bugs.webkit.org/show_bug.cgi?id=134165
3758
3759         Unreviewed - Forgotten review feedback from http://trac.webkit.org/changeset/170309
3760
3761         * Modules/gamepad/GamepadButton.idl: Forgot to commit the removal of NoInterfaceObject here.
3762
3763 2014-06-23  Brady Eidson  <beidson@apple.com>
3764
3765         Add skeleton code for updated Gamepad API
3766         https://bugs.webkit.org/show_bug.cgi?id=134165
3767
3768         Reviewed by Dean Jackson.
3769
3770         No new tests (No change in behavior for any tested configuration)
3771
3772         Interface and dummy implementation for the Gamepad object:
3773         * Modules/gamepad/Gamepad.cpp: Added.
3774         (WebCore::Gamepad::Gamepad):
3775         (WebCore::Gamepad::~Gamepad):
3776         (WebCore::Gamepad::axes):
3777         (WebCore::Gamepad::buttons):
3778         * Modules/gamepad/Gamepad.h: Added.
3779         * Modules/gamepad/Gamepad.idl: Added.
3780
3781         Interface and dummy implementation for the GamepadButton object:
3782         * Modules/gamepad/GamepadButton.cpp: Added.
3783         (WebCore::GamepadButton::GamepadButton):
3784         (WebCore::GamepadButton::pressed):
3785         * Modules/gamepad/GamepadButton.h: Added.
3786         (WebCore::GamepadButton::create):
3787         (WebCore::GamepadButton::value):
3788         (WebCore::GamepadButton::setValue):
3789         * Modules/gamepad/GamepadButton.idl: Added.
3790
3791         Interface and dummy implementation for the GamepadEvent object:
3792         * Modules/gamepad/GamepadEvent.cpp: Added.
3793         (WebCore::GamepadEvent::GamepadEvent):
3794         * Modules/gamepad/GamepadEvent.h: Added.
3795         (WebCore::GamepadEventInit::GamepadEventInit):
3796         (WebCore::GamepadEvent::~GamepadEvent):
3797         (WebCore::GamepadEvent::create):
3798         (WebCore::GamepadEvent::gamepad):
3799         * Modules/gamepad/GamepadEvent.idl: Added.
3800         * dom/EventNames.in:
3801
3802         Interface and dummy implementation for additions to the Navigator object:
3803         * Modules/gamepad/NavigatorGamepad.cpp: Added.
3804         (WebCore::NavigatorGamepad::NavigatorGamepad):
3805         (WebCore::NavigatorGamepad::supplementName):
3806         (WebCore::NavigatorGamepad::from):
3807         (WebCore::NavigatorGamepad::getGamepads):
3808         (WebCore::NavigatorGamepad::gamepads):
3809         * Modules/gamepad/NavigatorGamepad.h: Added.
3810         * Modules/gamepad/NavigatorGamepad.idl: Added.
3811
3812         Bindings additions necessary for these new interfaces:
3813         * bindings/js/JSDOMBinding.h:
3814         (WebCore::JSValueTraits<double>::arrayJSValue):
3815         * bindings/js/JSDictionary.cpp:
3816         (WebCore::JSDictionary::convertValue):
3817         * bindings/js/JSDictionary.h:
3818
3819         Project file stuff:
3820         * CMakeLists.txt:
3821         * WebCore.vcxproj/WebCore.vcxproj:
3822         * WebCore.vcxproj/WebCoreCommon.props:
3823         * WebCore.vcxproj/copyForwardingHeaders.cmd:
3824         * WebCore.xcodeproj/project.pbxproj:
3825         * DerivedSources.make:
3826
3827 2014-06-23  Simon Fraser  <simon.fraser@apple.com>
3828
3829         Catch Obj-C exceptions thrown by _linenPatternImage
3830         https://bugs.webkit.org/show_bug.cgi?id=134202
3831
3832         Reviewed by Geoffrey Garen.
3833
3834         Catch Objective-C exceptions thrown by _linenPatternImage and
3835         -[NSImage CGImageForProposedRect:context:hints:].
3836
3837         * platform/mac/ScrollbarThemeMac.mm:
3838         (WebCore::linenBackgroundColor):
3839
3840 2014-06-23  Simon Fraser  <simon.fraser@apple.com>
3841
3842         CSS clip property should make layers non-opaque
3843         https://bugs.webkit.org/show_bug.cgi?id=134147
3844         <rdar://problem/17324579>
3845
3846         Reviewed by Tim Horton.
3847         
3848         https://www.fairphone.com has position:fixed elements with clip: rect(...)
3849         but we were making those layers opaque, resulting in garbage pixels
3850         in areas outside the clip rect.
3851         
3852         Fix by checking for the clip property in RenderBox::backgroundIsKnownToBeOpaqueInRect().
3853
3854         Test: compositing/contents-opaque/opaque-with-clip.html
3855
3856         * rendering/RenderBox.cpp:
3857         (WebCore::RenderBox::backgroundIsKnownToBeOpaqueInRect):
3858
3859 2014-06-23  Simon Fraser  <simon.fraser@apple.com>
3860
3861         Adding a mask on a simple color compositing layer removes the content
3862         https://bugs.webkit.org/show_bug.cgi?id=134127
3863
3864         Reviewed by Dean Jackson.
3865         
3866         In r169053 I moved some updateDrawsContent() into updateAfterDescendents(),
3867         but this isn't called when a composited layer gains or loses a mask (which
3868         doesn't cause a layout). This caused us to fail to allocate backing store
3869         when gaining a mask, resulting in missing content.
3870         
3871         Fix by calling updateAfterDescendents() from RenderLayer::styleChange()
3872         when the layer config isn't changing.
3873         
3874         Also remove a condition in isSimpleContainerCompositingLayer() that caused us
3875         to fall off the simple layer path for masked layers, since this works just
3876         fine.
3877
3878         Test: compositing/masks/solid-color-masked.html
3879
3880         * rendering/RenderLayer.cpp:
3881         (WebCore::RenderLayer::calculateClipRects):
3882         * rendering/RenderLayerBacking.cpp:
3883         (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
3884
3885 2014-06-23  David Hyatt  <hyatt@apple.com>
3886
3887         [New Multicolumn] Writing mode changes on the <html> and RenderView need to
3888         be propagated to column sets and flow thread children of those renderers.
3889         https://bugs.webkit.org/show_bug.cgi?id=134121
3890         <rdar://problem/16884527>
3891
3892         Reviewed by Dean Jackson.
3893
3894         Added fast/multicol/pagination/RightToLeft-rl-dynamic.html
3895
3896         * rendering/RenderBlockFlow.cpp:
3897         (WebCore::RenderBlockFlow::styleDidChange):
3898         Refactor the propagation code for column sets and flow thread styles into a helper
3899         function that is called here.
3900
3901         (WebCore::RenderBlockFlow::updateStylesForColumnChildren):
3902         * rendering/RenderBlockFlow.h:
3903         Add a new helper function for recalculating the styles of the column sets and
3904         flow thread in response to changes.
3905
3906         * rendering/RenderBox.cpp:
3907         (WebCore::RenderBox::styleDidChange):
3908         When the style is changed for a root element or the RenderView in response to
3909         writing mode and direction changes, make sure that style gets propagated to
3910         the column children by calling the new helper function.
3911
3912 2014-06-23  Jer Noble  <jer.noble@apple.com>
3913
3914         [Mac] Uncaught exception crash when destroying MediaPlayerPrivateAVFoundationObjC
3915         https://bugs.webkit.org/show_bug.cgi?id=134198
3916
3917         Reviewed by Eric Carlson.
3918
3919         Now that we always create an AVPlayerLayer when creating an AVPlayer, but we don't
3920         return that layer from platformLayer() unless we've been asked to, we no longer are
3921         asked to destroy our video layer from MediaPlayerPrivateAVFoundation::tearDownVideoRendering().
3922
3923         Instead, explicitly destroy our video layer (and remove the KVO-observer which is
3924         causing this exception) in the MediaPlayerPrivateAVFoundationObjC destructor.
3925
3926         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3927         (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC):
3928
3929 2014-06-23  Andreas Kling  <akling@apple.com>
3930
3931         Remove unused FrameView::setUseCustomFixedPositionLayoutRect().
3932         <https://webkit.org/b/134194>
3933
3934         Reviewed by Anders Carlsson.
3935
3936         * WebCore.exp.in:
3937         * page/FrameView.cpp:
3938         (WebCore::FrameView::setUseCustomFixedPositionLayoutRect): Deleted.
3939         * page/FrameView.h:
3940
3941 2014-06-23  Antti Koivisto  <antti@apple.com>
3942
3943         REGRESSION (r160908): Unable to unset bold while entering text
3944         https://bugs.webkit.org/show_bug.cgi?id=134196
3945         <rdar://problem/17051653>
3946
3947         Reviewed by Andreas Kling.
3948         
3949         No test, this code path is used by some WK1 API clients only.
3950
3951         * editing/Editor.cpp:
3952         (WebCore::Editor::styleForSelectionStart):
3953         
3954             This needs to update the style before requesting the renderer.
3955
3956         * editing/Editor.h:
3957         * editing/ios/EditorIOS.mm:
3958         (WebCore::styleForSelectionStart): Deleted.
3959         * editing/mac/EditorMac.mm:
3960         (WebCore::styleForSelectionStart): Deleted.
3961         
3962             Removed the duplicated functions, moved to Editor.cpp.
3963
3964 2014-06-23  Alex Christensen  <achristensen@webkit.org>
3965
3966         [iOS] Fix video in WebGL.
3967         https://bugs.webkit.org/show_bug.cgi?id=133511
3968
3969         Reviewed by Jer Noble.
3970
3971         * WebCore.exp.in:
3972         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
3973         (WebCore::MediaPlayerPrivateAVFoundationObjC::hasSingleSecurityOrigin):
3974         (WebCore::wkAVAssetResolvedURL): Deleted.
3975         * platform/mac/WebCoreSystemInterface.h:
3976         * platform/mac/WebCoreSystemInterface.mm:
3977         Declare and use resolvedURL on AVURLAsset instead of using wkAVAssetResolvedURL through WebKitSystemInterface.
3978
3979 2014-06-23  Radu Stavila  <stavila@adobe.com>
3980
3981         REGRESSION (r168046): Incorrect handling of object information in WebCore::RenderFlowThread::removeLineRegionInfo
3982         https://bugs.webkit.org/show_bug.cgi?id=133587
3983
3984         Reviewed by Antti Koivisto.
3985
3986         When an object flowed in multicol is moved from in-flow positioning to out-of-flow positioning,
3987         its information must be removed from the flowthread prior to the change being made. 
3988         Otherwise, the flow thread will no longer be its containing block and a reference to it
3989         will not be possible to obtain.
3990
3991         No new tests can be added because the code still hits in an unrelated assertion followed by a null dereference.
3992         The issue was discussed with Antti Koivisto and we decided its better to fix this problem first and
3993         handle the following issue in a separate bug.
3994
3995         * rendering/RenderBlockFlow.cpp:
3996         (WebCore::RenderBlockFlow::styleWillChange):
3997         * rendering/RenderObject.h:
3998         (WebCore::RenderObject::flowThreadContainingBlock):
3999
4000 2014-06-23  Krzysztof Czech  <k.czech@samsung.com>
4001
4002         [EFL] Platform support for WebSpeech feature.
4003         https://bugs.webkit.org/show_bug.cgi?id=116438
4004
4005         Reviewed by Csaba Osztrogonác.
4006
4007         It's a first step of adding support for Speech Synthesis in EFL port.
4008         Just stub out required API and support for compilation.
4009
4010         * CMakeLists.txt:
4011         * PlatformEfl.cmake:
4012         * PlatformGTK.cmake: Added some idls to not break GTK build.
4013         * platform/PlatformSpeechSynthesizer.h:
4014         * platform/efl/PlatformSpeechSynthesisProviderEfl.cpp: Added.
4015         (WebCore::PlatformSpeechSynthesisProviderEfl::PlatformSpeechSynthesisProviderEfl):
4016         (WebCore::PlatformSpeechSynthesisProviderEfl::~PlatformSpeechSynthesisProviderEfl):
4017         (WebCore::PlatformSpeechSynthesisProviderEfl::initializeVoiceList):
4018         (WebCore::PlatformSpeechSynthesisProviderEfl::pause):
4019         (WebCore::PlatformSpeechSynthesisProviderEfl::resume):
4020         (WebCore::PlatformSpeechSynthesisProviderEfl::speak):
4021         (WebCore::PlatformSpeechSynthesisProviderEfl::cancel):
4022         * platform/efl/PlatformSpeechSynthesisProviderEfl.h: Added.
4023         * platform/efl/PlatformSpeechSynthesizerEfl.cpp: Added.
4024         (WebCore::PlatformSpeechSynthesizer::PlatformSpeechSynthesizer):