12014-09-17  Matthew Hanson  <matthew_hanson@apple.com>
2
3        Merge r173664. rdar://problem/18187713
4
5    2014-09-16  Jer Noble  <jer.noble@apple.com>
6
7            Videos with controls enabled never receive 'dragstart' events.
8            https://bugs.webkit.org/show_bug.cgi?id=136837
9
10            Reviewed by Eric Carlson.
11
12            Fixes a crash regression introduced by r173631. Node::contains() has an interesting property of returning false
13            if `this` is NULL. Rather than depending on this behavior, explicitly NULL-check state.source and bail early.
14
15            * page/DragController.cpp:
16            (WebCore::DragController::startDrag):
17
182014-09-17  Matthew Hanson  <matthew_hanson@apple.com>
19
20        Merge r173632. rdar://problem/18187713
21
22    2014-09-15  Jer Noble  <jer.noble@apple.com>
23
24            Unreviewed logic fix from r173631. Logic for includeShadowDOM was reversed.
25
26            * page/DragController.cpp:
27            (WebCore::DragController::startDrag):
28
292014-09-17  Matthew Hanson  <matthew_hanson@apple.com>
30
31        Merge r173631. rdar://problem/18187713
32
33    2014-09-15  Jer Noble  <jer.noble@apple.com>
34
35            Videos with controls enabled never receive 'dragstart' events.
36            https://bugs.webkit.org/show_bug.cgi?id=136837
37
38            Reviewed by Simon Fraser.
39
40            When initiating a drag, the DragController checks whether the hit-tested element at a
41            drag location is a child of the drag source, and bails if early if that is not the case.
42            For a <video> element with controls, the hit-tested element is an element within the
43            <video> element's Shadow DOM. Because the DragController uses a method which does not
44            take Shadow DOM into account when determining a child-parent relationship, this test fails
45            and all drag operations fail as well.
46
47            For <video> elements only, when testing whether the drag source is an ancestor of the
48            hit-tested element, use containsIncludingShadowDOM() instead of contains(). To ensure that
49            the controls are still usable when a drag listener is active on a <video> element, mark
50            the controls as a draggable element, but simply call preventDefault() in the controls'
51            'dragstart' handler, ensuring the timeline and volume controls are themselves still draggable.
52
53            * Modules/mediacontrols/mediaControlsApple.css:
54            (audio::-webkit-media-controls-panel):
55            * Modules/mediacontrols/mediaControlsApple.js:
56            (Controller.prototype.createControls):
57            (Controller.prototype.handlePanelDragStart):
58            * page/DragController.cpp:
59            (WebCore::DragController::startDrag):
60
612014-09-16  Eric Carlson  <eric.carlson@apple.com>
62
63        [Mac] MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput doesn't work with rotated movies
64        https://bugs.webkit.org/show_bug.cgi?id=136872
65
66        Reviewed by Tim Horton.
67
68        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
69        (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithImageGenerator): Add logging.
70        (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput): Apply the video track
71            preferred transform.
72
732014-09-16  Dana Burkart <dburkart@apple.com>
74
75        Merge r173635
76
77    2014-09-15  Alexey Proskuryakov  <ap@apple.com>
78
79            Crash when logging in to optionshouse.com
80            https://bugs.webkit.org/show_bug.cgi?id=136834
81
82            Reviewed by Anders Carlsson.
83
84            No test, because I couldn't make one. I don't have a way to reproduce first-hand.
85
86            * platform/network/cf/SocketStreamHandleCFNet.cpp:
87            (WebCore::SocketStreamHandle::readStreamCallback):
88            (WebCore::SocketStreamHandle::writeStreamCallback):
89
902014-09-12  Lucas Forschler  <lforschler@apple.com>
91
92        Merge r173584
93
94    2014-09-12  Jer Noble  <jer.noble@apple.com>
95
96            [Fullscreen] Taking embedded youtube video full screen takes the whole page full screen
97            https://bugs.webkit.org/show_bug.cgi?id=136792
98
99            Reviewed by Beth Dakin.
100
101            Recalculate style after beginning the enter fullscreen animation, but before sending the
102            "webkitfullscreenchange" event to listeners.
103
104            * dom/Document.cpp:
105            (WebCore::Document::webkitWillEnterFullScreenForElement):
106
1072014-09-12  Lucas Forschler  <lforschler@apple.com>
108
109        Merge r173544
110
111    2014-09-11  Beth Dakin  <bdakin@apple.com>
112
113            WebKit scrollbars flash in non-dominant spaces when entering Mission Control
114            https://bugs.webkit.org/show_bug.cgi?id=136761
115            -and corresponding-
116            rdar://problem/18195616
117
118            Reviewed by Tim Horton.
119
120            This patch makes our logic about when to call ScrollableArea::contentAreaDidHide/
121            Show match the logic in AppKit. We only want these notifications when the window 
122            has become both visible and active (or lost both, in the case of hide).
123
124            Re-name setIsVisibleInternal() to setIsVisibleAndActiveInternal(), and call it 
125            only when both visibility and active-state have changed.
126            * page/FocusController.cpp:
127            (WebCore::FocusController::setViewState):
128            (WebCore::FocusController::setIsVisibleAndActiveInternal):
129            (WebCore::FocusController::setIsVisibleInternal): Deleted.
130            * page/FocusController.h:
131
132            FocusController::setViewState() is the only place that needs to call 
133            ScrollableArea::contentAreaDidHide/Show, so remove these callers.
134            * page/FrameView.cpp:
135            (WebCore::FrameView::didMoveOnscreen): Deleted.
136            (WebCore::FrameView::willMoveOffscreen): Deleted.
137            * page/FrameView.h:
138            * page/Page.cpp:
139            (WebCore::Page::setIsVisibleInternal):
140
1412014-09-12  Lucas Forschler  <lforschler@apple.com>
142
143        Merge r173533
144
145    2014-09-11  Jer Noble  <jer.noble@apple.com>
146
147            Add site-specific quirk for entering fullscreen on YouTube.com.
148            https://bugs.webkit.org/show_bug.cgi?id=136742
149
150            Reviewed by Eric Carlson.
151
152            YouTube only resizes its <video> content when entering fullscreen after receiving the "webkitfullscreenchange"
153            event, which is fired once the animation to enter fullscreen completes. This leaves the apparent <video> content
154            too small during the animation, especially at the beginning of the animation. Add a site-specific hack for
155            YouTube sites which fires the "webkitfullscreenchange" event synchronously with the beginning of the enter
156            fullscreen animation. This will cause YouTube to resize their <video> content during the period of time where we
157            disable screen updates, and makes the enter fullscreen animation seamless.
158
159            Add a static utility method, hostIsYouTube(), for the various pieces of this site-specific hack, and expand it
160            to match youtube.co.uk, youtube.fr, etc.
161
162            * dom/Document.cpp:
163            (WebCore::hostIsYouTube): Added.
164            (WebCore::Document::webkitWillEnterFullScreenForElement): Fire fullscreenchange event if hacks are enabled.
165            (WebCore::Document::webkitDidEnterFullScreenForElement): Don't fire the event if same.
166            (WebCore::Document::webkitDidExitFullScreenForElement): Use hostIsYouTube().
167
1682014-09-08  Lucas Forschler  <lforschler@apple.com>
169
170        Merge r173365
171
172    2014-09-06  Jer Noble  <jer.noble@apple.com>
173
174            [Fullscreen] Add a site-specific hack to work around "flash on exit" behavior of YouTube.com.
175            https://bugs.webkit.org/show_bug.cgi?id=136604
176
177            Reviewed by Eric Carlson.
178
179            YouTube.com will cause a "flash" of the full screen sized <video> element upon exiting full
180            screen because the "fullscreenchange" event is fired asynchronously after the exit animation
181            completes. Only YouTube sites and embeds, add a site-specific-quirk which runs the "fullscreenchange"
182            event synchronously at the end of the exit animation. This causes YouTube's video resizing logic
183            to run during the period of time where we've disabled screen updates, instead of immediately
184            after.
185
186            * dom/Document.cpp:
187            (WebCore::Document::webkitDidExitFullScreenForElement):
188
1892014-08-28  Lucas Forschler  <lforschler@apple.com>
190
191        Merge r173097
192
193    2014-08-28  Enrica Casucci  <enrica@apple.com>
194
195            Can't hit tab key more than 3 times continuously.
196            https://bugs.webkit.org/show_bug.cgi?id=136357
197            rdar://problem/17927266
198
199            Reviewed by Dean Jackson.
200
201            Test: fast/css/multiple-tabs.html
202
203            When computing the tabWidth disregard increments of less than half the size of the space character
204            for the given font.
205
206            * platform/graphics/Font.h:
207            (WebCore::Font::tabWidth):
208
2092014-08-28  Lucas Forschler  <lforschler@apple.com>
210
211        Merge r173080
212
213    2014-08-28  Pratik Solanki  <psolanki@apple.com>
214
215            WebContent hangs under SharedBuffer::duplicateDataBufferIfNecessary() while browsing some websites
216            https://bugs.webkit.org/show_bug.cgi?id=136347
217            <rdar://problem/18073745>
218
219            Reviewed by Andreas Kling.
220
221            When passing data to ImageIO, we create a copy if we have to reallocate the buffer. We would
222            set the size of the new buffer to be the size of the SharedBuffer data. This causes memory
223            churn since we would create a new buffer for every data chunk we get. Fix this by at least
224            doubling the capacity of the buffer when we duplicate it.
225
226            * platform/SharedBuffer.cpp:
227            (WebCore::SharedBuffer::duplicateDataBufferIfNecessary):
228
2292014-08-28  Lucas Forschler  <lforschler@apple.com>
230
231        Merge r173067
232
233    2014-08-28  Chris Fleizach  <cfleizach@apple.com>
234
235            AX: Safari at com.apple.WebCore: WebCore::AXObjectCache::clearTextMarkerNodesInUse
236            https://bugs.webkit.org/show_bug.cgi?id=136333
237
238            Reviewed by David Kilzer.
239
240            If a Node is asked for it's Document when it's not actually in a document, it can lead to an assert/crash.
241            We can avoid this by checking that the node is in a document before asking for its document.
242
243            I was not able to make a test case.      
244
245            * accessibility/AXObjectCache.cpp:
246            (WebCore::AXObjectCache::clearTextMarkerNodesInUse):
247
2482014-08-28  Lucas Forschler  <lforschler@apple.com>
249
250        Merge r173028
251
252    2014-08-27  Andreas Kling  <akling@apple.com>
253
254            Drawing text in an SVG font causes load events to be fired.
255            <https://webkit.org/b/136269>
256            <rdar://problem/15724915>
257
258            Don't flush pending load events in Document::implicitClose() for frameless documents.
259            This is a targeted fix for an issue where parsing SVG fonts during layout would cause
260            event dispatch to happen in the main document, leading to arbitrary JS execution.
261
262            Note that the testcase only works in DRT/WTR, since once the SVG font is in cached
263            by WebCore, we won't reparse it again. Caches are cleared between tests, so it will
264            correctly fail if this should regress.
265
266            Longer-term, we should clean this up and get rid of the global dispatch entirely.
267
268            Reviewed by Simon Fraser.
269
270            Test: fast/text/svg-font-trigger-load-event.html
271
272            * dom/Document.cpp:
273            (WebCore::Document::implicitClose):
274
2752014-08-28  Lucas Forschler  <lforschler@apple.com>
276
277        Merge r173016
278
279    2014-08-27  Timothy Hatcher  <timothy@apple.com>
280
281            Web Inspector: Crash when you open Web Inspector in a private window (due to IndexedDB)
282            https://bugs.webkit.org/show_bug.cgi?id=136293
283
284            Reviewed by Joseph Pecoraro.
285
286            * inspector/InspectorIndexedDBAgent.cpp:
287            (WebCore::InspectorIndexedDBAgent::requestDatabaseNames): Null check idbRequest from
288            IDBFactory::getDatabaseNames, which can return null now after r172603 in private browsing.
289
2902014-08-28  Lucas Forschler  <lforschler@apple.com>
291
292        Merge r172871
293
294    2014-08-22  Dean Jackson  <dino@apple.com>
295
296            Google Canvas2D maps are too slow and uncontrollable with Safari with full screen mode
297            https://bugs.webkit.org/show_bug.cgi?id=136168
298
299            Reviewed by Tim Horton.
300
301            When Google maps are using their 2D "lite" fallback and you're drawing in a huge
302            window such as fullscreen 4K, we would drop back to unaccelerated mode, thinking
303            that we'd exceeded the maximum IOSurface size.
304
305            Remove the hardcoded limit on IOSurface sizes, and instead ask the system
306            what it believe the maximum to be. This was significantly higher than our
307            limit on the systems I tested.
308
309            * platform/graphics/cg/ImageBufferCG.cpp:
310            (WebCore::ImageBuffer::ImageBuffer): Include our IOSurface wrapper, which
311            has a query for maximum size, and use that instead.
312
3132014-08-26  Dana Burkart  <dburkart@apple.com>
314
315        Merge r172977. <rdar://problem/18141703>
316
317    2014-08-26  Brent Fulgham  <bfulgham@apple.com>
318    
319            [Win] WebKit IDL incorrectly passes HWND as OLE_HANDLE
320            https://bugs.webkit.org/show_bug.cgi?id=136258
321            <rdar://problem/18134138>
322    
323            Reviewed by Tim Horton.
324    
325            Avoid 32/64-bit truncation by preventing 64-bit HWND (and other)
326            values from passing through the 32-bit OLE_HANDLE data type.
327    
328            * platform/win/WindowMessageBroadcaster.cpp:
329            (WebCore::WindowMessageBroadcaster::addListener):
330            (WebCore::WindowMessageBroadcaster::removeListener):
331            (WebCore::WindowMessageBroadcaster::destroy):
332            (WebCore::WindowMessageBroadcaster::unsubclassWindow):
333            (WebCore::WindowMessageBroadcaster::SubclassedWndProc):
334    
3352014-08-26  Dana Burkart  <dburkart@apple.com>
336
337        Merge r172969. <rdar://problem/17435564>
338
339    2014-08-26  Simon Fraser  <simon.fraser@apple.com>
340    
341            Ensure that layout is up-to-date before hit testing
342            https://bugs.webkit.org/show_bug.cgi?id=136242
343            rdar://problem/17435564
344    
345            Reviewed by Tim Horton.
346            
347            Various code paths can call into RenderView::hitTest() but fail to
348            ensure that layout is up-to-date. This is a conservative change that
349            fixes the issue for callers of EventHandler::hitTestResultAtPoint(),
350            including WebPage::acceptsFirstMouse() and WebFrame::hitTest().
351            
352            This change is not general enough that we can ASSERT(!needsLayout())
353            in RenderView::hitTest() yet.
354            
355            * page/EventHandler.cpp:
356            (WebCore::EventHandler::hitTestResultAtPoint):
357    
3582014-08-22  Lucas Forschler  <lforschler@apple.com>
359
360        Merge r172854
361
362    2014-08-21  Antti Koivisto  <antti@apple.com>
363
364            Animated GIFs scrolled out of view still cause titlebar blur to update, on tumblr.com page
365            https://bugs.webkit.org/show_bug.cgi?id=136139
366
367            Reviewed by Simon Fraser.
368
369            The mechanism for pausing GIF images outside the viewport did not work for subframes.
370
371            Test: fast/repaint/no-animation-outside-viewport-subframe.html
372
373            * WebCore.exp.in:
374            * page/FrameView.cpp:
375            (WebCore::FrameView::scrollPositionChanged):
376            (WebCore::FrameView::resumeVisibleImageAnimationsIncludingSubframes):
377
378                Add a function for resuming animations as needed in all subframes.
379                This is used after scrolling instead of calling the RenderView function directly.
380
381            * page/FrameView.h:
382            * page/Page.cpp:
383            (WebCore::Page::resumeAnimatingImages):
384            * rendering/RenderElement.cpp:
385            (WebCore::RenderElement::newImageAnimationFrameAvailable):
386
387                Determine the overall visible rect so that it is correct in subframes too.
388
389            * rendering/RenderLayer.cpp:
390            (WebCore::RenderLayer::scrollTo):
391            * rendering/RenderView.cpp:
392            (WebCore::RenderView::resumePausedImageAnimationsIfNeeded):
393
3942014-08-21  Matthew Hanson  <matthew_hanson@apple.com>
395
396        Merge r172841. <rdar://problem/17733682>
397
398    2014-08-21  Brent Fulgham  <bfulgham@apple.com>
399    
400            [Win] WebCore.proj is not copying WebKit resource files.
401            https://bugs.webkit.org/show_bug.cgi?id=136142
402            <rdar://problem/17733682>
403    
404            Reviewed by Tim Horton.
405    
406            * WebCore.vcxproj/WebCore.proj: Copy missing resource files during
407            post-build step.
408    
4092014-08-19  Dana Burkart  <dburkart@apple.com>
410
411        Merge r172317. <rdar://problem/18052514>
412
413    2014-08-07  Simon Fraser  <simon.fraser@apple.com>
414    
415            HTML <sub> and <sup> elements do not work in some 64-bit builds
416            https://bugs.webkit.org/show_bug.cgi?id=135736
417    
418            Reviewed by Tim Horton.
419            
420            RootInlineBox::verticalPositionForBox() had some implicit conversions between
421            LayoutUnit and int that caused overflow, and resulted in different comparison
422            behavior with an int constant in different architectures, since overflow behavior
423            is undefined.
424            
425            Specifically, VerticalPositionCache was written in terms of ints with a special
426            0x80000000 "not found" value. However, 0x80000000 was being assigned to
427            a LayoutUnit, which multiplies by 64 causing overflow. The result was then
428            compared again with 0x80000000 which could pass or fail depending on overflow
429            behavior.
430            
431            Fix by converting VerticalPositionCache to use LayoutUnits, and to have a bool
432            return value with a result out param, instead of a special return value.
433    
434            Not easily testable, since the difference does not show in DRT output,
435            and a ref test would be flakey.
436    
437            * rendering/RootInlineBox.cpp:
438            (WebCore::RootInlineBox::ascentAndDescentForBox):
439            * rendering/VerticalPositionCache.h:
440            (WebCore::VerticalPositionCache::get):
441            (WebCore::VerticalPositionCache::set):
442    
4432014-08-19  Dana Burkart  <dburkart@apple.com>
444
445        Merge r172720. <rdar://problem/17767169>
446
447    2014-08-18  Brent Fulgham  <bfulgham@apple.com>
448    
449            [Mac] Unreviewed merge correction.
450    
451            * page/mac/EventHandlerMac.mm:
452            (WebCore::EventHandler::platformCompleteWheelEvent): Revert an
453            unintended change from r172705.
454    
4552014-08-19  Dana Burkart  <dburkart@apple.com>
456
457        Merge r172709. <rdar://problem/17850158>
458
459    2014-08-18  Andy Estes  <aestes@apple.com>
460    
461            REGRESSION (r167856): adobe.com no longer able to launch Create Cloud app using a URL with a custom scheme
462            https://bugs.webkit.org/show_bug.cgi?id=136010
463    
464            Reviewed by Darin Adler.
465    
466            r167856 caused WebKit to stop scheduling certain kinds of navigations (window.location changes, meta-refresh,
467            and some calls to window.open) when the request URL is invalid. Adobe.com performs one of these navigations to
468            an invalid URL with an external scheme (aam:), relying on Safari's navigation policy delegate to ignore the
469            navigation and launch the external app registered to handle aam: URLs. Since the navigation is no longer
470            scheduled, the policy delegate is never executed and the external app never launches.
471    
472            Instead of not scheduling the navigation, allow it to proceed until the client's policy delegate has executed
473            and made a decision. Only disallow the navigation if the policy delegate told WebKit to proceed with the load.
474            This exposes these navigations to clients via the policy delegate and via willPerformClientRedirectToURL and
475            didCancelClientRedirectForFrame on the frame load delegate.
476            
477            To constrain this check only to the navigation types covered by r167856, only two NavigationSchedulers
478            (ScheduledRedirect and ScheduledLocationChange) enable the invalid URL check.
479    
480            Note that r167856 also caused an iOS regression, and this was resolved in r170120 by adding a linked-on-or-after
481            check and a WebCore setting. Since the iOS regression is also resolved by the approach described above, this
482            patch reverts r170120 (but keeps some of its tests).
483    
484            Tests: fast/loader/redirect-to-invalid-url-using-javascript-calls-policy-delegate.html
485                   fast/loader/redirect-to-invalid-url-using-javascript-disallowed.html
486                   fast/loader/redirect-to-invalid-url-using-meta-refresh-calls-policy-delegate.html
487                   fast/loader/redirect-to-invalid-url-using-meta-refresh-disallowed.html
488                   fast/loader/window-open-to-invalid-url-calls-policy-delegate.html
489                   fast/loader/window-open-to-invalid-url-disallowed.html
490    
491            * WebCore.exp.in: Updated the symbol FrameLoader::loadFrameRequest.
492            * loader/FrameLoader.cpp:
493            (WebCore::FrameLoader::changeLocation): Added an AllowNavigationToInvalidURL argument; passed down to urlSelected.
494            (WebCore::FrameLoader::urlSelected): Added an AllowNavigationToInvalidURL argument; passed down to loadFrameRequest.
495            (WebCore::FrameLoader::loadURLIntoChildFrame): Passed AllowNavigationToInvalidURL::Yes to loadURL.
496            (WebCore::FrameLoader::loadFrameRequest): Added an AllowNavigationToInvalidURL argument; passed down to loadURL and loadPostRequest.
497            (WebCore::FrameLoader::loadURL): Added an AllowNavigationToInvalidURL argument; passed down to continueLoadAfterNewWindowPolicy and loadWithNavigationAction.
498            (WebCore::FrameLoader::loadPostRequest): Ditto.
499            (WebCore::FrameLoader::load): Passed AllowNavigationToInvalidURL::Yes to continueLoadAfterNewWindowPolicy.
500            (WebCore::FrameLoader::loadWithNavigationAction): Added an AllowNavigationToInvalidURL argument; passed down to loadWithDocumentLoader.
501            (WebCore::FrameLoader::loadWithDocumentLoader): Added an AllowNavigationToInvalidURL argument; passed down to continueLoadAfterNavigationPolicy.
502            (WebCore::FrameLoader::reloadWithOverrideEncoding): Passed AllowNavigationToInvalidURL::Yes to loadWithDocumentLoader.
503            (WebCore::FrameLoader::reload): Ditto.
504            (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
505                Added an AllowNavigationToInvalidURL argument; if its value is No and the request's URL is invalid, do not continue.
506                Added a FIXME about calling clientRedirectCancelledOrFinished on non-quick redirect cancellations.
507            (WebCore::FrameLoader::continueLoadAfterNewWindowPolicy): Added an AllowNavigationToInvalidURL argument; passed down to loadWithNavigationAction.
508            (WebCore::FrameLoader::loadDifferentDocumentItem): Passed AllowNavigationToInvalidURL::Yes to either loadWithDocumentLoader or loadWithNavigationAction.
509            * loader/FrameLoader.h:
510            * loader/FrameLoaderTypes.h: Defined AllowNavigationToInvalidURL to have values of Yes and No.
511            * loader/NavigationScheduler.cpp:
512            (WebCore::ScheduledRedirect::fire): Passed AllowNavigationToInvalidURL::No to FrameLoader::changeLocation.
513            (WebCore::ScheduledLocationChange::fire): Ditto.
514            (WebCore::NavigationScheduler::shouldScheduleNavigation): Removed the URL::isValid check.
515            (WebCore::NavigationScheduler::scheduleLocationChange): Passed AllowNavigationToInvalidURL::No to FrameLoder::changeLocation during fragment navigations.
516            * page/ContextMenuController.cpp:
517            (WebCore::openNewWindow): Passed AllowNavigationToInvalidURL::Yes to FrameLoader::loadFrameRequest.
518            (WebCore::ContextMenuController::contextMenuItemSelected): Ditto.
519            * page/Settings.in: Removed allowNavigationToInvalidURL.
520    
5212014-08-19  Dana Burkart  <dburkart@apple.com>
522
523        Merge r172705. <rdar://problem/17767169>
524
525    2014-08-18  Brent Fulgham  <bfulgham@apple.com>
526    
527            [Mac] Follow-up to r136040 based on Darin Adler's comments.
528    
529            Pass Widget* as a Widget&, since it can never be null.
530    
531            * page/EventHandler.cpp:
532            (WebCore::EventHandler::platformCompletePlatformWidgetWheelEvent):
533            (WebCore::EventHandler::handleWheelEvent):
534            * page/EventHandler.h:
535            * page/mac/EventHandlerMac.mm:
536            (WebCore::EventHandler::platformCompleteWheelEvent):
537            (WebCore::EventHandler::platformCompletePlatformWidgetWheelEvent):
538    
5392014-08-19  Dana Burkart  <dburkart@apple.com>
540
541        Merge r172703. <rdar://problem/17767169>
542
543    2014-08-17  Brent Fulgham  <bfulgham@apple.com>
544    
545            [Mac] Gesture scrolls don't work in the WebKit1 clients after scrolling a non-scrollable iFrame
546            https://bugs.webkit.org/show_bug.cgi?id=136029
547            <rdar://problem/17767169>
548    
549            Reviewed by Maciej Stachowiak.
550    
551            This is difficult to test in our layout tests, since it relies on specific host application
552            behavior.
553    
554            If the platform widget is a frame view (IFrame), and we are in WebKit1, 'passWheelEventToWidget'
555            has already called 'scrollWheel' on the underlying platform widget. We need to return true in
556            this case to avoid getting multiple copies of the scrollWheel event sent to the platform widget.
557    
558            * page/EventHandler.cpp:
559            (WebCore::EventHandler::platformCompletePlatformWidgetWheelEvent): Revise default stub to
560            accept a Widget* argument.
561            (WebCore::EventHandler::handleWheelEvent):
562            * page/EventHandler.h:
563            * page/mac/EventHandlerMac.mm:
564            (WebCore::EventHandler::platformCompletePlatformWidgetWheelEvent): Check for WK1 case and
565            return 'true' when the underlying NSScrollView has been issues a scrollWheel event.
566            
567    
5682014-08-19  Dana Burkart  <dburkart@apple.com>
569
570        Merge r172693. <rdar://problem/17577321>
571
572    2014-08-15  Dean Jackson  <dino@apple.com>
573    
574            REGRESSION (r164173): Safari AutoFill button in popover, default buttons on iCloud control panel and Safari Safe Browsing pages don't have default appearance
575            https://bugs.webkit.org/show_bug.cgi?id=136011
576    
577            Reviewed by Sam Weinig.
578    
579            When we render some controls, we need to make sure the NSWindow subclass we
580            use as the host of the AppKit views identifies itself as the key window (if
581            the control state is correct). We already have a flag tracking this for
582            key appearance - just make sure we do the same for isKeyWindow.
583    
584            * platform/mac/ThemeMac.mm:
585            (-[WebCoreThemeWindow isKeyWindow]): New override to mirror the static
586            variable for key appearance.
587    
5882014-08-19  Dana Burkart  <dburkart@apple.com>
589
590        Merge r172657. <rdar://problem/17896828>
591
592    2014-08-15  Eric Carlson  <eric.carlson@apple.com>
593    
594            [MSE] Implement a maximum buffer size for SourceBuffer
595            https://bugs.webkit.org/show_bug.cgi?id=135614
596    
597            Reviewed by Jer Noble.
598    
599            Implement the MSE coded frame eviction algorithm: when new buffers are appended attempt
600            to keep the amount of data buffered below a maximum size (which is determined by the media
601            session manager) by freeing coded frames as follows:
602                1 - Free frames in 30 second chunks from 0 to 30 seconds before the current time.
603                2 - If there are time ranges after the range with the current time, free frames in
604                    30 second chunks from duration back to the beginning of the time range after
605                    current time.
606    
607            For now we DO NOT throw a QUOTA_EXCEEDED_ERR when we are not able to free up enough
608            space to remain below the prescribed quota, because some big name, widely deployed, 
609            code bases ignore the error and continue appending data as though the failed append
610            succeeded, leading to a corrupted bitstream and failure to play.
611    
612            * Modules/mediasource/SampleMap.cpp:
613            (WebCore::SampleMap::addSample): Drive-by performance optimization: sample->presentationTime()
614                is used more than once, stash it in a local variable.
615            (WebCore::SampleMap::removeSample): Ditto.
616    
617            * Modules/mediasource/SourceBuffer.cpp:
618            (WebCore::logRanges): Debug-only function to log TimeRanges.
619            (WebCore::SourceBuffer::SourceBuffer):
620            (WebCore::SourceBuffer::remove): Optimize logging. Buffer full and coded frame eviction logic
621                is in SourceBuffer instead of SourceBufferPrivate.
622            (WebCore::SourceBuffer::appendBufferInternal): Ditto.
623            (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete): Set m_bufferFull when more data
624                has been buffered than allowed.
625            (WebCore::removeSamplesFromTrackBuffer): Add logging.
626            (WebCore::SourceBuffer::removeCodedFrames): Improve logging. Avoid debug build assert when
627                current time is after last enqueued presentation time.
628            (WebCore::SourceBuffer::evictCodedFrames): The coded frame eviction algorithm.
629            (WebCore::SourceBuffer::maximumBufferSize): Return the maximum amount of data that can 
630                be buffered.
631            (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Improve logging. Don't attempt
632                to create a PlatformTimeRanges with inverted start and end to avoid an assert in debug.
633            (WebCore::SourceBuffer::hasAudio): New, return true if there are any audio tracks.
634            (WebCore::SourceBuffer::hasVideo): New, return true if there are any video tracks.
635            (WebCore::SourceBuffer::sourceBufferPrivateHasAudio): Call hasAudio.
636            (WebCore::SourceBuffer::sourceBufferPrivateHasVideo): Call hasVideo.
637            (WebCore::SourceBuffer::hasCurrentTime): Return true if currentTime is greater than duration.
638            (WebCore::SourceBuffer::hasFutureTime): Ditto.
639            (WebCore::SourceBuffer::extraMemoryCost): Return the amount of data buffered: the size of
640                the input buffer plus the size of all track samples.
641            (WebCore::SourceBuffer::reportExtraMemoryCost): Move buffered size calculation to extraMemoryCost.
642            (WebCore::SourceBuffer::document): Document accessor.
643            * Modules/mediasource/SourceBuffer.h: Drive-by size optimization by moving all bool member
644                variables to the end of class.
645    
646            * html/HTMLMediaElement.cpp:
647            (WebCore::HTMLMediaElement::refreshCachedTime): Drive-by removal of overly chatty logging.
648            (WebCore::HTMLMediaElement::maximumSourceBufferSize): New, maximum source buffer size.
649            * html/HTMLMediaElement.h:
650    
651            * html/HTMLMediaSession.cpp:
652            (WebCore::HTMLMediaSession::maximumMediaSourceBufferSize): New, get maximum source buffer 
653                size from settings, return full amount for an SourceBuffer with video and audio, return 5%
654                of the maximum for an audio-only SourceBuffer.
655            * html/HTMLMediaSession.h:
656    
657            * page/Settings.in: Add maximumSourceBufferSize. Default value is enough for approximately
658                five minutes of 1080p video and stereo audio.
659    
660            * platform/graphics/PlatformTimeRanges.cpp:
661            (WebCore::PlatformTimeRanges::totalDuration): Drive-by optimization.
662            (WebCore::PlatformTimeRanges::dump): New, allow a PlatformTimeRanges to be printed.
663            * platform/graphics/PlatformTimeRanges.h:
664    
665            * platform/graphics/SourceBufferPrivate.h: Delete evictCodedFrames and isFull, that logic
666                is not in SourceBuffer.
667            * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
668            * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
669            (WebCore::SourceBufferPrivateAVFObjC::processCodedFrame): Drive-by logging fix.
670            (WebCore::SourceBufferPrivateAVFObjC::evictCodedFrames): Deleted.
671            (WebCore::SourceBufferPrivateAVFObjC::isFull): Deleted.
672    
673            * platform/mock/mediasource/MockSourceBufferPrivate.cpp:
674            (WebCore::MockSourceBufferPrivate::evictCodedFrames): Deleted.
675            (WebCore::MockSourceBufferPrivate::isFull): Deleted.
676            * platform/mock/mediasource/MockSourceBufferPrivate.h:
677    
6782014-08-19  Dana Burkart  <dburkart@apple.com>
679
680        Merge r172656. <rdar://problem/17961698>
681
682    2014-08-15  Zalan Bujtas  <zalan@apple.com>
683    
684            REGRESSION: Parts of the route/route options windows are invisible at maps.google.com
685            https://bugs.webkit.org/show_bug.cgi?id=135977
686            <rdar://problem/17961698>
687    
688            Reviewed by Andreas Kling.
689    
690            When the style change requires both layout and repaint, the style diff is set to
691            'layout is needed' (and masks the repaint change) as normally layout is followed by a repaint.
692            However, in compositing context, layout may not be followed by repaint, so when the style diff
693            indicates layout, we need to figure out whether it implies repaint too.
694            This logic should eventually be moved from RenderElement to RenderLayerModelObject/RenderLayer.
695            -tracked here: webkit.org/b/135990
696    
697            Test: compositing/cliprect-and-position-change-on-compositing-layer.html
698    
699            * rendering/RenderElement.cpp:
700            (WebCore::RenderElement::setNeedsPositionedMovementLayout):
701            * rendering/style/RenderStyle.cpp:
702            (WebCore::RenderStyle::changeRequiresLayerRepaint):
703            (WebCore::RenderStyle::diffRequiresLayerRepaint):
704            (WebCore::RenderStyle::diffRequiresRepaint): Deleted.
705            * rendering/style/RenderStyle.h:
706            * rendering/style/RenderStyleConstants.h:
707    
7082014-08-19  Dana Burkart  <dburkart@apple.com>
709
710        Merge r172603
711
712    2014-08-14  Martin Hock  <mhock@apple.com>
713
714            IndexedDB should respect SchemeRegistry's database access setting.
715            https://bugs.webkit.org/show_bug.cgi?id=135890
716            <rdar://problem/17989469>
717
718            Reviewed by Alexey Proskuryakov.
719
720            Test: storage/indexeddb/open-db-private-browsing.html
721
722            * Modules/indexeddb/IDBFactory.cpp:
723
7242014-08-19  Dana Burkart  <dburkart@apple.com>
725
726        Merge r172600
727
728    2014-08-14  Yoav Weiss  <yoav@yoav.ws>
729
730            srcset with w descriptor doesn't behave as expected when sizes is not supported.
731            https://bugs.webkit.org/show_bug.cgi?id=135935
732
733            Reviewed by Dean Jackson.
734
735            In current implementation, if sizes is not supported, when authors would write
736            markup such as `<img src=fallback.jpg srcset="100px.jpg 100w, 400px.jpg 400w">`
737            the first candidate in srcset would be picked, regardless of its dimensions 
738            That is likely to be confusing for authors.
739            Dropping these "not yet supported" candidates is likely to be less confusing,
740            and will result in the "fallback.jpg" candidate being picked.
741
742            No new tests since this change only concerns builds that are built
743            with the PICTURE_SIZES compile flag turned off.
744
745            * html/parser/HTMLSrcsetParser.cpp:
746            (WebCore::parseDescriptors):
747            Drop candidates that include either 'w' or 'h' descriptors when the
748            sizes feature is not supported.
749
7502014-08-19  Dana Burkart  <dburkart@apple.com>
751
752        Merge r172502
753
754    2014-08-12  Pratik Solanki  <psolanki@apple.com>
755
756            Cached file backed resources don't make it to the Web Process when NETWORK_CFDATA_ARRAY_CALLBACK is enabled
757            https://bugs.webkit.org/show_bug.cgi?id=135727
758            <rdar://problem/17947880>
759
760            Reviewed by Darin Adler.
761
762            Add SharedBuffer::existingCFData() which returns CFDataRef if it has one. Refactor
763            this code out of createCFData().
764
765            * WebCore.exp.in:
766            * platform/SharedBuffer.h:
767            * platform/mac/SharedBufferMac.mm:
768            (WebCore::SharedBuffer::existingCFData): Added.
769            (WebCore::SharedBuffer::createCFData):
770
7712014-08-19  Dana Burkart  <dburkart@apple.com>
772
773        Merge r172481
774
775    2014-08-11  Roger Fong  <roger_fong@apple.com>
776
777            Adjust max-width of cues based on text alignment when cue size is expanded.
778            https://bugs.webkit.org/show_bug.cgi?id=135823.
779
780            Reviewed by Brent Fulgham.
781
782            All units are in percentages.
783            If we are left aligned the max cue width is the 100 minus the cue position.
784            If we are right aligned the max cue width is the cue position.
785            If we are centered the max cue width is just 100.
786
787            * html/track/TextTrackCueGeneric.cpp:
788            (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties):
789            * html/track/VTTCue.cpp:
790            (WebCore::VTTCueBox::applyCSSProperties):
791
7922014-08-14  Lucas Forschler  <lforschler@apple.com>
793
794        Merge r172609
795
796    2014-08-14  Brent Fulgham  <bfulgham@apple.com>
797
798            [Win] Correct build when DerivedSources location not supplied by build environment
799            https://bugs.webkit.org/show_bug.cgi?id=135954
800            <rdar://problem/18023620>
801
802            Reviewed by Joseph Pecoraro.
803
804            The DerivedSourcesDirectory is not always defined, depending on what
805            solution is being used to build this project. Instead, just define
806            it directly, since we already know where it needs to go.
807
808            Also:
809            1. Stop redirecting the copy output to NUL so I can see if this fails in the future.
810            2. Make sure the target directory exists before copying to it.
811
812            * WebCore.vcxproj/copyForwardingHeaders.cmd: Properly specify
813            the directories for copying the JS file.
814
8152014-08-14  Lucas Forschler  <lforschler@apple.com>
816
817        Merge r172584
818
819    2014-08-14  Jer Noble  <jer.noble@apple.com>
820
821            [MSE] Altering the quality of a YouTube video will cause the video to distort and display an error message
822            https://bugs.webkit.org/show_bug.cgi?id=135931
823
824            Reviewed by Eric Carlson.
825
826            When removing samples from the TrackBuffer's sample map, also remove those samples from the
827            TrackBuffer's decode queue. Otherwise, removed samples may persist in the decode queue and
828            either break sync-sample dependencies or cause decoding artifacts.
829
830            Pull the code which removes samples from a track buffer into its own utility function, and
831            use this function both from removeCodedFrames(), and also when samples are removed due to
832            overlapping appends in sourceBufferPrivateDidReceiveSample(). In order to reference
833            TrackBuffers outside of SourceBuffer (and in the static removeSamplesFromTrackBuffer()
834            function), make TrackBuffer a public forward declaration.
835
836            * Modules/mediasource/SourceBuffer.cpp:
837            (WebCore::removeSamplesFromTrackBuffer):
838            (WebCore::SourceBuffer::removeCodedFrames):
839            (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
840            * Modules/mediasource/SourceBuffer.h:
841
8422014-08-14  Lucas Forschler  <lforschler@apple.com>
843
844        Merge r172506
845
846    2014-08-12  Jer Noble  <jer.noble@apple.com>
847
848            [MSE] YouTube will lose audio, video after seeking backwards to an unbuffered range.
849            https://bugs.webkit.org/show_bug.cgi?id=135855
850
851            Reviewed by Eric Carlson.
852
853            When seeking into an unbuffered or partially buffered range, we will unconditionally pass samples to the
854            decode queue even if there exist large gaps between those samples. Subsequently, the decoder will not
855            notify us that it has become ready for new samples until playback reaches those later samples and the samples
856            are discarded.
857
858            When sending samples to be decoded in provideMediaData(), stop if there exists a large gap in the sample timeline.
859            Do this by tracking the last enqueued decode end time, and look to see if the next sample's decode time indicates
860            a gap of greater than 1 second.
861
862            * Modules/mediasource/SourceBuffer.cpp:
863            (WebCore::SourceBuffer::TrackBuffer::TrackBuffer): Initialize lastEnqueuedDecodeEndTime.
864            (WebCore::SourceBuffer::seekToTime): Set needsReenqueueing, in case samples do not yet exist in the trackBuffer
865                sufficient to re-enqueue for the destination time, so that re-enqueueing will occur after the next append.
866            (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Check against lastEnqueuedDecodeEndTime, rather than
867                lastEnqueuedPresentationTime before adding samples to the decodeQueue.
868            (WebCore::SourceBuffer::provideMediaData): Stop when we reach a large gap between samples.
869            (WebCore::SourceBuffer::reenqueueMediaForTime): Set or clear lastEnqueuedDecodeEndTime based on whether we
870                have appended any non-displaying samples after flushing.
871
8722014-08-13  Lucas Forschler  <lforschler@apple.com>
873
874        Merge r172538
875
876    2014-08-13  Jer Noble  <jer.noble@apple.com>
877
878            [MSE] Replacing existing samples with overlapping new samples will cause playback to stutter.
879            https://bugs.webkit.org/show_bug.cgi?id=135902
880
881            Reviewed by Eric Carlson.
882
883            Only mark the TrackBuffer as needing re-enqueueing if the samples removed by overlapping samples
884            themselves overlap with potentially enqueued but not yet displayed frames.
885
886            * Modules/mediasource/SourceBuffer.cpp:
887            (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
888
8892014-08-13  Lucas Forschler  <lforschler@apple.com>
890
891        Merge r172534
892
893    2014-08-13  Simon Fraser  <simon.fraser@apple.com>
894
895            [WK1] A fixed-position <img> may not show on page load
896            https://bugs.webkit.org/show_bug.cgi?id=135893
897
898            Reviewed by Tim Horton.
899
900            A position:fixed image could fail to display because we didn't make a
901            compositing layer for it under some circumstances. This can happen if
902            RenderLayerCompositor::requiresCompositingForPosition() runs before the
903            image is loaded, in which cause the layer is zero-sized, so does not get
904            composited.
905
906            When the image loads, there was no code path that ensured that compositing
907            would be re-evaluated (unlike size changes due to style updates). Fix by
908            having RenderLayer::contentChanged() also check for ImageChanged.
909
910            Test: compositing/fixed-image-loading.html
911
912            * rendering/RenderLayer.cpp:
913            (WebCore::RenderLayer::contentChanged):
914
9152014-08-13  Lucas Forschler  <lforschler@apple.com>
916
917        Merge r172507
918
919    2014-08-12  Jer Noble  <jer.noble@apple.com>
920
921            [MSE][Mac] Seeking to the very beginning of a buffered range stalls video playback
922            https://bugs.webkit.org/show_bug.cgi?id=135865
923
924            Reviewed by Eric Carlson.
925
926            AVSampleBufferRenderSynchronizer will report a current time of about 100ms or so before
927            the destination seek time when seeking. It does this in order to pre-roll the synchronized
928            audio renderer, but this can lead to playback stalling when MediaSource::monitorSourceBuffers()
929            looks at the media element's current time and determines that the current time is 100ms before
930            any buffered samples.
931
932            Clamp the value of currentMediaTime() to, at a minimum, the last requested seek time. This was
933            the suggested course of action from <rdar://problem/17789374>.
934
935            * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
936            * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
937            (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::durationDouble):
938            (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::currentMediaTime):
939            (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
940
9412014-08-13  Lucas Forschler  <lforschler@apple.com>
942
943        Merge r172501
944
945    2014-08-12  Tim Horton  <timothy_horton@apple.com>
946
947            Small region (~1px tall) where you get the selection button instead of the phone number overlay
948            https://bugs.webkit.org/show_bug.cgi?id=135852
949            <rdar://problem/17992795>
950
951            Reviewed by Enrica Casucci.
952
953            * WebCore.exp.in:
954
9552014-08-13  Lucas Forschler  <lforschler@apple.com>
956
957        Merge r172383
958
959    2014-08-10  Tim Horton  <timothy_horton@apple.com>
960
961            Yelp phone number highlights often disappear
962            https://bugs.webkit.org/show_bug.cgi?id=135789
963            <rdar://problem/17971057>
964
965            Reviewed by Brady Eidson.
966
967            * editing/Editor.cpp:
968            (WebCore::Editor::scanSelectionForTelephoneNumbers):
969            (WebCore::Editor::clearDataDetectedTelephoneNumbers): Deleted.
970            * editing/Editor.h:
971            (WebCore::Editor::detectedTelephoneNumberRanges):
972            * page/EditorClient.h:
973            (WebCore::EditorClient::selectedTelephoneNumberRangesChanged):
974            Cache and expose detected telephone number ranges on Editor.
975            Change selectedTelephoneNumberRangesChanged to take no arguments; it's
976            just a notification now.
977
9782014-08-12  Lucas Forschler  <lforschler@apple.com>
979
980        Merge r172471
981
982    2014-08-12  Brent Fulgham  <bfulgham@apple.com>
983
984            [Win] Unreviewed build fix after r17425
985
986            * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h: Remove
987            unused 'currentTime' declaration from header file. This is now fully implemented
988            in platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h.
989
9902014-08-12  Lucas Forschler  <lforschler@apple.com>
991
992        Rollout r172278
993
9942014-08-12  Lucas Forschler  <lforschler@apple.com>
995
996        Merge r172425
997
998    2014-08-11  Brent Fulgham  <bfulgham@apple.com>
999
1000            [Mac, iOS] Some media content never reaches full 'loaded' state
1001            https://bugs.webkit.org/show_bug.cgi?id=135814
1002            <rdar://problem/17476923>
1003
1004            Reviewed by Jer Noble.
1005
1006            * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
1007            (WebCore::MediaPlayerPrivateAVFoundation::duration): Change to a wrapper that just calls
1008            the durationDouble method and narrows to a float.
1009            (WebCore::MediaPlayerPrivateAVFoundation::durationDouble): Revised version of duration
1010            that works with doubles.
1011            (WebCore::MediaPlayerPrivateAVFoundation::currentTime): Wrapper that calls the
1012            currentTimeDouble method and narrows to a float.
1013            (WebCore::MediaPlayerPrivateAVFoundation::seekWithTolerance): Use durationDouble for
1014            comparison with passed 'time' argument (which is a double).
1015            (WebCore::MediaPlayerPrivateAVFoundation::didEnd): Use 'currentTimeDouble' so we can
1016            cache the double precision version of this value.
1017            (WebCore::MediaPlayerPrivateAVFoundation::extraMemoryCost): Use 'durationDouble' since
1018            the rest of the calculation is in terms of doubles.
1019            * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
1020            * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
1021            (WebCore::MediaPlayerPrivateAVFoundationCF::platformDuration): Convert to 'double'. All
1022            uses of this method are internal to the MediaPlayerPrivateAVFoundation* files.
1023            (WebCore::MediaPlayerPrivateAVFoundationCF::currentTimeDouble): Switch from float implementation.
1024            (WebCore::MediaPlayerPrivateAVFoundationCF::currentTime): Deleted. (Moved to parent class)
1025            * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
1026            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
1027            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1028            (WebCore::MediaPlayerPrivateAVFoundationObjC::platformDuration): Convert to 'double'. All
1029            uses of this method are internal to the MediaPlayerPrivateAVFoundation* files.
1030            (WebCore::MediaPlayerPrivateAVFoundationObjC::currentTimeDouble): Switch from floating implementation.
1031            (WebCore::MediaPlayerPrivateAVFoundationObjC::currentTime): Deleted. (Moved to parent class)
1032
10332014-08-12  Lucas Forschler  <lforschler@apple.com>
1034
1035        Merge r172424
1036
1037    2014-08-11  Enrica Casucci  <enrica@apple.com>
1038
1039            Improve look and feel of combined service menu..
1040            https://bugs.webkit.org/show_bug.cgi?id=135824
1041            <rdar://problem/17936880>
1042
1043            Reviewed by Tim Horton.
1044
1045            Adding some localizable strings.
1046
1047            * English.lproj/Localizable.strings:
1048
10492014-08-12  Lucas Forschler  <lforschler@apple.com>
1050
1051        Merge r172428
1052
1053    2014-08-11  Mark Rowe  <mrowe@apple.com>
1054
1055            Fix the Mac build.
1056
1057            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1058            #if a function that's only used on iOS.
1059
10602014-08-12  Lucas Forschler  <lforschler@apple.com>
1061
1062        Merge r172422
1063
1064    2014-08-11  Jer Noble  <jer.noble@apple.com>
1065
1066            [iOS] <video> element requests are missing session cookies; sometimes persistant cookies.
1067            https://bugs.webkit.org/show_bug.cgi?id=135816
1068
1069            Reviewed by Alexey Proskuryakov.
1070
1071            On iOS, the AVFoundation framework will copy appropriate cookies for the requested URL across to the
1072            mediaserverd process. For WebKit2, the WebProcess does not have access to session cookies for the 
1073            current browsing session. When creating an AVURLAsset, fetch the appropriate cookies for the requested
1074            URL, and pass them into AVURLAsset in the options dictionary.
1075
1076            * html/HTMLMediaElement.cpp:
1077            (WebCore::HTMLMediaElement::mediaPlayerGetRawCookies): Call CookieJar's equivalent method.
1078            * html/HTMLMediaElement.h:
1079            * platform/graphics/MediaPlayer.cpp:
1080            (WebCore::MediaPlayer::getRawCookies): Pass to HTMLMediaElement.
1081            * platform/graphics/MediaPlayer.h:
1082            (WebCore::MediaPlayerClient::mediaPlayerGetRawCookies):
1083            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1084            (WebCore::toNSHTTPCookie): Convert a WebCore Cookie -> NSHTTPCookie.
1085            (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Fetch cookies for the requested
1086                URL, and if successful, add them to the AVURLAsset options dictionary.
1087
10882014-08-12  Lucas Forschler  <lforschler@apple.com>
1089
1090        Merge r172421
1091
1092    2014-08-11  Roger Fong  <roger_fong@apple.com>
1093
1094            Adjustments to CueBox CSS Width calculations Part 2.
1095            https://bugs.webkit.org/show_bug.cgi?id=135820
1096            <rdar://problem/17954473>.
1097
1098            Reviewed by Brent Fulgham.
1099
1100            Two adjustments made:
1101            a) The default font size used was incorrect. It is not just 10px, 
1102            but should be based off a percentage of the video size.
1103            b) The top/left CSS property needs to be adjusted appropriately if the cue
1104            is center aligned and we change the cue's size such that the cue remains centered.
1105            * html/track/TextTrackCueGeneric.cpp:
1106            (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties):
1107            * html/track/VTTCue.cpp:
1108            (WebCore::VTTCueBox::applyCSSProperties):
1109            * html/track/VTTCue.h: Remove unnecessary constant.
1110
11112014-08-12  Lucas Forschler  <lforschler@apple.com>
1112
1113        Merge r172417
1114
1115    2014-08-11  Beth Dakin  <bdakin@apple.com>
1116
1117            Fixed backgrounds don't paint in blurred inset areas
1118            https://bugs.webkit.org/show_bug.cgi?id=135712
1119
1120            Reviewed by Simon Fraser.
1121
1122            Background geometry calculations for fixed background need to use the larger 
1123            visible rect.
1124
1125            The first version of this patch caused a regression because it universally 
1126            adjusted the value for top to account for the inset whether or not the 
1127            viewportRect location was adjusted for the same. This version fixes that — those 
1128            two changes go hand-in-hand.
1129            * rendering/RenderBoxModelObject.cpp:
1130            (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
1131
11322014-08-12  Lucas Forschler  <lforschler@apple.com>
1133
1134        Merge r172404
1135
1136    2014-08-11  Timothy Hatcher  <timothy@apple.com>
1137
1138            Web Inspector: console.profile shouldn't stop auto-recorded profiles
1139            https://bugs.webkit.org/show_bug.cgi?id=135810
1140
1141            Reviewed by Joseph Pecoraro.
1142
1143            * inspector/InspectorTimelineAgent.cpp:
1144            (WebCore::InspectorTimelineAgent::start): Added. Call internalStart. Set m_enabledFromFrontend.
1145            (WebCore::InspectorTimelineAgent::stop): Added. Calls internalStop. Clear m_enabledFromFrontend.
1146            (WebCore::InspectorTimelineAgent::internalStart): Renamed from start.
1147            (WebCore::InspectorTimelineAgent::internalStop): Renamed from stop.
1148            (WebCore::InspectorTimelineAgent::startFromConsole): Use internalStart.
1149            (WebCore::InspectorTimelineAgent::stopFromConsole): Use internalStop. Only stop if !m_enabledFromFrontend.
1150            (WebCore::InspectorTimelineAgent::InspectorTimelineAgent): Initialize m_enabledFromFrontend.
1151            * inspector/InspectorTimelineAgent.h: Added m_enabledFromFrontend.
1152
11532014-08-12  Lucas Forschler  <lforschler@apple.com>
1154
1155        Merge r172397
1156
1157    2014-08-11  Brent Fulgham  <bfulgham@apple.com>
1158
1159            [Win] Adjust build script for Windows production build.
1160            https://bugs.webkit.org/show_bug.cgi?id=135806
1161            <rdar://problem/17978299>
1162
1163            Reviewed by Timothy Hatcher.
1164
1165            * WebCore.vcxproj/copyForwardingHeaders.cmd: Copy file needed
1166            for WebInspectorUI build.
1167
11682014-08-12  Lucas Forschler  <lforschler@apple.com>
1169
1170        Merge r172373
1171
1172    2014-08-09  Zalan Bujtas  <zalan@apple.com>
1173
1174            Subpixel rendering: Transforms on non-compositing layers leave bits behind when the box boundaries changes.
1175            https://bugs.webkit.org/show_bug.cgi?id=135786
1176
1177            Reviewed by Simon Fraser.
1178
1179            Since we don't control the transformed context painting's snapping strategy, our best bet to fully
1180            include the transformed box when requesting for repaint is to use enclosing.
1181            Pixelsnapping doesn't work here for all cases. For example, a scaled box at 0.8px can be anti-aliased painted
1182            both at 0.5px and 1px, while with pixelsnapping we'd expect it to be painted starting from 1px;
1183
1184            Test: fast/repaint/hidpi-transform-on-subpixel-repaintrect.html
1185
1186            * rendering/RenderBox.cpp:
1187            (WebCore::RenderBox::computeRectForRepaint): enclose the result of the transform.
1188
11892014-08-12  Lucas Forschler  <lforschler@apple.com>
1190
1191        Merge r172365
1192
1193    2014-08-08  Simon Fraser  <simon.fraser@apple.com>
1194
1195            [WK2] Scrolling does not work inside nested frames
1196            https://bugs.webkit.org/show_bug.cgi?id=135775
1197            <rdar://problem/17959896>
1198
1199            Reviewed by Tim Horton.
1200
1201            r169733 added an "isMainFrame" check in AsyncScrollingCoordinator::frameViewNonFastScrollableRegionChanged.
1202            However we have to rebuild the non-fast-scrollable region when any subframe changes,
1203            even a deeply nested one. So always rebuild it, starting from the root frame.
1204
1205            Fixes scrolling on nested framesets like http://www.opengl.org/sdk/docs/man3/.
1206
1207            Test: platform/mac-wk2/tiled-drawing/scrolling/frames/frameset-nested-frame-scrollability.html
1208
1209            * page/scrolling/AsyncScrollingCoordinator.cpp:
1210            (WebCore::AsyncScrollingCoordinator::frameViewNonFastScrollableRegionChanged):
1211
12122014-08-12  Lucas Forschler  <lforschler@apple.com>
1213
1214        Merge r172351
1215
1216    2014-08-08  Roger Fong  <roger_fong@apple.com>
1217
1218            Adjustments to CueBox CSS Width calculations.
1219            https://bugs.webkit.org/show_bug.cgi?id=135759
1220            <rdar://problem/17954473>.
1221
1222            Reviewed by Eric Carlson.
1223
1224            This is a followup patch that addresses some of the test failures caused by r172224.
1225            These tests were skipped in r172253.
1226            * html/shadow/MediaControlElements.cpp:
1227            (WebCore::MediaControlTextTrackContainerElement::updateActiveCuesFontSize):
1228            Tell the cue boxes that they need to be updated when the font size specified in the user prefs changes.
1229
1230            Cap width to 100%, calculate max-width in percentages instead of pixels.
1231            * html/track/TextTrackCueGeneric.cpp:
1232            (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties):
1233            * html/track/VTTCue.cpp:
1234            (WebCore::VTTCueBox::applyCSSProperties):
1235
1236            (WebCore::VTTCue::setFontSize):
1237            Remove some unnecessary code that doesn't actually work.
1238            Make sure to tell cuebox that it needs to be updated.
1239            * html/track/VTTCue.h: Change float constant to double.
1240
12412014-08-12  Lucas Forschler  <lforschler@apple.com>
1242
1243        Merge r172235
1244
1245    2014-08-07  Gordon Sheridan  <gordon_sheridan@apple.com>
1246
1247            Provide methods to clear undesired references to HistoryItems that have been removed from the back/forard list.
1248            https://bugs.webkit.org/show_bug.cgi?id=135634
1249            <rdar://problem/17388461>
1250
1251            Reviewed by Brady Eidson.
1252
1253            No new tests.  Would require an API test that also needs an httpd, which we don't currently support.
1254
1255            * WebCore.exp.in:
1256            Added export for Page::clearPreviousItemFromAllPages.
1257
1258            * loader/HistoryController.cpp:
1259            (WebCore::HistoryController::clearPreviousItem):
1260            Clear m_previousItem and iterate over children recursively calling clearPreviousItem().
1261            The m_previousItem is cleared for the target HistoryController, and all of its descendents.
1262
1263            * loader/HistoryController.h:
1264            Declared HistoryController::clearPreviousItem.
1265
1266            * page/Page.cpp:
1267            (WebCore::Page::clearPreviousItemFromAllPages):
1268            Iterate over each page in the web process, checking if the previous item of
1269            the HistoryController for the main frame is the same as the item being removed. If so, the
1270            frameTree is traversed and each associated HistoryController has its m_previousItem cleared.
1271
1272            * page/Page.h:
1273            Declared Page::clearPreviousItemFromAllPages.
1274
12752014-08-08  Lucas Forschler  <lforschler@apple.com>
1276
1277        Merge r172332
1278
1279    2014-08-07  Commit Queue  <commit-queue@webkit.org>
1280
1281            Unreviewed, rolling out r172291.
1282            https://bugs.webkit.org/show_bug.cgi?id=135748
1283
1284            broke background-attachment-fixed with backround-size-contain
1285            (e.g. iCloud.com) (Requested by thorton on #webkit).
1286
1287            Reverted changeset:
1288
1289            "Fixed backgrounds don't paint in blurred inset areas"
1290            https://bugs.webkit.org/show_bug.cgi?id=135712
1291            http://trac.webkit.org/changeset/172291
1292
12932014-08-07  Lucas Forschler  <lforschler@apple.com>
1294
1295        Merge r172287
1296
1297    2014-08-07  Jer Noble  <jer.noble@apple.com>
1298
1299            [EME][Mac] Error codes returned by AVSampleBufferDisplayLayer are negative; clip when passed to JavaScript as doubles.
1300            https://bugs.webkit.org/show_bug.cgi?id=135710
1301
1302            Reviewed by Brent Fulgham.
1303
1304            Return the absolute value of the error codes returned by AVSampleBufferDisplayLayer, so that the conversion from
1305            unsigned -> double does not clip due to the (converted) value being greater than 2^53.
1306
1307            * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
1308            (WebCore::CDMSessionMediaSourceAVFObjC::layerDidReceiveError):
1309            (WebCore::CDMSessionMediaSourceAVFObjC::rendererDidReceiveError):
1310
13112014-08-07  Dana Burkart <dburkart@apple.com>
1312
1313        Merge patch from <rdar://problem/17952779>.
1314
1315    2014-08-07  Brent Fulgham  <bfulgham@apple.com>
1316
1317            [Win] Branch-only build workaround.
1318
1319            * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp: Use custom
1320            DirectX header for branch build.
1321
13222014-08-07  Dana Burkart <dburkart@apple.com>
1323
1324        Merge r172301
1325
1326    2014-08-07  Enrica Casucci  <enrica@apple.com>
1327
1328            [Services with UI] Action menu does not appear if selection includes both text and an image.
1329            https://bugs.webkit.org/show_bug.cgi?id=135731
1330            <rdar://problem/17837491>
1331
1332            Reviewed by Brady Eidson.
1333
1334            When collecting selection rects via SelectionRectGatherer we should also note if the selection
1335            contains non text elements. This way the Notifier class can send that information to ServicesOverlayController
1336            to properly handle the highlight for the service.
1337
1338            * editing/SelectionRectGatherer.cpp:
1339            (WebCore::SelectionRectGatherer::SelectionRectGatherer):
1340            (WebCore::SelectionRectGatherer::Notifier::~Notifier):
1341            (WebCore::SelectionRectGatherer::clearAndCreateNotifier):
1342            * editing/SelectionRectGatherer.h:
1343            (WebCore::SelectionRectGatherer::setTextOnly):
1344            (WebCore::SelectionRectGatherer::isTextOnly):
1345            * page/EditorClient.h:
1346            (WebCore::EditorClient::selectionRectsDidChange):
1347            * rendering/RenderView.cpp:
1348            (WebCore::RenderView::applySubtreeSelection):
1349
13502014-08-07  Dana Burkart <dburkart@apple.com>
1351
1352        Merge r172293
1353
1354    2014-08-07  Andy Estes  <aestes@apple.com>
1355
1356            [Mac] Parental Controls content filter is mistakenly enabled for HTTP responses
1357            https://bugs.webkit.org/show_bug.cgi?id=135730
1358
1359            Reviewed by Brady Eidson.
1360
1361            On the Mac, the WebFilterEvaluator (Parental Controls) content filter should only be enabled for HTTPS
1362            responses. During iOS upstreaming we mistakenly enabled it for HTTP responses as well, and this causes HTTP
1363            responses to be filtered twice -- once by the Parental Controls HTTP proxy and once by WebCore. Revert to the
1364            pre-upstreaming behavior and only enable the content filter for HTTPS responses.
1365
1366            No new tests. Content filtering is not testable from WebKit.
1367
1368            * loader/DocumentLoader.cpp:
1369            (WebCore::DocumentLoader::responseReceived): Passed the response to ContentFilter::canHandleResponse().
1370            * platform/ContentFilter.h:
1371            * platform/mac/ContentFilterMac.mm:
1372            (WebCore::ContentFilter::canHandleResponse): Renamed from isEnabled(). Checks the response's scheme on Mac to
1373            determine whether WebFilterEvaluator should be used.
1374            (WebCore::ContentFilter::isEnabled): Deleted.
1375
13762014-08-07  Dana Burkart <dburkart@apple.com>
1377
1378        Merge r172291
1379
1380    2014-08-07  Beth Dakin  <bdakin@apple.com>
1381
1382            Fixed backgrounds don't paint in blurred inset areas
1383            https://bugs.webkit.org/show_bug.cgi?id=135712
1384
1385            Reviewed by Simon Fraser.
1386
1387            Background geometry calculations for fixed background need to use the larger 
1388            visible rect. 
1389
1390            * rendering/RenderBoxModelObject.cpp:
1391            (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
1392
13932014-08-07  Dana Burkart <dburkart@apple.com>
1394
1395        Merge r172275
1396
1397    2014-08-07  Daniel Bates  <dabates@apple.com>
1398
1399            Sometimes Gmail cannot load messages, particularly on refresh ("...the application ran into an unexpected error...")
1400            https://bugs.webkit.org/show_bug.cgi?id=135688
1401            <rdar://problem/17886686>
1402
1403            Reviewed by Alexey Proskuryakov.
1404
1405            Fixes an issue where gmail.com may fail to load the list of messages. In particular, a SQLTransactionCallback
1406            function may not be executed and hence Gmail will not display the list of messages and
1407            will subsequently display an error message.
1408
1409            When a WebKit client defers loading of a page (e.g. -[WebView setDefersCallbacks:YES]), WebCore
1410            may still load the main resource, say if substitute data is available for it, and defer executing
1411            tasks, such as a SQLTransactionCallback function, by appending such tasks to the end of the list
1412            of pending tasks for the associated Document. This list of pending tasks is never processed when
1413            a client subsequently allows loading (e.g. -[WebView setDefersCallbacks:NO])). Therefore, we never
1414            execute a SQLTransactionCallback function that was deferred.
1415
1416            Ideally WebCore would defer loading of substitute data when a WebKit client requests that loading
1417            be deferred and hence a SQLTransactionCallback function would be deferred as a consequence of the
1418            lack of JavaScript script execution (since substitute data wasn't loaded and hence any JavaScript
1419            script contained in the substitute data that initiates a SQL transaction isn't executed). For now,
1420            it's sufficient to only defer executing tasks when either there are existing pending tasks or the
1421            page defers loading and active DOM objects in the document are suspended (e.g. Document::suspendActiveDOMObjects() was called).
1422
1423            * dom/Document.cpp:
1424            (WebCore::Document::postTask):
1425
14262014-08-07  Dana Burkart <dburkart@apple.com>
1427
1428        Merge r172231
1429
1430    2014-08-07  Roger Fong  <roger_fong@apple.com>
1431
1432            Unreviewed build fix attempt #2 following r172224.
1433
1434            * html/track/VTTCue.cpp:
1435            (WebCore::VTTCueBox::applyCSSProperties):
1436
14372014-08-07  Dana Burkart <dburkart@apple.com>
1438
1439        Merge r172228
1440
1441    2014-08-07  Roger Fong  <roger_fong@apple.com>
1442
1443            Unreviewed build fix following r172224.
1444
1445            * html/track/TextTrackCueGeneric.cpp:
1446            (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties):
1447            * html/track/VTTCue.cpp:
1448            (WebCore::VTTCueBox::applyCSSProperties):
1449            * html/track/VTTCue.h:
1450
14512014-08-07  Dana Burkart <dburkart@apple.com>
1452
1453        Merge r172224
1454
1455    2014-08-06  Roger Fong  <roger_fong@apple.com>
1456
1457            Increase width of caption container if a larger font size is selected from user prefs.
1458            https://bugs.webkit.org/show_bug.cgi?id=135677.
1459
1460            Reviewed by Brent Fulgham.
1461
1462            * html/shadow/MediaControlElements.cpp:
1463            (WebCore::MediaControlTextTrackContainerElement::updateDisplay):
1464            Upon creation of a VTTCueBox make sure to supply the font size set by the user prefs.
1465            * html/track/TextTrackCueGeneric.cpp:
1466            (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties):
1467            Increase the width of the cue box based on user prefs font size selection.
1468
1469            * html/track/VTTCue.h:
1470            Keep track of the font size set in the user prefs for use when the cue boxes are created.
1471            (WebCore::VTTCueBox::setFontSizeFromCaptionUserPrefs):
1472            * html/track/VTTCue.cpp:
1473            (WebCore::VTTCueBox::applyCSSProperties):
1474            Increase the width of the cue box based on user prefs font size selection.
1475            (WebCore::VTTCue::getDisplayTree):
1476            (WebCore::VTTCue::setFontSize):
1477            If the font size set is important then we don't want to use the font size set by user prefs, set it to 0.
1478
14792014-08-07  Dana Burkart <dburkart@apple.com>
1480
1481        Merge r172257
1482
1483    2014-08-07  Eric Carlson  <eric.carlson@apple.com>
1484
1485            Create UTF-8 string from in-band VTT cues
1486            https://bugs.webkit.org/show_bug.cgi?id=135716
1487
1488            Reviewed by Brent Fulgham.
1489
1490            Tests will be added in https://bugs.webkit.org/show_bug.cgi?id=135717.
1491
1492            * platform/graphics/ISOVTTCue.cpp:
1493            (WebCore::ISOBox::peekString): Call String::fromUTF8 because we know that VTT is always
1494                UTF-8.
1495
14962014-08-07  Dana Burkart <dburkart@apple.com>
1497
1498        Merge r172244
1499
1500    2014-08-06  Jeremy Jones  <jeremyj@apple.com>
1501
1502            Disable implicit animations on video layer.
1503            https://bugs.webkit.org/show_bug.cgi?id=135679
1504
1505            Reviewed by Eric Carlson.
1506
1507            Disable implicit animations on AVPlayerLayer except when setting fullscreen frame.
1508            This prevents unwanted animations.
1509
1510            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1511            (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerLayer): disable implicit animations
1512            (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenFrame): allow implicit animations while changing fullscreen frame.
1513
15142014-08-07  Dana Burkart <dburkart@apple.com>
1515
1516        Merge r172197
1517
1518    2014-08-06  Myles C. Maxfield  <mmaxfield@apple.com>
1519
1520            [iOS] Make document marker assets not specific to particular scale factors
1521            https://bugs.webkit.org/show_bug.cgi?id=135671
1522
1523            Reviewed by Simon Fraser.
1524
1525            No new tests.
1526
1527            * WebCore.xcodeproj/project.pbxproj:
1528            * platform/ios/wak/WKGraphics.mm:
1529            (imageResourcePath):
1530            (WKGraphicsCreateImageFromBundleWithName):
1531
15322014-08-07  Dana Burkart <dburkart@apple.com>
1533
1534        Merge r172191
1535
1536    2014-08-06  Andy Estes  <aestes@apple.com>
1537
1538            [iOS] Subresources referenced in converted QuickLook documents sometimes fail to load
1539            https://bugs.webkit.org/show_bug.cgi?id=135676
1540
1541            Reviewed by David Kilzer.
1542
1543            * loader/DocumentLoader.h:
1544            (WebCore::DocumentLoader::setQuickLookHandle):
1545            (WebCore::DocumentLoader::quickLookHandle):
1546
15472014-08-07  Dana Burkart <dburkart@apple.com>
1548
1549        Merge r172183
1550
1551    2014-08-06  Simon Fraser  <simon.fraser@apple.com>
1552
1553            REGRESSION (r168119): Album flipping animation doesn’t work
1554            https://bugs.webkit.org/show_bug.cgi?id=132801
1555            <rdar://problem/16878497>, <rdar://problem/17908085>
1556
1557            Reviewed by Dean Jackson.
1558            
1559            In r168119 I avoided creating backing store for backface-visibility:hidden unless
1560            some ancestor was 3d-transformed. However, when starting transitions or animations
1561            that apply transforms, we don't do a layout, and therefore don't update the RenderLayer
1562            flags that mark an ancestor as having a transform. This broke various content which
1563            used backface-visibility:hidden for "flip" animations.
1564            
1565            Make a low-risk fix that looks for the pattern of CSS properties used for flipping,
1566            making a compositing layer for backface-visibility:hidden if the stacking context element
1567            has transform-style: preserve-3d.
1568
1569            Test: compositing/backing/backface-visibility-flip.html
1570
1571            * rendering/RenderLayerCompositor.cpp:
1572            (WebCore::RenderLayerCompositor::requiresCompositingForBackfaceVisibility):
1573
15742014-08-07  Dana Burkart <dburkart@apple.com>
1575
1576        Merge r172027
1577
1578    2014-08-04  Chris Fleizach  <cfleizach@apple.com>
1579
1580            AX: Select activity behavior does not work when an existing range is already selected
1581            https://bugs.webkit.org/show_bug.cgi?id=135579
1582
1583            Reviewed by Mario Sanchez Prada.
1584
1585            If you have an existing range selected, and try to apply a select and replace operation, like capitalize,
1586            searching for that range will fail because it skips the currently selected range.
1587
1588            For these cases, it seems the best way is to start the search from the start position, rather than relying on the
1589            entire range.
1590
1591            Updated existing test: platform/mac/accessibility/select-text.html
1592
1593            * accessibility/AccessibilityObject.cpp:
1594            (WebCore::AccessibilityObject::selectText):
1595
15962014-08-07  Dana Burkart <dburkart@apple.com>
1597
1598        Merge r172005
1599
1600    2014-08-04  Chris Fleizach  <cfleizach@apple.com>
1601
1602            AX: isWordEndMatch should allow for multiple word selections
1603            https://bugs.webkit.org/show_bug.cgi?id=135573
1604
1605            Reviewed by Mario Sanchez Prada.
1606
1607            isWordEndMatch was searching from the beginning of the selected range, which meant
1608            that if the result was multiple words, we'd reject the result. 
1609            Instead, we should search from the end of the range, so that we encompass all words.
1610
1611            Modified existing test: platform/mac/accessibility/select-text-should-match-whole-words.html
1612
1613            * editing/TextIterator.cpp:
1614            (WebCore::SearchBuffer::isWordEndMatch):
1615
16162014-08-07  Dana Burkart <dburkart@apple.com>
1617
1618        Merge r171997
1619
1620    2014-08-04  Chris Fleizach  <cfleizach@apple.com>
1621
1622            AX: SelectText functionality always selects text after current selection even if closer selection is behind it
1623            https://bugs.webkit.org/show_bug.cgi?id=135546
1624
1625            Reviewed by Mario Sanchez Prada.
1626
1627            Logic was incorrect for comparing ranges found before the current selection.
1628            ASSERT was incorrect for allowed ranges. We need to allow ranges that are right at the boundaries of our found ranges.
1629
1630            Extended existing test: platform/mac/accessibility/select-text.html
1631
1632            * accessibility/AccessibilityObject.cpp:
1633            (WebCore::rangeClosestToRange):
1634
16352014-08-07  Dana Burkart <dburkart@apple.com>
1636
1637        Merge r171996
1638
1639    2014-08-04  Chris Fleizach  <cfleizach@apple.com>
1640
1641            AX: AXSelectTextWithCriteriaParameterizedAttribute incorrectly selects the beginning letters of a word
1642            https://bugs.webkit.org/show_bug.cgi?id=135547
1643
1644            Reviewed by Mario Sanchez Prada.
1645
1646            Allow text search to specify that it wants to match end of words as well as start of words.
1647            This allows select text criteria to match on whole words only.
1648
1649            Test: platform/mac/accessibility/select-text-should-match-whole-words.html
1650
1651            * accessibility/AccessibilityObject.cpp:
1652            (WebCore::AccessibilityObject::rangeOfStringClosestToRangeInDirection):
1653            * editing/FindOptions.h:
1654            * editing/TextIterator.cpp:
1655            (WebCore::SearchBuffer::isWordEndMatch):
1656            (WebCore::SearchBuffer::search):
1657
16582014-08-07  Dana Burkart <dburkart@apple.com>
1659
1660        Merge r171994
1661
1662    2014-08-04  Chris Fleizach  <cfleizach@apple.com>
1663
1664            AX: The Dictation command "Replace <phrase> with <phrase>" always capitalizes the replacement string
1665            https://bugs.webkit.org/show_bug.cgi?id=135557
1666
1667            Reviewed by Mario Sanchez Prada.
1668
1669            When replacing text, we should match the capitalization of the word being replaced 
1670            (unless the replacement looks like an abbreviation).   
1671     
1672            Test: platform/mac/accessibility/find-and-replace-match-capitalization.html
1673
1674            * accessibility/AccessibilityObject.cpp:
1675            (WebCore::AccessibilityObject::selectText):
1676
16772014-08-07  Dana Burkart <dburkart@apple.com>
1678
1679        Merge r172215
1680
1681    2014-08-07  Pratik Solanki  <psolanki@apple.com>
1682
1683            Random resource replacement on beta.icloud.com
1684            https://bugs.webkit.org/show_bug.cgi?id=135685
1685            <rdar://problem/17937975>
1686
1687            Reviewed by Alexey Proskuryakov.
1688
1689            Revert the performance optimization in r170499. It turns out we could get a delayed disk
1690            cache notification for a resource that has since been changed in WebCore. In such a case, we
1691            were replacing the newer resource data with the older disk cached resource data. This was
1692            happening for cached POST content on beta.icloud.com. Fix this by forcing a memcmp of data
1693            contents before replacing it which is what we used to do before.
1694
1695            * loader/cache/CachedResource.cpp:
1696            (WebCore::CachedResource::tryReplaceEncodedData):
1697
16982014-08-07  Dana Burkart <dburkart@apple.com>
1699
1700        Merge r172213
1701
1702    2014-08-06  Brent Fulgham  <bfulgham@apple.com>
1703
1704            [Mac, iOS] Captions are appearing multiple times during repeated video play through
1705            https://bugs.webkit.org/show_bug.cgi?id=135680
1706            <rdar://problem/17926802>
1707
1708            Reviewed by Eric Carlson.
1709
1710            Test: media/track/track-in-band-cues-added-once.html
1711
1712            Revert TextTrackCueGeneric::isOrderedBefore logic to its original form, and add
1713            a new 'isOrderedBeforeDuringDisplay' for the special case of displaying captions.
1714
1715            * html/shadow/MediaControlElements.cpp:
1716            (WebCore::compareCueIntervalForDisplay): Added helper function.
1717            (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Use the new
1718            'isOrderedBeforeDuringDisplay' to order the cues for display.
1719            * html/track/TextTrackCue.h:
1720            (WebCore::TextTrackCue::isOrderedBeforeDuringDisplay): Added. This just
1721            calls the existing 'isOrderedBefore' method.
1722            * html/track/TextTrackCueGeneric.cpp:
1723            (WebCore::TextTrackCueGeneric::isOrderedBefore): Revert to logic used
1724            prior to r171700.
1725            (WebCore::TextTrackCueGeneric::isOrderedBeforeDuringDisplay): New method that
1726            implements the behavior in r171700.
1727            * html/track/TextTrackCueGeneric.h:
1728
17292014-08-07  Dana Burkart <dburkart@apple.com>
1730
1731        Merge r172202
1732
1733    2014-08-06  Brent Fulgham  <bfulgham@apple.com>
1734
1735            [Win] Correct build errors when WebGL Disabled
1736            https://bugs.webkit.org/show_bug.cgi?id=135687
1737
1738            Unreviewed build fix.
1739
1740            * WebCore.vcxproj/WebCore.vcxproj: Don't build Cairo files
1741            when building CG.
1742            * platform/graphics/GLContext.cpp: Correct use of 3D_GRAPHICS macro.
1743            * platform/graphics/GraphicsContext3DPrivate.cpp: Ditto.
1744            * platform/graphics/opengl/GLPlatformContext.cpp: Ditto.
1745            * platform/graphics/opengl/GLPlatformSurface.cpp: Ditto.
1746
17472014-08-07  Dana Burkart <dburkart@apple.com>
1748
1749        Merge r172195
1750
1751    2014-08-06  Enrica Casucci  <enrica@apple.com>
1752
1753            Services menu doesn't show up after you defocus/refocus the Safari window.
1754            https://bugs.webkit.org/show_bug.cgi?id=135678
1755            <rdar://problem/17929247>
1756
1757            Reviewed by Tim Horton.
1758
1759            In setSelection we create a SelectionRectGatherer::Notifier object that will notify
1760            SelectionOverlayController about changes to the selection rects.
1761            Upon creation, the list of selections rects is cleared, since it is populated by
1762            the code that collects the selection rects. That code is never called
1763            when setSelection won't change the selection, which the case when the window is
1764            activated. The fix consists in postponing the SelectionRectGatherer::Notifier object
1765            creation until we know for sure that the selection is indeed going to change.
1766            
1767            * rendering/RenderView.cpp:
1768            (WebCore::RenderView::setSelection):
1769
17702014-08-07  Dana Burkart <dburkart@apple.com>
1771
1772        Merge r172193
1773
1774    2014-08-06  Brady Eidson  <beidson@apple.com>
1775
1776            IDB transactions never reset if the Web Process ends before cleaning up
1777            https://bugs.webkit.org/show_bug.cgi?id=135218
1778
1779            Reviewed by David Kilzer.
1780
1781            No new tests (Covered by existing tests).
1782
1783            * Modules/indexeddb/IDBServerConnection.h: Add sync versions of reset/rollback.
1784
1785            * Modules/indexeddb/IDBTransactionBackend.cpp:
1786            (WebCore::IDBTransactionBackend::abort): Call the sync versions.
1787
17882014-08-07  Dana Burkart <dburkart@apple.com>
1789
1790        Merge r172183
1791
1792    2014-08-06  Simon Fraser  <simon.fraser@apple.com>
1793
1794            REGRESSION (r168119): Album flipping animation doesn’t work
1795            https://bugs.webkit.org/show_bug.cgi?id=132801
1796            <rdar://problem/16878497>, <rdar://problem/17908085>
1797
1798            Reviewed by Dean Jackson.
1799            
1800            In r168119 I avoided creating backing store for backface-visibility:hidden unless
1801            some ancestor was 3d-transformed. However, when starting transitions or animations
1802            that apply transforms, we don't do a layout, and therefore don't update the RenderLayer
1803            flags that mark an ancestor as having a transform. This broke various content which
1804            used backface-visibility:hidden for "flip" animations.
1805            
1806            Make a low-risk fix that looks for the pattern of CSS properties used for flipping,
1807            making a compositing layer for backface-visibility:hidden if the stacking context element
1808            has transform-style: preserve-3d.
1809
1810            Test: compositing/backing/backface-visibility-flip.html
1811
1812            * rendering/RenderLayerCompositor.cpp:
1813            (WebCore::RenderLayerCompositor::requiresCompositingForBackfaceVisibility):
1814
18152014-08-07  Dana Burkart <dburkart@apple.com>
1816
1817        Merge r172179
1818
1819    2014-08-06  Tim Horton  <timothy_horton@apple.com>
1820
1821            Document-relative overlays disappear after doing page-cache navigations
1822            https://bugs.webkit.org/show_bug.cgi?id=135669
1823            <rdar://problem/17929171>
1824
1825            Reviewed by Simon Fraser.
1826
1827            * rendering/RenderLayerCompositor.cpp:
1828            (WebCore::RenderLayerCompositor::rootLayerAttachmentChanged):
1829            When navigating from one page to another, the document-relative overlay
1830            layer is moved from the layer tree of the RenderLayerCompositor of the
1831            first RenderView to the layer tree of the RenderLayerCompositor of the
1832            new RenderView, upon layer tree construction.
1833            When going "back" via a page cache navigation, we don't rebuild the
1834            layer tree, and just assume that it is in a valid state.
1835            However, the document-relative overlay layer was *moved*, and as such,
1836            needs to be moved back. To do this, reattach the document-relative
1837            overlay layer whenever the root layer attachment of a RenderLayerCompositor
1838            changes, which will happen in the right order when going back to a cached page.
1839
18402014-08-07  Dana Burkart <dburkart@apple.com>
1841
1842        Merge r172172
1843
1844    2014-08-06  Alexey Proskuryakov  <ap@apple.com>
1845
1846            REGRESSION (WebKit2): iOS Safari default encoding doesn't follow system language
1847            https://bugs.webkit.org/show_bug.cgi?id=135667
1848            <rdar://problem/17862892>
1849
1850            Reviewed by Anders Carlsson.
1851
1852            Moved a function that computes default encoding from WebKit to WebCore, so that
1853            it could be shared with WebKit2.
1854
1855            * WebCore.exp.in:
1856            * platform/ios/WebCoreSystemInterfaceIOS.mm:
1857            * platform/mac/WebCoreSystemInterface.h:
1858            * platform/mac/WebCoreSystemInterface.mm:
1859            * platform/text/TextEncodingRegistry.cpp:
1860            (WebCore::defaultTextEncodingNameForSystemLanguage):
1861            * platform/text/TextEncodingRegistry.h:
1862
18632014-08-07  Dana Burkart <dburkart@apple.com>
1864
1865        Merge r172160
1866
1867    2014-08-05  Brent Fulgham  <bfulgham@apple.com>
1868
1869            [Mac] Unable to scroll to bottom of nested scrollable areas
1870            https://bugs.webkit.org/show_bug.cgi?id=135637
1871            <rdar://problem/17910241>
1872
1873            Reviewed by Zalan Bujtas.
1874
1875            Test: platform/mac/fast/scrolling/scroll-latched-nested-div.html
1876
1877            Avoid truncating the fractional portion of scroll ranges.
1878
1879            * rendering/RenderLayer.cpp:
1880            (WebCore::RenderLayer::updateScrollbarsAfterLayout): Round
1881            the LayoutUnit values for scroll width and height rather than
1882            truncating.
1883
18842014-08-07  Dana Burkart <dburkart@apple.com>
1885
1886        Merge r172159
1887
1888    2014-08-06  Andy Estes  <aestes@apple.com>
1889
1890            [iOS] QuickLook returns an invalid MIME type for some documents
1891            https://bugs.webkit.org/show_bug.cgi?id=135651
1892
1893            Reviewed by David Kilzer.
1894
1895            r172151 ensured that we ignore QuickLook delegate messages after an error, but neglected to do so for
1896            connectionDidFinishLoading:. Do not call ResourceLoader::didFinishLoading() if an error has occurred.
1897
1898            * platform/network/ios/QuickLook.mm:
1899            (-[WebResourceLoaderQuickLookDelegate connectionDidFinishLoading:]):
1900
19012014-08-07  Dana Burkart <dburkart@apple.com>
1902
1903        Merge r172151
1904
1905    2014-08-06  Andy Estes  <aestes@apple.com>
1906
1907            [iOS] QuickLook returns an invalid MIME type for some documents
1908            https://bugs.webkit.org/show_bug.cgi?id=135651
1909
1910            Reviewed by David Kilzer.
1911
1912            In some cases QuickLook indicates a failure by returning a nil MIME type in -[QLPreviewConverter previewResponse]
1913            rather than calling connection:didFailWithError:. Calling ResourceLoader::didReceiveResponse() with a response
1914            containing a nil MIME type leads to a crash.
1915
1916            Stop loading the resource and display an error page if QuickLook cannot provide a MIME type for the converted response.
1917
1918            No new tests. QuickLook is not testable from WebKit.
1919
1920            * platform/network/ios/QuickLook.mm:
1921            (-[WebResourceLoaderQuickLookDelegate _sendDidReceiveResponseIfNecessary]): Called ResourceLoader::didFail() if
1922            MIME type was nil. Called ResourceLoader::didReceiveResponse() otherwise.
1923            (-[WebResourceLoaderQuickLookDelegate connection:didReceiveDataArray:]): Called -_sendDidReceiveResponseIfNecessary.
1924            (-[WebResourceLoaderQuickLookDelegate connection:didReceiveData:lengthReceived:]): Ditto.
1925            (-[WebResourceLoaderQuickLookDelegate connection:didFailWithError:]): Ditto.
1926        
19272014-08-07  Dana Burkart <dburkart@apple.com>
1928
1929        Merge r172112
1930
1931    2014-08-05  Simon Fraser  <simon.fraser@apple.com>
1932
1933            [iOS WK2] Crash going back on a specific tumblr blog (under ScrollingStateTree::removeNodeAndAllDescendants)
1934            https://bugs.webkit.org/show_bug.cgi?id=135629
1935            <rdar://problem/17802174>
1936
1937            Reviewed by Tim Horton.
1938            
1939            In r170198 I added an "orphan scrolling nodes" code path that sets aside subtrees
1940            of scrolling nodes into an m_orphanedSubframeNodes map, which keeps them alive until
1941            they get reparented or destroyed. The nodes in that subtree remain in m_stateNodeMap,
1942            which holds raw pointers to them.
1943            
1944            However, ScrollingStateTree::commit() can clear m_orphanedSubframeNodes, which is
1945            sometimes non-empty at this point. When that happened, we would destroy nodes which
1946            were still referenced by m_stateNodeMap, with the result that a later query for the
1947            same nodeID would hand back a pointer to a deleted object.
1948            
1949            Fix by calling recursiveNodeWillBeRemoved() on nodes in the m_orphanedSubframeNodes
1950            before clearing it, which removes them and all their descendants from the state node map.
1951
1952            Test: platform/mac-wk2/tiled-drawing/scrolling/frames/orphaned-subtree.html
1953
1954            * page/scrolling/ScrollingStateTree.cpp:
1955            (WebCore::ScrollingStateTree::clear):
1956            (WebCore::ScrollingStateTree::commit):
1957
19582014-08-07  Dana Burkart  <dburkart@apple.com>
1959
1960        Merge r172035. <rdar://problem/17869353>
1961
1962    2014-08-04  Andy Estes  <aestes@apple.com>
1963
1964            [iOS] The raw bytes of an iWork document's PDF preview are displayed rather than the PDF itself
1965            https://bugs.webkit.org/show_bug.cgi?id=135596
1966
1967            Reviewed by David Kilzer.
1968
1969            Some iWork documents contain pre-rendered PDF previews. When WebKit asks QuickLook to convert such a document,
1970            QuickLook will return this PDF as the converted response. However, until WebKit has sent the document's data to
1971            QuickLook, -[QLPreviewConverter previewResponse] will misleadingly tell WebKit that the converted resource will
1972            be of type 'text/html'. This leads WebKit to render the PDF preview as HTML.
1973
1974            Instead of querying QLPreviewConverter for the previewResponse before we've sent it any data, postpone calling
1975            ResourceLoader::didReceiveResponse until we've begun to receive data via the QLPreviewConverter delegate. At
1976            that point -[QLPreviewConverter previewResponse] will have the correct MIME type and we can call didReceiveResponse.
1977
1978            No new tests. QuickLook is not testable from WebKit.
1979
1980            * platform/network/ios/QuickLook.mm:
1981            (-[WebResourceLoaderQuickLookDelegate connection:didReceiveDataArray:]): If didReceiveResponse has yet to be
1982            called, call it now with QuickLookHandle::nsResponse().
1983            (-[WebResourceLoaderQuickLookDelegate connection:didReceiveData:lengthReceived:]): Ditto.
1984            (-[WebResourceLoaderQuickLookDelegate connection:didFailWithError:]): Ditto.
1985            (-[WebResourceLoaderQuickLookDelegate connectionDidFinishLoading:]): Assert that didReceiveResponse has been called.
1986            (-[WebResourceLoaderQuickLookDelegate clearHandle]): Cleared the raw pointer to QuickLookHandle.
1987            (WebCore::QuickLookHandle::create): Pointed WebResourceLoaderQuickLookDelegate's quickLookHandle property to
1988            the newly created QuickLookHandle.
1989
19902014-08-06  Matthew Hanson  <matthew_hanson@apple.com>
1991
1992        Merge r172025. <rdar://problem/17715503>
1993
1994    2014-08-04  Jer Noble  <jer.noble@apple.com>
1995
1996            [MSE] Videos will report a stall when within 1 frame-duration before the end of a movie.
1997            https://bugs.webkit.org/show_bug.cgi?id=135586
1998
1999            Reviewed by Eric Carlson.
2000
2001            Under certain circumstances, videos which are within 1/24 seconds before the end of a media stream when
2002            monitorSourceBuffers() is called will fail the hasFutureTime() check. This is because hasFutureTime()
2003            checks whether enough media is buffered to play back at least some time in the future, but when the
2004            current time is close to the duration, not enough data is buffered to satisfy that check.
2005
2006            Add some logic which will break out early when the SourceBuffer has buffered up to and including the
2007            media's duration, and return that the buffer indeed hasFutureTime() available.
2008
2009            * Modules/mediasource/SourceBuffer.cpp:
2010            (WebCore::SourceBuffer::hasFutureTime):
2011
20122014-08-05  Dana Burkart  <dburkart@apple.com>
2013
2014        Merge r172114
2015
2016    2014-08-05  Brent Fulgham  <bfulgham@apple.com>
2017
2018            [Win] Build attempts to use ANGLE when not building WebGL.
2019            https://bugs.webkit.org/show_bug.cgi?id=135630
2020            <rdar://problem/135630>
2021
2022            Unreviewed build fix.
2023
2024            * platform/graphics/win/GraphicsContext3DWin.cpp: Move #include of GraphicsContext3D.h
2025            inside USE(3D_GRAPHICS) guard.
2026
20272014-08-05  Lucas Forschler  <lforschler@apple.com>
2028
2029        Merge r172083
2030
2031    2014-08-05  Dean Jackson  <dino@apple.com>
2032
2033            [iOS] Media controls layout incorrectly in RTL content
2034            https://bugs.webkit.org/show_bug.cgi?id=135621
2035            <rdar://problem/17849206>
2036
2037            Reviewed by Eric Carlson.
2038
2039            Media controls should always layout in LTR mode, even when the
2040            page content is RTL. There already was a rule to do this on
2041            non-iOS systems, but it wasn't getting included for iOS.
2042            In this case I put the rule on the composited parent of the
2043            controls in order to maintain the padding of the control panel.
2044            This should still leave the captions unaffected.
2045
2046            * Modules/mediacontrols/mediaControlsiOS.css:
2047            (video::-webkit-media-controls-panel-composited-parent): Add direction: ltr.
2048
20492014-08-05  Lucas Forschler  <lforschler@apple.com>
2050
2051        Merge r172053
2052
2053    2014-08-05  Antti Koivisto  <antti@apple.com>
2054
2055            REGRESSION: Extremely flashy scrolling while a page is still loading (because of flush throttling)
2056            https://bugs.webkit.org/show_bug.cgi?id=135603
2057            <rdar://problem/17876385>
2058
2059            This hit ASSERT(frame().isMainFrame()) in FrameView::updateLayerFlushThrottling
2060            running scrollbars/scrollbar-iframe-click-does-not-blur-content.html and a few other tests.
2061
2062            * page/FrameView.cpp:
2063            (WebCore::FrameView::setWasScrolledByUser): Only invoke updateLayerFlushThrottling for the main frame.
2064
20652014-08-05  Lucas Forschler  <lforschler@apple.com>
2066
2067        Merge r172039
2068
2069    2014-08-05  Antti Koivisto  <antti@apple.com>
2070
2071            REGRESSION: Extremely flashy scrolling while a page is still loading (because of flush throttling)
2072            https://bugs.webkit.org/show_bug.cgi?id=135603
2073            <rdar://problem/17876385>
2074
2075            Reviewed by Andreas Kling.
2076
2077            * page/FrameView.cpp:
2078            (WebCore::determineLayerFlushThrottleState):
2079
2080                Disable throttling after user has scrolled the page.
2081                This is consistent with the speculative tiling. It also gets enabled on first scroll.
2082
2083            (WebCore::FrameView::setWasScrolledByUser):
2084
20852014-08-05  Lucas Forschler  <lforschler@apple.com>
2086
2087        Merge r172032
2088
2089    2014-08-05  Jer Noble  <jer.noble@apple.com>
2090
2091            [MSE] Seeking occasionally causes many frames to be displayed in "fast forward" mode
2092            https://bugs.webkit.org/show_bug.cgi?id=135422
2093
2094            Reviewed by Eric Carlson.
2095
2096            Three related fixes:
2097
2098            In reenqueueMediaForTime(), update TrackBuffer.lastEnqueuedPresentationTime when we flush
2099            samples, so that the next time samples are re-enqueued, the starting point for re-enqueueing
2100            is correct.
2101
2102            In sourceBufferPrivateDidReceiveSample(), do not add samples to the decode queue
2103            if they are before the current media time.
2104
2105            When a seek is pending, but samples for the new time is not yet present in the SourceBuffer,
2106            the SourceBufferPrivate may signal that it's ready for new samples through the
2107            sourceBufferPrivateDidBecomeReadyForMoreSamples() method. In this situation, we should not
2108            continue to provideMediaData(), as that will append samples from the prior-to-seeking media
2109            timeline. Since the timeline may have moved forward due to the seek, a decoder may decide to
2110            display those frames as quickly as possible (the "fast forward" behavior) in order to catch
2111            up to the new current time.
2112
2113            If a re-enqueue is pending, don't provide media data in response to being notified that the
2114            SourceBufferPrivate is ready for more samples. Wait until samples for the new current time
2115            are appended.
2116
2117            Also, don't provide media data if we are waiting for a seek to complete.
2118
2119            * Modules/mediasource/MediaSource.h:
2120            (WebCore::MediaSource::isSeeking): Convenience method.
2121            * Modules/mediasource/SourceBuffer.cpp:
2122            (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
2123            (WebCore::SourceBuffer::sourceBufferPrivateDidBecomeReadyForMoreSamples):
2124            (WebCore::SourceBuffer::reenqueueMediaForTime):
2125
21262014-08-05  Lucas Forschler  <lforschler@apple.com>
2127
2128        Merge r172028
2129
2130    2014-08-05  Chris Fleizach  <cfleizach@apple.com>
2131
2132            AX: Select text activity should return replaced text instead of previously selected text
2133            https://bugs.webkit.org/show_bug.cgi?id=135595
2134
2135            Reviewed by Mario Sanchez Prada.
2136
2137            When the select activity API is used to replace text, the replacement string should be returned instead of the old selected text.
2138
2139            Updated existing test: platform/mac/accessibility/select-text.html
2140
2141            * accessibility/AccessibilityObject.cpp:
2142            (WebCore::AccessibilityObject::selectText):
2143
21442014-08-05  Lucas Forschler  <lforschler@apple.com>
2145
2146        Merge r172026
2147
2148    2014-08-04  Jer Noble  <jer.noble@apple.com>
2149
2150            [MSE][Mac] Seeking past buffered range will not resume playback when seek completes.
2151            https://bugs.webkit.org/show_bug.cgi?id=135591
2152
2153            Reviewed by Eric Carlson.
2154
2155            If a seek is delayed due to seeking into an unbuffered area, playback will not be restarted
2156            at that point. Instead, playback must resume when enough media data has been added, and
2157            the MediaSource indicates the seek should complete.
2158
2159            * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
2160            (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekCompleted):
2161
21622014-08-05  Lucas Forschler  <lforschler@apple.com>
2163
2164        Merge r172018
2165
2166    2014-08-04  Tim Horton  <timothy_horton@apple.com>
2167
2168            Lots of crashes in WebKit1 after r172013.
2169            https://bugs.webkit.org/show_bug.cgi?id=135582
2170            <rdar://problem/17837636>
2171
2172            Reviewed by Enrica Casucci.
2173
2174            * editing/SelectionRectGatherer.cpp:
2175            (WebCore::SelectionRectGatherer::addRect):
2176            (WebCore::SelectionRectGatherer::addGapRects):
2177            Don't try to do local-to-absolute coordinate conversion if we don't have
2178            a repaint container, which happens a lot in WebKit1.
2179
21802014-08-05  Lucas Forschler  <lforschler@apple.com>
2181
2182        Merge r172013
2183
2184    2014-08-04  Tim Horton  <timothy_horton@apple.com>
2185
2186            Selection services menu dropdown is in the wrong place when selecting some text on Yelp
2187            https://bugs.webkit.org/show_bug.cgi?id=135582
2188            <rdar://problem/17837636>
2189
2190            Reviewed by Simon Fraser.
2191
2192            * editing/SelectionRectGatherer.cpp:
2193            (WebCore::SelectionRectGatherer::addRect):
2194            (WebCore::SelectionRectGatherer::addGapRects):
2195            (WebCore::SelectionRectGatherer::addRects): Deleted.
2196            Rename addRects to addGapRects for clarity.
2197            Map rects and gapRects to absolute RenderView coordinates so that
2198            they are in a form WebKit2 can use. Previously they were sometimes
2199            relative to a different repaint container, but that information was
2200            lost when moving through SelectionRectGatherer.
2201
2202            Ideally we would keep selection rects as full quads instead of rects
2203            for more of their life, but that problem is much deeper than just SelectionRectGatherer.
2204
2205            * editing/SelectionRectGatherer.h:
2206            Add a comment clarifying the coordinate space of the stored selection rects.
2207
2208            * rendering/RenderView.cpp:
2209            (WebCore::RenderView::applySubtreeSelection):
2210            Rename addRects to addGapRects for clarity.
2211
22122014-08-05  Lucas Forschler  <lforschler@apple.com>
2213
2214        Merge r172006
2215
2216    2014-08-04  Joseph Pecoraro  <pecoraro@apple.com>
2217
2218            Always clear ConsoleClient when Page/WindowShell is destroyed
2219            https://bugs.webkit.org/show_bug.cgi?id=135569
2220
2221            Reviewed by Mark Lam.
2222
2223            * bindings/js/ScriptController.cpp:
2224            (WebCore::ScriptController::~ScriptController):
2225            Whenever a window shell goes away, clear the console client.
2226            We did this in clearWindowShell but not before destroying.
2227
22282014-08-05  Lucas Forschler  <lforschler@apple.com>
2229
2230        Merge r171973
2231
2232    2014-08-02  Jeremy Jones  <jeremyj@apple.com>
2233
2234            Support both window and view based video fullscreen.
2235            https://bugs.webkit.org/show_bug.cgi?id=135525
2236
2237            Reviewed by Simon Fraser.
2238
2239            Presenting in a separate window gives greater flexibility for rotation separately from the app.
2240            Presenting in the same window works better if the interface is rehosted in another process.
2241
2242            * platform/ios/WebVideoFullscreenControllerAVKit.mm:
2243            (-[WebVideoFullscreenController enterFullscreen:]): Use clientRect instead of screenRect.
2244            * platform/ios/WebVideoFullscreenInterfaceAVKit.h: Add m_window and m_parentView.
2245            * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: 
2246            (-[WebAVVideoLayer setBounds:]): Parent view might not be fullscreen; use window instead.
2247            (WebVideoFullscreenInterfaceAVKit::setupFullscreen): Conditionally create UIWindow and UIViewController for fullscreen.
2248            (WebVideoFullscreenInterfaceAVKit::enterFullscreen): Video, not the container should have black background.
2249            (WebVideoFullscreenInterfaceAVKit::exitFullscreen): Conditionally translate finalRect.
2250            (WebVideoFullscreenInterfaceAVKit::cleanupFullscreen): Clean up UIWindow and force status bar to correct orientation.
2251            (WebVideoFullscreenInterfaceAVKit::invalidate): Clean up UIWindow.
2252            (WebVideoFullscreenInterfaceAVKit::requestHideAndExitFullscreen): Hide window and exit without animation.
2253            * platform/ios/WebVideoFullscreenModelMediaElement.mm:
2254            (WebVideoFullscreenModelMediaElement::setVideoFullscreenLayer): Apply frame, because it may have been set before the layer.
2255
22562014-08-05  Lucas Forschler  <lforschler@apple.com>
2257
2258        Merge r171952
2259
2260    2014-08-01  Beth Dakin  <bdakin@apple.com>
2261
2262            Inspector highlights clipped at the bottom on the page in WK1 views with 
2263            contentInsets
2264            https://bugs.webkit.org/show_bug.cgi?id=135480
2265            -and corresponding-
2266            <rdar://problem/17850323>
2267
2268            Forgot to commit this one very critical part with 
2269            http://trac.webkit.org/changeset/171951 
2270
2271            * platform/ScrollView.cpp:
2272            (WebCore::ScrollView::unscaledVisibleContentSizeIncludingObscuredArea):
2273
22742014-08-05  Lucas Forschler  <lforschler@apple.com>
2275
2276        Merge r171951
2277
2278    2014-08-01  Beth Dakin  <bdakin@apple.com>
2279
2280            Inspector highlights clipped at the bottom on the page in WK1 views with 
2281            contentInsets
2282            https://bugs.webkit.org/show_bug.cgi?id=135480
2283            -and corresponding-
2284            <rdar://problem/17850323>
2285
2286            Reviewed by Simon Fraser.
2287
2288            unscaledTotalVisibleContentSize() was the main function on Mac that was expected 
2289            to return the rect representing ALL visible content, including content that might 
2290            be in an inset area and obscured by UI elements. This patch re-names that function 
2291            to unscaledVisibleContentSizeIncludingObscuredArea(), and that patch makes that 
2292            function return the right thing in the platformWidget() case.
2293
2294            Re-name.
2295            * inspector/InspectorOverlay.cpp:
2296            (WebCore::InspectorOverlay::update):
2297
2298            Return platformVisibleContentSizeIncludingObscuredArea() for the platformWidget() 
2299            case and re-name.
2300            * platform/ScrollView.cpp:
2301            (WebCore::ScrollView::unscaledVisibleContentSizeIncludingObscuredArea):
2302
2303            This was just wrong. It was returning the big rectangle instead of the small one 
2304            for platformWidget().
2305            (WebCore::ScrollView::unscaledUnobscuredVisibleContentSize):
2306
2307            New platform functions.
2308            (WebCore::ScrollView::platformVisibleContentRectIncludingObscuredArea):
2309            (WebCore::ScrollView::platformVisibleContentSizeIncludingObscuredArea):
2310            (WebCore::ScrollView::unscaledTotalVisibleContentSize): Deleted.
2311            * platform/ScrollView.h:
2312            * platform/ios/ScrollViewIOS.mm:
2313            (WebCore::ScrollView::platformVisibleContentRectIncludingObscuredArea):
2314            (WebCore::ScrollView::platformVisibleContentSizeIncludingObscuredArea):
2315            * platform/mac/ScrollViewMac.mm:
2316            (WebCore::ScrollView::platformVisibleContentRect):
2317            (WebCore::ScrollView::platformVisibleContentSize):
2318            (WebCore::ScrollView::platformVisibleContentRectIncludingObscuredArea):
2319            (WebCore::ScrollView::platformVisibleContentSizeIncludingObscuredArea):
2320
2321            Re-name.
2322            * rendering/RenderLayerCompositor.cpp:
2323            (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
2324            (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
2325            (WebCore::RenderLayerCompositor::updateRootLayerPosition):
2326            (WebCore::RenderLayerCompositor::ensureRootLayer):
2327
23282014-08-05  Lucas Forschler  <lforschler@apple.com>
2329
2330        Merge r172047
2331
2332    2014-08-05  Dean Jackson  <dino@apple.com>
2333
2334            [Media iOS] Ensure there is a nice default fallback for missing wireless target names
2335            https://bugs.webkit.org/show_bug.cgi?id=135488
2336            <rdar://problem/17879156>
2337
2338            Reviewed by Antoine Quint.
2339
2340            Antoine found me on iMessage to tell me I'm an idiot and that I've
2341            forgotten how to write JavaScript. Embarrassingly, this code is what
2342            I originally had, but then second-guessed myself.
2343
2344            * Modules/mediacontrols/mediaControlsiOS.js:
2345            (ControllerIOS.prototype.updateWirelessPlaybackStatus): No need for the local
2346            variable or conditional statement, since null and "" both evaluate as false.
2347
23482014-08-05  Lucas Forschler  <lforschler@apple.com>
2349
2350        Merge r171944
2351
2352    2014-07-31  Dean Jackson  <dino@apple.com>
2353
2354            [Media iOS] Ensure there is a nice default fallback for missing wireless target names
2355            https://bugs.webkit.org/show_bug.cgi?id=135488
2356            <rdar://problem/17879156>
2357
2358            Reviewed by Eric Carlson.
2359
2360            We occasionally run into cases where this.host.externalDeviceDisplayName
2361            is empty or null, creating a pretty ugly/confusing string in the
2362            wireless playback status screen.
2363
2364            If this happens, we should default to using "Apple TV".
2365
2366            * Modules/mediacontrols/mediaControlsiOS.js:
2367            (ControllerIOS.prototype.updateWirelessPlaybackStatus): Check if the externalDeviceDisplayName
2368            is empty or null, and fall back to "Apple TV" if so.
2369
23702014-08-05  Lucas Forschler  <lforschler@apple.com>
2371
2372        Merge r171937
2373
2374    2014-08-01  Jer Noble  <jer.noble@apple.com>
2375
2376            [MSE][Mac] Volume is not remembered between items in a YouTube playlist
2377            https://bugs.webkit.org/show_bug.cgi?id=135479
2378
2379            Reviewed by Eric Carlson.
2380
2381            When an AVSampleBufferAudioRenderer is added to the player, set its -volume and -muted
2382            properties with the current values from the HTMLMediaElement. 
2383
2384            * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
2385            (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::addAudioRenderer):
2386
23872014-08-05  Lucas Forschler  <lforschler@apple.com>
2388
2389        Merge r171895
2390
2391    2014-07-31  Jer Noble  <jer.noble@apple.com>
2392
2393            [iOS] Video in an <embed> has a bad aspect ratio when in fullscreen mode.
2394            https://bugs.webkit.org/show_bug.cgi?id=135481
2395
2396            Reviewed by Simon Fraser.
2397
2398            Do not change the gravity of our AVPlayerLayer when in full screen mode; its gravity
2399            is controlled by setVideoFullscreenGravity(), and should not be affected by style changes.
2400
2401            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2402            (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoLayerGravity):
2403
24042014-08-05  Lucas Forschler  <lforschler@apple.com>
2405
2406        Merge r171932
2407
2408    2014-08-01  Tim Horton  <timothy_horton@apple.com>
2409
2410            Fix the iOS build after r171891
2411
2412            * platform/ios/ScrollViewIOS.mm:
2413            (WebCore::ScrollView::platformTopContentInset):
2414            (WebCore::ScrollView::platformSetTopContentInset):
2415
24162014-08-05  Lucas Forschler  <lforschler@apple.com>
2417
2418        Merge r171905
2419
2420    2014-07-31  Timothy Horton  <timothy_horton@apple.com>
2421
2422            Build fix for platforms where we should have automaticallyAdjustsContentInsets but it isn't public yet
2423
2424            * platform/mac/ScrollViewMac.mm:
2425
24262014-08-05  Lucas Forschler  <lforschler@apple.com>
2427
2428        Merge r171891
2429
2430    2014-07-31  Beth Dakin  <bdakin@apple.com>
2431
2432            Hit-testing broken in WebKit 1 views with AppKit's contentInsets
2433            https://bugs.webkit.org/show_bug.cgi?id=135434
2434            -and corresponding-
2435            <rdar://problem/17850323>
2436
2437            Reviewed by Benjamin Poulain.
2438
2439            AppKit's contentInsets are factored into scroll positions and mouse positions, but
2440            in WebCore, we generally want all of those things to be factored out so that, for
2441            example, the scroll position of a document pinned to the top is the same whether
2442            or not there is a contentInset. So to fix hit-testing in WebKit 1 views with
2443            contentInsets, this patch factors the inset out or into of all coordinate
2444            conversion methods just like we do for the WebKit2 contentInset.
2445
2446            This patch also adds the ability to test WK1 platformContentInsets with
2447            window.internals, and it re-names convertFromRenderer to 
2448            convertFromRendererToContainingView and also re-names convertToRenderer to
2449            convertFromContainingViewToRenderer.
2450
2451            ScrollView::topContentInset() takes an optional parameter indicating whether the
2452            caller wants the WebCore::Page contentInset or the platform content inset. It’s
2453            necessary to distinguish between these cases because there is a lot of code that
2454            only wants the WebCore::Page contentInset since that feature is actually
2455            implemented in WebCore as opposed to being implemented at the platform level.
2456            * WebCore.exp.in:
2457            * page/FrameView.cpp:
2458            (WebCore::FrameView::topContentInset):
2459
2460            For layout test purposes, set the platforTopContentInset here if there is a 
2461            platformWidget().
2462            (WebCore::FrameView::topContentInsetDidChange):
2463
2464            Re-named functions, also all coordinate conversion functions call 
2465            topContentInset(ManualOrPlatformContentInset)
2466            (WebCore::FrameView::convertFromContainingViewToRenderer):
2467            (WebCore::FrameView::convertToContainingView):
2468            (WebCore::FrameView::convertFromContainingView):
2469            (WebCore::FrameView::convertFromRenderer): Deleted.
2470            (WebCore::FrameView::convertToRenderer): Deleted.
2471            * page/FrameView.h:
2472            * page/Page.cpp:
2473            (WebCore::Page::setTopContentInset):
2474            * platform/ScrollView.cpp:
2475            (WebCore::ScrollView::documentScrollOffsetRelativeToViewOrigin):
2476            (WebCore::ScrollView::documentScrollPositionRelativeToViewOrigin):
2477            (WebCore::ScrollView::contentsToRootView):
2478            (WebCore::ScrollView::rootViewToTotalContents):
2479            (WebCore::ScrollView::contentsToWindow):
2480            (WebCore::ScrollView::platformTopContentInset):
2481            (WebCore::ScrollView::platformSetTopContentInset):
2482            * platform/ScrollView.h:
2483            (WebCore::ScrollView::topContentInset):
2484            * platform/ios/ScrollViewIOS.mm:
2485            (WebCore::ScrollView::platformTopContentInset):
2486            (WebCore::ScrollView::platformSetTopContentInset):
2487
2488            Implement new platform inset-related functions using AppKit's implementation.
2489            * platform/mac/ScrollViewMac.mm:
2490            (WebCore::ScrollView::platformTopContentInset):
2491            (WebCore::ScrollView::platformSetTopContentInset):
2492
2493            When we set the scroll position for the documentView, we have to factor the inset
2494            back into the WebCore scroll position.
2495            (WebCore::ScrollView::platformSetScrollPosition):
2496
2497            Re-named functions.
2498            * rendering/RenderLayer.cpp:
2499            (WebCore::RenderLayer::convertFromScrollbarToContainingView):
2500            (WebCore::RenderLayer::convertFromContainingViewToScrollbar):
2501            * rendering/RenderListBox.cpp:
2502            (WebCore::RenderListBox::convertFromScrollbarToContainingView):
2503            (WebCore::RenderListBox::convertFromContainingViewToScrollbar):
2504
25052014-08-05  Lucas Forschler  <lforschler@apple.com>
2506
2507        Merge r171889
2508
2509    2014-07-31  Tim Horton  <timothy_horton@apple.com>
2510
2511            DOM::renderedImageForcingBlackText returns an image with the wrong logical size on 2x displays
2512            https://bugs.webkit.org/show_bug.cgi?id=135442
2513            <rdar://problem/17614632>
2514
2515            Reviewed by Simon Fraser.
2516
2517            * bindings/objc/DOM.mm:
2518            (-[DOMRange renderedImageForcingBlackText:renderedImageForcingBlackText:]):
2519            Scale the NSImage size by the device scale factor,
2520            similar to what we did for drag images in r167403.
2521            Ideally this scaling would happen in the code that
2522            generates the images, but this is a much larger change
2523            with much more regression potential.
2524
25252014-08-05  Lucas Forschler  <lforschler@apple.com>
2526
2527        Merge r171882
2528
2529    2014-07-31  Andrei Bucur  <abucur@adobe.com>
2530
2531            REGRESSION: Search highlight is broken in RTL multicolumn content
2532            https://bugs.webkit.org/show_bug.cgi?id=135452
2533
2534            Reviewed by Simon Fraser.
2535
2536            The offsets for elements inside RTL multi-column elements are incorrectly computed because
2537            the columns don't calculate their left position according to the writing direction.
2538
2539            The patch extracts the column position computation in two helper functions (for top and left)
2540            so they can be used when needed in different parts of the code. In our case, the |columnLogicalLeft|
2541            function should be used inside |columnTranslationForOffset|.
2542
2543            Test: fast/multicol/content-bounding-box-rtl.html
2544
2545            * rendering/RenderMultiColumnSet.cpp:
2546            (WebCore::RenderMultiColumnSet::columnLogicalLeft): Return the logical left of a column relative to the set.
2547            (WebCore::RenderMultiColumnSet::columnLogicalTop): Return the logical top of a column relative to the set.
2548            (WebCore::RenderMultiColumnSet::columnRectAt): Split the code between columnLogicalLeft and columnLogicalTop.
2549            (WebCore::RenderMultiColumnSet::collectLayerFragments): Make code clearer by adding a new line.
2550            (WebCore::RenderMultiColumnSet::columnTranslationForOffset): Use columnLogicalLeft instead of duplicating logic.
2551            * rendering/RenderMultiColumnSet.h:
2552
25532014-08-05  Lucas Forschler  <lforschler@apple.com>
2554
2555        Merge r171866
2556
2557    2014-07-31  Joseph Pecoraro  <pecoraro@apple.com>
2558
2559            Web Inspector: console.profile missing profile information
2560            https://bugs.webkit.org/show_bug.cgi?id=135432
2561
2562            Reviewed by Timothy Hatcher.
2563
2564            By switching console.profile to start/stop the timeline we would
2565            not have a chance to recompile JS functions with profiling information.
2566            This used to work because whenever the inspector was open we would
2567            have profiling information enabled. Go back to that behavior.
2568
2569            * inspector/InspectorController.cpp:
2570            (WebCore::InspectorController::profilerEnabled):
2571            Instead of checking if the timeline agent has started, check if the
2572            timeline agent has been created. Going back to the normal behavior
2573            of always having profiling information when the inspector is open.
2574
2575            * inspector/InspectorTimelineAgent.h:
2576            * inspector/InspectorTimelineAgent.cpp:
2577            (WebCore::InspectorTimelineAgent::didCreateFrontendAndBackend):
2578            Recompile initializing the timeline agent to include profiling information.
2579
2580            (WebCore::InspectorTimelineAgent::willDestroyFrontendAndBackend):
2581            Recompile destrying the timeline agent, only if needed.
2582
2583            (WebCore::InspectorTimelineAgent::willCallFunction):
2584            (WebCore::InspectorTimelineAgent::didCallFunction):
2585            (WebCore::InspectorTimelineAgent::willEvaluateScript):
2586            (WebCore::InspectorTimelineAgent::didEvaluateScript):
2587            Using a boolean to track nested calls would not give expected
2588            behavior when un-nesting. Switch to a counter to ensure that
2589            as we start profiling in the outermost level we then stop
2590            profiling at that same level and not inside an inner nesting.
2591
25922014-08-05  Lucas Forschler  <lforschler@apple.com>
2593
2594        Merge r171866
2595
2596    2014-07-31  Joseph Pecoraro  <pecoraro@apple.com>
2597
2598            Web Inspector: console.profile missing profile information
2599            https://bugs.webkit.org/show_bug.cgi?id=135432
2600
2601            Reviewed by Timothy Hatcher.
2602
2603            By switching console.profile to start/stop the timeline we would
2604            not have a chance to recompile JS functions with profiling information.
2605            This used to work because whenever the inspector was open we would
2606            have profiling information enabled. Go back to that behavior.
2607
2608            * inspector/InspectorController.cpp:
2609            (WebCore::InspectorController::profilerEnabled):
2610            Instead of checking if the timeline agent has started, check if the
2611            timeline agent has been created. Going back to the normal behavior
2612            of always having profiling information when the inspector is open.
2613
2614            * inspector/InspectorTimelineAgent.h:
2615            * inspector/InspectorTimelineAgent.cpp:
2616            (WebCore::InspectorTimelineAgent::didCreateFrontendAndBackend):
2617            Recompile initializing the timeline agent to include profiling information.
2618
2619            (WebCore::InspectorTimelineAgent::willDestroyFrontendAndBackend):
2620            Recompile destrying the timeline agent, only if needed.
2621
2622            (WebCore::InspectorTimelineAgent::willCallFunction):
2623            (WebCore::InspectorTimelineAgent::didCallFunction):
2624            (WebCore::InspectorTimelineAgent::willEvaluateScript):
2625            (WebCore::InspectorTimelineAgent::didEvaluateScript):
2626            Using a boolean to track nested calls would not give expected
2627            behavior when un-nesting. Switch to a counter to ensure that
2628            as we start profiling in the outermost level we then stop
2629            profiling at that same level and not inside an inner nesting.
2630
26312014-08-05  Lucas Forschler  <lforschler@apple.com>
2632
2633        Merge r171851
2634
2635    2014-07-31  Jer Noble  <jer.noble@apple.com>
2636
2637            REGRESSION(??): [iOS] Disabling MediaPlaybackRequiresUserGesture does not remove user gesture requirement for entering full screen.
2638            https://bugs.webkit.org/show_bug.cgi?id=135443
2639
2640            Reviewed by Dean Jackson.
2641
2642            Allow full screen mode to be entered without a user gesture if the gesture requirement for media playback
2643            has been unset.
2644
2645            * html/HTMLMediaElement.cpp:
2646            (WebCore::HTMLMediaElement::HTMLMediaElement):
2647
26482014-08-05  Lucas Forschler  <lforschler@apple.com>
2649
2650        Merge r171292
2651
2652    2014-07-20  Pratik Solanki  <psolanki@apple.com>
2653
2654            Reduce the chances of a race condition when sharing SharedBuffer
2655            https://bugs.webkit.org/show_bug.cgi?id=135060
2656            <rdar://problem/17729444>
2657
2658            Reviewed by Darin Adler.
2659
2660            We currently pass a SharedBuffer wrapped in WebCoreSharedBufferData to ImageIO for image
2661            decoding. This is not thread safe since ImageIO will access this buffer on a separate
2662            thread. We access SharedBuffer::buffer() on the other thread which resizes the Vector
2663            m_buffer if m_size is greater than the vector size. Since the code in SharedBuffer::append()
2664            sets m_size before appending the data to the buffer, m_size is out of sync with the m_buffer
2665            size for the entire duration of the Vector append which could be doing a lot of copying if
2666            the resource is large. While this change does not fix the race condition, we can at least
2667            reduce the chances of SharedBuffer::buffer() calling resize() by setting m_size after the
2668            cector has finished appending.
2669
2670            No new tests because no functional changes.
2671
2672            * platform/SharedBuffer.cpp:
2673            (WebCore::SharedBuffer::append):
2674
26752014-08-05  Lucas Forschler  <lforschler@apple.com>
2676
2677        Merge r171279
2678
2679    2014-07-20  Eric Carlson  <eric.carlson@apple.com>
2680
2681            [iOS] ignore requests to set volume
2682            https://bugs.webkit.org/show_bug.cgi?id=135081
2683
2684            Applied post-review comments from Darin Adler.
2685
2686            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2687            (WebCore::MediaPlayerPrivateAVFoundationObjC::setVolume): Don't include unreachable
2688                code on iOS.
2689
26902014-08-05  Lucas Forschler  <lforschler@apple.com>
2691
2692        Merge r171259
2693
2694    2014-07-18  Eric Carlson  <eric.carlson@apple.com>
2695
2696            [iOS] ignore requests to set volume
2697            https://bugs.webkit.org/show_bug.cgi?id=135081
2698
2699            Reviewed by Jer Noble.
2700
2701            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2702            (WebCore::MediaPlayerPrivateAVFoundationObjC::setVolume): Do nothing on iOS.
2703
27042014-07-30  Lucas Forschler  <lforschler@apple.com>
2705
2706        Merge r171802
2707
2708    2014-07-30  Dan Bernstein  <mitz@apple.com>
2709
2710            <rdar://problem/17199364> [Mac] Popup button arrows appear on the left, underlapping text, when the UI layout direction is right-to-left
2711            https://bugs.webkit.org/show_bug.cgi?id=135426
2712
2713            Reviewed by Dean Jackson.
2714
2715            No test, because the UI layout direction in the test harness is always left-to-right.
2716
2717            * rendering/RenderThemeMac.mm:
2718            (WebCore::RenderThemeMac::popupButton): Forced the user interface layout direction of the
2719            NSPopUpButtonCell to left-to-right. Added a FIXME about how we could make this vary based on
2720            the direction of the <select>, though that would require additional changes elsewhere.
2721
27222014-07-30  Lucas Forschler  <lforschler@apple.com>
2723
2724        Merge r171785
2725
2726    2014-07-29  Andreas Kling  <akling@apple.com>
2727
2728            Crash when using 'em' units to specify font-size inside animation keyframe.
2729            <https://webkit.org/b/135395>
2730            <rdar://problem/17851910>
2731
2732            We'd forgotten to initialize the "parent style" when resolving keyframe
2733            styles, and this led to a crash in length conversion where the code
2734            assumes a parent style will be present.
2735
2736            To keep this fix minimal, simply make the "parent style" a clone of the
2737            base element style.
2738
2739            Reviewed by Simon Fraser.
2740
2741            Test: fast/animation/keyframe-with-font-size-in-em-units.html
2742
2743            * css/StyleResolver.cpp:
2744            (WebCore::StyleResolver::styleForKeyframe):
2745
27462014-07-30  Lucas Forschler  <lforschler@apple.com>
2747
2748        Merge r171766
2749
2750    2014-07-29  Pratik Solanki  <psolanki@apple.com>
2751
2752            [iOS] REGRESSION(r171526): PDF documents fail to load in WebKit1 with disk image caching enabled
2753            https://bugs.webkit.org/show_bug.cgi?id=135359
2754            <rdar://problem/17824645>
2755
2756            Reviewed by Darin Adler.
2757
2758            r171526 broke the case where we have a memory mapped file from the DiskImageCache in the
2759            SharedBuffer. In such a case, m_buffer is empty and createCFData() returned an
2760            WebCoreSharedBufferData with an empty buffer.
2761
2762            Fix this by taking the easy route of bringing back the old code for the disk image cache
2763            file backed case. In the long run we probably want to remove the iOS specific disk image
2764            cache anyway.
2765
2766            Review also uncovered another bug in r171526 where we were balancing an Objective-C alloc
2767            with a CFRelease which is incorrect when running under GC. Fix that by using adoptNS along
2768            with adoptCF which is what the code did before.
2769
2770            No new tests because the bug only occurs on device and we can't run tests on device yet.
2771
2772            * platform/mac/SharedBufferMac.mm:
2773            (-[WebCoreSharedBufferData initWithDiskImageSharedBuffer:]):
2774            (-[WebCoreSharedBufferData length]):
2775            (-[WebCoreSharedBufferData bytes]):
2776            (WebCore::SharedBuffer::createCFData):
2777
27782014-07-30  Lucas Forschler  <lforschler@apple.com>
2779
2780        Merge r171749
2781
2782    2014-07-29  Brady Eidson  <beidson@apple.com>
2783
2784            Make WKOriginDataManager actually operate on IndexedDatabases.
2785            https://bugs.webkit.org/show_bug.cgi?id=135346
2786
2787            Reviewed by Sam Weinig (and David Kilzer and Alex Christensen)
2788
2789            * WebCore.exp.in:
2790
27912014-07-30  Lucas Forschler  <lforschler@apple.com>
2792
2793        Merge r171718
2794
2795    2014-07-28  Zalan Bujtas  <zalan@apple.com>
2796
2797            REGRESSION(r164133): Selection disappears after scrolling on nytimes.com
2798            https://bugs.webkit.org/show_bug.cgi?id=135361
2799
2800            Reviewed by Ryosuke Niwa.
2801
2802            Ensure that when a RenderElement, part of the current selection is removed,
2803            we recalculate and update the selection soon after layout.
2804
2805            Test: fast/dynamic/selection-gets-cleared-when-part-of-it-gets-removed.html
2806
2807            * editing/FrameSelection.cpp:
2808            (WebCore::FrameSelection::setNeedsSelectionUpdate):
2809            (WebCore::FrameSelection::didLayout): didLayout name reflects its functionality better.
2810            (WebCore::FrameSelection::layoutDidChange): Deleted.
2811            * editing/FrameSelection.h: : move some functions to private.
2812            * page/FrameView.cpp:
2813            (WebCore::FrameView::performPostLayoutTasks):
2814            * rendering/RenderBlockFlow.cpp:
2815            (WebCore::RenderBlockFlow::willBeDestroyed):
2816            * rendering/RenderElement.cpp:
2817            (WebCore::RenderElement::removeChildInternal):
2818            * rendering/RenderInline.cpp:
2819            (WebCore::RenderInline::willBeDestroyed):
2820
28212014-07-29  Lucas Forschler  <lforschler@apple.com>
2822
2823        Merge r171711
2824
2825    2014-07-28  Dean Jackson  <dino@apple.com>
2826
2827            [Media iOS] Touching play button feels unresponsive
2828            https://bugs.webkit.org/show_bug.cgi?id=135370
2829            <rdar://problem/17756281>
2830
2831            Reviewed by Simon Fraser.
2832
2833            Add an :active rule that shows a slightly darker button when touched.
2834
2835            * Modules/mediacontrols/mediaControlsiOS.css:
2836            (audio::-webkit-media-controls-start-playback-button:active):
2837
28382014-07-29  Lucas Forschler  <lforschler@apple.com>
2839
2840        Merge r171708
2841
2842    2014-07-28  Brady Eidson  <beidson@apple.com>
2843
2844            REGRESSION(168376): Standalone images pasted to Outlook 2011 don't display
2845            <rdar://problem/17768371> and https://bugs.webkit.org/show_bug.cgi?id=135363
2846
2847            Reviewed by Tim Horton.
2848
2849            Outlook isn’t prepared to handle the resource load callbacks when sent synchronously.
2850
2851            r168376 was an optimization that we no longer need, so the simplest fix is to roll it out.
2852
2853            * editing/mac/EditorMac.mm:
2854            (WebCore::Editor::WebContentReader::readImage):
2855
2856            * loader/archive/ArchiveResource.cpp:
2857            (WebCore::ArchiveResource::ArchiveResource):
2858            * loader/archive/ArchiveResource.h:
2859            (WebCore::ArchiveResource::setShouldLoadImmediately): Deleted.
2860            (WebCore::ArchiveResource::shouldLoadImmediately): Deleted.
2861
2862            * loader/cache/CachedResourceLoader.cpp:
2863            (WebCore::CachedResourceLoader::requestResource):
2864
28652014-07-29  Lucas Forschler  <lforschler@apple.com>
2866
2867        Merge r171703
2868
2869    2014-07-28  Mark Hahnenberg  <mhahnenberg@apple.com>
2870
2871            ASSERTION FAILED: m_heap->vm()->currentThreadIsHoldingAPILock()
2872            https://bugs.webkit.org/show_bug.cgi?id=135352
2873
2874            Reviewed by Oliver Hunt.
2875
2876            * Modules/plugins/QuickTimePluginReplacement.mm:
2877            (WebCore::QuickTimePluginReplacement::ensureReplacementScriptInjected): This should be taking a 
2878            JSLock like its sibling methods do (e.g. installReplacement).
2879
28802014-07-29  Lucas Forschler  <lforschler@apple.com>
2881
2882        Merge r171702
2883
2884    2014-07-28  Antti Koivisto  <antti@apple.com>
2885
2886            <embed> videos flashes constantly while playing inline on iPad, making it unwatchable
2887            https://bugs.webkit.org/show_bug.cgi?id=135356
2888            <rdar://problem/16828238>
2889
2890            Reviewed by Simon Fraser.
2891
2892            The shadow tree for media controls is scheduling style recalc. The general silliness of
2893            HTMLPlugInImageElement::willRecalcStyle/willDetachRenderers is turning those into render
2894            tree reconstructions causing flicker.
2895
2896            * html/HTMLPlugInImageElement.cpp:
2897            (WebCore::HTMLPlugInImageElement::willRecalcStyle):
2898
2899                Don't do the forced renderer reconstruction if there is no style change for the element
2900                or its ancestors. This way recalcs scheduled by the shadow tree don't trigger the widget
2901                update code path.
2902
29032014-07-29  Lucas Forschler  <lforschler@apple.com>
2904
2905        Merge r171700
2906
2907    2014-07-27  Brent Fulgham  <bfulgham@apple.com>
2908
2909            [Mac, iOS] Paint-on closed captions get out-of-order in Safari
2910            https://bugs.webkit.org/show_bug.cgi?id=135332
2911            <rdar://problem/15317278>
2912
2913            Reviewed by Brent Fulgham.
2914
2915            * html/shadow/MediaControlElements.cpp:
2916            (WebCore::MediaControlTextTrackContainerElement::updateDisplay): If the
2917            number of active cues is greater than the current set of CSS boxes representing
2918            the cues, throw away the CSS boxes and re-layout all the cues.
2919            * html/track/InbandGenericTextTrack.cpp:
2920            (WebCore::InbandGenericTextTrack::addGenericCue): Add some logging.
2921            (WebCore::InbandGenericTextTrack::removeGenericCue): Ditto.
2922            * html/track/TextTrackCueGeneric.cpp:
2923            (WebCore::TextTrackCueGeneric::isOrderedBefore): Revise ordering rules so that we put
2924            newer cues earlier in the layout order so they are drawn towards the bottom
2925            of the screen. Only do this for Generic captions.
2926            * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
2927            (WebCore::InbandTextTrackPrivateAVF::processAttributedStrings): Adjust logging
2928            messages.
2929            (WebCore::InbandTextTrackPrivateAVF::removeCompletedCues): Add logging.
2930
29312014-07-29  Lucas Forschler  <lforschler@apple.com>
2932
2933        Merge r171675
2934
2935    2014-07-28  Yusuke Suzuki  <utatane.tea@gmail.com>
2936
2937            CSS: Fix :visited behavior for SubSelectors
2938            https://bugs.webkit.org/show_bug.cgi?id=135324
2939
2940            Reviewed by Benjamin Poulain.
2941
2942            Disable :visited match for the selectors that has SubSelectors.
2943
2944            Tests: fast/history/nested-visited-test-complex.html
2945                   fast/history/sibling-visited-test-complex.html
2946
2947            * css/SelectorChecker.cpp:
2948            (WebCore::SelectorChecker::matchRecursively):
2949
29502014-07-27  Matthew Hanson  <matthew_hanson@apple.com>
2951
2952        Merge r171661. <rdar://problem/17315237>
2953
2954    2014-07-27  Daniel Bates  <dabates@apple.com>
2955    
2956            [WK2] Crash when accessing window.localStorage after calling window.close()
2957            https://bugs.webkit.org/show_bug.cgi?id=135328
2958            <rdar://problem/17315237>
2959    
2960            Reviewed by Sam Weinig.
2961    
2962            Fixes an issue where accessing local storage for the first time after calling window.close()
2963            causes a crash.
2964    
2965            For now, we should disallow accessing local storage after calling window.close() regardless of
2966            whether it's the first access to local storage as this seems like a bad idiom to support. Note,
2967            this represents a change in behavior from WebKit1. If such usage of window.localStorage turns
2968            out to be reasonable then we can visit this decision again in <https://bugs.webkit.org/show_bug.cgi?id=135330>.
2969    
2970            Tests: storage/domstorage/localstorage/access-storage-after-window-close.html
2971                   storage/domstorage/localstorage/access-storage-then-set-value-in-storage-after-window-close.html
2972                   storage/domstorage/localstorage/set-value-in-storage-after-window-close.html
2973    
2974            * page/DOMWindow.cpp:
2975            (WebCore::DOMWindow::localStorage): Modified to only return the cached local storage or
2976            create a new local storage so long as the page isn't being closed. Also, substitute nullptr
2977            for 0.
2978            (WebCore::DOMWindow::close): Call Page::setIsClosing() to mark that the page is closing.
2979            * page/Page.cpp:
2980            (WebCore::Page::Page): Initialize m_isClosing to false.
2981            * page/Page.h:
2982            (WebCore::Page::setIsClosing): Added.
2983            (WebCore::Page::isClosing): Added.
2984    
29852014-07-27  Matthew Hanson  <matthew_hanson@apple.com>
2986
2987        Merge r171647. <rdar://problem/17315168>
2988
2989    2014-07-26  Timothy Horton  <timothy_horton@apple.com>
2990    
2991            Crash in Web Content Process under ~PDFDocument under clearTouchEventListeners at topDocument()
2992            https://bugs.webkit.org/show_bug.cgi?id=135319
2993            <rdar://problem/17315168>
2994    
2995            Reviewed by Darin Adler and Antti Koivisto.
2996    
2997            * dom/Document.h:
2998            * dom/Document.cpp:
2999            (WebCore::Document::Document):
3000            (WebCore::Document::prepareForDestruction):
3001            Add a flag on Document, m_hasPreparedForDestruction, which ensures
3002            that each Document only goes through prepareForDestruction() once.
3003            prepareForDestruction() can be called a number of times during teardown,
3004            but it's only necessary to actually execute it once.
3005            
3006            This was previously achieved by virtue of all callers of prepareForDestruction()
3007            first checking hasLivingRenderTree, and prepareForDestruction() tearing down
3008            the render tree, but that meant that prepareForDestruction() was not called
3009            for Documents who never had a render tree in the first place.
3010    
3011            The only part of prepareForDestruction() that is now predicated on hasLivingRenderTree()
3012            is the call to destroyRenderTree(); the rest of the function has the potential to be relevant
3013            for non-rendered placeholder documents and can safely deal with them in other ways.
3014    
3015            It is important to call prepareForDestruction() on non-rendered placeholder documents
3016            because some of the cleanup (like disconnectFromFrame()) is critical to safe destruction.
3017    
3018            * loader/FrameLoader.cpp:
3019            (WebCore::FrameLoader::clear):
3020            Call prepareForDestruction() even if we don't have a living render tree.
3021            For the sake of minimizing change, removeFocusedNodeOfSubtree still
3022            depends on having a living render tree before calling prepareForDestruction().
3023    
3024            * page/Frame.cpp:
3025            (WebCore::Frame::setView):
3026            (WebCore::Frame::setDocument):
3027            Call prepareForDestruction() even if we don't have a living render tree.
3028    
30292014-07-27  Matthew Hanson  <matthew_hanson@apple.com>
3030
3031        Merge r171640. <rdar://problem/17812921>
3032
3033    2014-07-25  Zalan Bujtas  <zalan@apple.com>
3034    
3035            Subpixel rendering: Rounded rect gets non-renderable at certain subpixel size.
3036            https://bugs.webkit.org/show_bug.cgi?id=135314
3037            <rdar://problem/17812921>
3038    
3039            Reviewed by Tim Horton.
3040    
3041            While calculating the rounded rect for painting, the radius is adjusted to compensate
3042            for the pixel snapped size. However while scaling the radius, certain values overflow
3043            (float) mantissa and it produces a non-renderable rounded rect where the radius becomes bigger
3044            than the rectangle dimensions. In such cases, we need to shrink the radius to make it
3045            renderable again.
3046    
3047            Test: transitions/rounded-rect-becomes-non-renderable-while-transitioning.html
3048    
3049            * platform/graphics/RoundedRect.cpp:
3050            (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting): shrink the radius by
3051            one device pixel. It is as good as any other small value.
3052    
30532014-07-27  Matthew Hanson  <matthew_hanson@apple.com>
3054
3055        Merge r171624. <rdar://problem/17715503>
3056
3057    2014-07-25  Jer Noble  <jer.noble@apple.com>
3058    
3059            [MSE] Playback stalls & readyState drops to HAVE_CURRENT_DATA at end of stream with unbalanced buffered SourceBuffers
3060            https://bugs.webkit.org/show_bug.cgi?id=135291
3061            <rdar://problem/17715503>
3062    
3063            Reviewed by Sam Weinig.
3064    
3065            Test: media/media-source/media-source-end-of-stream-buffered.html
3066    
3067            When determining the correct ReadyState for the MediaSource in monitorSourceBuffers(), use the same
3068            definition of "buffered" as is used in the calculation of HTMLMediaElement.buffered and in the
3069            Stream Ended algorithm. Namely, when the stream has ended, treat each SourceBuffer as if its last
3070            buffered range extends to the duration of the stream. This allows playback to continue through to
3071            the duration without stalling due to monitorSourceBuffers().
3072    
3073            * Modules/mediasource/SourceBuffer.cpp:
3074            (WebCore::SourceBuffer::bufferedAccountingForEndOfStream): Added; extends the last range in buffered
3075                to MediaSource::duration() if the MediaSource is ended.
3076            (WebCore::SourceBuffer::hasCurrentTime): Uses bufferedAccountingForEndOfStream().
3077            (WebCore::SourceBuffer::hasFutureTime): Ditto.
3078            (WebCore::SourceBuffer::canPlayThrough): Ditto.
3079            * Modules/mediasource/SourceBuffer.h:
3080    
3081            Add a convenience method for determining whether the MediaSource has ended:
3082            * Modules/mediasource/MediaSource.cpp:
3083            (WebCore::MediaSource::isEnded):
3084            * Modules/mediasource/MediaSource.h:
3085    
3086            Add start() and end() methods that don't take a (usually ignored) isValid inout parameter. Add duration()
3087            and maximumBufferedTime() convenience methods:
3088            * platform/graphics/PlatformTimeRanges.cpp:
3089            (WebCore::PlatformTimeRanges::start):
3090            (WebCore::PlatformTimeRanges::end):
3091            (WebCore::PlatformTimeRanges::duration):
3092            (WebCore::PlatformTimeRanges::maximumBufferedTime):
3093            * platform/graphics/PlatformTimeRanges.h:
3094    
30952014-07-27  Matthew Hanson  <matthew_hanson@apple.com>
3096
3097        Merge r171616. <rdar://problem/17736875>
3098
3099    2014-07-25  Jer Noble  <jer.noble@apple.com>
3100    
3101            [MSE] High CPU usage in SampleMap::findSamplesWithinPresentationRange() with a large number of buffered samples.
3102            https://bugs.webkit.org/show_bug.cgi?id=135247
3103    
3104            Reviewed by Geoffrey Garen.
3105    
3106            Anchor our search for overlapping frames to the end of the search range when the overlap range is sufficiently
3107            close to the end of the search range. The common case for this search is when a sample is about to be appended
3108            to the end of the sample queue, so this should turn most searches into no-ops.
3109    
3110            * Modules/mediasource/SampleMap.cpp:
3111            (WebCore::PresentationOrderSampleMap::findSamplesWithinPresentationRangeFromEnd):
3112            * Modules/mediasource/SampleMap.h:
3113            * Modules/mediasource/SourceBuffer.cpp:
3114            (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
3115    
31162014-07-27  Matthew Hanson  <matthew_hanson@apple.com>
3117
3118        Merge r171609. <rdar://problem/17043792>
3119
3120    2014-07-25  David Hyatt  <hyatt@apple.com>
3121    
3122            [New Multicolumn] RenderViews paginated as RL or LR don't handle percentage widths correctly.
3123            REGRESSION: Images don’t scale to fit in page in vertical text books
3124    
3125            https://bugs.webkit.org/show_bug.cgi?id=135204
3126            <rdar://problem/17043792>
3127            
3128            Reviewed by Simon Fraser.
3129    
3130            Added fast/multicol/pagination/RightToLeft-max-width.html
3131    
3132            * rendering/RenderView.cpp:
3133            (WebCore::RenderView::availableLogicalHeight):
3134            Put back in the same code that used to exist for the old columns (but ported to the new
3135            columns).
3136    
31372014-07-25  Matthew Hanson  <matthew_hanson@apple.com>
3138
3139        Merge r171632. <rdar://problem/17817223>
3140
3141    2014-07-25  Jer Noble  <jer.noble@apple.com>
3142
3143            [EME][Mac] CDM error messages not piped through to MediaKeySession correctly; clients don't receive error events
3144            https://bugs.webkit.org/show_bug.cgi?id=135312
3145            <rdar://problem/17817223>
3146
3147            Reviewed by Brent Fulgham.
3148
3149            Set (and clear) the client interface so that errors can be piped from the CDMSession up to the MediaKeySession.
3150
3151            * Modules/encryptedmedia/MediaKeySession.cpp:
3152            (WebCore::MediaKeySession::MediaKeySession):
3153            (WebCore::MediaKeySession::close):
3154
31552014-07-25  Matthew Hanson  <matthew_hanson@apple.com>
3156
3157        Merge r171619. <rdar://problem/17811922>
3158
3159    2014-07-25  Pratik Solanki  <psolanki@apple.com>
3160
3161            [iOS] REGRESSION(r171526): Images fail to load sometimes
3162            https://bugs.webkit.org/show_bug.cgi?id=135304
3163            <rdar://problem/17811922>
3164
3165            Reviewed by Alexey Proskuryakov.
3166
3167            SharedBuffer::createCFData() calls data() as a way to coalesce the data array elements and
3168            segments into m_buffer. However, data() has an optimization where if we had a single element
3169            in the data array, it would just return that and not do coalescing. So when we passed
3170            m_buffer to WebCoreSharedData, we passed a buffer with no data in it.
3171
3172            Fix this by bringing the optimization to createCFData() and return the CFDataRef from the
3173            data array if we just have a single element.
3174
3175            No new tests. Should be covered by existing tests.
3176
3177            * platform/mac/SharedBufferMac.mm:
3178            (WebCore::SharedBuffer::createCFData):
3179
31802014-07-25  Lucas Forschler  <lforschler@apple.com>
3181
3182        Merge r171593
3183
3184    2014-07-25  Zalan Bujtas  <zalan@apple.com>
3185
3186            Subpixel rendering: iOS video playback controls look blurry.
3187            https://bugs.webkit.org/show_bug.cgi?id=135245
3188            <rdar://problem/16878037>
3189
3190            Reviewed by Simon Fraser.
3191
3192            This patch introduces a compositing parent of the overlay control panel so that
3193            the transformed overlay panel becomes sharp. This is a workaround for webkit.org/b/135246.
3194
3195            Can't find a way to test it yet.
3196
3197            * Modules/mediacontrols/mediaControlsApple.css:
3198            (video::-webkit-media-controls-panel-composited-parent):
3199            * Modules/mediacontrols/mediaControlsApple.js:
3200            (Controller.prototype.createControls):
3201            (Controller.prototype.addControls):
3202            * Modules/mediacontrols/mediaControlsiOS.css:
3203            (video::-webkit-media-controls-panel-composited-parent):
3204            * Modules/mediacontrols/mediaControlsiOS.js: This is a workaround for webkit.org/b/135248
3205            It pushes the overlay panel down to close the gap with the video element. Since the
3206            panel's size in css pixels is scale dependent, the gap needs to be scale dependent too.
3207            (ControllerIOS.prototype.set pageScaleFactor):
3208
32092014-07-24  Lucas Forschler  <lforschler@apple.com>
3210
3211        Merge r171203
3212
3213    2014-07-17  Enrica Casucci  <enrica@apple.com>
3214
3215            [REGRESSION WK2]The menu bar does not show up when tapping on the caret.
3216            https://bugs.webkit.org/show_bug.cgi?id=135023
3217            <rdar://problem/17617282>
3218
3219            Reviewed by Benjamin Poulain.
3220
3221            Adding some exports.
3222
3223            * WebCore.exp.in:
3224
32252014-07-24  Lucas Forschler  <lforschler@apple.com>
3226
3227        Merge r171580
3228
3229    2014-07-24  Ryosuke Niwa  <rniwa@webkit.org>
3230
3231            REGRESSION(r164401): Placing a caret doesn't bring up autocorrection panel
3232            https://bugs.webkit.org/show_bug.cgi?id=135278
3233
3234            Reviewed by Tim Horton.
3235
3236            The bug was caused by editorUIUpdateTimerFired calling respondToChangedSelection only if the selection was
3237            triggered by dictation instead of only if it was NOT triggered by dictation.
3238
3239            Prior to r164401, AlternativeTextController::respondToMarkerAtEndOfWord exited early when SetSelectionOptions
3240            had DictationTriggered set. r164401 intended to move this check to editorUIUpdateTimerFired to avoid passing
3241            options around but the boolean condition was erroneously flipped.
3242
3243            Fixed the bug by negating the condition in editorUIUpdateTimerFired.
3244
3245            No new tests for now since autocorrection panel cannot be tested automatically. (We should really automate this!)
3246
3247            * editing/Editor.cpp:
3248            (WebCore::Editor::editorUIUpdateTimerFired):
3249
32502014-07-24  Lucas Forschler  <lforschler@apple.com>
3251
3252        Merge r171577
3253
3254    2014-07-24  Tim Horton  <timothy_horton@apple.com>
3255
3256            Crashes under scanSelectionForTelephoneNumbers in Range::text() on some sites
3257            https://bugs.webkit.org/show_bug.cgi?id=135281
3258            <rdar://problem/17803347>
3259
3260            Reviewed by Ryosuke Niwa.
3261
3262            * editing/Editor.cpp:
3263            (WebCore::Editor::scanSelectionForTelephoneNumbers):
3264            toNormalizedRange is not guaranteed to return a non-null range.
3265            If it returns null, pass the empty markedRanges down to the client as our new set.
3266
32672014-07-24  Lucas Forschler  <lforschler@apple.com>
3268
3269        Merge r171567
3270
3271    2014-07-24  Simon Fraser  <simon.fraser@apple.com>
3272
3273            [iOS WK1] CSS viewport units use the wrong viewport size in WebKit1
3274            https://bugs.webkit.org/show_bug.cgi?id=135254
3275            <rdar://problem/17781423>
3276
3277            Reviewed by Tim Horton.
3278
3279            Test: fast/css/viewport-units-dynamic.html
3280
3281            In WebKit1 on iOS, we want to resolve viewport units against the visible
3282            viewport, not the legacy WK1 notion of the "viewport" which is the entire document.
3283
3284            Fixes rendering of medium.com articles in WK1 views on iPad.
3285
3286            * page/FrameView.cpp:
3287            (WebCore::FrameView::viewportSizeForCSSViewportUnits):
3288
32892014-07-24  Lucas Forschler  <lforschler@apple.com>
3290
3291        Merge r171561
3292
3293    2014-07-24  Myles C. Maxfield  <mmaxfield@apple.com>
3294
3295            Crash when measuring a glyphs from a fallback SVG font
3296            https://bugs.webkit.org/show_bug.cgi?id=135264
3297
3298            Reviewed by Simon Fraser.
3299
3300            We can't realize font data for all fallback fonts ahead
3301            of time, but we don't have all the necessary context to
3302            realize SVG fallback data when it's needed. For now, we
3303            can just bail; however, a larger, more invasive fix is
3304            in order.
3305
3306            Test: svg/text/svg-fallback-font-crash.html
3307
3308            * platform/graphics/WidthIterator.cpp:
3309            (WebCore::applyFontTransforms):
3310
33112014-07-24  Lucas Forschler  <lforschler@apple.com>
3312
3313        Merge r171559
3314
3315    2014-07-24  Daniel Bates  <dabates@apple.com>
3316                And Alexey Proskuryakov  <ap@apple.com>
3317
3318            [iOS] REGRESSION (WebKit2): Can't login to Wordpress.com, facebook.com when always allowing cookies
3319            https://bugs.webkit.org/show_bug.cgi?id=135273
3320            <rdar://problem/17598815>
3321
3322            Reviewed by Alexey Proskuryakov.
3323
3324            Fixes an issue where cookies may be created in the wrong cookie store.
3325
3326            Currently, when we update the CFURLRequest object associated with a ResourceRequest object
3327            we explicitly set a cookie storage, cookie accept policy, and SSL properties based on the
3328            corresponding values in the old CFURLRequest object (if we have one). This ultimately leads
3329            to CFNetwork associating the cookies for the request with a different cookie store when we
3330            handle the request in the NetworkProcess. Instead, we shouldn't set these properties
3331            explicitly as we already copy them implicitly earlier (via CFURLRequestCreateMutableCopy()).
3332
3333            * platform/network/cf/ResourceRequestCFNet.cpp:
3334            (WebCore::ResourceRequest::doUpdatePlatformRequest):
3335
33362014-07-24  Lucas Forschler  <lforschler@apple.com>
3337
3338        Merge r171505
3339
3340    2014-07-23  Joseph Pecoraro  <pecoraro@apple.com>
3341
3342            ScriptController::updateDocument ASSERT mutating map while iterating map
3343            https://bugs.webkit.org/show_bug.cgi?id=135211
3344
3345            Reviewed by Oliver Hunt.
3346
3347            Avoid iterating over m_windowShells in more places. This prevents
3348            the possibility of a collection during JSC allocation which might
3349            cause a mutation to m_windowShells (HTMLMediaElement destruction).
3350
3351            Have ScriptController defriend ScriptCachedFrameData by providing
3352            a getter for the list of window shells.
3353
3354            * bindings/js/ScriptCachedFrameData.cpp:
3355            (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
3356            (WebCore::ScriptCachedFrameData::restore):
3357            * bindings/js/ScriptController.cpp:
3358            (WebCore::ScriptController::windowShells):
3359            (WebCore::ScriptController::clearWindowShell):
3360            (WebCore::ScriptController::attachDebugger):
3361            (WebCore::ScriptController::updateDocument):
3362            * bindings/js/ScriptController.h:
3363
33642014-07-24  Lucas Forschler  <lforschler@apple.com>
3365
3366        Merge r171554
3367
3368    2014-07-24  Dan Bernstein  <mitz@apple.com>
3369
3370            Fixed Windows build fix.
3371
3372            * platform/network/cf/AuthenticationCF.cpp:
3373
33742014-07-24  Lucas Forschler  <lforschler@apple.com>
3375
3376        Merge r171545
3377
3378    2014-07-24  Dan Bernstein  <mitz@apple.com>
3379
3380            Attempted Windows build fix.
3381
3382            * platform/network/cf/AuthenticationCF.cpp:
3383            (WebCore::AuthenticationChallenge::AuthenticationChallenge):
3384            * platform/network/cf/CredentialStorageCFNet.cpp:
3385            (WebCore::CredentialStorage::getFromPersistentStorage):
3386            * platform/network/cf/ProtectionSpaceCFNet.cpp:
3387            (WebCore::ProtectionSpace::receivesCredentialSecurely):
3388            (WebCore::ProtectionSpaceBase::receivesCredentialSecurely): Deleted.
3389
33902014-07-24  Lucas Forschler  <lforschler@apple.com>
3391
3392        Merge r171540
3393
3394    2014-07-24  Dan Bernstein  <mitz@apple.com>
3395
3396            <rdar://problem/17766348> [Cocoa] WebCore::ProtectionSpace doesn’t preserve all NSURLProtectionSpace properties, such as the distinguishedNames array
3397            https://bugs.webkit.org/show_bug.cgi?id=135229
3398
3399            Reviewed by Alexey Proskuryakov.
3400
3401            * CMakeLists.txt: Updated for rename of a source file.
3402
3403            * WebCore.exp.in: Updated.
3404
3405            * WebCore.vcxproj/WebCore.vcxproj: Updated for rename of source files, added
3406            ProtectionSpaceCFNet.{cpp,h}.
3407            * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
3408
3409            * WebCore.xcodeproj/project.pbxproj: Updated for rename of source files, added
3410            ProtectionSpaceCococa.{h.mm}.
3411
3412            * platform/network/ProtectionSpace.cpp: Renamed to ProtectionSpaceBase.cpp.
3413            * platform/network/ProtectionSpace.h: This file was renamed to ProtectionSpaceBase.h, and
3414            in its place added a generic ProtectionSpace class that just derives from
3415            ProtectionSpaceBase. For Cocoa and CFNetwork, ProtectionSpace{Cocoa,CFNet}.h is included
3416            instead of the generic class.
3417
3418            * platform/network/ProtectionSpaceBase.cpp: Renamed ProtectionSpace.cpp to this.
3419            (WebCore::ProtectionSpaceBase::ProtectionSpaceBase): Updated for rename.
3420            (WebCore::ProtectionSpaceBase::host): Ditto.
3421            (WebCore::ProtectionSpaceBase::port): Ditto.
3422            (WebCore::ProtectionSpaceBase::serverType): Ditto.
3423            (WebCore::ProtectionSpaceBase::isProxy): Ditto.
3424            (WebCore::ProtectionSpaceBase::realm): Ditto.
3425            (WebCore::ProtectionSpaceBase::authenticationScheme): Ditto.
3426            (WebCore::ProtectionSpaceBase::receivesCredentialSecurely): Removed CFNetwork-specific part,
3427            which is now implemented in ProtectionSpaceCFNet.cpp.
3428            (WebCore::ProtectionSpaceBase::compare): Replaced operator== with this, and made it call
3429            ProtectionSpace::platformCompare at the end if needed.
3430
3431            * platform/network/ProtectionSpaceBase.h: Renamed ProtectionSpace.h to this.
3432            (WebCore::ProtectionSpaceBase::encodingRequiresPlatformData): Added with a default
3433            implementation that returns false, for ProtectionSpace implementations to override.
3434            (WebCore::ProtectionSpaceBase::platformCompare): Added with a default implementation that
3435            returns true, for ProtectionSpace implementations to override.
3436            (WebCore::operator==): Changed to call compare.
3437
3438            * platform/network/cf/AuthenticationCF.cpp:
3439            (WebCore::AuthenticationChallenge::AuthenticationChallenge): Changed to use the
3440            ProtectionSpace constructor that takes a CFURLProtectionSpaceRef.
3441            (WebCore::createCF): Changed to use ProtectionSpace::cfSpace.
3442
3443            * platform/network/cf/AuthenticationCF.h: Guarded a couple of functiosn that aren’t used in
3444            Cocoa with #if PLATFORM(WIN).
3445
3446            * platform/network/cf/CredentialStorageCFNet.cpp:
3447            (WebCore::CredentialStorage::getFromPersistentStorage): Changed to use
3448            ProtectionSpace::cfSpace.
3449            (WebCore::CredentialStorage::saveToPersistentStorage): Ditto.
3450
3451            * platform/network/cf/ProtectionSpaceCFNet.cpp: Added.
3452            (WebCore::ProtectionSpaceBase::receivesCredentialSecurely): Override with the
3453            CFNetwork-specific test that was previously in ProtectionSpace.cpp.
3454
3455            * platform/network/cf/ProtectionSpaceCFNet.h: Copied from Source/WebCore/platform/network/ProtectionSpace.h.
3456            Declare ProtectionSpace and override receivesCredentialSecurely.
3457
3458            * platform/network/mac/AuthenticationMac.h: Deleted the ProtectionSpace core() and mac().
3459            * platform/network/mac/AuthenticationMac.mm:
3460            (WebCore::AuthenticationChallenge::AuthenticationChallenge): Changed to use the
3461            ProtectionSpace constructor that takes an NSURLProtectionSpace.
3462            (WebCore::mac): Changed to use ProtectionSpace::nsSpace.
3463
3464            * platform/network/mac/CredentialStorageMac.mm:
3465            (WebCore::CredentialStorage::getFromPersistentStorage): Ditto.
3466
3467            * platform/network/mac/ResourceHandleMac.mm:
3468            (WebCore::ResourceHandle::receivedCredential): Changed to use the ProtectionSpace
3469            constructor that takes an NSURLProtectionSpace.
3470
3471            * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
3472            (-[WebCoreResourceHandleAsDelegate connection:canAuthenticateAgainstProtectionSpace:]):
3473            Ditto.
3474
3475            * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
3476            (-[WebCoreResourceHandleAsOperationQueueDelegate connection:canAuthenticateAgainstProtectionSpace:]):
3477            Ditto.
3478
34792014-07-24  Lucas Forschler  <lforschler@apple.com>
3480
3481        Merge r171532
3482
3483    2014-07-24  Benjamin Poulain  <benjamin@webkit.org>
3484
3485            [WK2] Fixed/Sticky layers can get mispositioned when the layer tree commit change their position or size
3486            https://bugs.webkit.org/show_bug.cgi?id=135227
3487            <rdar://problem/17279500>
3488
3489            Reviewed by Simon Fraser.
3490
3491            Keep track of the creation/destruction of Fixed and Sticky nodes in the ScrollingTree.
3492
3493            * page/scrolling/ScrollingTree.cpp:
3494            (WebCore::ScrollingTree::ScrollingTree):
3495            * page/scrolling/ScrollingTree.h:
3496            (WebCore::ScrollingTree::hasFixedOrSticky):
3497            (WebCore::ScrollingTree::fixedOrStickyNodeAdded):
3498            (WebCore::ScrollingTree::fixedOrStickyNodeRemoved):
3499            * page/scrolling/mac/ScrollingTreeFixedNode.mm:
3500            (WebCore::ScrollingTreeFixedNode::ScrollingTreeFixedNode):
3501            (WebCore::ScrollingTreeFixedNode::~ScrollingTreeFixedNode):
3502            * page/scrolling/mac/ScrollingTreeStickyNode.mm:
3503            (WebCore::ScrollingTreeStickyNode::ScrollingTreeStickyNode):
3504            (WebCore::ScrollingTreeStickyNode::~ScrollingTreeStickyNode):
3505
35062014-07-24  Lucas Forschler  <lforschler@apple.com>
3507
3508        Merge r171526
3509
3510    2014-07-24  Pratik Solanki  <psolanki@apple.com>
3511
3512            Sharing SharedBuffer between WebCore and ImageIO is racy and crash prone
3513            https://bugs.webkit.org/show_bug.cgi?id=135069
3514            <rdar://problem/17470655>
3515
3516            Reviewed by Simon Fraser.
3517
3518            When passing image data to ImageIO for decoding, we pass an NSData subclass that is a wraper
3519            around SharedBuffer. This can be a problem when ImageIO tries to access the data on the CA
3520            thread. End result is data corruption on large image loads and potential crashes. The fix is
3521            to have SharedBuffer create a copy of its data if the data has been passed to ImageIO and
3522            might be accessed concurrently.
3523
3524            Since Vector is not refcounted, we do this by having a new refcounted object in SharedBuffer
3525            that contains the buffer and we pass that in our NSData subclass WebCoreSharedBufferData.
3526            Code that would result in the Vector memory moving e.g. append(), resize(), now checks to
3527            see if the buffer was shared and if so, will create a new copy of the vector. This ensures
3528            that the main thread does not end up invalidating the vector memory that we have passed it
3529            to ImageIO.
3530
3531            No new tests because no functional changes.
3532
3533            * loader/cache/CachedResource.cpp:
3534            (WebCore::CachedResource::makePurgeable):
3535                Remove early return - createPurgeableMemory() has the correct check now.
3536            * platform/SharedBuffer.cpp:
3537            (WebCore::SharedBuffer::SharedBuffer):
3538            (WebCore::SharedBuffer::adoptVector):
3539            (WebCore::SharedBuffer::createPurgeableBuffer):
3540                Don't create purgeable buffer if we are sharing the buffer.
3541            (WebCore::SharedBuffer::append):
3542            (WebCore::SharedBuffer::clear):
3543            (WebCore::SharedBuffer::copy):
3544            (WebCore::SharedBuffer::duplicateDataBufferIfNecessary): Added.
3545                Create a new copy of the data if we have shared the buffer and if appending to it would
3546                exceed the capacity of the vector resulting in memmove.
3547            (WebCore::SharedBuffer::appendToInternalBuffer): Added.
3548            (WebCore::SharedBuffer::clearInternalBuffer): Added.
3549            (WebCore::SharedBuffer::buffer):
3550                Create a new copy of the buffer if we have shared it.
3551            (WebCore::SharedBuffer::getSomeData):
3552            * platform/SharedBuffer.h:
3553            * platform/cf/SharedBufferCF.cpp:
3554            (WebCore::SharedBuffer::SharedBuffer):
3555            (WebCore::SharedBuffer::singleDataArrayBuffer):
3556            (WebCore::SharedBuffer::maybeAppendDataArray):
3557            * platform/mac/SharedBufferMac.mm:
3558                Pass the InternalBuffer object to WebCoreSharedBufferData
3559            (-[WebCoreSharedBufferData dealloc]):
3560            (-[WebCoreSharedBufferData initWithSharedBufferInternalBuffer:]):
3561            (-[WebCoreSharedBufferData length]):
3562            (-[WebCoreSharedBufferData bytes]):
3563            (WebCore::SharedBuffer::createNSData):
3564                Call createCFData() instead of duplicating code.
3565            (WebCore::SharedBuffer::createCFData):
3566                If the data is in purgeable memory, make a copy of it since m_buffer was cleared when
3567                creating the purgeable buffer.
3568            (-[WebCoreSharedBufferData initWithSharedBuffer:]): Deleted.
3569
35702014-07-24  Lucas Forschler  <lforschler@apple.com>
3571
3572        Merge r171497
3573
3574    2014-07-23  Pratik Solanki  <psolanki@apple.com>
3575
3576            Get rid of SharedBuffer::NSDataRetainPtrWithoutImplicitConversionOperator
3577            https://bugs.webkit.org/show_bug.cgi?id=135219
3578
3579            Reviewed by Anders Carlsson.
3580
3581            No new tests because no functional changes.
3582
3583            * loader/ResourceBuffer.h:
3584            * loader/mac/ResourceBuffer.mm:
3585            (WebCore::ResourceBuffer::createNSData):
3586            * platform/SharedBuffer.h:
3587            (WebCore::SharedBuffer::NSDataRetainPtrWithoutImplicitConversionOperator::NSDataRetainPtrWithoutImplicitConversionOperator): Deleted.
3588            * platform/mac/SharedBufferMac.mm:
3589            (WebCore::SharedBuffer::createNSData):
3590
35912014-07-24  Lucas Forschler  <lforschler@apple.com>
3592
3593        Merge r171506
3594
3595    2014-07-23  Jeremy Jones  <jeremyj@apple.com>
3596
3597            Transparent fullscreen background when video is not present.
3598            https://bugs.webkit.org/show_bug.cgi?id=135226
3599
3600            Reviewed by Simon Fraser.
3601
3602            Set background to black just before beginning the animation to fullscreen.
3603
3604            * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
3605            (WebVideoFullscreenInterfaceAVKit::enterFullscreen): set background color black.
3606
36072014-07-24  Lucas Forschler  <lforschler@apple.com>
3608
3609        Merge r171481
3610
3611    2014-07-23  Joseph Pecoraro  <pecoraro@apple.com>
3612
3613            JSDOMWindowShell leaks on pages with media elements
3614            https://bugs.webkit.org/show_bug.cgi?id=135178
3615
3616            Reviewed by Oliver Hunt.
3617
3618            The DOMWindowWorld for HTMLMediaElements with MEDIA_CONTROLS_SCRIPT
3619            was not getting cleared and removed.
3620
3621            * bindings/js/ScriptController.cpp:
3622            (WebCore::ScriptController::clearWindowShell):
3623            Iterate over a copy of the values. A sweep / garbage collection caused by
3624            any JSC allocation during iteration could trigger a mutation of the m_windowShells
3625            table that was being iterating. So instead iterate a list that won't mutate.
3626
3627            * html/HTMLMediaElement.cpp:
3628            (WebCore::HTMLMediaElement::~HTMLMediaElement):
3629            If we had an isolated world, release as much memory as possible.
3630
36312014-07-24  Lucas Forschler  <lforschler@apple.com>
3632
3633        Merge r171478
3634
3635    2014-07-23  Jer Noble  <jer.noble@apple.com>
3636
3637            [MSE][Mac] Support abort() in SourceBufferPrivateAVFObjC.
3638            https://bugs.webkit.org/show_bug.cgi?id=135163
3639
3640            Reviewed by Brent Fulgham.
3641
3642            Recreate the parser when asked to abort().
3643
3644            * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
3645            (WebCore::SourceBufferPrivateAVFObjC::abort):
3646
36472014-07-23  Matthew Hanson  <matthew_hanson@apple.com>
3648
3649        Merge r171499. <rdar://problem/17783423>
3650
3651    2014-07-23  Tim Horton  <timothy_horton@apple.com>
3652
3653            REGRESSION (r171376): Sometimes we detect less than the whole phone number
3654            https://bugs.webkit.org/show_bug.cgi?id=135220
3655            <rdar://problem/17783423>
3656
3657            Reviewed by Brady Eidson.
3658
3659            * editing/Editor.cpp:
3660            (WebCore::Editor::scanSelectionForTelephoneNumbers):
3661            Use the visible selection's start and end instead of base and extent, because they'll
3662            always be in the right order in the case of a directional selection (base can be *after* extent
3663            if you select from right to left). This fixes the code that expands the selection.
3664
3665            Pass the *entire* expanded selection to DataDetectors, instead of using TextIterator.
3666            This way, we will find each number only once, and will never get part of a phone number once
3667            and then the whole phone number later.
3668
36692014-07-23  Lucas Forschler  <lforschler@apple.com>
3670
3671        Merge r171370
3672
3673    2014-07-22  Enrica Casucci  <enrica@apple.com>
3674
3675            REGRESSION (WebKit2): Selection inside accelerated overflow:scroll doesn't track scrolling.
3676            https://bugs.webkit.org/show_bug.cgi?id=135180
3677            <rdar://problem/16721055>
3678
3679            Reviewed by Simon Fraser.
3680
3681            AsyncScrollingCoordinator will force a selection update on iOS
3682            when scrolling terminates in an overflow scroll.
3683
3684            * loader/EmptyClients.h:
3685            * page/EditorClient.h:
3686            * page/scrolling/AsyncScrollingCoordinator.cpp:
3687            (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
3688            * page/scrolling/ScrollingTree.h:
3689            (WebCore::ScrollingTree::scrollingTreeNodeWillStartScroll):
3690            (WebCore::ScrollingTree::scrollingTreeNodeDidEndScroll):
3691
36922014-07-23  Lucas Forschler  <lforschler@apple.com>
3693
3694        Merge r171355
3695
3696    2014-07-21  Sam Weinig  <sam@webkit.org>
3697
3698            [Cocoa] WKScriptMessageHandlers don't seem to function properly after navigating
3699            https://bugs.webkit.org/show_bug.cgi?id=135148
3700
3701            Reviewed by Geoffrey Garen.
3702
3703            The "webkit" property on the window was not getting installed for subsequent
3704            loads due to intricate dance playing setting the JSDOMWindow where the DOMWindow
3705            object is not yet in a Frame when the JSDOMWindow is created. Since we were
3706            adding the "webkit" property on construction, the property was returning null
3707            thinking it had no Frame and was in a bad state. We can fix this by making the
3708            "webkit" property behave like all the other window properties moving its getting
3709            to JSDOMWindow::getOwnPropertySlot.
3710
3711            Added API test (WebKit2Cocoa/UserContentController).
3712
3713            * bindings/js/JSDOMWindowBase.cpp:
3714            (WebCore::JSDOMWindowBase::finishCreation):
3715            * bindings/js/JSDOMWindowCustom.cpp:
3716            (WebCore::jsDOMWindowWebKit):
3717            (WebCore::JSDOMWindow::getOwnPropertySlot):
3718
37192014-07-23  Lucas Forschler  <lforschler@apple.com>
3720
3721        Merge r171353
3722
3723    2014-07-22  Brent Fulgham  <bfulgham@apple.com>
3724
3725            [Win] Fix Leak in WebCore::createGlobalImageFileDescriptor 
3726            https://bugs.webkit.org/show_bug.cgi?id=134423
3727            <rdar://problem/17492758>
3728
3729            Reviewed by Geoffrey Garen.
3730
3731            * platform/win/PasteboardWin.cpp:
3732            (WebCore::createGlobalImageFileDescriptor): Unlock and release the
3733            HGLOBAL when exiting early.
3734
37352014-07-23  Lucas Forschler  <lforschler@apple.com>
3736
3737        Merge r171347
3738
3739    2014-07-21  Myles C. Maxfield  <mmaxfield@apple.com>
3740
3741            Clicking on links while accessibility is enabled sometimes crashes
3742            https://bugs.webkit.org/show_bug.cgi?id=135074
3743
3744            Reviewed by Chris Fleizach.
3745
3746            When an accessibility request comes in from the system, we call updateBackingStore() on the
3747            relevant AccessibilityObject, which triggers a relayout of the entire document. This relayout
3748            might delete that accessibility node and its parent, which would cause the node to be deleted.
3749            After the stack unwinds, we then call a member function on the node without checking for this
3750            condition.
3751
3752            Test: accessibility/parent-delete.html
3753
3754            * accessibility/AccessibilityObject.cpp:
3755            (WebCore::AccessibilityObject::updateBackingStore): Retain the node for the duration of the
3756            function.
3757
37582014-07-23  Lucas Forschler  <lforschler@apple.com>
3759
3760        Merge r171345
3761
3762    2014-07-22  Jeremy Jones  <jeremyj@apple.com>
3763
3764            Don't create new UIWindow for video fullscreen.
3765            https://bugs.webkit.org/show_bug.cgi?id=135038
3766
3767            Reviewed by Darin Adler.
3768
3769            * WebCore.exp.in:
3770            * platform/ios/WebVideoFullscreenControllerAVKit.h: use UIView instead of UIScreen.
3771            * platform/ios/WebVideoFullscreenControllerAVKit.mm:
3772            (-[WebVideoFullscreenController enterFullscreen:]): provide parent UIView.
3773            * platform/ios/WebVideoFullscreenInterfaceAVKit.h: remove UIWindow.
3774            * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: 
3775            (WebVideoFullscreenInterfaceAVKit::setupFullscreen): ditto 
3776            (WebVideoFullscreenInterfaceAVKit::cleanupFullscreen): ditto
3777            (WebVideoFullscreenInterfaceAVKit::invalidate): ditto
3778            (WebVideoFullscreenInterfaceAVKit::requestHideAndExitFullscreen): ditto
3779
37802014-07-22 Dana Burkart <dburkart@apple.com>
3781    
3782        Merge r171336.
3783
3784    2014-07-21  Benjamin Poulain  <bpoulain@apple.com>
3785
3786            [iOS][WK2] Improve event throttling for Scroll Events
3787            https://bugs.webkit.org/show_bug.cgi?id=135082
3788            <rdar://problem/17445266>
3789
3790            Reviewed by Simon Fraser.
3791
3792            This patch is composed of two parts. The first part in the WebKit layer
3793            track an approximate measurement of the main thread responsiveness.
3794            The second part in WebCore use that information to avoid sending events
3795            if a page is unresponsive.
3796
3797            In WebCore, this patch only consider scroll events so far. Hopefully the concept
3798            should be easy to generalize.
3799
3800            * loader/EmptyClients.h:
3801            * page/ChromeClient.h:
3802            Chrome client provides us with one information: how long an incoming event should be delayed.
3803            Every port is free to implement whatever logic is suitable for them.
3804
3805            * page/FrameView.cpp:
3806            (WebCore::FrameView::FrameView):
3807            (WebCore::FrameView::reset):
3808            (WebCore::FrameView::delayedScrollEventTimerFired):
3809            (WebCore::FrameView::scrollPositionChanged):
3810            (WebCore::FrameView::sendScrollEvent):
3811            * page/FrameView.h:
3812            Scroll events do not have any associated information so they can be coalesced by just skipping
3813            all input hapenning during the throttling delay.
3814
3815            The implementation is done by using a timer to delay the events.
3816
38172014-07-22 Dana Burkart <dburkart@apple.com>
3818    
3819        Merge r171332.
3820
3821    2014-07-21  Tim Horton  <timothy_horton@apple.com>
3822
3823            Avoid putting empty-sized surfaces into IOSurfacePool
3824            https://bugs.webkit.org/show_bug.cgi?id=135136
3825
3826            Reviewed by Simon Fraser.
3827
3828            * platform/graphics/cg/IOSurfacePool.cpp:
3829            (WebCore::IOSurfacePool::addSurface):
3830            Avoid adding 0x0 surfaces to the pool, because they will wreak havoc
3831            when their size is used as the key in the CachedSurfaceMap.
3832            Additionally, avoid any empty sizes, because they're just pointless.
3833
38342014-07-22 Dana Burkart <dburkart@apple.com>
3835    
3836        Merge r171321.
3837
3838    2014-07-21  Beth Dakin  <bdakin@apple.com>
3839
3840            WK1 should always setAcceleratedCompositingForFixedPositionEnabled(true) on 
3841            Yosemite
3842            https://bugs.webkit.org/show_bug.cgi?id=135135
3843
3844            Reviewed by Darin Adler.
3845
3846            This patch gets rid of the ChromeClient function that was introduced with 
3847            http://trac.webkit.org/changeset/171308 We’ll just enable the Setting instead.
3848            * css/StyleResolver.cpp:
3849            (WebCore::StyleResolver::adjustRenderStyle):
3850            (WebCore::fixedPositionCreatesStackingContext): Deleted.
3851            * page/ChromeClient.h:
3852            (WebCore::ChromeClient::requiresAcceleratedCompositingForViewportConstrainedPosition): Deleted.
3853            * rendering/RenderLayerCompositor.cpp:
3854            (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
3855
38562014-07-22 Dana Burkart <dburkart@apple.com>
3857    
3858        Merge r171320.
3859
3860    2014-07-21  Simon Fraser  <simon.fraser@apple.com>
3861
3862            [iOS WK2] Turn off position:fixed behavior when the keyboard is up
3863            https://bugs.webkit.org/show_bug.cgi?id=132537
3864
3865            Reviewed by Benjamin Poulain.
3866
3867            Export RenderObject::localToContainerPoint().
3868
3869            * WebCore.exp.in:
3870
38712014-07-22 Dana Burkart <dburkart@apple.com>
3872    
3873        Merge r171316.
3874
3875    2014-07-21  Jer Noble  <jer.noble@apple.com>
3876
3877            [MSE] YouTube video decode error when variant-switching
3878            https://bugs.webkit.org/show_bug.cgi?id=135128
3879
3880            Reviewed by Brent Fulgham.
3881
3882            Test: media/media-source/media-source-overlapping-decodetime.html
3883
3884            When variant-switching, the situation can arise where an existing sample with a presentation
3885            timestamp of N and a decode timestamp of M, and a new sample with a presentation timestamp > N
3886            and the same decode timestamp of M, will keep the new sample from being added to the SampleMap.
3887            This can result in a decode error when samples depending on that new, missing sample are enqueued.
3888
3889            The MSE spec is silent on the issue of overlapping decode timestamps. However, it guarantees that
3890            presentation timestamps are non-overlapping. So instead of using just the decode timestamp as a key
3891            for storing the samples in decode order, use both the decode timestamp and the presentation timestamp.
3892            That ensures that samples with different presentation times but equal decode times are both inserted
3893            into the decode queue, and in the correct order.
3894
3895            * Modules/mediasource/SampleMap.cpp:
3896            (WebCore::SampleIsRandomAccess::operator()): Update the parameter type to match the new KeyType.
3897            (WebCore::SampleMap::addSample): Pass both decodeTime and presentationTime as the key to decodeOrder.
3898            (WebCore::SampleMap::removeSample): Ditto.
3899            (WebCore::DecodeOrderSampleMap::findSampleWithDecodeKey): Renamed from findSampleWithDecodeTime.
3900            (WebCore::DecodeOrderSampleMap::reverseFindSampleWithDecodeKey): renamed from reverseFindSampleWithDecodeTime.
3901            (WebCore::DecodeOrderSampleMap::findSyncSamplePriorToPresentationTime): Use renamed version of above.
3902            (WebCore::DecodeOrderSampleMap::findSyncSampleAfterPresentationTime): Ditto.
3903            (WebCore::DecodeOrderSampleMap::findDependentSamples): Ditto.
3904            (WebCore::DecodeOrderSampleMap::findSampleWithDecodeTime): Deleted.
3905            (WebCore::DecodeOrderSampleMap::reverseFindSampleWithDecodeTime): Deleted.
3906            * Modules/mediasource/SampleMap.h:
3907            * Modules/mediasource/SourceBuffer.cpp:
3908            (WebCore::SourceBuffer::removeCodedFrames): Ditto.
3909            (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto.
3910            (WebCore::SourceBuffer::reenqueueMediaForTime): Ditto.
3911
39122014-07-22 Dana Burkart <dburkart@apple.com>
3913    
3914        Merge r171314.
3915
3916    2014-07-21  Andy Estes  <aestes@apple.com>
3917
3918            [iOS] Handle QuickLook ResourceLoaders in the web process
3919            https://bugs.webkit.org/show_bug.cgi?id=135113
3920
3921            Reviewed by David Kilzer.
3922
3923            No new tests. QuickLook is not testable from WebKit.
3924
3925            * WebCore.exp.in:
3926            * loader/ResourceLoadScheduler.cpp:
3927            (WebCore::ResourceLoadScheduler::maybeLoadQuickLookResource): Start loading the ResourceLoader if it is for a QuickLook resource.
3928            * loader/ResourceLoadScheduler.h:
3929
39302014-07-22 Dana Burkart <dburkart@apple.com>
3931    
3932        Merge r171308.
3933
3934    2014-07-21  Beth Dakin  <bdakin@apple.com>
3935
3936            Put position:fixed elements into layers when a WK1 view is layer-backed
3937            https://bugs.webkit.org/show_bug.cgi?id=135075
3938
3939            Reviewed by Darin Adler.
3940
3941            This patch adds a new ChromeClient function called 
3942            requiresAcceleratedCompositingForViewportConstrainedPosition(). Since a view can 
3943            go in and out of layer backing, we need a ChromeClient method that can be 
3944            dynamically re-evaluated rather than using the existing settings for enabling 
3945            accelerated fixed and fixed that creates a stacking context.
3946
3947            Ensure that fixed elements create a stacking context when 
3948            requiresAcceleratedCompositingForViewportConstrainedPosition is true.
3949            * css/StyleResolver.cpp:
3950            (WebCore::StyleResolver::adjustRenderStyle):
3951
3952            New ChromeClient function.
3953            * page/ChromeClient.h:
3954
39552014-07-22 Dana Burkart <dburkart@apple.com>
3956    
3957        Merge r171306.
3958
3959    2014-07-20  Simon Fraser  <simon.fraser@apple.com>
3960
3961            [iOS WK1] Single touch div scrolling doesn't work in framesets (breaks Word previews)
3962            https://bugs.webkit.org/show_bug.cgi?id=135103
3963            <rdar://problem/11830219>
3964
3965            Reviewed by Darin Adler.
3966
3967            After r166117 all layer flushing starts on the root frame; we no longer flush layers
3968            for each frame during painting. However, flushing GraphicsLayers can set some state
3969            on a subframe RenderLayerCompositor that is now never processed, which breaks scroll
3970            layer registration.
3971            
3972            Fix by doing a walk of the Frame tree, and calling didFlushLayers() on subframe RenderLayerCompositors
3973            before calling didFlushLayers() on self.
3974
3975            * rendering/RenderLayerCompositor.cpp:
3976            (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
3977            (WebCore::RenderLayerCompositor::didFlushLayers):
3978            (WebCore::RenderLayerCompositor::notifySubframesAfterLayerFlush):
3979            (WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers): Drive-by nullptr.
3980            * rendering/RenderLayerCompositor.h:
3981
39822014-07-22 Dana Burkart <dburkart@apple.com>
3983    
3984        Merge r171299.
3985
3986    2014-07-21  Eric Carlson  <eric.carlson@apple.com>
3987
3988            [iOS] a Paused media session is not active
3989            https://bugs.webkit.org/show_bug.cgi?id=135108
3990
3991            Reviewed by Darin Adler.
3992
3993            Activating the shared AudioSession will pause audio playing in another application,
3994            so only report a Playing media sessions as active.
3995
3996            * platform/audio/MediaSessionManager.cpp:
3997            * platform/audio/MediaSessionManager.h:
3998            (WebCore::MediaSessionManager::activeAudioSessionRequired): Renamed from hasActive to make
3999            clear what it does. Only return true for a session that is Playing.
4000
4001            * platform/audio/mac/MediaSessionManagerMac.cpp:
4002            (MediaSessionManager::updateSessionState): hasActive renamed to activeAudioSessionRequired.
4003
40042014-07-22 Dana Burkart <dburkart@apple.com>
4005    
4006        Merge r171289.
4007
4008    2014-07-20  Pratik Solanki  <psolanki@apple.com>
4009
4010            Reduce the chances of a race condition when sharing SharedBuffer
4011            https://bugs.webkit.org/show_bug.cgi?id=135060
4012            <rdar://problem/17729444>
4013
4014            Reviewed by Darin Adler.
4015
4016            We currently pass a SharedBuffer wrapped in WebCoreSharedBufferData to ImageIO for image
4017            decoding. This is not thread safe since ImageIO will access this buffer on a separate
4018            thread. We access SharedBuffer::buffer() on the other thread which resizes the Vector
4019            m_buffer if m_size is greater than the vector size. Since the code in SharedBuffer::append()
4020            sets m_size before appending the data to the buffer, m_size is out of sync with the m_buffer
4021            size for the entire duration of the Vector append which could be doing a lot of copying if
4022            the resource is large. While this change does not fix the race condition, we can at least
4023            reduce the chances of SharedBuffer::buffer() calling resize() by setting m_size after the
4024            cector has finished appending.
4025
4026            No new tests because no functional changes.
4027
4028            * platform/SharedBuffer.cpp:
4029            (WebCore::SharedBuffer::append):
4030
40312014-07-22 Dana Burkart <dburkart@apple.com>
4032    
4033        Merge r171288.
4034
4035    2014-07-20  Jeremy Jones  <jeremyj@apple.com>
4036
4037            Disable ff/rw based on canPlayFastForward and canPlayFastRewind.
4038            https://bugs.webkit.org/show_bug.cgi?id=134894
4039
4040            Reviewed by Darin Adler.
4041
4042            * WebCore.exp.in: add symbol for canPlayFastReverse
4043            * html/HTMLMediaElement.cpp: Add two new accessors
4044            (WebCore::HTMLMediaElement::nextScanRate): possibly limit scanRate
4045            (WebCore::HTMLMediaElement::canPlayFastForward): added
4046            (WebCore::HTMLMediaElement::canPlayFastReverse): added
4047            * html/HTMLMediaElement.h: declare two new methods
4048            * platform/graphics/MediaPlayer.cpp: Plumb through two new accessors
4049            (WebCore::MediaPlayer::maxFastForwardRate): added
4050            (WebCore::MediaPlayer::minFastReverseRate): added
4051            * platform/graphics/MediaPlayer.h: Declare new methods
4052            * platform/graphics/MediaPlayerPrivate.h: Added two new methods.
4053            (WebCore::MediaPlayerPrivateInterface::maxFastForwardRate): added
4054            (WebCore::MediaPlayerPrivateInterface::minFastReverseRate): added
4055            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h: member to cache ff/rw enabled state
4056            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
4057            (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): observe on item canPlayFastForward canPlayFastReverse
4058            (WebCore::MediaPlayerPrivateAVFoundationObjC::canPlayFastForwardDidChange): added
4059            (WebCore::MediaPlayerPrivateAVFoundationObjC::canPlayFastReverseDidChange): added
4060            (WebCore::itemKVOProperties): observe canPlayFastForward canPlayFastRewind
4061            (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]): ditto
4062            * platform/ios/WebVideoFullscreenInterface.h: add new method
4063            * platform/ios/WebVideoFullscreenInterfaceAVKit.h: ditto
4064            * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: ditto
4065            (WebVideoFullscreenInterfaceAVKit::setCanPlayFastReverse): Set value on WebAVPlayerController.
4066            (-[WebAVPlayerController canScanBackward]): Deleted.
4067            (+[WebAVPlayerController keyPathsForValuesAffectingCanScanBackward]): Deleted.
4068            * platform/ios/WebVideoFullscreenModelMediaElement.mm:
4069            (WebVideoFullscreenModelMediaElement::updateForEventName): update canPlayFastReverse.
4070
40712014-07-22 Dana Burkart <dburkart@apple.com>
4072    
4073        Merge r171287.
4074
4075    2014-07-18  Gavin Barraclough  <baraclough@apple.com>
4076
4077            HTMLMediaElement should registerWithDocument on iOS
4078            https://bugs.webkit.org/show_bug.cgi?id=135084
4079            <rdar://problem/17702531>
4080
4081            Reviewed by Andreas Kling.
4082
4083            Otherwise it won't know when the visibility changes!
4084
4085            * html/HTMLMediaElement.cpp:
4086            (WebCore::HTMLMediaElement::registerWithDocument):
4087            (WebCore::HTMLMediaElement::unregisterWithDocument):
4088
40892014-07-22 Dana Burkart <dburkart@apple.com>
4090    
4091        Merge r171286.
4092
4093    2014-07-20  Jeremy Jones  <jeremyj@apple.com>
4094
4095            Decrease flicker when enter and exit fullscreen.
4096            https://bugs.webkit.org/show_bug.cgi?id=134919
4097
4098            Reviewed by Simon Fraser.
4099
4100            Put AVPlayerLayer in a container layer so moving it between inline and fullscreen
4101            is as easy as adding and removing it from a containter layer; no need to do a layout.
4102
4103            Make sure fullscreen layers are transparent before moving moving the AVPlayerLayer
4104            between inline and fullscreen so you don't briefly see the empty fullscreen layers.
4105
4106            * html/HTMLMediaElement.cpp:
4107            (WebCore::HTMLMediaElement::platformLayer): remove fullscreen special case.
4108            (WebCore::HTMLMediaElement::setVideoFullscreenLayer): no need to recalc style
4109            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h: add inline container layer
4110            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: 
4111            add WebVideoContainerLayer to contain AVPlayerLayer and keep layout correct.
4112            (-[WebVideoContainerLayer setBounds:]): forward setbounds to set child frame.
4113            (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerLayer): create the video container layer
4114            (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoLayer): destroy the video container layer
4115            (WebCore::MediaPlayerPrivateAVFoundationObjC::platformLayer): use container layer instead of video layer
4116            (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenLayer): use transactions to prevent unwanted animation.
4117            (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenFrame): ditto
4118            * platform/graphics/ca/mac/PlatformCALayerMac.mm:
4119            (PlatformCALayerMac::layerTypeForPlatformLayer): WebVideoContainerLayer is a kind of AVPlayerLayer
4120            * platform/ios/WebVideoFullscreenControllerAVKit.mm:
4121            (-[WebVideoFullscreenController didCleanupFullscreen]): remove video fullscreen layer first
4122            * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
4123            (WebVideoFullscreenInterfaceAVKit::setupFullscreen): make background transparent during transition.
4124               dispatch_async to allow CATransaction to complete before calling didSetupFullscreen()
4125
41262014-07-22 Dana Burkart <dburkart@apple.com>
4127    
4128        Merge r171284.
4129
4130    2014-07-20  Dan Bernstein  <mitz@apple.com>
4131
4132            <rdar://problems/17742611> -[_WKActivatedElementInfo image] is often empty
4133            https://bugs.webkit.org/show_bug.cgi?id=135107
4134
4135            Reviewed by Sam Weinig.
4136
4137            Test: TestWebKitAPI/Tests/mac/RenderedImageFromDOMNode.mm
4138
4139            * page/FrameView.cpp:
4140            (WebCore::FrameView::paintContents): To work around http://webkit.org/b/135106, replace the
4141            paint root with its nearest ancestor that isn’t an inline with culled line boxes, if needed.
4142
41432014-07-22 Dana Burkart <dburkart@apple.com>
4144    
4145        Merge r171283.
4146
4147    2014-07-20  Darin Adler  <darin@apple.com>
4148
4149            Crashes seen in wheel event handling
4150            https://bugs.webkit.org/show_bug.cgi?id=135102
4151
4152            Reviewed by Beth Dakin.
4153
4154            Speculative fix based on guesses about what could be crashing.
4155            The crash seems to be calling ref on an event target, and my guess is that this
4156            has something to do with latching.
4157
4158            * page/EventHandler.cpp:
4159            (WebCore::EventHandler::platformPrepareForWheelEvents): Updated argument types.
4160            (WebCore::EventHandler::handleWheelEvent): Refactored a little and made some local
4161            variables use RefPtr instead of raw pointers. Also added some comments.
4162
4163            * page/EventHandler.h: Changed argument types to RefPtr.
4164
4165            * page/mac/EventHandlerMac.mm:
4166            (WebCore::EventHandler::platformPrepareForWheelEvents): Updated argument types.
4167            Also added a FIXME.
4168
41692014-07-22 Dana Burkart <dburkart@apple.com>
4170    
4171        Merge r171252.
4172
4173    2014-07-18  Andy Estes  <aestes@apple.com>
4174
4175            [iOS] Tapping "Allow Website" on a restricted page does not bring up the keypad
4176            https://bugs.webkit.org/show_bug.cgi?id=135072
4177            <rdar://problem/17528188>
4178
4179            Reviewed by David Kilzer.
4180
4181            No new tests. Content filtering is not testable from WebKit.
4182
4183            * WebCore.exp.in: Exported necessary ContentFilter symbols.
4184            * loader/DocumentLoader.cpp:
4185            (WebCore::DocumentLoader::finishedLoading): Called FrameLoaderClient::contentFilterDidBlockLoad().
4186            (WebCore::DocumentLoader::responseReceived): Created a new ContentFilter.
4187            (WebCore::DocumentLoader::dataReceived): Called FrameLoaderClient::contentFilterDidBlockLoad().
4188            (WebCore::DocumentLoader::setContentFilterForBlockedLoad): Deleted.
4189            (WebCore::DocumentLoader::handleContentFilterRequest): Deleted.
4190            * loader/DocumentLoader.h:
4191            * loader/FrameLoaderClient.h:
4192            (WebCore::FrameLoaderClient::contentFilterDidBlockLoad):
4193            * loader/PolicyChecker.cpp:
4194            (WebCore::PolicyChecker::checkNavigationPolicy): Removed the check for unblock navigations, as this is now
4195            handled at the WebKit layer.
4196            * platform/ContentFilter.h: ContentFilter no longer needs to be RefCounted, so made various changes in order to
4197            make it compatible with unique_ptr.
4198            * platform/ios/ContentFilterIOS.mm:
4199            (WebCore::scheme): Changed from a public member function to a static inline free function.
4200            (WebCore::ContentFilter::handleUnblockRequestAndDispatchIfSuccessful): Renamed from requestUnblockAndDispatchIfSuccessful.
4201            * platform/mac/ContentFilterMac.mm:
4202            (WebCore::ContentFilter::ContentFilter): Added a default constructor for use during message decoding.
4203            (WebCore::ContentFilter::addData): Removed calls to ref() and deref(). These were never actually needed since
4204            we were dispatching the block synchronously.
4205            (WebCore::ContentFilter::finishedAddingData): Ditto.
4206            (WebCore::ContentFilter::encode): Encoded m_platformContentFilter to the NSKeyedArchiver if it conforms to NSSecureCoding.
4207            (WebCore::ContentFilter::decode): Decoded m_platformContentFilter from the NSKeyedUnarchiver if it conforms to NSSecureCoding.
4208            (WebCore::ContentFilter::create): Deleted.
4209
42102014-07-22 Dana Burkart <dburkart@apple.com>
4211    
4212        Merge r171250.
4213
4214    2014-07-18  Simon Fraser  <simon.fraser@apple.com>
4215
4216            [iOS WK2] position:fixed in iframes with programmatic scroll could end up in the wrong place
4217            https://bugs.webkit.org/show_bug.cgi?id=135078
4218            <rdar://problem/17401823>
4219
4220            Reviewed by Tim Horton.
4221            
4222            When the UI-side scrolling tree receives a requested scroll position update, it scrolls
4223            the node (e.g. a frame) then traverses child nodes to update them, e.g. for fixed position.
4224            However, we would always use a viewport rect for the main document (from the scrolling tree),
4225            which is not appropriate for subframes. Subframes should just use their own visible
4226            rect to position fixed children.
4227
4228            Test: platform/mac-wk2/tiled-drawing/scrolling/frames/fixed-inside-frame.html
4229
4230            * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm:
4231            (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateChildNodesAfterScroll):
4232
42332014-07-22 Dana Burkart <dburkart@apple.com>
4234    
4235        Merge r171246.
4236
4237    2014-07-18  Beth Dakin  <bdakin@apple.com>
4238
4239            Fixed position elements are misplaced when a WK1 view has contentInsets set
4240            https://bugs.webkit.org/show_bug.cgi?id=135031
4241            -and corresponding-
4242            <rdar://problem/17682335>
4243
4244            Reviewed by Tim Horton.
4245
4246            [NSScrollView documentVisibleRect] includes content that is within the inset-area 
4247            of a view, but WebCore is interested in the content that is fully visible, so we 
4248            need to factor the inset sizes out of this rect.
4249
4250            Implement contract() to avoid the awkwardness of calling expand() with negative 
4251            values.
4252            * platform/graphics/IntSize.h:
4253            (WebCore::IntSize::contract):
4254
4255            Factor out insets
4256            * platform/mac/ScrollViewMac.mm:
4257            (WebCore::ScrollView::platformVisibleContentRect):
4258            (WebCore::ScrollView::platformVisibleContentSize):
4259
42602014-07-22 Dana Burkart <dburkart@apple.com>
4261    
4262        Merge r171239.
4263
4264    2014-07-18  Tim Horton  <timothy_horton@apple.com>
4265
4266            Take navigation snapshots whenever the current back-forward item is going to change
4267            https://bugs.webkit.org/show_bug.cgi?id=135058
4268            <rdar://problem/17464515>
4269
4270            Reviewed by Dan Bernstein.
4271
4272            * loader/HistoryController.cpp:
4273            (WebCore::HistoryController::updateForCommit):
4274            (WebCore::HistoryController::recursiveUpdateForCommit):
4275            (WebCore::HistoryController::recursiveUpdateForSameDocumentNavigation):
4276            (WebCore::HistoryController::createItem):
4277            Use setCurrentItem instead of duplicating the contents of it inside each of these functions.
4278
4279            (WebCore::HistoryController::setCurrentItem):
4280            (WebCore::HistoryController::replaceCurrentItem):
4281            When setting or replacing the current item, let the FrameLoaderClient know that we're going
4282            to change which history item is "current".
4283
4284            * loader/FrameLoaderClient.h:
4285            (WebCore::FrameLoaderClient::willChangeCurrentHistoryItem): Added.
4286
42872014-07-22 Dana Burkart <dburkart@apple.com>
4288    
4289        Merge r171215.
4290
4291    2014-07-17  Jer Noble  <jer.noble@apple.com>
4292
4293            [MSE] Re-enqueue after a removeCodedFrames() only if the removed frames overlap what may have possibly been enqueued but undisplayed.
4294            https://bugs.webkit.org/show_bug.cgi?id=135039
4295
4296            Reviewed by Eric Carlson.
4297
4298            When a client calls removeCodedFrames(), we must re-enqueue those ranges if the removed samples overlap with
4299            enqueued but possibly un-displayed samples. Otherwise, replacement samples may lead to decode errors as those
4300            new samples dependencies are not met. But if we re-enqueue too frequently, this may cause subtle but noticible
4301            display timing glitches, so only re-enqueue when removeCodedFrames have a possiblity of removing enqueued, but
4302            not yet displayed samples.
4303
4304            * Modules/mediasource/SourceBuffer.cpp:
4305            (WebCore::SourceBuffer::removeCodedFrames):
4306
43072014-07-22 Dana Burkart <dburkart@apple.com>
4308    
4309        Merge r171210.
4310
4311    2014-07-17  Zalan Bujtas  <zalan@apple.com>
4312
4313            Subpixel rendering: Embedded non-compositing rotate transform paints to wrong position.
4314            https://bugs.webkit.org/show_bug.cgi?id=135028
4315
4316            Reviewed by Simon Fraser.
4317
4318            CTM always translates to where the layer's renderer() is going to paint.
4319            It ensures that the pixel snapped renderer() always end up painting to (0, 0) which is
4320            required to be able to position properly on transformed context.
4321
4322            Test: fast/layers/hidpi-transform-on-child-content-is-mispositioned.html
4323
4324            * rendering/RenderLayer.cpp:
4325            (WebCore::RenderLayer::beginTransparencyLayers):
4326            (WebCore::RenderLayer::clipToRect):
4327            (WebCore::RenderLayer::paintLayerByApplyingTransform):
4328            (WebCore::RenderLayer::paintBackgroundForFragments):
4329            (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
4330            (WebCore::RenderLayer::paintOutlineForFragments):
4331            (WebCore::RenderLayer::paintMaskForFragments):
4332            (WebCore::RenderLayer::paintOverflowControlsForFragments):
4333            (WebCore::RenderLayer::calculateClipRects):
4334            * rendering/RenderLayer.h:
4335
43362014-07-22 Dana Burkart <dburkart@apple.com>
4337    
4338        Merge r171195.
4339
4340    2014-07-17  Timothy Hatcher  <timothy@apple.com>
4341
4342            Make console.profile record to the Timeline.
4343
4344            https://bugs.webkit.org/show_bug.cgi?id=134643
4345
4346            Reviewed by Joseph Pecoraro.
4347
4348            Passes existing profiler tests in fast/profiler.
4349
4350            * bindings/js/ScriptState.cpp:
4351            (WebCore::domWindowFromExecState):
4352            (WebCore::frameFromExecState):
4353            (WebCore::scriptExecutionContextFromExecState):
4354            (WebCore::mainWorldExecState):
4355            (WebCore::execStateFromNode):
4356            * bindings/js/ScriptState.h:
4357            * inspector/InspectorController.cpp:
4358            (WebCore::InspectorController::InspectorController):
4359            (WebCore::InspectorController::profilerEnabled):
4360            (WebCore::InspectorController::setProfilerEnabled):
4361            * inspector/InspectorController.h:
4362            * inspector/InspectorInstrumentation.cpp:
4363            (WebCore::InspectorInstrumentation::startProfilingImpl):
4364            (WebCore::InspectorInstrumentation::stopProfilingImpl):
4365            * inspector/InspectorTimelineAgent.cpp:
4366            (WebCore::InspectorTimelineAgent::didCreateFrontendAndBackend):
4367            (WebCore::InspectorTimelineAgent::willDestroyFrontendAndBackend):
4368            (WebCore::InspectorTimelineAgent::start):
4369            (WebCore::InspectorTimelineAgent::stop):
4370            (WebCore::startProfiling):
4371            (WebCore::stopProfiling):
4372            (WebCore::InspectorTimelineAgent::startFromConsole):
4373            (WebCore::InspectorTimelineAgent::stopFromConsole):
4374            (WebCore::InspectorTimelineAgent::didWriteHTML):
4375            (WebCore::InspectorTimelineAgent::breakpointActionProbe):
4376            (WebCore::toProtocol):
4377            (WebCore::InspectorTimelineAgent::addRecordToTimeline):
4378            (WebCore::InspectorTimelineAgent::didCompleteRecordEntry):
4379            (WebCore::InspectorTimelineAgent::didCompleteCurrentRecord):
4380            (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
4381            (WebCore::InspectorTimelineAgent::sendEvent):
4382            (WebCore::InspectorTimelineAgent::createRecordEntry):
4383            (WebCore::InspectorTimelineAgent::pushCurrentRecord):
4384            * inspector/InspectorTimelineAgent.h:
4385            (WebCore::InspectorTimelineAgent::TimelineRecordEntry::TimelineRecordEntry):
4386            (WebCore::InspectorTimelineAgent::pushCurrentRecord):
4387            * inspector/InstrumentingAgents.cpp:
4388            (WebCore::InstrumentingAgents::InstrumentingAgents):
4389            (WebCore::InstrumentingAgents::reset):
4390            * inspector/InstrumentingAgents.h:
4391            (WebCore::InstrumentingAgents::persistentInspectorTimelineAgent):
4392            (WebCore::InstrumentingAgents::setPersistentInspectorTimelineAgent):
4393            * inspector/TimelineRecordFactory.cpp:
4394            (WebCore::TimelineRecordFactory::createConsoleProfileData):
4395            * inspector/TimelineRecordFactory.h:
4396            * inspector/protocol/Timeline.json:
4397            * page/PageConsole.cpp:
4398            (WebCore::PageConsole::profileEnd):
4399
44002014-07-22 Dana Burkart <dburkart@apple.com>
4401    
4402        Merge r171188.
4403
4404    2014-07-16  Sam Weinig  <sam@webkit.org>
4405
4406            Don't send geolocation permission requests when the page is not visible
4407            <rdar://problem/17208715>
4408            https://bugs.webkit.org/show_bug.cgi?id=134989
4409
4410            Reviewed by Darin Adler.
4411
4412            Instead of eagerly requesting geolocation permission for pages that aren't visible,
4413            store a set of pending requests, and send them only once the page has become visible.
4414
4415            * Modules/geolocation/GeolocationController.cpp:
4416            (WebCore::GeolocationController::GeolocationController):
4417            (WebCore::GeolocationController::~GeolocationController):
4418            (WebCore::GeolocationController::requestPermission):
4419            (WebCore::GeolocationController::cancelPermissionRequest):
4420            (WebCore::GeolocationController::viewStateDidChange):
4421            (WebCore::provideGeolocationTo):
4422            * Modules/geolocation/GeolocationController.h:
4423            Store pending requests to be fired once the page is visible.
4424
4425            * WebCore.xcodeproj/project.pbxproj:
4426            Add ViewStateChangeObserver.h
4427
4428            * page/Page.cpp:
4429            (WebCore::Page::addViewStateChangeObserver):
4430            (WebCore::Page::removeViewStateChangeObserver):
4431            (WebCore::Page::setViewState):
4432            * page/Page.h:
4433            Add a set of registered view state observers, and notify them when the
4434            view state changes.
4435
4436            * page/ViewStateChangeObserver.h: Added.
4437            (WebCore::ViewStateChangeObserver::~ViewStateChangeObserver):
4438            Add an observer that can register with the page for view state changes.
4439
44402014-07-22 Dana Burkart <dburkart@apple.com>
4441    
4442        Merge r171184.
4443
4444    2014-07-17  Jer Noble  <jer.noble@apple.com>
4445
4446            Enable legacy fullscreen API in media controls
4447            https://bugs.webkit.org/show_bug.cgi?id=134985
4448
4449            Reviewed by Eric Carlson.
4450
4451            Allow clients who have not enabled HTML5 Fullscreen APIs to still use fullscreen mode
4452            with <video> elements by using the legacy, video-element-specific fullscreen APIs in
4453            the <video> media controls.
4454
4455            * Modules/mediacontrols/mediaControlsApple.js:
4456            (Controller):
4457            (Controller.prototype.handleReadyStateChange):
4458            (Controller.prototype.isFullScreen):
4459            (Controller.prototype.handlePlayButtonClicked):
4460            (Controller.prototype.updateFullscreenButton):
4461            (Controller.prototype.handleFullscreenButtonClicked):
4462
44632014-07-22 Dana Burkart <dburkart@apple.com>
4464    
4465        Merge r171376.
4466
4467    2014-07-22  Tim Horton  <timothy_horton@apple.com>
4468
4469            REGRESSION (r171016): Reproducible infinite spin selecting phone number
4470            https://bugs.webkit.org/show_bug.cgi?id=135183
4471            <rdar://problem/17727342>
4472
4473            Reviewed by Ryosuke Niwa.
4474
4475            * editing/Editor.cpp:
4476            (WebCore::Editor::scanRangeForTelephoneNumbers):
4477            Make use of TextIterator::subrange, which knows how to make a subrange from character positions,
4478            instead of assuming that our character positions translate directly to positions in the incoming range.
4479            Make use of DocumentMarkerController::addMarker, which takes a range and applies the marker to
4480            all text nodes inside the range as appropriate.
4481            Fix naming of the shadowed 'length' local.
4482            Fix a typo in the comment.
4483
44842014-07-17  Dean Jackson  <dino@apple.com>
4485
4486        <rdar://problem/17675068> Disable some features on this branch.
4487
4488        Reviewed originally by Simon Fraser.
4489
4490        Disable:
4491        - CSS_EXCLUSIONS
4492        - CSS_GRID_LAYOUT
4493        - INPUT_TYPE_COLOR
4494        - INPUT_TYPE_COLOR_POPUP
4495        - CANVAS_PATH
4496        - CSS_TRANSFORMS_ANIMATIONS_UNPREFIXED
4497        - INDIE_UI
4498        - SHARED_WORKERS
4499        - NAVIGATOR_HWCONCURRENCY
4500        - GAMEPAD
4501        - PICTURE_SIZES
4502        - CSS3_CONDITIONAL_RULES
4503        - WILL_REVEAL_EDGE_EVENTS
4504
4505        * Configurations/FeatureDefines.xcconfig:
4506
45072014-07-16  Zalan Bujtas  <zalan@apple.com>
4508
4509        Subpixel rendering: Adjust cliprect with devicePixelFractionFromRenderer() before painting.
4510        https://bugs.webkit.org/show_bug.cgi?id=134950
4511        <rdar://problem/17617994>
4512
4513        Reviewed by Simon Fraser.
4514
4515        The cliprect coming from the graphics layer needs to be adjusted with the subpixel gap
4516        from renderer. This is symmetric with the offsetting we do, when the dirty rect is sent off to the GraphicsLayer.
4517        It puts us back to the correct coordinating system for intersecting with renderers.
4518
4519        Test: compositing/hidpi-compositing-layer-with-tile-layers-on-subpixel-position.html
4520
4521        * rendering/RenderLayer.cpp:
4522        (WebCore::RenderLayer::beginTransparencyLayers):
4523        (WebCore::RenderLayer::clipToRect):
4524
45252014-07-16  Simon Fraser  <simon.fraser@apple.com>
4526
4527        Fix a typo noticed by Darin.
4528        
4529        * rendering/RenderBox.cpp:
4530        (WebCore::shouldApplyContainersClipAndOffset):
4531        (WebCore::RenderBox::computeRectForRepaint):
4532        (WebCore::shouldAppyContainersClipAndOffset): Deleted.
4533
45342014-07-16  Simon Fraser  <simon.fraser@apple.com>
4535
4536        Improve showTree() logging
4537        https://bugs.webkit.org/show_bug.cgi?id=134997
4538
4539        Reviewed by Tim Horton.
4540
4541        Have the debug showTree(), which dumps the Node/Element tree, show which nodes need
4542        style recalc, and print element renderers.
4543
4544        * dom/Node.cpp:
4545        (WebCore::Node::showNode):
4546
45472014-07-16  Simon Fraser  <simon.fraser@apple.com>
4548
4549        [iOS] Expose the points on WebEventRegion
4550        https://bugs.webkit.org/show_bug.cgi?id=134978
4551
4552        Reviewed by Tim Horton.
4553
4554        Expose WebEventRegion's points so that UIKit can get at them.
4555
4556        * page/ios/WebEventRegion.h:
4557        * page/ios/WebEventRegion.mm:
4558        (-[WebEventRegion p1]):
4559        (-[WebEventRegion p2]):
4560        (-[WebEventRegion p3]):
4561        (-[WebEventRegion p4]):
4562
45632014-07-16  Brady Eidson  <beidson@apple.com>
4564
4565        Add WebSecurityOrigin "webSecurityOriginFromDatabaseIdentifier" SPI and change _websiteDataURLForContainerWithURL: SPI
4566        <rdar://problem/17454712> and https://bugs.webkit.org/show_bug.cgi?id=134984
4567
4568        Reviewed by Dan Bernstein.
4569
4570        Change _websiteDataURLForContainerWithURL: SPI to include an optional bundle identifier argument:
4571        * UIProcess/API/Cocoa/WKProcessPool.mm:
4572        (+[WKProcessPool _websiteDataURLForContainerWithURL:bundleIdentifierIfNotInContainer:]):
4573        (+[WKProcessPool _websiteDataURLForContainerWithURL:]): Deleted.
4574        * UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
4575
4576        Add a big shiny comment in a few key places:
4577        * DatabaseProcess/DatabaseProcess.cpp:
4578        (WebKit::DatabaseProcess::initializeDatabaseProcess):
4579        * DatabaseProcess/IndexedDB/UniqueIDBDatabase.cpp:
4580        (WebKit::UniqueIDBDatabase::UniqueIDBDatabase):
4581        * UIProcess/WebContext.cpp:
4582        (WebKit::WebContext::applyPlatformSpecificConfigurationDefaults):
4583        (WebKit::WebContext::ensureDatabaseProcess):
4584
45852014-07-16  Roger Fong  <roger_fong@apple.com>
4586
4587        Captions container should not clip content.
4588        https://bugs.webkit.org/show_bug.cgi?id=134840.
4589        <rdar://problem/14553608>.
4590
4591        Reviewed by Simon Fraser.
4592
4593        Tests: media/track/track-in-band-subtitles-too-large.html
4594               media/track/track-long-word-container-sizing.html
4595
4596        * Modules/mediacontrols/mediaControlsApple.css:
4597        (video::-webkit-media-text-track-container):
4598        Set word break property of WebCTT cues to normal to make it consistent with in-band cues.
4599        * html/track/TextTrackCueGeneric.cpp:
4600        (WebCore::TextTrackCueGenericBoxElement::applyCSSProperties):
4601        Set -webkit-min-content on min-width/min-height property of the text track display.
4602        * html/track/VTTCue.cpp:
4603        (WebCore::VTTCueBox::applyCSSProperties):
4604        Do the same for WebVTT cues.
4605
46062014-07-16  Eric Carlson  <eric.carlson@apple.com>
4607
4608        [Mac] replace AVPlayerItem on the main thread
4609        https://bugs.webkit.org/show_bug.cgi?id=134983
4610
4611        Reviewed by Jer Noble.
4612
4613        No new tests, this fixes a problem with a thread configuration not present in the
4614        test environment.
4615
4616        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
4617        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
4618        (WebCore::MediaPlayerPrivateAVFoundationObjC::setAVPlayerItem): New, when called off of 
4619            the main thread, dispatch to the main thread before setting AVPlayerItem.
4620        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Call setAVPlayerItem.
4621        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Ditto.
4622        (WebCore::MediaPlayerPrivateAVFoundationObjC::setShouldBufferData): Ditto.
4623
46242014-07-16  Jer Noble  <jer.noble@apple.com>
4625
4626        [MSE] http/tests/media/media-source/mediasource-buffered.html is flakey
4627        https://bugs.webkit.org/show_bug.cgi?id=134949
4628
4629        Reviewed by Eric Carlson.
4630
4631        Depending on which SourceBuffer is successfully parsed first, the order of activeSourceBuffers
4632        may change from run to run, breaking the http/tests/media/media-source/mediasource-buffered.html
4633        test. Make the order of activeSourceBuffers the same as (a subset of) sourceBuffers, by replacing
4634        calls to activeSourceBuffers->add() and with a new call to regenerateActiveSourceBuffers(), which
4635        swaps the contents of the SourceBufferList with a new, ordered Vector.
4636
4637        * Modules/mediasource/MediaSource.cpp:
4638        (WebCore::MediaSource::addSourceBuffer):
4639        (WebCore::MediaSource::sourceBufferDidChangeAcitveState):
4640        (WebCore::MediaSource::regenerateActiveSourceBuffers):
4641        * Modules/mediasource/MediaSource.h:
4642        * Modules/mediasource/SourceBufferList.cpp:
4643        (WebCore::SourceBufferList::swap):
4644        * Modules/mediasource/SourceBufferList.h:
4645
46462014-07-16  Mike West  <mkwst@chromium.org>
4647
4648        CSP: Drop 'script-nonce' directive.
4649        https://bugs.webkit.org/show_bug.cgi?id=134926
4650
4651        Reviewed by Darin Adler.
4652
4653        This patch drops the outdated 'script-nonce' Content Security
4654        Policy directive. It was removed from the spec, and replaced in
4655        CSP2 with a new 'script-src' syntax. We should implement that
4656        instead.
4657
4658        Until then, removing the outdated syntax will ensure that no one
4659        ends up relying on it in WebKit's implementation.
4660
4661        This should have limited web-visible impact, as the feature is
4662        behind the CSP_NEXT flag, which is not enabled by default.
4663
4664        * dom/ScriptElement.cpp:
4665        (WebCore::ScriptElement::requestScript):
4666        (WebCore::ScriptElement::executeScript):
4667        * page/ContentSecurityPolicy.cpp:
4668        (WebCore::CSPDirectiveList::allowJavaScriptURLs):
4669        (WebCore::CSPDirectiveList::allowInlineEventHandlers):
4670        (WebCore::CSPDirectiveList::addDirective):
4671        (WebCore::NonceDirective::NonceDirective): Deleted.
4672        (WebCore::NonceDirective::allows): Deleted.
4673        (WebCore::NonceDirective::parse): Deleted.
4674        (WebCore::CSPDirectiveList::checkNonce): Deleted.
4675        (WebCore::CSPDirectiveList::checkNonceAndReportViolation): Deleted.
4676        (WebCore::CSPDirectiveList::allowScriptNonce): Deleted.
4677        (WebCore::isAllowedByAllWithNonce): Deleted.
4678        (WebCore::ContentSecurityPolicy::allowScriptNonce): Deleted.
4679        (WebCore::ContentSecurityPolicy::reportInvalidNonce): Deleted.
4680        * page/ContentSecurityPolicy.h:
4681
46822014-07-16  Jer Noble  <jer.noble@apple.com>
4683
4684        REGRESSION(r171069) 75% repro crash in WebCore::AudioHardwareListenerMac::processIsRunningChanged()
4685        https://bugs.webkit.org/show_bug.cgi?id=134986
4686
4687        Reviewed by Eric Carlson.
4688
4689        Add a WeakPtrFactory to AudioHardwareListenerMac, so that if CoreAudio calls our block after
4690        being unregistered, we can bail early instead of calling into a deleted object.
4691
4692        * platform/audio/mac/AudioHardwareListenerMac.cpp:
4693        (WebCore::AudioHardwareListenerMac::AudioHardwareListenerMac):
4694        * platform/audio/mac/AudioHardwareListenerMac.h:
4695
46962014-07-16  Jer Noble  <jer.noble@apple.com>
4697
4698        [MSE] REGRESSION(r171033): ASSERT in WebCore::MediaSource::onReadyStateChange()
4699        https://bugs.webkit.org/show_bug.cgi?id=134941
4700
4701        Reviewed by Eric Carlson.
4702
4703        Only do our modified-order change of the readyState if the error parameter is empty,
4704        as that's the only case where a duration change will cause an inadvertant readyState
4705        change.
4706
4707        * Modules/mediasource/MediaSource.cpp:
4708        (WebCore::MediaSource::streamEndedWithError):
4709
47102014-07-16  Alexey Proskuryakov  <ap@apple.com>
4711
4712        Remove svn:executable property erroneously added in <http://trac.webkit.org/changeset/171144> somehow.
4713
4714        * ChangeLog: Removed property svn:executable.
4715        * svg/SVGSVGElement.h: Removed property svn:executable.
4716        * svg/animation/SVGSMILElement.h: Removed property svn:executable.
4717
47182014-07-16  Daniel Bates  <dabates@apple.com>
4719
4720        Substitute CGRectZero for NSZeroRect in -[DOMNode hrefFrame].
4721
4722        Rubber-stamped by Zalan Bujtas.
4723
4724        The method -[DOMNode hrefFrame] returns a CGRect. So, when we don't have a renderer
4725        we should return CGRectZero instead of a NSZeroRect.
4726
4727        * bindings/objc/DOM.mm:
4728        (-[DOMNode hrefFrame]): Also, fix up some code style issues.
4729
47302014-07-16  Jeongeun Kim  <je_julie.kim@samsung.com>
4731
4732        mutable pointers from const methods, timeContainer().
4733        https://bugs.webkit.org/show_bug.cgi?id=134757
4734
4735        Reviewed by Alexey Proskuryakov.
4736
4737        Avoid return mutable pointers from const methods.
4738        No new tests, no behavior change.
4739
4740        * svg/SVGSVGElement.h:
4741        * svg/animation/SVGSMILElement.h:
4742        (WebCore::SVGSMILElement::timeContainer):
4743
47442014-07-15  Yusuke Suzuki  <utatane.tea@gmail.com>
4745
4746        CSS: Generalize CSS First Letter treatment
4747        https://bugs.webkit.org/show_bug.cgi?id=134936
4748
4749        Reviewed by Benjamin Poulain.
4750
4751        first-letter pseudo element rule is handled differently from the other rules
4752        such as first-line. This patch removes this special handling in SelectorChecker
4753        and handles it in RulesFeatureSet.
4754
4755        * css/RuleFeature.cpp:
4756        (WebCore::RuleFeatureSet::collectFeaturesFromSelector):
4757        (WebCore::RuleFeatureSet::add):
4758        (WebCore::RuleFeatureSet::clear):
4759        * css/RuleFeature.h:
4760        (WebCore::RuleFeatureSet::RuleFeatureSet):
4761        * css/SelectorChecker.cpp:
4762        (WebCore::SelectorChecker::matchRecursively):
4763        * css/StyleResolver.h:
4764        (WebCore::StyleResolver::usesFirstLetterRules):
4765        * dom/DocumentStyleSheetCollection.cpp:
4766        (WebCore::DocumentStyleSheetCollection::combineCSSFeatureFlags):
4767        (WebCore::DocumentStyleSheetCollection::resetCSSFeatureFlags):
4768        * dom/DocumentStyleSheetCollection.h:
4769        (WebCore::DocumentStyleSheetCollection::setUsesFirstLetterRules): Deleted.
4770
47712014-07-15  Simon Fraser  <simon.fraser@apple.com>
4772
4773        Fix non-iOS builds.
4774
4775        * rendering/RenderBox.cpp:
4776        (WebCore::shouldAppyContainersClipAndOffset):
4777
47782014-07-15  Simon Fraser  <simon.fraser@apple.com>
4779
4780        [iOS] Fix touches inside accelerated overflow:scroll
4781        https://bugs.webkit.org/show_bug.cgi?id=134961
4782        <rdar://problem/16088789>
4783
4784        Reviewed by Benjamin Poulain.
4785
4786        When individual elements inside an overflow:scroll with -webkit-overflow-scrolling: touch
4787        had touch event listeners, we would fail to take the scroll offset into account when
4788        building the touch event region, causing touches on those elements to fail after scrolling.
4789        
4790        Touch event region building uses RenderObject::absoluteClippedOverflowRect(), and that
4791        code path tries to fix up repaint rects to work correctly in composited overflow:scroll.
4792        However, that broke the touch region computation.
4793        
4794        Fix by only ignoring the scroll offset for calls to computeRectForRepaint() which
4795        have a non-null repaintContainer (which indicates that we're doing a repaint in the
4796        compositing layer), and for which the repaintContainer is the containing block
4797        which is using composited scrolling. This restores correct behavior to the event region
4798        code which always calls this with a null repaintContainer.
4799
4800        * rendering/RenderBox.cpp:
4801        (WebCore::shouldAppyContainersClipAndOffset):
4802        (WebCore::RenderBox::computeRectForRepaint):
4803
48042014-07-15  Simon Fraser  <simon.fraser@apple.com>
4805
4806        [iOS] Fix issues drawing subsampled image elements and CSS images
4807        https://bugs.webkit.org/show_bug.cgi?id=134944
4808        <rdar://problem/17634095>
4809
4810        Reviewed by Dean Jackson.
4811
4812        After r170675 it is important for BitmapImage::draw() to be given a srcRect computed
4813        using the original size of the image, not the subsampled size.
4814        
4815        So fix various code paths that end up in image drawing to use the originalSize(),
4816        which requires giving Image a virtual function that just returns size(), and hence has
4817        a FloatSize return value.
4818        
4819        Tested by setting a very low subsampling threshold and browsing various sites.
4820        
4821        A better longterm fix will happen via bug 134916.
4822
4823        * platform/graphics/BitmapImage.cpp:
4824        (WebCore::BitmapImage::originalSize):
4825        * platform/graphics/BitmapImage.h:
4826        * platform/graphics/GraphicsContext.cpp:
4827        (WebCore::GraphicsContext::drawImage):
4828        * platform/graphics/Image.cpp:
4829        (WebCore::Image::drawTiled):
4830        (WebCore::Image::computeIntrinsicDimensions):
4831        * platform/graphics/Image.h:
4832        (WebCore::Image::originalSize):
4833        * platform/graphics/cg/BitmapImageCG.cpp:
4834        (WebCore::BitmapImage::BitmapImage): Just use m_size for initializing the other members.
4835        (WebCore::BitmapImage::draw):
4836        * platform/graphics/cg/GraphicsContext3DCG.cpp:
4837        (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
4838        * platform/graphics/cg/ImageCG.cpp:
4839        (WebCore::Image::drawPattern):
4840
48412014-07-15  Brent Fulgham  <bfulgham@apple.com>
4842
4843        [Win] Unreviewed build fix after r171069.
4844
4845        Add missing AudioHardwareListener implementation on Windows.
4846
4847        * WebCore.vcxproj/WebCore.vcxproj:
4848        * WebCore.vcxproj/WebCore.vcxproj.filters:
4849
48502014-07-15  Antti Koivisto  <antti@apple.com>
4851
4852        REGRESSION (r155957): Invalid cast in WebCore::RenderNamedFlowThread::getRanges
4853        https://bugs.webkit.org/show_bug.cgi?id=134888
4854
4855        Reviewed by Mihnea Ovidenie.
4856
4857        Test: fast/regions/flowthread-getranges-box-cast.html
4858
4859        * rendering/RenderNamedFlowThread.cpp:
4860        (WebCore::RenderNamedFlowThread::getRanges): Test the type before casting.
4861
48622014-07-15  Carlos Alberto Lopez Perez  <clopez@igalia.com>
4863
4864        [GTK] Update GObject DOM bindings symbols file after r171014.
4865        https://bugs.webkit.org/show_bug.cgi?id=134907
4866
4867        Reviewed by Philippe Normand.
4868
4869        * bindings/gobject/webkitdom.symbols: Update to the current API.
4870
48712014-07-15  Manuel Rego Casasnovas  <rego@igalia.com>
4872
4873        Unreviwed fix wrong indentation from r171082.
4874
4875        * rendering/RenderGrid.cpp:
4876        (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid):
4877
48782014-07-14  Zalan Bujtas  <zalan@apple.com>
4879
4880        Subpixel rendering: Zero sized compositing container's content positioned off by one device pixel.
4881        https://bugs.webkit.org/show_bug.cgi?id=134903
4882
4883        Reviewed by Simon Fraser.
4884
4885        The compositing layer boundaries are calculated using its renderer()'s and the renderer()'s
4886        descendants' bounds. However when the renderer() is zero sized, its bounds are omitted.
4887        In such cases, when the child content has offset from the renderer(), the subpixel adjustment
4888        of the compositing layer becomes negative (-meaning that the compositing layer is to the right/bottom
4889        direction from its renderer()). Remove fabs() to be able to express such direction.
4890
4891        Test: compositing/hidpi-compositing-layer-with-zero-sized-container.html
4892
4893        * rendering/RenderLayerBacking.cpp:
4894        (WebCore::RenderLayerBacking::updateGeometry):
4895
48962014-07-14  Jeremy Jones  <jeremyj@apple.com>
4897
4898        Fix crash on WebVideoFullscreenManagerProxy construction.
4899        https://bugs.webkit.org/show_bug.cgi?id=134909
4900
4901        Unreviewed fix crash from r171089
4902
4903        Remove unnecessary dispatch to main queue since it can happen during construction.
4904
4905        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
4906        (WebVideoFullscreenInterfaceAVKit::setWebVideoFullscreenModel): remove dispatch_async
4907
49082014-07-14  Jeremy Jones  <jeremyj@apple.com>
4909
4910        WebVideoFullscreenInterfaceAVKit should only call the UI from main thread.
4911        https://bugs.webkit.org/show_bug.cgi?id=134890
4912
4913        Reviewed by Eric Carlson.
4914
4915        dispatch_async to the main thread before setting properties that would affect the UI.
4916
4917        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
4918        (WebVideoFullscreenInterfaceAVKit::setWebVideoFullscreenModel): wrap in call to dispatch_async
4919        (WebVideoFullscreenInterfaceAVKit::setDuration): ditto
4920        (WebVideoFullscreenInterfaceAVKit::setCurrentTime): ditto
4921        (WebVideoFullscreenInterfaceAVKit::setRate): ditto
4922        (WebVideoFullscreenInterfaceAVKit::setVideoDimensions): ditto
4923        (WebVideoFullscreenInterfaceAVKit::setSeekableRanges): ditto
4924        (WebVideoFullscreenInterfaceAVKit::setAudioMediaSelectionOptions): ditto
4925        (WebVideoFullscreenInterfaceAVKit::setLegibleMediaSelectionOptions): ditto
4926        (WebVideoFullscreenInterfaceAVKit::setExternalPlayback): ditto
4927
49282014-07-14  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
4929
4930        Fix the !ENABLE(FILTERS) && !ENABLE(CSS_FILTERS) build after r167497
4931        https://bugs.webkit.org/show_bug.cgi?id=134679
4932
4933        Reviewed by Darin Adler.
4934
4935        * html/ImageData.cpp:
4936        * platform/graphics/cairo/ImageBufferCairo.cpp:
4937
49382014-07-14  Manuel Rego Casasnovas  <rego@igalia.com>
4939
4940        [CSS Grid Layout] Support sparse in auto-placement algorithm
4941        https://bugs.webkit.org/show_bug.cgi?id=134544
4942
4943        Reviewed by Sergio Villar Senin.
4944
4945        This patch implements sparse mode for auto-placement algorithm, which is
4946        the default mode in the new grid-auto-flow syntax. It keeps track of the
4947        auto-placement cursor in
4948        RenderGrid::placeAutoMajorAxisItemsOnGrid() and updates it accordingly
4949        when auto-positioned items are placed.
4950        If we're in dense mode it resets the cursor after each item (which keeps
4951        the old behavior that was using dense mode by default).
4952
4953        GridIterator has been adapted to look for empty areas from a given
4954        position in both directions.
4955
4956        Test: fast/css-grid-layout/grid-auto-flow-sparse.html
4957
4958        * rendering/RenderGrid.cpp:
4959        (WebCore::RenderGrid::GridIterator::GridIterator): Modify constructor to
4960        add an optional argument for the varying index. This allows to look for
4961        empty areas in both axis.
4962        (WebCore::RenderGrid::placeAutoMajorAxisItemsOnGrid): Defined the
4963        auto-placement cursor and rested after each item if we're in dense mode.
4964        (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid): Use auto-placement
4965        cursor to look for empty areas from the last auto-positioned item
4966        placed.
4967        * rendering/RenderGrid.h: Modify placeAutoMajorAxisItemOnGrid() header
4968        to receive the auto-placement cursor.
4969
49702014-07-14  Brent Fulgham  <bfulgham@apple.com>
4971
4972        [iOS] Some videos play as inline audio-only content
4973        https://bugs.webkit.org/show_bug.cgi?id=134898.
4974        <rdar://problem/17629379>
4975
4976        Reviewed by Eric Carlson.
4977
4978        Add a new 'presentationType' accessor that indicates if the media
4979        element is playing in 'audio' mode. This can happen if a video
4980        element plays an HLS stream that starts off in audio-only mode.
4981
4982        * html/HTMLMediaElement.cpp:
4983        (WebCore::HTMLMediaElement::presentationType): Added.
4984        * html/HTMLMediaElement.h:
4985        * platform/audio/MediaSession.cpp:
4986        (WebCore::MediaSession::presentationType): Added.
4987        * platform/audio/MediaSession.h:
4988        * platform/audio/MediaSessionManager.cpp: 
4989        (WebCore::MediaSessionManager::sessionRestrictsInlineVideoPlayback):
4990        Use the presentationType, rather than the mediaType to control
4991        inline playback behavior.
4992        * platform/audio/ios/AudioDestinationIOS.h:
4993        (WebCore::AudioDestinationMac::presentationType): Add presentationType.
4994        * platform/audio/mac/AudioDestinationMac.h:
4995        (WebCore::AudioDestinationMac::presentationType): Ditto.
4996
49972014-07-14  Bear Travis  <betravis@adobe.com>
4998
4999        [Feature Queries] Enable Feature Queries on Mac
5000        https://bugs.webkit.org/show_bug.cgi?id=134404
5001
5002        Reviewed by Antti Koivisto.
5003
5004        Enable Feature Queries on Mac and resume running the
5005        feature tests.
5006
5007        * Configurations/FeatureDefines.xcconfig: Turn on
5008        ENABLE_CSS3_CONDITIONAL_RULES.
5009
50102014-07-11  David Hyatt  <hyatt@apple.com>
5011
5012        <rdar://problem/17305458> Cannot interact with video controls in ePubs
5013        Bug 134836 - [New Multicolumn] Crawl to check for compositing between us and the enclosingPaginationLayer
5014        https://bugs.webkit.org/show_bug.cgi?id=134836
5015
5016        Reviewed by Dean Jackson.
5017
5018        The paginatedAndComposited bit being set in updateLayerPositions just didn't work, since compositing states
5019        can change without triggering that function. This patch just gets rid of the bit and does a crawl every time
5020        to check. This ensures that changes in compositing states don't necessitate any changes in pagination,
5021        since the lookup will always check the current compositing state.
5022        
5023        The new function that does this check is hasCompositedLayerInEnclosingPaginationChain.
5024        
5025        I have been unable to reproduce this issue, and this is therefore a purely speculative fix. I have no test
5026        case to provide because of this.
5027
5028        * rendering/RenderLayer.cpp:
5029        (WebCore::RenderLayer::RenderLayer):
5030        (WebCore::RenderLayer::updateLayerPositions):
5031        (WebCore::RenderLayer::hasCompositedLayerInEnclosingPaginationChain):
5032        (WebCore::RenderLayer::updatePagination):
5033        * rendering/RenderLayer.h:
5034
50352014-07-14  Zalan Bujtas  <zalan@apple.com>
5036
5037        Move composite bounds calculation to RenderLayerBacking.
5038        https://bugs.webkit.org/show_bug.cgi?id=134864
5039
5040        Reviewed by Darin Adler.
5041
5042        No change in functionality.
5043
5044        * rendering/RenderLayerBacking.cpp:
5045        (WebCore::RenderLayerBacking::updateCompositedBounds):
5046        * rendering/RenderLayerCompositor.cpp: it was just proxying the calculateLayerBounds()
5047        to the RenderLayer.
5048        (WebCore::RenderLayerCompositor::calculateCompositedBounds): Deleted.
5049        * rendering/RenderLayerCompositor.h:
5050
50512014-07-14  Tim Horton  <timothy_horton@apple.com>
5052
5053        Fix the build.
5054
5055        * platform/audio/MediaSessionManager.h:
5056
50572014-07-14  Eric Carlson  <eric.carlson@apple.com>
5058
5059        [Mac] don't enable low power audio mode on external output devices
5060        https://bugs.webkit.org/show_bug.cgi?id=134877
5061
5062        Reviewed by Sam Weinig.
5063
5064        No new tests, this deals with changes to the audio hardware at runtime.
5065
5066        * WebCore.xcodeproj/project.pbxproj: Remove AudioSessionListener.h.
5067        * WebCore.vcxproj/WebCore.vcxproj: Ditto.
5068
5069        * platform/audio/AudioHardwareListener.cpp:
5070        (WebCore::AudioHardwareListener::AudioHardwareListener): Initialize m_outputDeviceSupportsLowPowerMode
5071            to true on iOS.
5072        * platform/audio/AudioHardwareListener.h:
5073        (WebCore::AudioHardwareListener::outputDeviceSupportsLowPowerMode): New accessor.
5074        (WebCore::AudioHardwareListener::setHardwareActivity): New setter for derived classes.
5075        (WebCore::AudioHardwareListener::setOutputDeviceSupportsLowPowerMode): Ditto.
5076
5077        Remove AudioSessionListener interface, it wasn't being used.
5078        * platform/audio/AudioSession.cpp:
5079        (WebCore::AudioSession::addListener): Deleted.
5080        (WebCore::AudioSession::removeListener): Deleted.
5081        (WebCore::AudioSession::beganAudioInterruption): Deleted.
5082        (WebCore::AudioSession::endedAudioInterruption): Deleted.
5083        * platform/audio/AudioSession.h:
5084        * platform/audio/AudioSessionListener.h: Removed.
5085
5086        * platform/audio/MediaSessionManager.cpp:
5087        (WebCore::MediaSessionManager::addSession): Allocate the AudioHardwareListener if necessary.
5088        (WebCore::MediaSessionManager::removeSession): Free the AudioHardwareListener if necessary.
5089        (WebCore::MediaSessionManager::audioOutputDeviceChanged): AudioHardwareListener client interface
5090            called when the output device changes, call updateSessionState to make sure we are using
5091            the correct buffer size.
5092        * platform/audio/MediaSessionManager.h:
5093
5094        * platform/audio/ios/AudioDestinationIOS.h:
5095        * platform/audio/ios/AudioSessionIOS.mm:
5096        (WebCore::AudioSessionPrivate::AudioSessionPrivate): Drive-by cleanup, remove ObjC helper object
5097            that was used to listen for OS notifications, it is no longer used.
5098        (SOFT_LINK_POINTER): Deleted.
5099        (-[WebAudioSessionHelper initWithCallback:]): Deleted.
5100        (-[WebAudioSessionHelper dealloc]): Deleted.
5101        (-[WebAudioSessionHelper interruption:]): Deleted.
5102
5103        * platform/audio/mac/AudioHardwareListenerMac.cpp:
5104        (WebCore::currentDeviceSupportsLowPowerBufferSize): New, return true only if using build-in 
5105            transport device.
5106        (WebCore::processIsRunningPropertyDescriptor): Return reference to static AudioObjectPropertyAddress
5107            for kAudioHardwarePropertyProcessIsRunning instead of declaring one in every method
5108            that needs one.
5109        (WebCore::outputDevicePropertyDescriptor): Return reference to static AudioObjectPropertyAddress
5110            for kAudioHardwarePropertyDefaultOutputDevice.
5111        (WebCore::AudioHardwareListenerMac::AudioHardwareListenerMac): Restructure and add audio object
5112            listener for default output device.
5113        (WebCore::AudioHardwareListenerMac::~AudioHardwareListenerMac): *Remove* listener audio object
5114            property listener instead of *Adding* a new one. Remove new listener.
5115        (WebCore::AudioHardwareListenerMac::propertyChanged): Enumerate the properties that changed,
5116            call appropriate method.
5117        (WebCore::AudioHardwareListenerMac::processIsRunningChanged): Renamed from setHardwareActive, 
5118            cleanup.
5119        (WebCore::AudioHardwareListenerMac::outputDeviceChanged): New, call client.audioHardwareOutputDeviceChanged.
5120        (WebCore::AudioHardwareListenerMac::setHardwareActive): Deleted, renamed processIsRunningChanged.
5121        * platform/audio/mac/AudioHardwareListenerMac.h:
5122
5123        * platform/audio/mac/MediaSessionManagerMac.cpp:
5124        (MediaSessionManager::updateSessionState): Only set the output buffer size to 4K when hardware
5125            supports it.
5126
51272014-07-13  Benjamin Poulain  <benjamin@webkit.org>
5128
5129        Remove SelectorCheckerFastPath from the style resolution algorithm
5130        https://bugs.webkit.org/show_bug.cgi?id=134866
5131
5132        Reviewed by Antti Koivisto.
5133
5134        SelectorCheckerFastPath is now pure overhead because it can almost never match
5135        if the CSS JIT was unable to compile.
5136
5137        * css/ElementRuleCollector.cpp:
5138        (WebCore::ElementRuleCollector::ruleMatches):
5139        The "pre-filter" behind fastCheckableSelector had two parts:
5140        1) Filtering the pseudoID.
5141        2) Filtering on the rule hash.
5142
5143        The first part has been generalized (RuleDatacanMatchPseudoElement())
5144        and moved to collectMatchingRulesForList(). 
5145
5146        (WebCore::ElementRuleCollector::collectMatchingRulesForList):
5147        * css/RuleSet.cpp:
5148        (WebCore::selectorCanMatchPseudoElement):
5149        (WebCore::RuleData::RuleData):
5150        (WebCore::RuleSet::addRegionRule):
5151        (WebCore::RuleSet::addRulesFromSheet):
5152        * css/RuleSet.h:
5153        (WebCore::RuleData::canMatchPseudoElement):
5154        (WebCore::RuleData::hasFastCheckableSelector): Deleted.
5155        * css/StyleResolver.cpp:
5156
51572014-07-13  Benjamin Poulain  <benjamin@webkit.org>
5158
5159        Remove an useless check from SelectorChecker
5160        https://bugs.webkit.org/show_bug.cgi?id=134868
5161
5162        Reviewed by Darin Adler.
5163
5164        * css/SelectorChecker.cpp:
5165        (WebCore::SelectorChecker::matchRecursively):
5166        The condition of this if() branch can never be met for the mode "QueryingRules".
5167
5168        The next condition in that if() is "dynamicPseudo != NOPSEUDO", which implies
5169        a pseudo element was matched prior to the current context/simple selector.
5170        This cannot happen with QueryingRules, since we never match pseudo elements for
5171        SelectorQuery.
5172
51732014-07-12  Nikos Andronikos  <nikos.andronikos-webkit@cisra.canon.com.au>
5174
5175        Elements with rendering disabled due to dimensions should not contribute to parent bounding box
5176        https://bugs.webkit.org/show_bug.cgi?id=134184
5177
5178        Reviewed by Dirk Schulze.
5179
5180        SVG elements that have rendering disabled should not contribute to any ancestor elements bounding box.
5181        Examples of elements with rendering disabled:
5182        - basic shape with width <= 0 or height <= 0
5183        - path with no path data (d attribute missing or empty)
5184        - polyline or polygon element with no point data (points attribute missing or empty)
5185
5186        To achieve this a method (isRenderingDisabled) was added to RenderSVGShape and it's derived classes.
5187        This is used to determine if an element is included when creating the union of child bounding boxes
5188        in a container element.
5189
5190        Tests: svg/custom/GetBBox-path-nodata.html
5191               svg/custom/GetBBox-polygon-nodata.html
5192               svg/custom/GetBBox-polyline-nodata.html
5193               svg/custom/getBBox-container-hiddenchild.html
5194
5195        * rendering/svg/RenderSVGEllipse.cpp:
5196        (WebCore::RenderSVGEllipse::isRenderingDisabled):
5197        New method added. Checks bounding box to determine if rendering is disabled.
5198        * rendering/svg/RenderSVGEllipse.h:
5199        * rendering/svg/RenderSVGPath.cpp:
5200        (WebCore::RenderSVGPath::isRenderingDisabled):
5201        New method added. Checks bounding box to determine if rendering is disabled.
5202        * rendering/svg/RenderSVGPath.h:
5203        * rendering/svg/RenderSVGRect.cpp:
5204        (WebCore::RenderSVGRect::isRenderingDisabled):
5205        New method added. Checks bounding box to determine if rendering is disabled.
5206        * rendering/svg/RenderSVGRect.h:
5207        * rendering/svg/RenderSVGShape.h:
5208        (WebCore::RenderSVGShape::isRenderingDisabled):
5209        New method added. Always returns false so that derived classes that do not
5210        implement this method retain the existing behaviour.
5211        * rendering/svg/SVGRenderSupport.cpp:
5212        (WebCore::SVGRenderSupport::computeContainerBoundingBoxes):
5213        For each element potentially being included in the unioned bounding box of
5214        a container, check isRenderingDisabled and skip that element if true.
5215
5216        * rendering/svg/RenderSVGEllipse.cpp:
5217        (WebCore::RenderSVGEllipse::isRenderingDisabled):
5218        * rendering/svg/RenderSVGEllipse.h:
5219        * rendering/svg/RenderSVGPath.cpp:
5220        (WebCore::RenderSVGPath::isRenderingDisabled):
5221        * rendering/svg/RenderSVGPath.h:
5222        * rendering/svg/RenderSVGRect.cpp:
5223        (WebCore::RenderSVGRect::isRenderingDisabled):
5224        * rendering/svg/RenderSVGRect.h:
5225        * rendering/svg/RenderSVGShape.h:
5226        * rendering/svg/SVGRenderSupport.cpp:
5227        (WebCore::SVGRenderSupport::computeContainerBoundingBoxes):
5228
52292014-07-12  Benjamin Poulain  <benjamin@webkit.org>
5230
5231        Rename selectorListContainsUncommonAttributeSelector() to selectorListContainsAttributeSelector()
5232        https://bugs.webkit.org/show_bug.cgi?id=134862
5233
5234        Reviewed by Sam Weinig.
5235
5236        Unlike containsUncommonAttributeSelector(), selectorListContainsUncommonAttributeSelector() does not
5237        evaluate the attribute for "uncommon" types.
5238
5239        It would be possible to change the function instead to evaluate common attributes based
5240        on the match type and the pseudo class type. Such change would be more risky
5241        and we would get very little benefit from it, I leave that for later if that ever becomes useful.
5242
5243        * css/RuleSet.cpp:
5244        (WebCore::selectorListContainsAttributeSelector):
5245        (WebCore::containsUncommonAttributeSelector):
5246        (WebCore::selectorListContainsUncommonAttributeSelector): Deleted.
5247
52482014-07-12  Zan Dobersek  <zdobersek@igalia.com>
5249
5250        Use braced-init-list to create one-item Vector object in insertPerformanceEntry
5251        https://bugs.webkit.org/show_bug.cgi?id=133675
5252
5253        Reviewed by Darin Adler.
5254
5255        * page/PerformanceUserTiming.cpp:
5256        (WebCore::insertPerformanceEntry): Avoid wasting three lines for creating a
5257        Vector object with just one item that in the end gets copied. Use the
5258        braced-init-list syntax instead, leveraging Vector's std::initializer_list
5259        constructor.
5260
52612014-07-12  Allan Sandfeld Jensen  <allan.jensen@digia.com>
5262
5263        Memory leaks with autoLoadImages off
5264        https://bugs.webkit.org/show_bug.cgi?id=124411
5265
5266        Reviewed by Darin Adler.
5267
5268        Do not emit notifyFinished for images with deferred load,
5269        and allow deferred loads to be cancelled.
5270
5271        * loader/cache/CachedResource.cpp:
5272        (WebCore::CachedResource::checkNotify):
5273        (WebCore::CachedResource::cancelLoad):
5274
52752014-07-11  Jer Noble  <jer.noble@apple.com>
5276
5277        [MSE] http/tests/media/media-source/mediasource-duration.html is failing.
5278        https://bugs.webkit.org/show_bug.cgi?id=134852
5279
5280        Reviewed by Eric Carlson.
5281
5282        Fixes the following tests:
5283        http/tests/media/media-source/mediasource-config-change-mp4-a-bitrate.html
5284        http/tests/media/media-source/mediasource-config-change-mp4-av-audio-bitrate.html
5285        http/tests/media/media-source/mediasource-config-change-mp4-av-video-bitrate.html
5286        http/tests/media/media-source/mediasource-config-change-mp4-v-bitrate.html
5287        http/tests/media/media-source/mediasource-config-change-mp4-v-framerate.html
5288        http/tests/media/media-source/mediasource-duration.html
5289        http/tests/media/media-source/mediasource-play.html
5290
5291        The primary change necessary to fix the mediasource-duration.html test was to add support
5292        for delaying the completion of a seek operation until the HTMLMediaElement's readyState
5293        rises to > HAVE_CURRENT_DATA. This is accomplished by modifying MediaSourcePrivate to have
5294        waitForSeekCompleted() and seekCompleted() virtual methods. These are called by MediaSource
5295        when a seek operation results in the current time moving outside the currently buffered time
5296        ranges, and when an append operation results in the readyState changing, respectively.
5297
5298        A number of other drive-by fixes were necessary to get this test fully passing, as noted
5299        below.
5300
5301        Make the MediaSource the primary owner of the media's duration, rather than the MediaSourcePrivate.
5302        Move the MediaSourcePrivateClient pointer to the MediaSourcePrivate from the MediaPlayerPrivate, so
5303        the MediaSource's duration can be retrieved.  While we're at it, do the same thing for buffered.
5304
5305        * Modules/mediasource/MediaSource.cpp:
5306        (WebCore::MediaSource::MediaSource): Initialize m_duration.
5307        (WebCore::MediaSource::duration): Simple accessor.
5308        (WebCore::MediaSource::setDurationInternal): Bring 'duration change algorithm' up to spec.
5309        (WebCore::MediaSource::setReadyState): Reset m_duration on close.
5310        * Modules/mediasource/MediaSource.h:
5311        * platform/graphics/MediaSourcePrivate.h:
5312        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
5313        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::load): Do not call setPrivateAndOpen().
5314        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::durationDouble): Pass through to MediaSourcePrivateAVFObjC.
5315        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered): Ditto.
5316        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
5317        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
5318        (WebCore::MediaSourcePrivateAVFObjC::create): Call setPrivateAndOpen().
5319        (WebCore::MediaSourcePrivateAVFObjC::MediaSourcePrivateAVFObjC): Set m_client.
5320        (WebCore::MediaSourcePrivateAVFObjC::duration): Pass through to MediaSourcePrivateClient.
5321        (WebCore::MediaSourcePrivateAVFObjC::buffered): Ditto.
5322        (WebCore::MediaSourcePrivateAVFObjC::durationChanged): Pass through to MediaPlayerPrivateMediaSourceAVFObjC.
5323        (WebCore::MediaSourcePrivateAVFObjC::setDuration): Deleted.
5324        * platform/graphics/gstreamer/MediaSourceGStreamer.cpp:
5325        (WebCore::MediaSourceGStreamer::open): Pass in MediaSourcePrivateClient.
5326        (WebCore::MediaSourceGStreamer::MediaSourceGStreamer): Initialize m_mediaSource.
5327        (WebCore::MediaSourceGStreamer::durationChanged): Retrieve the duration from MediaSourcePrivateClient.
5328        (WebCore::MediaSourceGStreamer::markEndOfStream): Remove unnecssary ASSERT.
5329        (WebCore::MediaSourceGStreamer::unmarkEndOfStream): Ditto.
5330        (WebCore::MediaSourceGStreamer::setDuration): Deleted.
5331        * platform/graphics/gstreamer/MediaSourceGStreamer.h:
5332        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
5333        (WebCore::MockMediaPlayerMediaSource::load): Do not call setPrivateAndOpen().
5334        (WebCore::MockMediaPlayerMediaSource::buffered): Pass through to MockMediaSourcePrivate.
5335        (WebCore::MockMediaPlayerMediaSource::durationDouble): Ditto.
5336        (WebCore::MockMediaPlayerMediaSource::advanceCurrentTime): Ditto.
5337        * platform/mock/mediasource/MockMediaSourcePrivate.cpp:
5338        (WebCore::MockMediaSourcePrivate::create): Call setPrivateAndOpen().
5339        (WebCore::MockMediaSourcePrivate::MockMediaSourcePrivate): Set m_client.
5340        (WebCore::MockMediaSourcePrivate::duration): Pass through to MediaSourcePrivateClient.
5341        (WebCore::MockMediaSourcePrivate::buffered): Ditto.
5342        (WebCore::MockMediaSourcePrivate::durationChanged): Pass thorugh to MockMediaPlayerMediaSource.
5343        (WebCore::MockMediaSourcePrivate::setDuration): Deleted.
5344
5345        Route seekToTime through MediaSource, rather than through MediaSourcePrivate, so that
5346        the time can be compared against the buffered ranges, and trigger the delay of the seek
5347        operation if necessary. Add a seekTimer to MediaPlayerPrivateMediaSourceAVFObjC, as this
5348        guarantees the order of asynchronous operations, rather than callOnMainThread, which can
5349        cause async operations to occur out of order.
5350
5351        * Modules/mediasource/MediaSource.cpp:
5352        (WebCore::MediaSource::seekToTime): Bring up to spec.
5353        (WebCore::MediaSource::completeSeek): Ditto.
5354        (WebCore::MediaSource::monitorSourceBuffers): Call completeSeek() when appropriate.
5355        * Modules/mediasource/SourceBuffer.cpp:
5356        (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime): Deleted.
5357        (WebCore::SourceBuffer::seekToTime): Renamed from sourceBufferPrivateSeekToTime().
5358        * platform/graphics/MediaSourcePrivate.h:
5359        * platform/graphics/MediaSourcePrivateClient.h:
5360        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
5361        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
5362        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC): Add seekTimer. Only
5363            call timeChanged() if no longer seeking, thereby triggering a 'seeked' event.
5364        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::~MediaPlayerPrivateMediaSourceAVFObjC): Clear m_seekTimer.
5365        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekWithTolerance): Use m_seekTimer.
5366        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekTimerFired): Call seekInternal.
5367        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal): Add logging.
5368        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::waitForSeekCompleted): Added.
5369        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekCompleted): Added; trigger 'seeked'.
5370        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setReadyState): No longer attempt to finish seek when
5371            readyState changes here; this has been moved up to MediaSource.cpp.
5372        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
5373        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
5374        (WebCore::MediaSourcePrivateAVFObjC::waitForSeekCompleted): Pass through to MediaPlayerPrivateMediaSourceAVFObjC.
5375        (WebCore::MediaSourcePrivateAVFObjC::seekCompleted): Ditto.
5376        (WebCore::MediaSourcePrivateAVFObjC::seekToTime): Pass through to MediaSourcePrivateClient.
5377        (WebCore::MediaSourcePrivateAVFObjC::fastSeekTimeForMediaTime): Ditto.
5378        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
5379        (WebCore::MockMediaPlayerMediaSource::MockMediaPlayerMediaSource): Initialize m_seekCompleted.
5380        (WebCore::MockMediaPlayerMediaSource::seeking): Check for an uncompleted seek operation. 
5381        (WebCore::MockMediaPlayerMediaSource::seekWithTolerance): Ditto.
5382        (WebCore::MockMediaPlayerMediaSource::waitForSeekCompleted): Added.
5383        (WebCore::MockMediaPlayerMediaSource::seekCompleted): Added; trigger 'seeked'.
5384        * platform/mock/mediasource/MockMediaPlayerMediaSource.h:
5385        * platform/mock/mediasource/MockMediaSourcePrivate.cpp:
5386        (WebCore::MockMediaSourcePrivate::waitForSeekCompleted): Pass through to MockMediaPlayerMediaSource.
5387        (WebCore::MockMediaSourcePrivate::seekCompleted): Ditto.
5388        * platform/mock/mediasource/MockMediaSourcePrivate.h:
5389
5390        Drive-by fixes.
5391
5392        * Modules/mediasource/MediaSource.cpp:
5393        (WebCore::MediaSource::streamEndedWithError): Re-order the steps in streamEndedWithError()
5394            to avoid the MediaSource being closed and re-opened by the resulting duration change
5395            operation.
5396        * Modules/mediasource/MediaSource.h:
5397        * Modules/mediasource/SourceBuffer.cpp:
5398        (WebCore::SourceBuffer::remove): Added logging.
5399        (WebCore::SourceBuffer::removeCodedFrames): Ditto.
5400        (WebCore::SourceBuffer::hasFutureTime): Swap an ASSERT for an early-return; it's possible
5401            for currentTime() to be outside of a buffered area.
5402        * Modules/mediasource/SourceBuffer.h:
5403        * html/HTMLMediaElement.cpp:
5404        (WebCore::HTMLMediaElement::parseAttribute): Do not issue an additional 'timeupdate' event
5405            after finishSeek() issues one of its own.
5406        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
5407        (WebCore::globalDataParserQueue): Allow parsing operations to happen concurrently on
5408            background queues.
5409
54102014-07-12  Eric Carlson  <eric.carlson@apple.com>
5411
5412        [iOS] update control type when playback state changes
5413        https://bugs.webkit.org/show_bug.cgi?id=134856
5414
5415        Reviewed by Dean Jackson.
5416
5417        Check to make sure the correct type of media controls are showing when playback state
5418        changes so we don't end up with the wrong type of controls during playback.
5419
5420        * Modules/mediacontrols/mediaControlsApple.js: 
5421        (Controller.prototype.HandledVideoEvents): Drive-by fix, call handlePlay on 'playing' instead
5422            of 'play' so controls don't hide too early.
5423        * Modules/mediacontrols/mediaControlsiOS.js:
5424        (ControllerIOS.prototype.setPlaying): New, call updateControls to make sure inline
5425            controls are shown when appropriate.
5426
54272014-07-12  Dean Jackson  <dino@apple.com>
5428
5429        [iOS Media] Start playback button should indicate when it can't play
5430        https://bugs.webkit.org/show_bug.cgi?id=134851
5431
5432        Post-commit review with Eric Carlson on IRC.
5433
5434        * Modules/mediacontrols/mediaControlsiOS.js:
5435        (ControllerIOS.prototype.updateStatusDisplay): Remove the line that sets the
5436        class on the inline play button.
5437
54382014-07-11  Dean Jackson  <dino@apple.com>
5439
5440        [iOS Media] Start playback button should indicate when it can't play
5441        https://bugs.webkit.org/show_bug.cgi?id=134851
5442
5443        Reviewed by Sam Weinig.
5444
5445        If a video element has errors and cannot play, then the start
5446        playback button should use the "broken" icon.
5447
5448        * Modules/mediacontrols/mediaControlsApple.js: Add a new "failed" class.
5449        * Modules/mediacontrols/mediaControlsiOS.js:
5450        (ControllerIOS.prototype.shouldHaveStartPlaybackButton): We need a playback button
5451        even when there is an error.
5452        (ControllerIOS.prototype.handleWirelessPickerButtonTouchStart): Don't offer Airplay
5453        if we're in an error state.
5454        (ControllerIOS.prototype.updateStatusDisplay): Set the "failed" class on
5455        the playback buttons if we are in an error state.
5456
54572014-07-11  Benjamin Poulain  <benjamin@webkit.org>
5458
5459        Partition the CSS rules based on the most specific filter of the rightmost fragment
5460        https://bugs.webkit.org/show_bug.cgi?id=134828
5461
5462        Reviewed by Andreas Kling.
5463
5464        Previously, RuleSet was partitioning each rule based on the rightmost filter.
5465        While fast, this had the side effect of putting many selectors with ID match in the class
5466        bucket (because the selectors are generally written starting with the ID).
5467
5468        This patch replace the code of findBestRuleSetAndAdd() by a simple loop going over all
5469        the simple selectors in the rightmost fragment to find the best bucket.
5470
5471        * css/ElementRuleCollector.cpp:
5472        (WebCore::ElementRuleCollector::ruleMatches):
5473        * css/RuleSet.cpp:
5474        (WebCore::isSelectorMatchingHTMLBasedOnRuleHash):
5475        I unified ruleData.hasRightmostSelectorMatchingHTMLBasedOnRuleHash() and hasMultipartSelector().
5476
5477        (WebCore::RuleData::RuleData):
5478        (WebCore::rulesCountForName):
5479        (WebCore::RuleSet::addRule):
5480        I removed the recursive part of findBestRuleSetAndAdd() (which was wrong anyway). The function
5481        was useless so I just moved the algorithm to addRule() directly.
5482
5483        We first loop over all the CSSSelectors related by SubSelector, this correspond to the rightmost fragment.
5484        If a filter with high specificity is found, we add the rule immediately and end there.
5485        If a filter that is not very specific is found, we keep a pointer to the selector to use it later.
5486
5487        (WebCore::RuleSet::findBestRuleSetAndAdd): Deleted.
5488        * css/RuleSet.h:
5489        (WebCore::RuleData::hasMultipartSelector): Deleted.
5490
54912014-07-11  Alex Christensen  <achristensen@webkit.org>
5492
5493        [WinCairo] Unreviewed build fix after r170937.
5494
5495        * WebCore.vcxproj/WebCoreGeneratedWinCairo.make:
5496        Update and apply changes applied to WebCoreGenerated.make in r170937.
5497
54982014-07-11  Joseph Pecoraro  <pecoraro@apple.com>
5499
5500        Web Inspector: Crash when using a stale InspectableNode Node
5501        https://bugs.webkit.org/show_bug.cgi?id=134849
5502
5503        Reviewed by Timothy Hatcher.
5504
5505        * inspector/PageConsoleAgent.cpp:
5506
55072014-07-11  Jer Noble  <jer.noble@apple.com>
5508
5509        [MSE] Separate MediaSource logging into its own log channel
5510        https://bugs.webkit.org/show_bug.cgi?id=134809
5511
5512        Reviewed by Eric Carlson.
5513
5514        Separate out MediaSource logging (which can be quite verbose) into its own log channel,
5515        distinct from the Media log channel. Add some per-sample logging and further sequester that
5516        logging into its own MediaSourceSamples log channel.
5517
5518        Add the MediaSource and MediaSourceSamples channels:
5519        * platform/Logging.h:
5520
5521        Move LOG(Media) -> LOG(MediaSource):
5522        * Modules/mediasource/MediaSource.cpp:
5523        (WebCore::MediaSource::MediaSource):
5524        (WebCore::MediaSource::~MediaSource):
5525        (WebCore::MediaSource::setReadyState):
5526        (WebCore::MediaSource::addSourceBuffer):
5527        (WebCore::MediaSource::removeSourceBuffer):
5528        (WebCore::MediaSource::isTypeSupported):
5529        * Modules/mediasource/SourceBuffer.cpp:
5530        (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime):
5531        (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete):
5532        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
5533        (WebCore::SourceBuffer::sourceBufferPrivateDidBecomeReadyForMoreSamples):
5534        (WebCore::SourceBuffer::provideMediaData):
5535        (WebCore::SourceBuffer::monitorBufferingRate):
5536        (WebCore::SourceBuffer::textTrackAddCues):
5537        (WebCore::SourceBuffer::hasFutureTime):
5538        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
5539        (WebCore::SourceBufferPrivateAVFObjC::didParseStreamDataAsAsset):
5540        (WebCore::SourceBufferPrivateAVFObjC::didFailToParseStreamDataWithError):
5541        (WebCore::SourceBufferPrivateAVFObjC::processCodedFrame):
5542        (WebCore::SourceBufferPrivateAVFObjC::didProvideContentKeyRequestInitializationDataForTrackID):
5543        (WebCore::SourceBufferPrivateAVFObjC::append):
5544        (WebCore::SourceBufferPrivateAVFObjC::layerDidReceiveError):
5545        (WebCore::SourceBufferPrivateAVFObjC::rendererDidReceiveError):
5546        (WebCore::SourceBufferPrivateAVFObjC::flushAndEnqueueNonDisplayingSamples):
5547        (WebCore::SourceBufferPrivateAVFObjC::enqueueSample):
5548
55492014-07-11  Brady Eidson  <beidson@apple.com>
5550
5551        Phone numbers that span two lines are not detected.
5552        <rdar://problem/17601146> and https://bugs.webkit.org/show_bug.cgi?id=134808
5553
5554        Reviewed by Tim Horton.
5555
5556        * editing/Editor.cpp:
5557        (WebCore::Editor::scanSelectionForTelephoneNumbers): After scanning a range from the TextIterator,
5558            create an "edge range" window around the end of the TextIterator range, and scan it.
5559            Also make sure to not accumulate duplicate ranges that might have showed up in both the
5560            TextIterator range and the edge window range.
5561
55622014-07-11  Enrica Casucci  <enrica@apple.com>
5563
5564        Implement textStylingAtPosition in WK2.
5565        https://bugs.webkit.org/show_bug.cgi?id=134843
5566        <rdar://problem/17614981>
5567        
5568        Reviewed by Benjamin Poulain.
5569
5570        Adding some exports and making styleForSelectionStart public.
5571
5572        * WebCore.exp.in:
5573        * editing/Editor.h:
5574
55752014-07-11  Zalan Bujtas  <zalan@apple.com>
5576
5577        REGRESSION (r168868): eBay 'see all' links fail due to different JS bindings conversion behavior.
5578        https://bugs.webkit.org/show_bug.cgi?id=134841
5579        <rdar://problem/17577563>
5580
5581        Reviewed by Simon Fraser.
5582
5583        Revert back to type int for Element.scroll* APIs in order to preserve exception handling
5584        behavior.
5585
5586        Test: cssom/non-subpixel-scroll-top-left-values.html
5587
5588        * dom/Element.cpp:
5589        (WebCore::Element::scrollLeft):
5590        (WebCore::Element::scrollTop):
5591        (WebCore::Element::setScrollLeft):
5592        (WebCore::Element::setScrollTop):
5593        (WebCore::Element::scrollWidth):
5594        (WebCore::Element::scrollHeight):
5595        * dom/Element.h:
5596        * dom/Element.idl:
5597        * html/HTMLBodyElement.cpp:
5598        (WebCore::adjustForZoom):
5599        (WebCore::HTMLBodyElement::scrollLeft):
5600        (WebCore::HTMLBodyElement::setScrollLeft):
5601        (WebCore::HTMLBodyElement::scrollTop):
5602        (WebCore::HTMLBodyElement::setScrollTop):
5603        (WebCore::HTMLBodyElement::scrollHeight):
5604        (WebCore::HTMLBodyElement::scrollWidth):
5605        * html/HTMLBodyElement.h:
5606
56072014-07-11  Joseph Pecoraro  <pecoraro@apple.com>
5608
5609        Web Inspector: Debugger Pause button does not work
5610        https://bugs.webkit.org/show_bug.cgi?id=134785
5611
5612        Reviewed by Timothy Hatcher.
5613
5614        * CMakeLists.txt:
5615        * DerivedSources.make:
5616        * inspector/CommandLineAPIModuleSource.js:
5617        Minification strips the sourceURL command. Add it back with minification.
5618
56192014-07-11  Andreas Kling  <akling@apple.com>
5620
5621        Use the bare minimum tile coverage rect when under memory pressure.
5622        <https://webkit.org/b/134837>
5623
5624        When the browser is under critical memory pressure, don't generate any
5625        more tiles than are needed to cover the exposed viewport rect.
5626
5627        Reviewed by Pratik Solanki.
5628
5629        * page/FrameView.cpp:
5630        (WebCore::FrameView::computeCoverageRect):
5631
56322014-07-11  Javier Fernandez  <jfernandez@igalia.com>
5633
5634        [CSS Grid Layout] Implement justify-self css property
5635        https://bugs.webkit.org/show_bug.cgi?id=134419
5636
5637        Reviewed by Dean Jackson.
5638
5639        This change adds the justify-self property from CSS 3 Box Alignment
5640        and implements the parsing.
5641
5642        From Blink r164685 by <jchaffraix@chromium.org>
5643
5644        Test: fast/css/parse-justify-self.html
5645
5646        * css/CSSComputedStyleDeclaration.cpp:
5647        (WebCore::ComputedStyleExtractor::propertyValue):
5648        * css/CSSParser.cpp:
5649        (WebCore::isValidKeywordPropertyAndValue):
5650        (WebCore::CSSParser::parseValue):
5651        (WebCore::isItemPositionKeyword):
5652        (WebCore::CSSParser::parseJustifySelf):
5653        * css/CSSParser.h:
5654        * css/CSSPrimitiveValueMappings.h:
5655        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
5656        (WebCore::CSSPrimitiveValue::operator EJustifySelf):
5657        (WebCore::CSSPrimitiveValue::operator EJustifySelfOverflowAlignment):
5658        * css/CSSPropertyNames.in:
5659        * css/CSSValueKeywords.in:
5660        * css/DeprecatedStyleBuilder.cpp:
5661        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
5662        * css/StyleResolver.cpp:
5663        (WebCore::StyleResolver::applyProperty):
5664        * rendering/style/RenderStyle.h:
5665        * rendering/style/RenderStyleConstants.h:
5666        * rendering/style/StyleRareNonInheritedData.cpp:
5667        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
5668        (WebCore::StyleRareNonInheritedData::operator==):
5669        * rendering/style/StyleRareNonInheritedData.h:
5670
56712014-07-11  Bear Travis  <betravis@adobe.com>
5672
5673        [Feature Queries] Feature Query CSS Grammar Productions Should Return a Value
5674        https://bugs.webkit.org/show_bug.cgi?id=134810
5675
5676        Reviewed by Antti Koivisto.
5677
5678        The parsing return values are used to determine if a feature query is valid. Two
5679        grammar productions have been updated to correctly return a value.
5680
5681        Tests exist for this feature but will not be run until the feature is turned on.
5682        See https://bugs.webkit.org/show_bug.cgi?id=134404.
5683
5684        * css/CSSGrammar.y.in: Adding return values for two valid feature query productions.
5685
56862014-07-10  Brent Fulgham  <bfulgham@apple.com>
5687
5688        Use a separate backdrop element to allow cues to have highlight and background color
5689        https://bugs.webkit.org/show_bug.cgi?id=134821
5690        <rdar://problem/15999721>
5691
5692        Reviewed by Eric Carlson.
5693
5694        Add a new <div> element wrapping the existing cue <span>. This allows
5695        us to have a highlight on the cue (in the <span> background), as well
5696        as an overall background color.
5697
5698        * Modules/mediacontrols/mediaControlsApple.css:
5699        (video::-webkit-media-text-track-display-backdrop): New markup for
5700        the backdrop element of the caption.
5701        * html/track/VTTCue.cpp:
5702        (WebCore::VTTCue::cueBackdropShadowPseudoId): Added to
5703        allow user customization of the cue backdrop.
5704        (WebCore::VTTCue::initialize): Rename the old "m_cueBackgroundBox" to
5705        "m_cueHighlightBox" and add a new "m_cueBackdropBox" member.
5706        (WebCore::VTTCue::updateDisplayTree): Update for m_cueHighlightBox.
5707        (WebCore::VTTCue::getDisplayTree): Make m_cueHighlightBox a child
5708        of the new m_cueBackdropBox element, and add m_cueBackdropBox to
5709        the display tree.
5710        * html/track/VTTCue.h:
5711        (WebCore::VTTCue::element):
5712        * page/CaptionUserPreferencesMediaAF.cpp:
5713        (WebCore::CaptionUserPreferencesMediaAF::setInterestedInCaptionPreferenceChanges):
5714        Fix for missing caption style updates. Even if we are already
5715        listening for caption changes, we still want to update the new
5716        instance's style sheet to match.
5717        (WebCore::CaptionUserPreferencesMediaAF::captionsStyleSheetOverride):
5718        * rendering/RenderVTTCue.cpp:
5719        (WebCore::RenderVTTCue::initializeLayoutParameters): Take the new
5720        <div> into consideration when looking for the Cue text element.
5721
57222014-07-11  Zalan Bujtas  <zalan@apple.com>
5723
5724        Subpixel layout: return integral results for offset*, client*, scroll* by default.
5725        https://bugs.webkit.org/show_bug.cgi?id=134651
5726
5727        Reviewed by Simon Fraser.
5728
5729        Revert to returning integral values for Element.offset* client* scroll* by default.
5730        Fractional values break number of sites(tight design) and JS frameworks(fail to handle fractional values).
5731
5732        Since snapped dimension depends on both the original point and the width/height of the box,
5733        we need to call RenderBoxModelObject::pixelSnapped*() helpers, instead of round().
5734
5735        Covered by existing tests
5736 
5737        * dom/Element.cpp:
5738        (WebCore::subpixelMetricsEnabled):
5739        (WebCore::convertToNonSubpixelValueIfNeeded):
5740        (WebCore::Element::offsetLeft):
5741        (WebCore::Element::offsetTop):
5742        (WebCore::Element::offsetWidth):
5743        (WebCore::Element::offsetHeight):
5744        (WebCore::Element::clientLeft):
5745        (WebCore::Element::clientTop):
5746        (WebCore::Element::clientWidth):
5747        (WebCore::Element::clientHeight):
5748        * page/Settings.in:
5749
57502014-07-11  Zalan Bujtas  <zalan@apple.com>
5751
5752        Subpixel rendering: icloud.com password arrow has clipped circle at some window sizes.
5753        https://bugs.webkit.org/show_bug.cgi?id=134824
5754        <rdar://problem/17612729>
5755
5756        Reviewed by Simon Fraser.
5757
5758        Transparent layer clipping needs device pixel offset adjusting.
5759
5760        Test: fast/layers/wrong-clipping-semi-transparent-compositing-layer-on-subpixel-position.html
5761
5762        * rendering/RenderLayer.cpp:
5763        (WebCore::RenderLayer::beginTransparencyLayers):
5764        (WebCore::RenderLayer::paintLayer):
5765        (WebCore::RenderLayer::paintLayerContents):
5766        (WebCore::RenderLayer::paintBackgroundForFragments):
5767        (WebCore::RenderLayer::paintForegroundForFragments):
5768        * rendering/RenderLayer.h:
5769
57702014-07-11  Carlos Garcia Campos  <cgarcia@igalia.com>
5771
5772        Unreviewed. Remove unused file.
5773
5774        * html/shadow/MediaControlsGtk.h: Removed.
5775
57762014-07-11  Manuel Rego Casasnovas  <rego@igalia.com>
5777
5778        [CSS Grid Layout] Update grid-auto-flow to the new syntax
5779        https://bugs.webkit.org/show_bug.cgi?id=134057
5780
5781        Reviewed by Sergio Villar Senin.
5782
5783        In last versions of the spec grid-auto-flow syntax has changed. New
5784        syntax is:
5785        [ row | column ] && dense? | stack && [ row | column ]?
5786
5787        Implemented parsing for new syntax and added/modified test cases in
5788        current layout tests.
5789
5790        For the moment, the implementation keeps working in the same way, but
5791        using "stack" value for grid-auto-flow property instead of "none". This
5792        should be fixed in a follow-up patch once "stack" is properly
5793        implemented.
5794
5795        Also "dense" needs to be reviewed. Right now auto-placement algorithm is
5796        always "dense" and never "sparse".
5797
5798        No new tests, update current tests to add new cases.
5799
5800        * css/CSSComputedStyleDeclaration.cpp:
5801        (WebCore::ComputedStyleExtractor::propertyValue): Adapt to new syntax.
5802        * css/CSSParser.cpp:
5803        (WebCore::isValidKeywordPropertyAndValue): Removed grid-auto-flow as it
5804        is not a keyword anymore.
5805        (WebCore::isKeywordPropertyID): Ditto.
5806        (WebCore::CSSParser::parseValue): Add specific method for parsing
5807        grid-auto-flow.
5808        (WebCore::CSSParser::parseGridShorthand): Adapt parsing for
5809        grid-auto-flow property inside the shorthand.
5810        (WebCore::isValidGridAutoFlowId): Helper method to check if the CSSValue
5811        id is a valid keyword for grid-auto-flow property.
5812        (WebCore::CSSParser::parseGridAutoFlow): Implement new parsing for
5813        grid-auto-flow.
5814        * css/CSSParser.h: Method header for grid-auto-flow parsing.
5815        * css/CSSPrimitiveValueMappings.h:
5816        (WebCore::CSSPrimitiveValue::operator GridAutoFlow): Deleted.
5817        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Deleted.
5818        * css/CSSValueKeywords.in: Add new keywords required by grid-auto-flow:
5819        "dense" and "stack".
5820        * css/DeprecatedStyleBuilder.cpp:
5821        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder): Remove
5822        default handler as grid-auto-flow is not a keyword now.
5823        * css/StyleResolver.cpp:
5824        (WebCore::StyleResolver::applyProperty): Implement particular handler
5825        for new grid-auto-flow syntax.
5826        * rendering/RenderGrid.cpp:
5827        (WebCore::RenderGrid::placeItemsOnGrid): Keep old "none" behavior as
5828        "stack" behavior for the moment.
5829        (WebCore::RenderGrid::autoPlacementMajorAxisDirection): Use the new
5830        helper methods in RenderStyle.
5831        (WebCore::RenderGrid::autoPlacementMinorAxisDirection): Ditto.
5832        * rendering/style/GridResolvedPosition.cpp:
5833        (WebCore::GridResolvedPosition::resolveGridPositionsFromStyle): Again
5834        keep old "none" behavior for "stack".
5835        * rendering/style/RenderStyle.h: Add new helper methods to know the
5836        direction and algorithm of grid-auto-flow property.
5837        * rendering/style/RenderStyleConstants.h: Redefine GridAutoFlow enum
5838        using flags for algorithm and direction.
5839        * rendering/style/StyleGridData.h: Change m_gridAutoFlow type to
5840        unsigned.
5841
58422014-07-10  Myles C. Maxfield  <mmaxfield@apple.com>
5843
5844        [iOS] Pasting rich content does not perform a two-step paste
5845        https://bugs.webkit.org/show_bug.cgi?id=134795
5846
5847        Reviewed by Benjamin Poulain.
5848
5849        UIKit requires writing something (anything!) to a particular pasteboard
5850        during copy in order to flag the content as rich. When a paste occurs,
5851        UIKit will read this flag and perform a two-step paste.
5852
5853        Test: platform/ios-sim/editing/pasteboard/two-step-paste.html
5854
5855        * platform/ios/PlatformPasteboardIOS.mm:
5856        (WebCore::PlatformPasteboard::write):
5857
58582014-07-09  Andy Estes  <aestes@apple.com>
5859
5860        [iOS] Some QuickLook documents are not displayed as previews
5861        https://bugs.webkit.org/show_bug.cgi?id=134788
5862        <rdar://problem/17278194>
5863
5864        Reviewed by Pratik Solanki.
5865
5866        ResourceRequest::isMainResourceRequest() is not reliable (e.g. ResourceRequests reconstituted from an
5867        NSURLRequest have no way to set this bit properly) and should probably be removed. Instead of using
5868        isMainResourceRequest() to check if a QuickLookHandle should be created when the Network Process is in use,
5869        just check if the current ResourceLoader is the same as the DocumentLoader's ResourceLoader.
5870
5871        No new tests. QuickLook is not testable from WebKit.
5872
5873        * platform/network/ios/QuickLook.mm:
5874        (WebCore::QuickLookHandle::create):
5875
58762014-07-10  Andreas Kling  <akling@apple.com>
5877
5878        [iOS WebKit2] Don't uninstall the memory pressure listener after first signal.
5879        <https://webkit.org/b/134814>
5880
5881        The call to uninstall() should not be made on iOS since iOS doesn't use the
5882        hold-off mechanism in MemoryPressureHandler.
5883
5884        Reviewed by Benjamin Poulain.
5885
5886        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
5887        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
5888
58892014-07-10  Jer Noble  <jer.noble@apple.com>
5890
5891        [MSE] Overlapping appended ranges must cause the decoder to flush and re-enqueue.
5892        https://bugs.webkit.org/show_bug.cgi?id=134805
5893
5894        Reviewed by Eric Carlson.
5895
5896        When appending a range of media data which overlaps with an existing range, SourceBuffer
5897        must cause the decoder to flush and re-enqueue samples. Those samples removed by appending
5898        the overlapping range may have already been enqueued for display, and unless the decode
5899        queue is flushed, corruption or decode errors may occur as the new samples are enqueued for
5900        display.
5901
5902        Add a boolean flag onto TrackBuffer to indicate whether the decoder needs to be flushed and
5903        re-enqueued the next time an append operation completes. Set this flag whenever samples are
5904        removed due to overlapping or an explicit call to removeCodedFrames(). Move the contents of
5905        sourceBufferPrivateSeekToTime() (which previously did flushing and re-enqueueing) into a new
5906        function, reenqueueMediaForTime(), which can be called from sourceBufferPrivateAppendComplete().
5907
5908        Drive-by fix: findSyncSampleAfterDecodeIterator() would return the passed in iterator if that
5909        sample is a sync-sample. Fix this to correctly return the next sync sample.
5910
5911        Drive-by fix: Use a SampleMap, rather than a DecodeOrderSampleMap, to track erased samples
5912        so that the erasedSamples are correctly accounted for in both presentation and decode orders.
5913
5914        * Modules/mediasource/SampleMap.cpp:
5915        (WebCore::SampleMap::empty): Add convenience method.
5916        (WebCore::DecodeOrderSampleMap::findSyncSampleAfterDecodeIterator): Drive-by fix.
5917        * Modules/mediasource/SampleMap.h:
5918        (WebCore::SampleMap::decodeOrder): Added const accessor.
5919        (WebCore::SampleMap::presentationOrder): Ditto.
5920        (WebCore::SampleMap::addRange): Added.
5921        * Modules/mediasource/SourceBuffer.cpp:
5922        (WebCore::SourceBuffer::TrackBuffer::TrackBuffer): Add needsReenqueeing flag.
5923        (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime): Move contents into reenqueueMediaForTime().
5924        (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete): Call reenqueMediaForTime() if necessary.
5925        (WebCore::SourceBuffer::removeCodedFrames): Set needsReenqueing.
5926        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto.
5927        (WebCore::SourceBuffer::provideMediaData): Drive-by fix.
5928        (WebCore::SourceBuffer::reenqueueMediaForTime): Moved from sourceBufferPrivateSeekToTime().
5929        * Modules/mediasource/SourceBuffer.h:
5930
59312014-07-10  Pratik Solanki  <psolanki@apple.com>
5932
5933        ASSERT in SharedBuffer::maybeAppendDataArray() on MobileSafari launch
5934        https://bugs.webkit.org/show_bug.cgi?id=134812
5935        <rdar://problem/17628434>
5936
5937        Reviewed by Joseph Pecoraro.
5938
5939        Fix bug in my fix in r170930. Initialize the badly named m_shouldUsePurgeableMemory field to
5940        false. This field indicates when it is okay to use purgeable memory and is set to true once
5941        the resource is finished loading. By setting it to true in the constructor we were creating
5942        purgeable memory while the resource was still being loaded and this triggered the assert.
5943
5944        No new tests. Should be covered by existing tests.
5945
5946        * platform/cf/SharedBufferCF.cpp:
5947        (WebCore::SharedBuffer::SharedBuffer):
5948
59492014-07-10  Andreas Kling  <akling@apple.com>
5950
5951        [iOS WebKit2] Some memory pressure relief tweaks.
5952        <https://webkit.org/b/134811>
5953
5954        Split memory pressure relief into critical and non-critical sections.
5955        Non-critical relief is for clearing out things that are really not
5956        essential, e.g unused font data, text measurement caches, etc.
5957
5958        On iOS, only flip the "WebKit is under memory pressure" flag when we
5959        are under *critical* memroy pressure, rather than doing it early on
5960        and gimping ourselves because other processes are too big.
5961
5962        Also added logging for when we transition in/out of system pressure.
5963
5964        Reviewed by Geoffrey Garen.
5965
5966        * platform/MemoryPressureHandler.cpp:
5967        (WebCore::MemoryPressureHandler::releaseNoncriticalMemory):
5968        (WebCore::MemoryPressureHandler::releaseCriticalMemory):
5969        (WebCore::MemoryPressureHandler::releaseMemory):
5970        * platform/MemoryPressureHandler.h:
5971        (WebCore::MemoryPressureHandler::ReliefLogger::loggingEnabled):
5972        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
5973        (WebCore::MemoryPressureHandler::install):
5974
59752014-07-10  Beth Dakin  <bdakin@apple.com>
5976
5977        Need Setting/WKPreference that allows clients to prevent scrollbars from drawing 
5978        on a secondary thread
5979        https://bugs.webkit.org/show_bug.cgi?id=134778
5980        -and corresponding-
5981        <rdar://problem/17595333>
5982
5983        Reviewed by Tim Horton.
5984
5985        This is a requirement for some types of performance tests. The patch adds a new 
5986        virtual function to ScrollableArea that forces subclasses to indicate the value of 
5987        the Setting. This is required because Scrollbar and ScrollableArea can’t get to 
5988        Settings on their own.
5989
5990        * page/FrameView.cpp:
5991        (WebCore::FrameView::forceUpdateScrollbarsOnMainThreadForPerformanceTesting):
5992        * page/FrameView.h:
5993        * page/Settings.in:
5994        * platform/ScrollableArea.h:
5995        * platform/Scrollbar.cpp:
5996        (WebCore::Scrollbar::supportsUpdateOnSecondaryThread):
5997        * platform/win/PopupMenuWin.h:
5998        * rendering/RenderLayer.cpp:
5999        (WebCore::RenderLayer::forceUpdateScrollbarsOnMainThreadForPerformanceTesting):
6000        * rendering/RenderLayer.h:
6001        * rendering/RenderListBox.cpp:
6002        (WebCore::RenderListBox::forceUpdateScrollbarsOnMainThreadForPerformanceTesting):
6003        * rendering/RenderListBox.h:
6004
60052014-07-10  Brady Eidson  <beidson@apple.com>
6006
6007        Phone number highlights should always be visible if the mouse hovers over.
6008        <rdar://problem/17527476> and https://bugs.webkit.org/show_bug.cgi?id=134784
6009
6010        Reviewed by Tim Horton.
6011
6012        * WebCore.exp.in:
6013
60142014-07-10  Timothy Horton  <timothy_horton@apple.com>
6015
6016        Assertions or crashes under _takeViewSnapshot when restoring windows
6017        https://bugs.webkit.org/show_bug.cgi?id=134792
6018
6019        Reviewed by Simon Fraser.
6020
6021        * platform/graphics/cocoa/IOSurface.mm:
6022        (IOSurface::createFromImage):
6023
60242014-07-10  Youenn Fablet  <youenn.fablet@crf.canon.fr>
6025
6026        [XHR] overrideMimeType() should be able to change encoding in HEADERS RECEIVED state
6027        https://bugs.webkit.org/show_bug.cgi?id=128968
6028
6029        Reviewed by Alexey Proskuryakov.
6030
6031        Moved response encoding computation from didReceiveResponse to didReceiveData, just before the decoder is instantiated.
6032        This allows overrideMimeType to be changed within readystatechange event callback and have an impact on selected encoding.
6033
6034        Test: http/tests/xmlhttprequest/overridemimetype-headers-received-state-force-shiftjis.html
6035
6036        * xml/XMLHttpRequest.cpp:
6037        (WebCore::XMLHttpRequest::didReceiveResponse): Removed m_responseEncoding computation from response and mimeTypeOverride.
6038        (WebCore::XMLHttpRequest::didReceiveData): Added m_responseEncoding computation from response and mimeTypeOverride.
6039
60402014-07-09  Brady Eidson  <beidson@apple.com>
6041
6042        Fire connected/disconnected events for Gamepads.
6043        https://bugs.webkit.org/show_bug.cgi?id=134386
6044
6045        Reviewed by Dean Jackson.
6046
6047        No new tests (No effect in a currently tested config)
6048
6049        * Modules/gamepad/GamepadManager.cpp:
6050        (WebCore::navigatorGamepadFromDOMWindow): Handling converting a possibly-null Navigator into
6051            a possibly null NavigatorGamepad.
6052        (WebCore::GamepadManager::platformGamepadConnected): Notify blind Navigator/DOMWindows of all
6053            previously attached Gamepads, then notify everybody of this new gamepad.
6054        (WebCore::GamepadManager::platformGamepadDisconnected): Handle dispatching the disconnected
6055            event to all registered DOMWindows.
6056        (WebCore::GamepadManager::platformGamepadInputActivity): Notify blind Navigator/DOMWindows of all
6057            attached Gamepads.
6058        (WebCore::GamepadManager::makeGamepadVisible): Handles notifying setting up a new gamepads
6059            with all NavigatorGamepads as well as dispatching the connected even to DOMWindows.
6060        (WebCore::GamepadManager::registerDOMWindow):
6061        (WebCore::GamepadManager::unregisterDOMWindow):
6062        (WebCore::GamepadManager::makeGamepadsVisibileToBlindNavigators): Deleted.
6063        * Modules/gamepad/GamepadManager.h:
6064
6065        * Modules/gamepad/NavigatorGamepad.cpp:
6066        (WebCore::NavigatorGamepad::gamepadAtIndex):
6067        * Modules/gamepad/NavigatorGamepad.h:
6068
60692014-07-09  Benjamin Poulain  <bpoulain@apple.com>
6070
6071        [iOS][WK2] Disable text quantization while actively changing the page's scale factor
6072        https://bugs.webkit.org/show_bug.cgi?id=134781
6073
6074        Reviewed by Tim Horton and Myles C. Maxfield.
6075
6076        Query the chrome client to setup quantization on each layers.
6077
6078        * page/ChromeClient.h:
6079        (WebCore::ChromeClient::hasStablePageScaleFactor):
6080        * platform/graphics/mac/FontMac.mm:
6081        (WebCore::Font::drawGlyphs):
6082        * rendering/RenderLayer.cpp:
6083        (WebCore::RenderLayer::setupFontSubpixelQuantization):
6084
60852014-07-09  peavo@outlook.com  <peavo@outlook.com>
6086
6087        [Curl] Cache entry invalidated too early.
6088        https://bugs.webkit.org/show_bug.cgi?id=134681
6089
6090        Reviewed by Alex Christensen.
6091
6092        When a cache entry has expired, it is invalidated when a request for the corresponding url is started.
6093        This is too early, since the resource is possibly not modified (even though it has expired),
6094        and the server might respond with a 304 (not modified) response.
6095        When we then receive a 304 response, the cache entry is deleted, and we have no cached response/data to provide.
6096        This can be solved by not invalidating the entry when a request for that url is started,
6097        but instead invalidate when a 200 OK response is received (which means the resource has been modified).
6098
6099        * platform/network/curl/CurlCacheManager.cpp:
6100        (WebCore::CurlCacheManager::isCached): Avoid invalidating cache entry when it has expired, wait until we know the server response.
6101        * platform/network/curl/CurlCacheManager.h: Added const modifier.
6102
61032014-07-09  Myles C. Maxfield  <mmaxfield@apple.com>
6104
6105        Revert r170413 and r170390
6106        https://bugs.webkit.org/show_bug.cgi?id=134741
6107
6108        Reviewed by Benjamin Poulain.
6109
6110        These patches caused a variety of failures. I'm going to break them up into
6111        smaller chunks and commit them separately at some point in the future.
6112
6113        Requesting a review from Ben Poulain because there were some conflicts with
6114        r170561 in InlineTextBox.cpp and InlineTextBox.h.
6115
6116        * WebCore.exp.in:
6117        * platform/graphics/Font.cpp:
6118        (WebCore::Font::drawText):
6119        (WebCore::Font::drawEmphasisMarks):
6120        (WebCore::Font::adjustSelectionRectForText):
6121        (WebCore::computeUnderlineType):
6122        * platform/graphics/Font.h:
6123        * platform/graphics/FontFastPath.cpp:
6124        (WebCore::Font::getGlyphsAndAdvancesForSimpleText):
6125        (WebCore::Font::drawSimpleText):
6126        (WebCore::Font::drawEmphasisMarksForSimpleText):
6127        (WebCore::Font::drawGlyphBuffer):
6128        (WebCore::Font::drawEmphasisMarks):
6129        (WebCore::Font::adjustSelectionRectForSimpleText):
6130        * platform/graphics/GlyphBuffer.h:
6131        (WebCore::GlyphBuffer::size):
6132        (WebCore::GlyphBuffer::glyphs):
6133        (WebCore::GlyphBuffer::advances):
6134        (WebCore::GlyphBuffer::fontDataAt):
6135        (WebCore::GlyphBuffer::advanceAt):
6136        (WebCore::GlyphBuffer::offsetAt):
6137        (WebCore::GlyphBuffer::reverse):
6138        (WebCore::GlyphBuffer::offsetInString):
6139        (WebCore::GlyphBuffer::swap):
6140        * platform/graphics/GraphicsContext.cpp:
6141        * platform/graphics/Latin1TextIterator.h:
6142        (WebCore::Latin1TextIterator::Latin1TextIterator):
6143        (WebCore::Latin1TextIterator::currentCharacter):
6144        * platform/graphics/SimpleFontData.h:
6145        * platform/graphics/SurrogatePairAwareTextIterator.cpp:
6146        (WebCore::SurrogatePairAwareTextIterator::SurrogatePairAwareTextIterator):
6147        * platform/graphics/SurrogatePairAwareTextIterator.h:
6148        (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
6149        * platform/graphics/TextRun.h:
6150        (WebCore::TextRun::length):
6151        (WebCore::TextRun::charactersLength):
6152        * platform/graphics/WidthIterator.cpp:
6153        (WebCore::WidthIterator::glyphDataForCharacter):
6154        (WebCore::applyFontTransforms):
6155        (WebCore::WidthIterator::advanceInternal):
6156        (WebCore::WidthIterator::advance):
6157        (WebCore::WidthIterator::advanceOneCharacter):
6158        * platform/graphics/WidthIterator.h:
6159        * platform/graphics/cairo/FontCairo.cpp:
6160        (WebCore::Font::drawGlyphs):
6161        * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
6162        (WebCore::Font::drawComplexText):
6163        (WebCore::Font::drawEmphasisMarksForComplexText):
6164        (WebCore::Font::adjustSelectionRectForComplexText):
6165        * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
6166        (WebCore::HarfBuzzShaper::setNormalizedBuffer):
6167        * platform/graphics/mac/FontComplexTextMac.cpp:
6168        (WebCore::Font::adjustSelectionRectForComplexText):
6169        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
6170        (WebCore::Font::drawComplexText):
6171        (WebCore::Font::drawEmphasisMarksForComplexText):
6172        * platform/graphics/mac/FontMac.mm:
6173        (WebCore::Font::drawGlyphs):
6174        * platform/graphics/win/FontCGWin.cpp:
6175        (WebCore::Font::drawGlyphs):
6176        * platform/graphics/win/FontWin.cpp:
6177        (WebCore::Font::adjustSelectionRectForComplexText):
6178        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
6179        (WebCore::Font::drawComplexText):
6180        (WebCore::Font::drawEmphasisMarksForComplexText):
6181        * platform/graphics/wince/FontWinCE.cpp:
6182        (WebCore::Font::drawGlyphs):
6183        (WebCore::Font::drawComplexText):
6184        (WebCore::Font::drawEmphasisMarksForComplexText):
6185        (WebCore::Font::selectionRectForComplexText):
6186        * rendering/InlineTextBox.cpp:
6187        (WebCore::InlineTextBox::isSelected):
6188        (WebCore::InlineTextBox::selectionState):
6189        (WebCore::InlineTextBox::localSelectionRect):
6190        (WebCore::InlineTextBox::paint):
6191        (WebCore::InlineTextBox::selectionStartEnd):
6192        (WebCore::InlineTextBox::paintSelection):
6193        (WebCore::InlineTextBox::paintCompositionBackground):
6194        (WebCore::InlineTextBox::paintDocumentMarker):
6195        (WebCore::InlineTextBox::paintTextMatchMarker):
6196        (WebCore::InlineTextBox::computeRectForReplacementMarker):
6197        (WebCore::InlineTextBox::paintCompositionUnderline):
6198        (WebCore::InlineTextBox::positionForOffset):
6199        (WebCore::InlineTextBox::constructTextRun):
6200        * rendering/InlineTextBox.h:
6201        (WebCore::InlineTextBox::truncation):
6202        * rendering/RenderCombineText.cpp:
6203        (WebCore::RenderCombineText::getStringToRender):
6204        * rendering/RenderCombineText.h:
6205        * rendering/RenderTextLineBoxes.cpp:
6206        (WebCore::ellipsisRectForBox):
6207        * rendering/svg/SVGInlineFlowBox.cpp:
6208        (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
6209        * rendering/svg/SVGInlineTextBox.cpp:
6210        (WebCore::SVGInlineTextBox::positionForOffset):
6211        (WebCore::SVGInlineTextBox::localSelectionRect):
6212        (WebCore::SVGInlineTextBox::paintSelectionBackground):
6213        (WebCore::SVGInlineTextBox::mapStartEndPositionsIntoFragmentCoordinates):
6214        (WebCore::SVGInlineTextBox::paintText):
6215        * rendering/svg/SVGInlineTextBox.h:
6216        * rendering/svg/SVGTextMetricsBuilder.cpp:
6217        (WebCore::SVGTextMetricsBuilder::currentCharacterStartsSurrogatePair):
6218        (WebCore::SVGTextMetricsBuilder::advance):
6219        * rendering/svg/SVGTextQuery.cpp:
6220        (WebCore::SVGTextQuery::mapStartEndPositionsIntoFragmentCoordinates):
6221        (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures):
6222        (WebCore::SVGTextQuery::subStringLengthCallback):
6223        (WebCore::SVGTextQuery::startPositionOfCharacterCallback):
6224        (WebCore::SVGTextQuery::endPositionOfCharacterCallback):
6225        (WebCore::SVGTextQuery::rotationOfCharacterCallback):
6226        (WebCore::SVGTextQuery::extentOfCharacterCallback):
6227        (WebCore::SVGTextQuery::characterNumberAtPositionCallback):
6228        * rendering/svg/SVGTextQuery.h:
6229        * rendering/svg/SVGTextRunRenderingContext.cpp:
6230        (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
6231        (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
6232        * rendering/svg/SVGTextRunRenderingContext.h:
6233        * svg/SVGFontData.cpp:
6234        (WebCore::SVGFontData::applySVGGlyphSelection):
6235        * svg/SVGFontData.h:
6236
62372014-07-08  Jeffrey Pfau  <jpfau@apple.com>
6238
6239        Fix flaky loading tests
6240        https://bugs.webkit.org/show_bug.cgi?id=133696
6241
6242        Reviewed by Ryosuke Niwa.
6243
6244        In some cases, the Frame may be destroyed while the loader is
6245        initializing. Make sure we don't delete it too early.
6246
6247        * loader/FrameLoader.cpp:
6248        (WebCore::FrameLoader::init):
6249
62502014-07-09  Simon Fraser  <simon.fraser@apple.com>
6251
6252        Make IndirectCompositingReason an enum class
6253        https://bugs.webkit.org/show_bug.cgi?id=134789
6254
6255        Reviewed by Tim Horton.
6256
6257        Make RenderLayer::IndirectCompositingReason an enum class, and change some code
6258        in RenderLayerCompositor::reasonsForCompositing() to use a switch.
6259
6260        * rendering/RenderLayer.cpp:
6261        (WebCore::RenderLayer::RenderLayer):
6262        * rendering/RenderLayer.h:
6263        * rendering/RenderLayerCompositor.cpp:
6264        (WebCore::RenderLayerCompositor::computeCompositingRequirements):
6265        (WebCore::RenderLayerCompositor::requiresOwnBackingStore):
6266        (WebCore::RenderLayerCompositor::reasonsForCompositing):
6267        (WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason):
6268
62692014-07-09  Pratik Solanki  <psolanki@apple.com>
6270
6271        Make SharedBuffer::append(SharedBuffer*) be smarter about CFData and data arrays
6272        https://bugs.webkit.org/show_bug.cgi?id=134731
6273
6274        Reviewed by Antti Koivisto.
6275
6276        If the target SharedBuffer has a CFDataRef or a data array then we can simply retain that
6277        CFDataRef or data array elements in the SharedBuffer being appended to. This avoids
6278        unnecessary copying.
6279
6280        No new tests because no functional changes.
6281
6282        * platform/SharedBuffer.cpp:
6283        (WebCore::SharedBuffer::append):
6284        (WebCore::SharedBuffer::maybeAppendPlatformData):
6285        * platform/SharedBuffer.h:
6286        * platform/cf/SharedBufferCF.cpp:
6287        (WebCore::SharedBuffer::maybeAppendPlatformData):
6288        (WebCore::SharedBuffer::maybeAppendDataArray):
6289        * platform/soup/SharedBufferSoup.cpp:
6290        (WebCore::SharedBuffer::maybeAppendPlatformData):
6291
62922014-07-09  Brent Fulgham  <bfulgham@apple.com>
6293
6294        [Win] Remove uses of 'bash' in build system
6295        https://bugs.webkit.org/show_bug.cgi?id=134782
6296        <rdar://problem/17615533>
6297
6298        Reviewed by Dean Jackson.
6299
6300        Remove uses of 'bash' by replacing Windows-specific bash scripts
6301        with Perl equivalents.
6302
6303        * WebCore.vcxproj/WebCoreGenerated.make:
6304        * WebCore.vcxproj/WebCoreGenerated.vcxproj:
6305        * WebCore.vcxproj/WebCoreGenerated.vcxproj.filters:
6306        * WebCore.vcxproj/WebCorePreBuild.cmd:
6307        * WebCore.vcxproj/build-generated-files.pl: Copied from Source/WebCore/WebCore.vcxproj/build-generated-files.sh.
6308        * WebCore.vcxproj/build-generated-files.sh: Removed.
6309        * WebCore.vcxproj/migrate-scripts.pl: Copied from Source/WebCore/WebCore.vcxproj/migrate-scripts.sh.
6310        * WebCore.vcxproj/migrate-scripts.sh: Removed.
6311
63122014-07-09  Anders Carlsson  <andersca@apple.com>
6313
6314        Support transparent WKWebViews
6315        https://bugs.webkit.org/show_bug.cgi?id=134779
6316        <rdar://problem/17351058>
6317
6318        Reviewed by Tim Horton.
6319
6320        Schedule rebuilding the compositing layers if a FrameView's transparency changes.
6321
6322        * page/FrameView.cpp:
6323        (WebCore::FrameView::setTransparent):
6324
63252014-07-09  Javier Fernandez  <jfernandez@igalia.com>
6326        CSS canvas color parsing accepts invalid color identifiers
6327        https://bugs.webkit.org/show_bug.cgi?id=134661
6328
6329        Reviewed by Benjamin Poulain.
6330
6331        Current implementation of the CSSParser::parseSystemColor assumes
6332        that if a valid cssValueKeywordID is got then it has to be a valid
6333        color. Such assumption is wrong and lead to many bugs and layout
6334        test failures.
6335
6336        The parseSystemFunction determines now whether the parsed color is
6337        valid or not.
6338
6339        Addtionally, a new method has been added to share the logic of
6340        determining whether a CSSValueID is a valid primitive values for
6341        colors or not. Generally, we should avoid passing invalid color
6342        identifiers to the theming API.
6343
6344        No new tests, but added additional cases to the
6345        canvas-color-serialization.html, test-setting-canvas-color and
6346        rgb-color-parse test.
6347
6348        * css/CSSParser.cpp:
6349        (WebCore::validPrimitiveValueColor): Added.
6350        (WebCore::parseColorValue):
6351        (WebCore::CSSParser::parseSystemColor):
6352
63532014-06-28  Jer Noble  <jer.noble@apple.com>
6354
6355        [MSE] http/tests/media/media-source/mediasource-remove.html is failing
6356        https://bugs.webkit.org/show_bug.cgi?id=134768
6357
6358        Reviewed by Eric Carlson.
6359
6360        Fix multiple bugs causing mediasource-remove.html to fail:
6361
6362        Separate out setDuration() into setDurationInternal() so that steps which require
6363        us to run the "duration change algorithm" don't bail out if the SoureBuffer is
6364        inside updating().
6365
6366        * Modules/mediasource/MediaSource.cpp:
6367        (WebCore::MediaSource::setDuration):
6368        (WebCore::MediaSource::setDurationInternal):
6369        * Modules/mediasource/MediaSource.h:
6370        * Modules/mediasource/SourceBuffer.cpp:
6371        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):
6372        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
6373
6374        When removing coded frames, do so starting from the first sample in the range in
6375        decode order, so that frames dependant on removed frames are themselves removed. Add
6376        a convenience method in SampleMap findSampleWithPresentationTime(), and rename
6377        findSampleAfterPresentationTime() to findSampleOnOrAfterPresentationTime() to correctly
6378        reflect what the method does, and simplify its implementation by searching the map's keys
6379        directly.
6380
6381        * Modules/mediasource/SampleMap.cpp:
6382        (WebCore::PresentationOrderSampleMap::findSampleWithPresentationTime):
6383        (WebCore::PresentationOrderSampleMap::findSampleOnOrAfterPresentationTime):
6384        (WebCore::DecodeOrderSampleMap::findSyncSampleAfterPresentationTime):
6385        (WebCore::PresentationOrderSampleMap::findSampleAfterPresentationTime): Deleted.
6386        * Modules/mediasource/SampleMap.h:
6387        * Modules/mediasource/SourceBuffer.cpp:
6388        (WebCore::decodeTimeComparator):
6389        (WebCore::SourceBuffer::removeCodedFrames):
6390
6391        Throw the correct exception (INVALID_STATE_ERR) from SourceBuffer::remove().
6392
6393        * Modules/mediasource/SourceBuffer.cpp:
6394        (WebCore::SourceBuffer::remove):
6395
63962014-07-09  Pratik Solanki  <psolanki@apple.com>
6397
6398        Add SharedBuffer::wrapCFDataArray() and use it
6399        https://bugs.webkit.org/show_bug.cgi?id=134733
6400
6401        Reviewed by Antti Koivisto.
6402
6403        No new tests. Should be covered by existing tests.
6404
6405        * platform/SharedBuffer.h:
6406        * platform/cf/SharedBufferCF.cpp:
6407        (WebCore::SharedBuffer::wrapCFDataArray):
6408        (WebCore::SharedBuffer::SharedBuffer):
6409        * platform/network/ResourceHandle.h:
6410        * platform/network/cf/ResourceHandleCFNet.cpp:
6411        (WebCore::ResourceHandle::handleDataArray): Deleted.
6412        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
6413        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveDataArray):
6414        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp:
6415        (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveDataArray):
6416        * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
6417        (-[WebCoreResourceHandleAsDelegate connection:didReceiveDataArray:]):
6418        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
6419        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveDataArray:]):
6420
64212014-07-09  Pratik Solanki  <psolanki@apple.com>
6422
6423        Move resource buffering from SynchronousNetworkLoaderClient to NetworkResourceLoader
6424        https://bugs.webkit.org/show_bug.cgi?id=134732
6425
6426        Reviewed by Darin Adler.
6427
6428        No new tests because no functional changes.
6429
6430        * WebCore.exp.in:
6431
64322014-07-09  Tim Horton  <timothy_horton@apple.com>
6433
6434        Fix the !USE(IOSURFACE) build.
6435
6436        * WebCore.exp.in:
6437
64382014-07-09  Tim Horton  <timothy_horton@apple.com>
6439
6440        Use IOSurface ViewSnapshots everywhere on Mac, remove JPEG encoding path
6441        https://bugs.webkit.org/show_bug.cgi?id=134773
6442
6443        Reviewed by Anders Carlsson.
6444
6445        * WebCore.exp.in:
6446        * platform/graphics/cocoa/IOSurface.h:
6447        * platform/graphics/cocoa/IOSurface.mm:
6448        (IOSurface::createFromImage):
6449        Move make-an-IOSurface-from-a-CGImageRef into WebCore::IOSurface.
6450
64512014-07-09  Enrica Casucci  <enrica@apple.com>
6452
6453        Implement Editor::fontAttributesForSelectionStart() or iOS.
6454        https://bugs.webkit.org/show_bug.cgi?id=134771
6455        <rdar://problem/16167838>
6456
6457        Reviewed by Ryosuke Niwa.
6458
6459        Implement for iOS the equivalent function we have for OS X.
6460
6461        * editing/ios/EditorIOS.mm:
6462        (WebCore::Editor::fontAttributesForSelectionStart):
6463
64642014-07-09  Brent Fulgham  <bfulgham@apple.com>
6465
6466        [Win] Remove use of 'grep' in build steps
6467        https://bugs.webkit.org/show_bug.cgi?id=134770
6468        <rdar://problem/17608783>
6469
6470        Reviewed by Tim Horton.
6471
6472        Replace uses of the grep command in Windows builds with the equivalent
6473        Perl program.
6474
6475        * WebCore.vcxproj/WebCoreGenerated.make:
6476        * WebCore.vcxproj/WebCorePreBuild.cmd:
6477        * platform/graphics/avfoundation/cf/WebCoreAVCFResourceLoader.cpp:
6478        (WebCore::WebCoreAVCFResourceLoader::notifyFinished):
6479
64802014-07-09  Alex Christensen  <achristensen@webkit.org>
6481
6482        Added css jit profiler, disabled by default.
6483        https://bugs.webkit.org/show_bug.cgi?id=134695
6484
6485        Reviewed by Benjamin Poulain.
6486
6487        * css/ElementRuleCollector.cpp:
6488        (WebCore::ElementRuleCollector::ruleMatches):
6489        Tell the RuleData when its compiled selector is used.
6490        * css/RuleSet.cpp:
6491        (WebCore::RuleData::RuleData):
6492        Initialize the compiled selector use count to 0.
6493        * css/RuleSet.h:
6494        (WebCore::RuleData::~RuleData):
6495        (WebCore::RuleData::compiledSelectorUsed):
6496        Count and log the number of times a compiled selector is used.
6497        * cssjit/SelectorCompiler.h:
6498        Added option for CSS_SELECTOR_JIT_PROFILING set to 0 by default.
6499        * dom/SelectorQuery.cpp:
6500        (WebCore::SelectorDataList::executeCompiledSimpleSelectorChecker):
6501        (WebCore::SelectorDataList::execute):
6502        Tell the SelectorData when its compiled selector is used.
6503        * dom/SelectorQuery.h:
6504        (WebCore::SelectorDataList::SelectorData::SelectorData):
6505        (WebCore::SelectorDataList::SelectorData::~SelectorData):
6506        (WebCore::SelectorDataList::SelectorData::compiledSelectorUsed):
6507        Count and log the number of times a compiled selector is used.
6508
65092014-07-09  Eric Carlson  <eric.carlson@apple.com>
6510
6511        [iOS] caption size is sometimes incorrect in fullscreen
6512        https://bugs.webkit.org/show_bug.cgi?id=134740
6513
6514        Reviewed by Jer Noble.
6515
6516        Captions on iOS are displayed in fullscreen with a TextTrackRepresentation object. Because
6517        the fullscreen video presentation is controlled by code in the UI process running on the
6518        UI thread, WebCore is notified of changes to fullscreen state asynchronously. This resulted
6519        in the TextTrackRepresentation object being created and/or destroyed too late some of the 
6520        time, which caused us to sometimes display captions incorrectly. Fix this by setting up and
6521        tearing down the TextTrackRepresentation object when WebCore's 'webkitfullscreenchange'
6522        event fires.
6523
6524        * Modules/mediacontrols/MediaControlsHost.cpp:
6525        (WebCore::MediaControlsHost::enteredFullscreen): Notify text track container.
6526        (WebCore::MediaControlsHost::exitedFullscreen): Ditto.
6527        * Modules/mediacontrols/MediaControlsHost.h:
6528        * Modules/mediacontrols/MediaControlsHost.idl:
6529
6530        * Modules/mediacontrols/mediaControlsApple.js:
6531        (Controller.prototype.handleFullscreenChange): Notify host of fullscreen change.
6532
6533        * html/HTMLMediaElement.cpp:
6534        (WebCore::HTMLMediaElement::requiresTextTrackRepresentation): Only return true when in
6535            fullscreen.
6536        (WebCore::HTMLMediaElement::setVideoFullscreenLayer): Call updateTextTrackDisplay.
6537
6538        * html/shadow/MediaControlElements.cpp:
6539        (WebCore::MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement): Initialize
6540            m_updateTextTrackRepresentationStyle to false.
6541        (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Move logic for creating
6542            TextTrackRepresentation to updateTextTrackRepresentation.
6543        (WebCore::MediaControlTextTrackContainerElement::updateActiveCuesFontSize): New, split out of updateTimerFired.
6544        (WebCore::MediaControlTextTrackContainerElement::updateTimerFired): Move code to force immediate
6545            font size change to updateActiveCuesFontSize.
6546        (WebCore::MediaControlTextTrackContainerElement::updateTextTrackRepresentation): New, update
6547            text track representation, creating first if necessary.
6548        (WebCore::MediaControlTextTrackContainerElement::clearTextTrackRepresentation): Add an early
6549            return if we don't have a text track representation.
6550        (WebCore::MediaControlTextTrackContainerElement::updateStyleForTextTrackRepresentation): Early
6551            return if there is nothing to be done.
6552        (WebCore::MediaControlTextTrackContainerElement::enteredFullscreen): Force a caption update
6553            if there are visible captions.
6554        (WebCore::MediaControlTextTrackContainerElement::updateSizes): Set m_updateTextTrackRepresentationStyle
6555            to true.
6556        (WebCore::MediaControlTextTrackContainerElement::textTrackRepresentationBoundsChanged):  Force a 
6557            caption update if there are visible captions.
6558        * html/shadow/MediaControlElements.h:
6559
65602014-07-09  Jer Noble  <jer.noble@apple.com>
6561
6562        [MSE] http/tests/media/media-source/mediasource-endofstream-invaliderror.html is failing.
6563        https://bugs.webkit.org/show_bug.cgi?id=134413
6564
6565        Reviewed by Eric Carlson.
6566
6567        Update MediaSource.endOfStream() to take an optional enum instead of an optional String.
6568
6569        * Modules/mediasource/MediaSource.cpp:
6570        (WebCore::MediaSource::endOfStream):
6571        * Modules/mediasource/MediaSource.h:
6572        * Modules/mediasource/MediaSource.idl:
6573
65742014-07-08  Brady Eidson  <beidson@apple.com>
6575
6576        DOMWindows should register themselves with the GamepadManager when they have event listeners
6577        https://bugs.webkit.org/show_bug.cgi?id=134669
6578
6579        Reviewed by Dean Jackson.
6580
6581        No new tests (No effect in a currently tested config)
6582
6583        By having DOMWindows register with the GamepadManager when they have/don’t have gamepad event
6584        listeners, we accomplish two things:
6585        1 - It’s simple for GamepadManager to dispatch gamepad events directly to the DOMWindows interested.
6586        2 - We know when to start monitoring for gamepad connections.
6587
6588        * Modules/gamepad/GamepadManager.cpp:
6589        (WebCore::GamepadManager::GamepadManager):
6590        (WebCore::GamepadManager::registerNavigator):
6591        (WebCore::GamepadManager::unregisterNavigator):
6592        (WebCore::GamepadManager::registerDOMWindow):
6593        (WebCore::GamepadManager::unregisterDOMWindow):
6594        (WebCore::GamepadManager::maybeStartMonitoringGamepads): Start monitoring gamepads if there are any
6595          registered DOMWindows or NavigatorGamepads, and we aren’t already monitoring them.
6596        (WebCore::GamepadManager::maybeStopMonitoringGamepads): Stop monitoring gamepads if there aren’t any
6597          registered DOMWindows or NavigatorGameads, and we have been monitoring them before now.
6598        * Modules/gamepad/GamepadManager.h:
6599
6600        * dom/EventNames.h:
6601        (WebCore::EventNames::isGamepadEventType):
6602
6603        * page/DOMWindow.cpp:
6604        (WebCore::DOMWindow::DOMWindow):
6605        (WebCore::DOMWindow::~DOMWindow): If registered for gamepad events, unregister now.
6606        (WebCore::DOMWindow::incrementGamepadEventListenerCount): If this is the first gamepad event
6607          listener, register with the GamepadManager now.
6608        (WebCore::DOMWindow::decrementGamepadEventListenerCount): If this was the last gamepad event
6609          listener, unregister from the GamepadManager now.
6610        (WebCore::DOMWindow::addEventListener):
6611        (WebCore::DOMWindow::removeEventListener):
6612        * page/DOMWindow.h:
6613
66142014-07-08  Sun-woo Nam  <sunny.nam@samsung.com>
6615
6616        [EFL] Fix the build break when ENABLE_ENCRYPTED_MEDIA_V2 is turned on.
6617        https://bugs.webkit.org/show_bug.cgi?id=134750
6618
6619        Reviewed by Gyuyoung Kim.
6620
6621        When turning ENABLE_ENCRYPTED_MEDIA_V2 on, build break occurs.
6622        Some source files need to be included in CMakeLists.txt file for build.
6623        And wrap the included header file which is built only on mac and wince.
6624
6625        * CMakeLists.txt:
6626        * Modules/encryptedmedia/CDMPrivateMediaPlayer.cpp:
6627
66282014-07-08  Eric Carlson  <eric.carlson@apple.com>
6629
6630        [iOS] user caption preferences not applied
6631        https://bugs.webkit.org/show_bug.cgi?id=134599
6632
6633        Reviewed by Sam Weinig.
6634
6635        * page/CaptionUserPreferences.cpp:
6636        (WebCore::CaptionUserPreferences::updateCaptionStyleSheetOveride): All Pages in a PageGroup
6637        do not necessarily use the same PageUserContentController, so apply and remove caption user
6638        the style sheet directly to each page rather than to the page group.
6639
66402014-07-08  Commit Queue  <commit-queue@webkit.org>
6641
6642        Unreviewed, rolling out r170894.
6643        https://bugs.webkit.org/show_bug.cgi?id=134749
6644
6645        "It broke the build on mountainlion release 32bit" (Requested
6646        by mmirman on #webkit).
6647
6648        Reverted changeset:
6649
6650        "Added css jit profiler, disabled by default."
6651        https://bugs.webkit.org/show_bug.cgi?id=134695
6652        http://trac.webkit.org/changeset/170894
6653
66542014-07-08  Jeremy Jones  <jeremyj@apple.com>
6655
6656        WebVideoFullscreenInterfaceAVKit should lazily create m_playerController.
6657        https://bugs.webkit.org/show_bug.cgi?id=134706
6658
6659        Reviewed by Simon Fraser.
6660
6661        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
6662        (WebVideoFullscreenInterfaceAVKit::setWebVideoFullscreenModel):
6663        Don't set the delegate if m_playerController isn't created.
6664
66652014-07-08  Bem Jones-Bey  <bjonesbe@adobe.com>
6666
6667        Ensure we compute the height of replaced elements to 'auto' when appropriate.
6668        https://bugs.webkit.org/show_bug.cgi?id=134700
6669
6670        Reviewed by David Hyatt.
6671
6672        This fixes two issues:
6673
6674        1) If a replaced element has a percentage height specified then its
6675        height should compute to 'auto' when its containing block does not
6676        have a height 'specified explicitly'. We were taking this to mean when
6677        its containing block's specified height value is 'auto' - in fact it
6678        means when the containing block's computed height is auto.
6679
6680        2) Top and bottom on the containing block should only affect the
6681        height of the block if that block has absolute or fixed position.
6682
6683        This brings us into line with IE, Firefox, and Chrome.
6684
6685        This is a port of Blink patches by Rob Hogan and David Vest.
6686
6687        Tests: css2.1/20110323/height-percentage-005.htm
6688               fast/css/replaced-element-ignore-top-bottom.html
6689
6690        * rendering/RenderBoxModelObject.cpp:
6691        (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight):
6692
66932014-07-08  Alex Christensen  <achristensen@webkit.org>
6694
6695        Added css jit profiler, disabled by default.
6696        https://bugs.webkit.org/show_bug.cgi?id=134695
6697
6698        Reviewed by Benjamin Poulain.
6699
6700        * css/ElementRuleCollector.cpp:
6701        (WebCore::ElementRuleCollector::ruleMatches):
6702        Tell the RuleData when its compiled selector is used.
6703        * css/RuleSet.cpp:
6704        (WebCore::RuleData::RuleData):
6705        Initialize the compiled selector use count to 0.
6706        * css/RuleSet.h:
6707        (WebCore::RuleData::~RuleData):
6708        (WebCore::RuleData::compiledSelectorUsed):
6709        Count and log the number of times a compiled selector is used.
6710        * cssjit/SelectorCompiler.h:
6711        Added option for CSS_SELECTOR_JIT_PROFILING set to 0 by default.
6712        * dom/SelectorQuery.cpp:
6713        (WebCore::SelectorDataList::executeCompiledSimpleSelectorChecker):
6714        (WebCore::SelectorDataList::execute):
6715        Tell the SelectorData when its compiled selector is used.
6716        * dom/SelectorQuery.h:
6717        (WebCore::SelectorDataList::SelectorData::SelectorData):
6718        (WebCore::SelectorDataList::SelectorData::~SelectorData):
6719        (WebCore::SelectorDataList::SelectorData::compiledSelectorUsed):
6720        Count and log the number of times a compiled selector is used.
6721
67222014-07-08  Carlos Garcia Campos  <cgarcia@igalia.com>
6723
6724        Unreviewed. Fix GObject DOM bindings API breaks test after r170700.
6725
6726        Add missing WebKitDOMXPathNSResolver.symbols that I forgot to add
6727        in r170700.
6728
6729        * bindings/gobject/WebKitDOMXPathNSResolver.symbols: Added.
6730
67312014-07-07  Pratik Solanki  <psolanki@apple.com>
6732
6733        Unreviewed. iOS build fix after r170871.
6734
6735        * rendering/RenderThemeIOS.mm:
6736        (WebCore::adjustInputElementButtonStyle):
6737
67382014-07-07  Zalan Bujtas  <zalan@apple.com>
6739
6740        Subpixel rendering: icloud.com password arrow has clipped circle at some window sizes.
6741        https://bugs.webkit.org/show_bug.cgi?id=134710
6742        <rdar://problem/17545291>
6743
6744        Reviewed by Simon Fraser.
6745
6746        Transparent layer clipping needs device pixel snapping.
6747
6748        Test: fast/layers/wrong-clipping-semi-transparent-layer-on-subpixel-position.html
6749
6750        * rendering/RenderLayer.cpp:
6751        (WebCore::RenderLayer::beginTransparencyLayers):
6752
67532014-07-07  Benjamin Poulain  <benjamin@webkit.org>
6754
6755        LinkBuffer should not keep a reference to the MacroAssembler
6756        https://bugs.webkit.org/show_bug.cgi?id=134668
6757
6758        Reviewed by Geoffrey Garen.
6759
6760        * cssjit/SelectorCompiler.cpp:
6761        (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
6762
67632014-07-07  Zalan Bujtas  <zalan@apple.com>
6764
6765        Subpixel rendering: Inline box decoration rounds to integral.
6766        https://bugs.webkit.org/show_bug.cgi?id=134523
6767        <rdar://problem/17530298>
6768
6769        Reviewed by Darin Adler.
6770
6771        This patch removes 2 integral roundings from InlineFlowBox:
6772        1. Border and padding sizes are implicitly integral truncated by the 'int' return type
6773           of borderLogicalLeft/Right()/paddingLogicalLeft/Right(). It results in losing
6774           fractional border/padding values.
6775        2. Painting rectangle is explicitly rounded which pushes border and
6776           other decoration elements to odd device pixel positions on retina displays.
6777        These values get pixel snapped right before calling in to GraphicsContext::*.
6778
6779        Test: fast/inline/hidpi-inline-text-decoration-with-subpixel-value.html
6780
6781        * rendering/InlineBox.h:
6782        (WebCore::InlineBox::frameRect):
6783        * rendering/InlineFlowBox.cpp:
6784        (WebCore::InlineFlowBox::nodeAtPoint):
6785        (WebCore::InlineFlowBox::paintBoxDecorations):
6786        (WebCore::InlineFlowBox::paintMask):
6787        (WebCore::InlineFlowBox::roundedFrameRect): Deleted.
6788        * rendering/InlineFlowBox.h:
6789        (WebCore::InlineFlowBox::borderLogicalLeft):
6790        (WebCore::InlineFlowBox::borderLogicalRight):
6791        (WebCore::InlineFlowBox::paddingLogicalLeft):
6792        (WebCore::InlineFlowBox::paddingLogicalRight):
6793
67942014-07-07  Zalan Bujtas  <zalan@apple.com>
6795
6796        Pass RenderLayer reference instead of pointer to RenderLayer::paintingExtent().
6797        https://bugs.webkit.org/show_bug.cgi?id=134714
6798
6799        Reviewed by Simon Fraser.
6800
6801        No change in functionality. 
6802
6803        * rendering/RenderLayer.cpp: * -> &
6804        (WebCore::expandClipRectForRegionAndReflection):
6805        (WebCore::expandClipRectForDescendantsAndReflection):
6806        (WebCore::transparencyClipBox):
6807        (WebCore::paintingExtent):
6808        (WebCore::RenderLayer::beginTransparencyLayers):
6809        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
6810        (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
6811        (WebCore::RenderLayer::paintingExtent): Deleted.
6812        * rendering/RenderLayer.h:
6813
68142014-07-07  Myles C. Maxfield  <mmaxfield@apple.com>
6815
6816        Remove misleadingly-named Font::isSVGFont()
6817        https://bugs.webkit.org/show_bug.cgi?id=134697
6818
6819        Reviewed by Dean Jackson.
6820
6821        Being a SVG font is a property of the FontData object, not
6822        the Font object. Providing an isSVGFont() function on the
6823        Font class will likely lead to incorrect code and non-obvious
6824        bugs.
6825
6826        No new tests because there is no behavior change.
6827
6828        * platform/graphics/Font.h:
6829        (WebCore::Font::isSVGFont): Deleted.
6830        * platform/graphics/mac/FontMac.mm:
6831        (WebCore::Font::primaryFontDataIsSystemFont):
6832        * rendering/InlineTextBox.cpp:
6833        (WebCore::InlineTextBox::constructTextRun):
6834        * rendering/RenderBlock.cpp:
6835        (WebCore::constructTextRunInternal):
6836        * rendering/SimpleLineLayout.cpp:
6837        (WebCore::SimpleLineLayout::canUseFor):
6838        * rendering/svg/SVGInlineTextBox.cpp:
6839        (WebCore::SVGInlineTextBox::constructTextRun):
6840        * rendering/svg/SVGTextMetrics.cpp:
6841        (WebCore::SVGTextMetrics::constructTextRun):
6842        (WebCore::SVGTextMetrics::SVGTextMetrics):
6843
68442014-07-07  Brady Eidson  <beidson@apple.com>
6845
6846        Move Gamepad index down into PlatformGamepad.
6847        https://bugs.webkit.org/show_bug.cgi?id=134670
6848
6849        Reviewed by Darin Adler.
6850
6851        PlatformGamepads always have an inherent index anyways.
6852        This will make things easier in all upcoming work.
6853
6854        * Modules/gamepad/Gamepad.cpp:
6855        (WebCore::Gamepad::Gamepad):
6856        * Modules/gamepad/Gamepad.h:
6857
6858        * Modules/gamepad/GamepadManager.cpp:
6859        (WebCore::GamepadManager::platformGamepadConnected):
6860        (WebCore::GamepadManager::platformGamepadDisconnected):
6861        (WebCore::GamepadManager::makeGamepadsVisibileToBlindNavigators):
6862        * Modules/gamepad/GamepadManager.h:
6863
6864        * Modules/gamepad/NavigatorGamepad.cpp:
6865        (WebCore::NavigatorGamepad::gamepadsBecameVisible):
6866        (WebCore::NavigatorGamepad::gamepadConnected):
6867        (WebCore::NavigatorGamepad::gamepadDisconnected):
6868        * Modules/gamepad/NavigatorGamepad.h:
6869
6870        * platform/GamepadProviderClient.h:
6871
6872        * platform/PlatformGamepad.h:
6873        (WebCore::PlatformGamepad::index):
6874        (WebCore::PlatformGamepad::PlatformGamepad):
6875
6876        * platform/mac/HIDGamepad.cpp:
6877        (WebCore::HIDGamepad::HIDGamepad):
6878        * platform/mac/HIDGamepad.h:
6879
6880        * platform/mac/HIDGamepadProvider.cpp:
6881        (WebCore::HIDGamepadProvider::deviceAdded):
6882        (WebCore::HIDGamepadProvider::deviceRemoved):
6883        (WebCore::HIDGamepadProvider::removeGamepadForDevice):
6884        * platform/mac/HIDGamepadProvider.h:
6885
68862014-07-07  Simon Fraser  <simon.fraser@apple.com>
6887
6888        [UI-side compositing] Support reflections on custom layers like video
6889        https://bugs.webkit.org/show_bug.cgi?id=134701
6890
6891        Reviewed by Tim Horton.
6892
6893        Add a LayerTypeWebGLLayer layer type, and support casting to PlatformCALayerRemoteCustom.
6894
6895        * WebCore.exp.in: Export PlatformCALayerMac::layerTypeForPlatformLayer(CALayer*), and sort.
6896        * platform/graphics/ca/PlatformCALayer.h:
6897        (WebCore::PlatformCALayer::isPlatformCALayerRemoteCustom):
6898        * platform/graphics/ca/mac/PlatformCALayerMac.h:
6899        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
6900        (PlatformCALayerMac::layerTypeForPlatformLayer):
6901        (PlatformCALayerMac::PlatformCALayerMac):
6902        (PlatformCALayerMac::commonInit):
6903
69042014-07-07  Simon Fraser  <simon.fraser@apple.com>
6905
6906        [UI-side compositing] Crash when starting a filter transition on a reflected layer
6907        https://bugs.webkit.org/show_bug.cgi?id=134694
6908
6909        Reviewed by Tim Horton.
6910
6911        Don't call the owner if we failed to find the animation key (which actually
6912        isn't used by PlatformCALayerMac anyway).
6913
6914        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
6915        (-[WebAnimationDelegate animationDidStart:]):
6916
69172014-07-07  Alex Christensen  <achristensen@webkit.org>
6918
6919        [iOS WebGL] Fix crash with too many nested glsl functions.
6920        https://bugs.webkit.org/show_bug.cgi?id=134683
6921        <rdar://problem/17541529>
6922
6923        Reviewed by Geoffrey Garen.
6924
6925        This fixes the Khronos WebGL 1.0.3 test nested-functions-should-not-crash.html.
6926
6927        * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
6928        (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE):
6929        Add SH_LIMIT_CALL_STACK_DEPTH to extraCompileOptions.
6930
69312014-07-07  Ion Rosca  <rosca@adobe.com>
6932
6933        [CSS Blending]The background images set on the root element will blend on an initial white backdrop.
6934        https://bugs.webkit.org/show_bug.cgi?id=134342
6935
6936        Reviewed by Dean Jackson.
6937
6938        Tests: css3/blending/background-blend-mode-body-image.html
6939               css3/blending/background-blend-mode-body-transparent-color-and-image.html
6940               css3/blending/background-blend-mode-body-transparent-image.html
6941
6942        * rendering/RenderBox.cpp:
6943        (WebCore::RenderBox::paintFillLayers):
6944        If the background layers have blend modes, we paint the base background color first,
6945        before starting a new transparency layer. After creating the transparency layer,
6946        the base background will be skipped, and the background layers will blend on top of
6947        a transparent backdrop.
6948        (WebCore::RenderBox::paintFillLayer):
6949        * rendering/RenderBox.h:
6950        * rendering/RenderBoxModelObject.cpp:
6951        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
6952        This method is able to paint only the base background color (BaseBackgroundColorOnly), 
6953        skipping the background-color and background-images. This option is available only
6954        on bottom layer of the root renderer and only if the background color is not opaque,
6955        otherwise the method will return early.
6956        Another option is to paint the root background without using the base background color
6957        (BaseBackgroundColorSkip).
6958        * rendering/RenderBoxModelObject.h:
6959        Adding the BaseBackgroundColorUsage enum.
6960
69612014-07-06  Yoav Weiss  <yoav@yoav.ws>
6962
6963        Turn on img@sizes compile flag
6964        https://bugs.webkit.org/show_bug.cgi?id=134634
6965
6966        Reviewed by Benjamin Poulain.
6967
6968        * Configurations/FeatureDefines.xcconfig: Moved compile flag to alphabetical order.
6969
69702014-07-06  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
6971
6972        Generate isMathMLFoo() toMathMLFoo() by using NODE_TYPE_CASTS macro and generateTypeHelpers
6973        https://bugs.webkit.org/show_bug.cgi?id=134647
6974
6975        Reviewed by Andreas Kling.
6976
6977        Use type cast macro and generation tag for isFoo() and toFoo() in some MathML classes.
6978
6979        No new tests, no behavior change.
6980
6981        * mathml/MathMLElement.h: Place MathMLElementTypeHelpers.h to the bottom of the
6982        file so that functions from that file can use the Element|Node classes and other things defined in this file.
6983        * mathml/MathMLMencloseElement.h:
6984        (WebCore::toMathMLMencloseElement): Deleted.
6985        * mathml/mathtags.in:
6986
69872014-07-06  Yusuke Suzuki  <utatane.tea@gmail.com>
6988
6989        CSS JIT: Ensure resolvingMode size is 1 byte
6990        https://bugs.webkit.org/show_bug.cgi?id=134662
6991
6992        Reviewed by Benjamin Poulain.
6993
6994        Since selector compiler uses MacroAssembler::branch8 for SelectorChecker::Mode,
6995        we should ensure sizeof(SelectorChecker::Mode) == 1.
6996        Old implementation works only in little endianness environments.
6997
6998        * css/ElementRuleCollector.cpp:
6999        (WebCore::ElementRuleCollector::matchedResult):
7000        (WebCore::ElementRuleCollector::matchedRuleList):
7001        (WebCore::ElementRuleCollector::collectMatchingRules):
7002        (WebCore::ElementRuleCollector::sortAndTransferMatchedRules):
7003        (WebCore::ElementRuleCollector::hasAnyMatchingRules):
7004        * css/ElementRuleCollector.h:
7005        (WebCore::ElementRuleCollector::ElementRuleCollector):
7006        * css/SelectorChecker.cpp:
7007        (WebCore::SelectorChecker::match):
7008        (WebCore::SelectorChecker::matchRecursively):
7009        (WebCore::SelectorChecker::checkOne):
7010        * css/SelectorChecker.h:
7011        * css/StyleInvalidationAnalysis.cpp:
7012        (WebCore::invalidateStyleRecursively):
7013        * css/StyleResolver.cpp:
7014        (WebCore::StyleResolver::pseudoStyleRulesForElement):
7015        * css/StyleResolver.h:
7016        (WebCore::checkRegionSelector):
7017        * cssjit/SelectorCompiler.cpp:
7018        (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNotResolvingStyle):
7019        (WebCore::SelectorCompiler::elementIsActiveForStyleResolution):
7020        (WebCore::SelectorCompiler::elementIsHoveredForStyleResolution):
7021        * dom/SelectorQuery.cpp:
7022        (WebCore::SelectorDataList::selectorMatches):
7023
70242014-07-06  Antti Koivisto  <antti@apple.com>
7025
7026        Don't throttle layer flushes when the main resource is a GIF
7027        https://bugs.webkit.org/show_bug.cgi?id=134650
7028        <rdar://problem/17490712>
7029
7030        Reviewed by Simon Fraser.
7031        
7032        Avoid throttling big image animations.
7033
7034        * page/FrameView.cpp:
7035        (WebCore::determineLayerFlushThrottleState):
7036        
7037            Disable for image documents.
7038
7039        (WebCore::FrameView::disableLayerFlushThrottlingTemporarilyForInteraction):
7040        (WebCore::FrameView::updateLayerFlushThrottling):
7041        
7042            Refactor a bit.
7043
7044        * page/LayerFlushThrottleState.h:
7045        
7046            Rename the flag.
7047
70482014-07-06  Andreas Kling  <akling@apple.com>
7049
7050        Inline NodeListsNodeData helpers more aggressively.
7051        <https://webkit.org/b/134654>
7052
7053        Get rid of call overhead costs when retrieving NodeLists and
7054        HTMLCollections from Document. These functions have very few clients,
7055        so there's no real reason to keep them out of line.
7056
7057        Reviewed by Antti Koivisto.
7058
7059        * dom/NodeRareData.h:
7060        (WebCore::NodeListsNodeData::addCacheWithAtomicName):
7061        (WebCore::NodeListsNodeData::addCacheWithName):
7062
70632014-07-06  Andreas Kling  <akling@apple.com>
7064
7065        Inline Node's rare data getters.
7066        <https://webkit.org/b/134652>
7067
7068        There was a fair bit of overhead when calling Node::ensureRareData()
7069        from Document's collection getters. This patch inlines the case where
7070        we've already materialized the rare data.
7071
7072        Reviewed by Antti Koivisto.
7073
7074        * dom/Node.cpp:
7075        (WebCore::Node::materializeRareData):
7076        (WebCore::Node::rareData): Deleted.
7077        (WebCore::Node::ensureRareData): Deleted.
7078        * dom/Node.h:
7079        * dom/NodeRareData.h:
7080        (WebCore::Node::rareData):
7081        (WebCore::Node::ensureRareData):
7082
70832014-07-05  Dean Jackson  <dino@apple.com>
7084
7085        [iOS] MediaDocument should set a viewport
7086        https://bugs.webkit.org/show_bug.cgi?id=134658
7087        <rdar://problem/17552339>
7088
7089        Reviewed by Zalan Bujtas.
7090
7091        A MediaDocument should fill the viewport, so set its
7092        initial-scale to 1 and make it non-zoomable.
7093
7094        * html/MediaDocument.cpp:
7095        (WebCore::MediaDocumentParser::createDocumentStructure): Create
7096        a <head> element and a <meta> element with a 1:1 viewport.
7097
70982014-07-05  Commit Queue  <commit-queue@webkit.org>
7099
7100        Unreviewed, rolling out r170825.
7101        https://bugs.webkit.org/show_bug.cgi?id=134653
7102
7103        broke debug builds (Requested by kling on #webkit).
7104
7105        Reverted changeset:
7106
7107        "Generate isMathMLFoo() toMathMLFoo() by using NODE_TYPE_CASTS
7108        macro and generateTypeHelpers"
7109        https://bugs.webkit.org/show_bug.cgi?id=134647
7110        http://trac.webkit.org/changeset/170825
7111
71122014-07-05  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
7113
7114        Generate isMathMLFoo() toMathMLFoo() by using NODE_TYPE_CASTS macro and generateTypeHelpers
7115        https://bugs.webkit.org/show_bug.cgi?id=134647
7116
7117        Reviewed by Andreas Kling.
7118
7119        Use type cast macro and generation tag for isFoo() and toFoo() in some MathML classes.
7120
7121        No new tests, no behavior change.
7122
7123        * mathml/MathMLElement.h: Place MathMLElementTypeHelpers.h to the bottom of the
7124        file so that functions from that file can use the Element|Node classes and other things defined in this file.
7125        (WebCore::isMathMLElement): Deleted.
7126        * mathml/MathMLMencloseElement.h:
7127        (WebCore::toMathMLMencloseElement): Deleted.
7128        * mathml/mathtags.in:
7129
71302014-07-04  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
7131
7132        [EFL] Support Geolocation
7133        https://bugs.webkit.org/show_bug.cgi?id=134439
7134
7135        Reviewed by Antonio Gomes.
7136
7137        Add geoclue files in order to enable geolocation for EFL port.
7138
7139        * PlatformEfl.cmake:
7140
71412014-07-04  Benjamin Poulain  <benjamin@webkit.org>
7142
7143        CSS JIT: compile :in-range and :out-of-range
7144        https://bugs.webkit.org/show_bug.cgi?id=134639
7145
7146        Reviewed by Andreas Kling.
7147
7148        The pseudo class :in-range and :out-of-range are trivial non-inlined selectors.
7149
7150        * css/SelectorChecker.cpp:
7151        (WebCore::SelectorChecker::checkOne):
7152        * css/SelectorCheckerTestFunctions.h:
7153        (WebCore::isInRange):
7154        (WebCore::isOutOfRange):
7155        * cssjit/SelectorCompiler.cpp:
7156        (WebCore::SelectorCompiler::addPseudoClassType):
7157
71582014-07-04  Andreas Kling  <akling@apple.com>
7159
7160        Fast path for jsStringWithCache() when asked for the same string repeatedly.
7161        <https://webkit.org/b/134635>
7162
7163        Reviewed by Darin Adler.
7164
7165        * WebCore.exp.in:
7166        * bindings/js/JSDOMBinding.cpp:
7167        (WebCore::jsStringWithCache): Deleted.
7168        * bindings/js/JSDOMBinding.h:
7169        (WebCore::JSValueTraits<String>::arrayJSValue):
7170        (WebCore::jsStringWithCache): Deleted.
7171        * bridge/c/c_utility.cpp:
7172        (JSC::Bindings::convertNPVariantToValue):
7173        * loader/cache/CachedResourceHandle.h:
7174
71752014-07-04  Zalan Bujtas  <zalan@apple.com>
7176
7177        Subpixel rendering: ebay.com rotating billboard on the main page has cut off buttons.
7178        https://bugs.webkit.org/show_bug.cgi?id=134636
7179        <rdar://problem/17529112>
7180
7181        Reviewed by Darin Adler.
7182
7183        Missing pixel snapping when clipping the transparency layer for BackgroundBleedUseTransparencyLayer.
7184        Clipping needs to take the same snapping strategy as the rest of the painting code.
7185
7186        Test: fast/borders/border-radius-on-subpixel-position-non-hidpi.html
7187
7188        * rendering/RenderBox.cpp:
7189        (WebCore::RenderBox::paintBoxDecorations):
7190
71912014-05-10  Andreas Kling  <akling@apple.com>
7192
7193        QualifiedName should use RefPtr<QualifiedNameImpl> internally.
7194        <https://webkit.org/b/132796>
7195
7196        We were not inlining ~QualifiedName() and it was showing up in some
7197        profiles (over 1% on dom-attr.html.)
7198
7199        This patch modernizes QualifiedName a bit by using RefPtr to store
7200        the QualifiedNameImpl instead of doing manual ref() and deref()
7201        in out-of-line functions.
7202
7203        Reviewed by Darin Adler.
7204
7205        * WebCore.exp.in:
7206        * dom/QualifiedName.cpp:
7207        (WebCore::QNameComponentsTranslator::translate):
7208        (WebCore::QualifiedName::QualifiedName):
7209        (WebCore::QualifiedName::~QualifiedName): Deleted.
7210        (WebCore::QualifiedName::deref): Deleted.
7211        * dom/QualifiedName.h:
7212        (WebCore::QualifiedName::QualifiedNameImpl::create):
7213        (WebCore::QualifiedName::QualifiedName):
7214        (WebCore::QualifiedName::isHashTableDeletedValue):
7215        (WebCore::QualifiedName::~QualifiedName):
7216        (WebCore::QualifiedName::operator=):
7217        (WebCore::QualifiedName::impl):
7218        (WebCore::QualifiedName::ref): Deleted.
7219
72202014-07-04  Dean Jackson  <dino@apple.com>
7221
7222        [iOS] [Media] Prevent page zoom if it started in the video element
7223        https://bugs.webkit.org/show_bug.cgi?id=134640
7224        <rdar://problem/16630794>
7225
7226        Reviewed by Sam Weinig.
7227
7228        In r170572 I attempted to prevent the page zoom from happening
7229        when the user was attempting to fullscreen the video. That fix was
7230        not complete, because it relied on the touchstart event being
7231        sent before a gesture event. It turns out this doesn't always happen,
7232        so we need to apply the same check in the gesture event - if the
7233        gesture began with two fingers on the media, don't do a page zoom.
7234        The exception is zooming out, if you've managed to make the video
7235        cover the entire screen (also, the pinch-out-of-fullscreen gesture
7236        does not get handled by WebKit).
7237
7238        * Modules/mediacontrols/mediaControlsiOS.js:
7239        (ControllerIOS.prototype.handleBaseGestureChange): Add a check to
7240        make sure our pinch didn't start in the video element.
7241
72422014-07-04  Hunseop Jeong  <hs85.jeong@samsung.com>
7243
7244        [CoordinatedGraphics] Use the C++11 syntax to clean-up for loops 
7245        https://bugs.webkit.org/show_bug.cgi?id=134594
7246
7247        Reviewed by Darin Adler.
7248
7249        Convert a couple of loops to range-based for 
7250
7251        No change in functionality, no new tests.
7252
7253        * platform/graphics/TiledBackingStore.cpp:
7254        (WebCore::TiledBackingStore::updateTileBuffers):
7255        (WebCore::TiledBackingStore::resizeEdgeTiles):
7256        (WebCore::TiledBackingStore::setKeepRect):
7257        * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
7258        (WebCore::CompositingCoordinator::~CompositingCoordinator):
7259        (WebCore::CompositingCoordinator::flushPendingImageBackingChanges):
7260        (WebCore::CompositingCoordinator::setVisibleContentsRect):
7261        (WebCore::CompositingCoordinator::purgeBackingStores):
7262        * platform/graphics/texmap/coordinated/CoordinatedBackingStore.cpp:
7263        (WebCore::CoordinatedBackingStore::removeAllTiles):
7264        (WebCore::CoordinatedBackingStore::paintToTextureMapper):
7265        (WebCore::CoordinatedBackingStore::drawBorder):
7266        (WebCore::CoordinatedBackingStore::drawRepaintCounter):
7267        (WebCore::CoordinatedBackingStore::commitTileOperations):
7268        * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
7269        (WebCore::CoordinatedGraphicsScene::adjustPositionForFixedLayers):
7270        (WebCore::CoordinatedGraphicsScene::commitPendingBackingStoreOperations):
7271
72722014-07-04  Andreas Kling  <akling@apple.com>
7273
7274        CTTE: ScriptElement always has a HTTPScriptElement or SVGScriptElement.
7275        <https://webkit.org/b/134637>
7276
7277        Have ScriptElement store the pointer to the more specific subclass
7278        element as a reference. Also made the constructor protected since
7279        nobody should instantiate ScriptElement directly.
7280
7281        Reviewed by Antti Koivisto.
7282
7283        * dom/ScriptElement.cpp:
7284        (WebCore::ScriptElement::ScriptElement):
7285        (WebCore::ScriptElement::childrenChanged):
7286        (WebCore::ScriptElement::dispatchErrorEvent):
7287        (WebCore::ScriptElement::prepareScript):
7288        (WebCore::ScriptElement::requestScript):
7289        (WebCore::ScriptElement::executeScript):
7290        (WebCore::ScriptElement::notifyFinished):
7291        (WebCore::ScriptElement::ignoresLoadRequest):
7292        (WebCore::ScriptElement::scriptContent):
7293        * dom/ScriptElement.h:
7294        (WebCore::ScriptElement::element):
7295        * dom/ScriptRunner.cpp:
7296        (WebCore::ScriptRunner::queueScriptForExecution):
7297        * html/HTMLScriptElement.cpp:
7298        (WebCore::HTMLScriptElement::HTMLScriptElement):
7299        * svg/SVGScriptElement.cpp:
7300        (WebCore::SVGScriptElement::SVGScriptElement):
7301
73022014-07-04  Julien Quint  <pom@graougraou.com>
7303
7304        input type=range element should only fire change events after committing a  value
7305        https://bugs.webkit.org/show_bug.cgi?id=134545
7306
7307        Reviewed by Dean Jackson.
7308
7309        A "change" event was fired every time the slider thumb element was dragged
7310        by the user. The "change" event is now fired only after the thumb
7311        element has stopped moving; previously, both "input" and "change" events
7312        where dispatched while changes were being made. This new behavior is
7313        consistent with the specification (cf.
7314        http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#event-input-change),
7315        as well as other implementations such as Firefox and Chrome.
7316
7317        * Modules/mediacontrols/mediaControlsApple.js:
7318        (Controller.prototype.createControls): Listen to the "input" event
7319        rather than the "change" event for the timeline control in order to
7320        keep track of value changes when the user is dragging the thumb.
7321        * accessibility/AccessibilitySlider.cpp:
7322        (WebCore::AccessibilitySlider::setValue): Dispatch "change" event while
7323        setting the new value rather than dispatching later, since setting the
7324        value now clears the change flag.
7325        * html/RangeInputType.cpp:
7326        (WebCore::RangeInputType::setValue): Update the text value of the
7327        control in the case when no event is to be dispatched, so that this
7328        value can be checked the next time a "change" event dispatch is
7329        requested.
7330        * html/shadow/SliderThumbElement.cpp:
7331        (WebCore::SliderThumbElement::setPositionFromPoint): Removed the
7332        dispatch of the "change" event, and no longer track the text value of
7333        the element as a result of dispatching a "change" event.
7334        (WebCore::SliderThumbElement::stopDragging): Dispatch the "change" event
7335        on completing the drag.
7336
73372014-07-04  Andreas Kling  <akling@apple.com>
7338
7339        CTTE: ApplicationCacheHost always has a DocumentLoader.
7340        <https://webkit.org/b/b/128435>
7341
7342        Have ApplicationCacheHost store the backpointer to its owning
7343        DocumentLoader as a reference.
7344
7345        Reviewed by Sam Weinig.
7346
7347        * loader/DocumentLoader.cpp:
7348        (WebCore::DocumentLoader::DocumentLoader):
7349        (WebCore::DocumentLoader::startLoadingMainResource):
7350        * loader/appcache/ApplicationCacheHost.cpp:
7351        (WebCore::ApplicationCacheHost::ApplicationCacheHost):
7352        (WebCore::ApplicationCacheHost::~ApplicationCacheHost):
7353        (WebCore::ApplicationCacheHost::selectCacheWithoutManifest):
7354        (WebCore::ApplicationCacheHost::selectCacheWithManifest):
7355        (WebCore::ApplicationCacheHost::maybeLoadMainResource):
7356        (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainResponse):
7357        (WebCore::ApplicationCacheHost::maybeLoadFallbackForMainError):
7358        (WebCore::ApplicationCacheHost::failedLoadingMainResource):
7359        (WebCore::ApplicationCacheHost::finishedLoadingMainResource):
7360        (WebCore::ApplicationCacheHost::maybeLoadResource):
7361        (WebCore::ApplicationCacheHost::maybeLoadFallbackForError):
7362        (WebCore::ApplicationCacheHost::maybeLoadSynchronously):
7363        (WebCore::ApplicationCacheHost::notifyDOMApplicationCache):
7364        (WebCore::ApplicationCacheHost::stopDeferringEvents):
7365        (WebCore::ApplicationCacheHost::scheduleLoadFallbackResourceFromApplicationCache):
7366        (WebCore::ApplicationCacheHost::update):
7367        (WebCore::ApplicationCacheHost::swapCache):
7368        (WebCore::ApplicationCacheHost::abort):
7369        (WebCore::ApplicationCacheHost::isApplicationCacheEnabled):
7370        * loader/appcache/ApplicationCacheHost.h:
7371        (WebCore::ApplicationCacheHost::documentLoader): Deleted.
7372
73732014-07-04  Antti Koivisto  <antti@apple.com>
7374
7375        REGRESSION(r159345): Lines are clipped between pages when printing web content from Safari
7376        https://bugs.webkit.org/show_bug.cgi?id=134633
7377        <rdar://problem/17088936>
7378
7379        Reviewed by Zalan Bujtas.
7380
7381        Test: printing/simple-lines-break.html
7382
7383        * rendering/SimpleLineLayout.cpp:
7384        (WebCore::SimpleLineLayout::canUseFor):
7385        
7386            Disable simple lines if global pagination is enabled.
7387            Printing does not currently use flow threads which we already test for.
7388
73892014-07-04  Zan Dobersek  <zdobersek@igalia.com>
7390
7391        Unreviewed. Fixing the build after r170795.
7392
7393        Mac didn't like that change as it seems to properly typedef long long to int64_t.
7394        That's not the case on 64-bit Linux (for some reason), so I'm changing the type of
7395        the two long long variables in FormDataElement to int64_t to avoid any further trouble.
7396
7397        * platform/network/FormData.h:
7398
73992014-07-03  Brady Eidson  <beidson@apple.com>
7400
7401        When showing the selection menu, include menu options for all selected phone numbers.
7402        <rdar://problem/16983434>, <rdar://problem/16874568>, and https://bugs.webkit.org/show_bug.cgi?id=134613
7403
7404        Reviewed by Tim Horton.
7405
7406        * English.lproj/Localizable.strings:
7407
7408        * dom/Range.cpp:
7409        (WebCore::rangesOverlap): Fix reversed arguments that caused some types of overlaps to not be detected.
7410
74112014-07-03  Daniel Bates  <dabates@apple.com>
7412
7413        Add WTF::move()
7414        https://bugs.webkit.org/show_bug.cgi?id=134500
7415
7416        Rubber-stamped by Anders Carlsson.
7417
7418        Substitute WTF::move() for std::move().
7419
7420        * Modules/battery/NavigatorBattery.cpp:
7421        * Modules/encryptedmedia/MediaKeys.cpp:
7422        * Modules/gamepad/NavigatorGamepad.cpp:
7423        * Modules/gamepad/deprecated/NavigatorGamepad.cpp:
7424        * Modules/geolocation/NavigatorGeolocation.cpp:
7425        * Modules/indexeddb/DOMWindowIndexedDatabase.cpp:
7426        * Modules/indexeddb/IDBDatabaseBackend.cpp:
7427        * Modules/indexeddb/IDBDatabaseBackend.h:
7428        [...]
7429
74302014-07-03  Benjamin Poulain  <bpoulain@apple.com>
7431
7432        [iOS][WK2] Fix small bugs of dynamicViewportSizeUpdate that were causing inaccuracies in the computed target
7433        https://bugs.webkit.org/show_bug.cgi?id=134582
7434
7435        Reviewed by Tim Horton.
7436
7437        * WebCore.exp.in:
7438        * platform/ScrollView.h:
7439        (WebCore::ScrollView::unobscuredContentSize):
7440        * platform/ios/ScrollViewIOS.mm:
7441        (WebCore::ScrollView::unobscuredContentRect):
7442        (WebCore::ScrollView::setUnobscuredContentSize):
7443
74442014-07-02  Brent Fulgham  <bfulgham@apple.com>
7445
7446        [Mac] WebKit1 WebView iframe not responding to scroll gestures
7447        https://bugs.webkit.org/show_bug.cgi?id=134569
7448        <rdar://problem/17309008>
7449
7450        Reviewed by Simon Fraser.
7451
7452        New test: platform/mac/fast/scrolling/scroll-iframe-fragment.html
7453
7454        WK1 scrollable areas are implemented on top of PlatformWidget (i.e., NSView) objects. They only
7455        perform a scroll operation if the EventHandler::handleWheelEvent method returns 'false', indicating
7456        that the Cocoa layer should do scrolling work. This is in contrast to WK2, where the scrolling is
7457        handled separately and we return 'true' from EventHandler::handleWheelEvent to indicate that the
7458        scroll event has been handled and that no other work is needed. This mismatch in the meaning of
7459        EventHandler::handleWheelEvent means that WK1 views do not properly handle scroll wheel events.
7460
7461        To correct this, we need to see if we are acting on an Element backed by a PlatformWidget. When we
7462        are (the WK1 case) we want to return 'false' to instruct the Cocoa object to do the scroll operation.
7463        To implement proper latching behavior in WK1, we must return 'true' in the case where we are latched
7464        to a PlatformWidget, and that PlatformWidget did not start the scroll gesture at the edge of
7465        the region in the dominant scroll direction.
7466
7467        Finally, additional logic was needed to determine whether the PlatformWidget is scrolled to the
7468        edge in the dominant scroll direction.
7469
7470        * page/EventHandler.cpp:
7471        (WebCore::EventHandler::platformCompleteWheelEvent): Added stub.
7472        (WebCore::EventHandler::platformCompletePlatformWidgetWheelEvent): Added stub.
7473        (WebCore::EventHandler::handleWheelEvent): Call new platformCompletePlatformWidgetWheelEvent if the
7474        event was handled for a PlatformWidget.
7475        * page/EventHandler.h:
7476        * page/mac/EventHandlerMac.mm:
7477        (WebCore::widgetForEventTarget): Added helper function.
7478        (WebCore::scrollViewForEventTarget): Added helper function.
7479        (WebCore::eventTargetIsPlatformWidget): Added helper function.
7480        (WebCore::EventHandler::platformPrepareForWheelEvents): Check whether we are at a scrolled edge
7481        for the NSView (PlatformWidget) case.
7482        (WebCore::EventHandler::platformCompleteWheelEvent): Return 'false' when handling WK1-style scrolls.
7483        (WebCore::EventHandler::platformCompletePlatformWidgetWheelEvent): Added. We generally want to
7484        return false so the PlatformWidget handles scrolling, except in the case where we are latched to
7485        a PlatformWidget, which has already performed its scroll, and we want to avoid propegating a
7486        scroll event to an enclosing region.
7487
74882014-07-03  Pratik Solanki  <psolanki@apple.com>
7489
7490        Preserve old behavior of creating an NSURLRequest of the exact same type as passed to us
7491        https://bugs.webkit.org/show_bug.cgi?id=134605
7492        <rdar://problem/17544641>
7493
7494        Reviewed by Andreas Kling.
7495
7496        We have client code that passes us a subclass of NSURLRequest to load resource. Later when
7497        we call willSendRequest, they test to make sure they get an object of the same type. My
7498        optimization in r170642 broke this path when I cleared out the NSURLRequest object. We
7499        already had code in updateNSURLRequest() that was taking this quirk into account but I broke
7500        that. Fix it by reverting to old behavior for such clients.
7501
7502        No new tests though we need one. I will add it later.
7503
7504        * platform/network/cf/ResourceRequest.h:
7505        * platform/network/cf/ResourceRequestCFNet.cpp:
7506        (WebCore::ResourceRequest::doUpdatePlatformRequest):
7507        (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
7508        (WebCore::ResourceRequest::setStorageSession):
7509        * platform/network/ios/ResourceRequestIOS.mm:
7510        (WebCore::ResourceRequest::updateNSURLRequest):
7511        (WebCore::ResourceRequest::clearOrUpdateNSURLRequest):
7512
75132014-07-02  Anders Carlsson  <andersca@apple.com>
7514
7515        Stop using EncoderAdapter/DecoderAdapter for FormData
7516        https://bugs.webkit.org/show_bug.cgi?id=134571
7517
7518        Reviewed by Andreas Kling.
7519
7520        * WebCore.exp.in:
7521        * platform/network/FormData.cpp:
7522        (WebCore::encodeElement): Deleted.
7523        (WebCore::decodeElement): Deleted.
7524        (WebCore::FormData::encode): Deleted.
7525        (WebCore::FormData::decode): Deleted.
7526        * platform/network/FormData.h:
7527        (WebCore::FormDataElement::encode):
7528        (WebCore::FormDataElement::decode):
7529        (WebCore::FormData::encode):
7530        (WebCore::FormData::decode):
7531
75322014-07-03  Brady Eidson  <beidson@apple.com>
7533
7534        Selection rects sent to ServicesOverlayController are wrong.
7535        <rdar://problem/16727796> and https://bugs.webkit.org/show_bug.cgi?id=134568
7536
7537        Reviewed by Darin Adler (and Tim Horton and Ryosuke Niwa).
7538
7539        * WebCore.exp.in:
7540
7541        Update the gatherer to keep GapRects separate from LayoutRects:
7542        * editing/SelectionRectGatherer.cpp:
7543        (WebCore::SelectionRectGatherer::addRects):
7544        (WebCore::SelectionRectGatherer::Notifier::~Notifier):
7545        (WebCore::SelectionRectGatherer::clearAndCreateNotifier):
7546        * editing/SelectionRectGatherer.h:
7547
7548        * page/EditorClient.h:
7549        (WebCore::EditorClient::selectionRectsDidChange): Updated to take LayoutRects and GapRects separately.
7550
7551        Change RenderSelectionInfo to also hang on to the individual rects that formed the final bounding rect:
7552        * rendering/RenderSelectionInfo.h:
7553        (WebCore::RenderSelectionInfo::RenderSelectionInfo): If the RenderObject is a RenderText, then call
7554          collectSelectionRectsForLineBoxes instead of selectionRectForRepaint.
7555        (WebCore::RenderSelectionInfo::rects):
7556
7557        * rendering/RenderText.cpp:
7558        (WebCore::RenderText::collectSelectionRectsForLineBoxes): Added
7559        (WebCore::RenderText::selectionRectForRepaint):
7560        * rendering/RenderText.h:
7561
7562        * rendering/RenderTextLineBoxes.cpp:
7563        (WebCore::RenderTextLineBoxes::collectSelectionRectsForRange): Added
7564        * rendering/RenderTextLineBoxes.h:
7565
7566        * rendering/RenderView.cpp:
7567        (WebCore::RenderView::setSubtreeSelection): Add the list of rects to the gatherer instead of just 
7568          the bounding rect.
7569
75702014-07-03  Brady Eidson  <beidson@apple.com>
7571
7572        Possible crash in IconDatabase in WebCore::IconDatabase::dispatchDidRemoveAllIconsOnMainThread
7573        <rdar://problem/17437687> and https://bugs.webkit.org/show_bug.cgi?id=134517
7574
7575        Reviewed by Eric Carlson.
7576
7577        Since WebCore::IconDatabase is not RefCounted there’s no obvious way to keep it alive until it is
7578        truly no longer needed.
7579
7580        This isn’t generally a problem because they are usually a singleton that lasts the lifetime of the process.
7581
7582        In the WebKit2 case, WebCore::IconDatabases can come and go as their owning WebIconDatabases come and go.
7583
7584        So we can rely on WebIconDatabase to handle the lifetime appropriately. 
7585
7586        * loader/icon/IconDatabase.cpp:
7587        (WebCore::IconDatabase::close): If the database is actually closed, notify the client.
7588        (WebCore::IconDatabase::IconDatabase):
7589        (WebCore::IconDatabase::isOpen): Take into account whether there’s any main thread callbacks, plus what
7590          is covered by isOpenBesidesMainThreadCallbacks.
7591        (WebCore::IconDatabase::isOpenBesidesMainThreadCallbacks): Take into account whether the sync thread
7592          is still running and whether or not the database file is still open.
7593        (WebCore::IconDatabase::checkClosedAfterMainThreadCallback): Checks to see if the database has just
7594          become 100% closed and - if so - notify the client.
7595        (WebCore::IconDatabase::dispatchDidImportIconURLForPageURLOnMainThread): Updated to increment the main thread
7596          callback count and to call checkClosedAfterMainThreadCallback when done.
7597        (WebCore::IconDatabase::dispatchDidImportIconDataForPageURLOnMainThread): Ditto.
7598        (WebCore::IconDatabase::dispatchDidRemoveAllIconsOnMainThread): Ditto.
7599        (WebCore::IconDatabase::dispatchDidFinishURLImportOnMainThread): Ditto.
7600        * loader/icon/IconDatabase.h:
7601
7602        * loader/icon/IconDatabaseClient.h:
7603        (WebCore::IconDatabaseClient::didClose): Added. For the IconDatabase to tell its client it is 100% closed.
7604
76052014-07-03  Chris Fleizach  <cfleizach@apple.com>
7606
7607        AX: VoiceOver does not read aria-expanded attribute on controls in Safari
7608        https://bugs.webkit.org/show_bug.cgi?id=134527
7609
7610        Reviewed by Mario Sanchez Prada.
7611
7612        Expose whether the ARIA expanded property is present or not.
7613
7614        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
7615        (-[WebAccessibilityObjectWrapper accessibilitySupportsARIAExpanded]):
7616
76172014-07-02  Jon Honeycutt  <jhoneycutt@apple.com>
7618
7619        Removing an element with CSS -webkit-overflow-scrolling: touch breaks
7620        subsequent touch events
7621
7622        <https://bugs.webkit.org/show_bug.cgi?id=134584>
7623        <rdar://problem/17202021>
7624
7625        This issue is caused by the order of teardown for RenderLayers.
7626
7627        RenderLayer clears its m_backing in its destructor, calling the
7628        RenderLayerBacking destructor. The RenderLayerBacking destructor calls
7629        RenderLayerCompositor::willRemoveScrollingLayer(), which tries to
7630        access the RenderLayer's backing that has already been cleared. This
7631        causes us to skip the call to ChromeClient::removeScrollingLayer(),
7632        resulting in a stale view that can block touch events.
7633
7634        Reviewed by Simon Fraser.
7635
7636        * rendering/RenderLayerBacking.cpp:
7637        (WebCore::RenderLayerBacking::updateScrollingLayers):
7638        When calling willRemoveScrollingLayerWithBacking(), pass both the layer
7639        and the RenderLayerBacking.
7640
7641        * rendering/RenderLayerCompositor.cpp:
7642        (WebCore::RenderLayerCompositor::willRemoveScrollingLayerWithBacking):
7643        Renamed. Use the passed RenderLayerBacking, as the RenderLayer's
7644        backing might have already been cleared.
7645        (WebCore::RenderLayerCompositor::willRemoveScrollingLayer): Deleted.
7646
7647        * rendering/RenderLayerCompositor.h:
7648        Renamed willRemoveScrollingLayer() to
7649        willRemoveScrollingLayerWithBacking() and added a parameter.
7650
76512014-07-01  Mark Rowe  <mrowe@apple.com>
7652
7653        Ensure that the WebKit bundle version in the user agent string continues to match the current format.
7654        <https://webkit.org/b/134524> / <rdar://problem/17447771>
7655
7656        Reviewed by Simon Fraser.
7657
7658        * page/cocoa/UserAgent.h:
7659        * page/cocoa/UserAgent.mm:
7660        (WebCore::userVisibleWebKitBundleVersionFromFullVersion): Updated to take an NSString now that it's internal
7661        to the file.
7662        (WebCore::userAgentBundleVersionFromFullVersionString): Limit the bundle version included in the user agent
7663        string to three components.
7664        * page/ios/UserAgentIOS.mm:
7665        (WebCore::standardUserAgentWithApplicationName): Update to call userAgentBundleVersionFromFullVersionString.
7666        * page/mac/UserAgentMac.mm:
7667        (WebCore::standardUserAgentWithApplicationName): Ditto.
7668
76692014-07-01  Mark Rowe  <mrowe@apple.com>
7670
7671        <https://webkit.org/b/134522> Remove duplication in code that prepares the user agent string on Mac and iOS
7672
7673        Reviewed by Simon Fraser.
7674
7675        * page/cocoa/UserAgent.h:
7676        * page/cocoa/UserAgent.mm:
7677        (WebCore::userVisibleWebKitBundleVersionFromFullVersion): Moved from WebKit2.
7678        * page/ios/UserAgentIOS.mm:
7679        (WebCore::standardUserAgentWithApplicationName): Pass the WebKit bundle version through userVisibleWebKitBundleVersionFromFullVersion
7680        before including it in the user agent string.
7681        * page/mac/UserAgentMac.mm:
7682        (WebCore::standardUserAgentWithApplicationName): Ditto.
7683
76842014-07-02  Mark Rowe  <mrowe@apple.com>
7685
7686        <https://webkit.org/b/134521> iOS should use shared code to determine the system marketing version
7687
7688        Reviewed by Simon Fraser.
7689
7690        * WebCore.xcodeproj/project.pbxproj: Add the new files, and sort the groups they're in.
7691        * page/cocoa/UserAgent.h: Copied from Source/WebCore/page/mac/UserAgent.h.
7692        * page/cocoa/UserAgent.mm: Renamed from Source/WebCore/page/mac/UserAgent.h.
7693        Move systemMarketingVersionForUserAgentString to a location where it can be shared between
7694        Mac and iOS.
7695        * page/ios/UserAgentIOS.mm:
7696        (WebCore::standardUserAgentWithApplicationName): Switch to systemMarketingVersionForUserAgentString.
7697        * page/mac/UserAgentMac.mm:
7698        * platform/cocoa/SystemVersion.h: Renamed from Source/WebCore/platform/mac/SystemVersionMac.h.
7699        * platform/cocoa/SystemVersion.mm: Renamed from Source/WebCore/platform/mac/SystemVersionMac.mm.
7700        Move to a location that makes it clear this is shared between Mac and iOS. Enable the modern Mac
7701        codepath for iOS as well.
7702
77032014-07-02  Anders Carlsson  <andersca@apple.com>
7704
7705        Remove keyed coding from FormData
7706        https://bugs.webkit.org/show_bug.cgi?id=134565
7707
7708        Reviewed by Tim Horton.
7709
7710        * platform/network/FormData.cpp:
7711        (WebCore::encodeElement): Deleted.
7712        (WebCore::decodeElement): Deleted.
7713        (WebCore::FormData::encode): Deleted.
7714        (WebCore::FormData::decode): Deleted.
7715        * platform/network/FormData.h:
7716
77172014-07-02  Anders Carlsson  <andersca@apple.com>
7718
7719        Get rid of the HistoryItem encoding/decoding in WebCore
7720        https://bugs.webkit.org/show_bug.cgi?id=134564
7721
7722        Reviewed by Beth Dakin.
7723
7724        * WebCore.exp.in:
7725        * history/HistoryItem.cpp:
7726        (WebCore::HistoryItem::encodeBackForwardTree): Deleted.
7727        (WebCore::encodeRect): Deleted.
7728        (WebCore::encodeSize): Deleted.
7729        (WebCore::HistoryItem::encodeBackForwardTreeNode): Deleted.
7730        (WebCore::DecodeRecursionStackElement::DecodeRecursionStackElement): Deleted.
7731        (WebCore::decodeRect): Deleted.
7732        (WebCore::decodeSize): Deleted.
7733        (WebCore::HistoryItem::decodeBackForwardTree): Deleted.
7734        * history/HistoryItem.h:
7735
77362014-07-02  Alex Christensen  <achristensen@webkit.org>
7737
7738        [WebGL] Fix crash when glsl expressions are too complex.
7739        https://bugs.webkit.org/show_bug.cgi?id=134554
7740        <rdar://problem/17540462>
7741
7742        Reviewed by Dean Jackson.
7743        
7744        This fixes the Khronos test conformance/glsl/bugs/long-expressions-should-not-crash.html.
7745
7746        * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
7747        (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE):
7748        Add SH_LIMIT_EXPRESSION_COMPLEXITY to the ANGLE compile options.
7749
77502014-07-02  Benjamin Poulain  <benjamin@webkit.org>
7751
7752        WebCore JIT: rename registerCount to something less generic and add new types for lists of registers and lists of stack references
7753        https://bugs.webkit.org/show_bug.cgi?id=134552
7754
7755        Reviewed by Alex Christensen.
7756
7757        Little cleanup:
7758        -The name registerCount was a little too generic. Rename that to "maximumRegisterCount" to avoid confusion.
7759        -Add a new type RegisterVector for any vector holding registers. This is just to avoid repeating the inline
7760         size everywhere, no functional change.
7761        -Same idea for the stack: welcome StackReferenceVector!
7762
7763        * cssjit/FunctionCall.h:
7764        (WebCore::FunctionCall::saveAllocatedCallerSavedRegisters):
7765        Remove the appendVector here. It was unnecessarily cautious, StackAllocator already protect us
7766        from mistakes.
7767
7768        * cssjit/RegisterAllocator.h:
7769        (WebCore::RegisterAllocator::allocatedRegisters):
7770        * cssjit/SelectorCompiler.cpp:
7771        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
7772        Changing from the count of "calleeSavedRegisterCount" to "maximumRegisterCount" will cause
7773        calleeSavedRegisterStackReferences to always overallocate.
7774        The code generator is never on the heap, so that should not change anything.
7775
7776        * cssjit/StackAllocator.h:
7777        (WebCore::StackAllocator::push):
7778        (WebCore::StackAllocator::pop):
7779
77802014-07-02  Dan Bernstein  <mitz@apple.com>
7781
7782        Remove some code only needed for versions of Safari that are no longer supported
7783        https://bugs.webkit.org/show_bug.cgi?id=134537
7784
7785        Reviewed by Anders Carlsson.
7786
7787        * bindings/objc/DOMHTML.mm:
7788        (-[DOMHTMLInputElement _rectOnScreen]): Deleted.
7789        (-[DOMHTMLInputElement _replaceCharactersInRange:withString:selectingFromIndex:]): Deleted.
7790        (-[DOMHTMLInputElement _selectedRange]): Deleted.
7791        * bindings/objc/DOMPrivate.h:
7792        * editing/EditorCommand.cpp:
7793        (WebCore::createCommandMap):
7794
77952014-07-02  Carlos Garcia Campos  <cgarcia@igalia.com>
7796
7797        [GStreamer] MediaPlayerPrivateGStreamer.cpp fails to build when VIDEO_TRACK is enabled and using GSTREAMER_MPEGTS
7798        https://bugs.webkit.org/show_bug.cgi?id=134548
7799
7800        Reviewed by Philippe Normand.
7801
7802        Include AtomicStringHash.h when ENABLE(VIDEO_TRACK) && USE(GSTREAMER_MPEGTS)
7803        since it's used by HashMap<AtomicString, RefPtr<InbandMetadataTextTrackPrivateGStreamer>>
7804
7805        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
7806
78072014-07-02  Carlos Garcia Campos  <cgarcia@igalia.com>
7808
7809        [GTK] Unstable headers should include webkitdomdefines-unstable.h
7810        https://bugs.webkit.org/show_bug.cgi?id=134540
7811
7812        Reviewed by Martin Robinson.
7813
7814        Instead of the class header that can only be included from webkitdom.h.
7815
7816        * bindings/scripts/CodeGeneratorGObject.pm:
7817        (WriteData):
7818
78192014-07-02  Mario Sanchez Prada  <mario.prada@samsung.com>
7820
7821        REGRESSION(r170008): [GTK] Layout Tests fast/forms/option-constructor-selected.html and fast/forms/select-live-pseudo-selectors.html crash.
7822        https://bugs.webkit.org/show_bug.cgi?id=134399
7823
7824        Reviewed by Chris Fleizach.
7825
7826        Check that the value of optionIndex passed as a parameter is valid
7827        before calling didUpdateActiveOption() over the item of the menu
7828        list, to prevent crashes in platforms where renderers (and therefore
7829        accessibility objects) might not be created for items at the time
7830        of calling AccessibilityMenuList::didUpdateActiveOption().
7831
7832        * accessibility/AccessibilityMenuList.cpp:
7833        (WebCore::AccessibilityMenuList::didUpdateActiveOption): Added check.
7834
78352014-07-02  Carlos Garcia Campos  <cgarcia@igalia.com>
7836
7837        [GTK] Do not add forward declaration of class struct for interfaces
7838        https://bugs.webkit.org/show_bug.cgi?id=134297
7839
7840        Reviewed by Martin Robinson.
7841
7842        * PlatformGTK.cmake: Make files generated by
7843        gobject-generate-headers.pl script depend on it.
7844        * bindings/gobject/WebKitDOMEventTarget.h: Remove forward declaration.
7845        * bindings/gobject/WebKitDOMNodeFilter.h: Ditto
7846        * bindings/gobject/WebKitDOMXPathNSResolver.h: Ditto.
7847        * bindings/scripts/gobject-generate-headers.pl: Use Iface instead
7848        of Class suffix for interfaces.
7849
78502014-07-01  Carlos Garcia Campos  <cgarcia@igalia.com>
7851
7852        [GTK] XPathNSResolver should be exposed as an interface instead of as a class
7853        https://bugs.webkit.org/show_bug.cgi?id=134028
7854
7855        Reviewed by Gustavo Noronha Silva.
7856
7857        Add custom implementation of WebKitDOMXPathNSResolver to expose it
7858        as an interface instead of a class. It also includes an internal
7859        default implementation of the interface to support methods that
7860        create a XPathNSResolver using the native implementation.
7861
7862        * PlatformGTK.cmake: Add new files to compilation.
7863        * bindings/gobject/GObjectXPathNSResolver.cpp: Added.
7864        (WebCore::GObjectXPathNSResolver::~GObjectXPathNSResolver):
7865        (WebCore::GObjectXPathNSResolver::lookupNamespaceURI): Call
7866        webkit_dom_xpath_ns_resolver_lookup_namespace_uri().
7867        * bindings/gobject/GObjectXPathNSResolver.h: Added.
7868        (WebCore::GObjectXPathNSResolver::create):
7869        (WebCore::GObjectXPathNSResolver::GObjectXPathNSResolver): Create
7870        a new GObjectXPathNSResolver for the given WebKitDOMXPathNSResolver.
7871        * bindings/gobject/WebKitDOMXPathNSResolver.cpp: Added.
7872        (webkit_dom_xpath_ns_resolver_default_init):
7873        (webkit_dom_xpath_ns_resolver_lookup_namespace_uri):
7874        (webkitDOMNativeXPathNSResolverFinalize):
7875        (webkitDOMNativeXPathNSResolverConstructor):
7876        (webkit_dom_native_xpath_ns_resolver_init):
7877        (webkit_dom_native_xpath_ns_resolver_class_init):
7878        (webkitDOMNativeXPathNSResolverLookupNamespaceURI):
7879        (webkitDOMXPathNSResolverIfaceInit):
7880        (WebKit::core): Return the native XPathNSResolver when using the
7881        internal implementation or create a custom XPathNSResolver when
7882        using a user provided WebKitDOMXPathNSResolver.
7883        (WebKit::kit):
7884        * bindings/gobject/WebKitDOMXPathNSResolver.h: Added.
7885        * bindings/gobject/WebKitDOMXPathNSResolverPrivate.h: Added.
7886        * bindings/scripts/CodeGeneratorGObject.pm:
7887        (GenerateFunction): Add exceptions for XPathNSResolver since
7888        the core method returns a PassRefPtr.
7889
78902014-07-01  Frédéric Wang  <fred.wang@free.fr>
7891
7892        The OpenType MATH table is not read on Mac
7893        https://bugs.webkit.org/show_bug.cgi?id=133569
7894
7895        Reviewed by Chris Fleizach.
7896
7897        An incorrect tag format is used to load the OpenType MATH table on Mac.
7898        This commit makes the format consistent with what is used for other tables on Mac.
7899        This will allow to load the MATH table and to use it for the MathML rendering.
7900
7901        No new tests. platform/graphics/opentype already contains tests for the OpenType MATH support.
7902
7903        * platform/graphics/opentype/OpenTypeMathData.cpp:
7904
79052014-07-01  Alex Christensen  <achristensen@webkit.org>
7906
7907        [Win64] Unreviewed build fix.
7908
7909        * WebCore.vcxproj/WebCore.vcxproj:
7910        Exclude CA files from 32 and 64 bit WinCairo builds.
7911        * WebCore.vcxproj/WebCoreTestSupport.vcxproj:
7912        Don't use a precompiled header in 32 or 63 bit builds of MockCDM.cpp.
7913
79142014-07-01  Alex Christensen  <achristensen@webkit.org>
7915
7916        Reduce dynamic memory allocation in css jit.
7917        https://bugs.webkit.org/show_bug.cgi?id=134416
7918
7919        Reviewed by Benjamin Poulain.
7920
7921        * cssjit/FunctionCall.h:
7922        (WebCore::FunctionCall::saveAllocatedRegisters):
7923        * cssjit/RegisterAllocator.h:
7924        * cssjit/SelectorCompiler.cpp:
7925        (WebCore::SelectorCompiler::addPseudoClassType):
7926        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
7927        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
7928        * cssjit/StackAllocator.h:
7929        (WebCore::StackAllocator::push):
7930        (WebCore::StackAllocator::pop):
7931        Use inlineCapacity template parameter to reduce malloc calls.
7932        I use 32 as the inline capacity for non-register related vectors because that
7933        is probably big enough for the selector compiler, and if it is not then a malloc
7934        call will not be significant because the selector is very complex.
7935
79362014-07-01  Eric Carlson  <eric.carlson@apple.com>
7937
7938        WebVTT percentage value can be a float
7939        https://bugs.webkit.org/show_bug.cgi?id=134511
7940
7941        Reviewed by Brent Fulgham.
7942
7943        No new tests, existing tests modified.
7944
7945        * html/track/TextTrackCueGeneric.cpp:
7946        (WebCore::TextTrackCueGeneric::setLine): int -> double.
7947        (WebCore::TextTrackCueGeneric::setPosition): Ditto.
7948        * html/track/TextTrackCueGeneric.h:
7949
7950        * html/track/VTTCue.cpp:
7951        (WebCore::VTTCue::setLine): Ditto.
7952        (WebCore::VTTCue::setPosition):  Ditto.
7953        (WebCore::VTTCue::setCueSettings): Support floating point values for line, position, and size.
7954        (WebCore::scanPercentage): Deleted.
7955        * html/track/VTTCue.h:
7956
7957        * html/track/VTTScanner.cpp:
7958        (WebCore::VTTScanner::scanFloat): Support negative values.
7959        * html/track/VTTScanner.h:
7960
7961        * html/track/WebVTTParser.cpp: Include parseFloatPercentageValue in non-WEBVTT_REGIONS builds.
7962        * html/track/WebVTTParser.h:
7963
7964        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
7965        (WebCore::InbandTextTrackPrivateAVF::processCueAttributes): Drive by change to take a cue
7966            reference rather than a pointer.
7967        (WebCore::InbandTextTrackPrivateAVF::processAttributedStrings): Ditto.
7968        (WebCore::InbandTextTrackPrivateAVF::removeCompletedCues): Loop over all cues, don't LOG that
7969            we are asking the client to delete the cue because the client will have already deleted
7970            it when status when to GenericCueData::Complete.
7971        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
7972
79732014-07-01  Simon Fraser  <simon.fraser@apple.com>
7974
7975        Improve behavior of position:sticky on zoomed pages
7976        https://bugs.webkit.org/show_bug.cgi?id=134535
7977        <rdar://problem/12898829>
7978
7979        Reviewed by Dean Jackson.
7980
7981        Despite r138036, position:sticky still had incorrect behavior in zoomed pages.
7982        
7983        Fix by removing the scaling of the rect from viewportConstrainedVisibleContentRect(),
7984        since all the other math happens in unscaled coordinates.
7985
7986        * rendering/RenderBoxModelObject.cpp:
7987        (WebCore::RenderBoxModelObject::constrainingRectForStickyPosition):
7988
79892014-07-01  Alex Christensen  <achristensen@webkit.org>
7990
7991        [WebGL] Fix PVRTC extension.
7992        https://bugs.webkit.org/show_bug.cgi?id=134525
7993
7994        Reviewed by Dean Jackson.
7995
7996        * html/canvas/WebGLRenderingContext.cpp:
7997        (WebCore::WebGLRenderingContext::validateCompressedTexDimensions):
7998        Remove the return false which I mistakenly committed in r170128
7999        and make the gl error match the S3TC error and the khronos test.
8000
80012014-07-01  Chris Fleizach  <cfleizach@apple.com>
8002
8003        AX: iOS does not expose ARIA toggle buttons at all (not even as a regular button)
8004        https://bugs.webkit.org/show_bug.cgi?id=133875
8005
8006        Reviewed by Enrica Casucci.
8007
8008        Support the toggle button type in iOS.
8009
8010        Test: platform/ios-sim/accessibility/toggle-button.html
8011
8012        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
8013        (-[WebAccessibilityObjectWrapper accessibilityCanFuzzyHitTest]):
8014        (-[WebAccessibilityObjectWrapper accessibilityTraits]):
8015        (-[WebAccessibilityObjectWrapper determineIsAccessibilityElement]):
8016
80172014-07-01  Dean Jackson  <dino@apple.com>
8018
8019        [iOS] Subsampled JPEG images do not draw correctly via the canvas APIs
8020        https://bugs.webkit.org/show_bug.cgi?id=134513
8021        <rdar://problem/12078860>
8022        <rdar://problem/16745393>
8023
8024        Reviewed by Tim Horton.
8025
8026        Subsampled images (e.g. JPEG) were not consistently using
8027        their original dimensions and subsampled dimensions. This caused
8028        things like texImage2D to pack the pixels incorrectly, or drawImage
8029        to squish the rendering.
8030
8031        Renamed m_scale to m_subsamplingScale on FrameData.
8032
8033        Tests: fast/canvas/image-potential-subsample.html
8034               fast/canvas/webgl/tex-image-and-sub-image-2d-with-potentially-subsampled-image.html
8035
8036        * platform/graphics/BitmapImage.cpp:
8037        (WebCore::BitmapImage::cacheFrame): Rename to m_subsamplingScale.
8038        (WebCore::BitmapImage::frameAtIndex): Ditto.
8039        * platform/graphics/BitmapImage.h:
8040        (WebCore::FrameData::FrameData): Ditto.
8041        * platform/graphics/cg/BitmapImageCG.cpp:
8042        (WebCore::FrameData::clear): Ditto.
8043        (WebCore::BitmapImage::BitmapImage): Ditto.
8044        (WebCore::BitmapImage::draw): Use a scaledSrcRect that reflects the subsampled size,
8045        rather than assuming the srcRect accurately reflects how many pixels we have
8046        in the Bitmap.
8047        (WebCore::BitmapImage::copyUnscaledFrameAtIndex):
8048        * platform/graphics/cg/GraphicsContext3DCG.cpp:
8049        (WebCore::GraphicsContext3D::ImageExtractor::extractImage): Similar fix, although this
8050        time we just ask the image decoder to take into account the subsampled size
8051        when it is "generating" a frame, causing it to use the bitmap data it has already
8052        decoded.
8053
80542014-07-01  Joseph Pecoraro  <pecoraro@apple.com>
8055
8056        Web Inspector: Selected DOM element highlights invisible near bottom of the viewport (topContentInset?)
8057        https://bugs.webkit.org/show_bug.cgi?id=133818
8058
8059        Reviewed by Beth Dakin.
8060
8061        * inspector/InspectorOverlay.cpp:
8062        (WebCore::InspectorOverlay::update):
8063        Take the topContentInset into account when sizing the InspectorOverlay's FrameView.
8064
80652014-07-01  Chris Fleizach  <cfleizach@apple.com>
8066
8067        AX: HTML indeterminate IDL attribute not mapped to checkbox value=2
8068        https://bugs.webkit.org/show_bug.cgi?id=134492
8069
8070        Reviewed by Andreas Kling.
8071
8072        Support the indeterminate attribute in AX code.
8073
8074        Test: Update existing test: accessibility/aria-checked-mixed-value
8075
8076        * accessibility/AccessibilityObject.cpp:
8077        (WebCore::AccessibilityObject::checkboxOrRadioValue):
8078
80792014-07-01  Myles C. Maxfield  <mmaxfield@apple.com>
8080
8081        Typing an automatic text replacement phrase after a br in contenteditable is not rendered as expected
8082        https://bugs.webkit.org/show_bug.cgi?id=133883
8083
8084        Reviewed by Enrica Casucci.
8085
8086        enclosingDeletableElement() makes sure that the element's container is editable, but not
8087        that it is capable of having content inside it (like how a <br> can't).
8088
8089        No new tests. I don't think this is testable because it requires setting some state in System Preferences.
8090
8091        * editing/DeleteButtonController.cpp:
8092        (WebCore::enclosingDeletableElement):
8093
80942014-07-01  Alex Christensen  <achristensen@webkit.org>
8095
8096        [iOS] Unreviewed build fix after r170640.
8097
8098        * page/EditorClient.h:
8099        (WebCore::EditorClient::selectedTelephoneNumberRangesChanged):
8100        Add ifdefs to make everything compile and link.
8101
81022014-07-01  Daniel Bates  <dabates@apple.com>
8103
8104        Remove unnecessary calls to std::move()
8105        https://bugs.webkit.org/show_bug.cgi?id=134493
8106
8107        Reviewed by Anders Carlsson.
8108
8109        * Modules/encryptedmedia/CDM.cpp:
8110        (WebCore::CDM::CDM):
8111        * css/CSSGrammar.y.in:
8112        * css/CSSPrimitiveValue.cpp:
8113        (WebCore::CSSPrimitiveValue::formatNumberValue):
8114        * css/MediaQuery.cpp:
8115        (WebCore::MediaQuery::MediaQuery):
8116        * platform/graphics/mac/FontMac.mm:
8117        (WebCore::Font::dashesForIntersectionsWithRect):
8118
81192014-07-01  Zalan Bujtas  <zalan@apple.com>
8120
8121        Subpixel rendering: Pixel crack in breadcrumbs at devforums.apple.com.
8122        https://bugs.webkit.org/show_bug.cgi?id=134491
8123
8124        Reviewed by Simon Fraser.
8125
8126        Do not early round geometry values, while computing background image position. It changes the final
8127        subpixel values and that could lead to wrong snap positions.
8128        pixelSnapBackgroundImageGeometryForPainting() takes care of geometry snapping.
8129
8130        Test: fast/backgrounds/background-image-size-double-rounding.html
8131
8132        * rendering/RenderBoxModelObject.cpp:
8133        (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
8134
81352014-07-01  Pratik Solanki  <psolanki@apple.com>
8136
8137        Create NSURLRequest lazily when USE(CFNETWORK) is enabled
8138        https://bugs.webkit.org/show_bug.cgi?id=134441
8139
8140        Reviewed by Andreas Kling.
8141
8142        No new tests. Should be covered by existing tests.
8143
8144        * platform/network/cf/ResourceRequest.h:
8145        (WebCore::ResourceRequest::ResourceRequest):
8146        (WebCore::ResourceRequest::encodingRequiresPlatformData):
8147        * platform/network/cf/ResourceRequestCFNet.cpp:
8148        (WebCore::ResourceRequest::doUpdatePlatformRequest):
8149        (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
8150        (WebCore::ResourceRequest::setStorageSession):
8151        * platform/network/cocoa/ResourceRequestCocoa.mm:
8152        (WebCore::ResourceRequest::nsURLRequest):
8153
81542014-07-01  Brady Eidson  <beidson@apple.com>
8155
8156        Combine the Telephone and Selection overlay controllers, updating UI behavior.
8157        https://bugs.webkit.org/show_bug.cgi?id=134461
8158
8159        Reviewed by Tim Horton.
8160
8161        * WebCore.exp.in:
8162
8163        * dom/Range.cpp:
8164        (WebCore::Range::contains): Returns true if the Range completely contains the passed-in Range.
8165        * dom/Range.h:
8166
81672014-07-01  Antti Koivisto  <antti@apple.com>
8168
8169        REGRESSION(160908): vube.com video won't play after going into and out of fullscreen
8170        https://bugs.webkit.org/show_bug.cgi?id=134489
8171
8172        Reviewed by Zalan Bujtas.
8173
8174        Test: fullscreen/full-screen-plugin.html
8175
8176        It is difficult to restore the render tree correctly in all cases after removing a full screen
8177        renderer from the tree. r160908 avoided dealing with this by simply always reconstructing the subtree.
8178        Unfortunately plugin lifetime is currently tied to its renderer so this would cause the plugin to restart.
8179        
8180        With this patch we avoid reconstruction in normal cases and only force it if the render tree is complicated.
8181
8182        * dom/Document.cpp:
8183        (WebCore::unwrapFullScreenRenderer):
8184        
8185            Force reconstruction conditionally.
8186
8187        (WebCore::Document::webkitWillEnterFullScreenForElement):
8188        (WebCore::Document::webkitDidExitFullScreenForElement):
8189        * rendering/RenderFullScreen.cpp:
8190        (WebCore::RenderFullScreen::wrapRenderer):
8191        (WebCore::RenderFullScreen::unwrapRenderer):
8192        
8193            Deal with the simple case of single child, possibly in anonymous wrapper.
8194            In other cases request reconstruction.
8195            This is covered by the existing fullscreen tests.
8196
8197        * rendering/RenderFullScreen.h:
8198
81992014-07-01  Zan Dobersek  <zdobersek@igalia.com>
8200
8201        Remove remaining Vector<> copies in WebCore accessibility code
8202        https://bugs.webkit.org/show_bug.cgi?id=133263
8203
8204        Reviewed by Darin Adler.
8205
8206        * accessibility/AXObjectCache.cpp:
8207        (WebCore::AXObjectCache::notificationPostTimerFired): Don't copy the Vector member and
8208        then clear it -- move it into the local variable instead.
8209        * accessibility/AccessibilityNodeObject.cpp:
8210        (WebCore::AccessibilityNodeObject::ariaLabeledByText): Move the axElements Vector into
8211        the AccessibilityText constructor.
8212        (WebCore::AccessibilityNodeObject::stringValue): Create a const reference to the Vector of
8213        HTMLSelectElement's list items instead of copying it.
8214        * accessibility/AccessibilityObject.h:
8215        (WebCore::AccessibilityText::AccessibilityText): Take the Vector parameter by non-const
8216        value and move it into the member variable.
8217        * accessibility/AccessibilityRenderObject.cpp: 
8218        (WebCore::AccessibilityRenderObject::stringValue): Create a const reference to the Vector
8219        of HTMLSelectElement's list items instead of copying it.
8220        (WebCore::AccessibilityRenderObject::ariaSelectedRows): Wrap the AccessibilityChildrenVector
8221        iteration in a lambda. Use it to iterate over either the newly-constructed Vector (in case
8222        the object has the tree role) or the reference to the vector returned by
8223        AccessibilityTable::rows() (in case the object is an AccessibilityTable instance).
8224
82252014-06-30  Commit Queue  <commit-queue@webkit.org>
8226
8227        Unreviewed, rolling out r170605.
8228        https://bugs.webkit.org/show_bug.cgi?id=134484
8229
8230        The changes cause crashes on ARM64 (Requested by benjaminp on
8231        #webkit).
8232
8233        Reverted changeset:
8234
8235        "Reduce dynamic memory allocation in css jit."
8236        https://bugs.webkit.org/show_bug.cgi?id=134416
8237        http://trac.webkit.org/changeset/170605
8238
82392014-06-30  Anders Carlsson  <andersca@apple.com>
8240
8241        Change the AddBackForwardItem message to take a page state object
8242        https://bugs.webkit.org/show_bug.cgi?id=134475
8243
8244        Reviewed by Andreas Kling.
8245
8246        * WebCore.exp.in:
8247
82482014-06-30  Benjamin Poulain  <benjamin@webkit.org>
8249
8250        [iOS][WK2] Do not put tap highlight on images that are not in links, and on applet/embed/object
8251        https://bugs.webkit.org/show_bug.cgi?id=134471
8252        <rdar://problem/17513542>
8253
8254        Reviewed by Enrica Casucci.
8255
8256        UIKit has some special code to avoid tap highlight on certain type of object. This is not very flexible
8257        since the page has no way of overriding that behavior.
8258
8259        This patch implement the same feature by changing the default stylesheet. The tap highlight is disabled
8260        by default for those object, and enabled for images that are in a link.
8261
8262        * css/html.css:
8263        (applet, embed, object, img):
8264        (:-webkit-any-link img):
8265
82662014-06-30  Myles C. Maxfield  <mmaxfield@apple.com>
8267
8268        All Indic text is rendered as boxes on iOS
8269        https://bugs.webkit.org/show_bug.cgi?id=134464
8270
8271        Reviewed by Simon Fraser.
8272
8273        I made a typo in r170207.
8274
8275        Test: fast/text/indic.html
8276
8277        * platform/graphics/ios/FontCacheIOS.mm:
8278        (WebCore::languageSpecificFallbackFont):
8279
82802014-06-30  Myles C. Maxfield  <mmaxfield@apple.com>
8281
8282        [iOS] languageSpecificFallbackFont() is not consistent
8283        https://bugs.webkit.org/show_bug.cgi?id=134473
8284
8285        Reviewed by Darin Adler.
8286
8287        It can use "<" throughout the function as well as keeping the fallthrough behavior consistent.
8288
8289        No tests because there is no behavior change.
8290
8291        * platform/graphics/ios/FontCacheIOS.mm:
8292        (WebCore::languageSpecificFallbackFont):
8293
82942014-06-30  Brent Fulgham  <bfulgham@apple.com>
8295
8296        [Win] Unreviewed gardening.
8297
8298        * WebCore.vcxproj/WebCore.vcxproj: Do not compile JSFileException
8299        and JSFileReaderSync multiple times.
8300
83012014-06-30  Daniel Bates  <dabates@apple.com>
8302
8303        Avoid copying function object in lambda function in ScrollingThread::dispatchBarrier(); actually use move semantics
8304        https://bugs.webkit.org/show_bug.cgi?id=134470
8305
8306        Reviewed by Anders Carlsson.
8307
8308        Currently we always copy construct the captured std::function object when calling callOnMainThread()
8309        in the lambda function created in ScrollingThread::dispatchBarrier() because captured variables are
8310        const in a lambda expression's body by default. That is, the std::function object is captured as const.
8311        Instead, we should mark this lambda expression as mutable so the captured std::function object is
8312        non-const and hence we can use move semantics when passing it to callOnMainThread().
8313
8314        * page/scrolling/ScrollingThread.cpp:
8315        (WebCore::ScrollingThread::dispatchBarrier):
8316
83172014-06-30  Anders Carlsson  <andersca@apple.com>
8318
8319        Adopt the legacy session decoding inside WebPage::restoreSession for now
8320        https://bugs.webkit.org/show_bug.cgi?id=134465
8321
8322        Reviewed by Sam Weinig.
8323
8324        * WebCore.exp.in:
8325
83262014-06-30  Commit Queue  <commit-queue@webkit.org>
8327
8328        Unreviewed, rolling out r170578.
8329        https://bugs.webkit.org/show_bug.cgi?id=134462
8330
8331        causes assertions loading nytimes.com on iOS (Requested by
8332        smfr on #webkit).
8333
8334        Reverted changeset:
8335
8336        "Create NSURLRequest lazily when USE(CFNETWORK) is enabled"
8337        https://bugs.webkit.org/show_bug.cgi?id=134441
8338        http://trac.webkit.org/changeset/170578
8339
83402014-06-30  Alex Christensen  <achristensen@webkit.org>
8341
8342        Reduce dynamic memory allocation in css jit.
8343        https://bugs.webkit.org/show_bug.cgi?id=134416
8344
8345        Reviewed by Benjamin Poulain.
8346
8347        * cssjit/FunctionCall.h:
8348        (WebCore::FunctionCall::FunctionCall):
8349        (WebCore::FunctionCall::saveAllocatedCallerSavedRegisters):
8350        * cssjit/RegisterAllocator.h:
8351        * cssjit/SelectorCompiler.cpp:
8352        (WebCore::SelectorCompiler::addPseudoClassType):
8353        (WebCore::SelectorCompiler::SelectorCodeGenerator::generatePrologue):
8354        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
8355        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
8356        Use inlineCapacity template parameter to reduce malloc calls.
8357        I use 16 and 32 as the inline capacity for non-register related vectors because that
8358        is probably big enough for the selector compiler, and if it is not then a malloc
8359        call will not be significant because the selector is very complex.
8360        * cssjit/StackAllocator.h:
8361        (WebCore::StackAllocator::push):
8362        Pass a vector of stack references to match calls to pop and to avoid a call to appendVector.
8363
83642014-06-30  Alex Christensen  <achristensen@webkit.org>
8365
8366        Use non-thumb registers in armv7 css jit.
8367        https://bugs.webkit.org/show_bug.cgi?id=134450
8368
8369        Reviewed by Geoff Garen.
8370
8371        * cssjit/RegisterAllocator.h:
8372        (WebCore::RegisterAllocator::isValidRegister):
8373        (WebCore::RegisterAllocator::isCallerSavedRegister):
8374        Use additional general purpose registers.
8375        * cssjit/SelectorCompiler.cpp:
8376        (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
8377        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
8378        Always succeed when compiling css selectors.
8379
83802014-06-30  Myles C. Maxfield  <mmaxfield@apple.com>
8381
8382        Tiles on bottom of screen are not always allocated when necessary
8383        https://bugs.webkit.org/show_bug.cgi?id=134272
8384
8385        Reviewed by Simon Fraser.
8386
8387        The initial visibleRect is in the coordinate of the root layer, so its origin
8388        is at the top left of the view. The initial rect we were using doesn't
8389        include the contents inset, so it was too short, which was causing tiles near
8390        the bottom of the screen to not always be allocated if the tile threshold was
8391        close to the bottom of the view. Instead, we want to include the contents
8392        inset size so the visible rect includes the entire view.
8393        GraphicsLayerCA::recursiveCommitChanges() takes care of mapping and cropping
8394        the visible rect into the tiled layer's coordinate system, at which point it
8395        is used for visible tile logic.
8396
8397        Test: platform/mac-wk2/tiled-drawing/visible-rect-content-inset.html
8398
8399        * platform/graphics/ca/TileCoverageMap.cpp:
8400        (WebCore::TileCoverageMap::update):
8401        * rendering/RenderLayerCompositor.cpp:
8402        (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
8403
84042014-06-30  Brent Fulgham  <bfulgham@apple.com>
8405
8406        [Win] Unreviewed project gardening.
8407
8408        * WebCore.vcxproj/WebCore.vcxproj: Clean up path information so
8409        files appear in appropriate places in project view.
8410        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
8411
84122014-06-30  Zalan Bujtas  <zalan@apple.com>
8413
8414        Remove redundant repaintCompositedLayers() parameter and its dependencies.
8415        https://bugs.webkit.org/show_bug.cgi?id=134431
8416
8417        Reviewed by Darin Adler.
8418
8419        No change in functionality.
8420
8421        * rendering/RenderLayer.cpp:
8422        (WebCore::RenderLayer::convertToPixelSnappedLayerCoords): Deleted.
8423        (WebCore::RenderLayer::convertToLayerCoords): Deleted.
8424        * rendering/RenderLayer.h:
8425        * rendering/RenderLayerCompositor.cpp:
8426        (WebCore::RenderLayerCompositor::repaintCompositedLayers):
8427        (WebCore::RenderLayerCompositor::recursiveRepaintLayer):
8428        * rendering/RenderLayerCompositor.h:
8429
84302014-06-30  Alex Christensen  <achristensen@webkit.org>
8431
8432        Remove webkit prefix from pointer lock.
8433        https://bugs.webkit.org/show_bug.cgi?id=134312
8434
8435        Reviewed by Dean Jackson.
8436
8437        * dom/Document.cpp:
8438        (WebCore::Document::exitPointerLock):
8439        (WebCore::Document::pointerLockElement):
8440        (WebCore::Document::webkitExitPointerLock): Deleted.
8441        (WebCore::Document::webkitPointerLockElement): Deleted.
8442        * dom/Document.h:
8443        * dom/Document.idl:
8444        * dom/Element.cpp:
8445        (WebCore::Element::requestPointerLock):
8446        (WebCore::Element::webkitRequestPointerLock): Deleted.
8447        * dom/Element.h:
8448        * dom/Element.idl:
8449        * dom/EventNames.h:
8450        * dom/MouseEvent.idl:
8451        * dom/MouseRelatedEvent.h:
8452        (WebCore::MouseRelatedEvent::movementX):
8453        (WebCore::MouseRelatedEvent::movementY):
8454        (WebCore::MouseRelatedEvent::webkitMovementX): Deleted.
8455        (WebCore::MouseRelatedEvent::webkitMovementY): Deleted.
8456        * page/PointerLockController.cpp:
8457        (WebCore::PointerLockController::PointerLockController):
8458        Initialize all data members.
8459        (WebCore::PointerLockController::requestPointerLock):
8460        (WebCore::PointerLockController::didAcquirePointerLock):
8461        (WebCore::PointerLockController::didNotAcquirePointerLock):
8462        (WebCore::PointerLockController::didLosePointerLock):
8463
84642014-06-30  Myles C. Maxfield  <mmaxfield@apple.com>
8465
8466        U16_IS_SURROGATE should not be called with a UChar32
8467        https://bugs.webkit.org/show_bug.cgi?id=134440
8468
8469        Reviewed by Darin Adler.
8470
8471        No new tests because there is no behavior change.
8472
8473        * platform/graphics/mac/ComplexTextController.cpp:
8474        (WebCore::advanceByCombiningCharacterSequence):
8475
84762014-06-30  Ryuan Choi  <ryuan.choi@samsung.com>
8477
8478        [EFL] Remove m_evasObject from Widget
8479        https://bugs.webkit.org/show_bug.cgi?id=134442
8480
8481        Reviewed by Gyuyoung Kim.
8482
8483        Since WebKit1/EFL was dropped, we don't need to keep the m_evasObject
8484        in the Widget.cpp because it's not used for WebKit2/Efl.
8485
8486        * platform/Widget.h:
8487        (WebCore::Widget::evasObject): Deleted.
8488        * platform/efl/ScrollbarEfl.cpp:
8489        Removed WebKit1/Efl specific code which uses m_evasObject.
8490        It will be a dummy until WebKit2/Efl support proper scrollbar implementation.
8491        (WebCore::ScrollbarEfl::ScrollbarEfl):
8492        (WebCore::ScrollbarEfl::~ScrollbarEfl):
8493        (WebCore::ScrollbarEfl::setParent):
8494        (WebCore::ScrollbarEfl::frameRectsChanged):
8495        (WebCore::ScrollbarEfl::invalidate):
8496        (ScrollbarEfl::ScrollbarEfl): Deleted.
8497        (ScrollbarEfl::~ScrollbarEfl): Deleted.
8498        (scrollbarEflEdjeMessage): Deleted.
8499        (ScrollbarEfl::setParent): Deleted.
8500        (ScrollbarEfl::updateThumbPosition): Deleted.
8501        (ScrollbarEfl::updateThumbProportion): Deleted.
8502        (ScrollbarEfl::updateThumbPositionAndProportion): Deleted.
8503        (ScrollbarEfl::frameRectsChanged): Deleted.
8504        (ScrollbarEfl::invalidate): Deleted.
8505        * platform/efl/ScrollbarEfl.h:
8506        Removed unnecessary methods. In addition, applied final, override keyword.
8507        (WebCore::ScrollbarEfl::handleMouseMoveEvent): Deleted.
8508        (WebCore::ScrollbarEfl::handleMouseOutEvent): Deleted.
8509        (WebCore::ScrollbarEfl::handleMousePressEvent): Deleted.
8510        (WebCore::ScrollbarEfl::handleMouseReleaseEvent): Deleted.
8511        * platform/efl/WidgetEfl.cpp:
8512        (WebCore::Widget::Widget):
8513        (WebCore::Widget::setEvasObject): Deleted.
8514
85152014-06-30  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
8516
8517        Fix deprecated warning with bison 3
8518        https://bugs.webkit.org/show_bug.cgi?id=133791
8519
8520        Reviewed by Csaba Osztrogonác.
8521
8522        No new tests because no functional changes.
8523
8524        * css/CSSGrammar.y.in:
8525        * xml/XPathGrammar.y:
8526
85272014-06-30  Jaehun Lim  <ljaehun.lim@samsung.com>
8528
8529        Remove HarfBuzzShaper::setDrawRange()
8530        https://bugs.webkit.org/show_bug.cgi?id=134243
8531
8532        Reviewed by Gyuyoung Kim.
8533
8534        setDrawRange() is not used anywhere. Remove it.
8535        And m_fromIndex and m_toIndex are changed by only setDrawRange().
8536        So remove them too and use the default values instead of them.
8537
8538        No new tests, no behavior changes.
8539
8540        * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
8541        (WebCore::HarfBuzzShaper::HarfBuzzShaper):
8542        (WebCore::HarfBuzzShaper::fillGlyphBufferFromHarfBuzzRun):
8543            currentCharacterIndex is unsigned, always greater than 0. Clean up if statements.
8544        (WebCore::HarfBuzzShaper::setDrawRange): Deleted.
8545        * platform/graphics/harfbuzz/HarfBuzzShaper.h:
8546
85472014-06-29  Pratik Solanki  <psolanki@apple.com>
8548
8549        Create NSURLRequest lazily when USE(CFNETWORK) is enabled
8550        https://bugs.webkit.org/show_bug.cgi?id=134441
8551
8552        Reviewed by Sam Weinig.
8553
8554        No new tests. Should be covered by exsting tests.
8555
8556        * platform/network/cf/ResourceRequest.h:
8557        (WebCore::ResourceRequest::ResourceRequest):
8558        * platform/network/cf/ResourceRequestCFNet.cpp:
8559        (WebCore::ResourceRequest::doUpdatePlatformRequest):
8560        (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
8561        (WebCore::ResourceRequest::setStorageSession):
8562        * platform/network/cocoa/ResourceRequestCocoa.mm:
8563        (WebCore::ResourceRequest::nsURLRequest):
8564
85652014-06-29  Ryuan Choi  <ryuan.choi@samsung.com>
8566
8567        [EFL] Remove netscape plugin implementation from WebCore
8568        https://bugs.webkit.org/show_bug.cgi?id=134438
8569
8570        Reviewed by Gyuyoung Kim.
8571
8572        Because WebKit1/Efl was dropped, PluginPackageEfl.cpp and PluginViewEfl.cpp are not necessary.
8573
8574        * PlatformEfl.cmake:
8575        * plugins/efl/PluginPackageEfl.cpp: Removed.
8576        * plugins/efl/PluginViewEfl.cpp: Removed.
8577        * plugins/x11/PluginViewX11.cpp: Removed.
8578        This file is to share common code between WebKit1/Efl and WebKit1/GTk.
8579        Now, both ports are dropped WebKit1 support and the GTK port already removed the related files at r167016.
8580
85812014-06-29  Yoav Weiss  <yoav@yoav.ws>
8582
8583        Add support for HTMLImageElement's sizes attribute
8584        https://bugs.webkit.org/show_bug.cgi?id=133620
8585
8586        Reviewed by Dean Jackson.
8587
8588        Tests: fast/dom/HTMLImageElement/sizes/image-sizes-1x.html
8589               fast/dom/HTMLImageElement/sizes/image-sizes-2x.html
8590               fast/dom/HTMLImageElement/sizes/image-sizes-js-change.html
8591               fast/dom/HTMLImageElement/sizes/image-sizes-js-innerhtml.html
8592               http/tests/loading/sizes/preload-image-sizes-2x.html
8593               http/tests/loading/sizes/preload-image-sizes.html
8594
8595        This patch adds support for HTMLImageElement's sizes attribute and the
8596        related srcset extended syntax as defined in
8597        http://picture.responsiveimages.org/.
8598        This sizes attribute syntax is added to the CSSGrammar and parsed by
8599        the CSSParser.
8600        The SourceSizeList class is generated by the parser, and used to get
8601        the final source size.
8602        HTMLImageElement and HTMLPreloadScanner send this value to
8603        HTMLSrcsetParser.
8604        HTMLSrcsetParser uses this value in order to pick the right resource.
8605
8606        * CMakeLists.txt: Added css/SourceSizeList.cpp.
8607        * Configurations/FeatureDefines.xcconfig: Added the PICTURE_SIZES flag.
8608        * WebCore.vcxproj/WebCore.vcxproj: Added css/SourceSizeList.*.
8609        * WebCore.vcxproj/WebCore.vcxproj.filters: Added css/SourceSizeList.*.
8610        * WebCore.xcodeproj/project.pbxproj: Added css/SourceSizeList.*.
8611        * css/CSSGrammar.y.in: Added 4 grammar rules that define a Media condition,
8612        Source size list, Source size length and source size.
8613        * css/CSSParser.cpp:
8614        (WebCore::CSSParser::parseSizesAttribute): Parse the sizes attribute.
8615        (WebCore::CSSParser::detectAtToken): Set the token to SIZESATTR.
8616        * css/CSSParser.h:
8617        * css/SourceSizeList.cpp: Added. Defined the SourceSize and SourceSizeList classes.
8618        (WebCore::SourceSize::match):
8619        (WebCore::computeLength):
8620        (WebCore::defaultValue):
8621        (WebCore::SourceSize::length):
8622        (WebCore::SourceSizeList::parseSizesAttribute):
8623        (WebCore::SourceSizeList::getEffectiveSize):
8624        * css/SourceSizeList.h: Added.
8625        (WebCore::SourceSize::SourceSize):
8626        (WebCore::SourceSizeList::append):
8627        * html/HTMLImageElement.cpp: Integrated sizes attribute parsing and added currentSrc.
8628        (WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
8629        (WebCore::HTMLImageElement::parseAttribute):
8630        (WebCore::HTMLImageElement::currentSrc):
8631        * html/HTMLImageElement.h:
8632        * html/HTMLImageElement.idl:
8633        * html/parser/HTMLDocumentParser.cpp: Added information required for sizes parsing to
8634        HTMLPreloadScanner calls.
8635        (WebCore::HTMLDocumentParser::pumpTokenizer):
8636        (WebCore::HTMLDocumentParser::insert):
8637        (WebCore::HTMLDocumentParser::append):
8638        (WebCore::HTMLDocumentParser::appendCurrentInputStreamToPreloadScannerAndScan):
8639        * html/parser/HTMLPreloadScanner.cpp: Integrated sizes attribute parsing.
8640        (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
8641        (WebCore::TokenPreloadScanner::StartTagScanner::processAttribute):
8642        (WebCore::TokenPreloadScanner::scan):
8643        (WebCore::HTMLPreloadScanner::scan):
8644        * html/parser/HTMLPreloadScanner.h:
8645        * html/parser/HTMLSrcsetParser.cpp: Added 'w' descriptor parsing sizes based normalization.
8646        (WebCore::parseDescriptors):
8647        (WebCore::pickBestImageCandidate):
8648        (WebCore::bestFitSourceForImageAttributes):
8649        * html/parser/HTMLSrcsetParser.h:
8650
86512014-06-29  Andreas Kling  <akling@apple.com>
8652
8653        No need to lazily initialize ResourceResponse internals when accessing timing data.
8654        <https://webkit.org/b/134437>
8655        <rdar://problem/17499876>
8656
8657        When building with ENABLE(WEB_TIMING), the last thing that would happen when
8658        serializing a ResourceResponse in the network process is that we'd retrieve
8659        the ResourceLoadTiming to encode it as part of the response. Doing so would
8660        trigger the lazy instantiation of ResourceResponse's internal data structures.
8661
8662        Since timing data is not actually lazily instantiated, we can just not do that.
8663
8664        This shaves off ~550ms of network process main thread time on PLT, reducing
8665        response latency by not doing unnecessary stuff before letting the web process
8666        look at the downloaded data.
8667
8668        Reviewed by Gavin Barraclough.
8669
8670        * WebCore.exp.in:
8671        * platform/network/ResourceResponseBase.cpp:
8672        (WebCore::ResourceResponseBase::adopt):
8673        (WebCore::ResourceResponseBase::resourceLoadTiming): Deleted.
8674        (WebCore::ResourceResponseBase::setResourceLoadTiming): Deleted.
8675        * platform/network/ResourceResponseBase.h:
8676        (WebCore::ResourceResponseBase::resourceLoadTiming):
8677
86782014-06-29  Pratik Solanki  <pratik.solanki@gmail.com>
8679
8680        Refactor ResourceRequest into Cocoa and iOS specific files
8681        https://bugs.webkit.org/show_bug.cgi?id=134430
8682
8683        Reviewed by Andreas Kling.
8684
8685        No new tests because no functional changes.
8686
8687        * WebCore.xcodeproj/project.pbxproj:
8688        * platform/network/cf/ResourceRequestCFNet.cpp:
8689        (WebCore::ResourceRequest::applyWebArchiveHackForMail): Deleted.
8690        * platform/network/cocoa/ResourceRequestCocoa.mm: Copied from Source/WebCore/platform/network/mac/ResourceRequestMac.mm.
8691        (WebCore::ResourceRequest::nsURLRequest):
8692        (WebCore::ResourceRequest::cfURLRequest):
8693        (WebCore::ResourceRequest::doUpdateResourceRequest):
8694        (WebCore::ResourceRequest::doUpdateResourceHTTPBody):
8695        (WebCore::ResourceRequest::doUpdatePlatformRequest):
8696        (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
8697        (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties):
8698        (WebCore::ResourceRequest::applyWebArchiveHackForMail):
8699        (WebCore::ResourceRequest::setStorageSession):
8700        * platform/network/ios/ResourceRequestIOS.mm: Added.
8701        (WebCore::ResourceRequest::useQuickLookResourceCachingQuirks):
8702        (WebCore::ResourceRequest::ResourceRequest):
8703        (WebCore::ResourceRequest::updateNSURLRequest):
8704        * platform/network/mac/ResourceRequestMac.mm:
8705        (WebCore::initQuickLookResourceCachingQuirks):
8706        (WebCore::ResourceRequest::useQuickLookResourceCachingQuirks):
8707        (WebCore::ResourceRequest::ResourceRequest):
8708        (WebCore::ResourceRequest::updateNSURLRequest):
8709        (WebCore::ResourceRequest::applyWebArchiveHackForMail):
8710        (WebCore::ResourceRequest::nsURLRequest): Deleted.
8711        (WebCore::ResourceRequest::cfURLRequest): Deleted.
8712        (WebCore::ResourceRequest::doUpdateResourceRequest): Deleted.
8713        (WebCore::ResourceRequest::doUpdateResourceHTTPBody): Deleted.
8714        (WebCore::ResourceRequest::doUpdatePlatformRequest): Deleted.
8715        (WebCore::ResourceRequest::doUpdatePlatformHTTPBody): Deleted.
8716        (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Deleted.
8717        (WebCore::ResourceRequest::setStorageSession): Deleted.
8718
87192014-06-29  Youenn Fablet  <youenn.fablet@crf.canon.fr>
8720
8721        TextCodecICU::encode turns the whole string as yen signs if there is any backslash in it
8722        https://bugs.webkit.org/show_bug.cgi?id=133678
8723
8724        Reviewed by Alexey Proskuryakov.
8725
8726        Test: fast/encoding/backslash-encoding-jp.html
8727
8728        * platform/text/TextCodecICU.cpp:
8729        (WebCore::TextCodecICU::encode): fixed the copy of characters other than backslash.
8730
87312014-06-28  Dean Jackson  <dino@apple.com>
8732
8733        [iOS] Pinching into a video (fullscreen gesture) leaves page zoomed in
8734        https://bugs.webkit.org/show_bug.cgi?id=134433
8735        <rdar://problem/16630794>
8736
8737        Reviewed by Eric Carlson.
8738
8739        Detect the number of target touches (those directly on the
8740        video element) and disable the page zoom if it looks
8741        like the user is trying to trigger fullscreen.
8742
8743        * Modules/mediacontrols/mediaControlsiOS.js:
8744        (ControllerIOS.prototype.handleBaseGestureStart): If we are seeing
8745        two touches in this video element, don't trigger fullscreen. The
8746        exception is if we haven't yet started playback.
8747        (ControllerIOS.prototype.handleBaseGestureChange): Don't allow fullscreen
8748        if we haven't started playback (iOS 7 behaviour).
8749        (ControllerIOS.prototype.handleWrapperTouchStart): Keep track of the
8750        number of targetted touches.
8751
87522014-06-27  Simon Fraser  <simon.fraser@apple.com>
8753
8754        [iOS WK2] position:fixed inside accelerated overflow:scroll is jumpy
8755        https://bugs.webkit.org/show_bug.cgi?id=134426
8756        <rdar://problem/17474523>
8757
8758        Reviewed by Tim Horton.
8759
8760        After committing a new layer tree (with possibly stale position:fixed layer
8761        positions), we need the scrolling tree to update those positions based on
8762        the current scroll offset.
8763        
8764        Give ScrollingTreeScrollingNode an implementation of updateLayersAfterAncestorChange()
8765        which is required to update fixed/sticky child nodes.
8766
8767        * WebCore.exp.in:
8768        * page/scrolling/ScrollingTreeScrollingNode.cpp:
8769        (WebCore::ScrollingTreeScrollingNode::updateLayersAfterAncestorChange):
8770        * page/scrolling/ScrollingTreeScrollingNode.h:
8771
87722014-06-28  Juan A. Suarez Romero  <jasuarez@igalia.com>  and  Carlos Garcia Campos  <cgarcia@igalia.com>
8773
8774        [GTK] Use public getter/setter in GObject DOM bindings properties implementation.
8775        https://bugs.webkit.org/show_bug.cgi?id=134390.
8776
8777        Reviewed by Carlos Garcia Campos.
8778
8779        The current GObject DOM bindings generator is duplicating code when
8780        implementing the get/set_property methods and the public
8781        getters/setters, instead of making one invoking the other.
8782        
8783        This commit changes this behaviour so the code is not duplicated,
8784        making it easier to maintain.
8785
8786        No new tests needed.
8787
8788        * bindings/scripts/CodeGeneratorGObject.pm:
8789        (GenerateProperty):
8790        (GenerateProperties):
8791        (WriteData):
8792        (GetCoreObject): Deleted.
8793        * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
8794        (webkit_dom_test_active_dom_object_get_property):
8795        * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
8796        (webkit_dom_test_event_constructor_get_property):
8797        * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
8798        (webkit_dom_test_exception_get_property):
8799        * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
8800        (webkit_dom_test_interface_set_property):
8801        (webkit_dom_test_interface_get_property):
8802        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.cpp:
8803        (webkit_dom_test_nondeterministic_set_property):
8804        (webkit_dom_test_nondeterministic_get_property):
8805        * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
8806        (webkit_dom_test_obj_set_property):
8807        (webkit_dom_test_obj_get_property):
8808        * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
8809        (webkit_dom_test_serialized_script_value_interface_get_property):
8810        * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
8811        (webkit_dom_test_typedefs_set_property):
8812        (webkit_dom_test_typedefs_get_property):
8813        * bindings/scripts/test/GObject/WebKitDOMattribute.cpp:
8814        (webkit_dom_test_exception_get_property):
8815        (webkit_dom_attribute_get_property):
8816
88172014-06-28  Radu Stavila  <stavila@adobe.com>
8818
8819        [New Multicolumn] Elements with rounded corners and overflow:hidden do not properly clip their content
8820        https://bugs.webkit.org/show_bug.cgi?id=133941
8821
8822        Reviewed by Darin Adler.
8823
8824        When having a multicol element inside an element with overflow:hidden and border-radius,
8825        the fragments representing the columns need to have the border radius set also, to ensure
8826        proper clipping.
8827
8828        Test: fast/multicol/newmulticol/multicol-clip-rounded-corners.html
8829
8830        * rendering/RenderLayer.cpp:
8831        (WebCore::RenderLayer::collectFragments):
8832
88332014-06-27  Zalan Bujtas  <zalan@apple.com>
8834
8835        Subpixel rendering: Background clipping with subpixel behaves differently when composited.
8836        https://bugs.webkit.org/show_bug.cgi?id=134422
8837
8838        Reviewed by Simon Fraser.
8839
8840        Adjust cliprect with the subpixel offset from the graphics layer the same way we do it for painting.
8841        It ensures that cliprect starts from the right position when graphics layer is not on the same
8842        coordinates as the associated render layer.
8843
8844        Test: compositing/hidpi-compositing-layer-with-subpixel-offset-accumulation-clipping.html
8845
8846        * rendering/RenderLayer.cpp:
8847        (WebCore::RenderLayer::clipToRect):
8848        (WebCore::RenderLayer::paintLayer):
8849        (WebCore::RenderLayer::applyFilters):
8850        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
8851        (WebCore::RenderLayer::paintBackgroundForFragments):
8852        (WebCore::RenderLayer::paintForegroundForFragments):
8853        (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
8854        (WebCore::RenderLayer::paintOutlineForFragments):
8855        (WebCore::RenderLayer::paintMaskForFragments):
8856        (WebCore::RenderLayer::paintOverflowControlsForFragments):
8857        (WebCore::RenderLayer::calculateClipRects):
8858        * rendering/RenderLayer.h:
8859
88602014-06-27  Brent Fulgham  <bfulgham@apple.com>
8861
8862        [Win] Implement parts of the AVFOUNDATION_LOADER_DELEGATE logic for Windows
8863        https://bugs.webkit.org/show_bug.cgi?id=134418
8864
8865        Reviewed by Eric Carlson.
8866
8867        Land an initial implementation of AVFOUNDATION_LOADER_DELEGATE for
8868        Windows.
8869
8870        * DerivedSources.cpp: Add new IDL files
8871        * DerivedSources.make: Add check for AVFOUNDATION_LOADER_DELEGATE.
8872        * Modules/encryptedmedia/CDMPrivateMediaPlayer.cpp: Added (ported from
8873        Objective C.)
8874        * WebCore.vcxproj/WebCore.vcxproj: Update for new files.
8875        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
8876        * WebCore.vcxproj/WebCoreCommon.props: Add new search paths.
8877        * WebCore.vcxproj/WebCoreTestSupport.vcxproj: Update for new files.
8878        * WebCore.vcxproj/WebCoreTestSupport.vcxproj.filters: Ditto.
8879        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
8880        (WebCore::MediaPlayerPrivateAVFoundation::extractKeyURIKeyIDAndCertificateFromInitData):
8881        Moved from MediaPlayerPrivateAVFoundationObjC.
8882        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
8883        * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h:
8884        Update for new API calls.
8885        * platform/graphics/avfoundation/cf/CDMSessionAVFoundationCF.cpp: Added.
8886        * platform/graphics/avfoundation/cf/CDMSessionAVFoundationCF.h: Added.
8887        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
8888        Updated for new AVFOUNDATION_LOADER_DELEGATE methods.
8889        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
8890        * platform/graphics/avfoundation/cf/WebCoreAVCFResourceLoader.cpp: Added.
8891        * platform/graphics/avfoundation/cf/WebCoreAVCFResourceLoader.h: Added.
8892        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
8893        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
8894        Remove method that was moved to base class.
8895
88962014-06-27  Benjamin Poulain  <benjamin@webkit.org>
8897
8898        Remove BufferForAppendingHyphen
8899        https://bugs.webkit.org/show_bug.cgi?id=134376
8900
8901        Reviewed by Darin Adler.
8902
8903        It is legacy, from a time when that code was using a Vector.
8904
8905        The problem is that StringBuilder's memory was also implicitly used to keep
8906        the string alive for the lifespan of the TextRun. That seems quite dangerous
8907        as changes in StringBuilder could have changed that.
8908
8909        To fix the lifetime issue, my first idea was to make it explicit by passing
8910        a String reference to hold the memory alive, and a boolean to say if the text
8911        need an hyphen. The problem with that is this code is very hot and I made things
8912        worse.
8913
8914        The solution with this patch is to just pass a pointer to a String to do both
8915        the buffer reference, and the decision to add the hyphen. Having a single
8916        argument with 2 meanings is not pretty but that's not worse than the old buffer.
8917
8918        * editing/TextIterator.cpp:
8919        * rendering/InlineTextBox.cpp:
8920        (WebCore::InlineTextBox::localSelectionRect):
8921        (WebCore::InlineTextBox::paint):
8922        (WebCore::InlineTextBox::paintSelection):
8923        (WebCore::InlineTextBox::constructTextRun):
8924        (WebCore::adjustCharactersAndLengthForHyphen): Deleted.
8925        * rendering/InlineTextBox.h:
8926        (WebCore::BufferForAppendingHyphen::BufferForAppendingHyphen): Deleted.
8927        * rendering/RenderText.cpp:
8928
89292014-06-27  Jeremy Jones  <jeremyj@apple.com>
8930
8931        Lazily link frameworks in WebVideoFullscreenInterfaceAVKit.
8932        https://bugs.webkit.org/show_bug.cgi?id=134407
8933
8934        Reviewed by Eric Carlson.
8935
8936        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
8937        (-[WebAVPlayerController init]):
8938        Load AVPlayerController on use.
8939        (WebVideoFullscreenInterfaceAVKit::WebVideoFullscreenInterfaceAVKit):
8940        Remove loading on construction.
8941        (WebVideoFullscreenInterfaceAVKit::setCurrentTime): Load AVValueTiming on use.
8942        (WebVideoFullscreenInterfaceAVKit::setupFullscreen): Load several classes on use.
8943        (WebVideoFullscreenInterfaceAVKit::exitFullscreen): Load UIColor on use.
8944
89452014-06-27  Alex Christensen  <achristensen@webkit.org>
8946
8947        Remove extra operations from 64-bit or on armv7.
8948        https://bugs.webkit.org/show_bug.cgi?id=134408
8949
8950        Reviewed by Geoffrey Garen.
8951
8952        * cssjit/SelectorCompiler.cpp:
8953        (WebCore::SelectorCompiler::SelectorCodeGenerator::addFlagsToElementStyleFromContext):
8954        Only do or operations if it would change values.
8955        Often we're only setting one flag, so half the operations are not necessary.
8956
89572014-06-27  Beth Dakin  <bdakin@apple.com>
8958
8959        ScrollView::rootViewToTotalContents() needs to take topContentInset into account
8960        https://bugs.webkit.org/show_bug.cgi?id=134415
8961        -and corresponding-
8962        <rdar://problem/17473633>
8963
8964        Reviewed by Simon Fraser.
8965
8966        This affects hit testing in headers aka PageBanners.
8967
8968        The root view will be anchored above the start of the total contents if there is a 
8969        topContentInset, so the inset value should be subtracted to get into the right 
8970        coordinate space here.
8971        * platform/ScrollView.cpp:
8972        (WebCore::ScrollView::rootViewToTotalContents):
8973
89742014-06-27  Antti Koivisto  <antti@apple.com>
8975
8976        Flush throttling with remote layers
8977        https://bugs.webkit.org/show_bug.cgi?id=134398
8978
8979        Reviewed by Darin Adler.
8980
8981        With remote layer trees the flush scheduling lives in the WebKit2 layer. The throttling code
8982        needs to live there as well.
8983        
8984        Add the required callbacks and disable the existing throttling code in RenderLayerCompositor
8985        when remote layers are in use. Later we can get rid of the RenderLayerCompositor throttling code.
8986
8987        * WebCore.xcodeproj/project.pbxproj:
8988        * loader/FrameLoader.cpp:
8989        (WebCore::FrameLoader::loadProgressingStatusChanged):
8990        * page/ChromeClient.h:
8991        (WebCore::ChromeClient::adjustLayerFlushThrottling):
8992        * page/FrameView.cpp:
8993        (WebCore::FrameView::disableLayerFlushThrottlingTemporarilyForInteraction):
8994        (WebCore::FrameView::loadProgressingStatusChanged):
8995        
8996            Factor the progress status change activities to a function.
8997
8998        (WebCore::FrameView::updateLayerFlushThrottling):
8999        (WebCore::FrameView::setExposedRect):
9000        
9001            Move the call to adjustTiledBackingCoverage from WebKit to here.
9002
9003        (WebCore::FrameView::updateLayerFlushThrottlingInAllFrames): Deleted.
9004        * page/FrameView.h:
9005        * page/LayerFlushThrottleState.h: Added.
9006        * rendering/RenderLayerCompositor.cpp:
9007        (WebCore::RenderLayerCompositor::RenderLayerCompositor):
9008
90092014-06-27  Brady Eidson  <beidson@apple.com>
9010
9011        The user pressing a button on a gamepad should cause gamepads to become visible to all NavigatorGamepads.
9012        https://bugs.webkit.org/show_bug.cgi?id=134375
9013
9014        Reviewed by Darin Adler.
9015
9016        No new tests (Not yet a tested config)
9017
9018        * Modules/gamepad/GamepadManager.cpp:
9019        (WebCore::GamepadManager::platformGamepadConnected): Also call to makeGamepadsVisibileToBlindNavigators.
9020        (WebCore::GamepadManager::platformGamepadDisconnected):
9021        (WebCore::GamepadManager::platformGamepadInputActivity): Call makeGamepadsVisibileToBlindNavigators.
9022        (WebCore::GamepadManager::makeGamepadsVisibileToBlindNavigators): Walk through each blind navigator
9023          notifying it of each connected Gamepad.
9024        (WebCore::GamepadManager::registerNavigator): Also add to the blind navigator set.
9025        (WebCore::GamepadManager::unregisterNavigator): Also remove from the blind navigator set.
9026        * Modules/gamepad/GamepadManager.h:
9027
9028        * platform/GamepadProviderClient.h: Added platformGamepadInputActivity.
9029
9030        * platform/mac/HIDGamepadProvider.cpp:
9031        (WebCore::HIDGamepadProvider::HIDGamepadProvider):
9032        (WebCore::HIDGamepadProvider::valuesChanged): Set the input notification timer which will notify the clients
9033          that a button was pressed.
9034        (WebCore::HIDGamepadProvider::inputNotificationTimerFired): Perform that notification.
9035        * platform/mac/HIDGamepadProvider.h:
9036
90372014-06-27  Brady Eidson  <beidson@apple.com>
9038
9039        HIDGamepads should populate themselves with initial input values
9040        https://bugs.webkit.org/show_bug.cgi?id=134381
9041
9042        Reviewed by Darin Adler.
9043
9044        No new tests (Not yet a tested config)
9045
9046        * platform/mac/HIDGamepad.cpp:
9047        (WebCore::HIDGamepad::getCurrentValueForElement):
9048        (WebCore::HIDGamepad::initElements):  Loop through all the saved elements to get current values.
9049        (WebCore::HIDGamepad::maybeAddButton):
9050        (WebCore::HIDGamepad::maybeAddAxis):
9051        * platform/mac/HIDGamepad.h:
9052        (WebCore::HIDGamepadElement::HIDGamepadElement):
9053        (WebCore::HIDGamepadButton::HIDGamepadButton):
9054        (WebCore::HIDGamepadAxis::HIDGamepadAxis):
9055
90562014-06-27  Peyton Randolph  <prandolph@apple.com>
9057
9058        Add feature flag for link long-press gesture.
9059        https://bugs.webkit.org/show_bug.cgi?id=134262
9060
9061        Reviewed by Enrica Casucci.
9062
9063        * Configurations/FeatureDefines.xcconfig:
9064        Add ENABLE_LINK_LONG_PRESS.
9065
90662014-06-26  Brady Eidson  <beidson@apple.com>
9067
9068        HIDGamepadProvider should only be active when someone is interested in Gamepads.
9069        https://bugs.webkit.org/show_bug.cgi?id=134374
9070
9071        Reviewed by Darin Adler.
9072
9073        No new tests (Not yet a tested config)
9074
9075        * Modules/gamepad/GamepadManager.cpp:
9076        (WebCore::GamepadManager::registerNavigator): Add some logging.
9077        (WebCore::GamepadManager::unregisterNavigator): Ditto.
9078
9079        * platform/mac/HIDGamepadProvider.cpp:
9080        (WebCore::HIDGamepadProvider::HIDGamepadProvider):
9081        (WebCore::HIDGamepadProvider::connectionDelayTimerFired): Stop suppressing connection callbacks
9082        (WebCore::HIDGamepadProvider::openAndScheduleManager):
9083        (WebCore::HIDGamepadProvider::closeAndUnscheduleManager): Stop listening for gamepad events, and clear
9084          all current gamepads.
9085        (WebCore::HIDGamepadProvider::startMonitoringGamepads): If the first client, call openAndScheduleManager
9086        (WebCore::HIDGamepadProvider::stopMonitoringGamepads): If the last client, call closeAndUnscheduleManager
9087        (WebCore::HIDGamepadProvider::deviceAdded): If this callback came while we were suppressing connection
9088          callbacks, it is a startup event for already-connected gamepads. Stop suppressing callbacks in a later
9089          spin of the runloop.
9090        (WebCore::HIDGamepadProvider::deviceRemoved):
9091        * platform/mac/HIDGamepadProvider.h:
9092        (WebCore::HIDGamepadProvider::setShouldDispatchCallbacks): Deleted.
9093
90942014-06-27  Alex Christensen  <achristensen@webkit.org>
9095
9096        Prevent unnecessary register saving in css jit.
9097        https://bugs.webkit.org/show_bug.cgi?id=133955
9098
9099        Reviewed by Geoff Garen.
9100
9101        * cssjit/FunctionCall.h:
9102        (WebCore::FunctionCall::prepareAndCall):
9103        (WebCore::FunctionCall::cleanupPostCall):
9104        (WebCore::FunctionCall::saveAllocatedCallerSavedRegisters):
9105        (WebCore::FunctionCall::restoreAllocatedCallerSavedRegisters):
9106        (WebCore::FunctionCall::saveAllocatedRegisters): Renamed to saveAllocatedCallerSavedRegisters.
9107        (WebCore::FunctionCall::restoreAllocatedRegisters): Renamed to restoreAllocatedCallerSavedRegisters.
9108        Only push caller saved registers before function calls.
9109        * cssjit/RegisterAllocator.h:
9110        (WebCore::RegisterAllocator::isValidRegister):
9111        Corrected register ranges.
9112        (WebCore::RegisterAllocator::isCallerSavedRegister): Added.
9113
91142014-06-27  Beth Dakin  <bdakin@apple.com>
9115
9116        Custom scrollbars should not create ScrollbarPainters on Mac
9117        https://bugs.webkit.org/show_bug.cgi?id=134406
9118        -and corresponding-
9119        <rdar://problem/16178301>
9120
9121        Reviewed by Tim Horton.
9122
9123        The solution here is to return early in ScrollbarThemeMac::registerScrollbar() if 
9124        the scrollbar is custom. However, since this function is called during the 
9125        RenderScrollbar and Scrollbar constructor, we need to re-implement 
9126        Scrollbar::isCustomScrollbar() to return a member variable that is passed into the 
9127        constructor. Otherwise, we will get Scrollbar’s implementation is 
9128        isCustomScrollbar() wrongfully returning false since instead of the derived
9129        class’s implementation. 
9130
9131        Scrollbar constructor now has an option parameter isCustomScrollbar that defaults 
9132        to false. That value is returned by isCustomScrollbar()
9133        * platform/Scrollbar.cpp:
9134        (WebCore::Scrollbar::Scrollbar):
9135        * platform/Scrollbar.h:
9136
9137        Return early if this is a custom scrollbar since the rest of the function deals 
9138        with creating a native scrollbar and getting it in the right state.
9139        * platform/mac/ScrollbarThemeMac.mm:
9140        (WebCore::ScrollbarThemeMac::registerScrollbar):
9141
9142        Send true to the Scrollbar constructor to indicate that this is a custom 
9143        scrollbar.
9144        * rendering/RenderScrollbar.cpp:
9145        (WebCore::RenderScrollbar::RenderScrollbar):
9146        * rendering/RenderScrollbar.h:
9147
91482014-06-27  Eric Carlson  <eric.carlson@apple.com>
9149
9150        [Mac] AVMetadataKeySpaceISOUserData not defined on 10.8
9151        https://bugs.webkit.org/show_bug.cgi?id=134401
9152
9153        Reviewed by Jer Noble.
9154
9155        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
9156        (WebCore::metadataType): Use SOFT_LINK_POINTER_OPTIONAL for AVMetadataKeySpaceISOUserData
9157            so we don't have problems on OS versions where it isn't defined.
9158
91592014-06-27  Martin Hodovan  <mhodovan.u-szeged@partner.samsung.com>
9160
9161        REGRESSION (r168685): css calc() expression fails 
9162        https://bugs.webkit.org/show_bug.cgi?id=134059
9163
9164        The expression 'calc((100% - 20px) / 3' did not work properly after r168685,
9165        because primitiveType() function in CSSCalculationValue.cpp has handled
9166        CalcPercentLength and CalcPercentNumber categories as if they were angles.
9167        The patch fixes this incorrect behavior.
9168
9169        Reviewed by Simon Fraser.
9170
9171        Test: fast/css/calc-percentage-pixel.html
9172
9173        * css/CSSCalculationValue.cpp:
9174
91752014-06-27  Jer Noble  <jer.noble@apple.com>
9176
9177        [MSE] http/tests/media/media-source/mediasource-append-buffer.html is failing
9178        https://bugs.webkit.org/show_bug.cgi?id=134389
9179
9180        Reviewed by Eric Carlson.
9181
9182        Two subtests in mediasource-append-buffer.html are failing. Bring setDuration() up to spec
9183        by throwing an exception if the duration is called while any SourceBuffer is updating. Do
9184        not cancel pending events when a SourceBuffer is removed from its MediaSource. And mark the
9185        SourceBuffer as having pending activity if there are pending events to be fired.
9186
9187        * Modules/mediasource/MediaSource.cpp:
9188        (WebCore::MediaSource::setDuration):
9189        * Modules/mediasource/SourceBuffer.cpp:
9190        (WebCore::SourceBuffer::removedFromMediaSource):
9191        (WebCore::SourceBuffer::hasPendingActivity):
9192
91932014-06-26  Simon Fraser  <simon.fraser@apple.com>
9194
9195        [iOS WK2] Fix touch-scrollable elements with overflow:scroll on just one axis, and RTL scrolling
9196        https://bugs.webkit.org/show_bug.cgi?id=134377
9197        <rdar://problem/16762224>
9198
9199        Reviewed by Tim Horton.
9200        
9201        Make -webkit-overflow-scrolling:touch scrolling work correctly when one axis
9202        has overflow:scroll and the other overflow:hidden. Also fix scrolling in RTL
9203        contexts.
9204        
9205        An RTL scroller with overflow-x:hidden will have a non-zero scroll origin,
9206        and needs to truncate the scrolled content on the left side. To pass the
9207        correct geometry to the UI process, we need to introduce the concept of
9208        "reachable" size as well as total content size; normally these are the same,
9209        but will differ when scrolling is only allowed on one axis but there is overflow
9210        on both axes.
9211        
9212        To get the reachable size, add RenderLayer::scrollableContentsSize().
9213        
9214        RenderLayer::visibleSize() was wrong; the function should return the size of the 
9215        scrollable portion, but used layer size which includes borders. Fix to use pixelSnappedClientWidth()/Height(),
9216        which is what we use for scrollbar computations.
9217
9218        * WebCore.exp.in:
9219        * page/scrolling/AsyncScrollingCoordinator.cpp:
9220        (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
9221        (WebCore::AsyncScrollingCoordinator::updateFrameScrollingNode):
9222        (WebCore::AsyncScrollingCoordinator::updateOverflowScrollingNode):
9223        * page/scrolling/ScrollingCoordinator.h:
9224        * page/scrolling/ScrollingStateScrollingNode.cpp:
9225        (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
9226        (WebCore::ScrollingStateScrollingNode::setReachableContentsSize):
9227        * page/scrolling/ScrollingStateScrollingNode.h:
9228        (WebCore::ScrollingStateScrollingNode::reachableContentsSize):
9229        * page/scrolling/ScrollingTreeScrollingNode.cpp:
9230        (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
9231        * page/scrolling/ScrollingTreeScrollingNode.h:
9232        (WebCore::ScrollingTreeScrollingNode::reachableContentsSize):
9233        * rendering/RenderLayer.cpp:
9234        (WebCore::RenderLayer::visibleSize):
9235        (WebCore::RenderLayer::scrollableContentsSize):
9236        * rendering/RenderLayer.h:
9237        * rendering/RenderLayerCompositor.cpp:
9238        (WebCore::updateScrollingLayerWithClient):
9239        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
9240
92412014-06-27  Bear Travis  <betravis@adobe.com>
9242
9243        [Feature Queries] Fix feature queries build on Mac
9244        https://bugs.webkit.org/show_bug.cgi?id=134359
9245
9246        Reviewed by Antti Koivisto.
9247
9248        Update the XCode project and Feature Queries code to build on Mac.
9249
9250        There are existing tests for supports in the LayoutTests/css3 directory.
9251
9252        * WebCore.xcodeproj/project.pbxproj: Add the Feature Queries files
9253        to the XCode project.
9254        * css/CSSGrammar.y.in: Update CSSParserExpression to CSSParserValueList.
9255        * css/DOMWindowCSS.idl: Add ImplementationLacksVTable metadata.
9256
92572014-06-27  Jer Noble  <jer.noble@apple.com>
9258
9259        [MSE] media/media-source/media-source-tracks.html is crashy
9260        https://bugs.webkit.org/show_bug.cgi?id=134385
9261
9262        Reviewed by Eric Carlson.
9263
9264        Fix the refactoring error (self assignment) introduced by r170488.
9265
9266        * Modules/mediasource/SourceBuffer.cpp:
9267        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):
9268
92692014-06-27  Mark Hahnenberg  <mhahnenberg@apple.com>
9270
9271        XHR should keep attributes on instance
9272        https://bugs.webkit.org/show_bug.cgi?id=134363
9273
9274        Reviewed by Sam Weinig.
9275
9276        Test: js/dom/xhr-prototype-define-property.html
9277
9278        Having them on the prototype broke some sites due to the fact that these DOM attributes are currently 
9279        not configurable. Once we make them configurable, we can move XHR attributes back to the prototype.
9280
9281        * bindings/scripts/CodeGeneratorJS.pm:
9282        (InterfaceRequiresAttributesOnInstanceForCompatibility):
9283
92842014-06-27  Jeremy Jones  <jeremyj@apple.com>
9285
9286        removeCodedFrames should modify ref to TrackBuffer no a copy.
9287        https://bugs.webkit.org/show_bug.cgi?id=134380
9288
9289        Reviewed by Daniel Bates.
9290
9291        * Modules/mediasource/SourceBuffer.cpp:
9292        (WebCore::SourceBuffer::removeCodedFrames):
9293        Iterate with a reference.
9294
92952014-06-27  Zalan Bujtas  <zalan@apple.com>
9296
9297        Set cliprect radius unconditionally in RenderLayer.
9298        https://bugs.webkit.org/show_bug.cgi?id=134396
9299
9300        Reviewed by Simon Fraser.
9301
9302        No change in functionality.
9303
9304        * rendering/RenderLayer.cpp:
9305        (WebCore::RenderLayer::calculateClipRects):
9306
93072014-06-27  Manuel Rego Casasnovas  <rego@igalia.com>
9308
9309        [CSS Grid Layout] Interaction between auto-placement and column / row spanning
9310        https://bugs.webkit.org/show_bug.cgi?id=110633
9311
9312        Reviewed by Sergio Villar Senin.
9313
9314        Modify auto-placement algorithm in order to support span in both
9315        definite and automatic positions.
9316
9317        This patch fixes examples like:
9318        grid-row: auto;
9319        grid-column: 2 / span 3;
9320
9321        And also:
9322        grid-row: auto;
9323        grid-column: span 3;
9324
9325        Tests: fast/css-grid-layout/grid-item-auto-placement-automatic-span.html
9326               fast/css-grid-layout/grid-item-auto-placement-definite-span.html
9327
9328        * rendering/RenderGrid.cpp:
9329        (WebCore::RenderGrid::GridIterator::isEmptyAreaEnough): New method that
9330        checks if a grid area is or not empty.
9331        (WebCore::RenderGrid::GridIterator::nextEmptyGridArea): Updated method
9332        that now receives two arguments with the span value in both directions.
9333        (WebCore::RenderGrid::ensureGridSize): Renamed from gridRow(). Adapted
9334        method to grow in both directions at the same time if needed. It ensures
9335        that the grid is big enough to insert a new item.
9336        (WebCore::RenderGrid::insertItemIntoGrid): Only leave the method that
9337        receives a GridCoordinate. It uses ensureGridSize() before inserting the
9338        item in the grid.
9339        (WebCore::RenderGrid::populateExplicitGridAndOrderIterator): Ensure that
9340        the grid is big enough to place the largest span for auto-positioned
9341        items.
9342        (WebCore::RenderGrid::createEmptyGridAreaAtSpecifiedPositionsOutsideGrid):
9343        New method that returns a GridCoordinate outside current grid with the
9344        requested dimensions.
9345        (WebCore::RenderGrid::placeSpecifiedMajorAxisItemsOnGrid): Adapted
9346        method to calculate the item's span and use the new version of
9347        nextEmptyGridArea(). If an empty area is not found it uses
9348        createEmptyGridAreaAtSpecifiedPositionsOutsideGrid() to place the item.
9349        (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid): Ditto.
9350        (WebCore::RenderGrid::growGrid): Renamed to ensureGridSize().
9351        * rendering/RenderGrid.h: Modify methods headers and add new method
9352        signature.
9353        * rendering/style/GridCoordinate.h:
9354        (WebCore::GridSpan::integerSpan): Add new simple method to return the
9355        span value of a position.
9356        * rendering/style/GridResolvedPosition.cpp:
9357        (WebCore::GridResolvedPosition::resolveGridPositionsFromAutoPlacementPosition):
9358        Implement method to take into account span in auto-placement algorithm.
9359        (WebCore::GridResolvedPosition::adjustGridPositionsFromStyle): Add new
9360        checks related with named grid line spans in auto-positioned items,
9361        which is not allowed according to the spec.
9362        * rendering/style/GridResolvedPosition.h: Update method header.
9363
93642014-06-27  Mahesh Kulkarni  <mahesh.kk@samsung.com>
9365
9366        [XHR] open method must uppercase only standard method types
9367        https://bugs.webkit.org/show_bug.cgi?id=134264
9368
9369        Reviewed by Darin Adler.
9370
9371        As per step-5 of http://xhr.spec.whatwg.org/#the-open()-method only
9372        DELETE, PUT, GET, POST, OPTIONS, HEAD are standard. Use other methods as is without case change.
9373        All tests from w3c-test suite pass http://w3c-test.org/XMLHttpRequest/open-method-case-sensitive.htm.
9374        This merges blink changes from r176592.
9375
9376        Tests: http/tests/xmlhttprequest/xmlhttprequest-open-method-allowed.html
9377               http/tests/xmlhttprequest/xmlhttprequest-open-method-case-insensitive.html
9378
9379        * xml/XMLHttpRequest.cpp:
9380        (WebCore::XMLHttpRequest::uppercaseKnownHTTPMethod):
9381
93822014-06-27  Andre Moreira Magalhaes   <andre.magalhaes@collabora.co.uk>
9383
9384        Increase priority on SharedTimer source.
9385        http://bugs.webkit.org/show_bug.cgi?id=134109
9386
9387        While running webkit on a Debian virtual machine I stumbled upon an issue where JS
9388        setTimeout callbacks were not being properly invoked due to machine limitations and the
9389        usage of a low priority on setTimeout timers.
9390
9391        This patch increases the SharedTimer source priority to use the default glib priority which
9392        fixes the issue, making setTimeout JS calls work properly on the test environment.
9393
9394        Reviewed by Gustavo Noronha Silva.
9395
9396        * platform/gtk/SharedTimerGtk.cpp:
9397        (WebCore::setSharedTimerFireInterval):
9398
93992014-06-27  Zalan Bujtas  <zalan@apple.com>
9400
9401        Remove redundant offsetFromAncestor() call from RenderLayer::localClipRect().
9402        https://bugs.webkit.org/show_bug.cgi?id=134378
9403
9404        Reviewed by Simon Fraser.
9405
9406        No change in functionality.
9407
9408        * rendering/RenderLayer.cpp:
9409        (WebCore::RenderLayer::calculateClipRects):
9410
94112014-06-27  Philippe Normand  <pnormand@igalia.com>
9412
9413        [GTK] 8tracks.com triggers annoying pop-up window/installation of "About protocol source plugin" (GStreamer?)
9414        https://bugs.webkit.org/show_bug.cgi?id=133605
9415
9416        Reviewed by Carlos Garcia Campos.
9417
9418        Don't attempt to load blank URLs with the GStreamer media
9419        player. Those URLs trigger the codec installer which is useless in
9420        this scenario. This patch also renames some of the variables of
9421        the ::load method, as suggested by Carlos.
9422
9423        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
9424        (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
9425        Check video-sink validity before disconnecting its signal handlers.
9426        (WebCore::MediaPlayerPrivateGStreamer::load): Don't load blank
9427        URLs (about:blank).
9428        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
9429        (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
9430        Disconnect repaint handler only if it's valid.
9431
94322014-06-26  Carlos Garcia Campos  <cgarcia@igalia.com>
9433
9434        [GTK] Expose getter and setter functions for attributes named type
9435        https://bugs.webkit.org/show_bug.cgi?id=134300
9436
9437        Reviewed by Martin Robinson.
9438
9439        We skip those because the getter conflicts with the get_type()
9440        function of all GObjects. We should use a different name for them. As
9441        a general rule we use the last word of the class name, something like:
9442
9443          webkit_dom_blob_get_type() -> webkit_dom_blob_get_blob_type()
9444          webkit_dom_event_get_type() -> webkit_dom_event_get_event_type()
9445
9446        It's consistent with other existing DOM methods like
9447        webkit_dom_xpath_result_get_result_type() or webkit_dom_css_value_get_css_value_type().
9448        This patch also adds some exceptions for particular cases.
9449
9450        * bindings/gobject/webkitdom.symbols: Add new public symbols.
9451        * bindings/scripts/CodeGeneratorGObject.pm:
9452        (GetFunctionSigName): Helper function to return the function name
9453        that takes into account all exceptions when generating getters and
9454        setters of attributes named type. Otherwise the name is returned unmodified.
9455        (GenerateFunction): Use GetFunctionSigName().
9456        (GenerateFunctions): Do not skip functions for type attributes.
9457
94582014-06-27  Sungmann Cho  <sungmann.cho@navercorp.com>
9459
9460        Remove unnecessary #include in HistoryController
9461        https://bugs.webkit.org/show_bug.cgi?id=134369
9462
9463        Reviewed by Daniel Bates.
9464
9465        After the landing of https://webkit.org/b/130099, HistoryController doesn't need
9466        WebCore::Settings class. So we can remove the related header.
9467
9468        * loader/HistoryController.cpp:
9469
94702014-06-26  Jeongeun Kim  <je_julie.kim@samsung.com>
9471
9472        REGRESSION (r170287): SVGDocumentExtensions::rebuildElements() called on removed element
9473        https://bugs.webkit.org/show_bug.cgi?id=134304
9474
9475        Reviewed by Daniel Bates.
9476
9477        Roll out <http://trac.webkit.org/170287> (https://bugs.webkit.org/show_bug.cgi?id=134186)
9478        as it led to SVGDocumentExtensions::rebuildElements() being called on an element(s) that
9479        may no longer be in the document.
9480
9481        * dom/ContainerNode.cpp:
9482        (WebCore::ContainerNode::removeChild):
9483        (WebCore::ContainerNode::removeChildren):
9484        * dom/Document.cpp:
9485        (WebCore::Document::commonTeardown):
9486        (WebCore::Document::implicitClose):
9487        * history/CachedFrame.cpp:
9488        (WebCore::CachedFrameBase::restore):
9489        * svg/SVGDocumentExtensions.cpp:
9490        (WebCore::SVGDocumentExtensions::startAnimations):
9491        (WebCore::SVGDocumentExtensions::pauseAnimations):
9492        (WebCore::SVGDocumentExtensions::unpauseAnimations):
9493        (WebCore::SVGDocumentExtensions::dispatchSVGLoadEventToOutermostSVGElements):
9494        (WebCore::SVGDocumentExtensions::rebuildElements):
9495        * svg/SVGDocumentExtensions.h:
9496
94972014-06-26  Tim Horton  <timothy_horton@apple.com>
9498
9499        [WK2] Pinch-zoom shadows can overlap headers and footers
9500        https://bugs.webkit.org/show_bug.cgi?id=134372
9501        <rdar://problem/16004095>
9502
9503        Reviewed by Simon Fraser.
9504
9505        * WebCore.exp.in:
9506        * rendering/RenderLayerCompositor.cpp:
9507        (WebCore::RenderLayerCompositor::updateLayerForHeader):
9508        (WebCore::RenderLayerCompositor::updateLayerForFooter):
9509        Put header/footer layers in front of the root content layer instead of behind.
9510        Ideally nothing would ever overlap them, but this will give them precedence regardless.
9511
95122014-06-26  David Kilzer  <ddkilzer@apple.com>
9513
9514        [Win] Always NULL-terminate the string in createUTF8String()
9515        <http://webkit.org/b/134353>
9516        <rdar://problem/17471783>
9517
9518        Reviewed by Brent Fulgham.
9519
9520        * plugins/PluginView.cpp:
9521        (WebCore::createUTF8String): Pull out CString length into local
9522        variable.  Switch to use memcpy.  Always NULL-terminate the
9523        string.
9524
95252014-06-26  Jer Noble  <jer.noble@apple.com>
9526
9527        [MSE][Mac] Crash in WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered const + 13
9528        https://bugs.webkit.org/show_bug.cgi?id=134367
9529
9530        Reviewed by Darin Adler.
9531
9532        Add a couple of null-checks to protect against methods being called in the brief time
9533        between when the object is created and when it's asked to load.
9534
9535        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
9536        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::durationDouble):
9537        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered):
9538
95392014-06-26  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
9540
9541        Rearrange conditions to find invalid protocol in NavigatorContentUtils::verifyProtocolHandlerScheme()
9542        https://bugs.webkit.org/show_bug.cgi?id=134289
9543
9544        Reviewed by Darin Adler.
9545
9546        If we do early return when there is invalid protocol, we're able to avoid unnecessary call flow.
9547
9548        No new tests, covered by existing tests.
9549
9550        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
9551        (WebCore::verifyProtocolHandlerScheme):
9552
95532014-06-26  Benjamin Poulain  <bpoulain@apple.com>
9554
9555        [WK1] Use native touch event's timestamp for DOM touch event
9556        https://bugs.webkit.org/show_bug.cgi?id=134326
9557
9558        Reviewed by Enrica Casucci.
9559
9560        * platform/ios/PlatformEventFactoryIOS.mm:
9561        (WebCore::PlatformTouchEventBuilder::PlatformTouchEventBuilder):
9562        Use device event timestamp to get more accurate timing information. This also removes
9563        the variance introduced by WebKit when computing velocity/acceleration/etc.
9564
95652014-06-26  Balazs Kelemen  <b.kelemen@samsung.com>
9566
9567        Memcache migth not be pruned when it should for https pages
9568        https://bugs.webkit.org/show_bug.cgi?id=134361
9569
9570        Reviewed by Geoffrey Garen.
9571
9572        There is no reason we should not try to prune in case of a https resource.
9573
9574        No observable change in behavior, no tests.
9575
9576        * loader/cache/CachedResource.cpp:
9577        (WebCore::CachedResource::removeClient):
9578        Call prune unconditionally and remove an unnecessary branch.
9579
95802014-06-26  Alexey Proskuryakov  <ap@apple.com>
9581
9582        REGRESSION: Mountain Lion: Gmail's "in new window" view of mail threads is very slow to load its content
9583        https://bugs.webkit.org/show_bug.cgi?id=133882
9584        <rdar://problem/17271965>
9585
9586        Reviewed by Brady Eidson.
9587
9588        This goes to pre-r161796 behavior on 10.8 and 10.9. We schedule the requests internally,
9589        and only give 6 of them to CFNetwork at a time. Except for synchronous requests,
9590        which still use the improved approach, and don't count against 6 connections.
9591
9592        * loader/ResourceLoadScheduler.cpp:
9593        (WebCore::ResourceLoadScheduler::scheduleLoad):
9594        * platform/network/cf/ResourceRequest.h:
9595        (WebCore::ResourceRequest::resourcePrioritiesEnabled):
9596        * platform/network/cf/ResourceRequestCFNet.cpp:
9597        (WebCore::ResourceRequest::doUpdatePlatformRequest):
9598        (WebCore::ResourceRequest::doUpdateResourceRequest):
9599        (WebCore::initializeMaximumHTTPConnectionCountPerHost): Deleted.
9600        * platform/network/mac/ResourceRequestMac.mm:
9601        (WebCore::ResourceRequest::doUpdateResourceRequest):
9602        (WebCore::ResourceRequest::doUpdatePlatformRequest):
9603
96042014-06-26  Brady Eidson  <beidson@apple.com>
9605
9606        Remove use of PlatformStrategies for Gamepad API.
9607        https://bugs.webkit.org/show_bug.cgi?id=134348
9608
9609        Reviewed by Dean Jackson.
9610
9611        No new tests (Not yet a tested config)
9612
9613        Introduce a virtual GamepadProvider with a process-global shared provider.
9614        The base implementation of the GamepadProvider does nothing.
9615        * platform/GamepadProvider.cpp: Renamed from Source/WebKit/mac/WebCoreSupport/WebHIDGamepadController.h.
9616        (WebCore::GamepadProvider::shared):
9617        (WebCore::GamepadProvider::setSharedProvider):
9618        (WebCore::GamepadProvider::startMonitoringGamepads):
9619        (WebCore::GamepadProvider::stopMonitoringGamepads):
9620        (WebCore::GamepadProvider::platformGamepads):
9621        * platform/GamepadProvider.h: Renamed from Source/WebCore/platform/GamepadStrategy.h.
9622        (WebCore::GamepadProvider::~GamepadProvider):
9623
9624        * platform/GamepadProviderClient.h: Renamed from Source/WebCore/platform/GamepadStrategyClient.h.
9625        (WebCore::GamepadProviderClient::~GamepadProviderClient):
9626
9627        GamepadManager is now a GamepadProviderClient:
9628        * Modules/gamepad/GamepadManager.cpp:
9629        (WebCore::GamepadManager::GamepadManager):
9630        (WebCore::GamepadManager::registerNavigator):
9631        (WebCore::GamepadManager::unregisterNavigator):
9632        * Modules/gamepad/GamepadManager.h:
9633
9634        Remove the GamepadStrategy altogether:
9635        * platform/PlatformStrategies.h:
9636        (WebCore::PlatformStrategies::PlatformStrategies):
9637        (WebCore::PlatformStrategies::gamepadStrategy): Deleted.
9638
9639        Call to the shared GamepadProvider instead of the strategy:
9640        * Modules/gamepad/NavigatorGamepad.cpp:
9641        (WebCore::NavigatorGamepad::gamepads):
9642        (WebCore::NavigatorGamepad::gamepadsBecameVisible):
9643        (WebCore::NavigatorGamepad::gamepadConnected):
9644
9645        HIDGamepadListener is now a subclass of GamepadProvider that implements the HID based management.
9646        LegacyWebKit on Mac will install the shared HIDGamepadProvider instead of the default GamepadProvider:
9647        * platform/mac/HIDGamepadProvider.cpp: Renamed from Source/WebCore/platform/mac/HIDGamepadListener.cpp.
9648        (WebCore::deviceMatchingDictionary):
9649        (WebCore::deviceAddedCallback):
9650        (WebCore::deviceRemovedCallback):
9651        (WebCore::deviceValuesChangedCallback):
9652        (WebCore::HIDGamepadProvider::shared):
9653        (WebCore::HIDGamepadProvider::HIDGamepadProvider):
9654        (WebCore::HIDGamepadProvider::indexForNewlyConnectedDevice):
9655        (WebCore::HIDGamepadProvider::startMonitoringGamepads):
9656        (WebCore::HIDGamepadProvider::stopMonitoringGamepads):
9657        (WebCore::HIDGamepadProvider::deviceAdded):
9658        (WebCore::HIDGamepadProvider::deviceRemoved):
9659        (WebCore::HIDGamepadProvider::valuesChanged):
9660        (WebCore::HIDGamepadProvider::removeGamepadForDevice):
9661        * platform/mac/HIDGamepadProvider.h: Renamed from Source/WebCore/platform/mac/HIDGamepadListener.h.
9662        (WebCore::HIDGamepadProvider::platformGamepads):
9663        (WebCore::HIDGamepadProvider::setShouldDispatchCallbacks):
9664
9665        * WebCore.exp.in:
9666        * WebCore.xcodeproj/project.pbxproj:
9667
9668        * platform/mac/HIDGamepad.h: Fix incorrect comment
9669
96702014-06-26  Andreas Kling  <akling@apple.com>
9671
9672        Skip memcmp()ing fully downloaded resources after they become mmap()able.
9673        <https://webkit.org/b/134362>
9674
9675        When we receive word that a downloaded resource is now available for mmap()ing
9676        from the file system, we don't need to compare against the buffered data,
9677        since even if there were a mismatch, the cached version should be the canonical one.
9678
9679        This was added as belt-and-suspenders while the supporting mechanism was being
9680        developed in CFNetwork, and there's no evidence of a race today. This change
9681        turns the runtime checks into debug-only assertions.
9682
9683        Saves ~300ms of main thread time on PLT.
9684
9685        Reviewed by Geoff Garen.
9686
9687        * loader/cache/CachedResource.cpp:
9688        (WebCore::CachedResource::tryReplaceEncodedData):
9689
96902014-06-26  Jer Noble  <jer.noble@apple.com>
9691
9692        [MSE] Refactoring: Use C++11 for-loops in SourceBuffer.
9693        https://bugs.webkit.org/show_bug.cgi?id=134352
9694
9695        Reviewed by Darin Adler.
9696
9697        Use C++11 style for-loops where appropriate in SourceBuffer now that the
9698        SampleMap ordered objects support them.
9699
9700        * Modules/mediasource/SourceBuffer.cpp:
9701        (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime):
9702        (WebCore::SourceBuffer::sourceBufferPrivateFastSeekTimeForMediaTime):
9703        (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete):
9704        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):
9705        (WebCore::SourceBuffer::validateInitializationSegment):
9706        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
9707
97082014-06-25  Joseph Pecoraro  <pecoraro@apple.com>
9709 
9710        [iOS]: Tapping <button> outside of a form is no longer working
9711        https://bugs.webkit.org/show_bug.cgi?id=134319
9712        <rdar://problem/17213346>
9713
9714        Reviewed by Daniel Bates.
9715
9716        Restore behavior of allowing <button> clicks outside of <form>.
9717        This used to be iOS behavior before it was removed in favor of the
9718        OpenSource (Android?) behavior. Now, willRespondToMouseClickEvents
9719        is only used by iOS, so lets restore the iOS behavior.
9720
9721        * html/HTMLButtonElement.cpp:
9722        (WebCore::HTMLButtonElement::willRespondToMouseClickEvents):
9723
97242014-06-26  Jer Noble  <jer.noble@apple.com>
9725
9726        Unreviewed build-fix. Remove unintentionial rename of MediaTime.h -> MediaTimeHash.h.
9727
9728        * Modules/mediasource/SampleMap.h:
9729
97302014-06-26  Eric Carlson  <eric.carlson@apple.com>
9731
9732        [iOS] no need to deactivate audio session
9733        https://bugs.webkit.org/show_bug.cgi?id=134350
9734
9735        Reviewed by Jer Noble.
9736
9737        * platform/audio/mac/MediaSessionManagerMac.cpp:
9738        (MediaSessionManager::updateSessionState): Don't bother calling 
9739            AudioSession::setActive(false), WebCore's audio session will be deactivated 
9740            automatically if another application begins playing audio.
9741
97422014-06-26  Jer Noble  <jer.noble@apple.com>
9743
9744        [MSE] Refactoring: Differentiate between SampleMap decode and presentation order methods
9745        https://bugs.webkit.org/show_bug.cgi?id=134349
9746
9747        Reviewed by Geoffrey Garen.
9748
9749        Refactor SampleMap to clarify the distinction between methods which return decode-order
9750        iterators and ones which retun presentation-order iterators.
9751
9752        Add two classes, PresentationOrderSampleMap and DecodeOrderSampleMap, to contain the actual
9753        MediaTime-to-Sample maps, and move the methods returning presentation-order and decode-order
9754        iterators to each, respectively.  Rename the {presentation,decode}{Begin,End}() methods to
9755        begin() and end() so the objects can be used in C++11 for-loops.
9756
9757        Update all the call sites in SourceBuffer to use the new ordered objects.
9758
9759        * Modules/mediasource/SampleMap.cpp:
9760        (WebCore::SampleIsLessThanMediaTimeComparator::operator()): Use new ordered objects.
9761        (WebCore::SampleIsGreaterThanMediaTimeComparator::operator()): Ditto.
9762        (WebCore::SampleMap::clear): Ditto.
9763        (WebCore::SampleMap::addSample): Ditto.
9764        (WebCore::SampleMap::removeSample): Ditto.
9765        (WebCore::PresentationOrderSampleMap::findSampleContainingPresentationTime): Renamed from SampleMap version.
9766        (WebCore::PresentationOrderSampleMap::findSampleAfterPresentationTime): Ditto.
9767        (WebCore::DecodeOrderSampleMap::findSampleWithDecodeTime): Ditto.
9768        (WebCore::PresentationOrderSampleMap::reverseFindSampleContainingPresentationTime): Ditto.
9769        (WebCore::PresentationOrderSampleMap::reverseFindSampleBeforePresentationTime): Ditto.
9770        (WebCore::DecodeOrderSampleMap::reverseFindSampleWithDecodeTime): Ditto.
9771        (WebCore::DecodeOrderSampleMap::findSyncSamplePriorToPresentationTime): Ditto.
9772        (WebCore::DecodeOrderSampleMap::findSyncSamplePriorToDecodeIterator): Ditto.
9773        (WebCore::DecodeOrderSampleMap::findSyncSampleAfterPresentationTime): Ditto.
9774        (WebCore::DecodeOrderSampleMap::findSyncSampleAfterDecodeIterator): Ditto.
9775        (WebCore::PresentationOrderSampleMap::findSamplesBetweenPresentationTimes): Ditto.
9776        (WebCore::PresentationOrderSampleMap::findSamplesWithinPresentationRange): Ditto.
9777        (WebCore::DecodeOrderSampleMap::findDependentSamples): Ditto.
9778        * Modules/mediasource/SampleMap.h:
9779        (WebCore::PresentationOrderSampleMap::begin): Renamed from presentationBegin().
9780        (WebCore::PresentationOrderSampleMap::end): Renamed from presentationEnd().
9781        (WebCore::PresentationOrderSampleMap::rbegin): Renamed from reversePresentationBegin().
9782        (WebCore::PresentationOrderSampleMap::rend): Renamed from reversePresentationEnd().
9783        (WebCore::DecodeOrderSampleMap::begin): Renamed from decodeBegin().
9784        (WebCore::DecodeOrderSampleMap::end): Renamed from decodeEnd().
9785        (WebCore::DecodeOrderSampleMap::rbegin): Renamed from reverseDecodeBegin().
9786        (WebCore::DecodeOrderSampleMap::rend): Renamed from reverseDecodeEnd().
9787        (WebCore::SampleMap::SampleMap): Create new ordered objects.
9788        (WebCore::SampleMap::sizeInBytes): Use new ordered objects.
9789        (WebCore::SampleMap::decodeOrder): Simple accessor.
9790        (WebCore::SampleMap::presentationOrder): Simple accessor.
9791        * Modules/mediasource/SourceBuffer.cpp:
9792        (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime): Use new ordered objects.
9793        (WebCore::SourceBuffer::sourceBufferPrivateFastSeekTimeForMediaTime): Ditto.
9794        (WebCore::SourceBuffer::removeCodedFrames): Ditto.
9795        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto.
9796        (WebCore::SourceBuffer::bufferedSamplesForTrackID): Ditto.
9797
97982014-06-26  Chris Fleizach  <cfleizach@apple.com>
9799
9800        Add an undo group for each dictated utterance in WebKit
9801        https://bugs.webkit.org/show_bug.cgi?id=134086
9802
9803        Applied review comments from Sam Weinig.
9804
9805        Move the associated USE #define into Platform.h.
9806 
9807        * WebCore.xcodeproj/project.pbxproj:
9808        * editing/mac/TextUndoInsertionMarkup.h: Removed.
9809        * editing/mac/TextUndoInsertionMarkupMac.h:
9810
98112014-06-26  Shivakumar JM  <shiva.jm@samsung.com>
9812
9813        [EFL][WK2] Fix Debug Build Error in Webcore module.
9814        https://bugs.webkit.org/show_bug.cgi?id=134345
9815
9816        Reviewed by Zalan Bujtas.
9817
9818        Use static cast to change the type of variable to fix error
9819
9820        * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
9821        (WebCore::HarfBuzzShaper::setDrawRange):
9822
98232014-06-26  Eric Carlson  <eric.carlson@apple.com>
9824
9825        [Mac] allow host application to canonicalize media urls
9826        https://bugs.webkit.org/show_bug.cgi?id=134329
9827
9828        Reviewed by Dean Jackson.
9829
9830        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
9831        (WebCore::canonicalURL): New, use NSURLProtocol to canonicalize a URL.
9832        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Call canonicalURL.
9833
98342014-06-26  Carlos Garcia Campos  <cgarcia@igalia.com>
9835
9836        [GTK] Add padding for future expansion to WebKitDOMEventTargetIface
9837        https://bugs.webkit.org/show_bug.cgi?id=134298
9838
9839        Reviewed by Martin Robinson.
9840
9841        * bindings/gobject/WebKitDOMEventTarget.h:
9842
98432014-06-25  Carlos Garcia Campos  <cgarcia@igalia.com>
9844
9845        [GTK] Add support for constants in GObject DOM bindings
9846        https://bugs.webkit.org/show_bug.cgi?id=133983
9847
9848        Reviewed by Martin Robinson.
9849
9850        * bindings/gobject/webkitdom.symbols: Add stable constants.
9851        * bindings/scripts/CodeGeneratorGObject.pm:
9852        (GenerateHeader): Add constants to the header.
9853        (Generate): Pass the interface object to GenerateHeader to get the constants
9854        (IsInterfaceSymbol): Helper function that returns whether the given
9855        symbol belongs to the interface. Check also constants now.
9856        (ReadStableSymbols): Use IsInterfaceSymbol().
9857        * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
9858        * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
9859
98602014-06-26  Manuel Rego Casasnovas  <rego@igalia.com>
9861
9862        [CSS Grid Layout] Properly support for z-index on grid items
9863        https://bugs.webkit.org/show_bug.cgi?id=103329
9864
9865        Reviewed by Benjamin Poulain.
9866
9867        From Blink r157620 by <jchaffraix@chromium.org> and r172402 by
9868        <wangxianzhu@chromium.org>.
9869
9870        The specification says that grid should match flexbox and force
9871        grid items to be stacking context if z-index is set, regardless
9872        of 'position'. After this change, this is what happens.
9873
9874        Previously z-index changes of static positioned objects were ignored.
9875        However, z-index is applicable for some static positioned objects,
9876        such as grid items. Ignoring them makes the object not to be properly
9877        painted on z-index change.
9878
9879        As StyleResolver has ensured that z-index is non-auto only if
9880        applicable, RenderStyle::changeRequiresLayerRepaint() should not check
9881        again (with inconsistent conditions).
9882
9883        Tests: fast/css-grid-layout/grid-item-z-index-change-repaint.html
9884               fast/css-grid-layout/grid-item-z-index-stacking-context.html
9885               fast/css-grid-layout/grid-item-z-index-support.html
9886
9887        * css/StyleResolver.cpp:
9888        (WebCore::isDisplayFlexibleOrGridBox): Add new method to check if parent
9889        display is flexbox or grid.
9890        (WebCore::StyleResolver::adjustRenderStyle): Use new method in z-index
9891        condition.
9892        * rendering/style/RenderStyle.cpp:
9893        (WebCore::RenderStyle::changeRequiresLayerRepaint): Move z-index checks
9894        out of non-static positioned objects if.
9895
98962014-06-25  Dean Jackson  <dino@apple.com>
9897
9898        HIDGamepad should use CFIndex when looping
9899        https://bugs.webkit.org/show_bug.cgi?id=134337
9900
9901        Reviewed by Dan Bernstein.
9902
9903        * platform/mac/HIDGamepad.cpp:
9904        (WebCore::HIDGamepad::initElementsFromArray): Replace int with CFIndex, and use
9905        a local variable for CFArrayCount.
9906
99072014-06-25  Ryosuke Niwa  <rniwa@webkit.org>
9908
9909        Build fix attempt after r170465.
9910
9911        * platform/mac/HIDGamepad.cpp:
9912        (WebCore::HIDGamepad::initElementsFromArray):
9913
99142014-06-25  Dean Jackson  <dino@apple.com>
9915
9916        [Mac] Radio buttons and checkboxes vanish when redrawn
9917        https://bugs.webkit.org/show_bug.cgi?id=134335
9918
9919        Reviewed by Dan Bernstein.
9920
9921        I screwed up when landing r170343 by moving some code around
9922        which broke the logic. We need to query the animation
9923        state for controls after we draw (both statically and animated).
9924
9925        * platform/mac/ThemeMac.mm:
9926        (WebCore::paintToggleButton): We need to check the state of animation again, after
9927        we draw.
9928
99292014-06-25  Brady Eidson  <beidson@apple.com>
9930
9931        Add HID-based gamepad implementation for Mac
9932        https://bugs.webkit.org/show_bug.cgi?id=134324
9933
9934        Reviewed by Dean Jackson.
9935
9936        No new tests (Not yet a tested config)
9937
9938        * Modules/gamepad/Gamepad.cpp:
9939        (WebCore::Gamepad::Gamepad):
9940        (WebCore::Gamepad::updateFromPlatformGamepad): Update the Gamepad’s data from the passed-in PlatformGamepad.
9941        * Modules/gamepad/Gamepad.h:
9942
9943        * Modules/gamepad/GamepadButton.h:
9944        (WebCore::GamepadButton::create): Change to use Ref instead of RefPtr.
9945
9946        GamepadManager is a GamepadStrategyClient that receives notifications from the platform gamepad implementation
9947        and forwards them to NavigatorGamepad objects. In the future it will also handle event dispatch and exposing
9948        gamepads to the API layer when a button is pressed:
9949        * Modules/gamepad/GamepadManager.cpp: Added.
9950        (WebCore::GamepadManager::shared):
9951        (WebCore::GamepadManager::GamepadManager):
9952        (WebCore::GamepadManager::platformGamepadConnected):
9953        (WebCore::GamepadManager::platformGamepadDisconnected):
9954        (WebCore::GamepadManager::registerNavigator):
9955        (WebCore::GamepadManager::unregisterNavigator):
9956        * Modules/gamepad/GamepadManager.h:
9957
9958        The NavigatorGamepad supplement actually manages visibility of Gamepads on a per-DOMWindow basis:
9959        * Modules/gamepad/NavigatorGamepad.cpp:
9960        (WebCore::NavigatorGamepad::NavigatorGamepad):
9961        (WebCore::NavigatorGamepad::~NavigatorGamepad):
9962        (WebCore::NavigatorGamepad::from):
9963        (WebCore::NavigatorGamepad::gamepads):
9964        (WebCore::NavigatorGamepad::gamepadsBecameVisible):
9965        (WebCore::NavigatorGamepad::gamepadConnected):
9966        (WebCore::NavigatorGamepad::gamepadDisconnected):
9967        * Modules/gamepad/NavigatorGamepad.h:
9968        (WebCore::NavigatorGamepad::navigationStart):
9969
9970        HIDGamepad is a PlatformGamepad that wraps an IOHIDDeviceRef and keeps input values updated:
9971        * platform/mac/HIDGamepad.cpp: Added.
9972        (WebCore::HIDGamepad::HIDGamepad):
9973        (WebCore::HIDGamepad::initElements):
9974        (WebCore::HIDGamepad::initElementsFromArray):
9975        (WebCore::HIDGamepad::maybeAddButton):
9976        (WebCore::HIDGamepad::maybeAddAxis):
9977        (WebCore::HIDGamepad::valueChanged):
9978        * platform/mac/HIDGamepad.h: Added.
9979        (WebCore::HIDGamepadElement::HIDGamepadElement):
9980        (WebCore::HIDGamepadElement::~HIDGamepadElement):
9981        (WebCore::HIDGamepadElement::isButton):
9982        (WebCore::HIDGamepadElement::isAxis):
9983        (WebCore::HIDGamepadButton::HIDGamepadButton):
9984        (WebCore::HIDGamepadAxis::HIDGamepadAxis):
9985        (WebCore::HIDGamepad::hidDevice):
9986
9987        HIDGamepadListener wraps an IOHIDManagerRef and continuously listens for changes to Gamepad-type
9988        devices plugged in to the system:
9989        * platform/mac/HIDGamepadListener.cpp: Added.
9990        (WebCore::deviceMatchingDictionary):
9991        (WebCore::deviceAddedCallback):
9992        (WebCore::deviceRemovedCallback):
9993        (WebCore::deviceValuesChangedCallback):
9994        (WebCore::HIDGamepadListener::shared):
9995        (WebCore::HIDGamepadListener::HIDGamepadListener):
9996        (WebCore::HIDGamepadListener::indexForNewlyConnectedDevice):
9997        (WebCore::HIDGamepadListener::deviceAdded):
9998        (WebCore::HIDGamepadListener::deviceRemoved):
9999        (WebCore::HIDGamepadListener::valuesChanged):
10000        (WebCore::HIDGamepadListener::removeGamepadForDevice):
10001        * platform/mac/HIDGamepadListener.h: Copied from Source/WebCore/Modules/gamepad/NavigatorGamepad.cpp.
10002        (WebCore::HIDGamepadListenerClient::~HIDGamepadListenerClient):
10003        (WebCore::HIDGamepadListener::setClient):
10004        (WebCore::HIDGamepadListener::platformGamepads):
10005        (WebCore::HIDGamepadListener::setShouldDispatchCallbacks):
10006
10007        * WebCore.exp.in:
10008        * WebCore.xcodeproj/project.pbxproj:
10009
100102014-06-25  Ryosuke Niwa  <rniwa@webkit.org>
10011
10012        WebProgressTracker updates progress too frequently
10013        https://bugs.webkit.org/show_bug.cgi?id=134185
10014
10015        Reviewed by Tim Horton.
10016
10017        The old code throttled the progress update to when either 100ms has passed or the delta is at least 2%
10018        but this was still not enough in pages that loaded in sub-seconds. The new code always throttles it at 200ms.
10019
10020        * loader/ProgressTracker.cpp:
10021        (WebCore::ProgressTracker::ProgressTracker):
10022        (WebCore::ProgressTracker::incrementProgress):
10023        * loader/ProgressTracker.h:
10024
100252014-06-25  Simon Fraser  <simon.fraser@apple.com>
10026
10027        [iOS WK2] Fixed position elements jump around when zooming
10028        https://bugs.webkit.org/show_bug.cgi?id=134328
10029        <rdar://problem/17447048>
10030
10031        Reviewed by Zalan Bujtas.
10032
10033        If a given remote layer tree commit contains changes of layers for viewport-constrained
10034        objects, then the associated scrolling tree also needs to show that the layers changed,
10035        since we need to re-run the "viewport changed" logic in the UI process to get the
10036        layers correctly positioned for the current zoom level.
10037        
10038        The bug was that page scale changes resulted in small "pixel alignment" position
10039        changes which touched layers, but we didn't commit any scrolling tree changes. So
10040        the scrolling tree commit would result in visibly stale layer positions, with no scrolling tree
10041        update to adjust them for the current transient zoom.
10042
10043        Fix by making use of the existing "alignment offset" field in the ViewportConstraints
10044        data, and having RemoteScrollingCoordinatorProxy::connectStateNodeLayers() note that
10045        fixed or sticky layers changed if any properties of fixed or sticky scrolling tree
10046        nodes were updated.
10047
10048        * page/scrolling/ScrollingConstraints.h:
10049        (WebCore::StickyPositionViewportConstraints::operator==):
10050        * platform/graphics/GraphicsLayer.h:
10051        (WebCore::GraphicsLayer::pixelAlignmentOffset):
10052        * platform/graphics/ca/GraphicsLayerCA.cpp:
10053        (WebCore::GraphicsLayerCA::updateGeometry):
10054        * platform/graphics/ca/GraphicsLayerCA.h:
10055        * rendering/RenderLayerCompositor.cpp:
10056        (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
10057        (WebCore::RenderLayerCompositor::computeStickyViewportConstraints):
10058
100592014-06-25  Simon Fraser  <simon.fraser@apple.com>
10060
10061        [iOS WK2] Tweak the logic used to choose the scale at which position:fixed gets pushed out of view
10062        https://bugs.webkit.org/show_bug.cgi?id=134323
10063
10064        Reviewed by Benjamin Poulain.
10065
10066        Previously we used a fixed scale (1.2x) at which we'd start pushing position:fixed elements
10067        out of the viewport. This worked well on iPad, but terribly on iPhone. Instead, choose a scale
10068        relative to how much of the page is visible width-wise, the threshold being 2/3 of the page width.
10069        The width is clamped to get reasonable behavior on wide pages.
10070
10071        * page/FrameView.cpp:
10072        (WebCore::FrameView::rectForViewportConstrainedObjects):
10073
100742014-06-25  Brady Eidson  <beidson@apple.com>
10075
10076        Add new platform gamepad abstractions
10077        https://bugs.webkit.org/show_bug.cgi?id=134325
10078
10079        Reviewed by Dean Jackson.
10080
10081        No new tests (Not yet a tested config)
10082
10083        - GamepadStrategy lets ports customize the 3 basic behaviors needed for a gamepad
10084          implementation to feed the API in WebCore.
10085        - GamepadStrategyClient gives arbitrary objects in WebCore the ability to register
10086          for callbacks with the GamepadStrategy.
10087        - PlatformGamepad is a platform-agnostic object that represents the data that
10088          feeds into the Gamepad object that is exposed to web content.
10089
10090        The code in this patch is dead as-is, but https://bugs.webkit.org/show_bug.cgi?id=134324
10091        will contain an immediate follow-up patch that uses it.
10092
10093        Makes sense to review them separately.
10094
10095        * WebCore.xcodeproj/project.pbxproj:
10096
10097        * platform/GamepadStrategy.h: Added.
10098        (WebCore::GamepadStrategy::~GamepadStrategy):
10099
10100        * platform/GamepadStrategyClient.h: Added.
10101        (WebCore::GamepadStrategyClient::~GamepadStrategyClient):
10102
10103        * platform/PlatformGamepad.h: Added.
10104        (WebCore::PlatformGamepad::~PlatformGamepad):
10105        (WebCore::PlatformGamepad::id):
10106        (WebCore::PlatformGamepad::lastUpdateTime):
10107        (WebCore::PlatformGamepad::connectTime):
10108        (WebCore::PlatformGamepad::PlatformGamepad):
10109
10110        * platform/PlatformStrategies.h:
10111        (WebCore::PlatformStrategies::gamepadStrategy):
10112        (WebCore::PlatformStrategies::PlatformStrategies):
10113
101142014-06-25  Zalan Bujtas  <zalan@apple.com>
10115
10116        Assertion failed: CGPathAddRoundedRect asserts on non-renderable rounded rectangle.
10117        https://bugs.webkit.org/show_bug.cgi?id=134288
10118
10119        Reviewed by Simon Fraser.
10120
10121        Speculative fix. This changeset attempts to address a possible mantissa overflow of radius
10122        when checking whether the rounded rectangle is renderable.
10123        We convert both the radius and the rectangle values to CGFloat(float/double) to perform
10124        this renderable check, instead of always using float.
10125
10126        * platform/graphics/FloatRoundedRect.cpp:
10127        (WebCore::FloatRoundedRect::Radii::scale): Move scale(float, float) from RoundedRect to FloatRoundedRect.
10128        (WebCore::FloatRoundedRect::isRenderable): Add check if radius is >= 0.
10129        * platform/graphics/FloatRoundedRect.h:
10130        * platform/graphics/RoundedRect.cpp:
10131        (WebCore::RoundedRect::Radii::scale):
10132        (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting): use FloatRoundeRect::Radii.
10133        * platform/graphics/RoundedRect.h:
10134        * platform/graphics/cg/PathCG.cpp:
10135        (WebCore::Path::platformAddPathForRoundedRect): use epsilon() to ensure width/height is always >= even with mantissa overflow. 
10136
101372014-06-25  Jer Noble  <jer.noble@apple.com>
10138
10139        [MSE] removeCodedFrames() can remove more than it should
10140        https://bugs.webkit.org/show_bug.cgi?id=134320
10141
10142        Reviewed by Geoff Garen.
10143
10144        removeCodedFrames() can remove more samples than it should because it compares an iterator
10145        in presentation timespace to one in decode timespace. Clean up this code by removing frames
10146        in decode order. Rename variables and add comments to make explicit which timespace defines
10147        the iterators being used.
10148
10149        * Modules/mediasource/SourceBuffer.cpp:
10150        (WebCore::SourceBuffer::removeCodedFrames):
10151
101522014-06-25  Beth Dakin  <bdakin@apple.com>
10153
10154        Crash in ScrollingTree::isRubberBandInProgress()
10155        https://bugs.webkit.org/show_bug.cgi?id=134316
10156        -and corresponding-
10157        <rdar://problem/16247911>
10158
10159        Reviewed by Geoffrey Garen.
10160
10161        This crash appears to have been caused by http://trac.webkit.org/changeset/161276 
10162        which moved the ScrollingNode creation code from ScrollingTree over to 
10163        ScrollingCoordinator. This creates a thread safety issue. In the crashing case, we 
10164        believe that the ScrollingCoordinator's ScrollingTree pointer had been null-ed out
10165        even though the ScrollingTree was kept alive by the bind call to propagate 
10166        commitNewTreeState() over to the scrolling thread. The fix is to move node 
10167        creation back to the ScrollingTree and to use the this pointer to create new
10168        nodes rather than the ScrollingCoordinator's ScrollingTree pointer.
10169
10170        Don't allow ScrollingCoordinator to handle ScrollingTreeNode creation.
10171        * page/scrolling/AsyncScrollingCoordinator.h:
10172
10173        Re-name createNode to createScrollingTreeNode(). 
10174        * page/scrolling/ScrollingTree.cpp:
10175        (WebCore::ScrollingTree::updateTreeFromStateNode):
10176        * page/scrolling/ScrollingTree.h:
10177
10178        Remove this implementation of createNode that called into the 
10179        ScrollingCoordinator.
10180        * page/scrolling/ThreadedScrollingTree.cpp:
10181        (WebCore::ThreadedScrollingTree::createNode): Deleted.
10182        * page/scrolling/ThreadedScrollingTree.h:
10183
10184        Don't allow ScrollingCoordinator to handle ScrollingTreeNode creation.
10185        * page/scrolling/ios/ScrollingCoordinatorIOS.h:
10186        * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
10187        (WebCore::ScrollingCoordinatorIOS::createScrollingTreeNode): Deleted.
10188
10189        Re-name createNode to createScrollingTreeNode, and actually create the nodes here.
10190        * page/scrolling/ios/ScrollingTreeIOS.cpp:
10191        (WebCore::ScrollingTreeIOS::createScrollingTreeNode):
10192        (WebCore::ScrollingTreeIOS::createNode): Deleted.
10193        * page/scrolling/ios/ScrollingTreeIOS.h:
10194
10195        Don't allow ScrollingCoordinator to handle ScrollingTreeNode creation.
10196        * page/scrolling/mac/ScrollingCoordinatorMac.h:
10197        * page/scrolling/mac/ScrollingCoordinatorMac.mm:
10198        (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode): Deleted.
10199
10200        Add the implementation of createScrollingTreeNode() for the Mac to 
10201        ScrollingTreeMac since it can create Mac-specific nodes.
10202        * page/scrolling/mac/ScrollingTreeMac.cpp:
10203        (ScrollingTreeMac::createScrollingTreeNode):
10204        * page/scrolling/mac/ScrollingTreeMac.h:
10205
102062014-06-25  Enrica Casucci  <enrica@apple.com>
10207
10208        iOS build fix after http://trac.webkit.org/changeset/170447.
10209        Unreviewed.
10210
10211        * editing/mac/TextUndoInsertionMarkup.h:
10212
102132014-06-25  Chris Fleizach  <cfleizach@apple.com>
10214
10215        Add an undo group for each dictated utterance in WebKit
10216        https://bugs.webkit.org/show_bug.cgi?id=134086
10217
10218        Reviewed by Enrica Casucci.
10219
10220        Provide a mechanism for ending the current undo group on a text insertion.
10221        This allows a stream of text, that is normally part of one undo group, to be
10222        broken up so that subsequent undo commands will only undo portions of the text stream.
10223
10224        * WebCore.exp.in:
10225        * WebCore.xcodeproj/project.pbxproj:
10226        * editing/mac/TextUndoInsertionMarkup.h: Added.
10227        * editing/mac/TextUndoInsertionMarkup.mm: Added.
10228        (WebCore::shouldRegisterInsertionUndoGroup):
10229        (WebCore::registerInsertionUndoGrouping):
10230
102312014-06-25  Joseph Pecoraro  <pecoraro@apple.com>
10232
10233        [iOS]: WK2 Inspector Node Search
10234        https://bugs.webkit.org/show_bug.cgi?id=134279
10235
10236        Reviewed by Benjamin Poulain.
10237
10238        * WebCore.exp.in:
10239        Export Node::inspect for WebKit2.
10240
102412014-06-25  Dana Burkart  <dburkart@apple.com>
10242
10243        Add support for 5-tuple versioning.
10244
10245        Reviewed by David Farler.
10246
10247        * Configurations/Version.xcconfig:
10248
102492014-06-25  Jer Noble  <jer.noble@apple.com>
10250
10251        [MSE][Mac] REGRESSION(r170336) - zero tolerance seeks are ignored.
10252        https://bugs.webkit.org/show_bug.cgi?id=134310
10253
10254        Reviewed by Brent Fulgham.
10255
10256        Tests for zero tolerance seeks were inadvertantly reversed in r170336.
10257
10258        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
10259        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
10260
102612014-06-25  Jer Noble  <jer.noble@apple.com>
10262
10263        [MSE][Mac] Pause playback when readyState drops below HAVE_FUTURE_DATA, and do not complete seek until it rises above HAVE_METADATA.
10264        https://bugs.webkit.org/show_bug.cgi?id=134306
10265
10266        Reviewed by Eric Carlson.
10267
10268        Pause the synchronizer before seeking, and do not resume the synchronizer until it both reports that the seek completed,
10269        and that the readyState rises above HAVE_METADATA. In every other location where we change the rate of the synchronizer,
10270        gate that rate change on the above.
10271
10272        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
10273        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
10274        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC): Check shouldBePlaying().
10275        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::playInternal): Ditto.
10276        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekWithTolerance): Unset m_seekCompleted.
10277        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal): Pause the synchronizer.
10278        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setRateDouble): Check shouldBePlaying().
10279        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::shouldBePlaying): Test m_seeking, !m_seekCompleted, and the readyState.
10280        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setReadyState): Set m_seekCompleted; check shouldBePlaying() and play if appropriate.
10281
102822014-06-25  Jer Noble  <jer.noble@apple.com>
10283
10284        [MSE] Update monitorSourceBuffers to match recent spec changes
10285        https://bugs.webkit.org/show_bug.cgi?id=134305
10286
10287        Reviewed by Eric Carlson.
10288
10289        In W3C bug #24347, the text for the third clause of Source Buffer Monitoring was updated. Update our
10290        implementation to match the new text.
10291
10292        * Modules/mediasource/MediaSource.cpp:
10293        (WebCore::MediaSource::monitorSourceBuffers):
10294
102952014-06-25  Alex Christensen  <achristensen@webkit.org>
10296            And peavo@outlook.com  <peavo@outlook.com>
10297
10298        Use references instead of pointers in RenderTheme.
10299        https://bugs.webkit.org/show_bug.cgi?id=134261
10300
10301        Reviewed by Zalan Bujtas.
10302
10303        * css/StyleResolver.cpp:
10304        (WebCore::StyleResolver::adjustRenderStyle):
10305        * html/TextFieldInputType.cpp:
10306        (WebCore::TextFieldInputType::shouldHaveSpinButton):
10307        * html/shadow/SliderThumbElement.cpp:
10308        (WebCore::RenderSliderThumb::updateAppearance):
10309        * platform/efl/RenderThemeEfl.cpp:
10310        (WebCore::RenderThemeEfl::adjustSizeConstraints):
10311        (WebCore::RenderThemeEfl::applyEdjeRTLState):
10312        (WebCore::RenderThemeEfl::isControlStyled):
10313        (WebCore::RenderThemeEfl::paintThemePart):
10314        (WebCore::RenderThemeEfl::supportsFocusRing):
10315        (WebCore::RenderThemeEfl::adjustSliderTrackStyle):
10316        (WebCore::RenderThemeEfl::adjustSliderThumbStyle):
10317        (WebCore::RenderThemeEfl::adjustSliderThumbSize):
10318        (WebCore::RenderThemeEfl::adjustCheckboxStyle):
10319        (WebCore::RenderThemeEfl::adjustRadioStyle):
10320        (WebCore::RenderThemeEfl::adjustButtonStyle):
10321        (WebCore::RenderThemeEfl::adjustMenuListStyle):
10322        (WebCore::RenderThemeEfl::adjustMenuListButtonStyle):
10323        (WebCore::RenderThemeEfl::adjustTextFieldStyle):
10324        (WebCore::RenderThemeEfl::adjustTextAreaStyle):
10325        (WebCore::RenderThemeEfl::adjustSearchFieldResultsButtonStyle):
10326        (WebCore::RenderThemeEfl::adjustSearchFieldResultsDecorationPartStyle):
10327        (WebCore::RenderThemeEfl::adjustSearchFieldCancelButtonStyle):
10328        (WebCore::RenderThemeEfl::adjustSearchFieldStyle):
10329        (WebCore::RenderThemeEfl::adjustInnerSpinButtonStyle):
10330        (WebCore::RenderThemeEfl::adjustProgressBarStyle):
10331        (WebCore::RenderThemeEfl::animationRepeatIntervalForProgressBar):
10332        (WebCore::RenderThemeEfl::animationDurationForProgressBar):
10333        * platform/efl/RenderThemeEfl.h:
10334        * platform/gtk/RenderThemeGtk.cpp:
10335        (WebCore::RenderThemeGtk::supportsFocusRing):
10336        (WebCore::RenderThemeGtk::adjustButtonStyle):
10337        (WebCore::RenderThemeGtk::adjustMenuListStyle):
10338        (WebCore::RenderThemeGtk::adjustMenuListButtonStyle):
10339        (WebCore::RenderThemeGtk::adjustSearchFieldResultsButtonStyle):
10340        (WebCore::adjustSearchFieldIconStyle):
10341        (WebCore::RenderThemeGtk::adjustSearchFieldResultsDecorationPartStyle):
10342        (WebCore::RenderThemeGtk::adjustSearchFieldCancelButtonStyle):
10343        (WebCore::RenderThemeGtk::adjustSearchFieldStyle):
10344        (WebCore::RenderThemeGtk::adjustSliderTrackStyle):
10345        (WebCore::RenderThemeGtk::adjustSliderThumbStyle):
10346        (WebCore::borderRadiiFromStyle):
10347        (WebCore::RenderThemeGtk::paintMediaSliderTrack):
10348        (WebCore::RenderThemeGtk::paintMediaSliderThumb):
10349        (WebCore::RenderThemeGtk::paintMediaVolumeSliderTrack):
10350        (WebCore::RenderThemeGtk::adjustProgressBarStyle):
10351        (WebCore::RenderThemeGtk::animationRepeatIntervalForProgressBar):
10352        (WebCore::RenderThemeGtk::animationDurationForProgressBar):
10353        (WebCore::RenderThemeGtk::calculateProgressRect):
10354        * platform/gtk/RenderThemeGtk.h:
10355        * platform/gtk/RenderThemeGtk2.cpp:
10356        (WebCore::setToggleSize):
10357        (WebCore::RenderThemeGtk::setCheckboxSize):
10358        (WebCore::RenderThemeGtk::setRadioSize):
10359        (WebCore::RenderThemeGtk::comboBoxArrowSize):
10360        (WebCore::RenderThemeGtk::getComboBoxPadding):
10361        (WebCore::RenderThemeGtk::popupInternalPaddingLeft):
10362        (WebCore::RenderThemeGtk::popupInternalPaddingRight):
10363        (WebCore::RenderThemeGtk::popupInternalPaddingTop):
10364        (WebCore::RenderThemeGtk::popupInternalPaddingBottom):
10365        (WebCore::RenderThemeGtk::paintMenuList):
10366        (WebCore::RenderThemeGtk::adjustSliderThumbSize):
10367        (WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
10368        * platform/gtk/RenderThemeGtk3.cpp:
10369        (WebCore::setToggleSize):
10370        (WebCore::RenderThemeGtk::setCheckboxSize):
10371        (WebCore::RenderThemeGtk::setRadioSize):
10372        (WebCore::getComboBoxMetrics):
10373        (WebCore::RenderThemeGtk::popupInternalPaddingLeft):
10374        (WebCore::RenderThemeGtk::popupInternalPaddingRight):
10375        (WebCore::RenderThemeGtk::popupInternalPaddingTop):
10376        (WebCore::RenderThemeGtk::popupInternalPaddingBottom):
10377        (WebCore::RenderThemeGtk::adjustSliderThumbSize):
10378        (WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
10379        * rendering/RenderButton.cpp:
10380        (WebCore::RenderButton::layout):
10381        * rendering/RenderInline.cpp:
10382        (WebCore::RenderInline::paintOutline):
10383        * rendering/RenderMediaControls.cpp:
10384        (WebCore::RenderMediaControls::adjustMediaSliderThumbSize):
10385        * rendering/RenderMediaControls.h:
10386        * rendering/RenderMenuList.cpp:
10387        (WebCore::RenderMenuList::adjustInnerStyle):
10388        (RenderMenuList::computeIntrinsicLogicalWidths):
10389        (RenderMenuList::menuStyle):
10390        * rendering/RenderMeter.cpp:
10391        (WebCore::RenderMeter::updateLogicalWidth):
10392        (WebCore::RenderMeter::computeLogicalHeight):
10393        * rendering/RenderObject.cpp:
10394        (WebCore::RenderObject::paintOutline):
10395        * rendering/RenderProgress.cpp:
10396        (WebCore::RenderProgress::updateAnimationState):
10397        * rendering/RenderTextControlSingleLine.cpp:
10398        (WebCore::RenderTextControlSingleLine::layout):
10399        * rendering/RenderTheme.cpp:
10400        (WebCore::RenderTheme::adjustStyle):
10401        (WebCore::RenderTheme::isControlStyled):
10402        (WebCore::RenderTheme::supportsFocusRing):
10403        (WebCore::RenderTheme::stateChanged):
10404        (WebCore::RenderTheme::adjustCheckboxStyle):
10405        (WebCore::RenderTheme::adjustRadioStyle):
10406        (WebCore::RenderTheme::adjustButtonStyle):
10407        (WebCore::RenderTheme::adjustInnerSpinButtonStyle):
10408        (WebCore::RenderTheme::adjustTextFieldStyle):
10409        (WebCore::RenderTheme::adjustTextAreaStyle):
10410        (WebCore::RenderTheme::adjustMenuListStyle):
10411        (WebCore::RenderTheme::adjustInputFieldSpeechButtonStyle):
10412        (WebCore::RenderTheme::adjustMeterStyle):
10413        (WebCore::RenderTheme::meterSizeForBounds):
10414        (WebCore::RenderTheme::animationRepeatIntervalForProgressBar):
10415        (WebCore::RenderTheme::animationDurationForProgressBar):
10416        (WebCore::RenderTheme::adjustProgressBarStyle):
10417        (WebCore::RenderTheme::shouldHaveSpinButton):
10418        (WebCore::RenderTheme::adjustMediaControlStyle):
10419        (WebCore::RenderTheme::adjustSliderTrackStyle):
10420        (WebCore::RenderTheme::adjustSliderThumbStyle):
10421        (WebCore::RenderTheme::adjustSliderThumbSize):
10422        (WebCore::RenderTheme::adjustSearchFieldStyle):
10423        (WebCore::RenderTheme::adjustSearchFieldCancelButtonStyle):
10424        (WebCore::RenderTheme::adjustSearchFieldDecorationPartStyle):
10425        (WebCore::RenderTheme::adjustSearchFieldResultsDecorationPartStyle):
10426        (WebCore::RenderTheme::adjustSearchFieldResultsButtonStyle):
10427        * rendering/RenderTheme.h:
10428        (WebCore::RenderTheme::supportsHover):
10429        (WebCore::RenderTheme::minimumMenuListSize):
10430        (WebCore::RenderTheme::popupInternalPaddingLeft):
10431        (WebCore::RenderTheme::popupInternalPaddingRight):
10432        (WebCore::RenderTheme::popupInternalPaddingTop):
10433        (WebCore::RenderTheme::popupInternalPaddingBottom):
10434        (WebCore::RenderTheme::popupMenuSize):
10435        (WebCore::RenderTheme::setCheckboxSize):
10436        (WebCore::RenderTheme::setRadioSize):
10437        (WebCore::RenderTheme::setButtonSize):
10438        * rendering/RenderThemeIOS.h:
10439        * rendering/RenderThemeIOS.mm:
10440        (WebCore::RenderThemeIOS::adjustCheckboxStyle):
10441        (WebCore::RenderThemeIOS::isControlStyled):
10442        (WebCore::RenderThemeIOS::adjustRadioStyle):
10443        (WebCore::RenderThemeIOS::popupInternalPaddingRight):
10444        (WebCore::RenderThemeIOS::adjustRoundBorderRadius):
10445        (WebCore::RenderThemeIOS::adjustMenuListButtonStyle):
10446        (WebCore::RenderThemeIOS::adjustSliderTrackStyle):
10447        (WebCore::RenderThemeIOS::adjustSliderThumbSize):
10448        (WebCore::RenderThemeIOS::animationRepeatIntervalForProgressBar):
10449        (WebCore::RenderThemeIOS::animationDurationForProgressBar):
10450        (WebCore::RenderThemeIOS::adjustSearchFieldStyle):
10451        (WebCore::RenderThemeIOS::adjustButtonStyle):
10452        (WebCore::RenderThemeIOS::setButtonSize):
10453        (WebCore::RenderThemeIOS::shouldHaveSpinButton):
10454        * rendering/RenderThemeMac.h:
10455        * rendering/RenderThemeMac.mm:
10456        (WebCore::RenderThemeMac::isControlStyled):
10457        (WebCore::RenderThemeMac::controlSizeForFont):
10458        (WebCore::RenderThemeMac::sizeForFont):
10459        (WebCore::RenderThemeMac::sizeForSystemFont):
10460        (WebCore::RenderThemeMac::setSizeFromFont):
10461        (WebCore::RenderThemeMac::setFontFromControlSize):
10462        (WebCore::RenderThemeMac::controlSizeForSystemFont):
10463        (WebCore::RenderThemeMac::adjustTextFieldStyle):
10464        (WebCore::RenderThemeMac::adjustTextAreaStyle):
10465        (WebCore::RenderThemeMac::paintMenuList):
10466        (WebCore::RenderThemeMac::meterSizeForBounds):
10467        (WebCore::RenderThemeMac::paintMeter):
10468        (WebCore::RenderThemeMac::levelIndicatorFor):
10469        (WebCore::RenderThemeMac::progressBarRectForBounds):
10470        (WebCore::RenderThemeMac::minimumProgressBarHeight):
10471        (WebCore::RenderThemeMac::animationRepeatIntervalForProgressBar):
10472        (WebCore::RenderThemeMac::animationDurationForProgressBar):
10473        (WebCore::RenderThemeMac::adjustProgressBarStyle):
10474        (WebCore::RenderThemeMac::paintProgressBar):
10475        (WebCore::RenderThemeMac::adjustMenuListStyle):
10476        (WebCore::RenderThemeMac::popupInternalPaddingLeft):
10477        (WebCore::RenderThemeMac::popupInternalPaddingRight):
10478        (WebCore::RenderThemeMac::popupInternalPaddingTop):
10479        (WebCore::RenderThemeMac::popupInternalPaddingBottom):
10480        (WebCore::RenderThemeMac::popupMenuSize):
10481        (WebCore::RenderThemeMac::minimumMenuListSize):
10482        (WebCore::RenderThemeMac::adjustSliderTrackStyle):
10483        (WebCore::RenderThemeMac::adjustSliderThumbStyle):
10484        (WebCore::RenderThemeMac::setSearchCellState):
10485        (WebCore::RenderThemeMac::setSearchFieldSize):
10486        (WebCore::RenderThemeMac::adjustSearchFieldStyle):
10487        (WebCore::RenderThemeMac::adjustSearchFieldCancelButtonStyle):
10488        (WebCore::RenderThemeMac::adjustSearchFieldDecorationPartStyle):
10489        (WebCore::RenderThemeMac::adjustSearchFieldResultsDecorationPartStyle):
10490        (WebCore::RenderThemeMac::adjustSearchFieldResultsButtonStyle):
10491        (WebCore::RenderThemeMac::adjustSliderThumbSize):
10492        * rendering/RenderThemeSafari.cpp:
10493        (WebCore::RenderThemeSafari::isControlStyled):
10494        (WebCore::RenderThemeSafari::adjustRepaintRect):
10495        (WebCore::RenderThemeSafari::baselinePosition):
10496        (WebCore::RenderThemeSafari::controlSizeForFont):
10497        (WebCore::RenderThemeSafari::sizeForFont):
10498        (WebCore::RenderThemeSafari::sizeForSystemFont):
10499        (WebCore::RenderThemeSafari::setSizeFromFont):
10500        (WebCore::RenderThemeSafari::setFontFromControlSize):
10501        (WebCore::RenderThemeSafari::controlSizeForSystemFont):
10502        (WebCore::RenderThemeSafari::paintCheckbox):
10503        (WebCore::RenderThemeSafari::setCheckboxSize):
10504        (WebCore::RenderThemeSafari::paintRadio):
10505        (WebCore::RenderThemeSafari::setRadioSize):
10506        (WebCore::RenderThemeSafari::setButtonPaddingFromControlSize):
10507        (WebCore::RenderThemeSafari::adjustButtonStyle):
10508        (WebCore::RenderThemeSafari::setButtonSize):
10509        (WebCore::RenderThemeSafari::adjustTextFieldStyle):
10510        (WebCore::RenderThemeSafari::adjustTextAreaStyle):
10511        (WebCore::RenderThemeSafari::paintMenuList):
10512        (WebCore::RenderThemeSafari::adjustMenuListStyle):
10513        (WebCore::RenderThemeSafari::popupInternalPaddingLeft):
10514        (WebCore::RenderThemeSafari::popupInternalPaddingRight):
10515        (WebCore::RenderThemeSafari::popupInternalPaddingTop):
10516        (WebCore::RenderThemeSafari::popupInternalPaddingBottom):
10517        (WebCore::RenderThemeSafari::adjustMenuListButtonStyle):
10518        (WebCore::RenderThemeSafari::minimumMenuListSize):
10519        (WebCore::RenderThemeSafari::adjustSliderThumbStyle):
10520        (WebCore::RenderThemeSafari::adjustSliderThumbSize):
10521        (WebCore::RenderThemeSafari::setSearchFieldSize):
10522        (WebCore::RenderThemeSafari::adjustSearchFieldStyle):
10523        (WebCore::RenderThemeSafari::adjustSearchFieldCancelButtonStyle):
10524        (WebCore::RenderThemeSafari::adjustSearchFieldDecorationPartStyle):
10525        (WebCore::RenderThemeSafari::adjustSearchFieldResultsDecorationPartStyle):
10526        (WebCore::RenderThemeSafari::adjustSearchFieldResultsButtonStyle):
10527        (WebCore::RenderThemeSafari::adjustMeterStyle):
10528        (WebCore::RenderThemeSafari::meterSizeForBounds):
10529        (WebCore::RenderThemeSafari::paintMeter):
10530        * rendering/RenderThemeSafari.h:
10531        * rendering/RenderThemeWin.cpp:
10532        (WebCore::RenderThemeWin::supportsHover):
10533        (WebCore::RenderThemeWin::supportsFocusRing):
10534        (WebCore::RenderThemeWin::adjustInnerSpinButtonStyle):
10535        (WebCore::RenderThemeWin::setCheckboxSize):
10536        (WebCore::RenderThemeWin::paintTextField):
10537        (WebCore::RenderThemeWin::paintMenuList):
10538        (WebCore::RenderThemeWin::adjustMenuListStyle):
10539        (WebCore::RenderThemeWin::adjustMenuListButtonStyle):
10540        (WebCore::RenderThemeWin::adjustSliderThumbSize):
10541        (WebCore::RenderThemeWin::adjustSearchFieldStyle):
10542        (WebCore::RenderThemeWin::adjustSearchFieldCancelButtonStyle):
10543        (WebCore::RenderThemeWin::adjustSearchFieldDecorationPartStyle):
10544        (WebCore::RenderThemeWin::adjustSearchFieldResultsDecorationPartStyle):
10545        (WebCore::RenderThemeWin::adjustSearchFieldResultsButtonStyle):
10546        (WebCore::RenderThemeWin::adjustMeterStyle):
10547        (WebCore::RenderThemeWin::meterSizeForBounds):
10548        (WebCore::RenderThemeWin::paintMeter):
10549        * rendering/RenderThemeWin.h:
10550        (WebCore::RenderThemeWin::paintCheckbox):
10551        (WebCore::RenderThemeWin::paintRadio):
10552        (WebCore::RenderThemeWin::setRadioSize):
10553        (WebCore::RenderThemeWin::paintTextArea):
10554        (WebCore::RenderThemeWin::popupOptionSupportsTextIndent):
10555        (WebCore::RenderThemeWin::paintSearchFieldDecorationPart):
10556        (WebCore::RenderThemeWin::adjustButtonStyle):
10557        (WebCore::RenderThemeWin::adjustTextFieldStyle):
10558        (WebCore::RenderThemeWin::adjustTextAreaStyle):
10559        (WebCore::RenderThemeWin::shouldShowPlaceholderWhenFocused):
10560
105612014-06-25  Benjamin Poulain  <benjamin@webkit.org>
10562
10563        [Mac] Update the time base of event's timestamp when the system time changes
10564        https://bugs.webkit.org/show_bug.cgi?id=134293
10565
10566        Reviewed by Anders Carlsson.
10567
10568        * platform/mac/PlatformEventFactoryMac.mm:
10569        (WebCore::cachedStartupTimeIntervalSince1970): Since events timestamps are absolute time, they also
10570        need to be updated if the system clock changes.
10571
105722014-06-25  Dirk Schulze  <krit@webkit.org>
10573
10574        Add all blend modes to feBlend
10575
10576        feBlend should support all blend modes from CSS and Canvas
10577        https://bugs.webkit.org/show_bug.cgi?id=134296
10578
10579        Reviewed by Dean Jackson.
10580
10581        Add all blend modes to <feBlend> (the SVG filter primitive) that are also
10582        supported by HTML Canvas and CSS.
10583
10584        In addition, add "normal" blend mode to HTML Canvas as requested by the
10585        CSS Compositing and Blending specification. (Referenced from HTML Canvas.)
10586        With this change, SVG, CSS and Canvas truly share the same blend modes and
10587        even the same keywords. This is much easier to for web authors.
10588
10589        http://www.w3.org/TR/2014/CR-compositing-1-20140220/#ltblendmodegt
10590
10591        Test: svg/filters/feBlend-all-blendmodes.svg
10592
10593        * platform/graphics/GraphicsTypes.cpp: Reorder blend mode text streams to match
10594            enumeration order. Add a new function to parse blend modes independent of
10595            compositing modes. Add a string "normal" that is supported by CSS, feBlend and
10596            HTML Canvas now.
10597        (WebCore::parseBlendMode):
10598        (WebCore::parseCompositeAndBlendOperator):
10599        * platform/graphics/GraphicsTypes.h: Reorder BlendMode enumeration values to match
10600         the SVG JS enumeration for blend modes.
10601        * platform/graphics/cpu/arm/filters/FEBlendNEON.h: Move all software code that is no
10602            longer required by the software path but still used by NEON here.
10603        (WebCore::FEBlend::platformApplySoftware):
10604        (WebCore::FEBlend::platformApplyNEON):
10605        * platform/graphics/filters/FEBlend.cpp:
10606            Use drawImageBuffer() to blend the results of previous filter primitives. This
10607            allows removing more than 60% of the code.
10608        (WebCore::FEBlend::FEBlend):
10609        (WebCore::FEBlend::create):
10610        (WebCore::FEBlend::blendMode):
10611        (WebCore::FEBlend::setBlendMode):
10612        (WebCore::FEBlend::platformApplySoftware):
10613        (WebCore::FEBlend::dump):
10614        (WebCore::FEBlend::externalRepresentation):
10615        (WebCore::feBlendNormal): Deleted.
10616        (WebCore::feBlendMultiply): Deleted.
10617        (WebCore::feBlendScreen): Deleted.
10618        (WebCore::feBlendDarken): Deleted.
10619        (WebCore::feBlendLighten): Deleted.
10620        (WebCore::feBlendUnknown): Deleted.
10621        (WebCore::platformApply): Deleted.
10622        (WebCore::FEBlend::platformApplyGeneric): Deleted.
10623        (WebCore::operator<<): Deleted.
10624        * platform/graphics/filters/FEBlend.h:
10625        * svg/SVGAnimatedEnumeration.cpp: Use the global BlendMode enumeration.
10626        (WebCore::enumerationValueForTargetAttribute):
10627        * svg/SVGFEBlendElement.cpp:
10628        (WebCore::SVGFEBlendElement::SVGFEBlendElement): Use the global BlendMode enumeration.
10629            No new enumeration values added or exposed to SVG DOM as requested by SVG WG.
10630        (WebCore::SVGFEBlendElement::parseAttribute):
10631        * svg/SVGFEBlendElement.h: Replace BlendModeType with global BlendMode enumeration. Remove
10632            blend mode parsing code and use the code in GraphicsTypes instead.
10633        (WebCore::SVGPropertyTraits<BlendMode>::highestEnumValue):
10634        (WebCore::SVGPropertyTraits<BlendMode>::toString):
10635        (WebCore::SVGPropertyTraits<BlendModeType>::highestEnumValue): Deleted.
10636        (WebCore::SVGPropertyTraits<BlendModeType>::toString): Deleted.
10637        (WebCore::SVGPropertyTraits<BlendModeType>::fromString): Deleted.
10638
106392014-06-25  Zalan Bujtas  <zalan@apple.com>
10640
10641        Unreviewed iOS build fix after r170425.
10642
10643        * accessibility/AccessibilityProgressIndicator.cpp:
10644        * accessibility/AccessibilityProgressIndicator.h:
10645
106462014-06-25  Chris Fleizach  <cfleizach@apple.com>
10647
10648        AX: Crash at com.apple.WebCore: WebCore::AlternativeTextController::removeDictationAlternativesForMarker + 43
10649        https://bugs.webkit.org/show_bug.cgi?id=134226
10650
10651        Reviewed by Enrica Casucci.
10652
10653        Unchecked access of details pointer in the Document marker led to the crash.
10654        It seems erroneous to allow creation of a DocumentMarker without details when one is expected, because it
10655        carries the dictation context (not just the description).
10656        Also, add in ASSERTs to catch scenarios where a nullptr might be passed in.
10657
10658        Test: platform/mac/editing/input/crash-for-empty-text-alternative.html
10659
10660        * dom/DocumentMarker.cpp:
10661        (WebCore::DocumentMarker::DocumentMarker):
10662        * editing/AlternativeTextController.cpp:
10663        (WebCore::AlternativeTextController::removeDictationAlternativesForMarker):
10664
106652014-06-25  Laszlo Gombos  <l.gombos@samsung.com>
10666
10667        Remove build guard for progress element
10668        https://bugs.webkit.org/show_bug.cgi?id=134292
10669
10670        Reviewed by Benjamin Poulain.
10671
10672        The build flag is no longer needed as it is always on.
10673
10674        No new tests as there is no new behaviour.
10675
10676        * Configurations/FeatureDefines.xcconfig:
10677        * DerivedSources.make:
10678        * accessibility/AXObjectCache.cpp:
10679        (WebCore::createFromRenderer):
10680        * accessibility/AccessibilityProgressIndicator.cpp:
10681        (WebCore::AccessibilityProgressIndicator::create):
10682        (WebCore::AccessibilityProgressIndicator::valueForRange):
10683        (WebCore::AccessibilityProgressIndicator::maxValueForRange):
10684        (WebCore::AccessibilityProgressIndicator::minValueForRange):
10685        (WebCore::AccessibilityProgressIndicator::progressElement):
10686        * accessibility/AccessibilityProgressIndicator.h:
10687        * css/CSSPrimitiveValueMappings.h:
10688        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
10689        * css/StyleResolver.cpp:
10690        (WebCore::StyleResolver::sharingCandidateHasIdenticalStyleAffectingAttributes):
10691        * css/html.css:
10692        (progress::-webkit-progress-value):
10693        * html/HTMLProgressElement.cpp:
10694        * html/HTMLProgressElement.h:
10695        * html/HTMLProgressElement.idl:
10696        * html/HTMLTagNames.in:
10697        * html/shadow/ProgressShadowElement.cpp:
10698        * html/shadow/ProgressShadowElement.h:
10699        * platform/efl/DefaultTheme/CMakeLists.txt:
10700        * platform/efl/DefaultTheme/default.edc:
10701        * platform/efl/RenderThemeEfl.cpp:
10702        (WebCore::toEdjeGroup):
10703        (WebCore::RenderThemeEfl::applyEdjeRTLState):
10704        (WebCore::RenderThemeEfl::paintProgressBar):
10705        * platform/efl/RenderThemeEfl.h:
10706        * platform/gtk/RenderThemeGtk.cpp:
10707        (WebCore::RenderThemeGtk::calculateProgressRect):
10708        * platform/gtk/RenderThemeGtk.h:
10709        * platform/gtk/RenderThemeGtk2.cpp:
10710        (WebCore::RenderThemeGtk::paintProgressBar):
10711        * platform/gtk/RenderThemeGtk3.cpp:
10712        (WebCore::RenderThemeGtk::paintProgressBar):
10713        * rendering/RenderObject.h:
10714        (WebCore::RenderObject::isSnapshottedPlugIn):
10715        (WebCore::RenderObject::isProgress):
10716        * rendering/RenderProgress.cpp:
10717        * rendering/RenderProgress.h:
10718        * rendering/RenderTheme.cpp:
10719        (WebCore::RenderTheme::adjustStyle):
10720        (WebCore::RenderTheme::paint):
10721        (WebCore::RenderTheme::paintBorderOnly):
10722        (WebCore::RenderTheme::paintDecorations):
10723        (WebCore::RenderTheme::progressBarRectForBounds):
10724        * rendering/RenderTheme.h:
10725        (WebCore::RenderTheme::paintProgressBar):
10726        * rendering/RenderThemeIOS.h:
10727        * rendering/RenderThemeIOS.mm:
10728        (WebCore::RenderThemeIOS::paintProgressBar):
10729        * rendering/RenderThemeMac.h:
10730        * rendering/RenderThemeMac.mm:
10731        (WebCore::RenderThemeMac::paintProgressBar):
10732
107332014-06-25  Carlos Garcia Campos  <cgarcia@igalia.com>
10734
10735        Unreviewed. Update GObject DOM bindings test results after r170422.
10736
10737        * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
10738        (WebKit::wrapTestActiveDOMObject):
10739        * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
10740        (WebKit::wrapTestCallback):
10741        * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
10742        (WebKit::wrapTestCustomNamedGetter):
10743        * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
10744        (WebKit::wrapTestEventConstructor):
10745        * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
10746        (WebKit::wrapTestEventTarget):
10747        * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
10748        (WebKit::wrapTestException):
10749        * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.cpp:
10750        (WebKit::wrapTestGenerateIsReachable):
10751        * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
10752        (WebKit::wrapTestInterface):
10753        * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
10754        (WebKit::wrapTestMediaQueryListListener):
10755        * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
10756        (WebKit::wrapTestNamedConstructor):
10757        * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
10758        (WebKit::wrapTestNode):
10759        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.cpp:
10760        (WebKit::wrapTestNondeterministic):
10761        * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
10762        (WebKit::wrapTestObj):
10763        * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.cpp:
10764        (WebKit::wrapTestOverloadedConstructors):
10765        * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
10766        (WebKit::wrapTestSerializedScriptValueInterface):
10767        * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
10768        (WebKit::wrapTestTypedefs):
10769        * bindings/scripts/test/GObject/WebKitDOMattribute.cpp:
10770        (WebKit::wrapattribute):
10771        * bindings/scripts/test/GObject/WebKitDOMreadonly.cpp:
10772        (WebKit::wrapreadonly):
10773
107742014-06-24  Tomas Popela  <tpopela@redhat.com>
10775
10776        [GTK] Some of DOM bindings macros are misnamed
10777        https://bugs.webkit.org/show_bug.cgi?id=121543
10778
10779        Reviewed by Carlos Garcia Campos.
10780
10781        As we are using WebKitDOM as a namespace we should unify all type macros
10782        to have WEBKIT_DOM_TYPE prefix instead of WEBKIT_TYPE_DOM. Also add
10783        more exceptions to decamelize function in GObject bindings generator
10784        to fix the names of bindings for BR, HR, UL, OL, DL and LI elements.
10785
10786        * bindings/gobject/GObjectEventListener.cpp:
10787        (WebCore::GObjectEventListener::handleEvent):
10788        * bindings/gobject/WebKitDOMEventTarget.h:
10789        * bindings/gobject/WebKitDOMNodeFilter.h:
10790        * bindings/gobject/WebKitDOMObject.h:
10791        * bindings/gobject/webkitdom.symbols:
10792        * bindings/scripts/CodeGeneratorGObject.pm:
10793        (decamelize):
10794        (GetParentGObjType):
10795        (GenerateProperty):
10796        (GenerateHeader):
10797        (GenerateCFile):
10798        (GenerateEventTargetIface):
10799        * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
10800        (WebKit::wrapFloat64Array):
10801        * bindings/scripts/test/GObject/WebKitDOMFloat64Array.h:
10802        * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
10803        (WebKit::wrapTestActiveDOMObject):
10804        * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
10805        * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
10806        (WebKit::wrapTestCallback):
10807        * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
10808        * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
10809        (WebKit::wrapTestCustomNamedGetter):
10810        * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
10811        * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
10812        (WebKit::wrapTestEventConstructor):
10813        * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.h:
10814        * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
10815        (WebKit::wrapTestEventTarget):
10816        * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
10817        * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
10818        (WebKit::wrapTestException):
10819        * bindings/scripts/test/GObject/WebKitDOMTestException.h:
10820        * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.cpp:
10821        (WebKit::wrapTestGenerateIsReachable):
10822        * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.h:
10823        * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
10824        (WebKit::wrapTestInterface):
10825        (webkit_dom_test_interface_class_init):
10826        * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
10827        * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
10828        (WebKit::wrapTestMediaQueryListListener):
10829        * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.h:
10830        * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
10831        (WebKit::wrapTestNamedConstructor):
10832        * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.h:
10833        * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
10834        (WebKit::wrapTestNode):
10835        * bindings/scripts/test/GObject/WebKitDOMTestNode.h:
10836        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.cpp:
10837        (WebKit::wrapTestNondeterministic):
10838        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.h:
10839        * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
10840        (WebKit::wrapTestObj):
10841        (webkit_dom_test_obj_class_init):
10842        * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
10843        * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.cpp:
10844        (WebKit::wrapTestOverloadedConstructors):
10845        * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.h:
10846        * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
10847        (WebKit::wrapTestSerializedScriptValueInterface):
10848        (webkit_dom_test_serialized_script_value_interface_class_init):
10849        * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h:
10850        * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
10851        (WebKit::wrapTestTypedefs):
10852        (webkit_dom_test_typedefs_class_init):
10853        * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:
10854        * bindings/scripts/test/GObject/WebKitDOMattribute.cpp:
10855        (WebKit::wrapattribute):
10856        * bindings/scripts/test/GObject/WebKitDOMattribute.h:
10857        * bindings/scripts/test/GObject/WebKitDOMreadonly.cpp:
10858        (WebKit::wrapreadonly):
10859        * bindings/scripts/test/GObject/WebKitDOMreadonly.h:
10860
108612014-06-24  Commit Queue  <commit-queue@webkit.org>
10862
10863        Unreviewed, rolling out r170414.
10864        https://bugs.webkit.org/show_bug.cgi?id=134291
10865
10866        the patch added a test that fails on almost every Mac tester
10867        (Requested by rniwa on #webkit).
10868
10869        Reverted changeset:
10870
10871        "Tiles on bottom of screen are not always allocated when
10872        necessary"
10873        https://bugs.webkit.org/show_bug.cgi?id=134272
10874        http://trac.webkit.org/changeset/170414
10875
108762014-06-24  Myles C. Maxfield  <mmaxfield@apple.com>
10877
10878        Tiles on bottom of screen are not always allocated when necessary
10879        https://bugs.webkit.org/show_bug.cgi?id=134272
10880
10881        Reviewed by Simon Fraser.
10882
10883        The initial visibleRect is in the coordinate of the root layer, so its origin
10884        is at the top left of the view. The initial rect we were using doesn't
10885        include the contents inset, so it was too short, which was causing tiles near
10886        the bottom of the screen to not always be allocated if the tile threshold was
10887        close to the bottom of the view. Instead, we want to include the contents
10888        inset size so the visible rect includes the entire view.
10889        GraphicsLayerCA::recursiveCommitChanges() takes care of mapping and cropping
10890        the visible rect into the tiled layer's coordinate system, at which point it
10891        is used for visible tile logic.
10892
10893        Test: platform/mac-wk2/tiled-drawing/visible-rect-content-inset.html
10894
10895        * platform/graphics/ca/TileCoverageMap.cpp:
10896        (WebCore::TileCoverageMap::update):
10897        * rendering/RenderLayerCompositor.cpp:
10898        (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
10899
109002014-06-24  Myles C. Maxfield  <mmaxfield@apple.com>
10901
10902        InlineTextBox's m_len can be an unsigned (rather than an unsigned short)
10903        https://bugs.webkit.org/show_bug.cgi?id=134173
10904
10905        Reviewed by Daniel Bates.
10906
10907        After Zalan's talks with Kling, it seems that the simple line layout code
10908        might alleviate the need for the space savings in InlineTextBox. Given this,
10909        it would be beneficial to be a little more safe by using unsigneds throughout.
10910
10911        For example, we have code like "void setLen(unsigned len) { m_len = len; }"
10912        which might silently break if given particular inputs.
10913
10914        No new tests because there is no behavior change.
10915
10916        * rendering/InlineTextBox.cpp:
10917        (WebCore::InlineTextBox::isSelected):
10918        (WebCore::InlineTextBox::localSelectionRect):
10919        (WebCore::InlineTextBox::paint):
10920        (WebCore::InlineTextBox::selectionStartEnd):
10921        (WebCore::InlineTextBox::paintSelection):
10922        (WebCore::InlineTextBox::paintCompositionBackground):
10923        (WebCore::InlineTextBox::paintDocumentMarker):
10924        (WebCore::InlineTextBox::paintTextMatchMarker):
10925        (WebCore::InlineTextBox::computeRectForReplacementMarker):
10926        * rendering/InlineTextBox.h:
10927        (WebCore::InlineTextBox::truncation):
10928        * rendering/RenderTextLineBoxes.cpp:
10929        (WebCore::ellipsisRectForBox):
10930
109312014-06-24  Ryosuke Niwa  <rniwa@webkit.org>
10932
10933        Speculative 32-bit Mac build fix after r170402.
10934
10935        * platform/graphics/mac/ComplexTextController.cpp:
10936        (WebCore::advanceByCombiningCharacterSequence):
10937
109382014-06-24  Joseph Pecoraro  <pecoraro@apple.com>
10939
10940        [iOS]: WK2 Inspector Node Highlighting
10941        https://bugs.webkit.org/show_bug.cgi?id=134257
10942
10943        Reviewed by Timothy Hatcher.
10944
10945        Some clients want to get highlights with the scroll applied,
10946        others do not. Provide a CoordinateSpace param to be used for
10947        getting a highlight (only used on iOS).
10948
10949        * WebCore.exp.in:
10950        * inspector/InspectorController.cpp:
10951        (WebCore::InspectorController::getHighlight):
10952        * inspector/InspectorController.h:
10953        * inspector/InspectorOverlay.cpp:
10954        (WebCore::InspectorOverlay::getHighlight):
10955        (WebCore::buildObjectForRendererFragments):
10956        * inspector/InspectorOverlay.h:
10957        (WebCore::Highlight::Highlight):
10958        * testing/Internals.cpp:
10959        (WebCore::Internals::inspectorHighlightRects):
10960
109612014-06-24  Jer Noble  <jer.noble@apple.com>
10962
10963        [MSE][Mac] Uncaught exception when deallocating AVSampleBufferDisplayLayer
10964        https://bugs.webkit.org/show_bug.cgi?id=134281
10965
10966        Reviewed by Brent Fulgham.
10967
10968        AVSampleBufferDisplayLayer is throwing an exception from its -dealloc method because KVO observers exist
10969        at the time of dealloc. Remove the observer for outputObscuredDueToInsufficientExternalProtection inside
10970        -stopObservingLayer.
10971
10972        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
10973        (-[WebAVSampleBufferErrorListener stopObservingLayer:]):
10974
109752014-06-24  Mark Rowe  <mrowe@apple.com>
10976
10977        WKContextHistoryClient::didNavigateWithNavigationData is passed incorrect URL when history.pushState is used
10978        <https://webkit.org/b/134271> / <rdar://problem/16270167>
10979
10980        Reviewed by Brady Eidson.
10981
10982        Tests: http/tests/globalhistory/history-delegate-pushstate.html
10983               http/tests/globalhistory/history-delegate-replacestate.html
10984
10985        * page/History.cpp:
10986        (WebCore::History::stateObjectAdded): Call HistoryController after updating the document's URL so that the
10987        URL will reflect the destination of the navigation when FrameLoaderClient::updateGlobalHistory is called.
10988
109892014-06-24  Myles C. Maxfield  <mmaxfield@apple.com>
10990
10991        advanceByCombiningCharacterSequence() can be simplified
10992        https://bugs.webkit.org/show_bug.cgi?id=133591
10993
10994        Reviewed by Dean Jackson.
10995
10996        Use U16_NEXT() because it already does what we're trying to do.
10997
10998        No new tests because there is no behavior change.
10999
11000        * platform/graphics/mac/ComplexTextController.cpp:
11001        (WebCore::advanceByCombiningCharacterSequence):
11002
110032014-06-24  Brady Eidson  <beidson@apple.com>
11004
11005        Enable GAMEPAD in the Mac build, but disabled at runtime.
11006        https://bugs.webkit.org/show_bug.cgi?id=134255
11007
11008        Reviewed by Dean Jackson.
11009
11010        No new tests (No changes to a tested config).
11011
11012        * bindings/scripts/CodeGeneratorJS.pm:
11013        (GenerateImplementation): Add the ability to have a function be EnabledAtRuntime by
11014          removing such functions from the prototype if they are disabled.
11015
11016        Change the three new objects and the one new function to be EnabledAtRuntime
11017        * Modules/gamepad/Gamepad.idl:
11018        * Modules/gamepad/GamepadButton.idl:
11019        * Modules/gamepad/GamepadEvent.idl:
11020        * Modules/gamepad/NavigatorGamepad.idl:
11021
11022        Add a RuntimeEnabledFeature for Gamepads:
11023        * bindings/generic/RuntimeEnabledFeatures.cpp:
11024        (WebCore::RuntimeEnabledFeatures::RuntimeEnabledFeatures):
11025        * bindings/generic/RuntimeEnabledFeatures.h:
11026        (WebCore::RuntimeEnabledFeatures::setGamepadsEnabled):
11027        (WebCore::RuntimeEnabledFeatures::gamepadsEnabled):
11028
11029        * Configurations/FeatureDefines.xcconfig:
11030
110312014-06-24  Yusuke Suzuki  <utatane.tea@gmail.com>
11032
11033        CSS JIT: Add positionInRootFragments to SelectorFragment
11034        https://bugs.webkit.org/show_bug.cgi?id=133609
11035
11036        Reviewed by Benjamin Poulain.
11037
11038        Some non-backtrack-related predicates use relationToRightFragment information
11039        to decide whether checkingContext->elementStyle should be refered.
11040        To make it works correctly, add the positionInRootFragments field to SelectorFragment.
11041        When positionInRootFragments == Rightmost and relationToRightFragment == Rightmost,
11042        we should see checkingContext->elementStyle.
11043
11044        Test: fast/selectors/first-child-update-with-renderer.html
11045
11046        * cssjit/SelectorCompiler.cpp:
11047        (WebCore::SelectorCompiler::shouldUseRenderStyleFromCheckingContext):
11048        (WebCore::SelectorCompiler::addPseudoClassType):
11049        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
11050        (WebCore::SelectorCompiler::constructFragments):
11051        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsActive):
11052        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
11053        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsHovered):
11054        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLastChild):
11055        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsOnlyChild):
11056        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
11057
110582014-06-24  Jer Noble  <jer.noble@apple.com>
11059
11060        [Fullscreen][Mac] WKView is not firstResponder after entering fullscreen mode
11061        https://bugs.webkit.org/show_bug.cgi?id=134270
11062
11063        Reviewed by Jon Honeycutt.
11064
11065        The WebCoreFullScreenWindow's firstResponder is reset when the full screen animation completes and
11066        the window's style is changed to a fullscreen style. Save the firstResponder, and if it's still in
11067        the window's view hierarchy after the style changes, reset it to the firstResponder.
11068
11069        * platform/mac/WebCoreFullScreenWindow.mm:
11070        (-[WebCoreFullScreenWindow setStyleMask:]):
11071
110722014-06-24  Jer Noble  <jer.noble@apple.com>
11073
11074        [MSE][Mac] Pass AVSampleBufferDisplayLayer HDCP status through to EME
11075        https://bugs.webkit.org/show_bug.cgi?id=134221
11076
11077        Reviewed by Eric Carlson.
11078
11079        Pass the outputObscuredDueToInsufficientExternalProtection property of AVSampleBufferDisplayLayer
11080        as an error to the associated MediaKeySession object.
11081
11082        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
11083        (-[WebAVSampleBufferErrorListener invalidate]):
11084        (-[WebAVSampleBufferErrorListener beginObservingLayer:]):
11085        (-[WebAVSampleBufferErrorListener observeValueForKeyPath:ofObject:change:context:]):
11086
110872014-06-20  Myles C. Maxfield  <mmaxfield@apple.com>
11088
11089        Use unsigneds instead of ints for indexes into a string in text layout code
11090        https://bugs.webkit.org/show_bug.cgi?id=133592
11091
11092        Reviewed by Zalan Bujtas.
11093
11094        Migrate much of the text-handling code to use unsigneds for indexes into a string.
11095
11096        No new tests because there is no behavior change.
11097
11098        * WebCore.exp.in:
11099        * platform/graphics/Font.cpp:
11100        (WebCore::Font::drawText):
11101        (WebCore::Font::drawEmphasisMarks):
11102        (WebCore::Font::adjustSelectionRectForText):
11103        (WebCore::computeUnderlineType):
11104        * platform/graphics/Font.h:
11105        * platform/graphics/FontFastPath.cpp:
11106        (WebCore::Font::getGlyphsAndAdvancesForSimpleText):
11107        (WebCore::Font::drawSimpleText):
11108        (WebCore::Font::drawEmphasisMarksForSimpleText):
11109        (WebCore::Font::drawGlyphBuffer):
11110        (WebCore::Font::drawEmphasisMarks):
11111        (WebCore::Font::adjustSelectionRectForSimpleText):
11112        * platform/graphics/GlyphBuffer.h:
11113        (WebCore::GlyphBuffer::size):
11114        (WebCore::GlyphBuffer::glyphs):
11115        (WebCore::GlyphBuffer::advances):
11116        (WebCore::GlyphBuffer::fontDataAt):
11117        (WebCore::GlyphBuffer::advanceAt):
11118        (WebCore::GlyphBuffer::offsetAt):
11119        (WebCore::GlyphBuffer::reverse):
11120        (WebCore::GlyphBuffer::offsetInString):
11121        (WebCore::GlyphBuffer::swap):
11122        * platform/graphics/GraphicsContext.cpp:
11123        (WebCore::TextRunIterator::atEnd):
11124        * platform/graphics/Latin1TextIterator.h:
11125        (WebCore::Latin1TextIterator::Latin1TextIterator):
11126        (WebCore::Latin1TextIterator::currentCharacter):
11127        * platform/graphics/SimpleFontData.h:
11128        * platform/graphics/SurrogatePairAwareTextIterator.cpp:
11129        (WebCore::SurrogatePairAwareTextIterator::SurrogatePairAwareTextIterator):
11130        * platform/graphics/SurrogatePairAwareTextIterator.h:
11131        (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
11132        * platform/graphics/TextRun.h:
11133        (WebCore::TextRun::length):
11134        (WebCore::TextRun::charactersLength):
11135        * platform/graphics/WidthIterator.cpp:
11136        (WebCore::WidthIterator::glyphDataForCharacter):
11137        (WebCore::applyFontTransforms):
11138        (WebCore::WidthIterator::advanceInternal):
11139        (WebCore::WidthIterator::advance):
11140        (WebCore::WidthIterator::advanceOneCharacter):
11141        * platform/graphics/WidthIterator.h:
11142        * platform/graphics/cairo/FontCairo.cpp:
11143        (WebCore::Font::drawGlyphs):
11144        * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
11145        (WebCore::Font::drawComplexText):
11146        (WebCore::Font::drawEmphasisMarksForComplexText):
11147        (WebCore::Font::adjustSelectionRectForComplexText):
11148        * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
11149        (WebCore::HarfBuzzShaper::setNormalizedBuffer):
11150        * platform/graphics/mac/FontComplexTextMac.cpp:
11151        (WebCore::Font::adjustSelectionRectForComplexText):
11152        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
11153        (WebCore::Font::drawComplexText):
11154        (WebCore::Font::drawEmphasisMarksForComplexText):
11155        * platform/graphics/mac/FontMac.mm:
11156        (WebCore::Font::drawGlyphs):
11157        * platform/graphics/win/FontCGWin.cpp:
11158        (WebCore::Font::drawGlyphs):
11159        * platform/graphics/win/FontWin.cpp:
11160        (WebCore::Font::adjustSelectionRectForComplexText):
11161        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
11162        (WebCore::Font::drawComplexText):
11163        (WebCore::Font::drawEmphasisMarksForComplexText):
11164        * platform/graphics/wince/FontWinCE.cpp:
11165        (WebCore::Font::drawGlyphs):
11166        (WebCore::Font::drawComplexText):
11167        (WebCore::Font::drawEmphasisMarksForComplexText):
11168        (WebCore::Font::selectionRectForComplexText):
11169        * rendering/InlineTextBox.cpp:
11170        (WebCore::InlineTextBox::isSelected):
11171        (WebCore::InlineTextBox::selectionState):
11172        (WebCore::adjustCharactersAndLengthForHyphen):
11173        (WebCore::InlineTextBox::localSelectionRect):
11174        (WebCore::InlineTextBox::paint):
11175        (WebCore::InlineTextBox::selectionStartEnd):
11176        (WebCore::InlineTextBox::paintSelection):
11177        (WebCore::InlineTextBox::paintCompositionBackground):
11178        (WebCore::InlineTextBox::paintDocumentMarker):
11179        (WebCore::InlineTextBox::paintTextMatchMarker):
11180        (WebCore::InlineTextBox::computeRectForReplacementMarker):
11181        (WebCore::InlineTextBox::paintCompositionUnderline):
11182        (WebCore::InlineTextBox::positionForOffset):
11183        (WebCore::InlineTextBox::constructTextRun):
11184        * rendering/InlineTextBox.h:
11185        * rendering/RenderCombineText.cpp:
11186        (WebCore::RenderCombineText::getStringToRender):
11187        * rendering/RenderCombineText.h:
11188        * rendering/svg/SVGInlineFlowBox.cpp:
11189        (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
11190        * rendering/svg/SVGInlineTextBox.cpp:
11191        (WebCore::SVGInlineTextBox::positionForOffset):
11192        (WebCore::SVGInlineTextBox::localSelectionRect):
11193        (WebCore::SVGInlineTextBox::paintSelectionBackground):
11194        (WebCore::SVGInlineTextBox::mapStartEndPositionsIntoFragmentCoordinates):
11195        (WebCore::SVGInlineTextBox::paintText):
11196        * rendering/svg/SVGInlineTextBox.h:
11197        * rendering/svg/SVGTextMetricsBuilder.cpp:
11198        (WebCore::SVGTextMetricsBuilder::currentCharacterStartsSurrogatePair):
11199        (WebCore::SVGTextMetricsBuilder::advance):
11200        * rendering/svg/SVGTextQuery.cpp:
11201        (WebCore::SVGTextQuery::mapStartEndPositionsIntoFragmentCoordinates):
11202        (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures):
11203        (WebCore::SVGTextQuery::subStringLengthCallback):
11204        (WebCore::SVGTextQuery::startPositionOfCharacterCallback):
11205        (WebCore::SVGTextQuery::endPositionOfCharacterCallback):
11206        (WebCore::SVGTextQuery::rotationOfCharacterCallback):
11207        (WebCore::SVGTextQuery::extentOfCharacterCallback):
11208        (WebCore::SVGTextQuery::characterNumberAtPositionCallback):
11209        * rendering/svg/SVGTextQuery.h:
11210        * rendering/svg/SVGTextRunRenderingContext.cpp:
11211        (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
11212        (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
11213        * rendering/svg/SVGTextRunRenderingContext.h:
11214        * svg/SVGFontData.cpp:
11215        (WebCore::SVGFontData::applySVGGlyphSelection):
11216        * svg/SVGFontData.h:
11217
112182014-06-24  Eric Carlson  <eric.carlson@apple.com>
11219
11220        Unreviewed build fix.
11221
11222        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
11223        (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): Cast variadic argument to int.
11224
112252014-06-24  Brent Fulgham  <bfulgham@apple.com>
11226
11227        [Win] MSVC mishandles enums in bitfields
11228        https://bugs.webkit.org/show_bug.cgi?id=134237
11229
11230        Reviewed by Michael Saboff.
11231
11232        Replace uses of enum types in bit fields with unsigned to
11233        avoid losing a bit to hold the sign value. This can result
11234        in Windows interpreting the value of the field improperly.
11235
11236        * loader/ResourceLoaderOptions.h:
11237        * platform/network/ResourceRequestBase.h:
11238        * platform/network/cf/ResourceResponse.h:
11239        * rendering/RenderLayer.h:
11240        * rendering/RenderMarquee.h:
11241
112422014-06-24  Antti Koivisto  <antti@apple.com>
11243
11244        Try to fix build.
11245
11246        * WebCore.exp.in: Remove duplicate export, this should be in the iOS section only.
11247
112482014-06-24  Eric Carlson  <eric.carlson@apple.com>
11249
11250        [Mac] process raw VTT in-band captions
11251        https://bugs.webkit.org/show_bug.cgi?id=134178
11252
11253        Reviewed by Jer Noble.
11254
11255        * CMakeLists.txt: Add ISOVTTCue.cpp|h.
11256        * WebCore.vcxproj/WebCore.vcxproj: Ditto.
11257        * WebCore.xcodeproj/project.pbxproj: Ditto.
11258
11259        * html/track/BufferedLineReader.h:
11260        (WebCore::BufferedLineReader::reset): New, empty the input buffer.
11261
11262        Make it possible to process WebVTT captions. 
11263        * html/track/InbandGenericTextTrack.cpp:
11264        (WebCore::InbandGenericTextTrack::parser): Allocate, if necessary, and return a WebVTT parser.
11265        (WebCore::InbandGenericTextTrack::parseWebVTTCueData): Pass a cue to the parser.
11266        (WebCore::InbandGenericTextTrack::parseWebVTTFileHeader): Pass a VTT file header to the parser.
11267        (WebCore::InbandGenericTextTrack::newCuesParsed): Parser callback.
11268        (WebCore::InbandGenericTextTrack::newRegionsParsed): Ditto.
11269        (WebCore::InbandGenericTextTrack::fileFailedToParse): Ditto.
11270        * html/track/InbandGenericTextTrack.h:
11271
11272        * html/track/InbandTextTrack.h:
11273
11274        * html/track/InbandWebVTTTextTrack.cpp:
11275        (WebCore::InbandWebVTTTextTrack::parser): New, parser accessor.
11276        (WebCore::InbandWebVTTTextTrack::parseWebVTTCueData): New, parse VTT data in an ISOWebVTTCue
11277            object.
11278        (WebCore::InbandWebVTTTextTrack::newCuesParsed): Cleanup.
11279        (WebCore::InbandWebVTTTextTrack::newRegionsParsed): Implement.
11280        (WebCore::InbandWebVTTTextTrack::fileFailedToParse): Change the error message.
11281        * html/track/InbandWebVTTTextTrack.h:
11282
11283        * html/track/TextTrackCueGeneric.cpp:
11284        (WebCore::TextTrackCueGenericBoxElement::TextTrackCueGenericBoxElement): Change cue parameter
11285            from a pointer to a reference.
11286        (WebCore::TextTrackCueGeneric::createDisplayTree): Ditto.
11287
11288        * html/track/VTTCue.cpp:
11289        (WebCore::VTTCueBox::create): Change cue parameter from a pointer to a reference.
11290        (WebCore::VTTCueBox::VTTCueBox): Ditto.
11291        (WebCore::VTTCueBox::getCue): Return a reference.
11292        (WebCore::VTTCueBox::applyCSSProperties): m_cue is a reference, not a pointer.
11293        (WebCore::VTTCue::create): New, create a VTTCue from WebVTTCueData.
11294        (WebCore::VTTCue::VTTCue): New, internal constructor that takes a WebVTTCueData.
11295        (WebCore::VTTCue::initialize): New, shared constructor initialization.
11296        (WebCore::VTTCue::createDisplayTree): m_cue is a reference, not a pointer.
11297        (WebCore::VTTCue::markFutureAndPastNodes): Ditto.
11298        (WebCore::VTTCue::setCueSettings): Ditto.
11299        * html/track/VTTCue.h:
11300        (WebCore::VTTCueBox::create): Deleted.
11301        (WebCore::VTTCue::create): Deleted.
11302
11303        * html/track/WebVTTParser.cpp:
11304        (WebCore::WebVTTParser::parseFileHeader): New. Reset the line reader buffer and parser state, 
11305            call the parser.
11306        (WebCore::WebVTTParser::parseCueData): Create a cue from ISOWebVTTCue.
11307        (WebCore::WebVTTParser::collectTimingsAndSettings): Return immediately if the string is empty.
11308        (WebCore::WebVTTParser::collectTimeStamp): Ditto.
11309        * html/track/WebVTTParser.h:
11310        (WebCore::WebVTTCueData::originalStartTime): New.
11311        (WebCore::WebVTTCueData::setOriginalStartTime): New.
11312        (WebCore::WebVTTCueData::WebVTTCueData):
11313
11314        * loader/TextTrackLoader.cpp:
11315        (WebCore::TextTrackLoader::getNewCues): Cleanup, use the new VTTCue::create.
11316
11317        Parse ISO WebVTT cue boxes.
11318        * platform/graphics/ISOVTTCue.cpp: Added.
11319        (WebCore::ISOBox::ISOBox):
11320        (WebCore::ISOBox::peekType):
11321        (WebCore::ISOBox::peekLength):
11322        (WebCore::ISOBox::peekString):
11323        (WebCore::vttCueBoxType):
11324        (WebCore::vttIdBoxType):
11325        (WebCore::vttSettingsBoxType):
11326        (WebCore::vttPayloadBoxType):
11327        (WebCore::vttCurrentTimeBoxType):
11328        (WebCore::vttCueSourceIDBoxType):
11329        (WebCore::ISOWebVTTCue::boxType):
11330        (WebCore::ISOWebVTTCue::ISOWebVTTCue):
11331        * platform/graphics/ISOVTTCue.h: Added.
11332        (WebCore::ISOBox::boxHeaderSize):
11333        (WebCore::ISOBox::length):
11334        (WebCore::ISOBox::type):
11335        (WebCore::ISOWebVTTCue::presentationTime):
11336        (WebCore::ISOWebVTTCue::duration):
11337        (WebCore::ISOWebVTTCue::sourceID):
11338        (WebCore::ISOWebVTTCue::id):
11339        (WebCore::ISOWebVTTCue::originalStartTime):
11340        (WebCore::ISOWebVTTCue::settings):
11341        (WebCore::ISOWebVTTCue::cueText):
11342
11343        * platform/graphics/InbandTextTrackPrivateClient.h:
11344        (WebCore::InbandTextTrackPrivateClient::parseWebVTTFileHeader): New.
11345
11346        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
11347        (WebCore::InbandTextTrackPrivateAVF::InbandTextTrackPrivateAVF): Add a cue format parameter.
11348        (WebCore::InbandTextTrackPrivateAVF::processCue): Call processNativeSamples.
11349        (WebCore::InbandTextTrackPrivateAVF::processAttributedStrings): Add logging. Minor cleanup.
11350        (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): New, process an array of 
11351            CMSampleBuffers, create ISOWebVTTCue from the sample data.
11352        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
11353
11354        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.cpp:
11355        (WebCore::InbandTextTrackPrivateAVCF::InbandTextTrackPrivateAVCF):
11356        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.h:
11357        (WebCore::InbandTextTrackPrivateAVCF::create):
11358        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
11359        (WebCore::MediaPlayerPrivateAVFoundationCF::processMediaSelectionOptions):
11360        (WebCore::LegibleOutputData::LegibleOutputData):
11361        (WebCore::AVFWrapper::processCue):
11362        (WebCore::AVFWrapper::legibleOutputCallback):
11363
11364        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
11365        (WebCore::InbandTextTrackPrivateAVFObjC::create): Add a cue format parameter.
11366        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
11367        (WebCore::InbandTextTrackPrivateAVFObjC::InbandTextTrackPrivateAVFObjC): Ditto.
11368
11369        * platform/graphics/avfoundation/InbandTextTrackPrivateLegacyAVFObjC.cpp:
11370        (WebCore::InbandTextTrackPrivateLegacyAVFObjC::InbandTextTrackPrivateLegacyAVFObjC): Pass cue
11371            format to base class.
11372
11373        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
11374        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
11375        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Improve logging.
11376        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Don't leak an NSDictionary.
11377        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Don't process media selection
11378            options until we have tracks.
11379        (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions): 
11380        (WebCore::MediaPlayerPrivateAVFoundationObjC::processCue): Pass native samples as well as 
11381            attributed strings to track.
11382        (-[WebCoreAVFMovieObserver legibleOutput:didOutputAttributedStrings:nativeSampleBuffers:forItemTime:]):
11383        * platform/graphics/avfoundation/objc/OutOfBandTextTrackPrivateAVF.h:
11384        (WebCore::OutOfBandTextTrackPrivateAVF::OutOfBandTextTrackPrivateAVF):
11385
11386        * platform/graphics/avfoundation/objc/OutOfBandTextTrackPrivateAVF.h:
11387        (WebCore::OutOfBandTextTrackPrivateAVF::OutOfBandTextTrackPrivateAVF):
11388
113892014-06-24  Antti Koivisto  <antti@apple.com>
11390
11391        Only flush layers when the exposed rect actually changes
11392        https://bugs.webkit.org/show_bug.cgi?id=134248
11393
11394        Reviewed by Anders Carlsson.
11395
11396        * WebCore.exp.in:
11397
113982014-06-24  Brady Eidson  <beidson@apple.com>
11399
11400        Remove references to "Shader.h" which doesn't currently exist in the project.
11401
11402        Rubberstamped by Andreas Kling.
11403
11404        * WebCore.xcodeproj/project.pbxproj:
11405
114062014-06-24  Martin Hock  <mhock@apple.com>
11407
11408        [iOS] DOMWindow::outerWidth and outerHeight don't return useful values, so return 0.
11409        Also, revert r169281.
11410        https://bugs.webkit.org/show_bug.cgi?id=134233
11411        <rdar://problem/17060183>
11412
11413        Reviewed by Benjamin Poulain.
11414
11415        * page/DOMWindow.cpp:
11416        (WebCore::DOMWindow::outerHeight):
11417        (WebCore::DOMWindow::outerWidth):
11418
114192014-06-24  Jeremy Jones  <jeremyj@apple.com>
11420
11421        Don't set AudioSession active while interrupted.
11422        https://bugs.webkit.org/show_bug.cgi?id=134239
11423
11424        Reviewed by Eric Carlson.
11425
11426        To activate the AudioSession there must be a session with audio or video
11427        and being playing or paused.
11428
11429        * platform/audio/MediaSessionManager.cpp:
11430        (WebCore::MediaSessionManager::hasActive): added
11431        (WebCore::MediaSessionManager::beginInterruption): updateSessionState
11432        (WebCore::MediaSessionManager::sessionWillBeginPlayback): updateSessionState
11433        * platform/audio/MediaSessionManager.h: declare hasActive()
11434        * platform/audio/mac/MediaSessionManagerMac.cpp:
11435        (MediaSessionManager::updateSessionState): use hasActive()
11436
114372014-06-24  Jer Noble  <jer.noble@apple.com>
11438
11439        REGRESSION(r170336): Crash in HTMLMediaElement::seekTimerFired()
11440        https://bugs.webkit.org/show_bug.cgi?id=134253
11441
11442        Rubber-stamped by Eric Carlson.
11443
11444        Now that seekWithTolerance() has been split up into an asyncronous section, the null-checks in seekWithTolerance()
11445        need to be re-performed in seekTimerFired(), in case the m_player has been cleared between when the seek was initiated
11446        and when the asynchronous section is performed.
11447
11448        * html/HTMLMediaElement.cpp:
11449        (WebCore::HTMLMediaElement::seekTimerFired):
11450
114512014-06-24  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
11452
11453        Fix unused parameter warnings if inspector is disabled
11454        https://bugs.webkit.org/show_bug.cgi?id=134244
11455
11456        Reviewed by Zalan Bujtas.
11457
11458        No new tests, no behavior change.
11459
11460        * inspector/InspectorConsoleInstrumentation.h:
11461        (WebCore::InspectorInstrumentation::startProfiling):
11462        (WebCore::InspectorInstrumentation::stopProfiling):
11463        * inspector/InspectorInstrumentation.h:
11464        (WebCore::InspectorInstrumentation::didFinishXHRLoading):
11465        * loader/cache/CachedResourceLoader.cpp:
11466        (WebCore::CachedResourceLoader::shouldContinueAfterNotifyingLoadedFromMemoryCache):
11467
114682014-06-24  Jer Noble  <jer.noble@apple.com>
11469
11470        [MSE] Add null-check in sourceBufferPrivateAppendComplete().
11471        https://bugs.webkit.org/show_bug.cgi?id=133230
11472
11473        Reviewed by Eric Carlson.
11474
11475        * Modules/mediasource/SourceBuffer.cpp:
11476        (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete): Bail early if the 
11477            SourceBuffer has been removed from the MediaSource.
11478
114792014-06-24  Commit Queue  <commit-queue@webkit.org>
11480
11481        Unreviewed, rolling out r170337.
11482        https://bugs.webkit.org/show_bug.cgi?id=134250
11483
11484        caused 3 layout tests to crash on debug. (Requested by zalan
11485        on #webkit).
11486
11487        Reverted changeset:
11488
11489        "Use unsigneds instead of ints for indexes into a string in
11490        text layout code"
11491        https://bugs.webkit.org/show_bug.cgi?id=133592
11492        http://trac.webkit.org/changeset/170337
11493
114942014-06-24  Jarek Czekalski  <jarekczek@poczta.onet.pl>
11495
11496        [ATK] Don't ignore links rendered as blocks.
11497        https://bugs.webkit.org/show_bug.cgi?id=130941
11498
11499        Reviewed by Mario Sanchez Prada.
11500
11501        * /m/usr/src/webkit-trunk/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
11502        (WebCore::AccessibilityObject::objectFocusedAndCaretOffsetUnignored): Don't ignore links
11503        when they are renderered with display:block.
11504
115052014-06-24  Carlos Garcia Campos  <cgarcia@igalia.com>
11506
11507        Unreviewed. Update GObject DOM bindings test results after r170351.
11508
11509        * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
11510        * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:
11511
115122014-06-24  Carlos Garcia Campos  <cgarcia@igalia.com>
11513
11514        Unreviewed. Fix GTK+ build after r170309.
11515
11516        Skip functions returning arrays in GObject DOM bindings.
11517
11518        * bindings/scripts/CodeGeneratorGObject.pm:
11519        (SkipFunction):
11520
115212014-06-23  Ryuan Choi  <ryuan.choi@samsung.com>
11522
11523        [EFL] Replace RefPtr<Evas_Object> with UniquePtrEfl
11524        https://bugs.webkit.org/show_bug.cgi?id=134236
11525
11526        Reviewed by Gyuyoung Kim.
11527
11528        * platform/efl/RenderThemeEfl.cpp:
11529        (WebCore::RenderThemeEfl::ThemePartCacheEntry::create):
11530        (WebCore::RenderThemeEfl::loadTheme):
11531        (WebCore::RenderThemeEfl::applyPartDescriptionsFrom):
11532        * platform/efl/RenderThemeEfl.h:
11533        * platform/graphics/efl/CairoUtilitiesEfl.cpp:
11534        (WebCore::evasObjectFromCairoImageSurface):
11535        * platform/graphics/efl/CairoUtilitiesEfl.h:
11536        * platform/graphics/efl/ImageEfl.cpp:
11537        (WebCore::BitmapImage::getEvasObject):
11538
115392014-06-23  Jeremy Jones  <jeremyj@apple.com>
11540
11541        Chapter forward/backward should seek to beginning/end.
11542        https://bugs.webkit.org/show_bug.cgi?id=134225
11543
11544        Reviewed by Eric Carlson.
11545
11546        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
11547        (-[WebAVPlayerController seekChapterBackward:]): forwards to -seekToBeginning
11548        (-[WebAVPlayerController seekChapterForward:]): forwards to -seekToEnd
11549
115502014-06-23  Dean Jackson  <dino@apple.com>
11551
11552        [Mac] Don't draw focus rings if we are animating controls
11553        https://bugs.webkit.org/show_bug.cgi?id=134232
11554        <rdar://problem/17381121>
11555
11556        Reviewed by Tim Horton.
11557
11558        Controls in native apps do not draw their focus rings as they
11559        animate (in Yosemite). Turn this off for WebKit too. It turns
11560        out that when we were drawing them, they were in the wrong
11561        place anyway.
11562
11563        Since we don't animate controls when testing, we can't really test this.
11564
11565        * platform/mac/ThemeMac.mm:
11566        (WebCore::paintToggleButton): Only draw the focus ring if the
11567        NSButtonCell is not animating.
11568
115692014-06-23  Krzysztof Czech  <k.czech@samsung.com>
11570
11571        [ATK] Remove some unnecessary code from WebKitAccessibleWrapperAtk
11572        https://bugs.webkit.org/show_bug.cgi?id=134193
11573
11574        Reviewed by Gyuyoung Kim.
11575
11576        It was used along with DRT. Since we have stopped support WK1/DRT, it won't be needed.
11577
11578        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
11579        (webkitAccessibleGetFocusedElement): Deleted.
11580        * accessibility/atk/WebKitAccessibleWrapperAtk.h:
11581
115822014-06-20  Myles C. Maxfield  <mmaxfield@apple.com>
11583
11584        Use unsigneds instead of ints for indexes into a string in text layout code
11585        https://bugs.webkit.org/show_bug.cgi?id=133592
11586
11587        Reviewed by Zalan Bujtas.
11588
11589        Migrate much of the text-handling code to use unsigneds for indexes into a string.
11590
11591        No new tests because there is no behavior change.
11592
11593        * WebCore.exp.in:
11594        * platform/graphics/Font.cpp:
11595        (WebCore::Font::drawText):
11596        (WebCore::Font::drawEmphasisMarks):
11597        (WebCore::Font::adjustSelectionRectForText):
11598        (WebCore::computeUnderlineType):
11599        * platform/graphics/Font.h:
11600        * platform/graphics/FontFastPath.cpp:
11601        (WebCore::Font::getGlyphsAndAdvancesForSimpleText):
11602        (WebCore::Font::drawSimpleText):
11603        (WebCore::Font::drawEmphasisMarksForSimpleText):
11604        (WebCore::Font::drawGlyphBuffer):
11605        (WebCore::Font::drawEmphasisMarks):
11606        (WebCore::Font::adjustSelectionRectForSimpleText):
11607        * platform/graphics/GlyphBuffer.h:
11608        (WebCore::GlyphBuffer::size):
11609        (WebCore::GlyphBuffer::glyphs):
11610        (WebCore::GlyphBuffer::advances):
11611        (WebCore::GlyphBuffer::fontDataAt):
11612        (WebCore::GlyphBuffer::advanceAt):
11613        (WebCore::GlyphBuffer::offsetAt):
11614        (WebCore::GlyphBuffer::reverse):
11615        (WebCore::GlyphBuffer::offsetInString):
11616        (WebCore::GlyphBuffer::swap):
11617        * platform/graphics/GraphicsContext.cpp:
11618        (WebCore::TextRunIterator::atEnd):
11619        * platform/graphics/Latin1TextIterator.h:
11620        (WebCore::Latin1TextIterator::Latin1TextIterator):
11621        (WebCore::Latin1TextIterator::currentCharacter):
11622        * platform/graphics/SimpleFontData.h:
11623        * platform/graphics/SurrogatePairAwareTextIterator.cpp:
11624        (WebCore::SurrogatePairAwareTextIterator::SurrogatePairAwareTextIterator):
11625        * platform/graphics/SurrogatePairAwareTextIterator.h:
11626        (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
11627        * platform/graphics/TextRun.h:
11628        (WebCore::TextRun::length):
11629        (WebCore::TextRun::charactersLength):
11630        * platform/graphics/WidthIterator.cpp:
11631        (WebCore::WidthIterator::glyphDataForCharacter):
11632        (WebCore::applyFontTransforms):
11633        (WebCore::WidthIterator::advanceInternal):
11634        (WebCore::WidthIterator::advance):
11635        (WebCore::WidthIterator::advanceOneCharacter):
11636        * platform/graphics/WidthIterator.h:
11637        * platform/graphics/cairo/FontCairo.cpp:
11638        (WebCore::Font::drawGlyphs):
11639        * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
11640        (WebCore::Font::drawComplexText):
11641        (WebCore::Font::drawEmphasisMarksForComplexText):
11642        (WebCore::Font::adjustSelectionRectForComplexText):
11643        * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
11644        (WebCore::HarfBuzzShaper::setNormalizedBuffer):
11645        * platform/graphics/mac/FontComplexTextMac.cpp:
11646        (WebCore::Font::adjustSelectionRectForComplexText):
11647        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
11648        (WebCore::Font::drawComplexText):
11649        (WebCore::Font::drawEmphasisMarksForComplexText):
11650        * platform/graphics/mac/FontMac.mm:
11651        (WebCore::Font::drawGlyphs):
11652        * platform/graphics/win/FontCGWin.cpp:
11653        (WebCore::Font::drawGlyphs):
11654        * platform/graphics/win/FontWin.cpp:
11655        (WebCore::Font::adjustSelectionRectForComplexText):
11656        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
11657        (WebCore::Font::drawComplexText):
11658        (WebCore::Font::drawEmphasisMarksForComplexText):
11659        * platform/graphics/wince/FontWinCE.cpp:
11660        (WebCore::Font::drawGlyphs):
11661        (WebCore::Font::drawComplexText):
11662        (WebCore::Font::drawEmphasisMarksForComplexText):
11663        (WebCore::Font::selectionRectForComplexText):
11664        * rendering/InlineTextBox.cpp:
11665        (WebCore::InlineTextBox::isSelected):
11666        (WebCore::InlineTextBox::selectionState):
11667        (WebCore::adjustCharactersAndLengthForHyphen):
11668        (WebCore::InlineTextBox::localSelectionRect):
11669        (WebCore::InlineTextBox::paint):
11670        (WebCore::InlineTextBox::selectionStartEnd):
11671        (WebCore::InlineTextBox::paintSelection):
11672        (WebCore::InlineTextBox::paintCompositionBackground):
11673        (WebCore::InlineTextBox::paintDocumentMarker):
11674        (WebCore::InlineTextBox::paintTextMatchMarker):
11675        (WebCore::InlineTextBox::computeRectForReplacementMarker):
11676        (WebCore::InlineTextBox::paintCompositionUnderline):
11677        (WebCore::InlineTextBox::positionForOffset):
11678        (WebCore::InlineTextBox::constructTextRun):
11679        * rendering/InlineTextBox.h:
11680        * rendering/RenderCombineText.cpp:
11681        (WebCore::RenderCombineText::getStringToRender):
11682        * rendering/RenderCombineText.h:
11683        * rendering/svg/SVGInlineFlowBox.cpp:
11684        (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
11685        * rendering/svg/SVGInlineTextBox.cpp:
11686        (WebCore::SVGInlineTextBox::positionForOffset):
11687        (WebCore::SVGInlineTextBox::localSelectionRect):
11688        (WebCore::SVGInlineTextBox::paintSelectionBackground):
11689        (WebCore::SVGInlineTextBox::mapStartEndPositionsIntoFragmentCoordinates):
11690        (WebCore::SVGInlineTextBox::paintText):
11691        * rendering/svg/SVGInlineTextBox.h:
11692        * rendering/svg/SVGTextMetricsBuilder.cpp:
11693        (WebCore::SVGTextMetricsBuilder::currentCharacterStartsSurrogatePair):
11694        (WebCore::SVGTextMetricsBuilder::advance):
11695        * rendering/svg/SVGTextQuery.cpp:
11696        (WebCore::SVGTextQuery::mapStartEndPositionsIntoFragmentCoordinates):
11697        (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures):
11698        (WebCore::SVGTextQuery::subStringLengthCallback):
11699        (WebCore::SVGTextQuery::startPositionOfCharacterCallback):
11700        (WebCore::SVGTextQuery::endPositionOfCharacterCallback):
11701        (WebCore::SVGTextQuery::rotationOfCharacterCallback):
11702        (WebCore::SVGTextQuery::extentOfCharacterCallback):
11703        (WebCore::SVGTextQuery::characterNumberAtPositionCallback):
11704        * rendering/svg/SVGTextQuery.h:
11705        * rendering/svg/SVGTextRunRenderingContext.cpp:
11706        (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
11707        (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
11708        * rendering/svg/SVGTextRunRenderingContext.h:
11709        * svg/SVGFontData.cpp:
11710        (WebCore::SVGFontData::applySVGGlyphSelection):
11711        * svg/SVGFontData.h:
11712
117132014-06-20  Jer Noble  <jer.noble@apple.com>
11714
11715        HTMLMediaElement seek algorithm should allow cancelling previous seeks.
11716        https://bugs.webkit.org/show_bug.cgi?id=134116
11717
11718        Reviewed by Eric Carlson.
11719
11720        Test: media/video-seek-double.html
11721
11722        Fulfill the requirement of the §4.7.14.9 seeking algorithm to do steps 5+ asynchronously and cancel
11723        previous instances of the algorithm.
11724
11725        For the html/ parts of the algorithm, implement this by adding a seek timer, which when fired will
11726        issue steps 5-12. MediaPlayerPrivateAVFoundation will already coalesce multiple seek operations, so nothing
11727        additional needs be done there.  However, MediaPlayerPrivateMediaSourceAVFObjC needs to implement the same
11728        pending seek logic in case additional seeks were issued after the html/ algorithm reached step 12.
11729
11730        * html/HTMLMediaElement.cpp:
11731        (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize the new m_seekTimer.
11732        (WebCore::HTMLMediaElement::parseAttribute): Clear the seek timer.
11733        (WebCore::HTMLMediaElement::seekInternal): Differentiate between DOM seeks and internal seeks.
11734        (WebCore::HTMLMediaElement::seekWithTolerance:) Split into the seekTimerFired() method.
11735        (WebCore::HTMLMediaElement::seekTimerFired:) Added, split from seekWithTolerance().
11736        * html/HTMLMediaElement.h:
11737        * html/MediaController.cpp:
11738        (MediaController::bringElementUpToSpeed): Call seekInternal().
11739        (WebCore::HTMLMediaElement::PendingSeek::PendingSeek): Added convenience struct for storing seek requests.
11740        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
11741        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::PendingSeek::PendingSeek): Ditto.
11742        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
11743        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC): Modify the time jumped
11744            handler to not clear the m_seeking flag if another seek request is pending.
11745        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekWithTolerance):
11746        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
11747
117482014-06-23  Timothy Horton  <timothy_horton@apple.com>
11749
11750        [WK2] Use the page background color instead of white when swipe snapshots were purged (134218)
11751        https://bugs.webkit.org/show_bug.cgi?id=134218
11752        <rdar://problem/17426454>
11753
11754        Reviewed by Benjamin Poulain.
11755
11756        * WebCore.exp.in:
11757
117582014-06-23  Eric Carlson  <eric.carlson@apple.com>
11759
11760        [iOS] remove InbandTextTrackPrivateAVFIOS
11761        https://bugs.webkit.org/show_bug.cgi?id=134220
11762
11763        Reviewed by Benjamin Poulain.
11764
11765        * WebCore.xcodeproj/project.pbxproj: Remove references to InbandTextTrackPrivateAVFIOS.
11766
11767        * platform/graphics/ios/InbandTextTrackPrivateAVFIOS.h: Removed.
11768        * platform/graphics/ios/InbandTextTrackPrivateAVFIOS.mm: Removed.
11769
117702014-06-23  Commit Queue  <commit-queue@webkit.org>
11771
11772        Unreviewed, rolling out r170323.
11773        https://bugs.webkit.org/show_bug.cgi?id=134224
11774
11775        lots of build breakage (Requested by bradeeoh on #webkit).
11776
11777        Reverted changeset:
11778
11779        "[Mac] process raw VTT in-band captions"
11780        https://bugs.webkit.org/show_bug.cgi?id=134178
11781        http://trac.webkit.org/changeset/170323
11782
117832014-06-23  Jeffrey Pfau  <jpfau@apple.com>
11784
11785        Fix release build
11786
11787        * Modules/indexeddb/IDBTransactionCoordinator.cpp:
11788        (WebCore::IDBTransactionCoordinator::canRunTransaction):
11789
117902014-06-19  Jeffrey Pfau  <jpfau@apple.com>
11791
11792        Database process crashes when multiple transactions attempt to run at once
11793        https://bugs.webkit.org/show_bug.cgi?id=134139
11794
11795        Reviewed by David Kilzer.
11796
11797        Ensure that only one transaction can be running at a time.
11798
11799        Test: storage/indexeddb/transaction-overlapping.html
11800
11801        * Modules/indexeddb/IDBTransactionCoordinator.cpp:
11802        (WebCore::IDBTransactionCoordinator::canRunTransaction):
11803
118042014-06-23  Benjamin Poulain  <bpoulain@apple.com>
11805
11806        [iOS][WK2] Make the state restore from HistoryItem more precise and reliable
11807        https://bugs.webkit.org/show_bug.cgi?id=134150
11808
11809        Reviewed by Tim Horton.
11810
11811        The two biggest changes for WebCore are:
11812        -Store everything we need to handle changes of ViewportConfiguration on HistoryItem.
11813        -Store the exposedRect with floating point coordinates.
11814
11815        * WebCore.exp.in:
11816        * history/CachedPage.cpp:
11817        (WebCore::CachedPage::restore):
11818        We cannot determine a good scroll position from the WebProcess because the obscured insets can change
11819        arbitrarily in the UIProcess. When we scroll here from the WebProcess, we would force an invalid position
11820        to the UIProcess with the next layer tree update.
11821
11822        To avoid any problem, we prohibit scrolling when restoring the focus appearance.
11823
11824        * history/HistoryItem.cpp:
11825        (WebCore::encodeRect):
11826        (WebCore::encodeSize):
11827        (WebCore::HistoryItem::encodeBackForwardTreeNode):
11828        (WebCore::decodeRect):
11829        (WebCore::decodeSize):
11830        (WebCore::HistoryItem::decodeBackForwardTree):
11831        * history/HistoryItem.h:
11832        (WebCore::HistoryItem::exposedContentRect):
11833        (WebCore::HistoryItem::setExposedContentRect):
11834        (WebCore::HistoryItem::unobscuredContentRect):
11835        (WebCore::HistoryItem::setUnobscuredContentRect):
11836        (WebCore::HistoryItem::minimumLayoutSizeInScrollViewCoordinates):
11837        (WebCore::HistoryItem::setMinimumLayoutSizeInScrollViewCoordinates):
11838        (WebCore::HistoryItem::contentSize):
11839        (WebCore::HistoryItem::setContentSize):
11840        (WebCore::HistoryItem::exposedContentPosition): Deleted.
11841        (WebCore::HistoryItem::setExposedContentPosition): Deleted.
11842        * loader/HistoryController.cpp:
11843        (WebCore::HistoryController::saveScrollPositionAndViewStateToItem):
11844        * page/FrameView.h:
11845        * platform/ScrollView.h:
11846        * platform/ios/ScrollViewIOS.mm:
11847        (WebCore::ScrollView::exposedContentRect):
11848        (WebCore::ScrollView::setExposedContentRect):
11849        * rendering/RenderLayerCompositor.cpp:
11850        (WebCore::RenderLayerCompositor::didChangeVisibleRect):
11851
118522014-06-23  Eric Carlson  <eric.carlson@apple.com>
11853
11854        [Mac] process raw VTT in-band captions
11855        https://bugs.webkit.org/show_bug.cgi?id=134178
11856
11857        Reviewed by Jer Noble.
11858
11859        * CMakeLists.txt: Add ISOVTTCue.cpp|h.
11860        * WebCore.vcxproj/WebCore.vcxproj: Ditto.
11861        * WebCore.xcodeproj/project.pbxproj: Ditto.
11862
11863        * html/track/BufferedLineReader.h:
11864        (WebCore::BufferedLineReader::reset): New, empty the input buffer.
11865
11866        Make it possible to process WebVTT captions. 
11867        * html/track/InbandGenericTextTrack.cpp:
11868        (WebCore::InbandGenericTextTrack::parser): Allocate, if necessary, and return a WebVTT parser.
11869        (WebCore::InbandGenericTextTrack::parseWebVTTCueData): Pass a cue to the parser.
11870        (WebCore::InbandGenericTextTrack::parseWebVTTFileHeader): Pass a VTT file header to the parser.
11871        (WebCore::InbandGenericTextTrack::newCuesParsed): Parser callback.
11872        (WebCore::InbandGenericTextTrack::newRegionsParsed): Ditto.
11873        (WebCore::InbandGenericTextTrack::fileFailedToParse): Ditto.
11874        * html/track/InbandGenericTextTrack.h:
11875
11876        * html/track/InbandTextTrack.h:
11877
11878        * html/track/InbandWebVTTTextTrack.cpp:
11879        (WebCore::InbandWebVTTTextTrack::parser): New, parser accessor.
11880        (WebCore::InbandWebVTTTextTrack::parseWebVTTCueData): New, parse VTT data in an ISOWebVTTCue
11881            object.
11882        (WebCore::InbandWebVTTTextTrack::newCuesParsed): Cleanup.
11883        (WebCore::InbandWebVTTTextTrack::newRegionsParsed): Implement.
11884        (WebCore::InbandWebVTTTextTrack::fileFailedToParse): Change the error message.
11885        * html/track/InbandWebVTTTextTrack.h:
11886
11887        * html/track/TextTrackCueGeneric.cpp:
11888        (WebCore::TextTrackCueGenericBoxElement::TextTrackCueGenericBoxElement): Change cue parameter
11889            from a pointer to a reference.
11890        (WebCore::TextTrackCueGeneric::createDisplayTree): Ditto.
11891
11892        * html/track/VTTCue.cpp:
11893        (WebCore::VTTCueBox::create): Change cue parameter from a pointer to a reference.
11894        (WebCore::VTTCueBox::VTTCueBox): Ditto.
11895        (WebCore::VTTCueBox::getCue): Return a reference.
11896        (WebCore::VTTCueBox::applyCSSProperties): m_cue is a reference, not a pointer.
11897        (WebCore::VTTCue::create): New, create a VTTCue from WebVTTCueData.
11898        (WebCore::VTTCue::VTTCue): New, internal constructor that takes a WebVTTCueData.
11899        (WebCore::VTTCue::initialize): New, shared constructor initialization.
11900        (WebCore::VTTCue::createDisplayTree): m_cue is a reference, not a pointer.
11901        (WebCore::VTTCue::markFutureAndPastNodes): Ditto.
11902        (WebCore::VTTCue::setCueSettings): Ditto.
11903        * html/track/VTTCue.h:
11904        (WebCore::VTTCueBox::create): Deleted.
11905        (WebCore::VTTCue::create): Deleted.
11906
11907        * html/track/WebVTTParser.cpp:
11908        (WebCore::WebVTTParser::parseFileHeader): New. Reset the line reader buffer and parser state, 
11909            call the parser.
11910        (WebCore::WebVTTParser::parseCueData): Create a cue from ISOWebVTTCue.
11911        (WebCore::WebVTTParser::collectTimingsAndSettings): Return immediately if the string is empty.
11912        (WebCore::WebVTTParser::collectTimeStamp): Ditto.
11913        * html/track/WebVTTParser.h:
11914        (WebCore::WebVTTCueData::originalStartTime): New.
11915        (WebCore::WebVTTCueData::setOriginalStartTime): New.
11916        (WebCore::WebVTTCueData::WebVTTCueData):
11917
11918        * loader/TextTrackLoader.cpp:
11919        (WebCore::TextTrackLoader::getNewCues): Cleanup, use the new VTTCue::create.
11920
11921        * platform/graphics/InbandTextTrackPrivateClient.h:
11922        (WebCore::InbandTextTrackPrivateClient::parseWebVTTFileHeader): New.
11923
11924        Parse ISO WebVTT cue boxes.
11925        * platform/graphics/ISOVTTCue.cpp: Added.
11926        (WebCore::ISOBox::ISOBox):
11927        (WebCore::ISOBox::peekType):
11928        (WebCore::ISOBox::peekLength):
11929        (WebCore::ISOBox::peekString):
11930        (WebCore::vttCueBoxType):
11931        (WebCore::vttIdBoxType):
11932        (WebCore::vttSettingsBoxType):
11933        (WebCore::vttPayloadBoxType):
11934        (WebCore::vttCurrentTimeBoxType):
11935        (WebCore::vttCueSourceIDBoxType):
11936        (WebCore::ISOWebVTTCue::boxType):
11937        (WebCore::ISOWebVTTCue::ISOWebVTTCue):
11938        * platform/graphics/ISOVTTCue.h: Added.
11939        (WebCore::ISOBox::boxHeaderSize):
11940        (WebCore::ISOBox::length):
11941        (WebCore::ISOBox::type):
11942        (WebCore::ISOWebVTTCue::presentationTime):
11943        (WebCore::ISOWebVTTCue::duration):
11944        (WebCore::ISOWebVTTCue::sourceID):
11945        (WebCore::ISOWebVTTCue::id):
11946        (WebCore::ISOWebVTTCue::originalStartTime):
11947        (WebCore::ISOWebVTTCue::settings):
11948        (WebCore::ISOWebVTTCue::cueText):
11949
11950        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
11951        (WebCore::InbandTextTrackPrivateAVF::InbandTextTrackPrivateAVF): Add a cue format parameter.
11952        (WebCore::InbandTextTrackPrivateAVF::processCue): Call processNativeSamples.
11953        (WebCore::InbandTextTrackPrivateAVF::processAttributedStrings): Add logging. Minor cleanup.
11954        (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): New, process an array of 
11955            CMSampleBuffers, create ISOWebVTTCue from the sample data.
11956        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
11957
11958        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
11959        (WebCore::InbandTextTrackPrivateAVFObjC::create): Add a cue format parameter.
11960        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
11961        (WebCore::InbandTextTrackPrivateAVFObjC::InbandTextTrackPrivateAVFObjC): Ditto.
11962
11963        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
11964        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
11965        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Improve logging.
11966        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Don't leak an NSDictionary.
11967        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Don't process media selection
11968            options until we have tracks.
11969        (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions): 
11970        (WebCore::MediaPlayerPrivateAVFoundationObjC::processCue): Pass native samples as well as 
11971            attributed strings to track.
11972        (-[WebCoreAVFMovieObserver legibleOutput:didOutputAttributedStrings:nativeSampleBuffers:forItemTime:]):
11973        * platform/graphics/avfoundation/objc/OutOfBandTextTrackPrivateAVF.h:
11974        (WebCore::OutOfBandTextTrackPrivateAVF::OutOfBandTextTrackPrivateAVF):
11975
11976        * platform/graphics/avfoundation/InbandTextTrackPrivateLegacyAVFObjC.cpp:
11977        (WebCore::InbandTextTrackPrivateLegacyAVFObjC::InbandTextTrackPrivateLegacyAVFObjC): Pass cue
11978            format to base class.
11979
11980        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.cpp:
11981        (WebCore::InbandTextTrackPrivateAVCF::InbandTextTrackPrivateAVCF): Ditto.
11982        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.h:
11983
119842014-06-23  Jer Noble  <jer.noble@apple.com>
11985
11986        [MSE][Mac] Crash in SourceBuffer::sourceBufferPrivateDidReceiveRenderingError()
11987        https://bugs.webkit.org/show_bug.cgi?id=134211
11988
11989        Reviewed by Eric Carlson.
11990
11991        Null-check m_source before dereferencing, as the SourceBuffer may have been removed
11992        from its MediaSource before this error was received.
11993
11994        * Modules/mediasource/SourceBuffer.cpp:
11995        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveRenderingError):
11996
119972014-06-23  Joseph Pecoraro  <pecoraro@apple.com>
11998
11999        Reduce synchronous layout triggered by JavaScript-based media controls
12000        https://bugs.webkit.org/show_bug.cgi?id=134208
12001
12002        Reviewed by Eric Carlson.
12003
12004        Avoid always querying the offsetWidth and offsetHeight of the timeline
12005        by only calculating these values when the timeline may change size.
12006        Also avoid doing work in a few cases where properties did not
12007        actually change.
12008
12009        * Modules/mediacontrols/mediaControlsApple.js:
12010        (Controller):
12011
12012        (Controller.prototype.setNeedsTimelineMetricsUpdate):
12013        (Controller.prototype.updateTimelineMetricsIfNeeded):
12014        Only update the timeline metrics when they may have changed.
12015
12016        (Controller.prototype.updateControls):
12017        (Controller.prototype.handleTimelineMouseMove):
12018        (Controller.prototype.progressFillStyle):
12019        (Controller.prototype.showControls):
12020        (Controller.prototype.addControls):
12021        Mark timeline metrics need update based on various UI changes.
12022
12023        (Controller.prototype.setStatusHidden):
12024        Only do work if the hidden status changed.
12025        Mark timeline metrics need update if the timeline is changed.
12026
12027        (Controller.prototype.updateProgress):
12028        Use cached timeline metrics instead of always querying offsetWidth/offsetHeight.
12029
12030        * Modules/mediacontrols/mediaControlsiOS.js:
12031        (ControllerIOS):
12032        (ControllerIOS.prototype.updateControls):
12033
12034        (ControllerIOS.prototype.updateProgress):
12035        Use cached timeline metrics instead of always querying offsetWidth/offsetHeight.
12036
12037        (ControllerIOS.prototype.handleWirelessPlaybackChange):
12038        Mark timeline metrics need update as button may have changed.
12039
12040        (ControllerIOS.prototype.handleWirelessTargetAvailableChange):
12041        Only do work if the availability changed.
12042        Mark timeline metrics need update as a new button may have appeared.
12043
12044        (ControllerIOS.prototype.set pageScaleFactor):
12045        Only do work if the page scale factor changed.
12046
120472014-06-23  Brady Eidson  <beidson@apple.com>
12048
12049        Add skeleton code for updated Gamepad API
12050        https://bugs.webkit.org/show_bug.cgi?id=134165
12051
12052        Unreviewed - Forgotten review feedback from http://trac.webkit.org/changeset/170309
12053
12054        * Modules/gamepad/GamepadButton.idl: Forgot to commit the removal of NoInterfaceObject here.
12055
120562014-06-23  Brady Eidson  <beidson@apple.com>
12057
12058        Add skeleton code for updated Gamepad API
12059        https://bugs.webkit.org/show_bug.cgi?id=134165
12060
12061        Reviewed by Dean Jackson.
12062
12063        No new tests (No change in behavior for any tested configuration)
12064
12065        Interface and dummy implementation for the Gamepad object:
12066        * Modules/gamepad/Gamepad.cpp: Added.
12067        (WebCore::Gamepad::Gamepad):
12068        (WebCore::Gamepad::~Gamepad):
12069        (WebCore::Gamepad::axes):
12070        (WebCore::Gamepad::buttons):
12071        * Modules/gamepad/Gamepad.h: Added.
12072        * Modules/gamepad/Gamepad.idl: Added.
12073
12074        Interface and dummy implementation for the GamepadButton object:
12075        * Modules/gamepad/GamepadButton.cpp: Added.
12076        (WebCore::GamepadButton::GamepadButton):
12077        (WebCore::GamepadButton::pressed):
12078        * Modules/gamepad/GamepadButton.h: Added.
12079        (WebCore::GamepadButton::create):
12080        (WebCore::GamepadButton::value):
12081        (WebCore::GamepadButton::setValue):
12082        * Modules/gamepad/GamepadButton.idl: Added.
12083
12084        Interface and dummy implementation for the GamepadEvent object:
12085        * Modules/gamepad/GamepadEvent.cpp: Added.
12086        (WebCore::GamepadEvent::GamepadEvent):
12087        * Modules/gamepad/GamepadEvent.h: Added.
12088        (WebCore::GamepadEventInit::GamepadEventInit):
12089        (WebCore::GamepadEvent::~GamepadEvent):
12090        (WebCore::GamepadEvent::create):
12091        (WebCore::GamepadEvent::gamepad):
12092        * Modules/gamepad/GamepadEvent.idl: Added.
12093        * dom/EventNames.in:
12094
12095        Interface and dummy implementation for additions to the Navigator object:
12096        * Modules/gamepad/NavigatorGamepad.cpp: Added.
12097        (WebCore::NavigatorGamepad::NavigatorGamepad):
12098        (WebCore::NavigatorGamepad::supplementName):
12099        (WebCore::NavigatorGamepad::from):
12100        (WebCore::NavigatorGamepad::getGamepads):
12101        (WebCore::NavigatorGamepad::gamepads):
12102        * Modules/gamepad/NavigatorGamepad.h: Added.
12103        * Modules/gamepad/NavigatorGamepad.idl: Added.
12104
12105        Bindings additions necessary for these new interfaces:
12106        * bindings/js/JSDOMBinding.h:
12107        (WebCore::JSValueTraits<double>::arrayJSValue):
12108        * bindings/js/JSDictionary.cpp:
12109        (WebCore::JSDictionary::convertValue):
12110        * bindings/js/JSDictionary.h:
12111
12112        Project file stuff:
12113        * CMakeLists.txt:
12114        * WebCore.vcxproj/WebCore.vcxproj:
12115        * WebCore.vcxproj/WebCoreCommon.props:
12116        * WebCore.vcxproj/copyForwardingHeaders.cmd:
12117        * WebCore.xcodeproj/project.pbxproj:
12118        * DerivedSources.make:
12119
121202014-06-23  Simon Fraser  <simon.fraser@apple.com>
12121
12122        Catch Obj-C exceptions thrown by _linenPatternImage
12123        https://bugs.webkit.org/show_bug.cgi?id=134202
12124
12125        Reviewed by Geoffrey Garen.
12126
12127        Catch Objective-C exceptions thrown by _linenPatternImage and
12128        -[NSImage CGImageForProposedRect:context:hints:].
12129
12130        * platform/mac/ScrollbarThemeMac.mm:
12131        (WebCore::linenBackgroundColor):
12132
121332014-06-23  Simon Fraser  <simon.fraser@apple.com>
12134
12135        CSS clip property should make layers non-opaque
12136        https://bugs.webkit.org/show_bug.cgi?id=134147
12137        <rdar://problem/17324579>
12138
12139        Reviewed by Tim Horton.
12140        
12141        https://www.fairphone.com has position:fixed elements with clip: rect(...)
12142        but we were making those layers opaque, resulting in garbage pixels
12143        in areas outside the clip rect.
12144        
12145        Fix by checking for the clip property in RenderBox::backgroundIsKnownToBeOpaqueInRect().
12146
12147        Test: compositing/contents-opaque/opaque-with-clip.html
12148
12149        * rendering/RenderBox.cpp:
12150        (WebCore::RenderBox::backgroundIsKnownToBeOpaqueInRect):
12151
121522014-06-23  Simon Fraser  <simon.fraser@apple.com>
12153
12154        Adding a mask on a simple color compositing layer removes the content
12155        https://bugs.webkit.org/show_bug.cgi?id=134127
12156
12157        Reviewed by Dean Jackson.
12158        
12159        In r169053 I moved some updateDrawsContent() into updateAfterDescendents(),
12160        but this isn't called when a composited layer gains or loses a mask (which
12161        doesn't cause a layout). This caused us to fail to allocate backing store
12162        when gaining a mask, resulting in missing content.
12163        
12164        Fix by calling updateAfterDescendents() from RenderLayer::styleChange()
12165        when the layer config isn't changing.
12166        
12167        Also remove a condition in isSimpleContainerCompositingLayer() that caused us
12168        to fall off the simple layer path for masked layers, since this works just
12169        fine.
12170
12171        Test: compositing/masks/solid-color-masked.html
12172
12173        * rendering/RenderLayer.cpp:
12174        (WebCore::RenderLayer::calculateClipRects):
12175        * rendering/RenderLayerBacking.cpp:
12176        (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
12177
121782014-06-23  David Hyatt  <hyatt@apple.com>
12179
12180        [New Multicolumn] Writing mode changes on the <html> and RenderView need to
12181        be propagated to column sets and flow thread children of those renderers.
12182        https://bugs.webkit.org/show_bug.cgi?id=134121
12183        <rdar://problem/16884527>
12184
12185        Reviewed by Dean Jackson.
12186
12187        Added fast/multicol/pagination/RightToLeft-rl-dynamic.html
12188
12189        * rendering/RenderBlockFlow.cpp:
12190        (WebCore::RenderBlockFlow::styleDidChange):
12191        Refactor the propagation code for column sets and flow thread styles into a helper
12192        function that is called here.
12193
12194        (WebCore::RenderBlockFlow::updateStylesForColumnChildren):
12195        * rendering/RenderBlockFlow.h:
12196        Add a new helper function for recalculating the styles of the column sets and
12197        flow thread in response to changes.
12198
12199        * rendering/RenderBox.cpp:
12200        (WebCore::RenderBox::styleDidChange):
12201        When the style is changed for a root element or the RenderView in response to
12202        writing mode and direction changes, make sure that style gets propagated to
12203        the column children by calling the new helper function.
12204
122052014-06-23  Jer Noble  <jer.noble@apple.com>
12206
12207        [Mac] Uncaught exception crash when destroying MediaPlayerPrivateAVFoundationObjC
12208        https://bugs.webkit.org/show_bug.cgi?id=134198
12209
12210        Reviewed by Eric Carlson.
12211
12212        Now that we always create an AVPlayerLayer when creating an AVPlayer, but we don't
12213        return that layer from platformLayer() unless we've been asked to, we no longer are
12214        asked to destroy our video layer from MediaPlayerPrivateAVFoundation::tearDownVideoRendering().
12215
12216        Instead, explicitly destroy our video layer (and remove the KVO-observer which is
12217        causing this exception) in the MediaPlayerPrivateAVFoundationObjC destructor.
12218
12219        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
12220        (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC):
12221
122222014-06-23  Andreas Kling  <akling@apple.com>
12223
12224        Remove unused FrameView::setUseCustomFixedPositionLayoutRect().
12225        <https://webkit.org/b/134194>
12226
12227        Reviewed by Anders Carlsson.
12228
12229        * WebCore.exp.in:
12230        * page/FrameView.cpp:
12231        (WebCore::FrameView::setUseCustomFixedPositionLayoutRect): Deleted.
12232        * page/FrameView.h:
12233
122342014-06-23  Antti Koivisto  <antti@apple.com>
12235
12236        REGRESSION (r160908): Unable to unset bold while entering text
12237        https://bugs.webkit.org/show_bug.cgi?id=134196
12238        <rdar://problem/17051653>
12239
12240        Reviewed by Andreas Kling.
12241        
12242        No test, this code path is used by some WK1 API clients only.
12243
12244        * editing/Editor.cpp:
12245        (WebCore::Editor::styleForSelectionStart):
12246        
12247            This needs to update the style before requesting the renderer.
12248
12249        * editing/Editor.h:
12250        * editing/ios/EditorIOS.mm:
12251        (WebCore::styleForSelectionStart): Deleted.
12252        * editing/mac/EditorMac.mm:
12253        (WebCore::styleForSelectionStart): Deleted.
12254        
12255            Removed the duplicated functions, moved to Editor.cpp.
12256
122572014-06-23  Alex Christensen  <achristensen@webkit.org>
12258
12259        [iOS] Fix video in WebGL.
12260        https://bugs.webkit.org/show_bug.cgi?id=133511
12261
12262        Reviewed by Jer Noble.
12263
12264        * WebCore.exp.in:
12265        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
12266        (WebCore::MediaPlayerPrivateAVFoundationObjC::hasSingleSecurityOrigin):
12267        (WebCore::wkAVAssetResolvedURL): Deleted.
12268        * platform/mac/WebCoreSystemInterface.h:
12269        * platform/mac/WebCoreSystemInterface.mm:
12270        Declare and use resolvedURL on AVURLAsset instead of using wkAVAssetResolvedURL through WebKitSystemInterface.
12271
122722014-06-23  Radu Stavila  <stavila@adobe.com>
12273
12274        REGRESSION (r168046): Incorrect handling of object information in WebCore::RenderFlowThread::removeLineRegionInfo
12275        https://bugs.webkit.org/show_bug.cgi?id=133587
12276
12277        Reviewed by Antti Koivisto.
12278
12279        When an object flowed in multicol is moved from in-flow positioning to out-of-flow positioning,
12280        its information must be removed from the flowthread prior to the change being made. 
12281        Otherwise, the flow thread will no longer be its containing block and a reference to it
12282        will not be possible to obtain.
12283
12284        No new tests can be added because the code still hits in an unrelated assertion followed by a null dereference.
12285        The issue was discussed with Antti Koivisto and we decided its better to fix this problem first and
12286        handle the following issue in a separate bug.
12287
12288        * rendering/RenderBlockFlow.cpp:
12289        (WebCore::RenderBlockFlow::styleWillChange):
12290        * rendering/RenderObject.h:
12291        (WebCore::RenderObject::flowThreadContainingBlock):
12292
122932014-06-23  Krzysztof Czech  <k.czech@samsung.com>
12294
12295        [EFL] Platform support for WebSpeech feature.
12296        https://bugs.webkit.org/show_bug.cgi?id=116438
12297
12298        Reviewed by Csaba Osztrogonác.
12299
12300        It's a first step of adding support for Speech Synthesis in EFL port.
12301        Just stub out required API and support for compilation.
12302
12303        * CMakeLists.txt:
12304        * PlatformEfl.cmake:
12305        * PlatformGTK.cmake: Added some idls to not break GTK build.
12306        * platform/PlatformSpeechSynthesizer.h:
12307        * platform/efl/PlatformSpeechSynthesisProviderEfl.cpp: Added.
12308        (WebCore::PlatformSpeechSynthesisProviderEfl::PlatformSpeechSynthesisProviderEfl):
12309        (WebCore::PlatformSpeechSynthesisProviderEfl::~PlatformSpeechSynthesisProviderEfl):
12310        (WebCore::PlatformSpeechSynthesisProviderEfl::initializeVoiceList):
12311        (WebCore::PlatformSpeechSynthesisProviderEfl::pause):
12312        (WebCore::PlatformSpeechSynthesisProviderEfl::resume):
12313        (WebCore::PlatformSpeechSynthesisProviderEfl::speak):
12314        (WebCore::PlatformSpeechSynthesisProviderEfl::cancel):
12315        * platform/efl/PlatformSpeechSynthesisProviderEfl.h: Added.
12316        * platform/efl/PlatformSpeechSynthesizerEfl.cpp: Added.
12317        (WebCore::PlatformSpeechSynthesizer::PlatformSpeechSynthesizer):
12318        (WebCore::PlatformSpeechSynthesizer::~PlatformSpeechSynthesizer):
12319        (WebCore::PlatformSpeechSynthesizer::initializeVoiceList):
12320        (WebCore::PlatformSpeechSynthesizer::pause):
12321        (WebCore::PlatformSpeechSynthesizer::resume):
12322        (WebCore::PlatformSpeechSynthesizer::speak):
12323        (WebCore::PlatformSpeechSynthesizer::cancel):
12324
123252014-06-23  Jeongeun Kim  <je_julie.kim@samsung.com>
12326
12327        Make it clear to get m_svgExtensions using svgExtensions().
12328        https://bugs.webkit.org/show_bug.cgi?id=134186.
12329
12330        Reviewed by Dirk Schulze.
12331
12332        This patch makes sure that the purpose of code is to get m_svgExtensions 
12333        as changing accessSVGExtensions() to svgExtensions(). 
12334        svgExtensions() is a getter API and accessSVGExtensions() checks 
12335        the presence of m_svgExtensions and create m_svgExtensions if it does not exist. 
12336
12337        No new tests, no behavior change.
12338
12339        * dom/ContainerNode.cpp:
12340        (WebCore::ContainerNode::removeChild):
12341        (WebCore::ContainerNode::removeChildren):
12342        * dom/Document.cpp:
12343        (WebCore::Document::commonTeardown):
12344        (WebCore::Document::implicitClose):
12345        * history/CachedFrame.cpp:
12346        (WebCore::CachedFrameBase::restore):
12347        * svg/SVGDocumentExtensions.cpp:
12348        (WebCore::SVGDocumentExtensions::startAnimations):
12349        (WebCore::SVGDocumentExtensions::pauseAnimations):
12350        (WebCore::SVGDocumentExtensions::unpauseAnimations):
12351        (WebCore::SVGDocumentExtensions::dispatchSVGLoadEventToOutermostSVGElements):
12352        (WebCore::SVGDocumentExtensions::rebuildElements):
12353        * svg/SVGDocumentExtensions.h:
12354
123552014-06-23  Dean Jackson  <dino@apple.com>
12356
12357        [iOS] Use WebGLLayer rather than PlatformLayer in GraphicsContext3D
12358        https://bugs.webkit.org/show_bug.cgi?id=134183
12359
12360        Follow-up review from Sam Weinig.
12361
12362        * platform/graphics/GraphicsContext3D.h: Merge another bit of MAC and IOS
12363        code.
12364        * ChangeLog: Actually read his review comments this time.
12365
123662014-06-23  Dean Jackson  <dino@apple.com>
12367
12368        [iOS] Use WebGLLayer rather than PlatformLayer in GraphicsContext3D
12369        https://bugs.webkit.org/show_bug.cgi?id=134183
12370
12371        Reviewed by Sam Weinig.
12372
12373        GraphicsContext3D has a reference to a WebGLLayer that was
12374        hidden behind a PlatformLayer. This meant we had to cast it
12375        to use a WebGLLayer method.
12376
12377        * platform/graphics/GraphicsContext3D.h: Replace RetainPtr<PlatformLayer>
12378        with RetainPtr<WebGLLayer>.
12379        * platform/graphics/mac/GraphicsContext3DMac.mm:
12380        (WebCore::GraphicsContext3D::~GraphicsContext3D): No need to cast.
12381
123822014-06-22  Zalan Bujtas  <zalan@apple.com>
12383
12384        Make offset from ancestor computation explicit by moving it to the callers.
12385        https://bugs.webkit.org/show_bug.cgi?id=134168.
12386
12387        Reviewed by Simon Fraser.
12388        
12389        Explicit offset computation helps code reading and less error-prone than passing
12390        the offset pointer and compute it locally when it is null.
12391
12392        No change in functionality.
12393
12394        * rendering/RenderLayer.cpp:
12395        (WebCore::transparencyClipBox):
12396        (WebCore::performOverlapTests):
12397        (WebCore::RenderLayer::setupClipPath):
12398        (WebCore::RenderLayer::setupFilters):
12399        (WebCore::RenderLayer::paintLayerContents):
12400        (WebCore::RenderLayer::collectFragments):
12401        (WebCore::RenderLayer::updatePaintingInfoForFragments):
12402        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
12403        (WebCore::RenderLayer::hitTestLayer):
12404        (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
12405        (WebCore::RenderLayer::calculateClipRects):
12406        * rendering/RenderLayer.h:
12407        * rendering/RenderLayerCompositor.cpp:
12408        (WebCore::RenderLayerCompositor::calculateCompositedBounds):
12409        (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
12410        * rendering/RenderTreeAsText.cpp:
12411        (WebCore::writeLayers):
12412
124132014-06-22  Zalan Bujtas  <zalan@apple.com>
12414
12415        Transition layer offsets from LayoutPoint to LayoutSize.
12416        https://bugs.webkit.org/show_bug.cgi?id=134156
12417
12418        Reviewed by Simon Fraser.
12419
12420        Use better representation for offset values.
12421
12422        No change in functionality.
12423
12424        * platform/graphics/LayoutSize.h:
12425        (WebCore::roundedForPainting):
12426        * rendering/RenderFlowThread.cpp:
12427        (WebCore::RenderFlowThread::fragmentsBoundingBox):
12428        * rendering/RenderLayer.cpp:
12429        (WebCore::expandClipRectForDescendantsAndReflection):
12430        (WebCore::RenderLayer::convertToLayerCoords):
12431        (WebCore::computeReferenceBox):
12432        (WebCore::RenderLayer::setupClipPath):
12433        (WebCore::RenderLayer::setupFilters):
12434        (WebCore::RenderLayer::paintLayerContents):
12435        (WebCore::RenderLayer::paintLayerByApplyingTransform):
12436        (WebCore::RenderLayer::collectFragments):
12437        (WebCore::RenderLayer::updatePaintingInfoForFragments):
12438        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
12439        (WebCore::RenderLayer::createLocalTransformState):
12440        (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
12441        (WebCore::RenderLayer::hitTestLayerByApplyingTransform):
12442        (WebCore::RenderLayer::calculateClipRects):
12443        * rendering/RenderLayer.h:
12444        * rendering/RenderMultiColumnSet.cpp:
12445        (WebCore::RenderMultiColumnSet::collectLayerFragments):
12446
124472014-06-22  Dean Jackson  <dino@apple.com>
12448
12449        Attempted iOS build fix.
12450
12451        * platform/graphics/mac/GraphicsContext3DMac.mm:
12452        (WebCore::GraphicsContext3D::~GraphicsContext3D): Cast to WebGLLayer.
12453
124542014-06-22  Dean Jackson  <dino@apple.com>
12455
12456        [Apple] WebGL layer may use GC3D after free with remote layer hosting
12457        https://bugs.webkit.org/show_bug.cgi?id=134179
12458        <rdar://problem/17412931>
12459
12460        Reviewed by Tim Horton.
12461
12462        With remote layer hosting, a WebGLLayer may attempt to draw after
12463        the GraphicsContext3D has been destroyed. We need to make sure
12464        the GC3D tells the WebGLLayer that it is no longer valid.
12465
12466        While here, I changed some return 0 to return nullptr, the
12467        name of the ObjC property member from m_context to _context,
12468        and removed some unnecessary .get() calls.
12469
12470        This is tested by run-webkit-tests with the --remote-layer-tree
12471        option.
12472
12473        * platform/graphics/mac/GraphicsContext3DMac.mm:
12474        (WebCore::GraphicsContext3D::GraphicsContext3D): No need for .get().
12475        (WebCore::GraphicsContext3D::~GraphicsContext3D): Set the context reference on WebGLLayer
12476        to be null.
12477        (WebCore::GraphicsContext3D::setRenderbufferStorageFromDrawable): No need for .get().
12478        * platform/graphics/mac/WebGLLayer.h: Set the context reference on WebGLLayer
12479        to be null.
12480        * platform/graphics/mac/WebGLLayer.mm:
12481        (-[WebGLLayer initWithGraphicsContext3D:]): Rename m_context to _context.
12482        (-[WebGLLayer copyCGLPixelFormatForDisplayMask:]): Check for null.
12483        (-[WebGLLayer copyCGLContextForPixelFormat:]): Rename to _context.
12484        (-[WebGLLayer drawInCGLContext:pixelFormat:forLayerTime:displayTime:]): Check for null.
12485        (-[WebGLLayer copyImageSnapshotWithColorSpace:]): Ditto.
12486        (-[WebGLLayer display]): Ditto.
12487
124882014-06-20  Simon Fraser  <simon.fraser@apple.com>
12489
12490        [WK2] Frameset frames are not scrollable after loading (and should be)
12491        https://bugs.webkit.org/show_bug.cgi?id=134151
12492        <rdar://problem/17403365>
12493
12494        Reviewed by Dan Bates.
12495        
12496        When loading a <frameset>, we could end up with an empty non-fast-scrollable
12497        region for the main frame, because after the initial frameset document layout,
12498        nothing updated the non-fast scrollable region as the subframes added their
12499        scrollable areas to the the main frame's scrollable area set.
12500        
12501        Fix by having addScrollableArea() and removeScrollableArea() trigger an update
12502        of the non-fast scrollable region.
12503
12504        Test: platform/mac-wk2/tiled-drawing/scrolling/frames/frameset-frame-scrollability.html
12505
12506        * page/FrameView.cpp:
12507        (WebCore::FrameView::addScrollableArea):
12508        (WebCore::FrameView::removeScrollableArea):
12509        (WebCore::FrameView::scrollableAreaSetChanged):
12510        * page/FrameView.h:
12511
125122014-06-22  Commit Queue  <commit-queue@webkit.org>
12513
12514        Unreviewed, rolling out r170265.
12515        https://bugs.webkit.org/show_bug.cgi?id=134174
12516
12517        Broke editing tests (Requested by litherum on #webkit).
12518
12519        Reverted changeset:
12520
12521        "Use unsigneds instead of ints for indexes into a string in
12522        text layout code"
12523        https://bugs.webkit.org/show_bug.cgi?id=133592
12524        http://trac.webkit.org/changeset/170265
12525
125262014-06-20  Simon Fraser  <simon.fraser@apple.com>
12527
12528        Have scrollingTreeAsText() dump the non-fast-scrollable region
12529        https://bugs.webkit.org/show_bug.cgi?id=134149
12530
12531        Reviewed by Sam Weinig.
12532
12533        Dump the non-fast-scrollable region (as an array of rects).
12534
12535        * WebCore.exp.in:
12536        * page/scrolling/ScrollingStateFrameScrollingNode.cpp:
12537        (WebCore::ScrollingStateFrameScrollingNode::dumpProperties):
12538
125392014-06-20  Myles C. Maxfield  <mmaxfield@apple.com>
12540
12541        Use unsigneds instead of ints for indexes into a string in text layout code
12542        https://bugs.webkit.org/show_bug.cgi?id=133592
12543
12544        Reviewed by Zalan Bujtas.
12545
12546        Migrate much of the text-handling code to use unsigneds for indexes into a string.
12547
12548        No new tests because there is no behavior change.
12549
12550        * WebCore.exp.in:
12551        * platform/graphics/Font.cpp:
12552        (WebCore::Font::drawText):
12553        (WebCore::Font::drawEmphasisMarks):
12554        (WebCore::Font::adjustSelectionRectForText):
12555        (WebCore::computeUnderlineType):
12556        * platform/graphics/Font.h:
12557        * platform/graphics/FontFastPath.cpp:
12558        (WebCore::Font::getGlyphsAndAdvancesForSimpleText):
12559        (WebCore::Font::drawSimpleText):
12560        (WebCore::Font::drawEmphasisMarksForSimpleText):
12561        (WebCore::Font::drawGlyphBuffer):
12562        (WebCore::Font::drawEmphasisMarks):
12563        (WebCore::Font::adjustSelectionRectForSimpleText):
12564        * platform/graphics/GlyphBuffer.h:
12565        (WebCore::GlyphBuffer::size):
12566        (WebCore::GlyphBuffer::glyphs):
12567        (WebCore::GlyphBuffer::advances):
12568        (WebCore::GlyphBuffer::fontDataAt):
12569        (WebCore::GlyphBuffer::advanceAt):
12570        (WebCore::GlyphBuffer::offsetAt):
12571        (WebCore::GlyphBuffer::reverse):
12572        (WebCore::GlyphBuffer::offsetInString):
12573        (WebCore::GlyphBuffer::swap):
12574        * platform/graphics/GraphicsContext.cpp:
12575        (WebCore::TextRunIterator::atEnd):
12576        * platform/graphics/Latin1TextIterator.h:
12577        (WebCore::Latin1TextIterator::Latin1TextIterator):
12578        (WebCore::Latin1TextIterator::currentCharacter):
12579        * platform/graphics/SimpleFontData.h:
12580        * platform/graphics/SurrogatePairAwareTextIterator.cpp:
12581        (WebCore::SurrogatePairAwareTextIterator::SurrogatePairAwareTextIterator):
12582        * platform/graphics/SurrogatePairAwareTextIterator.h:
12583        (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
12584        * platform/graphics/TextRun.h:
12585        (WebCore::TextRun::length):
12586        (WebCore::TextRun::charactersLength):
12587        * platform/graphics/WidthIterator.cpp:
12588        (WebCore::WidthIterator::glyphDataForCharacter):
12589        (WebCore::applyFontTransforms):
12590        (WebCore::WidthIterator::advanceInternal):
12591        (WebCore::WidthIterator::advance):
12592        (WebCore::WidthIterator::advanceOneCharacter):
12593        * platform/graphics/WidthIterator.h:
12594        * platform/graphics/cairo/FontCairo.cpp:
12595        (WebCore::Font::drawGlyphs):
12596        * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
12597        (WebCore::Font::drawComplexText):
12598        (WebCore::Font::drawEmphasisMarksForComplexText):
12599        (WebCore::Font::adjustSelectionRectForComplexText):
12600        * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
12601        (WebCore::HarfBuzzShaper::setNormalizedBuffer):
12602        * platform/graphics/mac/FontComplexTextMac.cpp:
12603        (WebCore::Font::adjustSelectionRectForComplexText):
12604        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
12605        (WebCore::Font::drawComplexText):
12606        (WebCore::Font::drawEmphasisMarksForComplexText):
12607        * platform/graphics/mac/FontMac.mm:
12608        (WebCore::Font::drawGlyphs):
12609        * platform/graphics/win/FontCGWin.cpp:
12610        (WebCore::Font::drawGlyphs):
12611        * platform/graphics/win/FontWin.cpp:
12612        (WebCore::Font::adjustSelectionRectForComplexText):
12613        (WebCore::Font::getGlyphsAndAdvancesForComplexText):
12614        (WebCore::Font::drawComplexText):
12615        (WebCore::Font::drawEmphasisMarksForComplexText):
12616        * platform/graphics/wince/FontWinCE.cpp:
12617        (WebCore::Font::drawGlyphs):
12618        (WebCore::Font::drawComplexText):
12619        (WebCore::Font::drawEmphasisMarksForComplexText):
12620        (WebCore::Font::selectionRectForComplexText):
12621        * rendering/InlineTextBox.cpp:
12622        (WebCore::InlineTextBox::isSelected):
12623        (WebCore::InlineTextBox::selectionState):
12624        (WebCore::adjustCharactersAndLengthForHyphen):
12625        (WebCore::InlineTextBox::localSelectionRect):
12626        (WebCore::InlineTextBox::paint):
12627        (WebCore::InlineTextBox::selectionStartEnd):
12628        (WebCore::InlineTextBox::paintSelection):
12629        (WebCore::InlineTextBox::paintCompositionBackground):
12630        (WebCore::InlineTextBox::paintDocumentMarker):
12631        (WebCore::InlineTextBox::paintTextMatchMarker):
12632        (WebCore::InlineTextBox::computeRectForReplacementMarker):
12633        (WebCore::InlineTextBox::paintCompositionUnderline):
12634        (WebCore::InlineTextBox::positionForOffset):
12635        (WebCore::InlineTextBox::constructTextRun):
12636        * rendering/InlineTextBox.h:
12637        * rendering/RenderCombineText.cpp:
12638        (WebCore::RenderCombineText::getStringToRender):
12639        * rendering/RenderCombineText.h:
12640        * rendering/svg/SVGInlineFlowBox.cpp:
12641        (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
12642        * rendering/svg/SVGInlineTextBox.cpp:
12643        (WebCore::SVGInlineTextBox::positionForOffset):
12644        (WebCore::SVGInlineTextBox::localSelectionRect):
12645        (WebCore::SVGInlineTextBox::paintSelectionBackground):
12646        (WebCore::SVGInlineTextBox::mapStartEndPositionsIntoFragmentCoordinates):
12647        (WebCore::SVGInlineTextBox::paintText):
12648        * rendering/svg/SVGInlineTextBox.h:
12649        * rendering/svg/SVGTextMetricsBuilder.cpp:
12650        (WebCore::SVGTextMetricsBuilder::currentCharacterStartsSurrogatePair):
12651        (WebCore::SVGTextMetricsBuilder::advance):
12652        * rendering/svg/SVGTextQuery.cpp:
12653        (WebCore::SVGTextQuery::mapStartEndPositionsIntoFragmentCoordinates):
12654        (WebCore::SVGTextQuery::modifyStartEndPositionsRespectingLigatures):
12655        (WebCore::SVGTextQuery::subStringLengthCallback):
12656        (WebCore::SVGTextQuery::startPositionOfCharacterCallback):
12657        (WebCore::SVGTextQuery::endPositionOfCharacterCallback):
12658        (WebCore::SVGTextQuery::rotationOfCharacterCallback):
12659        (WebCore::SVGTextQuery::extentOfCharacterCallback):
12660        (WebCore::SVGTextQuery::characterNumberAtPositionCallback):
12661        * rendering/svg/SVGTextQuery.h:
12662        * rendering/svg/SVGTextRunRenderingContext.cpp:
12663        (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
12664        (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
12665        * rendering/svg/SVGTextRunRenderingContext.h:
12666        * svg/SVGFontData.cpp:
12667        (WebCore::SVGFontData::applySVGGlyphSelection):
12668        * svg/SVGFontData.h:
12669
126702014-06-21  Zan Dobersek  <zdobersek@igalia.com>
12671
12672        createCairoGLSurface should take in a FloatSize reference as its first parameter
12673        https://bugs.webkit.org/show_bug.cgi?id=134159
12674
12675        Reviewed by Martin Robinson.
12676
12677        The ImageBuffer constructor operates with a FloatSize reference, which is also
12678        passed to createCairoGLSurface when accelerated 2D canvas support is enabled.
12679        That function should take in a reference to the same type.
12680
12681        * platform/graphics/cairo/ImageBufferCairo.cpp:
12682        (WebCore::createCairoGLSurface):
12683
126842014-06-21  Dean Jackson  <dino@apple.com>
12685
12686        [Mac] Margins for new form controls need tweaking
12687        https://bugs.webkit.org/show_bug.cgi?id=134135
12688        <rdar://problem/17262164>
12689
12690        Reviewed by Sam Weinig.
12691
12692        Take 2 of this patch. Only the mac-mountainlion LayoutTest
12693        results are different from the first attempt.
12694
12695        With the newer animated controls in OS X Yosemite, we need
12696        to tweak the fudge-factor margins for positioning. In a recent
12697        patch I added another fudge, which I'm removing with this. I'm
12698        not sure where the older values came from, but I've checked with
12699        the latest AppKit sources and am using the sizes they implement
12700        for the controls.
12701
12702        This will rebaseline a lot of tests, since I've made small tweaks
12703        to the form layout.
12704
12705        * platform/mac/ThemeMac.mm:
12706        (WebCore::checkboxMargins): New margin amounts.
12707        (WebCore::radioSizes): New sizes.
12708        (WebCore::radioMargins): New margin amounts.
12709        (WebCore::paintToggleButton): No need to call the positioning fudge any more.
12710        (WebCore::checkboxOffsets): Deleted.
12711        (WebCore::radioOffsets): Deleted.
12712
127132014-06-20  Sam Weinig  <sam@webkit.org>
12714
12715        Remove static tables for bindings that use eager reification
12716        https://bugs.webkit.org/show_bug.cgi?id=134126
12717
12718        Reviewed by Oliver Hunt.
12719
12720        This shaves about 1MB off of WebCore's .o files.
12721
12722        * bindings/scripts/CodeGeneratorJS.pm:
12723        (GenerateHeader):
12724        (GenerateImplementation):
12725        (GenerateConstructorHelperMethods):
12726        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
12727        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
12728        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
12729        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
12730        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
12731        * bindings/scripts/test/JS/JSTestEventConstructor.h:
12732        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
12733        * bindings/scripts/test/JS/JSTestEventTarget.h:
12734        * bindings/scripts/test/JS/JSTestException.cpp:
12735        * bindings/scripts/test/JS/JSTestException.h:
12736        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
12737        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
12738        * bindings/scripts/test/JS/JSTestInterface.cpp:
12739        * bindings/scripts/test/JS/JSTestInterface.h:
12740        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
12741        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
12742        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
12743        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
12744        * bindings/scripts/test/JS/JSTestNode.cpp:
12745        * bindings/scripts/test/JS/JSTestNode.h:
12746        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
12747        * bindings/scripts/test/JS/JSTestNondeterministic.h:
12748        * bindings/scripts/test/JS/JSTestObj.cpp:
12749        * bindings/scripts/test/JS/JSTestObj.h:
12750        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
12751        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
12752        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
12753        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
12754        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
12755        * bindings/scripts/test/JS/JSTestTypedefs.h:
12756        * bindings/scripts/test/JS/JSattribute.cpp:
12757        * bindings/scripts/test/JS/JSattribute.h:
12758        * bindings/scripts/test/JS/JSreadonly.cpp:
12759        * bindings/scripts/test/JS/JSreadonly.h:
12760
127612014-06-21  Brady Eidson  <beidson@apple.com>
12762
12763        Gamepad API - Deprecate the existing implementation
12764        https://bugs.webkit.org/show_bug.cgi?id=134108
12765
12766        Reviewed by Timothy Hatcher.
12767
12768        -Add new "GAMEPAD_DEPRECATED" build flag, moving the existing implementation to use it
12769        -Move some implementation files into a "deprecated" subdirectory.
12770
12771        * CMakeLists.txt:
12772        * Configurations/FeatureDefines.xcconfig:
12773        * PlatformGTK.cmake:
12774
12775        * Modules/gamepad/deprecated/Gamepad.cpp: Renamed from Source/WebCore/Modules/gamepad/Gamepad.cpp.
12776        * Modules/gamepad/deprecated/Gamepad.h: Renamed from Source/WebCore/Modules/gamepad/Gamepad.h.
12777        * Modules/gamepad/deprecated/Gamepad.idl: Renamed from Source/WebCore/Modules/gamepad/Gamepad.idl.
12778        * Modules/gamepad/deprecated/GamepadList.cpp: Renamed from Source/WebCore/Modules/gamepad/GamepadList.cpp.
12779        * Modules/gamepad/deprecated/GamepadList.h: Renamed from Source/WebCore/Modules/gamepad/GamepadList.h.
12780        * Modules/gamepad/deprecated/GamepadList.idl: Renamed from Source/WebCore/Modules/gamepad/GamepadList.idl.
12781        * Modules/gamepad/deprecated/NavigatorGamepad.cpp: Renamed from Source/WebCore/Modules/gamepad/NavigatorGamepad.cpp.
12782        * Modules/gamepad/deprecated/NavigatorGamepad.h: Renamed from Source/WebCore/Modules/gamepad/NavigatorGamepad.h.
12783        * Modules/gamepad/deprecated/NavigatorGamepad.idl: Renamed from Source/WebCore/Modules/gamepad/NavigatorGamepad.idl.
12784
12785        * platform/Gamepads.h:
12786        * platform/efl/GamepadsEfl.cpp:
12787        * platform/gtk/GamepadsGtk.cpp:
12788        * platform/linux/GamepadDeviceLinux.cpp:
12789        * platform/linux/GamepadDeviceLinux.h:
12790
127912014-06-21  Myles C. Maxfield  <mmaxfield@apple.com>
12792
12793        Mark TextRun's constructors as explicit
12794        https://bugs.webkit.org/show_bug.cgi?id=134124
12795
12796        Reviewed by Sam Weinig.
12797
12798        After r170072, nobody is implicitly converting a string to a TextRun. Therefore,
12799        we can make the constructors explicit.
12800
12801        No new tests because there is no behavior change.
12802
12803        * platform/graphics/TextRun.h:
12804        (WebCore::TextRun::TextRun):
12805
128062014-06-21  Commit Queue  <commit-queue@webkit.org>
12807
12808        Unreviewed, rolling out r170244.
12809        https://bugs.webkit.org/show_bug.cgi?id=134157
12810
12811        GTK/EFL bindings generator works differently, making this
12812        patch not work there.  Will fix entire patch after a rollout.
12813        (Requested by bradee-oh on #webkit).
12814
12815        Reverted changeset:
12816
12817        "Gamepad API - Deprecate the existing implementation"
12818        https://bugs.webkit.org/show_bug.cgi?id=134108
12819        http://trac.webkit.org/changeset/170244
12820
128212014-06-21  Zan Dobersek  <zdobersek@igalia.com>
12822
12823        Fix the mismatched header build guards in WebKitDOMNodeFilterPrivate.h
12824        which are throwing compilation warnings when building with Clang.
12825
12826        * bindings/gobject/WebKitDOMNodeFilterPrivate.h:
12827
128282014-06-21  Brady Eidson  <beidson@apple.com>
12829
12830        Gamepad API - Deprecate the existing implementation
12831        https://bugs.webkit.org/show_bug.cgi?id=134108
12832
12833        Reviewed by Timothy Hatcher.
12834
12835        -Add new "GAMEPAD_DEPRECATED" build flag, moving the existing implementation to use it
12836        -Add the "Deprecated" suffix to some implementation files
12837
12838        * CMakeLists.txt:
12839        * PlatformGTK.cmake:
12840        * Configurations/FeatureDefines.xcconfig:
12841        
12842        * Modules/gamepad/GamepadDeprecated.cpp: Renamed from Source/WebCore/Modules/gamepad/Gamepad.cpp.
12843        * Modules/gamepad/GamepadDeprecated.h: Renamed from Source/WebCore/Modules/gamepad/Gamepad.h.
12844        * Modules/gamepad/GamepadDeprecated.idl: Renamed from Source/WebCore/Modules/gamepad/Gamepad.idl.
12845
12846        * Modules/gamepad/GamepadList.cpp:
12847        * Modules/gamepad/GamepadList.h:
12848        * Modules/gamepad/GamepadList.idl:
12849
12850        * Modules/gamepad/NavigatorGamepadDeprecated.cpp: Renamed from Source/WebCore/Modules/gamepad/NavigatorGamepad.cpp.
12851        * Modules/gamepad/NavigatorGamepadDeprecated.h: Renamed from Source/WebCore/Modules/gamepad/NavigatorGamepad.h.
12852        * Modules/gamepad/NavigatorGamepadDeprecated.idl: Renamed from Source/WebCore/Modules/gamepad/NavigatorGamepad.idl.
12853
12854        * platform/Gamepads.h:
12855        * platform/efl/GamepadsEfl.cpp:
12856        * platform/gtk/GamepadsGtk.cpp:
12857        * platform/linux/GamepadDeviceLinux.cpp:
12858        * platform/linux/GamepadDeviceLinux.h:
12859
128602014-06-21  Commit Queue  <commit-queue@webkit.org>
12861
12862        Unreviewed, rolling out r170228.
12863        https://bugs.webkit.org/show_bug.cgi?id=134155
12864
12865        Caused 9 layout test failures on Mountain Lion
12866        http://build.webkit.org/builders/Apple%20MountainLion%20Release%20WK2%20(Tests)/builds/19216
12867        (Requested by bradee-oh on #webkit).
12868
12869        Reverted changeset:
12870
12871        "[Mac] Margins for new form controls need tweaking"
12872        https://bugs.webkit.org/show_bug.cgi?id=134135
12873        http://trac.webkit.org/changeset/170228
12874
128752014-06-21  Jer Noble  <jer.noble@apple.com>
12876
12877        [Mac] Create and attach the AVPlayerLayer to the AVPlayer immediately if the media element is <video>.
12878        https://bugs.webkit.org/show_bug.cgi?id=134131
12879
12880        Reviewed by Eric Carlson.
12881
12882        The AVPlayer uses the presence of an AVPlayerLayer to decide which alternate to display in the case of
12883        HLS streams with audio-only alternates. To give the AVPlayer the most information with which to make its
12884        decision, always create and attach an AVPlayerLayer before attaching an AVPlayerItem to the AVPlayerLayer.
12885        In addition, retrieve the <video> element bounds and create an AVPlayerLayer with a matching size, so that
12886        the AVPlayer can choose an alternate with the correct dimensions.
12887
12888        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
12889        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
12890        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
12891        (WebCore::MediaPlayerPrivateAVFoundationObjC::hasLayerRenderer):
12892        (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer):
12893        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerLayer):
12894        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):
12895        (WebCore::MediaPlayerPrivateAVFoundationObjC::platformLayer):
12896
128972014-06-21  Jeremy Jones  <jeremyj@apple.com>
12898
12899        Implement ios -[WAKWindow convertBaseToScreen:]
12900        https://bugs.webkit.org/show_bug.cgi?id=134053
12901
12902        Reviewed by Eric Carlson.
12903
12904        * platform/ios/wak/WAKWindow.mm:
12905        (-[WAKWindow convertBaseToScreen:]):
12906        Traverse layer hierarchy and convert point.
12907
12908        (-[WAKWindow convertScreenToBase:]):
12909        Traverse layer hierarchy and convert point.
12910
129112014-06-21  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
12912
12913        Removing PAGE_VISIBILITY_API compile guard.
12914        https://bugs.webkit.org/show_bug.cgi?id=133844
12915
12916        Reviewed by Gavin Barraclough.
12917
12918        No new tests because no functional changes.
12919
12920        * Configurations/FeatureDefines.xcconfig:
12921        * Modules/vibration/NavigatorVibration.cpp:
12922        (WebCore::NavigatorVibration::vibrate):
12923        * dom/Document.cpp:
12924        (WebCore::Document::hidden):
12925        * dom/Document.h:
12926        * dom/Document.idl:
12927        * dom/Element.h:
12928        * html/HTMLMediaElement.cpp:
12929        (WebCore::HTMLMediaElement::HTMLMediaElement):
12930        (WebCore::HTMLMediaElement::registerWithDocument):
12931        (WebCore::HTMLMediaElement::unregisterWithDocument):
12932        (WebCore::HTMLMediaElement::parseAttribute):
12933        * html/HTMLMediaElement.h:
12934        * page/Page.cpp:
12935        (WebCore::Page::setIsVisibleInternal):
12936        (WebCore::Page::visibilityState):
12937        (WebCore::Page::hiddenPageCSSAnimationSuspensionStateChanged):
12938        * page/Page.h:
12939        * page/PageVisibilityState.cpp:
12940        * page/PageVisibilityState.h:
12941        * page/Settings.cpp:
12942        (WebCore::Settings::Settings):
12943        (WebCore::Settings::setHiddenPageCSSAnimationSuspensionEnabled):
12944        * page/Settings.h:
12945        * platform/audio/MediaSession.cpp:
12946        (WebCore::MediaSession::updateClientDataBuffering):
12947        * platform/audio/MediaSession.h:
12948
129492014-06-21  Frédéric Wang  <fred.wang@free.fr>
12950
12951        [GTK][EFL] Use OpenType MATH fonts by default.
12952        https://bugs.webkit.org/show_bug.cgi?id=133604
12953
12954        Reviewed by Chris Fleizach.
12955
12956        In order to support stretching of horizontal operators and large
12957        operators in display mode as well as to improve the drawing of radicals,
12958        we need to use an OpenType MATH table. This commit makes the MathML code
12959        try "Latin Modern Math" first, which is an OpenType version of Knuth's
12960        popular Computer Modern font and is packaged with most TeX
12961        distributions (e.g. TeX Live on Linux). This should work well on the
12962        EFL & GTK ports for which the initial OpenType MATH support has been
12963        tested. Other ports will be handled later.
12964
12965        No new tests. This is already tested in LayoutTests/mathml/opentype/.
12966
12967        * css/mathml.css:
12968        (math): Add "Latin Modern Math" as the first font-family of the <math> element.
12969
129702014-06-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
12971
12972        Unreviewed EFL build fix since r170224.
12973
12974        Add retainPlatformLayer() and releasePlatformLayer() in ScrollingStateNodeCoordinatedGraphics.cpp
12975        as well. Thouse functions were missed in r170224.
12976
12977        * page/scrolling/ScrollingStateNode.h:
12978        * page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp:
12979        (WebCore::LayerRepresentation::retainPlatformLayer):
12980        (WebCore::LayerRepresentation::releasePlatformLayer):
12981
129822014-06-20  Dean Jackson  <dino@apple.com>
12983
12984        [Mac] Margins for new form controls need tweaking
12985        https://bugs.webkit.org/show_bug.cgi?id=134135
12986        <rdar://problem/17262164>
12987
12988        Reviewed by Sam Weinig.
12989
12990        With the newer animated controls in OS X Yosemite, we need
12991        to tweak the fudge-factor margins for positioning. In a recent
12992        patch I added another fudge, which I'm removing with this. I'm
12993        not sure where the older values came from, but I've checked with
12994        the latest AppKit sources and am using the sizes they implement
12995        for the controls.
12996
12997        This will rebaseline a lot of tests, since I've made small tweaks
12998        to the form layout.
12999
13000        * platform/mac/ThemeMac.mm:
13001        (WebCore::checkboxMargins): New margin amounts.
13002        (WebCore::radioSizes): New sizes.
13003        (WebCore::radioMargins): New margin amounts.
13004        (WebCore::paintToggleButton): No need to call the positioning fudge any more.
13005        (WebCore::checkboxOffsets): Deleted.
13006        (WebCore::radioOffsets): Deleted.
13007
130082014-06-20  Alex Christensen  <achristensen@webkit.org>
13009
13010        Fix css jit on armv7.
13011        https://bugs.webkit.org/show_bug.cgi?id=134143
13012        <rdar://problem/17348060>
13013
13014        Reviewed by Benjamin Poulain.
13015
13016        This fixes the acid3 test.
13017
13018        * cssjit/SelectorCompiler.cpp:
13019        (WebCore::SelectorCompiler::SelectorCodeGenerator::addFlagsToElementStyleFromContext):
13020        Correct high and low bits.
13021
130222014-06-20  Beth Dakin  <bdakin@apple.com>
13023
13024        https://bugs.webkit.org/show_bug.cgi?id=134117
13025        Unreproducible crashes under WebCore::ScrollingTree::updateTreeFromStateNode() 
13026        from messaging a deleted Obj-C object
13027        -and corresponding-
13028        <rdar://problem/17149252>
13029
13030        Reviewed by Simon Fraser.
13031
13032        This is a speculative fix. It makes LayerRepresentation retain m_platformLayer.
13033
13034        * WebCore.exp.in:
13035        * page/scrolling/ScrollingStateNode.h:
13036        (WebCore::LayerRepresentation::LayerRepresentation):
13037        (WebCore::LayerRepresentation::~LayerRepresentation):
13038        (WebCore::LayerRepresentation::operator=):
13039        (WebCore::LayerRepresentation::operator==):
13040        (WebCore::LayerRepresentation::operator ==): Deleted.
13041
13042        Make this ASSERT an ASSERT_WITH_SECURITY_IMPLICATION
13043        * page/scrolling/ScrollingTree.cpp:
13044        (WebCore::ScrollingTree::updateTreeFromStateNode):
13045
13046        Moved ScrollingStateNodeMac.mm, which was empty anyway, to cocoa/
13047        ScrollingStateNode.mm so that iOS can use it too.
13048        * page/scrolling/cocoa: Added.
13049        * page/scrolling/cocoa/ScrollingStateNode.mm: Copied from page/scrolling/mac/ScrollingStateNodeMac.mm.
13050
13051        Actual implementation for retain and release.
13052        (WebCore::LayerRepresentation::retainPlatformLayer):
13053        (WebCore::LayerRepresentation::releasePlatformLayer):
13054
13055        Deleted.
13056        * page/scrolling/mac/ScrollingStateNodeMac.mm: Removed.
13057
130582014-06-19  Zalan Bujtas  <zalan@apple.com>
13059
13060        Introduce RenderLayer::offsetFromAncestorLayer() to make convertToLayerCoords() calls with
13061        LayoutPoint(0, 0) as parameter more explicit.
13062        https://bugs.webkit.org/show_bug.cgi?id=134092
13063
13064        Reviewed by Simon Fraser.
13065
13066        Most of the RenderLayer::convertToLayerCoords() callers are only interested in
13067        the offset from the ancestor layer by passing LayoutPoint(0, 0) as the coordinate to convert.
13068        Introducing offsetFromAncestorLayer() makes those calls more explicit/self-explanatory.
13069        It helps simplifying the callsite's code.
13070
13071        No change in functionality.
13072
13073        * rendering/RenderGeometryMap.cpp:
13074        (WebCore::RenderGeometryMap::mapToContainer):
13075        (WebCore::RenderGeometryMap::pushMappingsToAncestor):
13076        (WebCore::RenderGeometryMap::push):
13077        * rendering/RenderLayer.cpp:
13078        (WebCore::RenderLayer::computeOffsetFromRoot):
13079        (WebCore::RenderLayer::updateLayerPositions):
13080        (WebCore::expandClipRectForRegionAndReflection):
13081        (WebCore::expandClipRectForDescendantsAndReflection):
13082        (WebCore::transparencyClipBox):
13083        (WebCore::RenderLayer::convertToPixelSnappedLayerCoords):
13084        (WebCore::accumulateOffsetTowardsAncestor):
13085        (WebCore::RenderLayer::convertToLayerCoords):
13086        (WebCore::RenderLayer::offsetFromAncestorLayer):
13087        (WebCore::RenderLayer::clipToRect):
13088        (WebCore::RenderLayer::paintLayerContents):
13089        (WebCore::RenderLayer::paintLayerByApplyingTransform):
13090        (WebCore::RenderLayer::collectFragments):
13091        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
13092        (WebCore::RenderLayer::createLocalTransformState):
13093        (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
13094        (WebCore::RenderLayer::calculateClipRects):
13095        * rendering/RenderLayer.h:
13096        * rendering/RenderLayerBacking.cpp:
13097        (WebCore::RenderLayerBacking::updateCompositedBounds):
13098        (WebCore::RenderLayerBacking::updateGeometry):
13099        * rendering/RenderLayerCompositor.cpp:
13100        (WebCore::RenderLayerCompositor::repaintInCompositedAncestor):
13101
131022014-06-20  Myles C. Maxfield  <mmaxfield@apple.com>
13103
13104        Removing dead code in platform/graphics/gpu
13105        https://bugs.webkit.org/show_bug.cgi?id=134065
13106
13107        Reviewed by Simon Fraser.
13108
13109        No new tests because there is no behavior change.
13110
13111        * WebCore.vcxproj/WebCore.vcxproj:
13112        * WebCore.vcxproj/WebCore.vcxproj.filters:
13113        * WebCore.xcodeproj/project.pbxproj:
13114        * platform/graphics/gpu/LoopBlinnClassifier.cpp: Removed.
13115        * platform/graphics/gpu/LoopBlinnClassifier.h: Removed.
13116        * platform/graphics/gpu/LoopBlinnConstants.h: Removed.
13117        * platform/graphics/gpu/LoopBlinnLocalTriangulator.cpp: Removed.
13118        * platform/graphics/gpu/LoopBlinnLocalTriangulator.h: Removed.
13119        * platform/graphics/gpu/LoopBlinnMathUtils.cpp: Removed.
13120        * platform/graphics/gpu/LoopBlinnMathUtils.h: Removed.
13121        * platform/graphics/gpu/LoopBlinnPathCache.cpp: Removed.
13122        * platform/graphics/gpu/LoopBlinnPathCache.h: Removed.
13123        * platform/graphics/gpu/LoopBlinnPathProcessor.h: Removed.
13124        * platform/graphics/gpu/LoopBlinnShader.cpp: Removed.
13125        * platform/graphics/gpu/LoopBlinnShader.h: Removed.
13126        * platform/graphics/gpu/LoopBlinnSolidFillShader.cpp: Removed.
13127        * platform/graphics/gpu/LoopBlinnSolidFillShader.h: Removed.
13128        * platform/graphics/gpu/LoopBlinnTextureCoords.cpp: Removed.
13129        * platform/graphics/gpu/LoopBlinnTextureCoords.h: Removed.
13130        * platform/graphics/gpu/Shader.cpp: Removed.
13131        * platform/graphics/gpu/Shader.h: Removed.
13132        * platform/graphics/gpu/SharedGraphicsContext3D.cpp: Removed.
13133        * platform/graphics/gpu/SharedGraphicsContext3D.h: Removed.
13134        * platform/graphics/gpu/mac/DrawingBufferMac.mm: Removed.
13135        * platform/graphics/gpu/opencl/FilterContextOpenCL.cpp: Removed.
13136        * platform/graphics/gpu/opencl/FilterContextOpenCL.h: Removed.
13137        * platform/graphics/gpu/opencl/OpenCLFEColorMatrix.cpp: Removed.
13138        * platform/graphics/gpu/opencl/OpenCLFEFlood.cpp: Removed.
13139        * platform/graphics/gpu/opencl/OpenCLFEImage.cpp: Removed.
13140        * platform/graphics/gpu/opencl/OpenCLFEMerge.cpp: Removed.
13141        * platform/graphics/gpu/opencl/OpenCLFESourceAlpha.cpp: Removed.
13142        * platform/graphics/gpu/opencl/OpenCLFESourceGraphic.cpp: Removed.
13143        * platform/graphics/gpu/opencl/OpenCLFETurbulence.cpp: Removed.
13144        * platform/graphics/gpu/opencl/OpenCLHandle.h: Removed.
13145
131462014-06-20  Myles C. Maxfield  <mmaxfield@apple.com>
13147
13148        [iOS] Support Khmer and Lao fallback fonts
13149        https://bugs.webkit.org/show_bug.cgi?id=134114
13150
13151        Reviewed by Enrica Casucci.
13152
13153        iOS has fonts which have glyphs for the Khmer and Lao languages.
13154
13155        This patch also does a little refactoring of the language-specific fallback
13156        font path to increase readability.
13157
13158        Test: fast/text/khmer-lao-font.html
13159
13160        * platform/graphics/ios/FontCacheIOS.mm:
13161        (WebCore::languageSpecificFallbackFont):
13162        (WebCore::FontCache::systemFallbackForCharacters):
13163
131642014-06-20  Anders Carlsson  <andersca@apple.com>
13165
13166        Give NPAPI post requests a default content type
13167        https://bugs.webkit.org/show_bug.cgi?id=134120
13168
13169        Reviewed by Andreas Kling.
13170
13171        * WebCore.exp.in:
13172
131732014-06-20  Simon Fraser  <simon.fraser@apple.com>
13174
13175        REGRESSION (r169972): fix issue when removing masks from compositing layers
13176        https://bugs.webkit.org/show_bug.cgi?id=134118
13177        <rdar://problem/17366654>
13178
13179        Reviewed by Dean Jackson.
13180        
13181        After r169972 when removing the mask, we could destroy the mask
13182        layer before the call into m_graphicsLayer->setMaskLayer(), which would
13183        try to call functions on the old mask. Fix by clearing the mask layer
13184        on the GraphicsLayer before the mask layer gets destroyed.
13185
13186        Test: compositing/masks/toggle-mask.html
13187
13188        * rendering/RenderLayerBacking.cpp:
13189        (WebCore::RenderLayerBacking::updateConfiguration):
13190        (WebCore::RenderLayerBacking::updateMaskLayer):
13191        * rendering/RenderLayerBacking.h:
13192
131932014-06-20  Andreas Kling  <akling@apple.com>
13194
13195        [Cocoa] Release freed up blocks from the JS heap after simulated memory pressure.
13196        <https://webkit.org/b/134112>
13197
13198        Reviewed by Mark Hahnenberg.
13199
13200        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
13201        (WebCore::MemoryPressureHandler::install):
13202
132032014-06-20  Zalan Bujtas  <zalan@apple.com>
13204
13205        Remove redundant RenderLayer::computeOffsetFromRoot() function.
13206        https://bugs.webkit.org/show_bug.cgi?id=134088
13207
13208        Reviewed by Benjamin Poulain.
13209
13210        No change in functionality.
13211
13212        * rendering/RenderLayer.cpp:
13213        (WebCore::RenderLayer::calculateClipRects):
13214        (WebCore::RenderLayer::computeOffsetFromRoot): Deleted.
13215        * rendering/RenderLayer.h:
13216
132172014-06-19  Simon Fraser  <simon.fraser@apple.com>
13218
13219        [iOS WebKit2] Make -webkit-overflow-scrolling:touch work in iframes (breaks MSWord previews)
13220        https://bugs.webkit.org/show_bug.cgi?id=134085
13221        <rdar://problem/16440586>
13222
13223        Reviewed by Tim Horton.
13224        
13225        When nodes were detached from the scrolling tree, we would previously throw away
13226        all descendant nodes, expecting that they would be re-attached as we walk the compositing
13227        layer tree in RenderLayerCompositor.
13228        
13229        However, this doesn't work across frame boundaries; the subframe may never update
13230        its compositing layers again, so would lose all its scrolling nodes.
13231        
13232        Fix by having ScrollingStateTree::detachNode() by default set aside subframe nodes
13233        into a hash map. On reattach, we'll look in the hash map and pull out an existing node
13234        (with its children intact) if possible.
13235
13236        Tests: platform/mac-wk2/tiled-drawing/scrolling/frames/coordinated-frame-gain-scrolling-ancestor.html
13237               platform/mac-wk2/tiled-drawing/scrolling/frames/coordinated-frame-lose-scrolling-ancestor.html
13238               platform/mac-wk2/tiled-drawing/scrolling/frames/remove-coordinated-frame.html
13239
13240        * page/scrolling/ScrollingStateNode.cpp:
13241        (WebCore::ScrollingStateNode::ScrollingStateNode):
13242        * page/scrolling/ScrollingStateTree.cpp:
13243        (WebCore::ScrollingStateTree::attachNode):
13244        (WebCore::ScrollingStateTree::detachNode):
13245        (WebCore::ScrollingStateTree::clear):
13246        (WebCore::ScrollingStateTree::removeNodeAndAllDescendants):
13247        (WebCore::ScrollingStateTree::recursiveNodeWillBeRemoved):
13248        * page/scrolling/ScrollingStateTree.h:
13249        * page/scrolling/ScrollingTree.cpp:
13250        (WebCore::ScrollingTree::commitNewTreeState): Go back to removing the deleted
13251        nodes from m_nodeMap first.
13252        (WebCore::ScrollingTree::removeDestroyedNodes): There is no need for this to
13253        actually make use of ScrollingTreeNode* any more; the ASSERT(!node->parent())
13254        is bogus because it can fire when whole subtrees are removed, and to clear the
13255        latched node we just need the ID.
13256
132572014-06-19  Simon Fraser  <simon.fraser@apple.com>
13258
13259        Handle scrolling tree modifications which remove intermediate nodes
13260        https://bugs.webkit.org/show_bug.cgi?id=134082
13261
13262        Reviewed by Tim Horton.
13263
13264        When updating the scrolling tree from the state tree, we failed to maintain
13265        the children arrays correctly. Fix by removing all children on scrolling nodes,
13266        and allowing the calls on children to add them back. A temporary hash map
13267        keeps the nodes alive.
13268        
13269        The state tree's m_nodesRemovedSinceLastCommit was also made into a HashSet,
13270        to make it easier to handle removal followed by re-insertion.
13271
13272        * WebCore.exp.in:
13273        * page/scrolling/ScrollingStateTree.cpp:
13274        (WebCore::ScrollingStateTree::attachNode): If a node is (possibly re-)added,
13275        remove it from m_nodesRemovedSinceLastCommit.remove.
13276        (WebCore::ScrollingStateTree::willRemoveNode):
13277        (WebCore::ScrollingStateTree::setRemovedNodes):
13278        * page/scrolling/ScrollingStateTree.h:
13279        (WebCore::ScrollingStateTree::removedNodes):
13280        * page/scrolling/ScrollingTree.cpp:
13281        (WebCore::ScrollingTree::commitNewTreeState):
13282        (WebCore::ScrollingTree::updateTreeFromStateNode): Clean up to have only one call
13283        to updateBeforeChildren(), and remove all children from the scrolling node
13284        before visiting state children.
13285        (WebCore::ScrollingTree::removeDestroyedNodes): It was very wrong to assume
13286        that all non-root nodes were parented in the root! Now we don't need to
13287        remove from the parent anyway.
13288        * page/scrolling/ScrollingTree.h:
13289        * page/scrolling/ScrollingTreeNode.h:
13290        (WebCore::ScrollingTreeNode::children):
13291
132922014-06-19  Simon Fraser  <simon.fraser@apple.com>
13293
13294        Make ScrollingTreeNodes refounted, for easier tree reconfiguration
13295        https://bugs.webkit.org/show_bug.cgi?id=134075
13296
13297        Reviewed by Tim Horton.
13298
13299        Make ScrollingTreeNode be ref-counted.
13300
13301        * page/scrolling/AsyncScrollingCoordinator.h:
13302        * page/scrolling/ScrollingTree.cpp:
13303        (WebCore::ScrollingTree::handleWheelEvent):
13304        (WebCore::ScrollingTree::updateTreeFromStateNode):
13305        * page/scrolling/ScrollingTree.h:
13306        (WebCore::ScrollingTree::rootNode):
13307        * page/scrolling/ScrollingTreeNode.cpp:
13308        (WebCore::ScrollingTreeNode::appendChild):
13309        * page/scrolling/ScrollingTreeNode.h:
13310        * page/scrolling/ThreadedScrollingTree.cpp:
13311        (WebCore::ThreadedScrollingTree::createNode):
13312        * page/scrolling/ThreadedScrollingTree.h:
13313        * page/scrolling/ios/ScrollingCoordinatorIOS.h:
13314        * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
13315        (WebCore::ScrollingCoordinatorIOS::createScrollingTreeNode):
13316        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.h:
13317        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm:
13318        (WebCore::ScrollingTreeFrameScrollingNodeIOS::create):
13319        * page/scrolling/ios/ScrollingTreeIOS.cpp:
13320        (WebCore::ScrollingTreeIOS::createNode):
13321        * page/scrolling/ios/ScrollingTreeIOS.h:
13322        * page/scrolling/mac/ScrollingCoordinatorMac.h:
13323        * page/scrolling/mac/ScrollingCoordinatorMac.mm:
13324        (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode):
13325        * page/scrolling/mac/ScrollingTreeFixedNode.h:
13326        * page/scrolling/mac/ScrollingTreeFixedNode.mm:
13327        (WebCore::ScrollingTreeFixedNode::create):
13328        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
13329        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
13330        (WebCore::ScrollingTreeFrameScrollingNodeMac::create):
13331        * page/scrolling/mac/ScrollingTreeStickyNode.h:
13332        * page/scrolling/mac/ScrollingTreeStickyNode.mm:
13333        (WebCore::ScrollingTreeStickyNode::create):
13334
133352014-06-20  Enrica Casucci  <enrica@apple.com>
13336
13337        iOS build fix after http://trac.webkit.org/changeset/170167.
13338
13339        Reviewed by Geoff Garen.
13340
13341        * bindings/js/JSDeviceMotionEventCustom.cpp:
13342        * bindings/js/JSDeviceOrientationEventCustom.cpp:
13343
133442014-06-19  Pratik Solanki  <psolanki@apple.com>
13345
13346        Enable synchronous willSendRequest on iOS
13347        https://bugs.webkit.org/show_bug.cgi?id=134081
13348        <rdar://problem/17350927>
13349
13350        Reviewed by Andreas Kling.
13351
13352        We lost the call to make willSendrequest callbacks be synchronous if possible during code
13353        refactoring. The call is present in ResourceHandleMac.mm but that code is not called when
13354        we use the CFNetwork based loader. Call the SPI in setupRequest().
13355
13356        No new tests because existing tests should cover this functionality.
13357
13358        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
13359        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::setupRequest):
13360        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willSendRequest):
13361
133622014-06-20  Carlos Garcia Campos  <cgarcia@igalia.com>
13363
13364        [GTK] Do not build quota files when QUOTA is disabled
13365        https://bugs.webkit.org/show_bug.cgi?id=134101
13366
13367        Reviewed by Philippe Normand.
13368
13369        * CMakeLists.txt: Remove exception for GTK+ that is no longer
13370        required since r170173.
13371        * PlatformGTK.cmake: Generate GObject DOM bindings for Quota when enabled.
13372
133732014-06-20  Manuel Rego Casasnovas  <rego@igalia.com>
13374
13375        [CSS Grid Layout] Add GridSpan::iterator
13376        https://bugs.webkit.org/show_bug.cgi?id=134058
13377
13378        Reviewed by Bem Jones-Bey.
13379
13380        Once that GridResolvedPosition has been introduced in r169934, this
13381        patch adds a GridSpan::iterator which allows to simplify the loops over
13382        GridResolvedPositions.
13383        From now on we could use range-based for loops.
13384
13385        No new tests as it is already covered by current tests
13386        (fast/css-grid-layout/).
13387
13388        * rendering/RenderGrid.cpp:
13389        (WebCore::RenderGrid::computeNormalizedFractionBreadth): Change loop to
13390        ranged-based for.
13391        (WebCore::RenderGrid::insertItemIntoGrid): Ditto.
13392        (WebCore::RenderGrid::gridAreaBreadthForChild): Ditto.
13393        * rendering/style/GridCoordinate.h: Define GridSpan::iterator.
13394        (WebCore::GridSpan::begin): Return resolved initial position.
13395        (WebCore::GridSpan::end): Return next to resolved final position.
13396        * rendering/style/GridResolvedPosition.h:
13397        (WebCore::GridResolvedPosition::operator*): Add operator required by
13398        range-based for loops.
13399        (WebCore::GridResolvedPosition::operator!=): Add not equal operator.
13400
134012014-06-20  Carlos Garcia Campos  <cgarcia@igalia.com>
13402
13403        Unreviewed. Fix GTK+ debug build after r170174.
13404
13405        * bindings/gobject/WebKitDOMNodeFilter.cpp:
13406        (WebKit::nodeFilterObjectDestroyedCallback):
13407
134082014-06-20  Tim Horton  <timothy_horton@apple.com>
13409
13410        LayerPool’d PlatformCALayerRemote/RemoteLayerBackingStore can have stale context pointers
13411        https://bugs.webkit.org/show_bug.cgi?id=134050
13412        <rdar://problem/17315114>
13413
13414        Reviewed by Simon Fraser.
13415
13416        * WebCore.exp.in:
13417        * WebCore.xcodeproj/project.pbxproj:
13418        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
13419        (WebCore::MemoryPressureHandler::platformReleaseMemory):
13420        Drain all LayerPools upon memory pressure.
13421
13422        * platform/graphics/ca/LayerPool.cpp:
13423        (WebCore::LayerPool::LayerPool):
13424        (WebCore::LayerPool::~LayerPool):
13425        (WebCore::LayerPool::allLayerPools):
13426        (WebCore::LayerPool::sharedPool): Deleted.
13427        * platform/graphics/ca/LayerPool.h:
13428        * platform/graphics/ca/PlatformCALayer.cpp:
13429        (WebCore::PlatformCALayer::createCompatibleLayerWithSize):
13430        Add createCompatibleLayerWithSize, which optionally tries to take said layer from the LayerPool.
13431
13432        (WebCore::PlatformCALayer::moveToLayerPool):
13433        Add moveToLayerPool, which moves the layer to the LayerPool.
13434
13435        (WebCore::PlatformCALayer::layerPool):
13436        The LayerPool for each layer is obtained via PlatformCALayer::layerPool(), which subclasses can override for special behaviors.
13437        The base class uses a global LayerPool.
13438
13439        * platform/graphics/ca/PlatformCALayer.h:
13440        * platform/graphics/ca/TileController.cpp:
13441        (WebCore::TileController::createTileLayer):
13442        * platform/graphics/ca/TileGrid.cpp:
13443        (WebCore::TileGrid::removeTiles):
13444
134452014-06-19  Carlos Garcia Campos  <cgarcia@igalia.com>
13446
13447        [GTK] webkit_dom_document_create_tree_walker impossible to use due to WebKitDOMNodeFilter
13448        https://bugs.webkit.org/show_bug.cgi?id=93002
13449
13450        Reviewed by Gustavo Noronha Silva.
13451
13452        Add custom implementation of WebKitDOMNodeFilter to expose it as
13453        an interface instead of a class.
13454
13455        * PlatformGTK.cmake: Add new files to compilation.
13456        * bindings/gobject/GObjectNodeFilterCondition.cpp: Added.
13457        (WebCore::GObjectNodeFilterCondition::~GObjectNodeFilterCondition):
13458        Reset the NodeFilter WebCore object associated to the
13459        WebKitDOMNodeFilter object.
13460        (WebCore::GObjectNodeFilterCondition::acceptNode): Call webkit_dom_node_filter_accept_node().
13461        * bindings/gobject/GObjectNodeFilterCondition.h: Added.
13462        (WebCore::GObjectNodeFilterCondition::create): Create a new
13463        GObjectNodeFilterCondition for the given WebKitDOMNodeFilter.
13464        (WebCore::GObjectNodeFilterCondition::GObjectNodeFilterCondition):
13465        * bindings/gobject/WebKitDOMNodeFilter.cpp: Added.
13466        (webkit_dom_node_filter_default_init):
13467        (webkit_dom_node_filter_accept_node):
13468        (WebKit::nodeFilterMap): Map NodeFilter WebCore objects to
13469        WebKitDOMNodeFilter objects.
13470        (WebKit::nodeFilterObjectDestroyedCallback): Remove the node
13471        filter form the map when the WebKitDOMNodeFilter objecrt is destroyed.
13472        (WebKit::kit): Return the WebKitDOMNodeFilter object for the given
13473        NodeFilter WebCore object.
13474        (WebKit::core): Get or create a NodeFilter WebCore object
13475        associated to the given WebKitDOMNodeFilter.
13476        * bindings/gobject/WebKitDOMNodeFilter.h: Added.
13477        * bindings/gobject/WebKitDOMNodeFilter.symbols: Added.
13478        * bindings/gobject/WebKitDOMNodeFilterPrivate.h: Added.
13479        * bindings/scripts/CodeGeneratorGObject.pm:
13480        (GenerateFunction): Add exceptions for NodeFilter parameters since
13481        the core method returns a PassRefPtr.
13482
134832014-06-19  Carlos Garcia Campos  <cgarcia@igalia.com>
13484
13485        [GTK] Limit the amount of API exposed to GObject DOM bindings API
13486        https://bugs.webkit.org/show_bug.cgi?id=133726
13487
13488        Reviewed by Gustavo Noronha Silva.
13489
13490        Split the GObject DOM bindings API into stable and unstable. The
13491        unstable API is not included in the main webkitdom.h file, so that
13492        to use it users have to include the headers individually and
13493        define a macro WEBKIT_DOM_USE_UNSTABLE_API. For unstable methods
13494        of stable classes we generate a {ClassName}Unstable.h header file
13495        containing the unstable API. From now on we only keep backwards
13496        compatibility for the stable API.
13497
13498        * PlatformGTK.cmake: Split GObject DOM bindings related variables
13499        into Stable and Unstable. Add also
13500        * bindings/gobject/WebKitDOMCustom.cpp:
13501        (webkit_dom_html_media_element_set_current_time): Deleted.
13502        (webkit_dom_text_track_get_kind): Deleted.
13503        (webkit_dom_text_track_get_mode): Deleted.
13504        (webkit_dom_text_track_set_mode): Deleted.
13505        * bindings/gobject/WebKitDOMCustom.h:
13506        * bindings/gobject/WebKitDOMCustom.symbols: Remove custom symbols
13507        added due to API changes.
13508        * bindings/gobject/WebKitDOMPrivate.h: Include webkitdomdefines-unstable.h.
13509        * bindings/gobject/webkitdom.symbols: Remove all unstable symbols.
13510        * bindings/scripts/CodeGeneratorGObject.pm:
13511        (SkipFunction): Do not skip webkit_dom_html_media_element_set_current_time anymore.
13512        (GenerateHeader): Only force single header include for stable
13513        headers and add WEBKIT_DOM_USE_UNSTABLE_API #ifdef to unstable headers.
13514        (GenerateFunction): Only add stable symbols to the symbols
13515        array. Add function prototypes to main header or unstable header
13516        depending on whether it's an unstable symbol for a stable class or
13517        not. Also add Stability gtk-doc tag to unstable methods.
13518        (GenerateEndHeader): Add required #endifs
13519        (WriteData): Write also an Unstable.h header when appropriate and
13520        only generate a symbols file for stable classes.
13521        (ReadStableSymbols): Read the stable symbols for the current class.
13522        (GenerateInterface): Call ReadStableSymbols.
13523        * bindings/scripts/gobject-generate-headers.pl: Generate webkitdomdefines-unstable.h.
13524        * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
13525        * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
13526        * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
13527        * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.h:
13528        * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
13529        * bindings/scripts/test/GObject/WebKitDOMTestException.h:
13530        * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.h:
13531        * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
13532        * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.h:
13533        * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.h:
13534        * bindings/scripts/test/GObject/WebKitDOMTestNode.h:
13535        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.h:
13536        * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
13537        * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.h:
13538        * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h:
13539        * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.h:
13540        * bindings/scripts/test/GObject/WebKitDOMattribute.h:
13541        * bindings/scripts/test/GObject/WebKitDOMreadonly.h:
13542
135432014-06-19  Andreas Kling  <akling@apple.com>
13544
13545        When simulating memory pressure, GC *after* releasing WebCore resources.
13546
13547        Since clearing the page cache is likely to create lots of garbage, defer the
13548        synchronous GC until after the WebCore pressure relief, so we can see the
13549        effect of clearing out all those pages.
13550
13551        Rubber-stamped by Gavin Barraclough.
13552
13553        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
13554        (WebCore::MemoryPressureHandler::install):
13555
135562014-06-18  Sam Weinig  <sam@webkit.org>
13557
13558        Move generate prototype and constructor classes into the generated implementation files
13559        https://bugs.webkit.org/show_bug.cgi?id=134054
13560
13561        Reviewed by Oliver Hunt.
13562
13563        In an effort to reduce the size of the generated bindings headers, which is important
13564        as the generated headers get included in a lot of places, this patch moves the prototype
13565        and constructor declarations from the header to implementation file. This works because,
13566        for the most part, no code cares about the prototype or constructors except the instance.
13567
13568        There are a few exceptions which had to be accounted for:
13569        - The global objects (JSDOMWindow and JSWorkerGlobalScope) need to have their prototypes
13570          available during initialization, so they remain in the header.
13571        - JSLocation requires customizing some aspects of the prototype behavior, so its prototype,
13572          and any future class that uses JSCustomNamedGetterOnPrototype or JSCustomDefineOwnPropertyOnPrototype,
13573          remains in the header.
13574        - A few classes had custom constructor functions. Instead of keeping the entire constructor
13575          in the header, I opted for pulling just the static constructor function into the header, and
13576          modifying the custom constructors to use the DOMConstructorObject type as the callee, since the
13577          more specific type was unnecessary.
13578
13579        As a result of making these changes, I was also able to remove the #include of JSDOMBinding.h from
13580        all the headers, which brought in quite a bit.
13581
13582        * bindings/js/JSAudioContextCustom.cpp:
13583        (WebCore::constructJSAudioContext):
13584        (WebCore::JSAudioContextConstructor::constructJSAudioContext): Deleted.
13585        * bindings/js/JSBlobCustom.cpp:
13586        (WebCore::constructJSBlob):
13587        (WebCore::JSBlobConstructor::constructJSBlob): Deleted.
13588        * bindings/js/JSCryptoCustom.cpp:
13589        * bindings/js/JSDOMFormDataCustom.cpp:
13590        (WebCore::constructJSDOMFormData):
13591        (WebCore::JSDOMFormDataConstructor::constructJSDOMFormData): Deleted.
13592        * bindings/js/JSDOMMimeTypeArrayCustom.cpp:
13593        * bindings/js/JSDOMPluginArrayCustom.cpp:
13594        * bindings/js/JSDOMPluginCustom.cpp:
13595        * bindings/js/JSDataCueCustom.cpp:
13596        (WebCore::constructJSDataCue):
13597        (WebCore::JSDataCueConstructor::constructJSDataCue): Deleted.
13598        * bindings/js/JSDataTransferCustom.cpp:
13599        * bindings/js/JSEventCustom.cpp:
13600        * bindings/js/JSFileReaderCustom.cpp:
13601        * bindings/js/JSHistoryCustom.cpp:
13602        * bindings/js/JSIDBAnyCustom.cpp:
13603        * bindings/js/JSIDBDatabaseCustom.cpp:
13604        * bindings/js/JSIDBObjectStoreCustom.cpp:
13605        * bindings/js/JSImageConstructor.cpp:
13606        (WebCore::JSImageConstructor::finishCreation):
13607        * bindings/js/JSImageDataCustom.cpp:
13608        * bindings/js/JSInspectorFrontendHostCustom.cpp:
13609        * bindings/js/JSLocationCustom.cpp:
13610        * bindings/js/JSMessagePortCustom.cpp:
13611        * bindings/js/JSMutationObserverCustom.cpp:
13612        (WebCore::constructJSMutationObserver):
13613        (WebCore::JSMutationObserverConstructor::constructJSMutationObserver): Deleted.
13614        * bindings/js/JSSQLResultSetRowListCustom.cpp:
13615        * bindings/js/JSSQLTransactionSyncCustom.cpp:
13616        * bindings/js/JSSVGLengthCustom.cpp:
13617        * bindings/js/JSSharedWorkerCustom.cpp:
13618        (WebCore::constructJSSharedWorker):
13619        (WebCore::JSSharedWorkerConstructor::constructJSSharedWorker): Deleted.
13620        * bindings/js/JSStorageCustom.cpp:
13621        * bindings/js/JSUserMessageHandlersNamespaceCustom.cpp:
13622        * bindings/js/JSWebKitPointCustom.cpp:
13623        (WebCore::constructJSWebKitPoint):
13624        (WebCore::JSWebKitPointConstructor::constructJSWebKitPoint): Deleted.
13625        * bindings/js/JSWorkerCustom.cpp:
13626        (WebCore::constructJSWorker):
13627        (WebCore::JSWorkerConstructor::constructJSWorker): Deleted.
13628        * bindings/js/SerializedScriptValue.cpp:
13629        * bindings/scripts/CodeGeneratorJS.pm:
13630        (GenerateHeader):
13631        (GenerateImplementation):
13632        (GeneratePrototypeDeclaration):
13633        (GenerateConstructorDeclaration):
13634        (GenerateConstructorHelperMethods):
13635        (HeaderNeedsPrototypeDeclaration):
13636        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
13637        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
13638        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
13639        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
13640        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
13641        * bindings/scripts/test/JS/JSTestEventConstructor.h:
13642        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
13643        * bindings/scripts/test/JS/JSTestEventTarget.h:
13644        * bindings/scripts/test/JS/JSTestException.cpp:
13645        * bindings/scripts/test/JS/JSTestException.h:
13646        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
13647        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
13648        * bindings/scripts/test/JS/JSTestInterface.cpp:
13649        * bindings/scripts/test/JS/JSTestInterface.h:
13650        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
13651        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
13652        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
13653        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
13654        * bindings/scripts/test/JS/JSTestNode.cpp:
13655        * bindings/scripts/test/JS/JSTestNode.h:
13656        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
13657        * bindings/scripts/test/JS/JSTestNondeterministic.h:
13658        * bindings/scripts/test/JS/JSTestObj.cpp:
13659        * bindings/scripts/test/JS/JSTestObj.h:
13660        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
13661        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
13662        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
13663        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
13664        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
13665        * bindings/scripts/test/JS/JSTestTypedefs.h:
13666        * bindings/scripts/test/JS/JSattribute.cpp:
13667        * bindings/scripts/test/JS/JSattribute.h:
13668        * bindings/scripts/test/JS/JSreadonly.cpp:
13669        * bindings/scripts/test/JS/JSreadonly.h:
13670
13671
136722014-06-19  peavo@outlook.com  <peavo@outlook.com>
13673
13674        [Curl] Compile errors related to http header field names.
13675        https://bugs.webkit.org/show_bug.cgi?id=134029
13676
13677        Reviewed by Brent Fulgham.
13678
13679        Http header field names should now be specified with an enum, not a string.
13680
13681        * platform/network/curl/MultipartHandle.cpp:
13682        (WebCore::MultipartHandle::didReceiveResponse):
13683        * platform/network/curl/ResourceHandleManager.cpp:
13684        (WebCore::getProtectionSpace):
13685
136862014-06-19  Anders Carlsson  <andersca@apple.com>
13687
13688        Put the divider in the right place.
13689
13690        * DerivedSources.make:
13691
136922014-06-19  Anders Carlsson  <andersca@apple.com>
13693
13694        Address a review comment from Darin.
13695
13696        * inspector/InspectorResourceAgent.cpp:
13697        (WebCore::InspectorResourceAgent::willLoadXHR):
13698
136992014-06-19  Anders Carlsson  <andersca@apple.com>
13700
13701        Simplify two HistoryController member functions
13702        https://bugs.webkit.org/show_bug.cgi?id=134064
13703
13704        Reviewed by Dan Bernstein.
13705
13706        Remove the FrameLoadType parameter from recursiveSetProvisionalItem,
13707        use early returns and modern loops.
13708
13709        * loader/HistoryController.cpp:
13710        (WebCore::HistoryController::goToItem):
13711        (WebCore::HistoryController::recursiveSetProvisionalItem):
13712        (WebCore::HistoryController::recursiveGoToItem):
13713        * loader/HistoryController.h:
13714
137152014-06-19  David Kilzer  <ddkilzer@apple.com>
13716
13717        MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL() leaks an NSMutableArray
13718        <http://webkit.org/b/134052>
13719
13720        Reviewed by Eric Carlson.
13721
13722        Fixes the following static analyzer warning:
13723
13724            WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:688:43: warning: Potential leak of an object stored into 'outOfBandTracks'
13725                    NSMutableArray* outOfBandTracks = [[NSMutableArray alloc] init];
13726                                                      ^
13727
13728        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
13729        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL):
13730        Use RetainPtr<NSMutableArray> to prevent a leak.  Use
13731        Objective-C literals to clean up the code.
13732
137332014-06-18  Zan Dobersek  <zdobersek@igalia.com>
13734
13735        ScriptExecutionContext::Task, FileThread::Task parameters should be values
13736        https://bugs.webkit.org/show_bug.cgi?id=134035
13737
13738        Reviewed by Anders Carlsson.
13739
13740        r170106 and similar previous changesets enforced ScriptExecutionContext::Task and
13741        FileThread::Task parameters as rvalue references. There's technically nothing wrong
13742        with that, but since both classes are move-only it is also not strictly required.
13743        Accepting these parameters as values is more common in C++ value semantics as well.
13744
13745        * dom/Document.cpp:
13746        (WebCore::Document::postTask):
13747        * dom/Document.h:
13748        * dom/ScriptExecutionContext.h:
13749        * fileapi/FileThread.cpp:
13750        (WebCore::FileThread::postTask):
13751        * fileapi/FileThread.h:
13752        * workers/DefaultSharedWorkerRepository.cpp:
13753        (WebCore::SharedWorkerProxy::postTaskToLoader):
13754        (WebCore::SharedWorkerProxy::postTaskForModeToWorkerGlobalScope):
13755        * workers/WorkerGlobalScope.cpp:
13756        (WebCore::WorkerGlobalScope::postTask):
13757        * workers/WorkerGlobalScope.h:
13758        * workers/WorkerLoaderProxy.h:
13759        * workers/WorkerMessagingProxy.cpp:
13760        (WebCore::WorkerMessagingProxy::postTaskToLoader):
13761        (WebCore::WorkerMessagingProxy::postTaskForModeToWorkerGlobalScope):
13762        * workers/WorkerMessagingProxy.h:
13763        * workers/WorkerRunLoop.cpp:
13764        (WebCore::WorkerRunLoop::postTask):
13765        (WebCore::WorkerRunLoop::postTaskAndTerminate):
13766        (WebCore::WorkerRunLoop::postTaskForMode):
13767        (WebCore::WorkerRunLoop::Task::create):
13768        (WebCore::WorkerRunLoop::Task::Task):
13769        * workers/WorkerRunLoop.h:
13770
137712014-06-18  James Craig  <jcraig@apple.com>
13772
13773        Web Inspector: AXI: expose aria-relevant
13774        https://bugs.webkit.org/show_bug.cgi?id=130913
13775
13776        Reviewed by Joseph Pecoraro.
13777
13778        Expose ARIA live region relevance in Web Inspector.
13779        E.g. "Live: Assertive (Additions, Text)"
13780
13781        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode_liveRegion.html
13782
13783        * inspector/InspectorDOMAgent.cpp:
13784        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties): Support for liveRegionRelevant.
13785        * inspector/protocol/DOM.json: Defined enum values and array passed to client.
13786
137872014-06-18  Simon Fraser  <simon.fraser@apple.com>
13788
13789        Add rebeccapurple to CSS named color list
13790        https://bugs.webkit.org/show_bug.cgi?id=133804
13791
13792        Reviewed by Jer Noble.
13793
13794        Add the named color "rebeccapurple" (#639).
13795
13796        * css/SVGCSSValueKeywords.in:
13797        * platform/ColorData.gperf:
13798
137992014-06-11  Jeffrey Pfau  <jpfau@apple.com>
13800
13801        Fix flaky beforeload tests
13802        https://bugs.webkit.org/show_bug.cgi?id=133685
13803
13804        Reviewed by David Kilzer.
13805
13806        * loader/FrameLoader.cpp:
13807        (WebCore::FrameLoader::loadURL):
13808
138092014-06-18  Anders Carlsson  <andersca@apple.com>
13810
13811        Make FrameLoadType a strongly typed enum
13812        https://bugs.webkit.org/show_bug.cgi?id=134047
13813
13814        Reviewed by Andreas Kling.
13815
13816        * history/BackForwardController.cpp:
13817        (WebCore::BackForwardController::goBackOrForward):
13818        (WebCore::BackForwardController::goBack):
13819        (WebCore::BackForwardController::goForward):
13820        * history/PageCache.cpp:
13821        (WebCore::logCanCachePageDecision):
13822        (WebCore::PageCache::canCache):
13823        * loader/FrameLoader.cpp:
13824        (WebCore::isBackForwardLoadType):
13825        (WebCore::FrameLoader::FrameLoader):
13826        (WebCore::FrameLoader::loadURLIntoChildFrame):
13827        (WebCore::FrameLoader::prepareForLoadStart):
13828        (WebCore::FrameLoader::loadFrameRequest):
13829        (WebCore::FrameLoader::loadURL):
13830        (WebCore::FrameLoader::load):
13831        (WebCore::FrameLoader::reloadWithOverrideEncoding):
13832        (WebCore::FrameLoader::reload):
13833        (WebCore::FrameLoader::commitProvisionalLoad):
13834        (WebCore::FrameLoader::transitionToCommitted):
13835        (WebCore::FrameLoader::isReplacing):
13836        (WebCore::FrameLoader::setReplacing):
13837        (WebCore::FrameLoader::subresourceCachePolicy):
13838        (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
13839        (WebCore::FrameLoader::addExtraFieldsToRequest):
13840        (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
13841        (WebCore::FrameLoader::shouldPerformFragmentNavigation):
13842        (WebCore::FrameLoader::continueLoadAfterNewWindowPolicy):
13843        (WebCore::FrameLoader::loadDifferentDocumentItem):
13844        * loader/FrameLoaderTypes.h:
13845        * loader/HistoryController.cpp:
13846        (WebCore::HistoryController::restoreDocumentState):
13847        (WebCore::HistoryController::updateForReload):
13848        (WebCore::HistoryController::isReplaceLoadTypeWithProvisionalItem):
13849        (WebCore::HistoryController::isReloadTypeWithProvisionalItem):
13850        * loader/NavigationAction.cpp:
13851        (WebCore::navigationType):
13852        * loader/PolicyChecker.cpp:
13853        (WebCore::PolicyChecker::PolicyChecker):
13854        (WebCore::PolicyChecker::checkNavigationPolicy):
13855        * loader/cache/CachedResourceLoader.cpp:
13856        (WebCore::CachedResourceLoader::cachePolicy):
13857        * loader/icon/IconController.cpp:
13858        (WebCore::IconController::startLoader):
13859
138602014-06-18  Alex Christensen  <achristensen@webkit.org>
13861
13862        [curl] Unreviewed speculative build fix after r170021.
13863
13864        * platform/network/curl/CurlCacheEntry.cpp:
13865        (WebCore::CurlCacheEntry::setResponseFromCachedHeaders):
13866        (WebCore::CurlCacheEntry::parseResponseHeaders):
13867        * platform/network/curl/CurlDownload.cpp:
13868        (WebCore::CurlDownload::didReceiveHeader):
13869        * platform/network/curl/ResourceHandleManager.cpp:
13870        (WebCore::getProtectionSpace):
13871        (WebCore::headerCallback):
13872        Use HTTPHeaderName constants.
13873
138742014-06-18  Simon Fraser  <simon.fraser@apple.com>
13875
13876        Move the removeNode() tree walking from ScrollingStateNote into ScrollingStateTree
13877        https://bugs.webkit.org/show_bug.cgi?id=134043
13878
13879        Reviewed by Beth Dakin.
13880
13881        It's cleaner if ScrollingStateTree does the descendant walk when removing nodes.
13882        We can simply start the "willBeRemoved" walk at the node in question.
13883        
13884        Have willRemoveNode() just remove the node from the m_stateNodeMap directly, rather
13885        than this happening in a separate walk of m_nodesRemovedSinceLastCommit.
13886
13887        * page/scrolling/ScrollingStateNode.cpp:
13888        (WebCore::ScrollingStateNode::removeDescendant): Deleted.
13889        (WebCore::ScrollingStateNode::willBeRemovedFromStateTree): Deleted.
13890        * page/scrolling/ScrollingStateNode.h:
13891        * page/scrolling/ScrollingStateTree.cpp:
13892        (WebCore::ScrollingStateTree::attachNode):
13893        (WebCore::ScrollingStateTree::detachNode):
13894        (WebCore::ScrollingStateTree::clear):
13895        (WebCore::ScrollingStateTree::removeNodeAndAllDescendants):
13896        (WebCore::ScrollingStateTree::recursiveNodeWillBeRemoved):
13897        (WebCore::ScrollingStateTree::willRemoveNode):
13898        (WebCore::ScrollingStateTree::removeNode): Deleted.
13899        * page/scrolling/ScrollingStateTree.h:
13900
139012014-06-18  Alex Christensen  <achristensen@webkit.org>
13902
13903        [iOS WebGL] Fixed WEBGL_compressed_texture_pvrtc.
13904        https://bugs.webkit.org/show_bug.cgi?id=133561
13905        
13906        Based on Blink r153971 by bajones@chromium.org.
13907
13908        Reviewed by Dean Jackson.
13909
13910        No new tests, but this should fix webgl-compressed-texture-pvrtc.html.
13911
13912        * html/canvas/WebGLRenderingContext.cpp:
13913        (WebCore::WebGLRenderingContext::validateCompressedTexDimensions):
13914        (WebCore::WebGLRenderingContext::validateCompressedTexSubDimensions):
13915        Added checks for pvrtc.
13916
139172014-06-18  Anders Carlsson  <andersca@apple.com>
13918
13919        Work around a Windows compiler crash.
13920
13921        * loader/archive/cf/LegacyWebArchive.cpp:
13922        (WebCore::LegacyWebArchive::createFromSelection):
13923
139242014-06-18  Benjamin Poulain  <benjamin@webkit.org>
13925
13926        Subtrees with :first-child and :last-child are not invalidated when siblings are added/removed
13927        https://bugs.webkit.org/show_bug.cgi?id=133934
13928
13929        Reviewed by Antti Koivisto.
13930
13931        When adding/removing nodes on an element, we try to invalidate only the elements that are
13932        affected. In the case of :first-child and :last-child, that optimizations is implemented
13933        through two types of flags that are updated during style resolution.
13934
13935        The first flag is childrenAffectedByFirstChildRules (childrenAffectedByLastChildRules),
13936        set on the parent of any element that could be affected by :first-child (:last-child).
13937
13938        The other part of the optimization is marking the style itself with firstChildState (lastChildState)
13939        to further reduce invalidations.
13940
13941        The problem in this case happen with a subtree of element is detached. Since there is no renderer,
13942        the computed style is resolved ad-hoc and stored directly on the element. When the element is moved,
13943        the computed style was never cleared because the invalidation optimizations were not handling
13944        elements without style.
13945
13946        Credit to Yusuke Suzuki for discovering the issue and creating test cases.
13947
13948        Tests: fast/css/getComputedStyle/empty-update-without-renderer.html
13949               fast/css/getComputedStyle/first-child-update-without-renderer.html
13950               fast/css/getComputedStyle/last-child-update-without-renderer.html
13951
13952        * dom/Element.cpp:
13953        (WebCore::checkForEmptyStyleChange):
13954        Clean up: pull the style directly from the function instead of expection the call sites to do that.
13955        Refine the checks to avoid invalidation.
13956
13957        (WebCore::checkForSiblingStyleChanges):
13958        Do not early return if the parent is detached, the children may still need invalidation.
13959
13960        When there is no renderer, assume the worst first-child/last-child and force the invalidation.
13961
13962        (WebCore::Element::childrenChanged):
13963
139642014-06-18  Daniel Bates  <dabates@apple.com>
13965
13966        REGRESSION (r167856): Unable to log into HSBC app
13967        https://bugs.webkit.org/show_bug.cgi?id=133991
13968        <rdar://problem/17044839>
13969
13970        Reviewed by David Kilzer.
13971
13972        Following <http://trac.webkit.org/changeset/167856> we disallow "navigation to any URL that is
13973        invalid, except for JavaScript URLs, which need not be valid." A byproduct of this policy
13974        decision is that we no longer notify the WebKit client to about a navigation if the destination
13975        URL is invalid. And some apps, including the HSBC app for iOS, have logic to intercept URLs
13976        as a means to pass data from their WebView-embedded web app to the WebView. We should expose a
13977        setting called allowNavigationToInvalidURL (disabled by default on all ports and conditionally
13978        enabled on iOS) to toggle whether WebCore allows navigation to any URL, even if its invalid,
13979        so as to not break clients that intercept URLs and have custom logic to handle them.
13980
13981        Tests: fast/loader/allow-redirect-to-invalid-url-using-javascript.html
13982               fast/loader/allow-redirect-to-invalid-url-using-meta-refresh.html
13983               fast/loader/disallow-redirect-to-invalid-url-using-javascript.html
13984               fast/loader/disallow-redirect-to-invalid-url-using-meta-refresh.html
13985
13986        * loader/NavigationScheduler.cpp:
13987        (WebCore::NavigationScheduler::shouldScheduleNavigation): Modified to only validate
13988        the URL when the setting allowNavigationToInvalidURL is disabled.
13989        * page/Settings.in: Added setting allowNavigationToInvalidURL (disabled by default).
13990
139912014-06-18  Simon Fraser  <simon.fraser@apple.com>
13992
13993        Make ScrollingStateNodes refcounted, and other minor cleanup
13994        https://bugs.webkit.org/show_bug.cgi?id=134040
13995
13996        Reviewed by Beth Dakin.
13997
13998        Prepare for future scrolling frame gyrations by making
13999        ScrollingStateNodes refcounted.
14000        
14001        Rename ScrollingStateNode::removeChild() to removeDescendant()
14002        since that's what it does. Also rename didRemoveNode() to willRemoveNode()
14003        to better match the behavior.
14004        
14005        Use 'auto' in more places.
14006
14007        * page/scrolling/AsyncScrollingCoordinator.cpp:
14008        (WebCore::AsyncScrollingCoordinator::syncChildPositions):
14009        * page/scrolling/ScrollingStateFixedNode.cpp:
14010        (WebCore::ScrollingStateFixedNode::create):
14011        (WebCore::ScrollingStateFixedNode::clone):
14012        * page/scrolling/ScrollingStateFixedNode.h:
14013        * page/scrolling/ScrollingStateFrameScrollingNode.cpp:
14014        (WebCore::ScrollingStateFrameScrollingNode::create):
14015        (WebCore::ScrollingStateFrameScrollingNode::clone):
14016        * page/scrolling/ScrollingStateFrameScrollingNode.h:
14017        * page/scrolling/ScrollingStateNode.cpp:
14018        (WebCore::ScrollingStateNode::cloneAndReset):
14019        (WebCore::ScrollingStateNode::appendChild):
14020        (WebCore::ScrollingStateNode::removeDescendant):
14021        (WebCore::ScrollingStateNode::willBeRemovedFromStateTree):
14022        (WebCore::ScrollingStateNode::removeChild): Deleted.
14023        * page/scrolling/ScrollingStateNode.h:
14024        (WebCore::ScrollingStateNode::children):
14025        * page/scrolling/ScrollingStateOverflowScrollingNode.cpp:
14026        (WebCore::ScrollingStateOverflowScrollingNode::create):
14027        (WebCore::ScrollingStateOverflowScrollingNode::clone):
14028        * page/scrolling/ScrollingStateOverflowScrollingNode.h:
14029        * page/scrolling/ScrollingStateStickyNode.cpp:
14030        (WebCore::ScrollingStateStickyNode::create):
14031        (WebCore::ScrollingStateStickyNode::clone):
14032        * page/scrolling/ScrollingStateStickyNode.h:
14033        * page/scrolling/ScrollingStateTree.cpp:
14034        (WebCore::ScrollingStateTree::attachNode):
14035        (WebCore::ScrollingStateTree::removeNode):
14036        (WebCore::ScrollingStateTree::willRemoveNode):
14037        (WebCore::ScrollingStateTree::didRemoveNode): Deleted.
14038        * page/scrolling/ScrollingStateTree.h:
14039        (WebCore::ScrollingStateTree::setRootStateNode):
14040        * page/scrolling/ScrollingTree.cpp:
14041        (WebCore::ScrollingTree::updateTreeFromStateNode):
14042
140432014-06-18  Anders Carlsson  <andersca@apple.com>
14044
14045        Adopt modern C++11 loops and fix WebArchive creation functions
14046        https://bugs.webkit.org/show_bug.cgi?id=134032
14047
14048        Reviewed by Andreas Kling.
14049
14050        Use modern loops in a couple of places, fix DocumentLoader::subresources() to return a Vector,
14051        and stop using Vectors of PassRefPtrs.
14052
14053        * WebCore.exp.in:
14054        * dom/Document.cpp:
14055        (WebCore::Document::textInserted):
14056        (WebCore::Document::textRemoved):
14057        (WebCore::Document::textNodesMerged):
14058        * loader/DocumentLoader.cpp:
14059        (WebCore::DocumentLoader::subresources):
14060        (WebCore::DocumentLoader::getSubresources): Deleted.
14061        * loader/DocumentLoader.h:
14062        * loader/appcache/ApplicationCache.cpp:
14063        (WebCore::ApplicationCache::dump):
14064        * loader/appcache/ApplicationCache.h:
14065        (WebCore::ApplicationCache::resources):
14066        (WebCore::ApplicationCache::begin): Deleted.
14067        (WebCore::ApplicationCache::end): Deleted.
14068        * loader/appcache/ApplicationCacheGroup.cpp:
14069        (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
14070        * loader/appcache/ApplicationCacheHost.cpp:
14071        (WebCore::ApplicationCacheHost::fillResourceList):
14072        * loader/appcache/ApplicationCacheStorage.cpp:
14073        (WebCore::ApplicationCacheStorage::fallbackCacheGroupForURL):
14074        (WebCore::ApplicationCacheStorage::store):
14075        (WebCore::ApplicationCacheStorage::empty):
14076        (WebCore::ApplicationCacheStorage::storeCopyOfCache):
14077        * loader/archive/cf/LegacyWebArchive.cpp:
14078        (WebCore::LegacyWebArchive::create):
14079        (WebCore::LegacyWebArchive::createFromSelection):
14080        * loader/archive/cf/LegacyWebArchive.h:
14081        * xml/XMLHttpRequestProgressEventThrottle.cpp:
14082        (WebCore::XMLHttpRequestProgressEventThrottle::dispatchDeferredEvents):
14083
140842014-06-18  Alex Christensen  <achristensen@webkit.org>
14085
14086        Remove duplicate code using sdiv.
14087        https://bugs.webkit.org/show_bug.cgi?id=133764
14088
14089        Reviewed by Daniel Bates.
14090
14091        * cssjit/SelectorCompiler.cpp:
14092        (WebCore::SelectorCompiler::SelectorCodeGenerator::modulo):
14093        Use template sdiv for apple armv7s and arm64.
14094
140952014-06-18  Zan Dobersek  <zdobersek@igalia.com>
14096
14097        ScriptExecutionContext::Task parameters should always be rvalue references
14098        https://bugs.webkit.org/show_bug.cgi?id=133615
14099
14100        Reviewed by Darin Adler.
14101
14102        ScriptExecutionContext::Task parameters should be rvalue references as the
14103        passed-in objects are always ScriptExecutionContext::Task rvalues that were
14104        implicitly constructed from a lambda function or rvalues of objects that
14105        derive from ScriptExecutionContext::Task.
14106
14107        This isn't really necessary since ScriptExecutionContext::Task is non-copyable
14108        and we have to use move semantics anyway, but it makes it clear that these
14109        objects are expiring rvalues that must be properly dealt with.
14110
14111        * dom/Document.cpp:
14112        (WebCore::Document::postTask):
14113        * dom/Document.h:
14114        * dom/ScriptExecutionContext.h:
14115        * workers/DefaultSharedWorkerRepository.cpp:
14116        (WebCore::SharedWorkerProxy::postTaskToLoader):
14117        (WebCore::SharedWorkerProxy::postTaskForModeToWorkerGlobalScope):
14118        * workers/WorkerGlobalScope.cpp:
14119        (WebCore::WorkerGlobalScope::postTask):
14120        * workers/WorkerGlobalScope.h:
14121        * workers/WorkerLoaderProxy.h:
14122        * workers/WorkerMessagingProxy.cpp:
14123        (WebCore::WorkerMessagingProxy::postTaskToLoader):
14124        (WebCore::WorkerMessagingProxy::postTaskForModeToWorkerGlobalScope):
14125        * workers/WorkerMessagingProxy.h:
14126        * workers/WorkerRunLoop.cpp:
14127        (WebCore::WorkerRunLoop::postTask):
14128        (WebCore::WorkerRunLoop::postTaskAndTerminate):
14129        (WebCore::WorkerRunLoop::postTaskForMode):
14130        (WebCore::WorkerRunLoop::Task::create):
14131        (WebCore::WorkerRunLoop::Task::Task):
14132        * workers/WorkerRunLoop.h:
14133
141342014-06-18  peavo@outlook.com  <peavo@outlook.com>
14135
14136        [WinCairo] Compile errors when trying to compile CA code.
14137        https://bugs.webkit.org/show_bug.cgi?id=134030
14138
14139        Reviewed by Simon Fraser.
14140
14141        WinCairo does not USE(CA).
14142
14143        * WebCore.vcxproj/WebCore.vcxproj:
14144        * platform/graphics/ca/TileController.h:
14145
141462014-06-17  Tim Horton  <timothy_horton@apple.com>
14147
14148        [iOS][wk2] Use ImageDocument to display subframe PDFs
14149        https://bugs.webkit.org/show_bug.cgi?id=133944
14150        <rdar://problem/17205983>
14151
14152        Reviewed by Dan Bates.
14153
14154        * dom/DOMImplementation.cpp:
14155        (WebCore::DOMImplementation::createDocument):
14156        Make a ImageDocument to show our subframe PDF, if the setting is enabled.
14157
14158        * html/ImageDocument.cpp:
14159        (WebCore::ImageDocument::finishedParsing):
14160        (WebCore::ImageDocument::createDocumentStructure):
14161        Set the ResourceResponse on the ImageElement upon creation, instead of
14162        when the load finishes. This way, when the internal CachedImage creates
14163        its Image, it can have the correct MIME type for the response, and can
14164        make a PDFDocumentImage if necessary.
14165
14166        We never noticed this before because CachedImage falls back to making a
14167        BitmapImage, and that was the only case that was normally used.
14168
14169        Throw an explicit white background behind PDF ImageDocuments; PDFDocumentImage
14170        paints with a transparent background, but when used as an ImageDocument
14171        it seems reasonable to assume that there should be a white page background
14172        (similar to what PDFPlugin and friends do).
14173
14174        * loader/DocumentWriter.cpp:
14175        (WebCore::DocumentWriter::createDocument):
14176        Don't make a PDFDocument if we want to use an ImageDocument for this subframe PDF.
14177
14178        * page/Settings.in:
14179
14180        * platform/MIMETypeRegistry.cpp:
14181        (WebCore::MIMETypeRegistry::isPDFMIMEType):
14182        * platform/MIMETypeRegistry.h:
14183        Expose the already implemented pdfMIMETypes table just like all the rest.
14184
141852014-06-17  Ryuan Choi  <ryuan.choi@samsung.com>
14186
14187        Unreviewed build fix with ENABLE_NOSNIFF after r170021
14188
14189        * loader/cache/CachedScript.cpp:
14190        (WebCore::CachedScript::mimeTypeAllowedByNosniff):
14191
141922014-06-17  Jeremy Jones  <jeremyj@apple.com>
14193
14194        Improve enter and exit fullscreen transition by using two step transition.
14195        https://bugs.webkit.org/show_bug.cgi?id=133706
14196
14197        Reviewed by Simon Fraser.
14198
14199        setupFullscreen, creates the fullscreen views ready to receive the video layer.
14200        Once they are in place, didSetupFullscreen will move the video layer into the 
14201        new view hierarchy and initiate enterFullscreen to animate.
14202
14203        Reverse process for exit fullscreen.
14204
14205        * WebCore.exp.in: Add exports.
14206        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
14207        (-[WebVideoFullscreenController enterFullscreen:]):
14208        Refactor into didSetupFullscreen.
14209        (-[WebVideoFullscreenController didSetupFullscreen]):
14210        Move the video layer once fullscreen is ready to receive it.
14211        (-[WebVideoFullscreenController didExitFullscreen]):
14212        Move the video layer back into we the web page, and initiate cleanup.
14213        (-[WebVideoFullscreenController didCleanupFullscreen]):
14214        Refactord cleanup from didExitFullscreen.
14215        * platform/ios/WebVideoFullscreenInterfaceAVKit.h: Add delcarations.
14216        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
14217        (WebVideoFullscreenInterfaceAVKit::setupFullscreen):
14218        Refactored from enterFullscreen. Builds views ready to receive video layer.
14219        (WebVideoFullscreenInterfaceAVKit::enterFullscreen):
14220        Animates into fullscreen.
14221        (WebVideoFullscreenInterfaceAVKit::exitFullscreen):
14222        Animates from fullscreen. Cleanup is refactored into cleanupFullscreen()
14223        (WebVideoFullscreenInterfaceAVKit::cleanupFullscreen):
14224        Refactored from exitFullscreen(), removes views.
14225
142262014-06-17  Sam Weinig  <sam@webkit.org>
14227
14228        Remove unnecessary Structure flags from generated bindings
14229        https://bugs.webkit.org/show_bug.cgi?id=133992
14230
14231        Reviewed by Daniel Bates.
14232
14233        - Remove OverridesVisitChildren flag from DOM prototype objects. They never
14234          implement visitChildren.
14235        - Remove OverridesGetOwnPropertySlot and ImplementsHasInstance from DOM constructor
14236          objects. getOwnPropertySlot is never implemented and ImplementsHasInstance is inherited
14237          automatically from DOMConstructorObject.
14238        - If we are not changing any flags, we now don't emit StructureFlags at all for the class.
14239
14240        * bindings/scripts/CodeGeneratorJS.pm:
14241        (GenerateHeader):
14242        (GeneratePrototypeDeclaration):
14243        (GenerateConstructorDeclaration):
14244        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
14245        (WebCore::JSTestActiveDOMObjectPrototype::JSTestActiveDOMObjectPrototype):
14246        (WebCore::JSTestActiveDOMObjectConstructor::createStructure):
14247        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
14248        (WebCore::JSTestCustomNamedGetterPrototype::JSTestCustomNamedGetterPrototype):
14249        (WebCore::JSTestCustomNamedGetterConstructor::createStructure):
14250        * bindings/scripts/test/JS/JSTestEventConstructor.h:
14251        (WebCore::JSTestEventConstructorPrototype::JSTestEventConstructorPrototype):
14252        * bindings/scripts/test/JS/JSTestEventTarget.h:
14253        (WebCore::JSTestEventTargetPrototype::JSTestEventTargetPrototype):
14254        (WebCore::JSTestEventTargetConstructor::createStructure):
14255        * bindings/scripts/test/JS/JSTestException.h:
14256        (WebCore::JSTestExceptionPrototype::JSTestExceptionPrototype):
14257        (WebCore::JSTestExceptionConstructor::createStructure):
14258        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
14259        (WebCore::JSTestGenerateIsReachablePrototype::JSTestGenerateIsReachablePrototype):
14260        (WebCore::JSTestGenerateIsReachableConstructor::createStructure):
14261        * bindings/scripts/test/JS/JSTestInterface.h:
14262        (WebCore::JSTestInterfacePrototype::JSTestInterfacePrototype):
14263        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
14264        (WebCore::JSTestMediaQueryListListenerPrototype::JSTestMediaQueryListListenerPrototype):
14265        (WebCore::JSTestMediaQueryListListenerConstructor::createStructure):
14266        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
14267        (WebCore::JSTestNamedConstructorPrototype::JSTestNamedConstructorPrototype):
14268        (WebCore::JSTestNamedConstructorConstructor::createStructure):
14269        * bindings/scripts/test/JS/JSTestNode.h:
14270        (WebCore::JSTestNodePrototype::JSTestNodePrototype):
14271        * bindings/scripts/test/JS/JSTestNondeterministic.h:
14272        (WebCore::JSTestNondeterministicPrototype::JSTestNondeterministicPrototype):
14273        (WebCore::JSTestNondeterministicConstructor::createStructure):
14274        * bindings/scripts/test/JS/JSTestObj.h:
14275        (WebCore::JSTestObjPrototype::JSTestObjPrototype):
14276        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
14277        (WebCore::JSTestOverloadedConstructorsPrototype::JSTestOverloadedConstructorsPrototype):
14278        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
14279        (WebCore::JSTestSerializedScriptValueInterfacePrototype::JSTestSerializedScriptValueInterfacePrototype):
14280        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::createStructure):
14281        * bindings/scripts/test/JS/JSTestTypedefs.h:
14282        (WebCore::JSTestTypedefsPrototype::JSTestTypedefsPrototype):
14283        * bindings/scripts/test/JS/JSattribute.h:
14284        (WebCore::JSattributePrototype::JSattributePrototype):
14285        (WebCore::JSattributeConstructor::createStructure):
14286        * bindings/scripts/test/JS/JSreadonly.h:
14287        (WebCore::JSreadonlyPrototype::JSreadonlyPrototype):
14288        (WebCore::JSreadonlyConstructor::createStructure):
14289
142902014-06-17  Myles C. Maxfield  <mmaxfield@apple.com>
14291
14292        [iOS] Input type=time elements styled with SVG fonts have 0 width
14293        https://bugs.webkit.org/show_bug.cgi?id=133524
14294
14295        Reviewed by Simon Fraser.
14296
14297        Refactor how the LocalizedDateCache returns maximum widths for input elements. Currently,
14298        measuring the width of an SVG font requires a RenderObject for context, which the
14299        LocalizedDateCache can't know about (it would be a platform violation). Instead, the
14300        LocalizedDateCache can return the strings that it would use to measure the width, and the
14301        caller can actually run the width computation.
14302
14303        Test: fast/forms/time-input-svg-font.html
14304
14305        * platform/text/PlatformLocale.h:
14306        * platform/text/ios/LocalizedDateCache.h:
14307        * platform/text/ios/LocalizedDateCache.mm:
14308        (WebCore::LocalizedDateCache::maximumWidthForDateType): Take a delegate which can
14309        measure text
14310        (WebCore::LocalizedDateCache::calculateMaximumWidth): Perform maximum width
14311        computation using delegate.
14312        * platform/text/mac/LocaleMac.h:
14313        * platform/text/mac/LocaleMac.mm:
14314        (WebCore::LocaleMac::formatDateTime):
14315        (WebCore::LocaleMac::maximumWidthForDateType): Deleted. Short-circuit this and go
14316        directly to the LocalizedDateCache. This makes sense because we have to explicitly
14317        insert computed values back into the cache in this new model.
14318        * rendering/RenderThemeIOS.mm:
14319        (WebCore::adjustInputElementButtonStyle): Create a delegate and pass it to the
14320        LocalizedDateCache
14321
143222014-06-17  Simon Fraser  <simon.fraser@apple.com>
14323
14324        [UI-side compositing] fix reflections on composited layers
14325        https://bugs.webkit.org/show_bug.cgi?id=133942
14326
14327        Reviewed by Tim Horton.
14328
14329        Fix reflections on composited layers. There are two main set of changes.
14330        
14331        First, a PlatformCALayerRemote which is a clone has to track the layer
14332        it is a clone of, so it knows where to grab the contents from in the UI process.
14333        This layer may be told that its contents need updating out of order during
14334        recursiveBuildTransaction(), so we need some small changes in RemoteLayerTreeContext
14335        to allow a layer to add itself to the set of layers requiring commit.
14336        
14337        In the UI process, a new step is added to RemoteLayerTreeHost::updateLayerTree()
14338        to go through clones, and copy their contents from the origin layer.
14339        
14340        The second set of changes makes platformCALayerLayerDidDisplay() work for
14341        UI-side compositing by not taking a PlatformLayer*, but instead a PlatformCALayer*.
14342        PlatformCALayer::setContentsChanged() changed to copyContentsFromLayer() so we know
14343        what the origin layer is.
14344
14345        Test: compositing/reflections/repaint-with-reflection.html
14346
14347        * WebCore.exp.in:
14348        * platform/graphics/GraphicsLayer.h:
14349        (WebCore::GraphicsLayer::layerDidDisplay): Deleted.
14350        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
14351        (WebCore::LayerClient::platformCALayerLayerDidDisplay): Deleted.
14352        * platform/graphics/ca/GraphicsLayerCA.cpp:
14353        (WebCore::GraphicsLayerCA::layerDidDisplay):
14354        (WebCore::GraphicsLayerCA::findOrMakeClone):
14355        * platform/graphics/ca/GraphicsLayerCA.h:
14356        * platform/graphics/ca/PlatformCALayer.h:
14357        * platform/graphics/ca/PlatformCALayerClient.h:
14358        (WebCore::PlatformCALayerClient::platformCALayerLayerDidDisplay):
14359        * platform/graphics/ca/mac/PlatformCALayerMac.h:
14360        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
14361        (PlatformCALayerMac::copyContentsFromLayer):
14362        (PlatformCALayerMac::superlayer):
14363        (PlatformCALayerMac::setContentsChanged): Deleted.
14364        * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
14365        (PlatformCALayerWinInternal::displayCallback):
14366        * platform/graphics/mac/WebLayer.mm:
14367        (-[WebSimpleLayer display]):
14368
143692014-06-17  Anders Carlsson  <andersca@apple.com>
14370
14371        Use strongly typed enums for AnimationState and AnimationInputState
14372        https://bugs.webkit.org/show_bug.cgi?id=133988
14373
14374        Reviewed by Tim Horton.
14375
14376        * page/animation/AnimationBase.cpp:
14377        (WebCore::AnimationBase::AnimationBase):
14378        (WebCore::nameForState):
14379        (WebCore::AnimationBase::updateStateMachine):
14380        (WebCore::AnimationBase::fireAnimationEventsIfNeeded):
14381        (WebCore::AnimationBase::updatePlayState):
14382        (WebCore::AnimationBase::timeToNextService):
14383        (WebCore::AnimationBase::goIntoEndingOrLoopingState):
14384        (WebCore::AnimationBase::freezeAtTime):
14385        (WebCore::AnimationBase::beginAnimationUpdateTime):
14386        * page/animation/AnimationBase.h:
14387        (WebCore::AnimationBase::clear):
14388        (WebCore::AnimationBase::onAnimationStartResponse):
14389        (WebCore::AnimationBase::waitingToStart):
14390        (WebCore::AnimationBase::preActive):
14391        (WebCore::AnimationBase::postActive):
14392        (WebCore::AnimationBase::fillingForwards):
14393        (WebCore::AnimationBase::paused):
14394        (WebCore::AnimationBase::inPausedState):
14395        (WebCore::AnimationBase::isNew):
14396        (WebCore::AnimationBase::waitingForStartTime):
14397        (WebCore::AnimationBase::waitingForStyleAvailable):
14398        (WebCore::AnimationBase::isAnimatingProperty):
14399        (WebCore::AnimationBase::styleAvailable):
14400        (WebCore::AnimationBase::compositeAnimation):
14401        * page/animation/ImplicitAnimation.cpp:
14402        (WebCore::ImplicitAnimation::onAnimationEnd):
14403        (WebCore::ImplicitAnimation::sendTransitionEvent):
14404        (WebCore::ImplicitAnimation::reset):
14405        (WebCore::ImplicitAnimation::setOverridden):
14406        * page/animation/KeyframeAnimation.cpp:
14407        (WebCore::KeyframeAnimation::KeyframeAnimation):
14408        (WebCore::KeyframeAnimation::animate):
14409        (WebCore::KeyframeAnimation::sendAnimationEvent):
14410
144112014-06-17  Andreas Kling  <akling@apple.com>
14412
14413        Avoid synchronous layout in window.scrollTo(0,0) when already at (0,0)
14414        <https://webkit.org/b/133893>
14415
14416        Going from 0,0 to 0,0 is a no-op since there is no way a layout will
14417        affect the current scroll position.
14418
14419        We don't send scroll events when moving to the previous position,
14420        so this change is not observable.
14421
14422        Reviewed by Anders Carlsson.
14423
14424        * page/DOMWindow.cpp:
14425        (WebCore::DOMWindow::scrollTo):
14426
144272014-06-17  Alex Christensen  <achristensen@webkit.org>
14428
14429        Fix css jit register usage on armv7.
14430        https://bugs.webkit.org/show_bug.cgi?id=133952
14431
14432        Reviewed by Benjamin Poulain.
14433
14434        * cssjit/RegisterAllocator.h:
14435        List r7 as a callee saved register, which it is.
14436        * cssjit/SelectorCompiler.cpp:
14437        (WebCore::SelectorCompiler::SelectorCodeGenerator::generatePrologue):
14438        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateEpilogue):
14439        Save r6, which is used as a temporary register and must be preserved.
14440
144412014-06-17  Miyoung Shin  <myid.shin@samsung.com>
14442
14443        Use references instead of pointers to RenderBlock in enclosingBoxModelObject()
14444        https://bugs.webkit.org/show_bug.cgi?id=133978
14445
14446        Reviewed by Andreas Kling.
14447
14448        Just a straightforward conversion from pointers to references.
14449
14450        No new tests, no behavior change.
14451
14452        * rendering/InlineFlowBox.cpp:
14453        (WebCore::InlineFlowBox::paint):
14454        * rendering/RenderBlock.cpp:
14455        (WebCore::RenderBlock::paintObject):
14456        * rendering/RenderObject.cpp:
14457        (WebCore::RenderObject::enclosingBoxModelObject):
14458        * rendering/RenderObject.h:
14459
144602014-06-17  Zan Dobersek  <zdobersek@igalia.com>
14461
14462        Cache the gst_query_get_n_buffering_ranges() return value for the for-loop conditional
14463        https://bugs.webkit.org/show_bug.cgi?id=133953
14464
14465        Reviewed by Philippe Normand.
14466
14467        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
14468        (WebCore::MediaPlayerPrivateGStreamer::buffered): Avoid the extra call in the for-loop
14469        conditional expression by caching the return value of gst_query_get_n_buffering_ranges().
14470
144712014-06-17  Zan Dobersek  <zdobersek@igalia.com>
14472
14473        Avoid Vector<char> copies in the OffsetBuffer constructor
14474        https://bugs.webkit.org/show_bug.cgi?id=133956
14475
14476        Reviewed by Andreas Kling.
14477
14478        * xml/parser/XMLDocumentParserLibxml2.cpp:
14479        (WebCore::OffsetBuffer::OffsetBuffer): Take the Vector parameter by value and
14480        move it into the member variable.
14481        (WebCore::openFunc): Move the Vector object into the OffsetBuffer constructor.
14482
144832014-06-17  Jer Noble  <jer.noble@apple.com>
14484
14485        [MSE] Overwritten samples are removed from buffered ranges using decode times; added samples using presentation times
14486        https://bugs.webkit.org/show_bug.cgi?id=133959
14487
14488        Reviewed by Eric Carlson.
14489
14490        Test: media/media-source/media-source-overlapping-append-buffered.html
14491
14492        Explicitly call presentationTime() on removed samples, rather than implicitly asking for the iterator's "first"
14493        member. When iterating over samples, "first" can either be presentation time, or decode time, depending on which
14494        iteration method is called. In the case of removing samples, this was using the decode time incorrectly.
14495
14496        * Modules/mediasource/SourceBuffer.cpp:
14497        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
14498
144992014-06-16  Mihnea Ovidenie  <mihnea@adobe.com>
14500
14501        [CSSRegions] Region with border radius and overflow:hidden does not clip content
14502        https://bugs.webkit.org/show_bug.cgi?id=133476
14503
14504        Reviewed by Andrei Bucur.
14505
14506        When setting the clip before painting the named flow content,
14507        use the region's foreground rect to take the region's border radius
14508        into account if needed.
14509
14510        Test: fast/regions/region-border-radius-overflow-clip.html
14511
14512        * rendering/RenderLayer.cpp:
14513        (WebCore::RenderLayer::paintFlowThreadIfRegionForFragments):
14514
145152014-06-16  Sam Weinig  <sam@webkit.org>
14516
14517        Extract prototype declaration generation into a helper function
14518        https://bugs.webkit.org/show_bug.cgi?id=133969
14519
14520        Reviewed by Dan Bernstein.
14521
14522        * bindings/scripts/CodeGeneratorJS.pm:
14523        (GenerateHeader):
14524        (GeneratePrototypeDeclaration):
14525
145262014-06-16  Sam Weinig  <sam@webkit.org>
14527
14528        Move forward declaration of bindings static functions into their implementation files
14529        https://bugs.webkit.org/show_bug.cgi?id=133943
14530
14531        Reviewed by Geoffrey Garen.
14532
14533        - Moves the forward declaration of static functions for generated files to the implementation.
14534        - Adds a new extended attribute, ForwardDeclareInHeader, for functions that still need a 
14535          forward declaration in the header.
14536
14537        * bindings/js/JSDOMBinding.h:
14538        (WebCore::nonCachingStaticFunctionGetter):
14539        Move this helper here from JSDOMWindowCustom.cpp.
14540
14541        * bindings/js/JSDOMWindowCustom.cpp:
14542        (WebCore::JSDOMWindow::getOwnPropertySlot):
14543        Switch to comparing the property name directly rather than looking up in the static table and
14544        comparing function pointers.
14545
14546        * bindings/js/JSHistoryCustom.cpp:
14547        (WebCore::JSHistory::getOwnPropertySlotDelegate):
14548        Switch to comparing the property name directly rather than looking up in the static table and
14549        comparing function pointers and start using the nonCachingStaticFunctionGetter<> helper.
14550
14551        * bindings/js/JSLocationCustom.cpp:
14552        (WebCore::JSLocation::getOwnPropertySlotDelegate):
14553        (WebCore::JSLocation::putDelegate):
14554        Switch to comparing the property name directly rather than looking up in the static table and
14555        comparing function pointers and start using the nonCachingStaticFunctionGetter<> helper.
14556
14557        * bindings/scripts/CodeGeneratorJS.pm:
14558        (GenerateHeader):
14559        (GenerateImplementation):
14560        Move forward declaration creation to the implementation file where possible.
14561
14562        * bindings/scripts/IDLAttributes.txt:
14563        Add ForwardDeclareInHeader.
14564
14565        * page/DOMWindow.idl:
14566        * page/History.idl:
14567        * page/Location.idl:
14568        Add ForwardDeclareInHeader where necessary.
14569
145702014-06-16  Jaehun Lim  <ljaehun.lim@samsung.com>
14571
14572        Unreviewed build fix after r170029
14573
14574        Use String() instead of AtomicString().
14575
14576        * platform/network/HTTPParsers.cpp:
14577        (WebCore::parseHTTPHeader):
14578        * platform/network/soup/ResourceRequestSoup.cpp:
14579        (WebCore::ResourceRequest::updateSoupMessageHeaders):
14580        * platform/network/soup/ResourceResponseSoup.cpp:
14581        (WebCore::ResourceResponse::toSoupMessage):
14582
145832014-06-16  Brent Fulgham  <bfulgham@apple.com>
14584
14585        [Win] Use TileController on Windows
14586        https://bugs.webkit.org/show_bug.cgi?id=133895
14587
14588        Reviewed by Tim Horton.
14589
14590        * WebCore.vcxproj/WebCore.vcxproj: Add Tiled Drawing files.
14591        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
14592        * platform/graphics/TiledBacking.h: No longer Cocoa-only.
14593        * platform/graphics/ca/GraphicsLayerCA.cpp:
14594        (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer): Windows
14595        now uses the same layer type as Mac.
14596        * platform/graphics/ca/LayerPool.cpp:
14597        (WebCore::LayerPool::takeLayerWithSize): Use nullptr
14598        rather than nil for C++ code.
14599        * platform/graphics/ca/PlatformCALayer.cpp:
14600        * platform/graphics/ca/PlatformCALayer.h: Expose necessary
14601        drawing functions for Windows port.
14602        * platform/graphics/ca/TileController.cpp: Remove unneeded
14603        header include for WebLayer.
14604        * platform/graphics/ca/TileCoverageMap.cpp: Correct #includes.
14605        * platform/graphics/ca/TileGrid.h: Not just for Cococa.
14606        * platform/graphics/ca/mac/PlatformCALayerMac.mm: Remove
14607        extra whitespace.
14608        * platform/graphics/ca/mac/PlatformCALayerMac.h: Remove
14609        unneeded overload.
14610        * platform/graphics/ca/win/PlatformCALayerWin.cpp:
14611        (PlatformCALayer::collectRectsToPaint): Added stub.
14612        (PlatformCALayer::drawLayerContents): Added.
14613        (PlatformCALayer::frameForLayer): Added.
14614        (PlatformCALayerWin::PlatformCALayerWin): Remove unneeded
14615        assert now that we support these types. Add TileController
14616        support.
14617        (PlatformCALayerWin::setEdgeAntialiasingMask): Added.
14618        (printLayer): Add newly-supported tile types.
14619        (PlatformCALayerWin::tiledBacking): Added.
14620        * platform/graphics/ca/win/PlatformCALayerWin.h: Update to
14621        support Tiled Drawing.
14622        * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
14623        (PlatformCALayerWinInternal::PlatformCALayerWinInternal): Update to
14624        recognize newly-supported layer types.
14625        (PlatformCALayerWinInternal::setNeedsDisplay): Ditto.
14626        (PlatformCALayerWinInternal::setSublayers): Ditto.
14627        (PlatformCALayerWinInternal::getSublayers): Ditto.
14628        (PlatformCALayerWinInternal::removeAllSublayers): Ditto.
14629        (PlatformCALayerWinInternal::insertSublayer): Ditto.
14630        (PlatformCALayerWinInternal::sublayerCount): Ditto.
14631        (PlatformCALayerWinInternal::indexOfSublayer): Ditto.
14632        (PlatformCALayerWinInternal::sublayerAtIndex): Ditto.
14633        (PlatformCALayerWinInternal::setBounds): Ditto.
14634        (PlatformCALayerWinInternal::setFrame): Ditto.
14635        (PlatformCALayerWinInternal::drawTile): Ditto.
14636        (PlatformCALayerWinInternal::createTileController): Ditto.
14637        (PlatformCALayerWinInternal::tiledBacking): Ditto.
14638        * platform/graphics/ca/win/PlatformCALayerWinInternal.h: Update to use
14639        TileController.
14640
146412014-06-16  Andreas Kling  <akling@apple.com>
14642
14643        Remove unnecessary style invalidation in RenderTextControl::styleDidChange().
14644        <https://webkit.org/b/133949>
14645
14646        This explicit invalidation of the text control's inner text element
14647        was hacked in to fix an editing test back in 2011, long before lazy
14648        render tree construction.
14649
14650        It should be safe to remove, since doing so doesn't affect any tests.
14651
14652        Reviewed by Antti Koivisto.
14653
14654        * rendering/RenderTextControl.cpp:
14655        (WebCore::RenderTextControl::styleDidChange):
14656
146572014-06-16  Anders Carlsson  <andersca@apple.com>
14658
14659        Fix iOS build.
14660
14661        * platform/network/cf/ResourceRequestCFNet.cpp:
14662        (WebCore::setHeaderFields):
14663
146642014-06-16  Anders Carlsson  <andersca@apple.com>
14665
14666        Accept-Ranges is not specific to GStreamer.
14667
14668        * platform/network/HTTPHeaderNames.in:
14669
146702014-06-16  Anders Carlsson  <andersca@apple.com>
14671
14672        Don't use AtomicString in HTTPHeaderMap
14673        https://bugs.webkit.org/show_bug.cgi?id=133957
14674        <rdar://problem/15256572>
14675
14676        Reviewed by Andreas Kling.
14677
14678        Use the string data that comes from the generated HTTPHeaderNames.cpp file
14679        for sharing header name data instead. In the future we can do something more fancy where
14680        we'll hash the HTTPHeaderName enum directly, but this is good enough for now.
14681
14682        * Modules/websockets/WebSocketHandshake.cpp:
14683        (WebCore::WebSocketHandshake::readHTTPHeaders):
14684        * WebCore.exp.in:
14685        * inspector/InspectorResourceAgent.cpp:
14686        (WebCore::buildObjectForHeaders):
14687        * loader/CrossOriginPreflightResultCache.cpp:
14688        (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders):
14689        * loader/appcache/ApplicationCacheStorage.cpp:
14690        (WebCore::parseHeader):
14691        * loader/cache/CachedResource.cpp:
14692        (WebCore::shouldUpdateHeaderAfterRevalidation):
14693        * platform/network/HTTPHeaderMap.cpp:
14694        (WebCore::HTTPHeaderMap::copyData):
14695        (WebCore::internHTTPHeaderNameString):
14696        (WebCore::HTTPHeaderMap::get):
14697        (WebCore::HTTPHeaderMap::set):
14698        (WebCore::HTTPHeaderMap::add):
14699        (WebCore::CaseFoldingCStringTranslator::hash): Deleted.
14700        (WebCore::CaseFoldingCStringTranslator::equal): Deleted.
14701        (WebCore::CaseFoldingCStringTranslator::translate): Deleted.
14702        * platform/network/HTTPHeaderMap.h:
14703        * platform/network/HTTPHeaderNames.in:
14704        * platform/network/HTTPParsers.cpp:
14705        (WebCore::parseHTTPHeader):
14706        * platform/network/HTTPParsers.h:
14707        * platform/network/ResourceRequestBase.cpp:
14708        (WebCore::ResourceRequestBase::httpHeaderField):
14709        (WebCore::ResourceRequestBase::setHTTPHeaderField):
14710        (WebCore::ResourceRequestBase::addHTTPHeaderField):
14711        * platform/network/ResourceRequestBase.h:
14712        * platform/network/ResourceResponseBase.cpp:
14713        (WebCore::ResourceResponseBase::httpHeaderField):
14714        (WebCore::ResourceResponseBase::setHTTPHeaderField):
14715        (WebCore::ResourceResponseBase::addHTTPHeaderField):
14716        * platform/network/ResourceResponseBase.h:
14717        * platform/network/mac/ResourceRequestMac.mm:
14718        (WebCore::ResourceRequest::doUpdateResourceRequest):
14719        * platform/network/mac/ResourceResponseMac.mm:
14720        (WebCore::ResourceResponse::platformLazyInit):
14721        * xml/XMLHttpRequest.cpp:
14722        (WebCore::XMLHttpRequest::setRequestHeader):
14723        (WebCore::XMLHttpRequest::setRequestHeaderInternal):
14724        (WebCore::XMLHttpRequest::getRequestHeader):
14725        (WebCore::XMLHttpRequest::getResponseHeader):
14726        * xml/XMLHttpRequest.h:
14727
147282014-06-16  Chris Fleizach  <cfleizach@apple.com>
14729
14730        AX: Safari crashed once in WebCore::AccessibilityObject::ariaIsHidden
14731        https://bugs.webkit.org/show_bug.cgi?id=133825
14732
14733        Reviewed by Enrica Casucci.
14734
14735        Sometimes asking accessibilityIsIgnored() will cause a newObject to be detached immediately after its created. 
14736        The creation function holds a reference with RefPtr as long as it lives, but when that method returns, the object goes away.
14737
14738        With that out of the way, I saw the same backtrace lead to updateLayoutIgnorePendingStylesheets being called while still inLayout.
14739
14740        I tried my best but could not create a reproducible layout test.
14741
14742        * accessibility/AXObjectCache.cpp:
14743        (WebCore::AXObjectCache::getOrCreate):
14744        * accessibility/AccessibilityObject.cpp:
14745        (WebCore::AccessibilityObject::updateBackingStore):
14746
147472014-06-16  Zan Dobersek  <zdobersek@igalia.com>
14748
14749        Unreviewed. Add more GStreamer-specific header names that are required
14750        after changes in r170021, fixing the build for ports using GStreamer.
14751
14752        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
14753        (StreamingClient::handleResponseReceived):
14754        * platform/network/HTTPHeaderNames.in:
14755
147562014-06-16  Chris Fleizach  <cfleizach@apple.com>
14757
14758        AX: Crash at WebCore::AXObjectCache::textChanged
14759        https://bugs.webkit.org/show_bug.cgi?id=133873
14760
14761        Reviewed by Enrica Casucci.
14762
14763        This looks like a very similar problem to 
14764        https://bugs.webkit.org/show_bug.cgi?id=133825
14765
14766        The object is being created and deallocated almost right away because calling accessibilityIsIgnored triggers
14767        a deferred layout that invalidates the associated render element.
14768
14769        Despite my best efforts, I could not come up with a way to reproduce this in a layout test.
14770
14771        * accessibility/AXObjectCache.cpp:
14772        (WebCore::AXObjectCache::getOrCreate):
14773
147742014-06-15  Anders Carlsson  <andersca@apple.com>
14775
14776        Change ResourceRequestBase::addHTTPHeaderFields to setHTTPHeaderFields instead
14777        https://bugs.webkit.org/show_bug.cgi?id=133925
14778
14779        Reviewed by Sam Weinig.
14780
14781        * WebCore.exp.in:
14782        * platform/network/ResourceRequestBase.cpp:
14783        (WebCore::ResourceRequestBase::setHTTPHeaderFields):
14784        (WebCore::ResourceRequestBase::addHTTPHeaderFields): Deleted.
14785        * platform/network/ResourceRequestBase.h:
14786        * plugins/PluginView.cpp:
14787        (WebCore::PluginView::handlePost):
14788        * xml/XMLHttpRequest.cpp:
14789        (WebCore::XMLHttpRequest::createRequest):
14790
147912014-06-16  Jeongeun Kim  <je_julie.kim@samsung.com>
14792
14793        Use references instead of pointers to RenderBlock in RenderObject::enclosingBox().
14794        https://bugs.webkit.org/show_bug.cgi?id=133902
14795
14796        Reviewed by Andreas Kling.
14797
14798        Just a straightforward conversion from pointers to references.
14799
14800        No new tests, no behavior change.
14801
14802        * bindings/objc/DOMUIKitExtensions.mm:
14803        (-[DOMHTMLElement structuralComplexityContribution]):
14804        * html/HTMLMediaElement.cpp:
14805        (WebCore::HTMLMediaElement::parseAttribute):
14806        * inspector/InspectorOverlay.cpp:
14807        (WebCore::buildObjectForRendererFragments):
14808        * page/EventHandler.cpp:
14809        (WebCore::scrollNode):
14810        (WebCore::EventHandler::scrollOverflow):
14811        (WebCore::EventHandler::logicalScrollOverflow):
14812        * page/FrameView.cpp:
14813        (WebCore::FrameView::layout):
14814        * rendering/RenderBox.cpp:
14815        (WebCore::computeInlineStaticDistance):
14816        * rendering/RenderFlowThread.cpp:
14817        (WebCore::RenderFlowThread::computedRegionRangeForBox):
14818        (WebCore::RenderFlowThread::objectShouldFragmentInFlowRegion):
14819        (WebCore::RenderFlowThread::objectInFlowRegion):
14820        * rendering/RenderLayer.cpp:
14821        (WebCore::RenderLayer::calculateClipRects):
14822        * rendering/RenderObject.cpp:
14823        (WebCore::RenderObject::enclosingBox): Removed FIXME comment
14824        * rendering/RenderObject.h:
14825        * rendering/RenderScrollbar.cpp:
14826        (WebCore::RenderScrollbar::owningRenderer):
14827
148282014-06-16  Anders Carlsson  <andersca@apple.com>
14829
14830        Use HTTPHeaderName in more places
14831        https://bugs.webkit.org/show_bug.cgi?id=133948
14832
14833        Reviewed by Andreas Kling.
14834
14835        * loader/cache/CachedRawResource.cpp:
14836        (WebCore::shouldIgnoreHeaderForCacheReuse):
14837        * platform/network/HTTPHeaderNames.in:
14838        * xml/XMLHttpRequest.cpp:
14839        (WebCore::isSetCookieHeader):
14840        (WebCore::isForbiddenRequestHeader):
14841        (WebCore::XMLHttpRequest::isAllowedHTTPHeader):
14842        (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData): Deleted.
14843        (WebCore::staticData): Deleted.
14844
148452014-06-16  Anders Carlsson  <andersca@apple.com>
14846
14847        Add HTTPHeaderName overloads on ResourceResponseBase
14848        https://bugs.webkit.org/show_bug.cgi?id=133946
14849
14850        Reviewed by Andreas Kling.
14851
14852        * WebCore.exp.in:
14853        * dom/Document.cpp:
14854        (WebCore::Document::lastModified):
14855        * loader/CrossOriginAccessControl.cpp:
14856        (WebCore::passesAccessControlCheck):
14857        * loader/CrossOriginPreflightResultCache.cpp:
14858        (WebCore::CrossOriginPreflightResultCacheItem::parse):
14859        * loader/FrameLoader.cpp:
14860        (WebCore::FrameLoader::receivedFirstData):
14861        (WebCore::FrameLoader::didBeginDocument):
14862        * loader/appcache/ApplicationCacheGroup.cpp:
14863        (WebCore::ApplicationCacheGroup::createResourceHandle):
14864        * loader/cache/CachedCSSStyleSheet.cpp:
14865        (WebCore::CachedCSSStyleSheet::canUseSheet):
14866        * loader/cache/CachedResource.cpp:
14867        (WebCore::CachedResource::load):
14868        * loader/cache/CachedScript.cpp:
14869        (WebCore::CachedScript::mimeType):
14870        * platform/network/HTTPHeaderNames.in:
14871        * platform/network/ResourceResponseBase.cpp:
14872        (WebCore::ResourceResponseBase::httpHeaderField):
14873        (WebCore::ResourceResponseBase::setHTTPHeaderField):
14874        * platform/network/ResourceResponseBase.h:
14875        * xml/XMLHttpRequest.cpp:
14876        (WebCore::XMLHttpRequest::getAllResponseHeaders):
14877        (WebCore::XMLHttpRequest::getResponseHeader):
14878        (WebCore::XMLHttpRequest::responseMIMEType):
14879        (WebCore::XMLHttpRequest::didReceiveResponse):
14880
148812014-04-05  Antonio Gomes  <a1.gomes@sisa.samsung.com>
14882
14883        [Bindings] "nullable" sequence support is incomplete (i.e. sequence<NativeType>?)
14884        https://bugs.webkit.org/show_bug.cgi?id=131240
14885
14886        Reviewed by Darin Adler.
14887
14888        Nullable sequences are not fully supported in WebKit's
14889        code generator machinery. Although the generated code
14890        does add "is nullable" check to the evaluation condition
14891        (i.e. if (arg.isNull() || ...)), when the JSValue
14892        that holds a "null" JSObject is actually to be "converted"
14893        to a native Vector<T>, it fails.
14894
14895        The reason for the failure is in JSDOMBindings::toNativeArray.
14896        This method verifies that JSValue does not hold a "non-null"
14897        object, and it bails out.
14898        Analogly, the "ref ptr" variant of this method (toRefPtrNativeArray)
14899        does support nullables.
14900
14901        Patch fixes it be checking for a "null" JSValue check before hand.
14902
14903        Tests: Binding tests updated.
14904
14905        * bindings/js/JSDOMBinding.h:
14906        (WebCore::toNativeArray):
14907        * bindings/scripts/CodeGeneratorJS.pm:
14908        (JSValueToNative):
14909        * Modules/websocket/WebSocket.idl:
14910        Removed one overload ctor now that
14911        we can use nullable sequences.
14912
149132014-06-16  Jer Noble  <jer.noble@apple.com>
14914
14915        [MSE][Mac] Occasional image corruption after seeking
14916        https://bugs.webkit.org/show_bug.cgi?id=133879
14917
14918        Reviewed by Eric Carlson.
14919
14920        Change the order of operations for seeks: change the current time of the AVSampleBufferRenderSynchronizer
14921        before flushing and appending non-displaying samples.
14922
14923        Rather than having a single function which retrieves the fast seek time and then seeks, split this out
14924        into two functions: one which gets the fast seek time, and one which seeks. (The later of course already
14925        exists: seekToTime()).
14926
14927        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
14928        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC):
14929        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
14930        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
14931        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
14932        (WebCore::MediaSourcePrivateAVFObjC::fastSeekTimeForMediaTime): Renamed from seekToTime()
14933        (WebCore::MediaSourcePrivateAVFObjC::seekToTime): Deleted.
14934
149352014-06-16  Zan Dobersek  <zdobersek@igalia.com>
14936
14937        Have ScriptExecutionContext::Task functions take in a ScriptExecutionContext reference
14938        https://bugs.webkit.org/show_bug.cgi?id=133795
14939
14940        Reviewed by Andreas Kling.
14941
14942        The pointer to the ScriptExecutionContext object that is passed to the C++11 lambdas or
14943        helper functions wrapped in ScriptExecutionContext::Task is never null, so that parameter
14944        should be a reference instead.
14945
14946        * Modules/webdatabase/Database.cpp:
14947        (WebCore::Database::~Database):
14948        (WebCore::Database::runTransaction):
14949        (WebCore::Database::scheduleTransactionCallback):
14950        * Modules/webdatabase/DatabaseManager.cpp:
14951        (WebCore::DatabaseManager::openDatabase):
14952        * Modules/webdatabase/SQLCallbackWrapper.h:
14953        (WebCore::SQLCallbackWrapper::clear):
14954        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
14955        (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasksCallback):
14956        (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks): Dereference the
14957        member variable that holds a never-null pointer to the ScriptExecutionContext. This should
14958        similarly be a reference.
14959        (WebCore::ThreadableWebSocketChannelClientWrapper::didConnectCallback):
14960        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageCallback):
14961        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryDataCallback):
14962        (WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmountCallback):
14963        (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshakeCallback):
14964        (WebCore::ThreadableWebSocketChannelClientWrapper::didCloseCallback):
14965        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageErrorCallback):
14966        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
14967        * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
14968        (WebCore::workerGlobalScopeDidSend):
14969        (WebCore::workerGlobalScopeDidGetBufferedAmount):
14970        (WebCore::workerGlobalScopeDidConnect):
14971        (WebCore::workerGlobalScopeDidReceiveMessage):
14972        (WebCore::workerGlobalScopeDidReceiveBinaryData):
14973        (WebCore::workerGlobalScopeDidUpdateBufferedAmount):
14974        (WebCore::workerGlobalScopeDidStartClosingHandshake):
14975        (WebCore::workerGlobalScopeDidClose):
14976        (WebCore::workerGlobalScopeDidReceiveMessageError):
14977        (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadInitialize):
14978        (WebCore::WorkerThreadableWebSocketChannel::mainThreadConnect):
14979        (WebCore::WorkerThreadableWebSocketChannel::mainThreadSend):
14980        (WebCore::WorkerThreadableWebSocketChannel::mainThreadSendArrayBuffer):
14981        (WebCore::WorkerThreadableWebSocketChannel::mainThreadSendBlob):
14982        (WebCore::WorkerThreadableWebSocketChannel::mainThreadBufferedAmount):
14983        (WebCore::WorkerThreadableWebSocketChannel::mainThreadClose):
14984        (WebCore::WorkerThreadableWebSocketChannel::mainThreadFail):
14985        (WebCore::WorkerThreadableWebSocketChannel::mainThreadDestroy):
14986        (WebCore::WorkerThreadableWebSocketChannel::mainThreadSuspend):
14987        (WebCore::WorkerThreadableWebSocketChannel::mainThreadResume):
14988        * Modules/websockets/WorkerThreadableWebSocketChannel.h:
14989        * bindings/js/JSCallbackData.h:
14990        (WebCore::DeleteCallbackDataTask::DeleteCallbackDataTask):
14991        * bindings/js/JSDOMGlobalObjectTask.cpp:
14992        (WebCore::JSGlobalObjectTask::JSGlobalObjectTask):
14993        * dom/Document.cpp:
14994        (WebCore::Document::postTask):
14995        (WebCore::Document::pendingTasksTimerFired):
14996        * dom/ScriptExecutionContext.cpp:
14997        (WebCore::ScriptExecutionContext::processMessagePortMessagesSoon):
14998        * dom/ScriptExecutionContext.h:
14999        (WebCore::ScriptExecutionContext::Task::performTask):
15000        (WebCore::ScriptExecutionContext::AddConsoleMessageTask::AddConsoleMessageTask):
15001        * dom/StringCallback.cpp:
15002        (WebCore::StringCallback::scheduleCallback):
15003        * fileapi/FileReader.cpp:
15004        (WebCore::delayedAbort):
15005        (WebCore::FileReader::abort):
15006        (WebCore::FileReader::doAbort): Deleted.
15007        * loader/WorkerThreadableLoader.cpp:
15008        (WebCore::WorkerThreadableLoader::MainThreadBridge::mainThreadCreateLoader):
15009        (WebCore::WorkerThreadableLoader::MainThreadBridge::mainThreadDestroy):
15010        (WebCore::WorkerThreadableLoader::MainThreadBridge::mainThreadCancel):
15011        (WebCore::workerGlobalScopeDidSendData):
15012        (WebCore::workerGlobalScopeDidReceiveResponse):
15013        (WebCore::workerGlobalScopeDidReceiveData):
15014        (WebCore::workerGlobalScopeDidFinishLoading):
15015        (WebCore::workerGlobalScopeDidFail):
15016        (WebCore::workerGlobalScopeDidFailAccessControlCheck):
15017        (WebCore::workerGlobalScopeDidFailRedirectCheck):
15018        * loader/WorkerThreadableLoader.h:
15019        * loader/appcache/ApplicationCacheGroup.cpp:
15020        (WebCore::ApplicationCacheGroup::postListenerTask):
15021        * loader/cache/MemoryCache.cpp:
15022        (WebCore::MemoryCache::crossThreadRemoveRequestFromCache):
15023        (WebCore::MemoryCache::crossThreadRemoveRequestFromSessionCaches):
15024        * loader/cache/MemoryCache.h:
15025        * workers/DefaultSharedWorkerRepository.cpp:
15026        (WebCore::SharedWorkerProxy::postExceptionToWorkerObject):
15027        (WebCore::SharedWorkerProxy::postConsoleMessageToWorkerObject):
15028        (WebCore::SharedWorkerConnectTask::SharedWorkerConnectTask):
15029        * workers/WorkerEventQueue.cpp:
15030        (WebCore::WorkerEventQueue::enqueueEvent):
15031        * workers/WorkerGlobalScope.cpp:
15032        (WebCore::WorkerGlobalScope::close):
15033        * workers/WorkerMessagingProxy.cpp:
15034        (WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
15035        (WebCore::WorkerMessagingProxy::postMessageToWorkerGlobalScope):
15036        (WebCore::WorkerMessagingProxy::postExceptionToWorkerObject):
15037        (WebCore::WorkerMessagingProxy::postConsoleMessageToWorkerObject):
15038        (WebCore::WorkerMessagingProxy::workerObjectDestroyed):
15039        (WebCore::WorkerMessagingProxy::notifyNetworkStateChange):
15040        (WebCore::WorkerMessagingProxy::connectToInspector):
15041        (WebCore::WorkerMessagingProxy::disconnectFromInspector):
15042        (WebCore::WorkerMessagingProxy::sendMessageToInspector):
15043        (WebCore::WorkerMessagingProxy::workerGlobalScopeDestroyed):
15044        (WebCore::WorkerMessagingProxy::workerGlobalScopeClosed):
15045        (WebCore::WorkerMessagingProxy::postMessageToPageInspector):
15046        (WebCore::WorkerMessagingProxy::confirmMessageFromWorkerObject):
15047        (WebCore::WorkerMessagingProxy::reportPendingActivity):
15048        * workers/WorkerRunLoop.cpp:
15049        (WebCore::WorkerRunLoop::Task::performTask):
15050        * workers/WorkerScriptLoader.cpp:
15051        * workers/WorkerThread.cpp:
15052        (WebCore::WorkerThread::stop):
15053        (WebCore::WorkerThread::releaseFastMallocFreeMemoryInAllThreads):
15054
150552014-06-16  Zan Dobersek  <zdobersek@igalia.com>
15056
15057        Page::findStringMatchingRanges() should take Vector<RefPtr<Range>> by reference instead of pointer
15058        https://bugs.webkit.org/show_bug.cgi?id=133677
15059
15060        Reviewed by Anders Carlsson.
15061
15062        * WebCore.exp.in: Update the changed symbol.
15063        * page/Page.cpp:
15064        (WebCore::Page::findStringMatchingRanges): The method expects the matchRanges parameter to be non-null,
15065        so it should take in that parameter by reference instead of pointer.
15066        * page/Page.h:
15067
150682014-06-16  Radu Stavila  <stavila@adobe.com>
15069
15070        REGRESSION (r168046): Incorrect layout for multicol spanners when moving from one thread to another
15071        https://bugs.webkit.org/show_bug.cgi?id=133589
15072
15073        Reviewed by Antti Koivisto.
15074
15075        When a spanner is moved from a multicol thread to another, its placeholder
15076        must be properly repositioned.
15077
15078        Test: fast/multicol/newmulticol/spanner-crash.html
15079
15080        * rendering/RenderMultiColumnFlowThread.cpp:
15081        (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantInserted):
15082
150832014-06-16  Mario Sanchez Prada  <mario.prada@samsung.com>
15084
15085        [ATK] Missing 'selection-changed' signal when navigating a combo box with keyboard
15086        https://bugs.webkit.org/show_bug.cgi?id=133512
15087
15088        Reviewed by Chris Fleizach.
15089
15090        Make sure that AccessibilityMenuList objects update their active
15091        option when it changes, which will send a platform-dependent
15092        accessibility-related notification when needed.
15093
15094        Test: accessibility/combo-box-collapsed-selection-changed.html
15095
15096        * rendering/RenderMenuList.cpp:
15097        (RenderMenuList::didUpdateActiveOption): Keep the out-of-bounds
15098        check for the index passed but don't avoid updating the option for
15099        the associated AccessibilityMenuList object if the selected list
15100        item does not have a renderer, because that could be the case for
15101        cases where the popup (and its elements) would be rendered in the
15102        UI Process (e.g. GTK+ port uses GtkMenu and GtkMenuItem for that).
15103
15104        * accessibility/AccessibilityMenuList.cpp:
15105        (WebCore::AccessibilityMenuList::didUpdateActiveOption): Ensure
15106        that the AccessibilityMenuListPopup object for a given menu list
15107        has accessibility children before updating its active option.
15108
151092014-06-16  Commit Queue  <commit-queue@webkit.org>
15110
15111        Unreviewed, rolling out r170003.
15112        https://bugs.webkit.org/show_bug.cgi?id=133938
15113
15114        This patch broke GTK build (Requested by kczech on #webkit).
15115
15116        Reverted changeset:
15117
15118        "[EFL] Platform support for WebSpeech feature."
15119        https://bugs.webkit.org/show_bug.cgi?id=116438
15120        http://trac.webkit.org/changeset/170003
15121
151222014-06-16  Frédéric Wang  <fred.wang@free.fr>
15123
15124        Draw radicals with glyphs for better rendering.
15125        https://bugs.webkit.org/show_bug.cgi?id=119038
15126
15127        Unreviewed ASSERT fix.
15128
15129        * rendering/mathml/RenderMathMLRoot.h:
15130
151312014-06-16  Frédéric Wang  <fred.wang@free.fr>
15132
15133        Draw radicals with glyphs for better rendering
15134        https://bugs.webkit.org/show_bug.cgi?id=119038
15135
15136        Reviewed by Chris Fleizach.
15137
15138        We rewrite RenderMathMLRoot in order to fix bugs with SVG transforms and dynamic modification of children and allow drawing with an OpenType MATH table.
15139        The drawing of the radical sign (without the top bar) is now moved to a RenderMathMLRadicalOperator class inheriting from RenderMathMLOperator.
15140        This class fallbacks to the original drawing with graphic primitives if an OpenType MATH table is not available.
15141
15142        Tests: mathml/opentype/roots-LatinModern.html
15143               mathml/presentation/mroot-transform.html
15144
15145        * CMakeLists.txt: add files to build system.
15146        * WebCore.vcxproj/WebCore.vcxproj: ditto.
15147        * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
15148        * WebCore.xcodeproj/project.pbxproj: ditto
15149        * css/mathml.css: remove rules for msqrt/mroot. The "script level" in mroot is not incremented by 2 as specified in the spec.
15150        (math, mrow, mfenced, merror, mphantom, mstyle, menclose):
15151        (mroot > *:last-child):
15152        (math, mrow, mfenced, msqrt, mroot, merror, mphantom, mstyle, menclose): Deleted.
15153        (msqrt > *): Deleted.
15154        (mroot): Deleted. This rule was causing bug 126516.
15155        (mroot > * + *): Deleted.
15156        * rendering/RenderObject.h: Add two new isRenderMathML* functions for dynamic casting.
15157        (WebCore::RenderObject::isRenderMathMLRadicalOperator):
15158        (WebCore::RenderObject::isRenderMathMLRootWrapper):
15159        * rendering/mathml/RenderMathMLOperator.cpp: Accept a set of operator dictionary flags, all disabled by default. This is to allow anonymous radicas, which don't have any flag.
15160        isFencedOperator() is now replaced with the more general isAnonymous() since we allow anonymous radical operator fors msqrt/mroot.
15161        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
15162        (WebCore::RenderMathMLOperator::setOperatorFlagFromAttribute):
15163        (WebCore::RenderMathMLOperator::setOperatorPropertiesFromOpDictEntry):
15164        (WebCore::RenderMathMLOperator::SetOperatorProperties):
15165        (WebCore::RenderMathMLOperator::updateTokenContent):
15166        * rendering/mathml/RenderMathMLOperator.h: Allow class to be overriden, redefine the anonymous constructor, remove isFencedOperator().
15167        * rendering/mathml/RenderMathMLRadicalOperator.cpp: Added.
15168        (WebCore::RenderMathMLRadicalOperator::RenderMathMLRadicalOperator):
15169        (WebCore::RenderMathMLRadicalOperator::stretchTo):
15170        (WebCore::RenderMathMLRadicalOperator::SetOperatorProperties):
15171        (WebCore::RenderMathMLRadicalOperator::computePreferredLogicalWidths):
15172        (WebCore::RenderMathMLRadicalOperator::computeLogicalHeight):
15173        (WebCore::RenderMathMLRadicalOperator::paint):
15174        (WebCore::RenderMathMLRadicalOperator::trailingSpaceError):
15175        * rendering/mathml/RenderMathMLRadicalOperator.h: Added.
15176        * rendering/mathml/RenderMathMLRoot.cpp: Rewritten. Some parts to use graphic primitives are moved to RenderMathMLRadicalOperator.cpp.
15177        (WebCore::RenderMathMLRoot::RenderMathMLRoot):
15178        (WebCore::RenderMathMLRoot::baseWrapper):
15179        (WebCore::RenderMathMLRoot::radicalWrapper):
15180        (WebCore::RenderMathMLRoot::indexWrapper):
15181        (WebCore::RenderMathMLRoot::radicalOperator):
15182        (WebCore::RenderMathMLRoot::restructureWrappers):
15183        (WebCore::RenderMathMLRoot::addChild):
15184        (WebCore::RenderMathMLRoot::styleDidChange):
15185        (WebCore::RenderMathMLRoot::updateFromElement):
15186        (WebCore::RenderMathMLRoot::updateStyle):
15187        (WebCore::RenderMathMLRoot::firstLineBaseline):
15188        (WebCore::RenderMathMLRoot::layout):
15189        (WebCore::RenderMathMLRoot::paint):
15190        (WebCore::RenderMathMLRootWrapper::createAnonymousWrapper):
15191        (WebCore::RenderMathMLRootWrapper::removeChildWithoutRestructuring):
15192        (WebCore::RenderMathMLRootWrapper::removeChild):
15193        (WebCore::RenderMathMLRoot::paddingTop): Deleted.
15194        (WebCore::RenderMathMLRoot::paddingBottom): Deleted.
15195        (WebCore::RenderMathMLRoot::paddingLeft): Deleted.
15196        (WebCore::RenderMathMLRoot::paddingRight): Deleted.
15197        (WebCore::RenderMathMLRoot::paddingBefore): Deleted.
15198        (WebCore::RenderMathMLRoot::paddingAfter): Deleted.
15199        (WebCore::RenderMathMLRoot::paddingStart): Deleted.
15200        (WebCore::RenderMathMLRoot::paddingEnd): Deleted.
15201        (WebCore::RenderMathMLRoot::index): Deleted.
15202        * rendering/mathml/RenderMathMLRoot.h: Rewritten.
15203        (WebCore::RenderMathMLRootWrapper::RenderMathMLRootWrapper):
15204
152052014-06-16  Krzysztof Czech  <k.czech@samsung.com>
15206
15207        [EFL] Platform support for WebSpeech feature.
15208        https://bugs.webkit.org/show_bug.cgi?id=116438
15209
15210        Reviewed by Gyuyoung Kim.
15211
15212        It's a first step of adding support for Speech Synthesis in EFL port.
15213        Just stub out required API and support for compilation.
15214
15215        * CMakeLists.txt:
15216        * PlatformEfl.cmake:
15217        * platform/PlatformSpeechSynthesizer.h:
15218        * platform/efl/PlatformSpeechSynthesisProviderEfl.cpp: Added.
15219        (WebCore::PlatformSpeechSynthesisProviderEfl::PlatformSpeechSynthesisProviderEfl):
15220        (WebCore::PlatformSpeechSynthesisProviderEfl::~PlatformSpeechSynthesisProviderEfl):
15221        (WebCore::PlatformSpeechSynthesisProviderEfl::initializeVoiceList):
15222        (WebCore::PlatformSpeechSynthesisProviderEfl::pause):
15223        (WebCore::PlatformSpeechSynthesisProviderEfl::resume):
15224        (WebCore::PlatformSpeechSynthesisProviderEfl::speak):
15225        (WebCore::PlatformSpeechSynthesisProviderEfl::cancel):
15226        * platform/efl/PlatformSpeechSynthesisProviderEfl.h: Added.
15227        * platform/efl/PlatformSpeechSynthesizerEfl.cpp: Added.
15228        (WebCore::PlatformSpeechSynthesizer::PlatformSpeechSynthesizer):
15229        (WebCore::PlatformSpeechSynthesizer::~PlatformSpeechSynthesizer):
15230        (WebCore::PlatformSpeechSynthesizer::initializeVoiceList):
15231        (WebCore::PlatformSpeechSynthesizer::pause):
15232        (WebCore::PlatformSpeechSynthesizer::resume):
15233        (WebCore::PlatformSpeechSynthesizer::speak):
15234        (WebCore::PlatformSpeechSynthesizer::cancel):
15235
152362014-06-15  Benjamin Poulain  <benjamin@webkit.org>
15237
15238        CSS JIT: add support for the :lang() pseudo class
15239        https://bugs.webkit.org/show_bug.cgi?id=133913
15240
15241        Reviewed by Andreas Kling.
15242
15243        The selector is already very expensive to begin with, just implement it with
15244        a function call.
15245
15246        It is also done after every other filter since it is so inefficient.
15247
15248        Tests: fast/selectors/lang-conflict.html
15249               fast/selectors/lang-empty.html
15250               fast/selectors/lang-specificity-xml.xhtml
15251               fast/selectors/lang-specificity.html
15252
15253        * css/SelectorChecker.cpp:
15254        (WebCore::SelectorChecker::checkOne):
15255        * css/SelectorCheckerTestFunctions.h:
15256        (WebCore::matchesLangPseudoClass):
15257        * cssjit/SelectorCompiler.cpp:
15258        (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
15259        (WebCore::SelectorCompiler::addPseudoClassType):
15260        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
15261        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsInLanguage):
15262        * dom/Element.cpp:
15263        (WebCore::Element::computeInheritedLanguage):
15264        * dom/ElementData.cpp:
15265        (WebCore::ElementData::findLanguageAttribute):
15266        * dom/ElementData.h:
15267
152682014-06-15  Anders Carlsson  <andersca@apple.com>
15269
15270        Add an autorelease() member function to RetainPtr
15271        https://bugs.webkit.org/show_bug.cgi?id=133929
15272
15273        Reviewed by Dan Bernstein.
15274
15275        * bindings/objc/DOM.mm:
15276        (-[DOMNode renderedImage]):
15277        (-[DOMRange renderedImageForcingBlackText:renderedImageForcingBlackText:]):
15278        * bindings/objc/DOMUIKitExtensions.mm:
15279        (-[DOMHTMLImageElement dataRepresentation:]):
15280        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
15281        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:willSendRequest:redirectResponse:]):
15282        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:willCacheResponse:]):
15283
152842014-06-14  Anders Carlsson  <andersca@apple.com>
15285
15286        Adopt HTTPHeaderName in ResourceResponseBase
15287        https://bugs.webkit.org/show_bug.cgi?id=133919
15288
15289        Reviewed by Sam Weinig.
15290
15291        * platform/network/HTTPHeaderNames.in:
15292        * platform/network/ResourceResponseBase.cpp:
15293        (WebCore::ResourceResponseBase::updateHeaderParsedState):
15294        (WebCore::ResourceResponseBase::setHTTPHeaderField):
15295        (WebCore::ResourceResponseBase::addHTTPHeaderField):
15296        (WebCore::ResourceResponseBase::parseCacheControlDirectives):
15297        (WebCore::ResourceResponseBase::hasCacheValidatorFields):
15298        (WebCore::parseDateValueInHeader):
15299        (WebCore::ResourceResponseBase::date):
15300        (WebCore::ResourceResponseBase::age):
15301        (WebCore::ResourceResponseBase::expires):
15302        (WebCore::ResourceResponseBase::lastModified):
15303        (WebCore::ResourceResponseBase::isAttachment):
15304        * platform/network/ResourceResponseBase.h:
15305
153062014-06-14  Anders Carlsson  <andersca@apple.com>
15307
15308        Simplify ResourceRequest constructors
15309        https://bugs.webkit.org/show_bug.cgi?id=133911
15310
15311        Reviewed by Sam Weinig.
15312
15313        * platform/network/cf/ResourceRequest.h:
15314        (WebCore::ResourceRequest::ResourceRequest):
15315
153162014-06-14  Benjamin Poulain  <benjamin@webkit.org>
15317
15318        Fix the ARM64 build
15319
15320        * cssjit/SelectorCompiler.cpp:
15321        (WebCore::SelectorCompiler::SelectorCodeGenerator::addFlagsToElementStyleFromContext):
15322
153232014-06-13  Sam Weinig  <sam@webkit.org>
15324
15325        Store DOM constants directly in the JS object rather than jumping through a custom accessor
15326        https://bugs.webkit.org/show_bug.cgi?id=133898
15327
15328        Reviewed by Oliver Hunt.
15329
15330        Instead of implementing constants as custom accessors that just happen to return a value,
15331        we now store the constant directly in the HashTableValue array (where the GetValueFunc used
15332        to be). 
15333        
15334        - For the case where the constant is accessed via the static table (still in use for instances 
15335          and some prototypes), the static lookup function will set the value on the property slot,
15336          instead of passing a function pointer.
15337        - For the case where the constant is eagerly reified (most prototypes and all constructors) the
15338          constant is put directly in the object.
15339
15340        In micro benchmarks this looks to be around a 4x speedup on the use of DOM constants.
15341
15342        This also removes support for constant strings in IDL, which we had no uses of.
15343
15344        * bindings/scripts/CodeGeneratorJS.pm:
15345        (GenerateHeader):
15346        Remove code to generate forward declaration of constant accessor functions.
15347
15348        (GenerateImplementation):
15349        Remove code to generate implementation of constant accessor functions.
15350
15351        (GenerateHashTableValueArray):
15352        Plant the constant directly in the value array.
15353
15354        * bindings/scripts/IDLParser.pm:
15355        (parseConstValue):
15356        Remove support for constant strings.
15357
15358        * bindings/scripts/test/JS/JSTestInterface.cpp:
15359        * bindings/scripts/test/JS/JSTestInterface.h:
15360        * bindings/scripts/test/JS/JSTestObj.cpp:
15361        * bindings/scripts/test/JS/JSTestObj.h:
15362        * bindings/scripts/test/ObjC/DOMTestObj.h:
15363        * bindings/scripts/test/TestObj.idl:
15364        Update test results.
15365
153662014-06-14  Anders Carlsson  <andersca@apple.com>
15367
15368        Simplify Document::processHttpEquiv
15369        https://bugs.webkit.org/show_bug.cgi?id=133910
15370
15371        Reviewed by Andreas Kling.
15372
15373        * dom/Document.cpp:
15374        (WebCore::Document::processHttpEquiv):
15375        * platform/network/HTTPHeaderNames.in:
15376
153772014-06-14  Andreas Kling  <akling@apple.com>
15378
15379        GCController should return FastMalloc memory to the system.
15380        <https://webkit.org/b/133884>
15381
15382        Reviewed by Anders Carlsson.
15383
15384        Speculative test fix; I'm kinda suspecting that some tests are reporting
15385        more memory used because we did a GC but didn't get around to returning
15386        free pages to the system yet.
15387
15388        * bindings/js/GCController.cpp:
15389        (WebCore::GCController::garbageCollectNow):
15390
153912014-06-14  Zan Dobersek  <zdobersek@igalia.com>
15392
15393        Generate HTTP header names that are required by WebKitWebSrc
15394        https://bugs.webkit.org/show_bug.cgi?id=133906
15395
15396        Reviewed by Anders Carlsson.
15397
15398        WebKitWebSrc implementation sets icy-metadata and transferMode.dlna HTTP headers
15399        on ResourceRequest objects. The two headers are added to HTTPHeaderNames.in, and
15400        a small tweak is added to the generator script to avoid the dot in the second
15401        header's name (which would otherwise generate invalid C++).
15402
15403        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
15404        (webKitWebSrcStart):
15405        * platform/network/HTTPHeaderNames.in:
15406        * platform/network/create-http-header-name-table:
15407
154082014-06-14  Anders Carlsson  <andersca@apple.com>
15409
15410        Replace some uses of ResourceRequestBase::addHTTPHeaderField with setHTTPHeaderField
15411        https://bugs.webkit.org/show_bug.cgi?id=133907
15412
15413        Reviewed by Andreas Kling.
15414
15415        * Modules/websockets/WebSocketHandshake.cpp:
15416        (WebCore::WebSocketHandshake::clientHandshakeRequest):
15417        * platform/network/HTTPHeaderNames.in:
15418        * platform/network/cf/ResourceHandleCFNet.cpp:
15419        (WebCore::applyBasicAuthorizationHeader):
15420        * platform/network/mac/ResourceHandleMac.mm:
15421        (WebCore::applyBasicAuthorizationHeader):
15422
154232014-06-13  Anders Carlsson  <andersca@apple.com>
15424
15425        Add a ResourceRequestBase::setHTTPHeaderField overload that takes a HTTPHeaderName
15426        https://bugs.webkit.org/show_bug.cgi?id=133881
15427
15428        Reviewed by Sam Weinig.
15429
15430        * WebCore.exp.in:
15431        * fileapi/FileReaderLoader.cpp:
15432        (WebCore::FileReaderLoader::start):
15433        * inspector/InspectorResourceAgent.cpp:
15434        (WebCore::InspectorResourceAgent::willSendRequest):
15435        * loader/CrossOriginAccessControl.cpp:
15436        (WebCore::createAccessControlPreflightRequest):
15437        * loader/FrameLoader.cpp:
15438        (WebCore::FrameLoader::addExtraFieldsToRequest):
15439        * loader/PingLoader.cpp:
15440        (WebCore::PingLoader::loadImage):
15441        (WebCore::PingLoader::sendPing):
15442        * loader/appcache/ApplicationCacheGroup.cpp:
15443        (WebCore::ApplicationCacheGroup::createResourceHandle):
15444        * loader/cache/CachedResource.cpp:
15445        (WebCore::CachedResource::load):
15446        * page/EventSource.cpp:
15447        (WebCore::EventSource::connect):
15448        * platform/network/BlobResourceHandle.cpp:
15449        (WebCore::BlobResourceHandle::doStart):
15450        * platform/network/HTTPHeaderNames.in:
15451        * platform/network/ResourceRequestBase.cpp:
15452        (WebCore::ResourceRequestBase::httpHeaderField):
15453        (WebCore::ResourceRequestBase::setHTTPHeaderField):
15454        (WebCore::ResourceRequestBase::httpContentType):
15455        (WebCore::ResourceRequestBase::setHTTPContentType):
15456        (WebCore::ResourceRequestBase::httpReferrer):
15457        (WebCore::ResourceRequestBase::setHTTPReferrer):
15458        (WebCore::ResourceRequestBase::httpOrigin):
15459        (WebCore::ResourceRequestBase::setHTTPOrigin):
15460        (WebCore::ResourceRequestBase::httpUserAgent):
15461        (WebCore::ResourceRequestBase::setHTTPUserAgent):
15462        (WebCore::ResourceRequestBase::httpAccept):
15463        (WebCore::ResourceRequestBase::setHTTPAccept):
15464        * platform/network/ResourceRequestBase.h:
15465        * platform/network/mac/ResourceHandleMac.mm:
15466        (WebCore::ResourceHandle::willSendRequest):
15467
154682014-06-14  Simon Fraser  <simon.fraser@apple.com>
15469
15470        Masks disappear when layers become tiled
15471        https://bugs.webkit.org/show_bug.cgi?id=133892
15472        <rdar://problem/17309793>
15473
15474        Reviewed by Tim Horton.
15475        
15476        There were several problems with tiled mask layers.
15477        
15478        First, when a layer became tiled it failed to re-apply the platform layer
15479        for its mask; fixed by adding MaskLayerChanged to the set of flags in
15480        swapFromOrToTiledLayer().
15481        
15482        Secondly, in CA, a mask layer's superlayer is the layer which is it masking,
15483        so the if (oldLayer->superlayer())... code in swapFromOrToTiledLayer() would
15484        erroneously try to swap out a sublayer on the superlayer with the mask.
15485        
15486        Thirdly, the mask layer is updated after its host layer, but when the mask layer
15487        become tiled, there was no code that updated the mask platform layer on its
15488        host layer. Fix by:
15489            1. setting a bit on a layer to note that it's being used as a mask.
15490            2. setting the parent of such a layer to its host layer (mimicking CA)
15491            3. when the mask becomes tiled, dirtying the MaskLayerChanged bit on
15492               its parent and adding a clause to commitLayerChangesAfterSublayers()
15493               to update the mask layer.
15494        
15495        Finally, ASSERTION FAILED: owningGraphicsLayer()->isCommittingChanges() would
15496        fire because we failed to set the m_isCommittingChanges flag while committing
15497        the mask layer. Fix by moving the TemporaryChange<bool> that sets this flag
15498        into commitLayerChangesBeforeSublayers() and commitLayerChangesAfterSublayers().
15499        
15500        Also used safe casts in more places in GraphicsLayerCA.
15501
15502        Tests: compositing/masks/become-tiled-mask.html
15503               compositing/masks/cease-tiled-mask.html
15504               compositing/masks/tiled-mask.html
15505
15506        * platform/graphics/GraphicsLayer.cpp:
15507        (WebCore::GraphicsLayer::GraphicsLayer):
15508        (WebCore::GraphicsLayer::removeFromParent):
15509        (WebCore::GraphicsLayer::setMaskLayer):
15510        * platform/graphics/GraphicsLayer.h:
15511        (WebCore::GraphicsLayer::setIsMaskLayer):
15512        (WebCore::GraphicsLayer::isMaskLayer):
15513        (WebCore::GraphicsLayer::setMaskLayer): Deleted.
15514        * platform/graphics/ca/GraphicsLayerCA.cpp:
15515        (WebCore::GraphicsLayerCA::removeFromParent):
15516        (WebCore::GraphicsLayerCA::setMaskLayer):
15517        (WebCore::GraphicsLayerCA::recursiveVisibleRectChangeRequiresFlush):
15518        (WebCore::GraphicsLayerCA::recursiveCommitChanges):
15519        (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
15520        (WebCore::GraphicsLayerCA::commitLayerChangesAfterSublayers):
15521        (WebCore::GraphicsLayerCA::updateSublayerList):
15522        (WebCore::GraphicsLayerCA::ensureStructuralLayer):
15523        (WebCore::GraphicsLayerCA::updateMaskLayer):
15524        (WebCore::GraphicsLayerCA::replicatedLayerRoot):
15525        (WebCore::GraphicsLayerCA::createFilterAnimationsFromKeyframes):
15526        (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
15527        (WebCore::GraphicsLayerCA::propagateLayerChangeToReplicas):
15528        (WebCore::GraphicsLayerCA::fetchCloneLayers):
15529
155302014-06-14  peavo@outlook.com  <peavo@outlook.com>
15531
15532        [Curl] Compile errors related to http headers.
15533        https://bugs.webkit.org/show_bug.cgi?id=133901
15534
15535        Reviewed by Brent Fulgham.
15536
15537        Http headers should now be specified with an enum, not a string.
15538
15539        * platform/network/curl/CurlCacheEntry.cpp:
15540        (WebCore::CurlCacheEntry::parseResponseHeaders):
15541        * platform/network/curl/MultipartHandle.cpp:
15542        (WebCore::MultipartHandle::didReceiveResponse):
15543
155442014-06-14  Brent Fulgham  <bfulgham@apple.com>
15545
15546        Unreviewed build fix after r169960.
15547
15548        * platform/graphics/ca/PlatformCALayer.cpp: Add missing include
15549        for snprintf on Windows.
15550
155512014-06-14  Csaba Osztrogonác  <ossy@webkit.org>
15552
15553        URTBF after r169943 and r169946.
15554
15555        * platform/network/HTTPHeaderMap.h: Removed maybe accidental deletion of the only one add function.
15556        * platform/network/HTTPHeaderNames.in: Added Sec-WebSocket-Key.
15557
155582014-06-14  Commit Queue  <commit-queue@webkit.org>
15559
15560        Unreviewed, rolling out r169963.
15561        https://bugs.webkit.org/show_bug.cgi?id=133899
15562
15563        Assertion in mathml/roots-removeChild.html (Requested by fredw
15564        on #webkit).
15565
15566        Reverted changeset:
15567
15568        "Draw radicals with glyphs for better rendering"
15569        https://bugs.webkit.org/show_bug.cgi?id=119038
15570        http://trac.webkit.org/changeset/169963
15571
155722014-06-14  Frédéric Wang  <fred.wang@free.fr>
15573
15574        Draw radicals with glyphs for better rendering
15575        https://bugs.webkit.org/show_bug.cgi?id=119038
15576
15577        Reviewed by Chris Fleizach.
15578
15579        We rewrite RenderMathMLRoot in order to fix bugs with SVG transforms and dynamic modification of children and allow drawing with an OpenType MATH table.
15580        The drawing of the radical sign (without the top bar) is now moved to a RenderMathMLRadicalOperator class inheriting from RenderMathMLOperator.
15581        This class fallbacks to the original drawing with graphic primitives if an OpenType MATH table is not available.
15582
15583        Tests: mathml/opentype/roots-LatinModern.html
15584               mathml/presentation/mroot-transform.html
15585
15586        * CMakeLists.txt: add files to build system.
15587        * WebCore.vcxproj/WebCore.vcxproj: ditto.
15588        * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
15589        * WebCore.xcodeproj/project.pbxproj: ditto
15590        * css/mathml.css: remove rules for msqrt/mroot. The "script level" in mroot is not incremented by 2 as specified in the spec.
15591        (math, mrow, mfenced, merror, mphantom, mstyle, menclose):
15592        (mroot > *:last-child):
15593        (math, mrow, mfenced, msqrt, mroot, merror, mphantom, mstyle, menclose): Deleted.
15594        (msqrt > *): Deleted.
15595        (mroot): Deleted. This rule was causing bug 126516.
15596        (mroot > * + *): Deleted.
15597        * rendering/RenderObject.h: Add two new isRenderMathML* functions for dynamic casting.
15598        (WebCore::RenderObject::isRenderMathMLRadicalOperator):
15599        (WebCore::RenderObject::isRenderMathMLRootWrapper):
15600        * rendering/mathml/RenderMathMLOperator.cpp: Accept a set of operator dictionary flags, all disabled by default. This is to allow anonymous radicas, which don't have any flag.
15601        isFencedOperator() is now replaced with the more general isAnonymous() since we allow anonymous radical operator fors msqrt/mroot.
15602        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
15603        (WebCore::RenderMathMLOperator::setOperatorFlagFromAttribute):
15604        (WebCore::RenderMathMLOperator::setOperatorPropertiesFromOpDictEntry):
15605        (WebCore::RenderMathMLOperator::SetOperatorProperties):
15606        (WebCore::RenderMathMLOperator::updateTokenContent):
15607        * rendering/mathml/RenderMathMLOperator.h: Allow class to be overriden, redefine the anonymous constructor, remove isFencedOperator().
15608        * rendering/mathml/RenderMathMLRadicalOperator.cpp: Added.
15609        (WebCore::RenderMathMLRadicalOperator::RenderMathMLRadicalOperator):
15610        (WebCore::RenderMathMLRadicalOperator::stretchTo):
15611        (WebCore::RenderMathMLRadicalOperator::SetOperatorProperties):
15612        (WebCore::RenderMathMLRadicalOperator::computePreferredLogicalWidths):
15613        (WebCore::RenderMathMLRadicalOperator::computeLogicalHeight):
15614        (WebCore::RenderMathMLRadicalOperator::paint):
15615        (WebCore::RenderMathMLRadicalOperator::trailingSpaceError):
15616        * rendering/mathml/RenderMathMLRadicalOperator.h: Added.
15617        * rendering/mathml/RenderMathMLRoot.cpp: Rewritten. Some parts to use graphic primitives are moved to RenderMathMLRadicalOperator.cpp.
15618        (WebCore::RenderMathMLRoot::RenderMathMLRoot):
15619        (WebCore::RenderMathMLRoot::baseWrapper):
15620        (WebCore::RenderMathMLRoot::radicalWrapper):
15621        (WebCore::RenderMathMLRoot::indexWrapper):
15622        (WebCore::RenderMathMLRoot::radicalOperator):
15623        (WebCore::RenderMathMLRoot::restructureWrappers):
15624        (WebCore::RenderMathMLRoot::addChild):
15625        (WebCore::RenderMathMLRoot::styleDidChange):
15626        (WebCore::RenderMathMLRoot::updateFromElement):
15627        (WebCore::RenderMathMLRoot::updateStyle):
15628        (WebCore::RenderMathMLRoot::firstLineBaseline):
15629        (WebCore::RenderMathMLRoot::layout):
15630        (WebCore::RenderMathMLRoot::paint):
15631        (WebCore::RenderMathMLRootWrapper::createAnonymousWrapper):
15632        (WebCore::RenderMathMLRootWrapper::removeChildWithoutRestructuring):
15633        (WebCore::RenderMathMLRootWrapper::removeChild):
15634        (WebCore::RenderMathMLRoot::paddingTop): Deleted.
15635        (WebCore::RenderMathMLRoot::paddingBottom): Deleted.
15636        (WebCore::RenderMathMLRoot::paddingLeft): Deleted.
15637        (WebCore::RenderMathMLRoot::paddingRight): Deleted.
15638        (WebCore::RenderMathMLRoot::paddingBefore): Deleted.
15639        (WebCore::RenderMathMLRoot::paddingAfter): Deleted.
15640        (WebCore::RenderMathMLRoot::paddingStart): Deleted.
15641        (WebCore::RenderMathMLRoot::paddingEnd): Deleted.
15642        (WebCore::RenderMathMLRoot::index): Deleted.
15643        * rendering/mathml/RenderMathMLRoot.h: Rewritten.
15644        (WebCore::RenderMathMLRootWrapper::RenderMathMLRootWrapper):
15645
156462014-06-13  Brent Fulgham  <bfulgham@apple.com>
15647
15648        Move utility functions from WebLayer to PlatformCALayer
15649        https://bugs.webkit.org/show_bug.cgi?id=133887
15650        <rdar://problem/17309622>
15651
15652        Reviewed by Simon Fraser.
15653
15654        Move some utility functions from WebLayer.h/.mm to PlatformCALayer.
15655        Provide ObjC implementation in PlatformCALayerMac. A future patch will
15656        provide corresponding Windows versions.
15657
15658        * WebCore.exp.in:
15659        * platform/graphics/ca/PlatformCALayer.cpp:
15660        (WebCore::PlatformCALayer::drawRepaintIndicator):
15661        * platform/graphics/ca/PlatformCALayer.h:
15662        * platform/graphics/ca/TileController.cpp:
15663        (WebCore::TileController::blankPixelCountForTiles):
15664        * platform/graphics/ca/TileGrid.cpp:
15665        (WebCore::TileGrid::platformCALayerPaintContents):
15666        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
15667        (PlatformCALayer::collectRectsToPaint):
15668        (PlatformCALayer::drawLayerContents):
15669        (PlatformCALayer::frameForLayer):
15670        * platform/graphics/mac/WebLayer.h:
15671        * platform/graphics/mac/WebLayer.mm:
15672        (-[WebLayer drawInContext:]):
15673        (WebCore::collectRectsToPaint): Deleted.
15674        (WebCore::drawLayerContents): Deleted.
15675        (WebCore::drawRepaintIndicator): Deleted.
15676        (WebCore::frameForLayer): Deleted.
15677
156782014-06-13  Alex Christensen  <achristensen@webkit.org>
15679
15680        Unreviewed disabling css jit on armv7.  It's not quite ready yet.
15681
15682        * cssjit/SelectorCompiler.cpp:
15683        (WebCore::SelectorCompiler::SelectorCodeGenerator::modulo):
15684        Removed extra comma.
15685
156862014-06-13  Alex Christensen  <achristensen@webkit.org>
15687
15688        Make css jit compile on armv7.
15689        https://bugs.webkit.org/show_bug.cgi?id=133889
15690
15691        Reviewed by Benjamin Poulain.
15692
15693        * cssjit/SelectorCompiler.cpp:
15694        (WebCore::SelectorCompiler::moduloHelper):
15695        (WebCore::SelectorCompiler::SelectorCodeGenerator::modulo):
15696        Implement modulo using a function call for now.
15697
156982014-06-13  Anders Carlsson  <andersca@apple.com>
15699
15700        Use the callOnMainThread version that takes an std::function in BlobResourceHandle::start()
15701        https://bugs.webkit.org/show_bug.cgi?id=133886
15702
15703        Reviewed by Andreas Kling.
15704
15705        Also replace a couple of NSAutoreleasePools with @autoreleasepool and an OwnPtr with an std::unique_ptr.
15706
15707        * page/scrolling/mac/ScrollingThreadMac.mm:
15708        (WebCore::ScrollingThread::threadRunLoopSourceCallback):
15709        * platform/mac/SharedTimerMac.mm:
15710        (WebCore::PowerObserver::PowerObserver):
15711        (WebCore::timerFired):
15712        (WebCore::setSharedTimerFireInterval):
15713        (WebCore::PowerObserver::create): Deleted.
15714        (WebCore::PowerObserver::didReceiveSystemPowerNotification): Deleted.
15715        * platform/network/BlobResourceHandle.cpp:
15716        (WebCore::BlobResourceHandle::start):
15717        (WebCore::delayedStartBlobResourceHandle): Deleted.
15718        * platform/network/BlobResourceHandle.h:
15719
157202014-06-12  Sam Weinig  <sam@webkit.org>
15721
15722        Constructors should eagerly reify their properties too
15723        https://bugs.webkit.org/show_bug.cgi?id=133822
15724
15725        Reviewed by Andreas Kling.
15726
15727        * bindings/scripts/CodeGeneratorJS.pm:
15728        (GenerateConstructorDeclaration):
15729        Constructors should never need to use the lazy property HashTable, so we can just
15730        remove its getOwnPropertySlot completely.
15731
15732        (ConstructorHasProperties):
15733        Add helper to determine if we need to reify any properties.
15734
15735        (GenerateConstructorHelperMethods):
15736        Reify if needed, and remove the implementation of getOwnPropertySlot.
15737
15738        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
15739        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
15740        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
15741        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
15742        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
15743        * bindings/scripts/test/JS/JSTestEventConstructor.h:
15744        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
15745        * bindings/scripts/test/JS/JSTestEventTarget.h:
15746        * bindings/scripts/test/JS/JSTestException.cpp:
15747        * bindings/scripts/test/JS/JSTestException.h:
15748        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
15749        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
15750        * bindings/scripts/test/JS/JSTestInterface.cpp:
15751        * bindings/scripts/test/JS/JSTestInterface.h:
15752        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
15753        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
15754        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
15755        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
15756        * bindings/scripts/test/JS/JSTestNode.cpp:
15757        * bindings/scripts/test/JS/JSTestNode.h:
15758        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
15759        * bindings/scripts/test/JS/JSTestNondeterministic.h:
15760        * bindings/scripts/test/JS/JSTestObj.cpp:
15761        * bindings/scripts/test/JS/JSTestObj.h:
15762        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
15763        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
15764        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
15765        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
15766        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
15767        * bindings/scripts/test/JS/JSTestTypedefs.h:
15768        * bindings/scripts/test/JS/JSattribute.cpp:
15769        * bindings/scripts/test/JS/JSattribute.h:
15770        * bindings/scripts/test/JS/JSreadonly.cpp:
15771        * bindings/scripts/test/JS/JSreadonly.h:
15772        Update tests.
15773
157742014-06-13  Alex Christensen  <achristensen@webkit.org>
15775
15776        Make css jit allocator smarter.
15777        https://bugs.webkit.org/show_bug.cgi?id=133834
15778
15779        Reviewed by Benjamin Poulain.
15780
15781        * cssjit/RegisterAllocator.h:
15782        (WebCore::RegisterAllocator::allocateRegister):
15783        (WebCore::RegisterAllocator::deallocateRegister):
15784        (WebCore::RegisterAllocator::reserveCalleeSavedRegisters):
15785        (WebCore::LocalRegister::LocalRegister):
15786        (WebCore::RegisterAllocator::RegisterAllocator):
15787        Use a Deque for the registers.  Allocate from the front and deallocate to the back to cycle the register usage.
15788        (WebCore::RegisterAllocator::allocateRegisterWithPreference):
15789        (WebCore::LocalRegisterWithPreference::LocalRegisterWithPreference):
15790        Added the ability to specify that we prefer a certain register if it is available while allocating.
15791        These functions always return a register.  It is just a different register than preferred if the preferred register is not available.
15792        * cssjit/SelectorCompiler.cpp:
15793        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueExactMatching):
15794        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeFunctionCallValueMatching):
15795        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsActive):
15796        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsHovered):
15797        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
15798        Whenever we are allocating a register for the second argument, we should specify that we 
15799        prefer to have argumentGPR1 to reduce register swapping when preparing for a function call.
15800        This cannot be done for argumentGPR0 because elementAddressRegister is argumentGPR0 and it is always allocated.
15801
158022014-06-13  Jeremy Jones  <jeremyj@apple.com>
15803
15804        set setUsesExternalPlaybackWhileExternalScreenIsActive based on fullscreen mode
15805        https://bugs.webkit.org/show_bug.cgi?id=133829
15806
15807        Reviewed by Eric Carlson.
15808
15809        When playing inline and external screen is active, don't use external playback.
15810
15811        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
15812        declare updateDisableExternalPlayback()
15813        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
15814        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):
15815        call updateDisableExternalPlayback when player is created
15816        (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenLayer):
15817        call updateDisableExternalPlayback when fullscreen mode changes
15818        (WebCore::MediaPlayerPrivateAVFoundationObjC::updateDisableExternalPlayback):
15819        update setUsesExternalPlaybackWhileExternalScreenIsActive based on fullscreen mode
15820
158212014-06-13  Brent Fulgham  <bfulgham@apple.com>
15822
15823        Convert LayerPool and TileCoverageMap from ObjC to C++
15824        https://bugs.webkit.org/show_bug.cgi?id=133862
15825        <rdar://problem/17302883>
15826
15827        Reviewed by Simon Fraser.
15828
15829        This just moves two ObjC files from the mac subdirectory to the parent and
15830        revises the project to build them as C++.
15831
15832        * WebCore.xcodeproj/project.pbxproj:
15833        * platform/graphics/ca/LayerPool.cpp: Copied from platform/graphics/ca/mac/LayerPool.mm.
15834        * platform/graphics/ca/LayerPool.h: Copied from platform/graphics/ca/mac/LayerPool.h.
15835        * platform/graphics/ca/TileCoverageMap.cpp: Copied from platform/graphics/ca/mac/TileCoverageMap.mm.
15836        * platform/graphics/ca/TileCoverageMap.h: Copied from platform/graphics/ca/mac/TileCoverageMap.h.
15837        * platform/graphics/ca/mac/LayerPool.h: Removed.
15838        * platform/graphics/ca/mac/LayerPool.mm: Removed.
15839        * platform/graphics/ca/mac/TileCoverageMap.h: Removed.
15840        * platform/graphics/ca/mac/TileCoverageMap.mm: Removed.
15841
158422014-06-13  Alex Christensen  <achristensen@webkit.org>
15843
15844        Make css jit compile for armv7.
15845        https://bugs.webkit.org/show_bug.cgi?id=133596
15846
15847        Reviewed by Benjamin Poulain.
15848
15849        * cssjit/FunctionCall.h:
15850        (WebCore::FunctionCall::swapArguments):
15851        Implemented for ARM_THUMB2 and removed allocator hack.
15852        * cssjit/RegisterAllocator.h:
15853        Added list of ARM_THUMB2 general purpose registers.
15854        (WebCore::RegisterAllocator::isValidRegister):
15855        Added ARM register range and corrected ARM64 register range now that r15 is tempRegister.
15856        * cssjit/SelectorCompiler.cpp:
15857        (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
15858        Return CannotCompile if compiling fails because of lack of registers.
15859        (WebCore::SelectorCompiler::SelectorCodeGenerator::generatePrologue):
15860        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateEpilogue):
15861        Implemented for ARM_THUMB2.
15862        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
15863        Return false if the selector cannot be compiled because of lack of registers.
15864        (WebCore::SelectorCompiler::SelectorCodeGenerator::addFlagsToElementStyleFromContext):
15865        Added code using 32-bit operations and used macro assembler for 64-bit operations.
15866        (WebCore::SelectorCompiler::SelectorCodeGenerator::modulo):
15867        Implemented for APPLE_ARMV7S, where sdiv is not a template in the assembler.
15868        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributesMatching):
15869        Use addPtr instead of add64.
15870
158712014-06-13  Anders Carlsson  <andersca@apple.com>
15872
15873        Add a HTTPHeaderMap::get overload that takes an HTTPHeaderName
15874        https://bugs.webkit.org/show_bug.cgi?id=133877
15875
15876        Reviewed by Andreas Kling.
15877
15878        * Modules/websockets/WebSocketHandshake.cpp:
15879        (WebCore::WebSocketHandshake::serverWebSocketProtocol):
15880        (WebCore::WebSocketHandshake::serverSetCookie):
15881        (WebCore::WebSocketHandshake::serverSetCookie2):
15882        (WebCore::WebSocketHandshake::serverUpgrade):
15883        (WebCore::WebSocketHandshake::serverConnection):
15884        (WebCore::WebSocketHandshake::serverWebSocketAccept):
15885        * WebCore.exp.in:
15886        * platform/network/HTTPHeaderMap.cpp:
15887        (WebCore::HTTPHeaderMap::get):
15888        * platform/network/HTTPHeaderMap.h:
15889        * platform/network/HTTPHeaderNames.in:
15890        * plugins/PluginView.cpp:
15891        (WebCore::PluginView::handlePost):
15892
158932014-06-13  Commit Queue  <commit-queue@webkit.org>
15894
15895        Unreviewed, rolling out r169939.
15896        https://bugs.webkit.org/show_bug.cgi?id=133878
15897
15898        This patch raises assertions on mac (Requested by fredw on
15899        #webkit).
15900
15901        Reverted changeset:
15902
15903        "Draw radicals with glyphs for better rendering"
15904        https://bugs.webkit.org/show_bug.cgi?id=119038
15905        http://trac.webkit.org/changeset/169939
15906
159072014-06-13  Anders Carlsson  <andersca@apple.com>
15908
15909        Add a HTTPHeaderMap::set overload that takes a HTTPHeaderName
15910        https://bugs.webkit.org/show_bug.cgi?id=133874
15911
15912        Reviewed by Tim Horton.
15913
15914        * platform/network/HTTPHeaderMap.cpp:
15915        (WebCore::HTTPHeaderMap::set):
15916        * platform/network/HTTPHeaderMap.h:
15917        * platform/network/cf/ResourceRequestCFNet.cpp:
15918        (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
15919        * platform/network/mac/ResourceRequestMac.mm:
15920        (WebCore::ResourceRequest::doUpdatePlatformHTTPBody):
15921        * xml/XMLHttpRequest.cpp:
15922        (WebCore::XMLHttpRequest::send):
15923
159242014-06-13  Anders Carlsson  <andersca@apple.com>
15925
15926        Add a HTTPHeaderMap::find overload that takes a HTTPHeaderName
15927        https://bugs.webkit.org/show_bug.cgi?id=133872
15928
15929        Reviewed by Andreas Kling.
15930
15931        * loader/DocumentLoader.cpp:
15932        (WebCore::DocumentLoader::responseReceived):
15933        * platform/network/HTTPHeaderMap.cpp:
15934        (WebCore::HTTPHeaderMap::get):
15935        (WebCore::HTTPHeaderMap::find):
15936        * platform/network/HTTPHeaderMap.h:
15937        * platform/network/HTTPHeaderNames.in:
15938
159392014-06-13  Frédéric Wang  <fred.wang@free.fr>
15940
15941        Draw radicals with glyphs for better rendering
15942        https://bugs.webkit.org/show_bug.cgi?id=119038
15943
15944        Reviewed by Chris Fleizach.
15945
15946        We rewrite RenderMathMLRoot in order to fix bugs with SVG transforms and dynamic modification of children and allow drawing with an OpenType MATH table.
15947        The drawing of the radical sign (without the top bar) is now moved to a RenderMathMLRadicalOperator class inheriting from RenderMathMLOperator.
15948        This class fallbacks to the original drawing with graphic primitives if an OpenType MATH table is not available.
15949
15950        Tests: mathml/opentype/roots-LatinModern.html
15951               mathml/presentation/mroot-transform.html
15952
15953        * CMakeLists.txt: add files to build system.
15954        * WebCore.vcxproj/WebCore.vcxproj: ditto.
15955        * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
15956        * WebCore.xcodeproj/project.pbxproj: ditto
15957        * css/mathml.css: remove rules for msqrt/mroot. The "script level" in mroot is not incremented by 2 as specified in the spec.
15958        (math, mrow, mfenced, merror, mphantom, mstyle, menclose):
15959        (mroot > *:last-child):
15960        (math, mrow, mfenced, msqrt, mroot, merror, mphantom, mstyle, menclose): Deleted.
15961        (msqrt > *): Deleted.
15962        (mroot): Deleted. This rule was causing bug 126516.
15963        (mroot > * + *): Deleted.
15964        * rendering/RenderObject.h: Add two new isRenderMathML* functions for dynamic casting.
15965        (WebCore::RenderObject::isRenderMathMLRadicalOperator):
15966        (WebCore::RenderObject::isRenderMathMLRootWrapper):
15967        * rendering/mathml/RenderMathMLOperator.cpp: Accept a set of operator dictionary flags, all disabled by default. This is to allow anonymous radicas, which don't have any flag.
15968        isFencedOperator() is now replaced with the more general isAnonymous() since we allow anonymous radical operator fors msqrt/mroot.
15969        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
15970        (WebCore::RenderMathMLOperator::setOperatorFlagFromAttribute):
15971        (WebCore::RenderMathMLOperator::setOperatorPropertiesFromOpDictEntry):
15972        (WebCore::RenderMathMLOperator::SetOperatorProperties):
15973        (WebCore::RenderMathMLOperator::updateTokenContent):
15974        * rendering/mathml/RenderMathMLOperator.h: Allow class to be overriden, redefine the anonymous constructor, remove isFencedOperator().
15975        * rendering/mathml/RenderMathMLRadicalOperator.cpp: Added.
15976        (WebCore::RenderMathMLRadicalOperator::RenderMathMLRadicalOperator):
15977        (WebCore::RenderMathMLRadicalOperator::stretchTo):
15978        (WebCore::RenderMathMLRadicalOperator::SetOperatorProperties):
15979        (WebCore::RenderMathMLRadicalOperator::computePreferredLogicalWidths):
15980        (WebCore::RenderMathMLRadicalOperator::computeLogicalHeight):
15981        (WebCore::RenderMathMLRadicalOperator::paint):
15982        (WebCore::RenderMathMLRadicalOperator::trailingSpaceError):
15983        * rendering/mathml/RenderMathMLRadicalOperator.h: Added.
15984        * rendering/mathml/RenderMathMLRoot.cpp: Rewritten. Some parts to use graphic primitives are moved to RenderMathMLRadicalOperator.cpp.
15985        (WebCore::RenderMathMLRoot::RenderMathMLRoot):
15986        (WebCore::RenderMathMLRoot::baseWrapper):
15987        (WebCore::RenderMathMLRoot::radicalWrapper):
15988        (WebCore::RenderMathMLRoot::indexWrapper):
15989        (WebCore::RenderMathMLRoot::radicalOperator):
15990        (WebCore::RenderMathMLRoot::restructureWrappers):
15991        (WebCore::RenderMathMLRoot::addChild):
15992        (WebCore::RenderMathMLRoot::styleDidChange):
15993        (WebCore::RenderMathMLRoot::updateFromElement):
15994        (WebCore::RenderMathMLRoot::updateStyle):
15995        (WebCore::RenderMathMLRoot::firstLineBaseline):
15996        (WebCore::RenderMathMLRoot::layout):
15997        (WebCore::RenderMathMLRoot::paint):
15998        (WebCore::RenderMathMLRootWrapper::createAnonymousWrapper):
15999        (WebCore::RenderMathMLRootWrapper::removeChildWithoutRestructuring):
16000        (WebCore::RenderMathMLRootWrapper::removeChild):
16001        (WebCore::RenderMathMLRoot::paddingTop): Deleted.
16002        (WebCore::RenderMathMLRoot::paddingBottom): Deleted.
16003        (WebCore::RenderMathMLRoot::paddingLeft): Deleted.
16004        (WebCore::RenderMathMLRoot::paddingRight): Deleted.
16005        (WebCore::RenderMathMLRoot::paddingBefore): Deleted.
16006        (WebCore::RenderMathMLRoot::paddingAfter): Deleted.
16007        (WebCore::RenderMathMLRoot::paddingStart): Deleted.
16008        (WebCore::RenderMathMLRoot::paddingEnd): Deleted.
16009        (WebCore::RenderMathMLRoot::index): Deleted.
16010        * rendering/mathml/RenderMathMLRoot.h: Rewritten.
16011        (WebCore::RenderMathMLRootWrapper::RenderMathMLRootWrapper):
16012
160132014-06-12  Anders Carlsson  <andersca@apple.com>
16014
16015        Add overloads of HTTPHeaderMap::find and remove that take enums
16016        https://bugs.webkit.org/show_bug.cgi?id=133823
16017
16018        Reviewed by Sam Weinig.
16019
16020        * WebCore.exp.in:
16021        Update symbols.
16022
16023        * WebCore.xcodeproj/project.pbxproj:
16024        Make HTTPHeaderNames.h private.
16025
16026        * platform/network/HTTPHeaderMap.cpp:
16027        (WebCore::HTTPHeaderMap::contains):
16028        Convert the enum value to a string and call the contains overload that takes a string.
16029
16030        (WebCore::HTTPHeaderMap::remove):
16031        Convert the enum value to a string and call the remove overload that takes a string.
16032
16033        * platform/network/HTTPHeaderMap.h:
16034        Add new overloads taking HTTPHeaderName and mark the versions taking string literals as deleted.
16035
16036        * platform/network/HTTPHeaderNames.in:
16037        Add new header names.
16038
16039        * platform/network/ResourceRequestBase.cpp:
16040        (WebCore::ResourceRequestBase::clearHTTPAuthorization):
16041        (WebCore::ResourceRequestBase::clearHTTPContentType):
16042        (WebCore::ResourceRequestBase::clearHTTPReferrer):
16043        (WebCore::ResourceRequestBase::clearHTTPOrigin):
16044        (WebCore::ResourceRequestBase::clearHTTPUserAgent):
16045        (WebCore::ResourceRequestBase::clearHTTPAccept):
16046        Update functions to use HTTPHeaderName enums.
16047
16048        (WebCore::ResourceRequestBase::isConditional):
16049        (WebCore::ResourceRequestBase::makeUnconditional):
16050        Simplify these.
16051
160522014-06-13  Jarek Czekalski  <jarekczek@poczta.onet.pl>
16053
16054        [ATK] Fix text inside "span" block in "a" block was not accessible.
16055        https://bugs.webkit.org/show_bug.cgi?id=132349
16056
16057        Reviewed by Mario Sanchez Prada.
16058
16059        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: Add link role
16060          to the list of roles whose objects always expose atk_text interface.
16061
160622014-06-13  Alberto Garcia  <berto@igalia.com>
16063
16064        [GTK] GLContextEGL.cpp: conflicting declaration 'typedef ptrdiff_t GLintptr'
16065        https://bugs.webkit.org/show_bug.cgi?id=133550
16066
16067        Reviewed by Gustavo Noronha Silva.
16068
16069        Cairo includes some definitions from GLX that conflict with the
16070        ones provided by our GLES2 headers (GLintptr, GLsizeiptr).
16071
16072        Since GLContextEGL doesn't use any GLX functions we can safely
16073        disable the inclusion of those functions in that source file.
16074
16075        * platform/graphics/egl/GLContextEGL.cpp:
16076
160772014-06-13  Manuel Rego Casasnovas  <rego@igalia.com>
16078
16079        [CSS Grid Layout] Introduce an explicit type for resolved grid positions
16080        https://bugs.webkit.org/show_bug.cgi?id=131732
16081
16082        Reviewed by Sergio Villar Senin.
16083
16084        We were using simple size_t integers to represent resolved grid
16085        positions in our internal data structures. This change allows us to
16086        clarify the code, avoid potential off by one mistakes, and move the
16087        resolving code to a central place.
16088
16089        A new class GridResolvedPosition has been created and the related
16090        methods have been moved there from RenderGrid.
16091        GridSpan is now defined by two GridResolvedPosition, so all the code
16092        using it has been modified to adapt it to GridResolvedPosition.
16093
16094        No new tests as it is already covered by current tests
16095        (fast/css-grid-layout/).
16096
16097        * CMakeLists.txt:
16098        * WebCore.vcxproj/WebCore.vcxproj:
16099        * WebCore.vcxproj/WebCore.vcxproj.filters:
16100        * WebCore.xcodeproj/project.pbxproj:
16101        * css/CSSGridTemplateAreasValue.cpp:
16102        (WebCore::stringForPosition):
16103        * css/CSSParser.cpp:
16104        (WebCore::CSSParser::parseGridTemplateAreasRow):
16105        * css/StyleResolver.cpp:
16106        (WebCore::createImplicitNamedGridLinesFromGridArea):
16107        * rendering/RenderGrid.cpp:
16108        (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
16109        (WebCore::RenderGrid::computeNormalizedFractionBreadth):
16110        (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForItems):
16111        (WebCore::RenderGrid::insertItemIntoGrid):
16112        (WebCore::RenderGrid::placeItemsOnGrid):
16113        (WebCore::RenderGrid::populateExplicitGridAndOrderIterator):
16114        (WebCore::RenderGrid::placeSpecifiedMajorAxisItemsOnGrid):
16115        (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid):
16116        (WebCore::RenderGrid::autoPlacementMajorAxisDirection):
16117        (WebCore::RenderGrid::autoPlacementMinorAxisDirection):
16118        (WebCore::RenderGrid::gridAreaBreadthForChild):
16119        (WebCore::RenderGrid::findChildLogicalPosition):
16120        (WebCore::RenderGrid::explicitGridColumnCount): Deleted.
16121        (WebCore::RenderGrid::explicitGridRowCount): Deleted.
16122        (WebCore::isColumnSide): Deleted.
16123        (WebCore::isStartSide): Deleted.
16124        (WebCore::RenderGrid::explicitGridSizeForSide): Deleted.
16125        (WebCore::RenderGrid::resolveGridPositionsFromAutoPlacementPosition): Deleted.
16126        (WebCore::gridLinesForSide): Deleted.
16127        (WebCore::implicitNamedGridLineForSide): Deleted.
16128        (WebCore::isNonExistentNamedLineOrArea): Deleted.
16129        (WebCore::RenderGrid::adjustGridPositionsFromStyle): Deleted.
16130        (WebCore::RenderGrid::resolveGridPositionsFromStyle): Deleted.
16131        (WebCore::RenderGrid::resolveNamedGridLinePositionFromStyle): Deleted.
16132        (WebCore::RenderGrid::resolveGridPositionFromStyle): Deleted.
16133        (WebCore::RenderGrid::resolveGridPositionAgainstOppositePosition): Deleted.
16134        (WebCore::RenderGrid::resolveNamedGridLinePositionAgainstOppositePosition): Deleted.
16135        (WebCore::firstNamedGridLineBeforePosition): Deleted.
16136        (WebCore::RenderGrid::resolveRowStartColumnStartNamedGridLinePositionAgainstOppositePosition): Deleted.
16137        (WebCore::RenderGrid::resolveRowEndColumnEndNamedGridLinePositionAgainstOppositePosition): Deleted.
16138        * rendering/RenderGrid.h:
16139        * rendering/style/GridCoordinate.h:
16140        (WebCore::GridSpan::GridSpan):
16141        (WebCore::GridSpan::operator==):
16142        * rendering/style/GridPosition.h:
16143        (WebCore::GridPosition::adjustGridPositionForRowEndColumnEndSide): Deleted.
16144        (WebCore::GridPosition::adjustGridPositionForSide): Deleted.
16145        * rendering/style/GridResolvedPosition.cpp: Added.
16146        (WebCore::isColumnSide):
16147        (WebCore::isStartSide):
16148        (WebCore::explicitGridSizeForSide):
16149        (WebCore::GridResolvedPosition::resolveGridPositionsFromAutoPlacementPosition):
16150        (WebCore::gridLinesForSide):
16151        (WebCore::implicitNamedGridLineForSide):
16152        (WebCore::isNonExistentNamedLineOrArea):
16153        (WebCore::GridResolvedPosition::adjustGridPositionsFromStyle):
16154        (WebCore::GridResolvedPosition::resolveGridPositionsFromStyle):
16155        (WebCore::GridResolvedPosition::resolveNamedGridLinePositionFromStyle):
16156        (WebCore::GridResolvedPosition::resolveGridPositionFromStyle):
16157        (WebCore::GridResolvedPosition::resolveGridPositionAgainstOppositePosition):
16158        (WebCore::GridResolvedPosition::resolveNamedGridLinePositionAgainstOppositePosition):
16159        (WebCore::firstNamedGridLineBeforePosition):
16160        (WebCore::GridResolvedPosition::resolveRowStartColumnStartNamedGridLinePositionAgainstOppositePosition):
16161        (WebCore::GridResolvedPosition::resolveRowEndColumnEndNamedGridLinePositionAgainstOppositePosition):
16162        * rendering/style/GridResolvedPosition.h: Added.
16163        (WebCore::GridResolvedPosition::adjustGridPositionForRowEndColumnEndSide):
16164        (WebCore::GridResolvedPosition::adjustGridPositionForSide):
16165        (WebCore::GridResolvedPosition::GridResolvedPosition):
16166        (WebCore::GridResolvedPosition::operator++):
16167        (WebCore::GridResolvedPosition::operator==):
16168        (WebCore::GridResolvedPosition::operator<):
16169        (WebCore::GridResolvedPosition::operator>):
16170        (WebCore::GridResolvedPosition::operator<=):
16171        (WebCore::GridResolvedPosition::operator>=):
16172        (WebCore::GridResolvedPosition::toInt):
16173        (WebCore::GridResolvedPosition::next):
16174
161752014-06-12  Carlos Garcia Campos  <cgarcia@igalia.com>
16176
16177        [GTK] Remove all deprecated API from GObject DOM bindings
16178        https://bugs.webkit.org/show_bug.cgi?id=133728
16179
16180        Reviewed by Martin Robinson.
16181
16182        Remove all deprecated symbols from the GObject DOM bindings,
16183        keeping the deprecation infraestructure for future API breaks.
16184
16185        * PlatformGTK.cmake: Remove WebKitDOMDeprecated files from the
16186        build.
16187        * bindings/gobject/WebKitDOMDeprecated.cpp: Removed.
16188        * bindings/gobject/WebKitDOMDeprecated.h: Removed.
16189        * bindings/gobject/WebKitDOMDeprecated.symbols: Removed.
16190        * bindings/gobject/webkitdom.symbols: Updated to the current API.
16191        * bindings/scripts/CodeGeneratorGObject.pm:
16192        (SkipFunction): Remove exceptions for deprecated API.
16193        (GetFunctionDeprecationInformation): Ditto.
16194        (GetEffectiveFunctionName): Ditto.
16195        * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
16196        (webkit_dom_test_event_target_dispatch_event): Deleted.
16197        * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
16198        * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.symbols:
16199        * dom/Element.idl: Remove GObject exception.
16200
162012014-06-12  Zalan Bujtas  <zalan@apple.com>
16202
16203        Subpixel rendering: Make <input type=> and <button> elements' decoration subpixel aware.
16204        https://bugs.webkit.org/show_bug.cgi?id=133812
16205        <rdar://problem/17286309>
16206
16207        Reviewed by Simon Fraser.
16208
16209        Enable <input type=> and <button> decoration painting on subpixel positions.
16210        The theme size is still integral, but its position is snapped to device pixels.
16211        Theme's label, the InlineTextBox is already subpixel position aware.
16212        webkit.org/b/132005 tracks the rest of the themes.
16213
16214        Not testable.
16215
16216        * accessibility/AccessibilityObject.cpp:
16217        (WebCore::AccessibilityObject::boundingBoxForQuads): Keep integral snapping for now.
16218        * platform/Theme.h:
16219        (WebCore::Theme::paint):
16220        (WebCore::Theme::inflateControlPaintRect):
16221        * platform/mac/ThemeMac.h:
16222        * platform/mac/ThemeMac.mm:
16223        (WebCore::inflateRect):
16224        (WebCore::configureToggleButton):
16225        (WebCore::sharedRadioCell):
16226        (WebCore::sharedCheckboxCell):
16227        (WebCore::paintToggleButton):
16228        (WebCore::setUpButtonCell):
16229        (WebCore::button):
16230        (WebCore::paintButton):
16231        (WebCore::paintStepper):
16232        (WebCore::ThemeMac::inflateControlPaintRect):
16233        (WebCore::ThemeMac::paint):
16234        * rendering/RenderBlock.cpp:
16235        (WebCore::RenderBlock::addVisualOverflowFromTheme): Keep integral snapping for now.
16236        * rendering/RenderFlowThread.cpp:
16237        (WebCore::RenderFlowThread::addRegionsVisualOverflowFromTheme): Keep integral snapping for now.
16238        * rendering/RenderTheme.cpp:
16239        (WebCore::RenderTheme::paint):
16240        (WebCore::RenderTheme::adjustRepaintRect):
16241        * rendering/RenderTheme.h:
16242        * rendering/RenderThemeMac.h:
16243        * rendering/RenderThemeMac.mm:
16244        (WebCore::RenderThemeMac::adjustRepaintRect):
16245
162462014-06-12  Brent Fulgham  <bfulgham@apple.com>
16247
16248        [Win] Avoid fork bomb during build
16249        https://bugs.webkit.org/show_bug.cgi?id=133837
16250        <rdar://problem/17296034>
16251
16252        Reviewed by Tim Horton.
16253
16254        * WebCore.vcxproj/build-generated-files.sh: Use a reasonable
16255        default value when the 'num-cpus' script is not available.
16256
162572014-06-12  Gavin Barraclough  <barraclough@apple.com>
16258
16259        Add support for thread/WorkQueue QoS
16260        https://bugs.webkit.org/show_bug.cgi?id=130688
16261
16262        Reviewed by Anders Carlson & Simon Fraser.
16263
16264        WebCore's ScrollingThread should be UserInteractive.
16265
16266        * page/scrolling/ScrollingThread.cpp:
16267        (WebCore::ScrollingThread::threadCallback):
16268            - ScrollingThread should be UserInteractive
16269
162702014-06-12  Brent Fulgham  <bfulgham@apple.com>
16271
16272        [Mac] Build fix after r169919.
16273
16274        * WebCore.xcodeproj/project.pbxproj: The 'TileController.h' file must be a private header.
16275
162762014-06-12  Andy Estes  <aestes@apple.com>
16277
16278        [Mac] Speculative build fix after r169921.
16279
16280        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
16281        (WebCore::SourceBufferPrivateAVFObjC::destroyRenderers):
16282
162832014-06-12  Jer Noble  <jer.noble@apple.com>
16284
16285        [MSE][Mac] Stop observing the sample buffer renderers when destroying them.
16286        https://bugs.webkit.org/show_bug.cgi?id=133831
16287
16288        Reviewed by Beth Dakin.
16289
16290        Release our retain on our AVSampleBufferDisplayLayer and AVSampleBufferAudioRenderer by stopping
16291        our observation of its properties when removing them from the SourceBufferPrivateAVFObjC object.
16292
16293        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
16294        (WebCore::SourceBufferPrivateAVFObjC::destroyRenderers):
16295
162962014-06-12  Brent Fulgham  <bfulgham@apple.com>
16297
16298        Correct file locations after r169914. These should have been
16299        in platform/graphics/ca.
16300
16301        Rubberstamped by Tim Horton.
16302
16303        * WebCore.xcodeproj/project.pbxproj:
16304        * platform/graphics/ca/TileController.cpp: Copied from platform/graphics/ca/mac/TileController.cpp.
16305        * platform/graphics/ca/TileController.h: Copied from platform/graphics/ca/mac/TileController.h.
16306        * platform/graphics/ca/TileGrid.cpp: Copied from platform/graphics/ca/mac/TileGrid.cpp.
16307        * platform/graphics/ca/TileGrid.h: Copied from platform/graphics/ca/mac/TileGrid.h.
16308        * platform/graphics/ca/mac/TileController.cpp: Removed.
16309        * platform/graphics/ca/mac/TileController.h: Removed.
16310        * platform/graphics/ca/mac/TileGrid.cpp: Removed.
16311        * platform/graphics/ca/mac/TileGrid.h: Removed.
16312
163132014-06-12  Andy Estes  <aestes@apple.com>
16314
16315        Fix the build after r169913.
16316
16317        * loader/HistoryController.cpp:
16318        (WebCore::HistoryController::restoreScrollPositionAndViewState):
16319
163202014-06-12  Alex Christensen  <achristensen@webkit.org>
16321
16322        Collect correct web timing data from CFNetwork.
16323        https://bugs.webkit.org/show_bug.cgi?id=133824
16324        <rdar://problem/17273654>
16325
16326        Reviewed by Simon Fraser.
16327
16328        Covered by existing web timing tests.
16329
16330        * platform/network/mac/ResourceHandleMac.mm:
16331        (WebCore::ResourceHandle::getConnectionTimingData):
16332        Use _kCFNTimingDataFetchStart as the reference start time key.
16333
163342014-06-12  Brent Fulgham  <bfulgham@apple.com>
16335
16336        Convert TileController and TileGrid from ObjC to C++
16337        https://bugs.webkit.org/show_bug.cgi?id=133819
16338        <rdar://problem/17291841>
16339
16340        Reviewed by Tim Horton.
16341
16342        Convert TileGrid.mm and TileController.mm into C++ implementations. This required creating a 'frameForLayer'
16343        wrapper to call the 'frame' method of the CALayer object.
16344
16345        * WebCore.xcodeproj/project.pbxproj:
16346        * platform/graphics/ca/mac/TileController.cpp: Copied from platform/graphics/ca/mac/TileController.mm.
16347        (WebCore::TileController::blankPixelCountForTiles):
16348        * platform/graphics/ca/mac/TileController.mm: Removed.
16349        * platform/graphics/ca/mac/TileGrid.cpp: Copied from platform/graphics/ca/mac/TileGrid.mm.
16350        * platform/graphics/ca/mac/TileGrid.h:
16351        * platform/graphics/ca/mac/TileGrid.mm: Removed.
16352        * platform/graphics/mac/WebLayer.h:
16353        * platform/graphics/mac/WebLayer.mm:
16354        (WebCore::frameForLayer): Wrapper function to hide ObjC call from C++ compilation unit.
16355
163562014-06-12  Simon Fraser  <simon.fraser@apple.com>
16357
16358        [iOS WK2] Fix crash on back/foward swipe
16359        https://bugs.webkit.org/show_bug.cgi?id=133826
16360        <rdar://problem/17032752>
16361
16362        Reviewed by Tim Horton.
16363
16364        AsyncScrollingCoordinator::frameViewForScrollingNode() would crash with a null root
16365        state node, because HistoryController::restoreScrollPositionAndViewState() tried
16366        to restore scroll position (via restoreViewState()) before hooking up the scrolling
16367        coordinator.
16368        
16369        Fix by doing the scrollingCoordinator->frameViewRootLayerDidChange() before
16370        calling restoreViewState().
16371        
16372        Also add a defensive null-check on the root state node in updateScrollPositionAfterAsyncScrollTimerFired().
16373
16374        * loader/HistoryController.cpp:
16375        (WebCore::HistoryController::restoreScrollPositionAndViewState):
16376        * page/scrolling/AsyncScrollingCoordinator.cpp:
16377        (WebCore::AsyncScrollingCoordinator::frameViewForScrollingNode):
16378
163792014-06-12  Anders Carlsson  <andersca@apple.com>
16380
16381        Add a space after the comma.
16382
16383        * platform/network/HTTPHeaderMap.cpp:
16384        (WebCore::HTTPHeaderMap::add):
16385
163862014-06-12  Anders Carlsson  <andersca@apple.com>
16387
16388        Move header value merging to HTTPHeaderMap
16389        https://bugs.webkit.org/show_bug.cgi?id=133815
16390
16391        Reviewed by Andreas Kling.
16392
16393        * platform/network/HTTPHeaderMap.cpp:
16394        (WebCore::HTTPHeaderMap::set):
16395        (WebCore::HTTPHeaderMap::add):
16396        * platform/network/HTTPHeaderMap.h:
16397        * platform/network/ResourceRequestBase.cpp:
16398        (WebCore::ResourceRequestBase::addHTTPHeaderField):
16399        * platform/network/ResourceResponseBase.cpp:
16400        (WebCore::ResourceResponseBase::addHTTPHeaderField):
16401        * xml/XMLHttpRequest.cpp:
16402        (WebCore::XMLHttpRequest::setRequestHeaderInternal):
16403
164042014-06-12  Anders Carlsson  <andersca@apple.com>
16405
16406        Add ShapeValue.cpp and move ShapeValue::isImageValid() there
16407        https://bugs.webkit.org/show_bug.cgi?id=133809
16408
16409        Reviewed by Antti Koivisto.
16410
16411        This gets rid of CachedImage.h (and ResourceRequest and friends) from RenderStyle.h.
16412
16413        * CMakeLists.txt:
16414        * WebCore.vcxproj/WebCore.vcxproj:
16415        * WebCore.vcxproj/WebCore.vcxproj.filters:
16416        * WebCore.xcodeproj/project.pbxproj:
16417        * css/CSSComputedStyleDeclaration.cpp:
16418        (WebCore::shapePropertyValue):
16419        * css/CSSCrossfadeValue.cpp:
16420        * css/CSSFilterImageValue.cpp:
16421        * css/StyleResolver.h:
16422        * page/animation/CSSPropertyAnimation.cpp:
16423        (WebCore::blendFunc):
16424        * rendering/ShapeValue.cpp: Added.
16425        (WebCore::ShapeValue::isImageValid):
16426        * rendering/shapes/ShapeOutsideInfo.cpp:
16427        (WebCore::referenceBox):
16428        (WebCore::ShapeOutsideInfo::computedShape):
16429        (WebCore::ShapeOutsideInfo::isEnabledFor):
16430        * rendering/style/ShapeValue.h:
16431        (WebCore::ShapeValue::type):
16432        (WebCore::ShapeValue::setImage):
16433        (WebCore::ShapeValue::ShapeValue):
16434        (WebCore::ShapeValue::isImageValid): Deleted.
16435
164362014-06-12  Zalan Bujtas  <zalan@apple.com>
16437
16438        Subpixel rendering: Make <select> element's decoration subpixel aware.
16439        https://bugs.webkit.org/show_bug.cgi?id=133781
16440        <rdar://problem/17272083>
16441
16442        Reviewed by Simon Fraser.
16443
16444        Enable <select> decoration painting on subpixel positions.
16445        The theme size is still integral, but its position is snapped to device pixels.
16446        Theme's label, the InlineTextBox is already subpixel position aware.
16447        webkit.org/b/132005 tracks the rest of the themes.
16448
16449        Not testable.
16450
16451        * rendering/RenderTheme.cpp:
16452        (WebCore::RenderTheme::paint):
16453        * rendering/RenderTheme.h:
16454        (WebCore::RenderTheme::paintMenuList):
16455        * rendering/RenderThemeMac.h:
16456        * rendering/RenderThemeMac.mm:
16457        (WebCore::inflateRect):
16458        (WebCore::RenderThemeMac::adjustRepaintRect):
16459        (WebCore::RenderThemeMac::paintMenuList):
16460        (WebCore::RenderThemeMac::progressBarRectForBounds):
16461        (WebCore::RenderThemeMac::setPopupButtonCellState):
16462        (WebCore::RenderThemeMac::inflateRect): Deleted.
16463
164642014-06-12  Jer Noble  <jer.noble@apple.com>
16465
16466        [MSE][Mac] Crash in MediaSourcePrivateAVFObjC::naturalSize()
16467        https://bugs.webkit.org/show_bug.cgi?id=133789
16468
16469        Reviewed by Eric Carlson.
16470
16471        Add null-check to proctect against being queried for the naturalSize before we have a
16472        m_mediaSourcePrivate.
16473
16474        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
16475        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::naturalSize):
16476
164772014-06-12  Alberto Garcia  <berto@igalia.com>
16478
16479        [GTK] fails to build with --disable-webgl --disable-accelerated-compositing
16480        https://bugs.webkit.org/show_bug.cgi?id=131267
16481
16482        Reviewed by Philippe Normand.
16483
16484        Add missing headers needed for Float32Array::create().
16485
16486        * Modules/webaudio/AudioBuffer.cpp:
16487
164882014-06-12  Sergio Villar Senin  <svillar@igalia.com>
16489
16490        [GTK] REGRESSION: application name is not correctly appended to the UA
16491        https://bugs.webkit.org/show_bug.cgi?id=133793
16492
16493        Reviewed by Carlos Garcia Campos.
16494
16495        We must use a blank to separate the default UA provided by WebKitGtk
16496        from the application name coming from the public API.
16497
16498        Added an extra test case to the API tests to catch regressions.
16499
16500        * platform/gtk/UserAgentGtk.cpp:
16501        (WebCore::standardUserAgent):
16502
165032014-06-12  Zan Dobersek  <zdobersek@igalia.com>
16504
16505        WorkerRunLoop::Task::performTask should take in WorkerGlobalScope* to avoid downcasting
16506        https://bugs.webkit.org/show_bug.cgi?id=133616
16507
16508        Reviewed by Andreas Kling.
16509
16510        * workers/WorkerRunLoop.cpp:
16511        (WebCore::WorkerRunLoop::Task::performTask): Demand the context parameter to be a pointer
16512        to WorkerGlobalScope instead of ScriptExecutionContext, avoiding an unnecessary downcast.
16513        In the future this complete code path should use a reference to WorkerGlobalScope instead
16514        of a pointer.
16515        * workers/WorkerRunLoop.h:
16516
165172014-06-12  Sergio Villar Senin  <svillar@igalia.com>
16518
16519        [GTK] Unsupported browser in www.icloud.com
16520        https://bugs.webkit.org/show_bug.cgi?id=133403
16521
16522        Reviewed by Martin Robinson.
16523
16524        We claim to be Safari (among others) to ensure maximum
16525        compatibility with existing web sites. Valid Safari UA strings do
16526        always (since Safari 3.0) contain the string "Version/X" before
16527        the "Safari/X" part. We were wrongly only adding it in very
16528        specific cases and we were placing it at the wrong position as it
16529        must precede the "Safari/X" part.
16530
16531        From now on we unconditionally prepend the "Version/X" string to
16532        the "Safari/X" part as we always claim to be Safari. This makes
16533        the NeedsSafariVersion6 quirk invalid. This not only fixes
16534        "unsupported browser" issues in icloud.com, but also in
16535        globalforestwatch.com and live.com among many others.
16536
16537        Apart from that I'm bumping the Safari Version in the UA to 8.0 as
16538        we're already claiming to be "Safari/538.35"" which corresponds to
16539        Safari 8 beta.
16540
16541        * platform/gtk/UserAgentGtk.cpp:
16542        (WebCore::buildUserAgentString):
16543        (WebCore::standardUserAgentForURL):
16544
165452014-06-12  Pratik Solanki  <psolanki@apple.com>
16546
16547        Avoid creating a CFData when checking if a resource is file backed
16548        https://bugs.webkit.org/show_bug.cgi?id=133783
16549
16550        Reviewed by Andreas Kling.
16551
16552        Export SharedBuffer::hasPlatformData().
16553
16554        No new tests because no functional changes.
16555
16556        * WebCore.exp.in:
16557        * platform/SharedBuffer.h:
16558
165592014-06-11  Myles C. Maxfield  <mmaxfield@apple.com>
16560
16561        SVGGlyphToPathTranslator ASSERTs when encountering a missing glyph in an SVG font
16562        https://bugs.webkit.org/show_bug.cgi?id=133528
16563
16564        Reviewed by Simon Fraser.
16565
16566        Turns out this assertion is benign. We can take an early out of advance() (which
16567        is then handled properly by Font::dashesForIntersectionsWithRect()
16568
16569        Test: svg/custom/skip-underline-missing-glyph.html
16570
16571        * platform/graphics/mac/FontMac.mm:
16572        (WebCore::Font::dashesForIntersectionsWithRect): Rather than skip partial results,
16573        don't skip anything at all to be consistent.
16574        * rendering/svg/SVGTextRunRenderingContext.cpp:
16575        (WebCore::SVGGlyphToPathTranslator::advance): Take an early out to avoid an ASSERT.
16576
165772014-06-11  Simon Fraser  <simon.fraser@apple.com>
16578
16579        [iOS WK2] Give WebKitTestRunner a viewport configuration with initial scale=1 for testing
16580        https://bugs.webkit.org/show_bug.cgi?id=133779
16581
16582        Reviewed by Benjamin Poulain.
16583
16584        Add a "testing" viewport configuration with initial scale of 1.
16585
16586        * WebCore.exp.in:
16587        * page/ViewportConfiguration.cpp:
16588        (WebCore::ViewportConfiguration::testingParameters):
16589        * page/ViewportConfiguration.h:
16590
165912014-06-11  Pratik Solanki  <psolanki@apple.com>
16592
16593        Keep CFDataRefs in SharedBuffer instead of merging them
16594        https://bugs.webkit.org/show_bug.cgi?id=133775
16595
16596        Reviewed by Alexey Proskuryakov.
16597
16598        Instead of merging the CFDataRefs into one buffer, save them in as CFDataRefs in
16599        SharedBuffer. They will get merged when code calls buffer() later on.
16600
16601        No new tests because no functional changes.
16602
16603        * platform/network/cf/ResourceHandleCFNet.cpp:
16604        (WebCore::ResourceHandle::handleDataArray):
16605
166062014-06-11  Alexey Proskuryakov  <ap@apple.com>
16607
16608        editing/selection/selection-in-iframe-removed-crash.html or selection-invalid-offset.html crashes intermittently
16609        https://bugs.webkit.org/show_bug.cgi?id=111521
16610        <rdar://problem/15159351>
16611
16612        Reviewed by Brady Eidson.
16613
16614        Covered by existing tests.
16615
16616        * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::commitData): Bail out if the
16617        load was canceled from under receivedFirstData(). Since this is where we commit the
16618        load, there are ample opportunities for scripts or clients to do anything.
16619
166202014-06-11  Zalan Bujtas  <zalan@apple.com>
16621
16622        Subpixel rendering: RenderBox's content clipping should clip on device pixel boundary.
16623        https://bugs.webkit.org/show_bug.cgi?id=133767
16624        <rdar://problem/17272365>
16625
16626        Reviewed by Simon Fraser.
16627
16628        Push RenderBox's content clipping to device pixel boundaries. Integral snapping makes
16629        content cut off prematurely.
16630
16631        Test: fast/inline-block/hidpi-margin-top-with-subpixel-value-and-overflow-hidden.html
16632
16633        * rendering/RenderBox.cpp:
16634        (WebCore::RenderBox::pushContentsClip):
16635
166362014-06-11  Anders Carlsson  <andersca@apple.com>
16637
16638        Remove XHRReplayData::addHeader
16639        https://bugs.webkit.org/show_bug.cgi?id=133776
16640
16641        Reviewed by Antti Koivisto.
16642
16643        Just pass the HTTP header map to XHRReplayData::create directly.
16644
16645        * inspector/InspectorResourceAgent.cpp:
16646        (WebCore::InspectorResourceAgent::willLoadXHR):
16647        * inspector/NetworkResourcesData.cpp:
16648        (WebCore::XHRReplayData::create):
16649        (WebCore::XHRReplayData::XHRReplayData):
16650        (WebCore::XHRReplayData::addHeader): Deleted.
16651        * inspector/NetworkResourcesData.h:
16652
166532014-06-11  Andy Estes  <aestes@apple.com>
16654
16655        Fix the Mac build.
16656
16657        * WebCore.exp.in: Exported __ZN7WebCore19ResourceRequestBase15setHTTPReferrerERKN3WTF6StringE
16658        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: Moved ivar declarations to @interface to account for the 32-bit legacy runtime.
16659
166602014-06-11  Simon Fraser  <simon.fraser@apple.com>
16661
16662        Make FrameView 8 bytes smaller
16663        https://bugs.webkit.org/show_bug.cgi?id=133771
16664
16665        Reviewed by Anders Carlsson.
16666
16667        m_borderX and m_borderY were historical cruft.
16668
16669        * page/FrameView.cpp:
16670        (WebCore::FrameView::reset):
16671        * page/FrameView.h:
16672
166732014-06-11  David Kilzer  <ddkilzer@apple.com>
16674
16675        WindowFeatures arguments shoud ignore invalid characters in values
16676        <http://webkit.org/b/133703>
16677        <rdar://problem/17254118>
16678
16679        Reviewed by Andy Estes.
16680
16681        Test: fast/dom/Window/window-property-invalid-characters-ignored.html
16682
16683        * page/WindowFeatures.cpp:
16684        (WebCore::WindowFeatures::WindowFeatures): Set |length| based on
16685        |buffer|, not |features|.  Switch to using a for loop.  Switch
16686        to unsigned types since we are working with positive offsets
16687        into a String.
16688
166892014-06-11  David Kilzer  <ddkilzer@apple.com>
16690
16691        Viewport arguments should ignore invalid characters in values
16692        <http://webkit.org/b/133555>
16693        <rdar://problem/17179650>
16694
16695        Reviewed by Daniel Bates.
16696
16697        Test: fast/viewport/viewport-warnings-7.html
16698
16699        * dom/Document.cpp:
16700        (WebCore::Document::processArguments): Set |length| based on
16701        |buffer|, not |features|.  Switch to using a for loop.  Switch
16702        to unsigned types since we are working with positive offsets
16703        into a String.
16704
167052014-06-11  Anders Carlsson  <andersca@apple.com>
16706
16707        Move some HTTP header field accessors to ResourceRequestBase.cpp
16708        https://bugs.webkit.org/show_bug.cgi?id=133773
16709
16710        Reviewed by Andreas Kling.
16711
16712        This will avoid having to include HTTPHeaderNames.h from ResourceRequestBase.h.
16713
16714        * platform/network/ResourceRequestBase.cpp:
16715        (WebCore::ResourceRequestBase::httpContentType):
16716        (WebCore::ResourceRequestBase::setHTTPContentType):
16717        (WebCore::ResourceRequestBase::httpReferrer):
16718        (WebCore::ResourceRequestBase::setHTTPReferrer):
16719        (WebCore::ResourceRequestBase::httpOrigin):
16720        (WebCore::ResourceRequestBase::setHTTPOrigin):
16721        (WebCore::ResourceRequestBase::httpUserAgent):
16722        (WebCore::ResourceRequestBase::setHTTPUserAgent):
16723        (WebCore::ResourceRequestBase::httpAccept):
16724        (WebCore::ResourceRequestBase::setHTTPAccept):
16725        * platform/network/ResourceRequestBase.h:
16726        (WebCore::ResourceRequestBase::httpContentType): Deleted.
16727        (WebCore::ResourceRequestBase::setHTTPContentType): Deleted.
16728        (WebCore::ResourceRequestBase::httpReferrer): Deleted.
16729        (WebCore::ResourceRequestBase::setHTTPReferrer): Deleted.
16730        (WebCore::ResourceRequestBase::httpOrigin): Deleted.
16731        (WebCore::ResourceRequestBase::setHTTPOrigin): Deleted.
16732        (WebCore::ResourceRequestBase::httpUserAgent): Deleted.
16733        (WebCore::ResourceRequestBase::setHTTPUserAgent): Deleted.
16734        (WebCore::ResourceRequestBase::httpAccept): Deleted.
16735        (WebCore::ResourceRequestBase::setHTTPAccept): Deleted.
16736
167372014-06-11  Anders Carlsson  <andersca@apple.com>
16738
16739        Remove some more unneeded member functions from HTTPHeaderMap
16740        https://bugs.webkit.org/show_bug.cgi?id=133768
16741
16742        Reviewed by Simon Fraser.
16743
16744        * loader/CrossOriginAccessControl.cpp:
16745        (WebCore::createAccessControlPreflightRequest):
16746        * platform/network/HTTPHeaderMap.cpp:
16747        (WebCore::HTTPHeaderMap::find): Deleted.
16748        (WebCore::HTTPHeaderMap::keys): Deleted.
16749        * platform/network/HTTPHeaderMap.h:
16750
167512014-06-11  Jer Noble  <jer.noble@apple.com>
16752
16753        Unreviwed Mac release build fix; mark the keyPath parameter as unused.
16754
16755        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
16756        (-[WebAVSampleBufferErrorListener observeValueForKeyPath:ofObject:change:context:]):
16757
167582014-06-11  Brent Fulgham  <bfulgham@apple.com>
16759
16760        [Win] Avoid deadlock with AVFoundation
16761        https://bugs.webkit.org/show_bug.cgi?id=133762
16762        <rdar://problem/17128248>
16763
16764        Reviewed by Eric Carlson.
16765
16766        Always invoke our notifications asynchronously so that we do not
16767        execute long-running code while holding the AVFWrapper map mutex
16768        lock. AVFoundationCF callbacks can deadlock if we call into AVF
16769        while holding this lock.
16770
16771
16772        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
16773        (WebCore::MediaPlayerPrivateAVFoundation::scheduleMainThreadNotification):
16774
167752014-06-11  Csaba Osztrogonác  <ossy@webkit.org>
16776
16777        [CMake] One more URTBF after r169826.
16778
16779        * CMakeLists.txt: Generate files to the proper place.
16780
167812014-06-11  Csaba Osztrogonác  <ossy@webkit.org>
16782
16783        [CMake]URTBF after r169826.
16784
16785        * CMakeLists.txt: Typo fix.
16786
167872014-06-11  Anders Carlsson  <andersca@apple.com>
16788
16789        Get rid of an unneeded HTTPHeaderMap::remove overload
16790        https://bugs.webkit.org/show_bug.cgi?id=133763
16791
16792        Reviewed by Andreas Kling.
16793
16794        Change HTTPHeaderMap::remove to return whether an entry was removed or not and simplify
16795        ResourceRequestBase::clearHTTPAuthorization.
16796
16797        * platform/network/HTTPHeaderMap.cpp:
16798        (WebCore::HTTPHeaderMap::remove):
16799        * platform/network/HTTPHeaderMap.h:
16800        * platform/network/ResourceRequestBase.cpp:
16801        (WebCore::ResourceRequestBase::clearHTTPAuthorization):
16802
168032014-06-11  Jer Noble  <jer.noble@apple.com>
16804
16805        [EME][Mac] Propagate errors from AVSampleBufferDisplayLayer through to MSE
16806        https://bugs.webkit.org/show_bug.cgi?id=133747
16807
16808        Reviewed by Eric Carlson.
16809
16810        Abstract out the delivery of errors in MediaKeySession into its own method, which can be triggered by 
16811        CDMSession objects through the CDMSessionClient interface:
16812        * Modules/encryptedmedia/MediaKeySession.cpp:
16813        (WebCore::MediaKeySession::keyRequestTimerFired):
16814        (WebCore::MediaKeySession::addKeyTimerFired):
16815        (WebCore::MediaKeySession::sendMessage):
16816        (WebCore::MediaKeySession::sendError):
16817        * Modules/encryptedmedia/MediaKeySession.h:
16818        * Modules/mediasource/SourceBuffer.cpp:
16819        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveRenderingError):
16820        * Modules/mediasource/SourceBuffer.h:
16821        * platform/graphics/SourceBufferPrivateClient.h:
16822        * platform/graphics/CDMSession.h:
16823
16824        Add an Objective-C object which can listen for error KVO notifications:
16825        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
16826        (WebCore::SourceBufferPrivateAVFObjCErrorClient::~SourceBufferPrivateAVFObjCErrorClient):
16827        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
16828        (-[WebAVSampleBufferErrorListener initWithParent:WebCore::]):
16829        (-[WebAVSampleBufferErrorListener dealloc]):
16830        (-[WebAVSampleBufferErrorListener invalidate]):
16831        (-[WebAVSampleBufferErrorListener beginObservingLayer:]):
16832        (-[WebAVSampleBufferErrorListener stopObservingLayer:]):
16833        (-[WebAVSampleBufferErrorListener beginObservingRenderer:]):
16834        (-[WebAVSampleBufferErrorListener stopObservingRenderer:]):
16835        (-[WebAVSampleBufferErrorListener observeValueForKeyPath:ofObject:change:context:]):
16836        (-[WebAVSampleBufferErrorListener layerFailedToDecode:]):
16837        (WebCore::SourceBufferPrivateAVFObjC::SourceBufferPrivateAVFObjC):
16838        (WebCore::SourceBufferPrivateAVFObjC::trackDidChangeEnabled):
16839        (WebCore::SourceBufferPrivateAVFObjC::registerForErrorNotifications):
16840        (WebCore::SourceBufferPrivateAVFObjC::unregisterForErrorNotifications):
16841        (WebCore::SourceBufferPrivateAVFObjC::layerDidReceiveError):
16842        (WebCore::SourceBufferPrivateAVFObjC::rendererDidReceiveError):
16843
16844        Register for the new error notifications:
16845        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.h:
16846        (WebCore::CDMSessionMediaSourceAVFObjC::~CDMSessionMediaSourceAVFObjC): Moved to source file.
16847        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
16848        (WebCore::CDMSessionMediaSourceAVFObjC::CDMSessionMediaSourceAVFObjC): Register for error notifications.
16849        (WebCore::CDMSessionMediaSourceAVFObjC::~CDMSessionMediaSourceAVFObjC): Unregister for error notifications.
16850        (WebCore::CDMSessionMediaSourceAVFObjC::layerDidReceiveError): Pass through to CDMSessionClient.
16851        (WebCore::CDMSessionMediaSourceAVFObjC::rendererDidReceiveError): Ditto.
16852
168532014-06-11  Andreas Kling  <akling@apple.com>
16854
16855        Don't force CharacterData to override getOwnPropertySlot.
16856        <https://webkit.org/b/133717>
16857
16858        This was preventing us from taking the GetByVal fast path for Text nodes
16859        since they inherit from CharacterData and having a "length" attribute
16860        meant we gave them a custom getOwnPropertySlot, despite not actually
16861        needing it for anything.
16862
16863        Reviewed by Anders Carlsson.
16864
16865        * bindings/scripts/CodeGeneratorJS.pm:
16866        (AttributeShouldBeOnInstance):
16867
168682014-06-11  Anders Carlsson  <andersca@apple.com>
16869
16870        Add a script that generates a gperf hash for HTTP header names
16871        https://bugs.webkit.org/show_bug.cgi?id=133760
16872
16873        Reviewed by Andreas Kling.
16874
16875        This is the first step towards getting rid of AtomicString from HTTPHeaderMap.
16876
16877        * CMakeLists.txt:
16878        * DerivedSources.make:
16879        * WebCore.vcxproj/WebCore.vcxproj:
16880        * WebCore.xcodeproj/project.pbxproj:
16881        * platform/network/HTTPHeaderNames.in: Added.
16882        * platform/network/create-http-header-name-table: Added.
16883        (HTTPHeaderName):
16884
168852014-06-11  Brent Fulgham  <bfulgham@apple.com>
16886
16887        ROLLOUT: r153510: Broke Table borders on Wikipedia
16888        https://bugs.webkit.org/show_bug.cgi?id=132802
16889        <rdar://problem/16792562>
16890
16891        * rendering/RenderTableCell.cpp:
16892        (WebCore::RenderTableCell::paintCollapsedBorders):
16893        (WebCore::RenderTableCell::alignLeftRightBorderPaintRect): Deleted.
16894        (WebCore::RenderTableCell::alignTopBottomBorderPaintRect): Deleted.
16895        * rendering/RenderTableCell.h:
16896
168972014-06-11  peavo@outlook.com  <peavo@outlook.com>
16898
16899        [Curl] Empty headers in request response.
16900        https://bugs.webkit.org/show_bug.cgi?id=133483
16901
16902        Reviewed by Brent Fulgham.
16903
16904        When a request is taken from the cache, its cached response headers are empty, if the cache entry was created in the same session.
16905        It is only when the cache entry is loaded from disc, that the response headers are properly set.
16906        We need to set the cached response headers in both cases.
16907        There is also an issue if two jobs are loading the same url at the same time.
16908        Both jobs will then write to the cache content file, and create invalid content.
16909        This can be fixed by only letting the first request write to the content file.
16910
16911        * platform/network/curl/CurlCacheEntry.cpp:
16912        (WebCore::CurlCacheEntry::CurlCacheEntry):
16913        (WebCore::CurlCacheEntry::isLoading): Added method to check if cache entry is loading the content.
16914        (WebCore::CurlCacheEntry::saveResponseHeaders): Set the cached response headers when response is saved.
16915        (WebCore::CurlCacheEntry::invalidate): To be on the safe side, close content file when entry is invalidated.
16916        (WebCore::CurlCacheEntry::parseResponseHeaders): Made parameter const.
16917        * platform/network/curl/CurlCacheEntry.h: Keep track of which job is creating this cache entry.
16918        (WebCore::CurlCacheEntry::getJob):
16919        * platform/network/curl/CurlCacheManager.cpp:
16920        (WebCore::CurlCacheManager::loadIndex): When cache entry is loaded from disc, there is no associated job.
16921        (WebCore::CurlCacheManager::didReceiveResponse): Bail out if cache entry is already currently loading,
16922        otherwise associate this job with the new cache entry.
16923        (WebCore::CurlCacheManager::didFinishLoading): Changed parameter type.
16924        (WebCore::CurlCacheManager::isCached): Don't report the url as cached if it's currently loading content.
16925        (WebCore::CurlCacheManager::didReceiveData): Don't write to the content file if the entry is not associated with the job.
16926        (WebCore::CurlCacheManager::didFail): Changed parameter type.
16927        * platform/network/curl/CurlCacheManager.h: Changed parameter type.
16928        * platform/network/curl/ResourceHandleManager.cpp: Ditto.
16929        (WebCore::writeCallback):
16930        (WebCore::ResourceHandleManager::downloadTimerCallback):
16931
169322014-06-11  Sam Weinig  <sam@webkit.org>
16933
16934        REGRESSION (r133705): Layout Test js/dom/webidl-type-mapping.html is failing
16935        https://bugs.webkit.org/show_bug.cgi?id=133736
16936
16937        * bindings/scripts/CodeGeneratorJS.pm:
16938        (GenerateImplementation):
16939        Turns out we can't remove the HashTable yet after all, as JavaScriptCore
16940        relies on hasSetterOrReadonlyProperties bit to make put work correctly. We
16941        can, however, skip creating the table, and just use the value array during
16942        reification. 
16943
169442014-06-11  Chris Fleizach  <cfleizach@apple.com>
16945
16946        AX: iOS: VoiceOver ignores input type = date in Safari on iOS7
16947        https://bugs.webkit.org/show_bug.cgi?id=133709
16948
16949        Reviewed by Mario Sanchez Prada.
16950
16951        The date field on iOS appears as a popup button, which is not a type we had encountered for <input> types.
16952        This returns an appropriate role in that case.
16953
16954        * accessibility/AccessibilityRenderObject.cpp:
16955        (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
16956
169572014-06-11  Zan Dobersek  <zdobersek@igalia.com>
16958
16959        Avoid FontGlyphsCacheKey copy in FontGlyphsCacheEntry constructor
16960        https://bugs.webkit.org/show_bug.cgi?id=133674
16961
16962        Reviewed by Andreas Kling.
16963
16964        * platform/graphics/Font.cpp:
16965        (WebCore::FontGlyphsCacheEntry::FontGlyphsCacheEntry): The FontGlyphsCacheKey
16966        variable is already passed-in as an rvalue reference, so it should be moved
16967        into the constructor of the corresponding member variable instead of copied.
16968
169692014-06-11  Andy Estes  <aestes@apple.com>
16970
16971        Fix the build after after r169789 on platforms that build with -Wunused-const-variable
16972
16973        * bindings/scripts/CodeGeneratorJS.pm:
16974        (GenerateHashTable): Don't create the value array if it'll never be used.
16975
169762014-06-11  Carlos Garcia Campos  <cgarcia@igalia.com>
16977
16978        [GTK] Use a different user agent string depending on the site
16979        https://bugs.webkit.org/show_bug.cgi?id=132681
16980
16981        Reviewed by Anders Carlsson.
16982
16983        We have changed the user agent string several times to try to fix
16984        broken websites that require specific things in the UA string to
16985        properly work. But everytime we change the UA string to fix a
16986        website we break others. We could use different UA string
16987        depending on the website. UserAgentGtk code has also been cleaned
16988        up, using NeverDestroyed instead of DEPRECATED_DEFINE_STATIC_LOCAL
16989        and avoiding unneeded conversions to UTF-8.
16990
16991        * platform/gtk/UserAgentGtk.cpp:
16992        (WebCore::UserAgentQuirks::UserAgentQuirks): New helper private
16993        class to handle user agent quirks.
16994        (WebCore::UserAgentQuirks::add):
16995        (WebCore::UserAgentQuirks::contains):
16996        (WebCore::UserAgentQuirks::isEmpty):
16997        (WebCore::platformForUAString): Bring back this method that was
16998        removed to always pretend to be Macintosh.
16999        (WebCore::platformVersionForUAString): Return a different platform
17000        version depending on the actual platform.
17001        (WebCore::versionForUAString): Return the WebKit version.
17002        (WebCore::buildUserAgentString): Helper function to build the user
17003        agent taking into account the UserAgentQuirks received.
17004        (WebCore::standardUserAgentStatic): Standard user agent string
17005        when no quirks are present.
17006        (WebCore::standardUserAgent):
17007        (WebCore::standardUserAgentForURL): New method that returns the
17008        user agent string for the given URL.
17009        * platform/gtk/UserAgentGtk.h:
17010
170112014-06-11  Alex Christensen  <achristensen@webkit.org>
17012
17013        [Win] Unreviewed build fix.
17014
17015        * platform/network/curl/ResourceRequest.h:
17016        Include missing PassOwnPtr.h.
17017
170182014-06-10  Sam Weinig  <sam@webkit.org>
17019
17020        Actually only generate tables for History and Location.
17021
17022        * bindings/scripts/CodeGeneratorJS.pm:
17023        (GenerateImplementation):
17024
170252014-06-10  Sam Weinig  <sam@webkit.org>
17026
17027        Attempt to fix the tests.
17028
17029        * bindings/scripts/CodeGeneratorJS.pm:
17030        (GenerateImplementation):
17031        Keep generating HashTables for History and Location, since they use them in
17032        their custom getOwnPropertySlot delegates.
17033
170342014-06-10  Benjamin Poulain  <benjamin@webkit.org>
17035
17036        [iOS][WK2] ScrollingTreeOverflowScrollingNode does not use asynchronous touch dispatch
17037        https://bugs.webkit.org/show_bug.cgi?id=133702
17038
17039        Reviewed by Simon Fraser.
17040
17041        * page/scrolling/ScrollingTree.h:
17042        (WebCore::ScrollingTree::scrollingTreeNodeWillStartPanGesture):
17043
170442014-06-10  Benjamin Poulain  <benjamin@webkit.org>
17045
17046        Reduce the overhead of updating the animatable style on ARMv7
17047        https://bugs.webkit.org/show_bug.cgi?id=133618
17048
17049        Reviewed by Simon Fraser.
17050
17051        While updating the style for animations, most of the time spent was pure calling overhead.
17052
17053        This patch should reduce this a bit on ARMv7:
17054        1) Get the frame directly from the document instead of document->view->framview->frame.
17055        2) Inline RenderObject::animation(). This is just 3 loads, setting up the registers on the call
17056           site is more expensive than loading the values directly.
17057        3) Inline RenderElement::setAnimatableStyle(). It has only one call site and the call is mostly
17058           overhead.
17059
17060        * css/CSSComputedStyleDeclaration.cpp:
17061        * rendering/RenderElement.cpp:
17062        (WebCore::RenderElement::setAnimatableStyle): Deleted.
17063        * rendering/RenderElement.h:
17064        (WebCore::RenderElement::setAnimatableStyle):
17065        * rendering/RenderObject.cpp:
17066        (WebCore::RenderObject::adjustRectForOutlineAndShadow):
17067        (WebCore::RenderObject::animation): Deleted.
17068        * rendering/RenderObject.h:
17069        (WebCore::RenderObject::animation):
17070        * rendering/RenderView.h:
17071        (WebCore::RenderObject::frame):
17072
170732014-06-10  Sam Weinig  <sam@webkit.org>
17074
17075        Don't create a HashTable for JSObjects that use eager reification
17076        https://bugs.webkit.org/show_bug.cgi?id=133705
17077
17078        Reviewed by Geoffrey Garen.
17079
17080        It is unnecessary to create the CompactHashIndex or HashTable for JSObjects
17081        that use eager reification, since we will never look up properties directly.
17082        Instead, we can iterate the HashTableValue array directly during reification.
17083
17084        * bindings/scripts/CodeGeneratorJS.pm:
17085        (GenerateImplementation):
17086        Only generate the value array for prototypes that use eager reification.
17087
17088        (GenerateHashTableValueArray):
17089        Extract out into a helper.
17090
17091        (GenerateHashTable):
17092        Add a parameter, $justGenerateValueArray, that if true, means we only
17093        should generate the value array. 
17094
17095        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
17096        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
17097        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
17098        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
17099        * bindings/scripts/test/JS/JSTestException.cpp:
17100        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
17101        * bindings/scripts/test/JS/JSTestInterface.cpp:
17102        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
17103        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
17104        * bindings/scripts/test/JS/JSTestNode.cpp:
17105        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
17106        * bindings/scripts/test/JS/JSTestObj.cpp:
17107        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
17108        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
17109        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
17110        * bindings/scripts/test/JS/JSattribute.cpp:
17111        * bindings/scripts/test/JS/JSreadonly.cpp:
17112
171132014-06-10  Chris Fleizach  <cfleizach@apple.com>
17114
17115        AX: iOS: Return the language for attributed text marker queries
17116        https://bugs.webkit.org/show_bug.cgi?id=133682
17117
17118        Reviewed by Mario Sanchez Prada.
17119
17120        Add language to the list of objects being returned for attributed text.
17121
17122        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
17123        (AXAttributeStringSetLanguage):
17124        (AXAttributedStringAppendText):
17125
171262014-06-10  Dan Bernstein  <mitz@apple.com>
17127
17128        WebCore part of [Cocoa] Handling authentication challenges should not require multiple delegate methods
17129        https://bugs.webkit.org/show_bug.cgi?id=133697
17130
17131        Reviewed by Anders Carlsson.
17132
17133        * platform/network/AuthenticationClient.h: Declared new virtual member functions for
17134        requesting default handling of a challenge and rejecting a challenge.
17135        * platform/network/ResourceHandle.h: Override new AuthenticationClient functions.
17136        * platform/network/cf/ResourceHandleCFNet.cpp:
17137        (WebCore::ResourceHandle::receivedRequestToPerformDefaultHandling): Added. Calls
17138        CFURLConnectionPerformDefaultHandlingForChallenge.
17139        (WebCore::ResourceHandle::receivedChallengeRejection): Added. Calls
17140        CFURLConnectionRejectChallenge.
17141        * platform/network/cf/SocketStreamHandle.h: Override new AuthenticationClient functions.
17142        * platform/network/cf/SocketStreamHandleCFNet.cpp:
17143        (WebCore::SocketStreamHandle::receivedRequestToPerformDefaultHandling): Added empty
17144        override.
17145        (WebCore::SocketStreamHandle::receivedChallengeRejection): Ditto.
17146
171472014-06-09  Brent Fulgham  <bfulgham@apple.com>
17148
17149        REGRESSION (r167962): Out of bounds read in JSC::StructureIDTable::get()
17150        https://bugs.webkit.org/show_bug.cgi?id=133463
17151        <rdar://problem/17098100>
17152
17153        Reviewed by Geoffrey Garen.
17154
17155        Revise MediaControllerHost implementation so that instead of holding its
17156        own pointer to the JS Controller object, it uses new properties added to
17157        the internal media controls DOM hierarchy. This allows the GC to see the
17158        needed lifecycle of the various media control objects and avoids the
17159        premature deallocation that caused this bug.
17160 
17161        * Modules/mediacontrols/MediaControlsHost.h:
17162        (WebCore::MediaControlsHost::controllerJSValue): Deleted.
17163        (WebCore::MediaControlsHost::setControllerJSValue): Deleted.
17164        * html/HTMLMediaElement.cpp:
17165        (WebCore::HTMLMediaElement::controllerJSValue): Added convenience function
17166        to share logic for retrieving the controller object.
17167        (WebCore::HTMLMediaElement::updateCaptionContainer): Revise to use new method
17168        for accessing the controller.
17169        (WebCore::HTMLMediaElement::didAddUserAgentShadowRoot): Connect the media
17170        elements JS wrapper object to the MediaControlsHost JS wrapper. Then connect
17171        the MediaControlsHost JS wrapper to the Controller JS object.
17172        (WebCore::HTMLMediaElement::pageScaleFactorChanged): Revise to use new method
17173        for accessing the controller.
17174
171752014-06-10  Myles C. Maxfield  <mmaxfield@apple.com>
17176
17177        Japanese text in Google search is rendered too low and clipped
17178        https://bugs.webkit.org/show_bug.cgi?id=133595
17179
17180        Reviewed by Simon Fraser.
17181
17182        This is a revert of r155324.
17183
17184        By forcing line-height to be normal, r155324 was forcing WebKit to inspect font metrics
17185        to determine the height of a line. This means that if a fallback font was required to
17186        draw a line of text, and the fallback font had a higher ascent than the primary font,
17187        the entire line of text would be pushed down. If we don't force line-height to be normal,
17188        then we use the line-height value instead, which short circuits this mechanism, thereby
17189        not pushing text down.
17190
17191        No new tests (because this is simply a revert)
17192
17193        * css/html.css:
17194        (input): Deleted.
17195
171962014-06-10  Zalan Bujtas  <zalan@apple.com>
17197
17198        REGRESSION (r167937): Do not use effective zoom factor while resolving media query's min-, max-(device)width/height values.
17199        https://bugs.webkit.org/show_bug.cgi?id=133681
17200
17201        Reviewed by Simon Fraser.
17202
17203        We lost the default multiplier(zoom) value of 1 with r167937 at template<typename T> T computeLength().
17204        Now MediaQueryEvaluator takes the current page zoom factor into account while resolving min-, max- width values.
17205
17206        This patch explicitly sets the multiplier value to 1 to ensure zoom independent media query value resolving.
17207
17208        Test: fast/media/media-query-with-scaled-content.html
17209
17210        * css/CSSToLengthConversionData.cpp:
17211        (WebCore::CSSToLengthConversionData::viewportWidthFactor):
17212        (WebCore::CSSToLengthConversionData::viewportHeightFactor):
17213        * css/CSSToLengthConversionData.h:
17214        * css/MediaQueryEvaluator.cpp:
17215        (WebCore::MediaQueryEvaluator::eval):
17216        * testing/Internals.cpp:
17217        (WebCore::Internals::setPageZoomFactor):
17218        * testing/Internals.h:
17219        * testing/Internals.idl:
17220
172212014-06-10  Simon Fraser  <simon.fraser@apple.com>
17222
17223        https://bugs.webkit.org/show_bug.cgi?id=133694
17224
17225        Revert the part of r169733 that caused this test to start failing.
17226
17227        * rendering/RenderLayerCompositor.cpp:
17228        (WebCore::RenderLayerCompositor::notifyIFramesOfCompositingChange):
17229
172302014-06-10  Timothy Horton  <timothy_horton@apple.com>
17231
17232        Factor repeated CFRunLoopObserver code out
17233        https://bugs.webkit.org/show_bug.cgi?id=133690
17234
17235        Reviewed by Simon Fraser.
17236
17237        * WebCore.exp.in:
17238        * WebCore.xcodeproj/project.pbxproj:
17239        * platform/cf/RunLoopObserver.cpp: Added.
17240        (WebCore::RunLoopObserver::create):
17241        (WebCore::RunLoopObserver::~RunLoopObserver):
17242        (WebCore::RunLoopObserver::runLoopObserverFired):
17243        (WebCore::RunLoopObserver::schedule):
17244        (WebCore::RunLoopObserver::invalidate):
17245        * platform/cf/RunLoopObserver.h: Added.
17246        (WebCore::RunLoopObserver::isScheduled):
17247        (WebCore::RunLoopObserver::RunLoopObserver):
17248        Factor CFRunLoopObserver management code out of LayerFlushScheduler and WebKit2.
17249
17250        * platform/graphics/ca/LayerFlushScheduler.h:
17251        * platform/graphics/ca/mac/LayerFlushSchedulerMac.cpp:
17252        (WebCore::LayerFlushScheduler::LayerFlushScheduler):
17253        (WebCore::LayerFlushScheduler::~LayerFlushScheduler):
17254        (WebCore::LayerFlushScheduler::layerFlushCallback):
17255        (WebCore::LayerFlushScheduler::schedule):
17256        (WebCore::LayerFlushScheduler::invalidate):
17257        (WebCore::LayerFlushScheduler::runLoopObserverCallback): Deleted.
17258        Make use of WebCore::RunLoopObserver.
17259
172602014-06-10  Simon Fraser  <simon.fraser@apple.com>
17261
17262        Modernize loop code in scrolling tree code
17263        https://bugs.webkit.org/show_bug.cgi?id=133688
17264
17265        Reviewed by Anders Carlsson.
17266
17267        Use new loop syntax for walking children.
17268
17269        * page/scrolling/ScrollingStateNode.cpp:
17270        (WebCore::ScrollingStateNode::cloneAndResetChildren):
17271        (WebCore::ScrollingStateNode::removeChild):
17272        (WebCore::ScrollingStateNode::willBeRemovedFromStateTree):
17273        (WebCore::ScrollingStateNode::dump):
17274        * page/scrolling/ScrollingTreeNode.cpp:
17275        (WebCore::ScrollingTreeNode::removeChild):
17276        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
17277        (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollLayerPosition):
17278
172792014-06-10  Anders Carlsson  <andersca@apple.com>
17280
17281        Add -[WKWebView evaluateJavaScript:completionHandler:]
17282        https://bugs.webkit.org/show_bug.cgi?id=133689
17283        <rdar://problem/17152685>
17284
17285        Reviewed by Geoffrey Garen.
17286
17287        * English.lproj/Localizable.strings:
17288        Add new localizable strings.
17289
172902014-06-10  Antti Koivisto  <antti@apple.com>
17291
17292        Serialize ResourceRequests without platform request
17293        https://bugs.webkit.org/show_bug.cgi?id=133679
17294
17295        Reviewed by Alexey Proskuryakov.
17296
17297        We create platform requests in the web process just so we can serialize them. This is unnecessary work.
17298
17299        * platform/network/ResourceRequestBase.h:
17300        (WebCore::ResourceRequestBase::encodingRequiresPlatformData):
17301        (WebCore::ResourceRequestBase::encodeWithoutPlatformData):
17302        (WebCore::ResourceRequestBase::decodeWithoutPlatformData):
17303        
17304            Add encoding and decoding functions here to avoid exposing internals.
17305
17306        * platform/network/cf/ResourceRequest.h:
17307        (WebCore::ResourceRequest::encodingRequiresPlatformData):
17308        
17309            Allow encoding without platform data if it hasn't been created yet and there is no request body.
17310
173112014-06-10  Brady Eidson  <beidson@apple.com>
17312
17313        Send more context about text selection to telephone number scanner
17314        <rdar://problem/16874385> and https://bugs.webkit.org/show_bug.cgi?id=133684
17315
17316        Reviewed by Enrica Casucci.
17317
17318        * dom/Range.cpp:
17319        (WebCore::rangesOverlap):Add a utility to check if two ranges overlap.
17320        * dom/Range.h:
17321        
17322        * editing/Editor.cpp:
17323        (WebCore::Editor::scanSelectionForTelephoneNumbers): Create a range that is wider than the 
17324          actual selection to search for phone numbers that are not completely selected yet.
17325
173262014-06-10  Alex Christensen  <achristensen@webkit.org>
17327
17328        [iOS] Another unreviewed build fix after r169746.
17329
17330        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
17331        Prevent another unused value error.
17332
173332014-06-10  Alex Christensen  <achristensen@webkit.org>
17334
17335        [iOS] Unreviewed build fix after r169746.
17336
17337        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
17338        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
17339        Protect startTime with !PLATFORM(IOS) to prevent a unused variable build error.
17340
173412014-06-10  Chris Fleizach  <cfleizach@apple.com>
17342
17343        AX: WK2: iOS: text editing does not work
17344        https://bugs.webkit.org/show_bug.cgi?id=133666
17345
17346        Reviewed by Mario Sanchez Prada.
17347
17348        In WK2, all the text editing is handled by the WebProcess, so selectedTextRange and setSelectedTextRange
17349        need to be implemented, as well as posting the right value change notification.
17350
17351        * accessibility/ios/AXObjectCacheIOS.mm:
17352        (WebCore::AXObjectCache::postPlatformNotification):
17353        * accessibility/ios/WebAccessibilityObjectWrapperIOS.h:
17354        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
17355        (-[WebAccessibilityObjectWrapper postValueChangedNotification]):
17356        (-[WebAccessibilityObjectWrapper _accessibilitySelectedTextRange]):
17357        (-[WebAccessibilityObjectWrapper _accessibilitySetSelectedTextRange:]):
17358
173592014-06-10  Andreas Kling  <akling@apple.com>
17360
17361        [iOS WebKit2] Stay in "memory pressure" mode until told otherwise.
17362        <https://webkit.org/b/133671>
17363
17364        When we receive the first memory pressure signal, flip the flag in
17365        MemoryPressureHandler so that isUnderMemoryPressure() returns true
17366        from then on, until the system tells us pressure levels are back
17367        to normal.
17368
17369        The hold-off mechanism is disabled for iOS, that wasn't actually
17370        needed in the first place, since the system is not going to spam
17371        you with tons of notifications.
17372
17373        Also propagate the "critical" flag all the way from the system
17374        to the pressure handler. Note that we don't actually do anything
17375        differently based on the flag yet.
17376
17377        Reviewed by Sam Weinig.
17378
17379        * platform/MemoryPressureHandler.cpp:
17380        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
17381        * platform/MemoryPressureHandler.h:
17382        (WebCore::MemoryPressureHandler::setUnderMemoryPressure):
17383        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
17384        (WebCore::MemoryPressureHandler::install):
17385        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
17386
173872014-06-10  Simon Fraser  <simon.fraser@apple.com>
17388
17389        Fix logging of sticky scrolling tree nodes
17390        https://bugs.webkit.org/show_bug.cgi?id=133670
17391
17392        Reviewed by Sam Weinig.
17393
17394        ScrollingStateStickyNode::dumpProperties() dumped stickyBoxRect() twice and
17395        didn't dump constrainingRectAtLastLayout(), so fix that.
17396
17397        * page/scrolling/ScrollingStateStickyNode.cpp:
17398        (WebCore::ScrollingStateStickyNode::dumpProperties):
17399
174002014-06-05  Sergio Villar Senin  <svillar@igalia.com>
17401
17402        [CSS Grid Layout] Simplify the named grid lines resolution algorithm
17403        https://bugs.webkit.org/show_bug.cgi?id=133543
17404
17405        Reviewed by Darin Adler.
17406
17407        Named grid lines resolution algorithm can be heavily simplified by
17408        inserting the implicit named grid lines generated by each grid
17409        area (<area-name>-{start|end} for rows and columns), into the list
17410        of user defined named grid lines. This way we would only have to
17411        deal with named grid lines and forget about the named grid areas
17412        (as described in the specs
17413        http://dev.w3.org/csswg/css-grid/#grid-placement-slot).
17414
17415        As a nice side effect, we'll get for free the implementation of the
17416        use case described in section 5.2.2 Implicit Named Areas.
17417
17418        Test: fast/css-grid-layout/named-grid-lines-with-named-grid-areas-dynamic-get-set.html
17419
17420        * css/StyleResolver.cpp:
17421        (WebCore::createImplicitNamedGridLinesFromGridArea):
17422        (WebCore::StyleResolver::applyProperty):
17423        * rendering/RenderGrid.cpp:
17424        (WebCore::isStartSide):
17425        (WebCore::gridLinesForSide):
17426        (WebCore::implicitNamedGridLineForSide):
17427        (WebCore::isNonExistentNamedLineOrArea):
17428        (WebCore::RenderGrid::adjustGridPositionsFromStyle):
17429        (WebCore::RenderGrid::resolveNamedGridLinePositionFromStyle):
17430        (WebCore::RenderGrid::resolveGridPositionFromStyle):
17431        (WebCore::RenderGrid::resolveNamedGridLinePositionAgainstOppositePosition):
17432        (WebCore::gridLineDefinedBeforeGridArea): Deleted.
17433        (WebCore::setNamedLinePositionIfDefinedBeforeArea): Deleted.
17434        (WebCore::RenderGrid::adjustNamedGridItemPosition): Deleted.
17435
174362014-06-10  Kiran  <kiran.guduru@samsung.com>
17437
17438        [MediaStream] Add getTracks() support to MediaStream.
17439        https://bugs.webkit.org/show_bug.cgi?id=133641
17440
17441        Reviewed by Eric Carlson.
17442
17443        A new method named getTracks is proposed to retrieve all the tracks
17444        of a MediaStream irrespective of the type. This method has been implementd.
17445
17446        Test: fast/mediastream/MediaStream-getTracks.html
17447
17448        * Modules/mediastream/MediaStream.cpp:
17449        (WebCore::MediaStream::getTracks):
17450        * Modules/mediastream/MediaStream.h:
17451        * Modules/mediastream/MediaStream.idl:
17452
174532014-06-09  Simon Fraser  <simon.fraser@apple.com>
17454
17455        Remove use of view() in RenderView code
17456        https://bugs.webkit.org/show_bug.cgi?id=133669
17457
17458        Reviewed by Andreas Kling.
17459
17460        view() in RenderView just returns *this, so no need to use it.
17461
17462        * rendering/RenderView.cpp:
17463        (WebCore::RenderView::setSelection):
17464
174652014-06-09  Eric Carlson  <eric.carlson@apple.com>
17466
17467        [iOS] Wireless route picker control should use touch event handlers
17468        https://bugs.webkit.org/show_bug.cgi?id=133672
17469
17470        Reviewed by Brent Fulgham.
17471
17472        * Modules/mediacontrols/mediaControlsiOS.js:
17473        (ControllerIOS.prototype.createControls): Listen for touch events.
17474        (ControllerIOS.prototype.handleWirelessPickerButtonTouchStart): New, handle touch start.
17475        (ControllerIOS.prototype.handleWirelessPickerButtonTouchEnd): New, handle touch end.
17476        (ControllerIOS.prototype.handleWirelessPickerButtonTouchCancel): New, handle touch cancel.
17477        (ControllerIOS.prototype.handleWirelessPickerButtonClicked): Deleted.
17478
174792014-06-09  Benjamin Poulain  <benjamin@webkit.org>
17480
17481        Do not use a mask when matching the return value of a function call on ARM
17482        https://bugs.webkit.org/show_bug.cgi?id=133614
17483
17484        Reviewed by Andreas Kling.
17485
17486        On ARM, we cannot have garbage on the top bits of booleans. It is faster to check the whole
17487        register for nullity.
17488
17489        * cssjit/FunctionCall.h:
17490        (WebCore::FunctionCall::callAndBranchOnBooleanReturnValue):
17491        (WebCore::FunctionCall::callAndBranchOnCondition):
17492        * cssjit/SelectorCompiler.cpp:
17493        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueExactMatching):
17494        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeFunctionCallValueMatching):
17495        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementFunctionCallTest):
17496        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsActive):
17497        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsHovered):
17498
174992014-06-09  Ryosuke Niwa  <rniwa@webkit.org>
17500
17501        Remove the bogus assertion that didn't even build.
17502
17503        * css/CSSPrimitiveValue.cpp:
17504        (WebCore::CSSPrimitiveValue::formatNumberValue):
17505
175062014-06-09  Ryosuke Niwa  <rniwa@webkit.org>
17507
17508        Commit the right fix.
17509
17510        * css/CSSPrimitiveValue.cpp:
17511        (WebCore::CSSPrimitiveValue::formatNumberValue):
17512
175132014-06-09  Ryosuke Niwa  <rniwa@webkit.org>
17514
17515        Debug build fix after r169731.
17516
17517        * css/CSSPrimitiveValue.cpp:
17518        (WebCore::CSSPrimitiveValue::formatNumberValue):
17519
175202014-06-09  Simon Fraser  <simon.fraser@apple.com>
17521
17522        Work towards having frames in the scrolling tree
17523        https://bugs.webkit.org/show_bug.cgi?id=133665
17524
17525        Reviewed by Tim Horton.
17526        
17527        Optionally (based on Setting) create nodes in the scrolling tree for frames which
17528        contain async-scrollable content. This will be used on iOS/WK2 to support accelerated
17529        overflow-scroll in iframes. The setting allows for testing on OS X.
17530        
17531        The change breaks an assumption in ScrollingCoordinator/AsyncScrollingCoordinator
17532        that we're always dealing with the main frame, and changes logic in RenderLayerCompositor
17533        so that we can connect the scrolling tree across frame boundaries. RenderLayerCompositor
17534        maintains a m_subframeScrollLayersNeedReattach flag that gets set whenever we add or remove
17535        scroll-coordinated layers in the current frame. When set, after updating compositing
17536        layers we walk child frames, and, if they have scrolling nodes, re-attach them to the
17537        scrolling tree (which will find the new ancestor node).
17538
17539        Tests: platform/mac-wk2/tiled-drawing/scrolling/frames/coordinated-frame-in-fixed.html
17540               platform/mac-wk2/tiled-drawing/scrolling/frames/coordinated-frame.html
17541
17542        * WebCore.exp.in:
17543        * page/FrameView.cpp:
17544        (WebCore::FrameView::scrollLayerID): Use the new "for role" way of getting the node ID.
17545        * page/Settings.cpp:
17546        * page/Settings.in: Add scrollingTreeIncludesFrames.
17547        * page/scrolling/AsyncScrollingCoordinator.cpp:
17548        (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
17549        (WebCore::AsyncScrollingCoordinator::frameViewNonFastScrollableRegionChanged): Only set
17550        the region for the main frame.
17551        (WebCore::AsyncScrollingCoordinator::frameViewForScrollingNode): updateScrollPositionAfterAsyncScroll()
17552        needs to know which FrameView a given nodeID is hosted in; doing a walk of the frame tree for
17553        non-main frames seems to be the safest way.
17554        (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
17555        (WebCore::AsyncScrollingCoordinator::syncChildPositions):
17556        * page/scrolling/AsyncScrollingCoordinator.h:
17557        * page/scrolling/ScrollingCoordinator.cpp:
17558        (WebCore::ScrollingCoordinator::coordinatesScrollingForFrameView): Consult the new setting.
17559        (WebCore::ScrollingCoordinator::frameViewHasSlowRepaintObjectsDidChange):
17560        (WebCore::ScrollingCoordinator::frameViewFixedObjectsDidChange):
17561        (WebCore::ScrollingCoordinator::frameViewRootLayerDidChange):
17562        (WebCore::ScrollingCoordinator::synchronousScrollingReasons):
17563        (WebCore::ScrollingCoordinator::updateSynchronousScrollingReasons):
17564        (WebCore::ScrollingCoordinator::setForceSynchronousScrollLayerPositionUpdates):
17565        (WebCore::ScrollingCoordinator::shouldUpdateScrollLayerPositionSynchronously):
17566        (WebCore::ScrollingCoordinator::replaySessionStateDidChange):
17567        (WebCore::ScrollingCoordinator::synchronousScrollingReasonsAsText):
17568        * page/scrolling/ScrollingCoordinator.h:
17569        (WebCore::ScrollingCoordinator::shouldUpdateScrollLayerPositionSynchronously): Deleted.
17570        * rendering/RenderLayerBacking.h: Rather than separate functions to get the two scrolling
17571        node IDs, having one scrollingNodeIDForRole() makes calling code cleaner.
17572        * rendering/RenderLayerCompositor.cpp:
17573        (WebCore::RenderLayerCompositor::RenderLayerCompositor):
17574        (WebCore::RenderLayerCompositor::updateCompositingLayers):  call reattachSubframeScrollLayers()
17575        after a compositing tree update.
17576        (WebCore::RenderLayerCompositor::isAsyncScrollableStickyLayer): Deals with the various configurations
17577        in which we can do async scrolling of sticky elements.
17578        (WebCore::RenderLayerCompositor::isViewportConstrainedFixedOrStickyLayer):
17579        (WebCore::useCoordinatedScrollingForLayer):
17580        (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
17581        (WebCore::RenderLayerCompositor::requiresCompositingForScrolling): Moved.
17582        (WebCore::RenderLayerCompositor::notifyIFramesOfCompositingChange): This is a bug fix;
17583        we only need to notify child frames, not all descendant frames.
17584        (WebCore::RenderLayerCompositor::updateScrollCoordinatedStatus):
17585        (WebCore::RenderLayerCompositor::removeFromScrollCoordinatedLayers):
17586        (WebCore::enclosingScrollingNodeID):
17587        (WebCore::scrollCoordinatedAncestorInParentOfFrame):
17588        (WebCore::RenderLayerCompositor::reattachSubframeScrollLayers):
17589        (WebCore::RenderLayerCompositor::attachScrollingNode):
17590        (WebCore::RenderLayerCompositor::updateScrollCoordinationForThisFrame):
17591        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
17592        (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer):
17593        (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
17594        (WebCore::RenderLayerCompositor::willRemoveScrollingLayer):
17595        (WebCore::isStickyInAcceleratedScrollingLayerOrViewport): Deleted.
17596        (WebCore::isViewportConstrainedFixedOrStickyLayer): Deleted.
17597        (WebCore::isMainFrameScrollingOrOverflowScrolling): Deleted.
17598        (WebCore::nearestScrollCoordinatedAncestor): Deleted.
17599        * rendering/RenderLayerCompositor.h:
17600        * rendering/RenderView.cpp:
17601        (WebCore::RenderView::setSelection): Added comment.
17602        * testing/InternalSettings.cpp:
17603        (WebCore::InternalSettings::setScrollingTreeIncludesFrames):
17604        * testing/InternalSettings.h: Removed some useless parameter names.
17605        * testing/InternalSettings.idl: Added setScrollingTreeIncludesFrames() setting.
17606
176072014-06-09  Benjamin Poulain  <bpoulain@apple.com>
17608
17609        Improve CSSPrimitiveValue::customCSSText for ARMv7
17610        https://bugs.webkit.org/show_bug.cgi?id=133597
17611
17612        Reviewed by Andreas Kling.
17613
17614        On imgur, some script is updating some layout on timers and on scroll.
17615
17616        It looks like CSSPrimitiveValue::customCSSText() is a little constrained
17617        by the instruction cache on ARMv7. This patch improve the situation a bit.
17618
17619        First, the creation of the string itself is changed to go from two allocation to one.
17620        Previously, we would allocate a StringBuffer and adopt it. Now we allocate a StringImpl
17621        directly with the inline buffer.
17622
17623        The second issue is that the compiler was generating a real copy constructor for every
17624        assignment of the "text" variable (likely because the variable span is so large).
17625        This was solved by moving the string creating into a separate function (to fix the span)
17626        and being careful with passing PassRef<StringImpl> around.
17627
17628        Then there was the problem that the compiler was a little too aggressive with inlining
17629        which caused each "case" to repeat the same prologue and epilogue before formatValue().
17630        This was solved by adding formatNumberValue() with NEVER_INLINE to have the prologue/epilogue
17631        in a single place.
17632
17633        On older device, that's about 3% improvement on style access. On modern ARM64/x86_64
17634        there is no noticeable difference.
17635
17636        * css/CSSPrimitiveValue.cpp:
17637        (WebCore::CSSPrimitiveValue::formatNumberValue):
17638        (WebCore::CSSPrimitiveValue::formatNumberForcustomCSSText):
17639        (WebCore::CSSPrimitiveValue::customCSSText):
17640        (WebCore::formatNumber): Deleted.
17641        * css/CSSPrimitiveValue.h:
17642
176432014-06-09  Alex Christensen  <achristensen@webkit.org>
17644
17645        [iOS WebGL] Fix EXT_shader_texture_lod.
17646        https://bugs.webkit.org/show_bug.cgi?id=133633
17647
17648        Reviewed by Brady Eidson.
17649
17650        Covered by the Khronos test (and in LayoutTests):
17651        conformance/extensions/ext-shader-texture-lod.html
17652
17653        * html/canvas/WebGLRenderingContext.cpp:
17654        (WebCore::WebGLRenderingContext::getExtension):
17655        (WebCore::WebGLRenderingContext::getSupportedExtensions):
17656        Added shader texture lod name to match value from glGetString(GL_EXTENSIONS) on iOS.
17657
176582014-06-09  Benjamin Poulain  <bpoulain@apple.com>
17659
17660        Document::updateStyleIfNeededForNode can get very expensive
17661        https://bugs.webkit.org/show_bug.cgi?id=133599
17662
17663        Reviewed by Andreas Kling.
17664
17665        When pages are querying their style, we first run through
17666        Document::updateStyleIfNeededForNode() to find if that particular node needs style recalc.
17667
17668        The problem was that updateStyleIfNeededForNode() could get really expensive. For each node,
17669        it needs to check the whole parent chain to find if any needs style recalc.
17670        When web pages get a bunch of nodes and querying their style, we ended up going over a lot
17671        of nodes just to find there is nothing to do.
17672
17673        This patch adds two tweaks to reduce the problem:
17674        First, before querying nodeOrItsAncestorNeedsStyleRecalc() we check if the Document is dirty at all.
17675        The other part is making nodeOrItsAncestorNeedsStyleRecalc() faster by removing useless elements check.
17676
17677        * dom/Document.cpp:
17678        (WebCore::nodeOrItsAncestorNeedsStyleRecalc):
17679        (WebCore::Document::updateStyleIfNeededForNode):
17680
176812014-06-09  Enrica Casucci  <enrica@apple.com>
17682
17683        iOS WebKit: Crash in charactersAroundPosition.
17684        https://bugs.webkit.org/show_bug.cgi?id=133659
17685        <rdar://problem/17220870>
17686
17687        Reviewed by Benjamin Poulain.
17688
17689        Ensure that we stay within the vector boundaries
17690        when returning the characters around the position.
17691
17692        * editing/VisibleUnits.cpp:
17693        (WebCore::charactersAroundPosition):
17694
176952014-06-09  Alexey Proskuryakov  <ap@apple.com>
17696
17697        Properly reset UStringSearch object in SearchBuffer constructor.
17698        https://bugs.webkit.org/show_bug.cgi?id=133662
17699        <rdar://problem/17240136>
17700
17701        Reviewed by Tim Horton.
17702
17703        * editing/TextIterator.cpp: (WebCore::SearchBuffer::~SearchBuffer):
17704
177052014-06-09  Eric Carlson  <eric.carlson@apple.com>
17706
17707        Automatic text track selection can select more than one track
17708        https://bugs.webkit.org/show_bug.cgi?id=133590
17709
17710        Reviewed by Brent Fulgham.
17711
17712        Test: media/video-trackmenu-selection.html
17713
17714        * html/HTMLMediaElement.cpp:
17715        (WebCore::HTMLMediaElement::configureTextTrack): Consider the currently selected
17716            track, if any.
17717
17718        * page/CaptionUserPreferencesMediaAF.cpp:
17719        (WebCore::CaptionUserPreferencesMediaAF::sortedTrackListForMenu): Drive-by change
17720            to make sure no non-visible text tracks are included in the track menu.
17721
177222014-06-09  Jer Noble  <jer.noble@apple.com>
17723
17724        [Mac] Hang when painting media before compositing mode activated
17725        https://bugs.webkit.org/show_bug.cgi?id=133655
17726
17727        Reviewed by Eric Carlson.
17728
17729        When asked to paint(), MediaPlayerPrivateAVFoundationObjC should not create an image generator
17730        or a video output. These operations are synchronous, and will block the drawing thread and cause
17731        a spin. paint() as opposed to paintImageInContext() is only called when painting the layer tree
17732        and MediaPlayerPrivateAVFoundationObjC will paint by creating a AVPlayerLayer, not by painting
17733        frames directly into the tree.
17734
17735        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
17736        (WebCore::MediaPlayerPrivateAVFoundationObjC::paint):
17737
177382014-06-09  Jer Noble  <jer.noble@apple.com>
17739
17740        [Mac][MSE] Exception thrown from ~MediaPlayerPrivateMediaSourceAVFObjC().
17741        https://bugs.webkit.org/show_bug.cgi?id=133656
17742
17743        Reviewed by Eric Carlson.
17744
17745        AVSampleBufferRenderSynchronizer can't handle being passed a NULL observer, so only attempt
17746        to remove the time jumped or duration observer if one was actually created.
17747
17748        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
17749        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::~MediaPlayerPrivateMediaSourceAVFObjC):
17750
177512014-06-09  Zalan Bujtas  <zalan@apple.com>
17752
17753        Subpixel rendering: Pixelsnapping empty rounded rect results in NaN radii width/height.
17754        https://bugs.webkit.org/show_bug.cgi?id=133654
17755
17756        Reviewed by Simon Fraser.
17757
17758        Empty rounded rects don't need snapping.
17759
17760        Not testable.
17761
17762        * platform/graphics/RoundedRect.cpp:
17763        (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
17764
177652014-05-21  Myles C. Maxfield  <mmaxfield@apple.com>
17766
17767        REGRESSION: missing underline under CJK text
17768        https://bugs.webkit.org/show_bug.cgi?id=128145
17769
17770        Reviewed by Darin Adler.
17771
17772        This patch refactors the GlyphToPathTranslator which is used to find intersections of
17773        glyphs and underlines. It was modified to allow for querying these pieces of
17774        information:
17775        1) The extents of the glyph. This can be used to make the underlines skip an entire
17776        glyph, wholesale
17777        2) What kind of skipping behavior should be used
17778        3) The Path which represents the glyph
17779        There are three skipping behaviors:
17780        1) (SkipDescenders) The previous behavior
17781        2) (SkipGlyph) Make the underline skip over the entire glyph, using the extents() function
17782        3) (DrawOverGlyph) Make the underline plow through the glyph, ignoring any descenders
17783
17784        Calculating which underlining behavior to use depends on what the base codepoint that
17785        originated that glyph is. This means that we have to map from glyphs to characters,
17786        something which is nontrivial to do. In order to solve this problem, this patch adds
17787        an optional vector to GlyphBuffer which represents the location in the original string
17788        from which a particular glyph originated. Then, when our WidthIterator code adds
17789        glyphs to the GlyphBuffer, we can include the extra information about where we are
17790        in the input string. Once this data is available, the GlyphPathTranslator can look up
17791        the base codepoint from which this glyph originates, and can run ICU functions on that
17792        codepoint.
17793
17794        We can use the ICU ublock_getCode() function to find which Unicode block a particular
17795        codepoint comes from. If the codepoint comes from a CJK block, we will use
17796        DrawOverGlyph; otherwise, we will use SkipDescenders.
17797
17798        Test: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-ink-cjk.html
17799
17800        * platform/graphics/Font.cpp:
17801        (WebCore::sharedUnderlineType): Look up the base codepoint from which this glyph
17802        originates, call ublock_getCode to get its Unicode block, then return
17803        a GlyphUnderlineType accordingly. This code is shared between SVG and non-SVG.
17804        * platform/graphics/Font.h: New virtual functions in GlyphToPathTranslator, as well as
17805        function signatures for the above two functions.
17806        * platform/graphics/GlyphBuffer.h: Add an optional instance member for the location
17807        from within the original string from which a particular glyph originates.
17808        (WebCore::GlyphBuffer::clear): Updated for new member.
17809        (WebCore::GlyphBuffer::add): Ditto.
17810        (WebCore::GlyphBuffer::saveOffsetsInString): Opt-in to using the new variable
17811        (WebCore::GlyphBuffer::offsetInString): New variable accessor.
17812        * platform/graphics/TextRun.h: SVG needs the TextRun to use sharedUnderlineType.
17813        * platform/graphics/WidthIterator.cpp:
17814        (WebCore::WidthIterator::advanceInternal): Use GlyphBuffer's new variable (if present).
17815        * platform/graphics/mac/ComplexTextController.cpp:
17816        (WebCore::ComplexTextController::advance): Use GlyphBuffer's new variable (if present).
17817        * platform/graphics/mac/FontMac.mm: Implement new GlyphToPathTranslator functions.
17818        (WebCore::MacGlyphToPathTranslator::path):
17819        (WebCore::MacGlyphToPathTranslator::extents):
17820        (WebCore::MacGlyphToPathTranslator::underlineType): Calls sharedUnderlineType().
17821        (WebCore::MacGlyphToPathTranslator::moveToNextValidGlyph):
17822        (WebCore::MacGlyphToPathTranslator::increment):
17823        (WebCore::Font::dashesForIntersectionsWithRect): Ask the translator what kind of underline
17824        behavior should be used. React accordingly.
17825        (WebCore::MacGlyphToPathTranslator::nextPath): Deleted.
17826        (WebCore::MacGlyphToPathTranslator::incrementIndex): Deleted.
17827        * platform/graphics/win/UniscribeController.cpp:
17828        (WebCore::UniscribeController::shapeAndPlaceItem): Update to new signature of GlyphBuffer::add()
17829        * rendering/svg/SVGTextRunRenderingContext.cpp: Implement new GlyphToPathTranslator functions.
17830        (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
17831        (WebCore::SVGGlyphToPathTranslator::getCurrentTransform):
17832        (WebCore::SVGGlyphToPathTranslator::path):
17833        (WebCore::SVGGlyphToPathTranslator::extents):
17834        (WebCore::MacGlyphToPathTranslator::underlineType): Calls sharedUnderlineType().
17835        (WebCore::SVGGlyphToPathTranslator::moveToNextValidGlyph):
17836        (WebCore::SVGGlyphToPathTranslator::increment):
17837        (WebCore::SVGTextRunRenderingContext::createGlyphToPathTranslator):
17838        (WebCore::SVGTextRunRenderingContext::drawSVGGlyphs):
17839        (WebCore::SVGGlyphToPathTranslator::nextPath): Deleted.
17840        (WebCore::SVGGlyphToPathTranslator::incrementIndex): Deleted.
17841        * rendering/svg/SVGTextRunRenderingContext.h: SVG needs the TextRun to use sharedUnderlineType.
17842
178432014-06-09  Alex Christensen  <achristensen@webkit.org>
17844
17845        [iOS WebGL] Implement OES_vertex_array_object for iOS.
17846        https://bugs.webkit.org/show_bug.cgi?id=133629
17847
17848        Reviewed by Brady Eidson.
17849
17850        Covered by the Khronos test (and in LayoutTests):
17851        conformance/extensions/oes-vertex-array-object.html
17852
17853        * platform/graphics/ios/GraphicsContext3DIOS.h:
17854        Added OpenGL vertex array function renaming for iOS adding the OES suffix.
17855        * platform/graphics/opengl/Extensions3DOpenGL.cpp:
17856        (WebCore::Extensions3DOpenGL::createVertexArrayOES):
17857        (WebCore::Extensions3DOpenGL::deleteVertexArrayOES):
17858        (WebCore::Extensions3DOpenGL::isVertexArrayOES):
17859        (WebCore::Extensions3DOpenGL::bindVertexArrayOES):
17860        Added isVertexArrayObjectSupported and support for iOS.
17861        (WebCore::Extensions3DOpenGL::supportsExtension):
17862        Added iOS name for GL_OES_vertex_array_object extension.
17863        * platform/graphics/opengl/Extensions3DOpenGL.h:
17864        Added isVertexArrayObjectSupported for iOS.        
17865
178662014-06-09  Eric Carlson  <eric.carlson@apple.com>
17867
17868        [Mac] caption size is not update immediately when system preferences change
17869        https://bugs.webkit.org/show_bug.cgi?id=133598
17870
17871        Reviewed by Brent Fulgham.
17872
17873        * Modules/mediacontrols/MediaControlsHost.cpp:
17874        (WebCore::MediaControlsHost::updateCaptionDisplaySizes): New.
17875        * Modules/mediacontrols/MediaControlsHost.h:
17876
17877        * html/HTMLMediaElement.cpp:
17878        (WebCore::HTMLMediaElement::captionPreferencesChanged): Tell the controls host to update sizes.
17879
178802014-06-09  Daniel Bates  <dabates@apple.com>
17881
17882        [iOS] Amazon app: Cannot interact with product page after tapping on product image
17883        https://bugs.webkit.org/show_bug.cgi?id=133559
17884        <rdar://problem/16332749>
17885
17886        Reviewed by Oliver Hunt.
17887
17888        As a workaround for issues in the Amazon app, mark the attribute navigator.geolocation as
17889        replaceable so that we don't throw a JavaScript type error when assigning to an instance
17890        attribute that shadows it. At the time of writing the first such assignment to is ignored.
17891        See <https://bugs.webkit.org/show_bug.cgi?id=133648> for more details.
17892
17893        When loading a product page in the Amazon app it overwrites the readonly property geolocation
17894        on an object that extends the Navigator object. In strict mode, this operation is not honored
17895        and is treated as a JavaScript type error, which stops JavaScript execution. Therefore, the
17896        product page does not behave as intended. In contrast, this operation would not be honored in
17897        non-strict mode and would not be treated as a JavaScript type error.
17898
17899        Test: js/dom/shadow-navigator-geolocation-in-strict-mode-does-not-throw.html
17900
17901        * Modules/geolocation/NavigatorGeolocation.idl:
17902
179032014-06-09  Andreas Kling  <akling@apple.com>
17904
17905        HTML*ListElement wrappers have custom getOwnPropertySlot()s for no good reason.
17906        <https://webkit.org/b/133653>
17907
17908        The JavaScript bindings generator was a bit overzealous in forcing every
17909        interface with "List" in the name to have its attributes on the instance.
17910        This caused some elements (HTMLUListElement, etc.) to automatically opt out
17911        of eager prototype attribute reification.
17912
17913        Reviewed by Mark Hahnenberg.
17914
17915        * bindings/scripts/CodeGeneratorJS.pm:
17916        (InterfaceRequiresAttributesOnInstance):
17917
179182014-06-09  Jer Noble  <jer.noble@apple.com>
17919
17920        ASSERT(!m_inRemovedLastRefFunction) in Element::addShadowRoot while destroying a document
17921        https://bugs.webkit.org/show_bug.cgi?id=133450
17922
17923        Reviewed by Eric Carlson.
17924
17925        ensureUserAgentShadowRoot() is being called when a media element is removed from its document
17926        in HTMLMediaElement::removedFrom() because Node::removedFrom() has not yet run and removed the
17927        InDocument flag from the node.  Rather than calling configureMediaControls() at this point
17928        just expilictly remove the media controls if present.
17929
17930        * html/HTMLMediaElement.cpp:
17931        (WebCore::HTMLMediaElement::parseAttribute):
17932
179332014-06-09  Mark Hahnenberg  <mhahnenberg@apple.com>
17934
17935        Rebaseline bindings tests after r169703
17936
17937        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
17938        (WebCore::JSTestActiveDOMObjectPrototype::finishCreation):
17939        (WebCore::JSTestActiveDOMObjectPrototype::getOwnPropertySlot): Deleted.
17940        * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
17941        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
17942        (WebCore::JSTestCustomNamedGetterPrototype::finishCreation):
17943        (WebCore::JSTestCustomNamedGetterPrototype::getOwnPropertySlot): Deleted.
17944        * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
17945        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
17946        (WebCore::JSTestEventConstructorPrototype::finishCreation):
17947        (WebCore::JSTestEventConstructorPrototype::getOwnPropertySlot): Deleted.
17948        (WebCore::JSTestEventConstructor::getOwnPropertySlot): Deleted.
17949        * bindings/scripts/test/JS/JSTestEventConstructor.h:
17950        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
17951        (WebCore::JSTestEventTargetPrototype::finishCreation):
17952        (WebCore::JSTestEventTargetPrototype::getOwnPropertySlot): Deleted.
17953        * bindings/scripts/test/JS/JSTestEventTarget.h:
17954        * bindings/scripts/test/JS/JSTestException.cpp:
17955        (WebCore::JSTestExceptionPrototype::finishCreation):
17956        (WebCore::JSTestExceptionPrototype::getOwnPropertySlot): Deleted.
17957        * bindings/scripts/test/JS/JSTestException.h:
17958        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
17959        (WebCore::JSTestGenerateIsReachablePrototype::finishCreation):
17960        (WebCore::JSTestGenerateIsReachablePrototype::getOwnPropertySlot): Deleted.
17961        (WebCore::JSTestGenerateIsReachable::getOwnPropertySlot): Deleted.
17962        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
17963        * bindings/scripts/test/JS/JSTestInterface.cpp:
17964        (WebCore::JSTestInterfacePrototype::finishCreation):
17965        (WebCore::JSTestInterfacePrototype::getOwnPropertySlot): Deleted.
17966        * bindings/scripts/test/JS/JSTestInterface.h:
17967        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
17968        (WebCore::JSTestMediaQueryListListenerPrototype::finishCreation):
17969        (WebCore::JSTestMediaQueryListListenerPrototype::getOwnPropertySlot): Deleted.
17970        (WebCore::JSTestMediaQueryListListener::getOwnPropertySlot): Deleted.
17971        * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
17972        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
17973        (WebCore::JSTestNamedConstructorPrototype::finishCreation):
17974        (WebCore::JSTestNamedConstructorPrototype::getOwnPropertySlot): Deleted.
17975        (WebCore::JSTestNamedConstructor::getOwnPropertySlot): Deleted.
17976        * bindings/scripts/test/JS/JSTestNamedConstructor.h:
17977        * bindings/scripts/test/JS/JSTestNode.cpp:
17978        (WebCore::JSTestNodePrototype::finishCreation):
17979        (WebCore::JSTestNodePrototype::getOwnPropertySlot): Deleted.
17980        (WebCore::JSTestNode::getOwnPropertySlot): Deleted.
17981        * bindings/scripts/test/JS/JSTestNode.h:
17982        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
17983        (WebCore::JSTestNondeterministicPrototype::finishCreation):
17984        (WebCore::JSTestNondeterministicPrototype::getOwnPropertySlot): Deleted.
17985        (WebCore::JSTestNondeterministic::getOwnPropertySlot): Deleted.
17986        * bindings/scripts/test/JS/JSTestNondeterministic.h:
17987        * bindings/scripts/test/JS/JSTestObj.cpp:
17988        (WebCore::JSTestObjPrototype::finishCreation):
17989        (WebCore::JSTestObjPrototype::getOwnPropertySlot): Deleted.
17990        * bindings/scripts/test/JS/JSTestObj.h:
17991        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
17992        (WebCore::JSTestOverloadedConstructorsPrototype::finishCreation):
17993        (WebCore::JSTestOverloadedConstructorsPrototype::getOwnPropertySlot): Deleted.
17994        (WebCore::JSTestOverloadedConstructors::getOwnPropertySlot): Deleted.
17995        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
17996        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
17997        (WebCore::JSTestSerializedScriptValueInterfacePrototype::finishCreation):
17998        (WebCore::JSTestSerializedScriptValueInterfacePrototype::getOwnPropertySlot): Deleted.
17999        (WebCore::JSTestSerializedScriptValueInterface::getOwnPropertySlot): Deleted.
18000        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
18001        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
18002        (WebCore::JSTestTypedefsPrototype::finishCreation):
18003        (WebCore::JSTestTypedefsPrototype::getOwnPropertySlot): Deleted.
18004        * bindings/scripts/test/JS/JSTestTypedefs.h:
18005        * bindings/scripts/test/JS/JSattribute.cpp:
18006        (WebCore::JSattributePrototype::finishCreation):
18007        (WebCore::JSattributePrototype::getOwnPropertySlot): Deleted.
18008        (WebCore::JSattribute::getOwnPropertySlot): Deleted.
18009        * bindings/scripts/test/JS/JSattribute.h:
18010        * bindings/scripts/test/JS/JSreadonly.cpp:
18011        (WebCore::JSreadonlyPrototype::finishCreation):
18012        (WebCore::JSreadonlyPrototype::getOwnPropertySlot): Deleted.
18013        (WebCore::JSreadonly::getOwnPropertySlot): Deleted.
18014        * bindings/scripts/test/JS/JSreadonly.h:
18015
180162014-06-09  Simon Fraser  <simon.fraser@apple.com>
18017
18018        Group the methods in InternalSettings.idl
18019        https://bugs.webkit.org/show_bug.cgi?id=133652
18020
18021        Reviewed by Tim Horton.
18022
18023        Group methods by topic.
18024
18025        * testing/InternalSettings.idl:
18026
180272014-06-05  Mark Hahnenberg  <mhahnenberg@apple.com>
18028
18029        Eagerly reify DOM prototype attributes
18030        https://bugs.webkit.org/show_bug.cgi?id=133558
18031
18032        Reviewed by Oliver Hunt.
18033
18034        No new tests.
18035
18036        This allows us to get rid of a lot of the additional overhead of pushing DOM attributes up into the prototype. 
18037        By eagerly reifying the custom getters and setters into the actual JSObject we avoid having to override 
18038        getOwnPropertySlot for all of the DOM prototypes, which is a lot of the overhead of doing property lookups on 
18039        DOM wrappers.
18040
18041        * bindings/scripts/CodeGeneratorJS.pm:
18042        (prototypeHashTableAccessor): Changed to pass along the VM.
18043        (AttributeShouldBeOnInstanceForCompatibility): We were being overly conservative in regard to touch events. 
18044        This caused us to store the touch event handler getters and setters on the JSElement instance, which caused
18045        us to override getOwnPropertySlot for every JSElement subclass.
18046        (InstanceOverridesGetOwnPropertySlot): This was being overly paranoid about generate a getOwnPropertySlot if
18047        there was going to be a "constructor" property, even though we handled this in another place already.
18048        (GenerateHeader): Generate a finishCreation for prototypes unless it's the JSDOMWindow. We can't correctly 
18049        handle the DOMWindow in this version of the patch because reifying the static properties requires a global object,
18050        which hasn't been created yet when the prototype for the window object is being created.
18051        (GenerateImplementation): Generate the finishCreation calls to reifyStaticProperties.
18052
180532014-06-09  Alexey Proskuryakov  <ap@apple.com>
18054
18055        REGRESSION (r169681): Three tests are broken
18056        https://bugs.webkit.org/show_bug.cgi?id=133646
18057
18058        Reviewed by Tim Horton.
18059
18060        r169681 removed platformFocusRingMaxWidth() override, which returned either 0 or 9
18061        on Mac. But the cross-platform default is 3, so this changed Mac behavior.
18062
18063        I'm not entirely sure why the cross-platform default is 3 (it was also added in r168397),
18064        but restoring the override to return 0 fixes test cases.
18065
18066        While at it, also added final/override, and removed some functions that were only
18067        needed by subclasses, which we now have none.
18068
18069        * rendering/RenderThemeMac.h:
18070        (WebCore::RenderThemeMac::supportsControlTints): Deleted.
18071        (WebCore::RenderThemeMac::scrollbarControlSizeForPart): Deleted.
18072        (WebCore::RenderThemeMac::supportsSelectionForegroundColors): Deleted.
18073        (WebCore::RenderThemeMac::supportsClosedCaptioning): Deleted.
18074        (WebCore::RenderThemeMac::updateActiveState): Deleted.
18075        * rendering/RenderThemeMac.mm:
18076        (WebCore::RenderThemeMac::platformFocusRingMaxWidth):
18077        (WebCore::RenderThemeMac::setPopupButtonCellState):
18078        (WebCore::RenderThemeMac::paintSliderThumb):
18079        (WebCore::RenderThemeMac::setSearchCellState):
18080        (WebCore::RenderThemeMac::paintSearchFieldCancelButton):
18081        (WebCore::RenderThemeMac::paintSearchFieldResultsDecorationPart):
18082        (WebCore::RenderThemeMac::paintSearchFieldResultsButton):
18083
180842014-06-09  Bem Jones-Bey  <bjonesbe@adobe.com>
18085
18086        [CSS Shapes] Bound RasterShapeInterval size to int
18087        https://bugs.webkit.org/show_bug.cgi?id=133576
18088
18089        Reviewed by Simon Fraser.
18090
18091        Everything in the code assumes that the interval size will always fit
18092        in an int. However, to make sure there are no negatives, the
18093        RasterShapeInterval constructor takes an unsigned. This clamps that
18094        value to make sure we can't overflow an int later.
18095
18096        * rendering/shapes/RasterShape.h:
18097        (WebCore::RasterShapeIntervals::RasterShapeIntervals):
18098
180992014-06-09  Zalan Bujtas  <zalan@apple.com>
18100
18101        [iOS] Gaps below and to the right of the video controls on devour.com
18102        https://bugs.webkit.org/show_bug.cgi?id=133607
18103
18104        Reviewed by Simon Fraser.
18105
18106        Non-toplevel compositing layers are device pixel aligned. In order to render the content
18107        to the same position as if the layer was not aligned, the graphics layer needs to be translated.
18108        CALayer::bounds is set to compensate for the shifted layer. However, we should not change the layer's
18109        size as that stretches the content and results in overlaps/gaps/extra fuzziness.
18110
18111        Test: compositing/contents-scale/hidpi-compositing-layer-positioned-on-scaled-context.html
18112
18113        * platform/graphics/ca/GraphicsLayerCA.cpp:
18114        (WebCore::GraphicsLayerCA::updateGeometry):
18115        (WebCore::GraphicsLayerCA::computePixelAlignment): remove old epsilon adjustment code.
18116        * platform/graphics/ca/GraphicsLayerCA.h:
18117
181182014-06-09  Zalan Bujtas  <zalan@apple.com>
18119
18120        [SVG] Subpixel rendering: Mask with transformed text does not render.
18121        https://bugs.webkit.org/show_bug.cgi?id=133626
18122        <rdar://problem/17123070>
18123
18124        Reviewed by Simon Fraser.
18125
18126        Replace IntRect::infiniteRect() with Layout::infiniteRect(). A transformed IntRect::infiniteRect()
18127        overflows and produces invalid repaint rect. -also remove IntRect::infiniteRect() as no one calls
18128        it anymore.
18129
18130        Tests: svg/masking/mask-transformed-text-missing-expected.svg
18131               svg/masking/mask-transformed-text-missing.svg
18132
18133        * platform/graphics/IntRect.h:
18134        (WebCore::IntRect::infiniteRect): Deleted.
18135        * rendering/svg/SVGRenderingContext.cpp:
18136        (WebCore::SVGRenderingContext::renderSubtreeToImageBuffer):
18137
181382014-06-08  Dean Jackson  <dino@apple.com>
18139
18140        [Mac] checkboxes and radio buttons animate incorrectly
18141        https://bugs.webkit.org/show_bug.cgi?id=133619
18142        <rdar://problem/16478676>
18143
18144        Reviewed by Sam Weinig.
18145
18146        As many people have noticed, the new checkboxes and radio
18147        buttons jump around during their animation. To fix this
18148        I've added yet another magic set of numbers to our
18149        native form positioning - this time the placement
18150        of the controls when rendering on the animated path.
18151        This is quite annoying, since there doesn't appear
18152        to be any pattern to the offsets (or margins) given
18153        a control size, and this case also needed a sub-pixel
18154        offset to display correctly on retina machines.
18155
18156        * platform/mac/ThemeMac.mm:
18157        (WebCore::checkboxMargins): Add comment so I know what the values mean.
18158        (WebCore::checkboxOffsets): Add the magic translation values for animated states.
18159        (WebCore::radioMargins): Ditto.
18160        (WebCore::radioOffsets):
18161        (WebCore::paintToggleButton): Paint with these new offsets.
18162
181632014-06-07  Dean Jackson  <dino@apple.com>
18164
18165        Regression r168397 - Form layout is incorrect on OS X Yosemite
18166        https://bugs.webkit.org/show_bug.cgi?id=133612
18167        <rdar://problem/16850492>
18168        <rdar://problem/17016914>
18169
18170        Reviewed by Anders Carlson.
18171
18172        Revision 168397 introduced a new animated style of form controls. Part of
18173        it included extending the margins for the controls to take into account the
18174        focus ring that animates in from a large radius to a small radius. This
18175        caused two problems:
18176
18177        - the incorrect margins broke many layouts
18178        - despite increased margins, there were still some areas
18179          that did not repaint correctly.
18180
18181        Restore the old margins and (temporarily) turn off focus ring animation.
18182        Bad layout is much worse than a missing animation. Another benefit
18183        of this is that we will use less memory.
18184
18185        * platform/graphics/mac/GraphicsContextMac.mm:
18186        (WebCore::drawFocusRingToContextAtTime): Pass in a time far far far in the future to
18187        get the static rendering.
18188        * platform/mac/ThemeMac.mm:
18189        (WebCore::checkboxMargins): Restore correct margins.
18190        (WebCore::radioMargins): Ditto.
18191        (WebCore::drawCellFocusRing): New method that calls WKSI with a future time.
18192        (WebCore::paintToggleButton): Call the new wrapper.
18193        (WebCore::buttonMargins): Restore correct margins.
18194        (WebCore::paintButton): Call the new wrapper.
18195        * rendering/RenderThemeMac.h:
18196        * rendering/RenderThemeMac.mm:
18197        (WebCore::RenderThemeMac::paintMenuList): Use a future time.
18198        (WebCore::RenderThemeMac::platformFocusRingMaxWidth): Deleted. Use old outline value.
18199
182002014-05-29  Anders Carlsson  <andersca@apple.com>
18201
18202        HTTPHeaderMap should not derive from HashMap
18203        https://bugs.webkit.org/show_bug.cgi?id=133392
18204
18205        Reviewed by Darin Adler.
18206
18207        Use a HashMap member variable instead.
18208
18209        * WebCore.exp.in:
18210        * loader/DocumentLoader.cpp:
18211        (WebCore::DocumentLoader::responseReceived):
18212        * platform/network/HTTPHeaderMap.cpp:
18213        (WebCore::HTTPHeaderMap::copyData):
18214        (WebCore::HTTPHeaderMap::adopt):
18215        (WebCore::HTTPHeaderMap::get):
18216        (WebCore::HTTPHeaderMap::set):
18217        (WebCore::HTTPHeaderMap::add):
18218        (WebCore::HTTPHeaderMap::contains):
18219        (WebCore::HTTPHeaderMap::find):
18220        (WebCore::HTTPHeaderMap::remove):
18221        (WebCore::HTTPHeaderMap::keys):
18222        * platform/network/HTTPHeaderMap.h:
18223        (WebCore::HTTPHeaderMap::isEmpty):
18224        (WebCore::HTTPHeaderMap::size):
18225        (WebCore::HTTPHeaderMap::clear):
18226        (WebCore::HTTPHeaderMap::begin):
18227        (WebCore::HTTPHeaderMap::end):
18228        (WebCore::HTTPHeaderMap::operator==):
18229        (WebCore::HTTPHeaderMap::operator!=):
18230        * platform/network/ResourceRequestBase.cpp:
18231        (WebCore::ResourceRequestBase::adopt):
18232        * platform/network/ResourceRequestBase.h:
18233        * platform/network/ResourceResponseBase.cpp:
18234        (WebCore::ResourceResponseBase::adopt):
18235        * platform/network/ResourceResponseBase.h:
18236        * xml/XMLHttpRequest.cpp:
18237        (WebCore::XMLHttpRequest::createRequest):
18238
182392014-06-07  Zan Dobersek  <zdobersek@igalia.com>
18240
18241        Use C++11 lambdas to construct FileThread::Task objects
18242        https://bugs.webkit.org/show_bug.cgi?id=133079
18243
18244        Reviewed by Darin Adler.
18245
18246        Have FileThread::Task constructor take in a std::function<void ()>-like object
18247        as the second parameter. Much like with ScriptExecutionContext::Task, the idea here
18248        is to use inlined C++11 lambdas in FileThread::postTask() calls. Because FileThread::Task
18249        also requires an instance pointer, a brace-init list is passed to these calls, passing
18250        in the instance pointer as the first parameter and the C++11 lambda as the second.
18251
18252        FileThread::postTask() now takes in a FileThread::Task rvalue and moves it onto the heap
18253        and into the queue.
18254
18255        In AsyncFileStream.cpp, calls to FileThread::postTask() are updated to use C++11 lambdas.
18256        Uses of MainThreadTask are also replaced by C++11 lambdas. This modernizes the code and
18257        removes a lot of helper functions.
18258
18259        FileThread::Task doesn't use CrossThreadCopier anymore. Instead, we manually produce
18260        thread-safe copies as necessary. At the moment this approach produces another copy when
18261        passing the freshly-copied object into the lambda, but this will be avoidable once we
18262        make C++14 and the lambda capture expression support mandatory.
18263
18264        * fileapi/AsyncFileStream.cpp:
18265        (WebCore::AsyncFileStream::create):
18266        (WebCore::AsyncFileStream::stop):
18267        (WebCore::AsyncFileStream::getSize):
18268        (WebCore::AsyncFileStream::openForRead):
18269        (WebCore::AsyncFileStream::openForWrite):
18270        (WebCore::AsyncFileStream::close):
18271        (WebCore::AsyncFileStream::read):
18272        (WebCore::AsyncFileStream::write):
18273        (WebCore::AsyncFileStream::truncate):
18274        (WebCore::didStart): Deleted.
18275        (WebCore::AsyncFileStream::startOnFileThread): Deleted.
18276        (WebCore::derefProxyOnMainThread): Deleted.
18277        (WebCore::AsyncFileStream::stopOnFileThread): Deleted.
18278        (WebCore::didGetSize): Deleted.
18279        (WebCore::AsyncFileStream::getSizeOnFileThread): Deleted.
18280        (WebCore::didOpen): Deleted.
18281        (WebCore::AsyncFileStream::openForReadOnFileThread): Deleted.
18282        (WebCore::AsyncFileStream::openForWriteOnFileThread): Deleted.
18283        (WebCore::AsyncFileStream::closeOnFileThread): Deleted.
18284        (WebCore::didRead): Deleted.
18285        (WebCore::AsyncFileStream::readOnFileThread): Deleted.
18286        (WebCore::didWrite): Deleted.
18287        (WebCore::AsyncFileStream::writeOnFileThread): Deleted.
18288        (WebCore::didTruncate): Deleted.
18289        (WebCore::AsyncFileStream::truncateOnFileThread): Deleted.
18290        * fileapi/AsyncFileStream.h:
18291        * fileapi/FileThread.cpp:
18292        (WebCore::FileThread::postTask):
18293        * fileapi/FileThread.h:
18294        (WebCore::FileThread::Task::Task):
18295
182962014-06-07  Zan Dobersek  <zdobersek@igalia.com>
18297
18298        Pass C++11 lambdas to callOnMainThread() calls in IconDatabase
18299        https://bugs.webkit.org/show_bug.cgi?id=133374
18300
18301        Reviewed by Darin Adler.
18302
18303        Use C++11 lambads to inline the main thread tasks into the calling code,
18304        modernizing the look of the code and removing a few static methods and
18305        classes that were used as helpers.
18306
18307        * loader/icon/IconDatabase.cpp:
18308        (WebCore::IconDatabase::scheduleOrDeferSyncTimer):
18309        (WebCore::IconDatabase::performURLImport):
18310        (WebCore::IconDatabase::dispatchDidImportIconURLForPageURLOnMainThread):
18311        (WebCore::IconDatabase::dispatchDidImportIconDataForPageURLOnMainThread):
18312        (WebCore::IconDatabase::dispatchDidRemoveAllIconsOnMainThread):
18313        (WebCore::IconDatabase::dispatchDidFinishURLImportOnMainThread):
18314        (WebCore::IconDatabase::notifyPendingLoadDecisionsOnMainThread): Deleted.
18315        (WebCore::IconDatabase::performScheduleOrDeferSyncTimer): Deleted.
18316        (WebCore::IconDatabase::performScheduleOrDeferSyncTimerOnMainThread): Deleted.
18317        (WebCore::ClientWorkItem::ClientWorkItem): Deleted.
18318        (WebCore::ClientWorkItem::~ClientWorkItem): Deleted.
18319        (WebCore::ImportedIconURLForPageURLWorkItem::ImportedIconURLForPageURLWorkItem): Deleted.
18320        (WebCore::ImportedIconURLForPageURLWorkItem::~ImportedIconURLForPageURLWorkItem): Deleted.
18321        (WebCore::ImportedIconURLForPageURLWorkItem::performWork): Deleted.
18322        (WebCore::ImportedIconDataForPageURLWorkItem::ImportedIconDataForPageURLWorkItem): Deleted.
18323        (WebCore::ImportedIconDataForPageURLWorkItem::~ImportedIconDataForPageURLWorkItem): Deleted.
18324        (WebCore::ImportedIconDataForPageURLWorkItem::performWork): Deleted.
18325        (WebCore::RemovedAllIconsWorkItem::RemovedAllIconsWorkItem): Deleted.
18326        (WebCore::RemovedAllIconsWorkItem::performWork): Deleted.
18327        (WebCore::FinishedURLImport::FinishedURLImport): Deleted.
18328        (WebCore::FinishedURLImport::performWork): Deleted.
18329        (WebCore::performWorkItem): Deleted.
18330        * loader/icon/IconDatabase.h:
18331
183322014-06-07  Zan Dobersek  <zdobersek@igalia.com>
18333
18334        Replace uses of CrossThreadTask in DefaultSharedWorkerRepository, WorkerMessagingProxy with C++11 lambdas
18335        https://bugs.webkit.org/show_bug.cgi?id=133375
18336
18337        Reviewed by Darin Adler.
18338
18339        Uses of CrossThreadTask in the two classes are replaced with C++11 lambdas.
18340        The necessary cross-thread copies are created manually and passed into the
18341        lambdas by value, removing the need for CrossThreadTask and its use of CrossThreadCopier.
18342
18343        Remove the explicit use of this pointer in some lambdas -- it is captured automatically when
18344        capturing by value, so enforcing its capturing through explicit use is not necessary.
18345
18346        * workers/DefaultSharedWorkerRepository.cpp:
18347        (WebCore::SharedWorkerProxy::postExceptionToWorkerObject):
18348        (WebCore::SharedWorkerProxy::postConsoleMessageToWorkerObject):
18349        (WebCore::postExceptionTask): Deleted.
18350        (WebCore::postConsoleMessageTask): Deleted.
18351        * workers/WorkerMessagingProxy.cpp:
18352        (WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
18353        (WebCore::WorkerMessagingProxy::postConsoleMessageToWorkerObject):
18354        (WebCore::WorkerMessagingProxy::workerObjectDestroyed):
18355        (WebCore::WorkerMessagingProxy::notifyNetworkStateChange):
18356        (WebCore::WorkerMessagingProxy::connectToInspector):
18357        (WebCore::WorkerMessagingProxy::disconnectFromInspector):
18358        (WebCore::WorkerMessagingProxy::sendMessageToInspector):
18359        (WebCore::WorkerMessagingProxy::postMessageToPageInspector):
18360        (WebCore::WorkerMessagingProxy::confirmMessageFromWorkerObject):
18361        (WebCore::WorkerMessagingProxy::reportPendingActivity):
18362        (WebCore::postConsoleMessageTask): Deleted.
18363        (WebCore::WorkerMessagingProxy::workerObjectDestroyedInternal): Deleted.
18364        (WebCore::connectToWorkerGlobalScopeInspectorTask): Deleted.
18365        (WebCore::disconnectFromWorkerGlobalScopeInspectorTask): Deleted.
18366        (WebCore::dispatchOnInspectorBackendTask): Deleted.
18367        * workers/WorkerMessagingProxy.h:
18368
183692014-06-06  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
18370
18371        Scheme of content utils should be compared in an ASCII case-insensitive manner
18372        https://bugs.webkit.org/show_bug.cgi?id=133502
18373
18374        Reviewed by Darin Adler.
18375
18376        According to spec, scheme must be compared in an ASCII case-insensitive manner by user agents.
18377
18378        Covered by existing tests.
18379
18380        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
18381        (WebCore::isProtocolWhitelisted):
18382
183832014-06-06  Andreas Kling  <akling@apple.com>
18384
18385        Indexed getters should return values directly on the PropertySlot.
18386        <https://webkit.org/b/133586>
18387
18388        Make indexed getters more efficient by using PropertySlot::setValue()
18389        to pass the value directly back through the slot, instead of giving it
18390        a function pointer that JSC would then immediately call back through
18391        to retrieve the value.
18392
18393        The function pointer approach would make sense if we did inline caching
18394        of indexed getters but since we currently don't, this is pure overhead.
18395
18396        Reviewed by Darin Adler.
18397
18398        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
18399        (WebCore::JSCSSStyleDeclaration::getOwnPropertySlotDelegate):
18400        (WebCore::cssPropertyGetterPixelOrPosPrefixCallback): Deleted.
18401        (WebCore::cssPropertyGetterCallback): Deleted.
18402        * bindings/js/JSDOMWindowCustom.cpp:
18403        (WebCore::JSDOMWindow::getOwnPropertySlot):
18404        (WebCore::JSDOMWindow::getOwnPropertySlotByIndex):
18405        (WebCore::indexGetter): Deleted.
18406        * bindings/scripts/CodeGeneratorJS.pm:
18407        (GenerateGetOwnPropertySlotBody):
18408        (GenerateHeader):
18409        (GetIndexedGetterExpression):
18410        (GenerateImplementation):
18411        * bridge/runtime_array.cpp:
18412        (JSC::RuntimeArray::getOwnPropertySlot):
18413        (JSC::RuntimeArray::getOwnPropertySlotByIndex):
18414        (JSC::RuntimeArray::indexGetter): Deleted.
18415        * bridge/runtime_array.h:
18416
184172014-06-06  Brent Fulgham  <bfulgham@apple.com>
18418
18419        GenericCueData elements prematurely removed
18420        https://bugs.webkit.org/show_bug.cgi?id=133588
18421
18422        Reviewed by Eric Carlson.
18423
18424        Add a 'removeCompletedCues' method instead of using the 'resetCueValues' method
18425        after processing new cues. We do not want to reset cue state if we have pending
18426        cues that are being extended by future updates (such as paint-on cues).
18427
18428        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
18429        (WebCore::InbandTextTrackPrivateAVF::processCue):  Call new 'removeCompletedCues' method.
18430        (WebCore::InbandTextTrackPrivateAVF::removeCompletedCues): Added.
18431        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
18432
184332014-06-06  Brady Eidson  <beidson@apple.com>
18434
18435        Initialize a char* that needs to be initialized.
18436        <rdar://problem/15840022> and https://bugs.webkit.org/show_bug.cgi?id=133585
18437
18438        Reviewed by Mark Rowe.
18439
18440        r152134 (erroneously) removed this initialization.
18441
18442        * platform/sql/SQLiteStatement.cpp:
18443        (WebCore::SQLiteStatement::prepare): tail should start out initialized to 0.
18444
184452014-06-06  Alexey Proskuryakov  <ap@apple.com>
18446
18447        [iOS] Support pasting HTML
18448        https://bugs.webkit.org/show_bug.cgi?id=133581
18449        <rdar://problem/17070305>
18450
18451        Reviewed by Enrica Casucci.
18452
18453        We can probably share a lot of code between Mac and iOS here, but for now, just
18454        implement the unimplemented functions.
18455
18456        * editing/ios/EditorIOS.mm: (WebCore::Editor::WebContentReader::readHTML):
18457        Implemented based on WebArchive reading code above, and on Mac version of readHTML.
18458        Unlike on Mac, we don't need to support Microsoft CF_HTML format, as nothing
18459        generates it.
18460
18461        * platform/ios/PasteboardIOS.mm:
18462        (WebCore::Pasteboard::read):
18463        (WebCore::Pasteboard::supportedPasteboardTypes):
18464        Added HTML support, as the second preferred format after WebArchive.
18465
184662014-06-06  Alexey Proskuryakov  <ap@apple.com>
18467
18468        Try to fix the build after http://trac.webkit.org/changeset/169655
18469
18470        Unfortunately, the fix is very fragile, and will likely not work for some SDKs
18471        or possibly local headers - all OS versions have multiple SecBsse.h headers with
18472        different definitions for SecIdentityRef.
18473
18474        We'll see.
18475
18476        * WebCore.exp.in:
18477
184782014-06-06  Dan Bernstein  <mitz@apple.com>
18479
18480        WebCore part of <rdar://problem/17095692> [iOS] Client-certificate authentication isn’t working
18481        https://bugs.webkit.org/show_bug.cgi?id=133527
18482
18483        Reviewed by Darin Adler.
18484
18485        * WebCore.exp.in: Exported some Credential member functions.
18486
184872014-06-06  Dean Jackson  <dino@apple.com>
18488
18489        [iOS WebGL] Float texture extension has a slightly different name
18490        https://bugs.webkit.org/show_bug.cgi?id=133580
18491        <rdar://problem/17113451>
18492
18493        Reviewed by Brady Eidson.
18494
18495        Floating point textures were not available on iOS, because we were
18496        looking for the wrong extension.
18497
18498        Covered by the Khronos test (and in LayoutTests):
18499        conformance/extensions/oes-texture-float.html
18500
18501        * platform/graphics/opengl/Extensions3DOpenGL.cpp:
18502        (WebCore::Extensions3DOpenGL::supportsExtension): Look for GL_OES_texture_float
18503        as well as GL_ARB_texture_float.
18504        * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
18505        (WebCore::GraphicsContext3D::texImage2D): Increase the set of things skipped
18506        on PLATFORM(IOS) since they are supported natively there.
18507
185082014-06-05  David Hyatt  <hyatt@apple.com>
18509
18510        REGRESSION: Hit testing of composited elements is broken in new multicolumn layout.
18511        https://bugs.webkit.org/show_bug.cgi?id=133522 (<rdar://problem/17060556>)
18512        
18513        Reviewed by Simon Fraser.
18514
18515        Hit testing for the new columns doesn't care about compositing but does still
18516        need a pagination layer set to work. The old column code didn't care about this
18517        because it was top down (and wrong). The new code lets each layer paint and hit
18518        test its own fragments, so having a pagination layer set suddenly becomes relevant
18519        for composited layers.
18520    
18521        The solution is to cache whether or not the pagination layer crosses a compositing
18522        boundary, and then to force call sites of enclosingPaginationLayer to pass an argument
18523        indicating whether compositing layers should be included. Typically painting wants to
18524        exclude them but hit testing wants to include them.
18525
18526        * page/FrameView.cpp:
18527        (WebCore::updateLayerPositionFlags):
18528        * rendering/RenderLayer.cpp:
18529        (WebCore::RenderLayer::RenderLayer):
18530        (WebCore::RenderLayer::updateLayerPositions):
18531        (WebCore::RenderLayer::updatePagination):
18532        (WebCore::transparencyClipBox):
18533        (WebCore::RenderLayer::paintLayer):
18534        (WebCore::RenderLayer::paintLayerContents):
18535        (WebCore::RenderLayer::enclosingPaginationLayerInSubtree):
18536        (WebCore::RenderLayer::collectFragments):
18537        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
18538        (WebCore::RenderLayer::hitTestLayer):
18539        (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
18540        (WebCore::RenderLayer::calculateClipRects):
18541        * rendering/RenderLayer.h:
18542        * rendering/RenderLayerCompositor.cpp:
18543        (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
18544
185452014-06-06  Kiran  <kiran.guduru@samsung.com>
18546
18547        [MediaStream] 'get' prefix is missing for capabilities and constraints.
18548        https://bugs.webkit.org/show_bug.cgi?id=133573
18549
18550        Reviewed by Eric Carlson.
18551
18552        Modified the existing MediaStreamTrack.html to test the changes.
18553
18554        As per the Media Capture and Streams spec method names constreaints and
18555        capabilities should be prefixed by 'get'. So updated the method names.
18556
18557        * Modules/mediastream/MediaStreamTrack.cpp:
18558        (WebCore::MediaStreamTrack::getConstraints):
18559        (WebCore::MediaStreamTrack::getCapabilities):
18560        (WebCore::MediaStreamTrack::constraints): Deleted.
18561        (WebCore::MediaStreamTrack::capabilities): Deleted.
18562        * Modules/mediastream/MediaStreamTrack.h:
18563        * Modules/mediastream/MediaStreamTrack.idl:
18564
185652014-06-05  Brent Fulgham  <bfulgham@apple.com>
18566
18567        REGRESSION(169440): Repro crash when playing a video with captions
18568        https://bugs.webkit.org/show_bug.cgi?id=133459
18569        <rdar://problem/17079081>
18570
18571        Reviewed by Eric Carlson.
18572
18573        The change I made in r169440 introduced a crash for paint-on captions. This
18574        resolves the problem as follows:
18575        1. No longer attempt to modify the start/endTime in the TextTrack implementation.
18576        2. Check for extensions to existing cues when we are about to add new arriving
18577           cues. If they extend a current pending cue, don't set an end-time for the
18578           pending cue, and throw away the new duplicate. Otherwise set the end time
18579           as previously and continue.
18580
18581        * html/track/TextTrack.cpp:
18582        (WebCore::TextTrack::hasCue): Remove 'doesExtendCue' case since this is
18583        no longer possible.
18584        * platform/graphics/InbandTextTrackPrivateClient.h:
18585        (WebCore::GenericCueData::doesExtendCueData): Added.
18586        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
18587        (WebCore::InbandTextTrackPrivateAVF::processCue): Check for cues extending
18588        other cues and handle appropriately.
18589
185902014-06-06  Brent Fulgham  <bfulgham@apple.com>
18591
18592        ROLLOUT: r169630: Caused a retain cycle.
18593        https://bugs.webkit.org/show_bug.cgi?id=133463
18594        <rdar://problem/17098100>
18595
18596        Rolling out this change as it introduced a retain cycle.
18597
18598        * Modules/mediacontrols/MediaControlsHost.cpp:
18599        (WebCore::MediaControlsHost::setControllerJSObject): Deleted.
18600        * Modules/mediacontrols/MediaControlsHost.h:
18601        (WebCore::MediaControlsHost::controllerJSValue):
18602        (WebCore::MediaControlsHost::setControllerJSValue):
18603        (WebCore::MediaControlsHost::controllerJSObject): Deleted.
18604        * html/HTMLMediaElement.cpp:
18605        (WebCore::HTMLMediaElement::parseAttribute):
18606
186072014-06-05  Dean Jackson  <dino@apple.com>
18608
18609        StyleResolver doesn't compile without CSS_GRID_LAYOUT enabled
18610        https://bugs.webkit.org/show_bug.cgi?id=133568
18611
18612        Reviewed by Tim Horton.
18613
18614        * css/StyleResolver.cpp:
18615        (WebCore::isDisplayGridBox): Add UNUSED_PARAM.
18616
186172014-06-05  Mihnea Ovidenie  <mihnea@adobe.com>
18618
18619        [CSSRegions] Region box incorrectly overlaps floating box
18620        https://bugs.webkit.org/show_bug.cgi?id=133545
18621
18622        Reviewed by David Hyatt.
18623
18624        A region box creates a BFC and it should not overlap a floating box in the same formatting context: http://www.w3.org/TR/CSS21/visuren.html#bfc-next-to-float
18625
18626        Test: fast/regions/region-as-bfc-avoids-float.html
18627
18628        * rendering/RenderBlock.cpp:
18629        (WebCore::RenderBlock::avoidsFloats):
18630
186312014-06-05  Yoav Weiss  <yoav@yoav.ws>
18632
18633        Align srcset parser with recent spec changes
18634        https://bugs.webkit.org/show_bug.cgi?id=133504
18635
18636        Reviewed by Darin Adler.
18637
18638        New tests were added to fast/hidpi/image-srcset-invalid-descriptor.html
18639
18640        The srcset parser changes align it with the spec:
18641        http://picture.responsiveimages.org/#parse-srcset-attr.
18642        The spec changes are meant to give the parser better future
18643        compatibility, and enable it to work well with the 'w' descriptor, the
18644        soon to be added 'h' descriptor and function descriptors (e.g.
18645        future-descriptor(a, b, c) ).
18646
18647        * CMakeLists.txt:
18648        * WebCore.vcxproj/WebCore.vcxproj:
18649        * WebCore.vcxproj/WebCore.vcxproj.filters:
18650        * WebCore.xcodeproj/project.pbxproj:
18651        * html/HTMLImageElement.cpp:
18652        (WebCore::HTMLImageElement::setBestFitURLAndDPRFromImageCandidate):
18653        (WebCore::HTMLImageElement::parseAttribute):
18654        * html/HTMLImageElement.h:
18655        * html/parser/HTMLParserIdioms.h:
18656        (WebCore::isHTMLSpace):
18657        (WebCore::isComma):
18658        (WebCore::isHTMLSpaceOrComma):
18659        * html/parser/HTMLPreloadScanner.cpp:
18660        (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
18661        * html/parser/HTMLSrcsetParser.cpp:
18662        (WebCore::compareByDensity):
18663        (WebCore::appendDescriptorAndReset):
18664        (WebCore::appendCharacter):
18665        (WebCore::isEOF):
18666        (WebCore::tokenizeDescriptors):
18667        (WebCore::stringViewToFloat):
18668        (WebCore::stringViewToInt):
18669        (WebCore::parseDescriptors):
18670        (WebCore::parseImageCandidatesFromSrcsetAttribute):
18671        (WebCore::pickBestImageCandidate):
18672        (WebCore::bestFitSourceForImageAttributes):
18673        (WebCore::compareByScaleFactor): Deleted.
18674        (WebCore::parseImagesWithScaleFromSrcsetAttribute): Deleted.
18675        * html/parser/HTMLSrcsetParser.h:
18676        (WebCore::DescriptorParsingResult::DescriptorParsingResult):
18677        (WebCore::DescriptorParsingResult::hasDensity):
18678        (WebCore::DescriptorParsingResult::hasWidth):
18679        (WebCore::DescriptorParsingResult::hasHeight):
18680        (WebCore::DescriptorParsingResult::density):
18681        (WebCore::DescriptorParsingResult::resourceWidth):
18682        (WebCore::DescriptorParsingResult::resourceHeight):
18683        (WebCore::DescriptorParsingResult::setResourceWidth):
18684        (WebCore::DescriptorParsingResult::setResourceHeight):
18685        (WebCore::DescriptorParsingResult::setDensity):
18686        (WebCore::ImageCandidate::ImageCandidate):
18687        (WebCore::ImageCandidate::toString):
18688        (WebCore::ImageCandidate::url):
18689        (WebCore::ImageCandidate::setDensity):
18690        (WebCore::ImageCandidate::density):
18691        (WebCore::ImageCandidate::resourceWidth):
18692        (WebCore::ImageCandidate::srcOrigin):
18693        (WebCore::ImageCandidate::isEmpty):
18694        (WebCore::ImageWithScale::ImageWithScale): Deleted.
18695        (WebCore::ImageWithScale::imageURL): Deleted.
18696        (WebCore::ImageWithScale::scaleFactor): Deleted.
18697        * html/parser/ParsingUtilities.h: Renamed from Source/WebCore/html/track/ParsingUtilities.h.
18698        (skipExactly):
18699        (skipUntil):
18700        (skipWhile):
18701        (reverseSkipWhile):
18702
187032014-06-05 Wenson Hsieh  <wenson_hsieh@apple.com>
18704
18705        Current media controls look different from previous media controls. Adjusted CSS to make media elements more similar by adding padding, adjusting hues/svg, resizing elements, etc.
18706
18707        https://bugs.webkit.org/show_bug.cgi?id=133521
18708
18709        Reviewed by Eric Carlson.
18710
18711        The main issues:
18712        - The widths between elements of both audio and video players are incorrect.
18713        - The hues of audio player elements are incorrect.
18714        - The hues of video player elements are content dependent (refer to full-screen mode), and this cannot be exactly replicated using just css. This patch only attempts to make them more similar.
18715        - The height of the audio player is incorrect.
18716
18717        Test: platform/ios-sim/media/audio-width.html
18718
18719        * Modules/mediacontrols/mediaControlsiOS.css: Updated style elements for audio/video elements.
18720        (::-webkit-media-controls): Enforce a minimum width on audio/video controls.
18721        (audio): Enforce a minimum width on audio elements.
18722        (audio::-webkit-media-controls): see below
18723        (audio::-webkit-media-controls-wireless-playback-picker-button): modified SVG, hue and width/height.
18724        (audio::-webkit-media-controls-panel): adjusted hue, added left/right padding.
18725        (audio::-webkit-media-controls-fullscreen-button): removed. There's no fullscreen for audio anyways.
18726        (audio::-webkit-media-controls-current-time-display): adjusted font size, added left padding.
18727        (audio::-webkit-media-controls-time-remaining-display): adjusted font size, added right padding.
18728
18729        (video::-webkit-media-controls-panel): adjusted hue, added left/right padding.
18730        (video::-webkit-media-controls-current-time-display): added left padding.
18731        (video::-webkit-media-controls-time-remaining-display): added right padding.
18732        (video::-webkit-media-controls-wireless-playback-picker-button): modified SVG, hue, opacity and width/height.
18733        (video::-webkit-media-controls-fullscreen-button): modified SVG, hue, opacity, and width/height. In particular, made the svg seem sharper.
18734        (video::-webkit-media-controls-play-button): modified SVG, hue, opacity, and width/height.
18735
187362014-06-05  Commit Queue  <commit-queue@webkit.org>
18737
18738        Unreviewed, rolling out r169570.
18739        https://bugs.webkit.org/show_bug.cgi?id=133565
18740
18741        It breaks Baidu (Requested by benjaminp on #webkit).
18742
18743        Reverted changeset:
18744
18745        "[iOS] Start ignoring common bogus viewport parameters"
18746        https://bugs.webkit.org/show_bug.cgi?id=133466
18747        http://trac.webkit.org/changeset/169570
18748
187492014-06-05  Michael Timbrook  <timbrook@apple.com>
18750
18751        AX: Add support for ARIA 1.1 'none' role
18752        https://bugs.webkit.org/show_bug.cgi?id=133367
18753
18754        Reviewed by Chris Fleizach.
18755
18756        Added support for the 'none' role by added a lookup for it to go to PresentationalRole
18757        Test: accessibility/aria-none-role.html
18758
18759        * accessibility/AccessibilityObject.cpp:
18760        (WebCore::initializeRoleMap):
18761
187622014-06-05  Joanmarie Diggs  <jdiggs@igalia.com>
18763
18764        AX: [ATK] Children of tables and lists with role='presentation' should each be exposed as if they were div elements
18765        https://bugs.webkit.org/show_bug.cgi?id=133133
18766
18767        Reviewed by Chris Fleizach.
18768
18769        When a table or list has role='presentation', accessibility is "ignored"
18770        for that element, but not for the required children. The default roles
18771        for the children (CellRole and ListItemRole) do not make sense without
18772        the parent, therefore map them to DivRole in ATK if they inherit the
18773        presentational role.
18774
18775        Test: accessibility/aria-inherits-presentational.html
18776
18777        * accessibility/AccessibilityObject.h:
18778        (WebCore::AccessibilityObject::inheritsPresentationalRole):
18779        * accessibility/AccessibilityRenderObject.cpp:
18780        (WebCore::AccessibilityRenderObject::inheritsPresentationalRole):
18781        * accessibility/AccessibilityRenderObject.h:
18782        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
18783        (atkRole):
18784
187852014-06-05  Brent Fulgham  <bfulgham@apple.com>
18786
18787        REGRESSION (r167962): Out of bounds read in JSC::StructureIDTable::get() 
18788        https://bugs.webkit.org/show_bug.cgi?id=133463
18789        <rdar://problem/17098100>
18790
18791        Reviewed by Dean Jackson.
18792
18793        Revise MediaControllerHost implementation so that it holds a Strong
18794        reference to the JavaScript 'Controller' object it mirrors. The
18795        MediaControllerHost is constructed when we create an HTMLMediaElement,
18796        and is the logical place to retain ownership of the JS object so that
18797        it does not get garbage collected as long as HTMLMediaElement exists.
18798
18799        * Modules/mediacontrols/MediaControlsHost.cpp:
18800        (WebCore::MediaControlsHost::setControllerJSObject): Create a strong
18801        reference to the JavaScript Controller object.
18802        * Modules/mediacontrols/MediaControlsHost.h: Use JSC::Strong to hold a
18803        JSObject, rather than a bare JSValue.
18804        (WebCore::MediaControlsHost::controllerJSObject): Change name to reflect
18805        that we are working with JSObjects, not JSValues.
18806        (WebCore::MediaControlsHost::controllerJSValue): Deleted.
18807        (WebCore::MediaControlsHost::setControllerJSValue): Deleted.
18808        * html/HTMLMediaElement.cpp:
18809        (WebCore::HTMLMediaElement::parseAttribute): Revise for changed method
18810        signature.
18811
188122014-06-05  Benjamin Poulain  <bpoulain@apple.com>
18813
18814        [iOS][WK2] Add device orientation
18815        https://bugs.webkit.org/show_bug.cgi?id=133530
18816
18817        Reviewed by Tim Horton.
18818
18819        Previously, WebCore was getting the orientation directly from the WebKit layer.
18820        This had to be done during the frame creation and was very fragile.
18821
18822        Frame is changed to pull the value from the chrome client. That way we avoid races
18823        and we can maintain a single value for all frames.
18824
18825        Sending the values to all the subframes is aslo done here so that we do not have to repeat
18826        it in both WebKit layers.
18827
18828        * WebCore.exp.in:
18829        * loader/EmptyClients.h:
18830        * page/ChromeClient.h:
18831        * page/Frame.cpp:
18832        (WebCore::Frame::Frame):
18833        (WebCore::Frame::orientationChanged):
18834        (WebCore::Frame::orientation):
18835        (WebCore::Frame::sendOrientationChangeEvent): Deleted.
18836        * page/Frame.h:
18837        (WebCore::Frame::orientation): Deleted.
18838
188392014-06-05  Timothy Horton  <timothy_horton@apple.com>
18840
18841        Fix the !CACHE_SUBIMAGES build
18842
18843        * platform/graphics/cg/GraphicsContextCG.cpp:
18844        (WebCore::GraphicsContext::drawNativeImage):
18845
188462014-06-05  Yusuke Suzuki  <utatane.tea@gmail.com>
18847
18848        CSS JIT: Clean up StackAllocator
18849        https://bugs.webkit.org/show_bug.cgi?id=133506
18850
18851        Reviewed by Benjamin Poulain.
18852
18853        Cleaning up CSS JIt StackAllocator code. Sharing push / pop code and
18854        using information provided by MacroAssembler more aggressively
18855        to drop ifdefs.
18856
18857        * cssjit/StackAllocator.h:
18858        (WebCore::StackAllocator::allocateUninitialized):
18859        (WebCore::StackAllocator::push):
18860        (WebCore::StackAllocator::pop):
18861        (WebCore::StackAllocator::popAndDiscard):
18862        (WebCore::StackAllocator::popAndDiscardUpTo):
18863        (WebCore::StackAllocator::alignStackPreFunctionCall):
18864        (WebCore::StackAllocator::unalignStackPostFunctionCall):
18865        (WebCore::StackAllocator::stackUnitInBytes):
18866
188672014-06-05  Zalan Bujtas  <zalan@apple.com>
18868
18869        Subpixel rendering: border-radius painting falls back to rectangle when the snapped rounded rect becomes non-renderable.
18870        https://bugs.webkit.org/show_bug.cgi?id=133491
18871
18872        Reviewed by Simon Fraser.
18873
18874        Pixel snapping can change the rectangle's size when it is on a certain subpixel position. (usually it does not)
18875        This patch ensures that the snapped rect is still renderable by adjusting the radii as well.
18876
18877        Test: fast/borders/hidpi-border-radius-with-subpixel-margin-not-renderable.html
18878
18879        * platform/graphics/RoundedRect.cpp:
18880        (WebCore::RoundedRect::Radii::scale):
18881        (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
18882        * platform/graphics/RoundedRect.h:
18883
188842014-06-05  Commit Queue  <commit-queue@webkit.org>
18885
18886        Unreviewed, rolling out r169587.
18887        https://bugs.webkit.org/show_bug.cgi?id=133552
18888
18889        Calls a pure virtual method, crashes (Requested by ap on
18890        #webkit).
18891
18892        Reverted changeset:
18893
18894        "WebKit should adopt journal_mode=wal for all SQLite
18895        databases."
18896        https://bugs.webkit.org/show_bug.cgi?id=133496
18897        http://trac.webkit.org/changeset/169587
18898
188992014-06-05  Frédéric Wang  <fred.wang@free.fr>
18900
18901        Apply Character-level mirroring to stretchy operators in RTL mode.
18902        https://bugs.webkit.org/show_bug.cgi?id=130839
18903
18904        Reviewed by Chris Fleizach.
18905
18906        We add support for character-level mirroring for stretchy MathML operators in RTL mode.
18907        Glyph-level mirroring (via the rtlm OpenType feature) will be handled in bug 130840.
18908
18909        Test: mathml/presentation/stretchy-rtl.html
18910
18911        * rendering/mathml/RenderMathMLOperator.cpp: reorganize the Unicode stretchyCharacters table to make mirroring easy.
18912        (WebCore::RenderMathMLOperator::computePreferredLogicalWidths): pass the right boolean to glyphDataForCharacter.
18913        (WebCore::RenderMathMLOperator::getDisplayStyleLargeOperator): ditto
18914        (WebCore::RenderMathMLOperator::findStretchyData): ditto and change the index for the stretchyCharacters fallback.
18915        (WebCore::RenderMathMLOperator::updateStyle): pass the right boolean to glyphDataForCharacter.
18916        (WebCore::RenderMathMLOperator::paint): remove the FIXME comment.
18917        (WebCore::RenderMathMLOperator::paintVerticalGlyphAssembly): switch the leading/trailing space in RTL mode.
18918
189192014-06-05  Zalan Bujtas  <zalan@apple.com>
18920
18921        Subpixel rendering: Buttons in default media controls shift vertically when controls fade in or out.
18922        https://bugs.webkit.org/show_bug.cgi?id=133488
18923
18924        Reviewed by Simon Fraser.
18925
18926        Filter effects are not subpixel aware yet. They paint to integrally sized image buffers.
18927        In order to ensure that the content is rendered to the the same position on the filter 
18928        source context as if there was no filter, the repaint rects need to be adjusted to match with
18929        the internal filter snapping (enclosingIntRect).
18930        This is a temporary change until after filter effects get subpixelized.
18931
18932        However, this changeset regresses RenderNameFlow clipping when the content is on subpixel position
18933        and filter effect is present. Instead of adding the failing test cases to TestExpectations, I removed
18934        the video controls from the <video> to make the tests pass, when possible (they just happen to have <video>)
18935        and filed webkit.org/b/133523 to track the regression.
18936
18937        Test: css3/filters/filter-is-on-subpixel-position.html
18938
18939        * rendering/RenderLayer.cpp:
18940        (WebCore::RenderLayer::setupFilters):
18941
189422014-06-05  Kiran  <kiran.guduru@samsung.com>
18943
18944        [MediaStream] MediaStream.addTrack should not check for tracks ended state.
18945        https://bugs.webkit.org/show_bug.cgi?id=133510
18946
18947        Reviewed by Eric Carlson.
18948
18949        Adding and removing of tracks to a MediaStream should not have dependency
18950        on tracks state. So the check for MediaStreamTrack's ended state has been
18951        removed while adding a track in MediaStreamPrivate.cpp.
18952
18953        Test: fast/mediastream/MediaStream-add-ended-tracks.html
18954
18955        * platform/mediastream/MediaStreamPrivate.cpp:
18956        (WebCore::MediaStreamPrivate::addTrack):
18957
189582014-06-05  Gwang Yoon Hwang  <yoon@igalia.com>
18959
18960        [GTK] Remove ScrollViewGtk.cpp
18961        https://bugs.webkit.org/show_bug.cgi?id=133535
18962
18963        Reviewed by Carlos Garcia Campos.
18964
18965        Because GTK+ WK1 was removed, we don't have to consider special cases
18966        handled in ScrollViewGtk.cpp.
18967
18968        No new tests are necessary because there is no behavior change.
18969
18970        * PlatformGTK.cmake:
18971        * platform/ScrollView.cpp:
18972        (WebCore::ScrollView::setScrollbarModes):
18973        (WebCore::ScrollView::visibleContentRectInternal):
18974        * platform/gtk/ScrollViewGtk.cpp: Removed.
18975
189762014-06-05  Frédéric Wang  <fred.wang@free.fr>
18977
18978        MathML operators not stretched horizontally
18979        https://bugs.webkit.org/show_bug.cgi?id=72828
18980
18981        Reviewed by Chris Fleizach.
18982
18983        This patch adds basic horizontal stretching rules for operators inside
18984        an <munder>, <mover> or <munderover> elements. The stretchy operators
18985        in such an element stretch to cover the size of the non-stretchy
18986        operators. This only works when fonts that have an OpenType MATH table
18987        are used.
18988
18989        Tests: mathml/opentype/horizontal-LatinModern.html
18990               mathml/opentype/opentype-stretchy-horizontal.html
18991               mathml/opentype/horizontal-LatinModern-munderover.html
18992
18993        * rendering/mathml/RenderMathMLOperator.cpp:
18994        (WebCore::MathMLOperatorDictionary::ExtractKeyHorizontal): We add an ordered list of operators that have horizontal stretch direction.
18995        (WebCore::RenderMathMLOperator::RenderMathMLOperator): init m_Vertical
18996        (WebCore::RenderMathMLOperator::SetOperatorProperties): set m_Vertical by checking whether the operator is in the horizontalOperators list.
18997        (WebCore::RenderMathMLOperator::stretchTo): We do not stretch vertically
18998        if the operator has horizontal direction.
18999        We also add a new version stretchTo(LayoutUnit width) for horizontal stretching only.
19000        (WebCore::RenderMathMLOperator::computePreferredLogicalWidths): Handle horizontal stretching: the maximumGlyphWidth is the maximum of
19001        the base size or of the stretch size.
19002        (WebCore::RenderMathMLOperator::getDisplayStyleLargeOperator): Add an ASSERT to ensure that this function is only called for vertical stretching.
19003        (WebCore::RenderMathMLOperator::findStretchyData): Add an ASSERT to ensure that this function is not called to get the maximum width of a horizontal stretchy operator.
19004        We take into account m_isVertical when calling getMathVariants or computing sizes.
19005        There is not any Unicode-only construction for horizontal stretching, so a MATH table is required for horizontal stretching.
19006        (WebCore::RenderMathMLOperator::updateStyle): Ignore some code paths specific to vertical stretching and take into account the m_Vertical parameters.
19007        For horizontal stretching, the m_stretch*Baseline parameters are now updated to match the metrics of the size variant or of the maximum of the parts in the glyph assembly.
19008        (WebCore::RenderMathMLOperator::computeLogicalHeight): logicalHeight is now explicitely the sum of m_stretchHeightAboveBaseline and m_stretchDepthBelowBaseline, since it can be different from the stretchSize() in horizontal stretching.
19009        (WebCore::RenderMathMLOperator::paintGlyph): handle trimming for horizontal stretching.
19010        (WebCore::RenderMathMLOperator::fillWithVerticalExtensionGlyph): rename the function and ensure it is only call for m_isVertical.
19011        (WebCore::RenderMathMLOperator::fillWithHorizontalExtensionGlyph): same as fillWithVerticalExtensionGlyph, but for horizontal stretching.
19012        (WebCore::RenderMathMLOperator::paint): For glyph assembly, choose between paintVerticalGlyphAssembly or paintHorizontalGlyphAssembly.
19013        (WebCore::RenderMathMLOperator::paintVerticalGlyphAssembly): rename the function and ensure it is only call for m_isVertical.
19014        (WebCore::RenderMathMLOperator::paintHorizontalGlyphAssembly): same as paintVerticalGlyphAssembly but for horizontal stretching.
19015        * rendering/mathml/RenderMathMLOperator.h: we add a m_isVertical member to indicate the stretch direction and a m_stretchWidth to indicate the width of the stretchy character.
19016        We define the horizontal counterparts of fillWith*ExtensionGlyph, paint*GlyphAssembly, GlyphPaintTrimming  StretchyData.
19017        Finally stretchSize() takes into account the stretch direction.
19018        * rendering/mathml/RenderMathMLUnderOver.cpp: We override the layout() function to stretch munderover children horizontally.
19019        (WebCore::RenderMathMLUnderOver::layout):
19020        * rendering/mathml/RenderMathMLUnderOver.h: we declare layout().
19021
190222014-06-04  Bem Jones-Bey  <bjonesbe@adobe.com>
19023
19024        [CSS Shapes] Image lifetime is not properly handled for gradient shapes
19025        https://bugs.webkit.org/show_bug.cgi?id=133414
19026
19027        Reviewed by Simon Fraser.
19028
19029        Refactor computedShape() and it's helpers to be able to properly
19030        manage the lifetime of the image returned from StyleImage.
19031
19032        This is a port of a Blink patch by Hans Muller.
19033
19034        Test: fast/shapes/shape-outside-floats/shape-outside-uncached-gradient.html
19035
19036        * rendering/shapes/ShapeOutsideInfo.cpp:
19037        (WebCore::ShapeOutsideInfo::createShapeForImage): Properly handle the
19038            lifetime of the image. Changed to use StyleImage::image() to get
19039            the image in all cases there's no need to special case cached
19040            images.
19041        (WebCore::ShapeOutsideInfo::computedShape): Call createShapeForImage.
19042        (WebCore::getShapeImageAndRect): Deleted.
19043        * rendering/shapes/ShapeOutsideInfo.h:
19044
190452014-06-04  Bem Jones-Bey  <bjonesbe@adobe.com>
19046
19047        [CSS Shapes] Fix off by one in creating a RasterShape
19048        https://bugs.webkit.org/show_bug.cgi?id=133499
19049
19050        Reviewed by Darin Adler.
19051
19052        Test: fast/shapes/shape-outside-floats/shape-outside-floats-shape-margin-crash.html
19053
19054        * rendering/shapes/RasterShape.cpp:
19055        (WebCore::RasterShapeIntervals::computeShapeMarginIntervals):
19056            marginY1 is supposed to be an inclusive endpoint, however, maxY()
19057            is an exclusive endpoint. This simply changes marginY1 into an
19058            exclusive endpoint.
19059
190602014-06-04  Benjamin Poulain  <bpoulain@apple.com>
19061
19062        [iOS][WK2] Restore the visual scroll position instead of the dom scroll position when restoring states from the history
19063        https://bugs.webkit.org/show_bug.cgi?id=133490
19064
19065        Reviewed by Tim Horton.
19066
19067        Expose the WebKit1 parameter "ScaleIsInitial". It is used for a similar concept in WebKit2 (userHasChangedPageScaleFactor).
19068
19069        Add "exposedContentPosition", which is the scroll position of the exposed rect.
19070
19071        * history/HistoryItem.h:
19072        (WebCore::HistoryItem::exposedContentPosition):
19073        (WebCore::HistoryItem::setExposedContentPosition):
19074        (WebCore::HistoryItem::setScaleIsInitial):
19075        * loader/HistoryController.cpp:
19076        (WebCore::HistoryController::saveScrollPositionAndViewStateToItem):
19077
190782014-06-04  Alex Christensen  <achristensen@webkit.org>
19079
19080        Enable WebGL on Windows.
19081        https://bugs.webkit.org/show_bug.cgi?id=133503
19082
19083        Reviewed by Brent Fulgham.
19084
19085        No new tests, but we should enable the webgl tests soon.
19086
19087        * html/canvas/WebGLRenderingContext.cpp:
19088        (WebCore::WebGLRenderingContext::markContextChanged):
19089        Check if the context and RenderBox are accelerated to use accelerated code path.
19090        * html/canvas/WebGLRenderingContext.h:
19091        Disable accelerated compositing on WebGL canvases until that works.
19092        * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
19093        (WebCore::GraphicsContext3D::reshapeFBOs):
19094        Compile fix after r166563.
19095
190962014-06-04  Benjamin Poulain  <benjamin@webkit.org>
19097
19098        Regression(r169547): Crash in WebCore::styleForFirstLetter() while loading http://thenextweb.com/apple/2014/02/21/apple-confirms-acquired-testflight-creator-burstly/
19099        https://bugs.webkit.org/show_bug.cgi?id=133500
19100
19101        Reviewed by Antti Koivisto.
19102
19103        Unlike the other tree marking optimization, adding HasPseudoStyle() on an element style
19104        during style resolution must be conservative and not set the flag unless every other filter
19105        matched first.
19106
19107        After r169547, the SelectorChecker was setting flags on HasPseudoStyle() during the pseudo
19108        element matching. If that passed but the remaining filter did not match, the element style
19109        could have the flag "FIRST_LETTER" while not being able to resolve a style for "FIRST_LETTER".
19110
19111        When the layout code was creating the renderer, it would find the FIRST_LETTER flag on the main style
19112        and try to get the specific style for FIRST_LETTER. Since no rule would resolve for FIRST_LETTER,
19113        the style would be null and the code would be crashing when accessing its parameters.
19114
19115        This patch fixes the issue by moving the style marking for pseudo element at the end of the matching.
19116
19117        Test: fast/css/first-letter-on-non-matching-selectors.html
19118
19119        * css/SelectorChecker.cpp:
19120        (WebCore::SelectorChecker::match):
19121        (WebCore::SelectorChecker::matchRecursively):
19122        * css/SelectorChecker.h:
19123        (WebCore::SelectorChecker::match): Deleted.
19124
191252014-06-04  Eric Carlson  <eric.carlson@apple.com>
19126
19127        [iOS] allow UA to specify network interface
19128        https://bugs.webkit.org/show_bug.cgi?id=133396
19129
19130        Reviewed by Jer Noble.
19131
19132        * html/HTMLMediaElement.cpp:
19133        (WebCore::HTMLMediaElement::mediaPlayerInterfaceName): Return settings->networkInterfaceName.
19134        * html/HTMLMediaElement.h:
19135
19136        * platform/graphics/MediaPlayer.cpp:
19137        (WebCore::MediaPlayer::mediaPlayerNetworkInterfaceName): Pass through the media element.
19138        * platform/graphics/MediaPlayer.h:
19139        (WebCore::MediaPlayerClient::mediaPlayerNetworkInterfaceName):
19140
19141        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
19142        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): If the media player
19143            wants to use a specific netork interface name, pass it to the AVAsset allocator.
19144
191452014-06-03  Jon Honeycutt  <jhoneycutt@apple.com>
19146
19147        Pasting multiple photos on iOS only pastes one photo
19148
19149        <https://bugs.webkit.org/show_bug.cgi?id=133495>
19150        <rdar://problem/16138616>
19151
19152        Reviewed by Alexey Proskuryakov.
19153
19154        * editing/ios/EditorIOS.mm:
19155        (WebCore::Editor::pasteWithPasteboard):
19156        Create a WebContentReader. For each pasteboard item, get the document
19157        fragment for that item, and add it to the reader. If we fail to get
19158        the fragment from the delegate, fall back to using
19159        webContentFromPasteboard() as before.
19160
191612014-06-04  Myles C. Maxfield  <litherum@gmail.com>
19162
19163        Use references instead of pointers for non-optional arguments during text layout
19164        https://bugs.webkit.org/show_bug.cgi?id=133501
19165
19166        Reviewed by Tim Horton.
19167
19168        This patch applies some cleanup to InlineBox layout functions to take
19169        references instead of pointers where appropriate.
19170
19171        No new tests are necessary because there is no behavior change.
19172
19173        * rendering/InlineFlowBox.cpp:
19174        (WebCore::InlineFlowBox::computeLogicalBoxHeights): Make the function take a
19175        reference to the RootInlineBox instead of a pointer. This function does some
19176        rounding.
19177        (WebCore::InlineFlowBox::addTextBoxVisualOverflow): Make the function take a
19178        reference to the InlineTextBox instead of a pointer.
19179        (WebCore::InlineFlowBox::computeOverflow): Update call to addTextBoxVisualOverflow
19180        to pass a reference instead of a pointer.
19181        * rendering/RootInlineBox.cpp:
19182        (WebCore::RootInlineBox::alignBoxesInBlockDirection): Update call to
19183        computeLogicalBoxHeights to pass a reference instead of a pointer.
19184        (WebCore::RootInlineBox::ascentAndDescentForBox): Make the function take a
19185        reference to the InlineBox instead of a pointer.
19186        (WebCore::RootInlineBox::includeLeadingForBox): Make the function take a reference
19187        instead of a pointer.
19188        (WebCore::RootInlineBox::includeFontForBox): Ditto.
19189        (WebCore::RootInlineBox::includeGlyphsForBox): Ditto.
19190        (WebCore::RootInlineBox::includeMarginForBox): Ditto.
19191        * rendering/RootInlineBox.h: Move functions that are not externally called into
19192        a private: section. In addition, update function signatures to take references
19193        instead of pointers.
19194
191952014-05-27  Myles C. Maxfield  <mmaxfield@apple.com>
19196
19197        Lists styled with SVG fonts are not rendered as expected
19198        https://bugs.webkit.org/show_bug.cgi?id=133198
19199
19200        Reviewed by Simon Fraser.
19201
19202        There were a couple places in RenderListMarker and RenderMenuList that were
19203        implicitly creating TextRuns by passing a String to a function which
19204        expected a TextRun. Because TextRun has a constructor which takes a single
19205        String and isn't marked explicit, TextRuns were being created without
19206        any of the associated code that initializes the TextRun (such as creating
19207        a RenderingContext if necessary).
19208
19209        There is currently one more client of this code that needs to be fixed.
19210        This is in RenderThemeIOS::adjustMenuListButtonStyle(). However, fixing
19211        this will be a somewhat large change, and is out of scope for this patch.
19212        I will submit a follow-up patch that fixes this permanently. Once this is
19213        fixed, I can mark TextRun's constructors as explicit.
19214
19215        Test: svg/custom/list-items-with-svg-font-family.html
19216
19217        * platform/graphics/TextRun.h:
19218        (WebCore::TextRun::TextRun): Mark constructors as explicit.
19219        * rendering/RenderListMarker.cpp:
19220        (WebCore::RenderListMarker::computePreferredLogicalWidths): Call
19221        RenderBlock::constructTextRun.
19222        (WebCore::RenderListMarker::getRelativeMarkerRect): Ditto.
19223        * rendering/RenderMenuList.cpp:
19224        (RenderMenuList::updateOptionsWidth): Ditto.
19225        * rendering/RenderThemeIOS.mm:
19226        (WebCore::adjustInputElementButtonStyle): Instead of crashing, mark
19227        form controls rendered with SVG fonts as having 0 width. This isn't
19228        perfect, but fixing this is out of scope for this patch.
19229
192302014-06-04  Andreas Kling  <akling@apple.com>
19231
19232        WebKit should adopt journal_mode=wal for all SQLite databases.
19233        <https://webkit.org/b/133496>
19234        <rdar://problem/15600186>
19235
19236        We already had code to enable write-ahead logging, but it didn't work
19237        since calling SQLiteStatement::step() without first calling prepare()
19238        is a no-op.
19239
19240        Converted it to use into a simple executeCommand() instead.
19241
19242        Reviewed by Brady Eidson.
19243
19244        * platform/sql/SQLiteDatabase.cpp:
19245        (WebCore::SQLiteDatabase::open):
19246
192472014-06-04  Radu Stavila  <stavila@adobe.com>
19248
19249        REGRESSION: [CSS Regions] Regions with overflow:auto generate scrollbars even if the content flows into the following regions and as such, should not be scrolled
19250        https://bugs.webkit.org/show_bug.cgi?id=133481
19251
19252        Reviewed by Antti Koivisto.
19253
19254        When enlarging the layout overflow of a scrollable region, the portion of the content that flows
19255        in the region must be taken into consideration. If the content continues to flow into the next
19256        region, the layout overflow of the current region must not be enlarged.
19257
19258        Test: fast/regions/scrollable-first-region.html
19259
19260        * rendering/RenderFlowThread.cpp:
19261        (WebCore::RenderFlowThread::addRegionsOverflowFromChild):
19262
192632014-06-03  Benjamin Poulain  <benjamin@webkit.org>
19264
19265        Fix some corner cases of :hover and :active in quirks mode
19266        https://bugs.webkit.org/show_bug.cgi?id=133493
19267
19268        Reviewed by Andreas Kling.
19269
19270        Previously, the quirks mode of :hover and :active were evaluated from the SelectorFragment
19271        in fragmentOnlyMatchesLinksInQuirksMode(). There were two problems with that approach:
19272        1) The FragmentGenerator optimizes out some filter when they always match or can never match.
19273           Those fragment should still qualify :hover and :active, but they were lost
19274           for fragmentOnlyMatchesLinksInQuirksMode().
19275        2) Explicitely listing every attribute of SelectorFragment in fragmentOnlyMatchesLinksInQuirksMode()
19276           was extremly fragile. When :not() and :-webkit-any() were added, we forgot to update the quirks
19277           exceptions.
19278
19279        This patch moves the quirks mode exception code from the code generator to the Fragment generator.
19280        The useless filters are no longer ignored for the quirks, and we don't need to update the quirks mode detection
19281        with every change of SelectorFragment.
19282
19283        It is inefficient and ugly, but that is how that quirks is defined. It is only a problem for compilation,
19284        execution time remains unchanged.
19285
19286        * cssjit/SelectorCompiler.cpp:
19287        (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
19288        (WebCore::SelectorCompiler::addPseudoClassType):
19289        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
19290        (WebCore::SelectorCompiler::pseudoClassOnlyMatchesLinksInQuirksMode):
19291        (WebCore::SelectorCompiler::constructFragments):
19292        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSpecialFailureInQuirksModeForActiveAndHoverIfNeeded):
19293        (WebCore::SelectorCompiler::fragmentOnlyMatchesLinksInQuirksMode): Deleted.
19294
192952014-06-03  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
19296
19297        Need to check invalid scheme in navigator content utils 
19298        https://bugs.webkit.org/show_bug.cgi?id=133296
19299
19300        Reviewed by Darin Adler.
19301
19302        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
19303        (WebCore::verifyProtocolHandlerScheme): Just fix a wrong typo.
19304
193052014-06-03  Timothy Horton  <timothy_horton@apple.com>
19306
19307        WebKit2 View Gestures (Zoom): Can show unpainted regions when zoom-pinching-out
19308        https://bugs.webkit.org/show_bug.cgi?id=133472
19309        <rdar://problem/15686848>
19310
19311        Reviewed by Simon Fraser.
19312
19313        * WebCore.exp.in:
19314
193152014-06-03  Yoav Weiss  <yoav@yoav.ws>
19316
19317        Refactor the srcset parser into its own file
19318        https://bugs.webkit.org/show_bug.cgi?id=133480
19319
19320        Reviewed by Andreas Kling.
19321
19322        No new tests, since this patch doesn't change the parser's behavior.
19323
19324        This patch moves the srcset parser into its own file,
19325        in order to prepare the code for alignment with recent spec changes.
19326
19327        * CMakeLists.txt:
19328        * html/HTMLImageElement.cpp:
19329        * html/parser/HTMLParserIdioms.cpp:
19330        (WebCore::compareByScaleFactor): Deleted.
19331        (WebCore::parseDescriptors): Deleted.
19332        (WebCore::parseImagesWithScaleFromSrcsetAttribute): Deleted.
19333        (WebCore::bestFitSourceForImageAttributes): Deleted.
19334        * html/parser/HTMLParserIdioms.h:
19335        (WebCore::ImageWithScale::ImageWithScale): Deleted.
19336        (WebCore::ImageWithScale::imageURL): Deleted.
19337        (WebCore::ImageWithScale::scaleFactor): Deleted.
19338        * html/parser/HTMLPreloadScanner.cpp:
19339        * html/parser/HTMLSrcsetParser.cpp: Added.
19340        (WebCore::compareByScaleFactor):
19341        (WebCore::parseDescriptors):
19342        (WebCore::parseImagesWithScaleFromSrcsetAttribute):
19343        (WebCore::bestFitSourceForImageAttributes):
19344        * html/parser/HTMLSrcsetParser.h: Added.
19345        (WebCore::ImageWithScale::ImageWithScale):
19346        (WebCore::ImageWithScale::imageURL):
19347        (WebCore::ImageWithScale::scaleFactor):
19348
193492014-06-03  Mario Sanchez Prada  <mario.prada@samsung.com>
19350
19351        [ATK] accessibility/textarea-selected-text-range.html is failing
19352        https://bugs.webkit.org/show_bug.cgi?id=133479
19353
19354        Reviewed by Chris Fleizach.
19355
19356        Implement atk_text_set_caret_offset() in terms of
19357        atk_text_set_selection() for zero-length selections.
19358
19359        No new tests needed, the following test should just start
19360        passing again now: accessibility/textarea-selected-text-range.html.
19361
19362        * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
19363        (webkitAccessibleTextSetCaretOffset): Reimplemented this function
19364        in terms of webkitAccessibleTextSetSelection().
19365
193662014-06-03  Alex Christensen  <achristensen@webkit.org>
19367
19368        Corrected arm64 assertion in css jit.
19369
19370        Rubber stamped by Benjamin Poulain.
19371
19372        * cssjit/StackAllocator.h:
19373        (WebCore::StackAllocator::pop):
19374        Changed assertion from incorrectly matching x86_64 to using the correct minimum offset,
19375        taking into account that a stackUnitInBytes is used for two registers on arm64
19376        except the last stack unit, which could only be used for one register if there are
19377        an odd number of registers.
19378
193792014-06-03  Benjamin Poulain  <bpoulain@apple.com>
19380
19381        [iOS] Start ignoring common bogus viewport parameters
19382        https://bugs.webkit.org/show_bug.cgi?id=133466
19383        <rdar://problem/16203396>
19384
19385        Reviewed by Sam Weinig.
19386
19387        Incorrect viewports are spreading really quickly lately. We have to start ignoring
19388        some combinations of arguments as they are almost always used incorrectly, causing
19389        a poor user experience on those websites.
19390
19391        * dom/ViewportArguments.cpp:
19392        (WebCore::finalizeViewportArguments):
19393
193942014-06-03  Yusuke Suzuki  <utatane.tea@gmail.com>
19395
19396        CSS JIT: add support for the "any" pseudo class
19397        https://bugs.webkit.org/show_bug.cgi?id=133473
19398
19399        Reviewed by Benjamin Poulain.
19400
19401        Add support for the :any pseudo class.
19402
19403        Test: fast/selectors/pseudo-class-any.html
19404
19405        * cssjit/SelectorCompiler.cpp:
19406        (WebCore::SelectorCompiler::addPseudoClassType):
19407        (WebCore::SelectorCompiler::minimumRegisterRequirements):
19408        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
19409        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesAnyPseudoClass):
19410
194112014-06-02  Jer Noble  <jer.noble@apple.com>
19412
19413        Update PlatformTimeRanges to use MediaTime rather than doubles for time values.
19414        https://bugs.webkit.org/show_bug.cgi?id=133454
19415
19416        Reviewed by Eric Carlson.
19417
19418        PlatformTimeRanges will now use MediaTime, so operations at the platform level won't
19419        lose precision when converting to and from doubles and rational time values like CMTime.
19420
19421        * Modules/mediasource/SourceBuffer.cpp:
19422        (WebCore::currentTimeFudgeFactor):
19423        (WebCore::SourceBuffer::hasCurrentTime):
19424        (WebCore::SourceBuffer::hasFutureTime):
19425        (WebCore::SourceBuffer::canPlayThrough):
19426        * html/HTMLMediaElement.cpp:
19427        (WebCore::HTMLMediaElement::parseAttribute):
19428        * html/TimeRanges.cpp:
19429        (WebCore::TimeRanges::TimeRanges):
19430        (WebCore::TimeRanges::start):
19431        (WebCore::TimeRanges::end):
19432        (WebCore::TimeRanges::add):
19433        (WebCore::TimeRanges::contain):
19434        (WebCore::TimeRanges::find):
19435        (WebCore::TimeRanges::nearest):
19436        (WebCore::TimeRanges::totalDuration):
19437        * platform/graphics/MediaPlayerPrivate.h:
19438        (WebCore::MediaPlayerPrivateInterface::seekable):
19439        * platform/graphics/PlatformTimeRanges.cpp:
19440        (WebCore::PlatformTimeRanges::create):
19441        (WebCore::PlatformTimeRanges::PlatformTimeRanges):
19442        (WebCore::PlatformTimeRanges::invert):
19443        (WebCore::PlatformTimeRanges::start):
19444        (WebCore::PlatformTimeRanges::end):
19445        (WebCore::PlatformTimeRanges::add):
19446        (WebCore::PlatformTimeRanges::contain):
19447        (WebCore::PlatformTimeRanges::find):
19448        (WebCore::PlatformTimeRanges::nearest):
19449        (WebCore::PlatformTimeRanges::totalDuration):
19450        * platform/graphics/PlatformTimeRanges.h:
19451        (WebCore::PlatformTimeRanges::Range::Range):
19452        (WebCore::PlatformTimeRanges::Range::isPointInRange):
19453        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
19454        (WebCore::MediaPlayerPrivateAVFoundation::extraMemoryCost):
19455        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
19456        (WebCore::MediaPlayerPrivateAVFoundationCF::platformBufferedTimeRanges):
19457        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
19458        (WebCore::MediaPlayerPrivateAVFoundationObjC::platformBufferedTimeRanges):
19459        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
19460        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekable):
19461        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered): Deleted.
19462        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
19463        (WebCore::MediaPlayerPrivateQTKit::buffered):
19464        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
19465        (WebCore::MediaPlayerPrivateGStreamer::buffered):
19466        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
19467        (WebCore::MockMediaPlayerMediaSource::advanceCurrentTime):
19468
194692014-06-03  Benjamin Poulain  <bpoulain@apple.com>
19470
19471        [iOS][WK2] Align the highlight rects with device pixels
19472        https://bugs.webkit.org/show_bug.cgi?id=133464
19473
19474        Reviewed by Enrica Casucci.
19475
19476        Add utility functions to pixel align points and rects.
19477
19478        * WebCore.exp.in:
19479        * platform/graphics/FloatPoint.h:
19480        (WebCore::flooredToDevicePixels):
19481        (WebCore::ceiledToDevicePixels):
19482        * platform/graphics/FloatRect.cpp:
19483        (WebCore::enclosingRectExtendedToDevicePixels):
19484        * platform/graphics/FloatRect.h:
19485
194862014-06-03  Timothy Horton  <timothy_horton@apple.com>
19487
19488        Prepopulated tiles may never be unparented from TileGrids with aggressive tile retention on
19489        https://bugs.webkit.org/show_bug.cgi?id=133471
19490
19491        Reviewed by Simon Fraser.
19492
19493        * platform/graphics/ca/mac/TileController.h:
19494        * platform/graphics/ca/mac/TileGrid.h:
19495        (WebCore::TileGrid::TileCohortInfo::TileCohortInfo):
19496        * platform/graphics/ca/mac/TileGrid.mm:
19497        (WebCore::TileGrid::TileCohortInfo::timeUntilExpiration):
19498        (WebCore::TileGrid::cohortRemovalTimerFired):
19499        Factor timeUntilExpiration() out of cohortRemovalTimerFired().
19500
19501        (WebCore::TileGrid::revalidateTiles):
19502        Ensure that secondary tiles that never touch the primary coverage rect
19503        are still unparented eventually (after 2 seconds, the same lifetime we use
19504        for cohorts in non-aggressive retention).
19505        Schedule another revalidateTiles if we left parented secondary tiles behind.
19506
195072014-06-03  Timothy Horton  <timothy_horton@apple.com>
19508
19509        TileGrid::prepopulateRect populates the wrong tiles if scale != 1
19510        https://bugs.webkit.org/show_bug.cgi?id=133470
19511
19512        Reviewed by Simon Fraser.
19513
19514        * page/FrameView.cpp:
19515        (WebCore::FrameView::requestScrollPositionUpdate):
19516        * platform/graphics/ca/mac/TileGrid.mm:
19517        (WebCore::TileGrid::prepopulateRect):
19518        (WebCore::TileGrid::revalidateTiles):
19519        prepopulateRect takes rects in "content" coordinates, but when later passed to
19520        ensureTilesForRect, they're expected to be in the same coordinate space as the layer's
19521        visible rect, and are scaled up. So, apply the inverse scale to counter that.
19522
195232014-06-03  Timothy Horton  <timothy_horton@apple.com>
19524
19525        Minor TileCoverageMap refinements
19526        https://bugs.webkit.org/show_bug.cgi?id=133468
19527
19528        Reviewed by Simon Fraser.
19529
19530        * platform/graphics/ca/mac/TileController.mm:
19531        (WebCore::TileController::setContentsScale):
19532        * platform/graphics/ca/mac/TileCoverageMap.h:
19533        * platform/graphics/ca/mac/TileCoverageMap.mm:
19534        (WebCore::TileCoverageMap::TileCoverageMap):
19535        (WebCore::TileCoverageMap::setDeviceScaleFactor):
19536        Keep the TileCoverageMap's contentsScale at the device scale factor, so that it
19537        looks sharp on non-1x displays.
19538
19539        (WebCore::TileCoverageMap::update):
19540        Decrease the height available for the TileCoverageMap by the topContentInset;
19541        it's already being vertically offset by the topContentInset, but the height was
19542        not adjusted, so it would run off the bottom of the window.
19543
19544        * platform/graphics/ca/mac/TileGrid.mm:
19545        (WebCore::TileGrid::drawTileMapContents):
19546        If using aggressive tile retention (and thus not coloring tiles based on age),
19547        dim tiles that aren't in the visible cohort.
19548
195492014-06-03  Timothy Horton  <timothy_horton@apple.com>
19550
19551        Fix a typo, TileGrid::updateTilerLayerProperties
19552        https://bugs.webkit.org/show_bug.cgi?id=133474
19553
19554        Reviewed by Anders Carlsson.
19555
19556        * platform/graphics/ca/mac/TileController.mm:
19557        (WebCore::TileController::setAcceleratesDrawing):
19558        (WebCore::TileController::setTilesOpaque):
19559        (WebCore::TileController::setTileDebugBorderWidth):
19560        (WebCore::TileController::setTileDebugBorderColor):
19561        * platform/graphics/ca/mac/TileGrid.h:
19562        * platform/graphics/ca/mac/TileGrid.mm:
19563        (WebCore::TileGrid::updateTileLayerProperties):
19564        (WebCore::TileGrid::updateTilerLayerProperties):
19565        s/updateTilerLayerProperties/updateTileLayerProperties/g
19566
195672014-06-03  Carlos Garcia Campos  <cgarcia@igalia.com>
19568
19569        [SOUP] ResourceLoadTiming.responseStart is always 0
19570        https://bugs.webkit.org/show_bug.cgi?id=133469
19571
19572        Reviewed by Sergio Villar Senin.
19573
19574        * platform/network/soup/ResourceHandleSoup.cpp:
19575        (WebCore::sendRequestCallback): Record the responseStart time.
19576
195772014-06-02  David Kilzer  <ddkilzer@apple.com>
19578
19579        [iOS] WebCore fails to build: platform/network/mac/ResourceHandleMac.mm:729:62: error: use of undeclared identifier '_CFURLConnectionCopyTimingData'
19580        <http://webkit.org/b/133445>
19581        <rdar://problem/17090035>
19582
19583        Reviewed by Alexey Proskuryakov.
19584
19585        * platform/network/mac/ResourceHandleMac.mm: Attempt to fix the
19586        build by including a private header and local declaration.
19587
195882014-05-31  Anders Carlsson  <andersca@apple.com>
19589
19590        Change DeferrableOneShotTimer to use std::function instead of being a class template
19591        https://bugs.webkit.org/show_bug.cgi?id=133423
19592
19593        Reviewed by Antti Koivisto.
19594
19595        Also, add a new constructor to DeferrableOneShotTimer that takes an std::function. Change the callback
19596        to not pass a DeferrableOneShotTimer& anymore. Change the delay parameter to use std::chrono::milliseconds.
19597
19598        * css/CSSImageGeneratorValue.cpp:
19599        (WebCore::CSSImageGeneratorValue::CachedGeneratedImage::CachedGeneratedImage):
19600        (WebCore::CSSImageGeneratorValue::CachedGeneratedImage::evictionTimerFired):
19601        * css/CSSImageGeneratorValue.h:
19602        * html/HTMLPlugInImageElement.cpp:
19603        (WebCore::HTMLPlugInImageElement::simulatedMouseClickTimerFired):
19604        * html/HTMLPlugInImageElement.h:
19605        * loader/cache/CachedResource.cpp:
19606        (WebCore::deadDecodedDataDeletionIntervalForResourceType):
19607        (WebCore::CachedResource::destroyDecodedDataIfNeeded):
19608        (WebCore::CachedResource::decodedDataDeletionTimerFired):
19609        * loader/cache/CachedResource.h:
19610        * loader/cache/MemoryCache.cpp:
19611        (WebCore::MemoryCache::MemoryCache):
19612        * loader/cache/MemoryCache.h:
19613        (WebCore::MemoryCache::setDeadDecodedDataDeletionInterval):
19614        (WebCore::MemoryCache::deadDecodedDataDeletionInterval):
19615        * platform/Timer.h:
19616        (WebCore::Timer::Timer):
19617        (WebCore::DeferrableOneShotTimer::DeferrableOneShotTimer):
19618        * platform/graphics/cg/SubimageCacheWithTimer.cpp:
19619        (WebCore::SubimageCacheWithTimer::invalidateCacheTimerFired):
19620        * platform/graphics/cg/SubimageCacheWithTimer.h:
19621
196222014-06-02  Benjamin Poulain  <benjamin@webkit.org>
19623
19624        Make pseudo element matching for style resolution more JIT friendly
19625        https://bugs.webkit.org/show_bug.cgi?id=133441
19626
19627        Reviewed by Antti Koivisto.
19628
19629        Sharing pseudo elements is a complicated mess shared between the SelectorChecker
19630        and the RuleCollector.
19631
19632        For compiling pseudo element matching, it would be best if all the complexity could
19633        be moved to compile time instead of runtime. It is also preferable to keep the compiler
19634        independant of the RuleCollector implementation's detail.
19635
19636        This patch is a first step toward that goal. The main objective here is to make
19637        "dynamicPseudo" completely internal to the SelectorChecker.
19638        This is mostly a mechanical change, it is likely PseudoElement matching could be simplified
19639        further but that is not attempted here.
19640
19641        Test: fast/css/style-sharing-empty-rule-modification.html
19642
19643        * css/ElementRuleCollector.cpp:
19644        (WebCore::ElementRuleCollector::ruleMatches):
19645        The condition regarding pseudo element matching has been moved into SelectorChecker::match().
19646
19647        This creates an extra cost for querySelector(), but that should be fine since the vast majority
19648        of selectors are JIT compiled and never use SelectorChecker in the first place.
19649
19650        (WebCore::ElementRuleCollector::collectMatchingRulesForList):
19651        The loop is changed such that the tree marking (Style::setHasPseudoStyle) could be moved
19652        to SelectorChecker.
19653
19654        The conditions about the security origin for getMatchedCSSRules() and the empty style rules
19655        are moved prior to the call to ElementRuleCollector::ruleMatches(). This ensure we keep the same
19656        behavior of not adding the pseudo style for empty rules (this could also help with tree marking
19657        in general but empty rules are probably uncommon).
19658
19659        There is one behavior change from making this loop simpler: the SharingRules and StyleInvalidation
19660        modes now update their ruleRange. It is useless but it is simpler.
19661
19662        * css/ElementRuleCollector.h:
19663        * css/SelectorChecker.cpp:
19664        (WebCore::SelectorChecker::matchRecursively):
19665        The tree marking has been moved here.
19666
19667        * css/SelectorChecker.h:
19668        (WebCore::SelectorChecker::match):
19669        The pseudo element matching has been moved here.
19670
19671        * css/StyleResolver.h:
19672        (WebCore::checkRegionSelector):
19673        * dom/SelectorQuery.cpp:
19674        (WebCore::SelectorDataList::selectorMatches):
19675
196762014-06-02  Jeremy Jones  <jeremyj@apple.com>
19677
19678        Send external playback properties to fullscreen.
19679        https://bugs.webkit.org/show_bug.cgi?id=133366
19680
19681        Reviewed by Simon Fraser.
19682
19683        Refactor property updates in WebVideoFullscreenModelMediaElement and update
19684        setExternalPlayback on webkitcurrentplaybacktargetiswirelesschangedEvent.
19685
19686        * WebCore.exp.in: Add export for setExternalPlayback.
19687        * platform/ios/WebVideoFullscreenInterface.h: add setExternalPlayback
19688        * platform/ios/WebVideoFullscreenInterfaceAVKit.h: add setExternalPlayback
19689        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
19690        (-[WebAVPlayerController isPlayingOnExternalScreen]): added
19691        (+[WebAVPlayerController keyPathsForValuesAffectingPlayingOnExternalScreen]): added
19692        (WebVideoFullscreenInterfaceAVKit::setExternalPlayback): added
19693        (WebVideoFullscreenInterfaceAVKit::enterFullscreen): added
19694        * platform/ios/WebVideoFullscreenModelMediaElement.h: add updateForEventName
19695        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
19696        (WebVideoFullscreenModelMediaElement::setMediaElement): refactor property changes into updateForEventName()
19697        (WebVideoFullscreenModelMediaElement::handleEvent): refactor property changes into updateForEventName()
19698        (WebVideoFullscreenModelMediaElement::updateForEventName): remove duplicate code, implement for setExternalPlayback
19699
197002014-06-02  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
19701
19702        WebCore build fix for webreplay
19703        https://bugs.webkit.org/show_bug.cgi?id=133401
19704
19705        Reviewed by Darin Adler.
19706
19707        * replay/MemoizedDOMResult.cpp:
19708        (WebCore::MemoizedDOMResultBase::createFromEncodedResult):
19709        Add a default nullptr return in order to avoid a gcc warning.
19710        The warning is because of a non-void method that has a case which doesn't return.
19711        * replay/ReplayController.cpp:
19712        (WebCore::ReplayController::setForceDeterministicSettings):
19713        Guard the ScrollingCoordinator with the appropriate #ifdef.
19714        * replay/SerializationMethods.cpp:
19715        Guard the KeypressCommand with COCOA as it is only present there.
19716
197172014-06-02  Jer Noble  <jer.noble@apple.com>
19718
19719        Further unreviewed GTK build fix after r169536.
19720
19721        Update the m_duration contructor in MediaSourceGStreamer.
19722
19723        * platform/graphics/gstreamer/MediaSourceGStreamer.cpp:
19724        (WebCore::MediaSourceGStreamer::MediaSourceGStreamer):
19725
197262014-06-02  Jer Noble  <jer.noble@apple.com>
19727
19728        Unreviewed GTK build fix after r169536.
19729
19730        Update MediaSourceGStreamer to match new duration parameters.
19731
19732        * platform/graphics/gstreamer/MediaSourceGStreamer.cpp:
19733        (WebCore::MediaSourceGStreamer::setDuration): Ditto.
19734        * platform/graphics/gstreamer/MediaSourceGStreamer.h:
19735        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
19736
197372014-06-02  Jer Noble  <jer.noble@apple.com>
19738
19739        [MSE][Mac] Media does not generate 'ended' event when playing to duration.
19740        https://bugs.webkit.org/show_bug.cgi?id=133452
19741
19742        Reviewed by Eric Carlson.
19743
19744        Add a boundaryTimeObserver to the AVSampleBufferRenderSynchronizer to detect when
19745        playback crosses the duration boundary, and pause in that event. Also refuse to begin
19746        playback if the currentTime is beyond the duration. Also, pause playback if duration
19747        becomes less than currentTime.
19748
19749        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
19750        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
19751        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::~MediaPlayerPrivateMediaSourceAVFObjC):
19752        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::playInternal):
19753        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::currentMediaTime):
19754        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::currentTimeDouble):
19755        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::durationChanged):
19756
19757        Update MediaSource::duration() and ::setDuration() to take and give MediaTimes rather than doubles:
19758        * Modules/mediasource/MediaSource.cpp:
19759        (WebCore::MediaSource::duration): double -> MediaTime.
19760        (WebCore::MediaSource::setDuration): Ditto.
19761        (WebCore::MediaSource::streamEndedWithError): Ditto.
19762        * platform/graphics/MediaSourcePrivate.h: Ditto.
19763        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
19764        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
19765        (WebCore::MediaSourcePrivateAVFObjC::MediaSourcePrivateAVFObjC): Ditto.
19766        (WebCore::MediaSourcePrivateAVFObjC::duration): Ditto.
19767        (WebCore::MediaSourcePrivateAVFObjC::setDuration): Ditto.
19768        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
19769        (WebCore::MockMediaPlayerMediaSource::MockMediaPlayerMediaSource): Ditto.
19770        (WebCore::MockMediaPlayerMediaSource::maxTimeSeekableDouble): Ditto.
19771        (WebCore::MockMediaPlayerMediaSource::durationDouble): Ditto.
19772        (WebCore::MockMediaPlayerMediaSource::advanceCurrentTime): Ditto.
19773        (WebCore::MockMediaPlayerMediaSource::updateDuration): Ditto.
19774        * platform/mock/mediasource/MockMediaPlayerMediaSource.h:
19775        * platform/mock/mediasource/MockMediaSourcePrivate.cpp:
19776        (WebCore::MockMediaSourcePrivate::MockMediaSourcePrivate): Ditto.
19777        (WebCore::MockMediaSourcePrivate::duration): Ditto.
19778        (WebCore::MockMediaSourcePrivate::setDuration): Ditto.
19779        * platform/mock/mediasource/MockMediaSourcePrivate.h:
19780
197812014-06-02  Zalan Bujtas  <zalan@apple.com>
19782
19783        Rename ImagePaintingContext to ImagePaintingOptions.
19784        https://bugs.webkit.org/show_bug.cgi?id=133451
19785
19786        Reviewed by Simon Fraser.
19787
19788        No change in functionality.
19789
19790        * WebCore.exp.in:
19791        * html/HTMLCanvasElement.cpp:
19792        (WebCore::HTMLCanvasElement::paint):
19793        * html/canvas/CanvasRenderingContext2D.cpp:
19794        (WebCore::CanvasRenderingContext2D::drawImage):
19795        * platform/graphics/GraphicsContext.cpp:
19796        (WebCore::GraphicsContext::drawImage):
19797        (WebCore::GraphicsContext::drawTiledImage):
19798        (WebCore::GraphicsContext::drawImageBuffer):
19799        * platform/graphics/GraphicsContext.h:
19800        (WebCore::ImagePaintingOptions::ImagePaintingOptions):
19801        (WebCore::ImagePaintingContext::ImagePaintingContext): Deleted.
19802        * rendering/RenderBoxModelObject.cpp:
19803        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
19804        * rendering/RenderEmbeddedObject.cpp:
19805        (WebCore::RenderEmbeddedObject::paintSnapshotImage):
19806        * rendering/RenderImage.cpp:
19807        (WebCore::RenderImage::paintIntoRect):
19808        * rendering/RenderSnapshottedPlugIn.cpp:
19809        (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
19810
198112014-05-31  Brent Fulgham  <bfulgham@apple.com>
19812
19813        REGRESSION (r154622): Borders disappear when hovering over cells in table
19814        https://bugs.webkit.org/show_bug.cgi?id=133057
19815        <rdar://problem/15922359>
19816
19817        Reviewed by Tim Horton.
19818
19819        * rendering/RenderTableCell.cpp:
19820        (WebCore::RenderTableCell::paintCollapsedBorders): Revert recent
19821        non-edge collapsed border optimization due to drawing
19822        regressions.
19823
198242014-06-02  Zalan Bujtas  <zalan@apple.com>
19825
19826        Provide better encapsulation for image related painting properties.
19827        https://bugs.webkit.org/show_bug.cgi?id=133434
19828
19829        Reviewed by Darin Adler.
19830
19831        Image related drawing property list keeps growing for the functions below and results in
19832        multiple overloadings with seemingly random default parameters.
19833        
19834        GraphicsContext::drawImage()
19835        GraphicsContext::drawTiledImage()
19836        GraphicsContext::drawImageBuffer()
19837        
19838        This patch provides encapsulation for the image drawing properties. Encapsulation ensures that
19839        introducing a new property does not result in yet another overloaded function.
19840
19841        No change in functionality.
19842
19843        * WebCore.exp.in:
19844        * html/HTMLCanvasElement.cpp:
19845        (WebCore::HTMLCanvasElement::paint):
19846        * html/canvas/CanvasRenderingContext2D.cpp:
19847        (WebCore::CanvasRenderingContext2D::drawImage):
19848        (WebCore::CanvasRenderingContext2D::compositeBuffer):
19849        * platform/graphics/GraphicsContext.cpp:
19850        (WebCore::GraphicsContext::drawImage):
19851        (WebCore::GraphicsContext::drawTiledImage):
19852        (WebCore::GraphicsContext::drawImageBuffer):
19853        * platform/graphics/GraphicsContext.h:
19854        (WebCore::ImagePaintingContext::ImagePaintingContext):
19855        * platform/graphics/ShadowBlur.cpp:
19856        (WebCore::ShadowBlur::endShadowLayer):
19857        * platform/graphics/cairo/ImageBufferCairo.cpp:
19858        (WebCore::ImageBuffer::draw):
19859        * platform/graphics/filters/FEComposite.cpp:
19860        (WebCore::FEComposite::platformApplySoftware):
19861        * rendering/FilterEffectRenderer.cpp:
19862        (WebCore::FilterEffectRendererHelper::applyFilterEffect):
19863        * rendering/RenderBoxModelObject.cpp:
19864        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
19865        * rendering/RenderEmbeddedObject.cpp:
19866        (WebCore::RenderEmbeddedObject::paintSnapshotImage):
19867        * rendering/RenderImage.cpp:
19868        (WebCore::RenderImage::paintReplaced):
19869        (WebCore::RenderImage::paintIntoRect):
19870        * rendering/RenderSnapshottedPlugIn.cpp:
19871        (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
19872
198732014-06-02  Commit Queue  <commit-queue@webkit.org>
19874
19875        Unreviewed, rolling out r169529.
19876        https://bugs.webkit.org/show_bug.cgi?id=133447
19877
19878        caused assert in drawImage() (Requested by zalan on #webkit).
19879
19880        Reverted changeset:
19881
19882        "Provide better encapsulation for image related painting
19883        properties."
19884        https://bugs.webkit.org/show_bug.cgi?id=133434
19885        http://trac.webkit.org/changeset/169529
19886
198872014-06-02  Zalan Bujtas  <zalan@apple.com>
19888
19889        Provide better encapsulation for image related painting properties.
19890        https://bugs.webkit.org/show_bug.cgi?id=133434
19891
19892        Reviewed by Darin Adler.
19893
19894        Image related drawing property list keeps growing for the functions below and results in
19895        multiple overloadings with seemingly random default parameters.
19896        
19897        GraphicsContext::drawImage()
19898        GraphicsContext::drawTiledImage()
19899        GraphicsContext::drawImageBuffer()
19900        
19901        This patch provides encapsulation for the image drawing properties. Encapsulation ensures that
19902        introducing a new property does not result in yet another overloaded function.
19903
19904        No change in functionality.
19905
19906        * WebCore.exp.in:
19907        * html/HTMLCanvasElement.cpp:
19908        (WebCore::HTMLCanvasElement::paint):
19909        * html/canvas/CanvasRenderingContext2D.cpp:
19910        (WebCore::CanvasRenderingContext2D::drawImage):
19911        (WebCore::CanvasRenderingContext2D::compositeBuffer):
19912        * platform/graphics/GraphicsContext.cpp:
19913        (WebCore::GraphicsContext::drawImage):
19914        (WebCore::GraphicsContext::drawTiledImage):
19915        (WebCore::GraphicsContext::drawImageBuffer):
19916        * platform/graphics/GraphicsContext.h:
19917        (WebCore::ImagePaintingContext::ImagePaintingContext):
19918        * platform/graphics/ShadowBlur.cpp:
19919        (WebCore::ShadowBlur::endShadowLayer):
19920        * platform/graphics/cairo/ImageBufferCairo.cpp:
19921        (WebCore::ImageBuffer::draw):
19922        * platform/graphics/filters/FEComposite.cpp:
19923        (WebCore::FEComposite::platformApplySoftware):
19924        * rendering/FilterEffectRenderer.cpp:
19925        (WebCore::FilterEffectRendererHelper::applyFilterEffect):
19926        * rendering/RenderBoxModelObject.cpp:
19927        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
19928        * rendering/RenderEmbeddedObject.cpp:
19929        (WebCore::RenderEmbeddedObject::paintSnapshotImage):
19930        * rendering/RenderImage.cpp:
19931        (WebCore::RenderImage::paintReplaced):
19932        (WebCore::RenderImage::paintIntoRect):
19933        * rendering/RenderSnapshottedPlugIn.cpp:
19934        (WebCore::RenderSnapshottedPlugIn::paintSnapshot):
19935
199362014-06-02  Kiran  <kiran.guduru@samsung.com>
19937
19938        Add mock DTMFSender support.
19939        https://bugs.webkit.org/show_bug.cgi?id=133298
19940
19941        Reviewed by Eric Carlson.
19942
19943        Implemented mock implementation for RTCPeerConnectionHandler. Now creating
19944        RTCDTMFSenderHandlerMock and returning while creating DTMFSender instead of
19945        returning null.
19946       
19947        Test: fast/mediastream/RTCPeerConnection-dtmf.html.
19948
19949        * CMakeLists.txt:
19950        * platform/mock/RTCDTMFSenderHandlerMock.cpp: Added.
19951        (WebCore::RTCDTMFSenderHandlerMock::RTCDTMFSenderHandlerMock):
19952        (WebCore::RTCDTMFSenderHandlerMock::setClient):
19953        (WebCore::RTCDTMFSenderHandlerMock::insertDTMF):
19954        * platform/mock/RTCDTMFSenderHandlerMock.h: Added.
19955        * platform/mock/RTCPeerConnectionHandlerMock.cpp:
19956        (WebCore::RTCPeerConnectionHandlerMock::createDTMFSender):
19957
199582014-06-02  Xabier Rodriguez Calvar  <calvaris@igalia.com>
19959
19960        [GTK] media controls should prevent 'click' events from reaching the page
19961        https://bugs.webkit.org/show_bug.cgi?id=133402
19962
19963        Reviewed by Eric Carlson.
19964
19965        When handling events, we events we need to return true in order
19966        that the superclass gets the value and prevents the execution of
19967        the default event handler in the page.
19968
19969        Test: media/media-controls-cancel-events.html
19970
19971        * Modules/mediacontrols/mediaControlsGtk.js:
19972        (ControllerGtk.prototype.handleMuteButtonMouseOver):
19973        (ControllerGtk.prototype.handleVolumeBoxMouseOut):
19974        (ControllerGtk.prototype.handleCaptionButtonClicked):
19975        (ControllerGtk.prototype.handleCaptionButtonMouseOver):
19976        (ControllerGtk.prototype.handleCaptionButtonShowMenu):
19977        (ControllerGtk.prototype.handleCaptionButtonMouseOut):
19978        (ControllerGtk.prototype.handleCaptionMouseOut): Return true to
19979        prevent forwarding the event execution.
19980
199812014-06-02  Yusuke Suzuki  <utatane.tea@gmail.com>
19982
19983        CSS JIT: add support for the "not" pseudo class
19984        https://bugs.webkit.org/show_bug.cgi?id=133314
19985
19986        Reviewed by Benjamin Poulain.
19987
19988        Add :not pseudo class support to CSS JIT. Current implementation
19989        doesn't support visitedMatchType. So when link pseudo class appears in
19990        :not sub fragment, fallback to the non-JIT implementation.
19991
19992        Tests: fast/selectors/not-active-hover-quirks.html
19993               fast/selectors/not-active-hover-strict.html
19994               fast/selectors/pseudo-class-not.html
19995
19996        * cssjit/SelectorCompiler.cpp:
19997        (WebCore::SelectorCompiler::addPseudoClassType):
19998        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
19999        (WebCore::SelectorCompiler::constructFragments):
20000        (WebCore::SelectorCompiler::minimumRegisterRequirements):
20001        (WebCore::SelectorCompiler::computeBacktrackingInformation):
20002        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
20003        (WebCore::SelectorCompiler::fragmentOnlyMatchesLinksInQuirksMode):
20004        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
20005        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementDataMatching):
20006        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
20007        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatchesNotPseudoClass):
20008        (WebCore::SelectorCompiler::SelectorCodeGenerator::computeBacktrackingInformation): Deleted.
20009
200102014-06-01  Jer Noble  <jer.noble@apple.com>
20011
20012        [MSE] Appends of overlapping sample data do not clear existing samples properly.
20013        https://bugs.webkit.org/show_bug.cgi?id=133435
20014
20015        Reviewed by Darin Adler.
20016
20017        Test: media/media-source/media-source-overlapping-append.html
20018
20019        The MSE spec has a spec error in how it removes overlapping frames. The intention seems to be
20020        to check for overlapping samples only when the incoming sample increases the highest presentation time
20021        field. But due to a mismatch in the range of a sample, defined as [start, end), and the check, which 
20022        treats the end as inclusive, the overlapping check is almost never run.
20023
20024        Add the sample comparison logic to match [start, end) ranges, and rename the existing check to differentiate
20025        it from the new one:
20026        * Modules/mediasource/SampleMap.cpp:
20027        (WebCore::SamplePresentationTimeIsInsideRangeComparator::operator()):
20028        (WebCore::SamplePresentationTimeIsWithinRangeComparator::operator()):
20029        (WebCore::SampleMap::findSamplesBetweenPresentationTimes):
20030        (WebCore::SampleMap::findSamplesWithinPresentationRange):
20031        * Modules/mediasource/SampleMap.h:
20032
20033        Update the overlapping check to occur whenever the highest presentation time increases, and update the
20034        logic within that check to catch all overlapping frames.
20035        * Modules/mediasource/SourceBuffer.cpp:
20036        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):
20037        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
20038        (WebCore::SourceBuffer::bufferedSamplesForTrackID):
20039        * Modules/mediasource/SourceBuffer.h:
20040        * WebCore.exp.in:
20041
20042        Add a dump method to MediaSample so that samples can be easily converted to a string for testing.
20043        * platform/MediaSample.h:
20044        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
20045        (WebCore::MediaSampleAVFObjC::presentationSize):
20046        (WebCore::MediaSampleAVFObjC::dump):
20047
20048        Update the Mock MSE implementation to pass along a "generation" field, to aid in testing.
20049        * platform/mock/mediasource/MockBox.cpp:
20050        (WebCore::MockSampleBox::MockSampleBox):
20051        * platform/mock/mediasource/MockBox.h:
20052        * platform/mock/mediasource/MockSourceBufferPrivate.cpp:
20053        (WebCore::MockMediaSample::dump):
20054
20055        Add a method to internals to dump the buffered samples to string.
20056        * Modules/mediasource/SourceBuffer.cpp:
20057        (WebCore::SourceBuffer::bufferedSamplesForTrackID):
20058        * Modules/mediasource/SourceBuffer.h:
20059        * testing/Internals.cpp:
20060        (WebCore::Internals::bufferedSamplesForTrackID):
20061        * testing/Internals.h:
20062        * testing/Internals.idl:
20063
200642014-06-01  Nikos Andronikos  <nikos.andronikos-webkit@cisra.canon.com.au>
20065
20066        getBBox() returns (0,0) when width or height is zero.
20067        https://bugs.webkit.org/show_bug.cgi?id=93290
20068
20069        Reviewed by Philip Rogers.
20070
20071        The SVG spec states that a width or height of zero for  rects, circles and
20072        ellipses is valid but disables rendering of that shape.
20073        In this case, getBBox() should return the actual bounding box of the element.
20074        Previously, WebKit always returned (0,0,0,0) rather than the
20075        correct bounding box. This patch fixes that. 
20076
20077        Rects and ellipses both now follow the same behaviour where
20078        the fall-back code path is only used when the shape will render (e.g. not
20079        when a dimension <= 0).
20080  
20081        This necessitates calling calculateRadiiAndCenter for ellipses even
20082        when the calculated values will be discarded in the fall back code path.
20083        But calculateRadiiAndCenter is cheap and this avoids making changes 
20084        elsewhere to stop CG drawing a zero width (or height) ellipse.  
20085
20086        Tests: svg/custom/getBBox-js-circle-zerodimension.html
20087               svg/custom/getBBox-js-ellipse-zerodimension.html
20088               svg/custom/getBBox-js-rect-zerodimension.html
20089
20090        * rendering/svg/RenderSVGEllipse.cpp:
20091        (WebCore::RenderSVGEllipse::updateShapeFromElement):
20092        Only follow fall-back code path when shape renders. 
20093        width||height==0 is not an error case so calculate bounding box.        
20094
20095        * rendering/svg/RenderSVGRect.cpp:
20096        (WebCore::RenderSVGRect::updateShapeFromElement):
20097        Only follow fall-back code path when shape renders. 
20098        rx||ry==0 is not an error case so calculate bounding box.        
20099
201002014-06-01  Simon Fraser  <simon.fraser@apple.com>
20101
20102        Don't scroll to non-integral scroll offsets
20103        https://bugs.webkit.org/show_bug.cgi?id=133436
20104        <rdar://problem/17088336>
20105
20106        Reviewed by Darin Adler.
20107
20108        With the gradual migration of scroll offsets to floating point, we ended
20109        up with a fully floating point code path been event scroll deltas and
20110        setting scroll positions in the scrolling tree.
20111        
20112        With some input devices (e.g. Logitech scrollwheel mice), the scroll deltas
20113        come in with non-integral values, and that caused the scroll offset to be non-integral,
20114        resulting in fuzzy layer contents. So round the scroll position.
20115
20116        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
20117        (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPosition):
20118
201192014-05-31  Anders Carlsson  <andersca@apple.com>
20120
20121        Add a LazyNeverDestroyed class template and use it
20122        https://bugs.webkit.org/show_bug.cgi?id=133425
20123
20124        Reviewed by Darin Adler.
20125
20126        * Modules/webdatabase/DatabaseBackendBase.cpp:
20127        (WebCore::guidMutex):
20128        * crypto/CryptoAlgorithmRegistry.cpp:
20129        (WebCore::registryMutex):
20130        * inspector/WorkerDebuggerAgent.cpp:
20131        * loader/CrossOriginAccessControl.cpp:
20132        (WebCore::isOnAccessControlResponseHeaderWhitelist):
20133        * platform/network/NetworkStateNotifier.cpp:
20134        (WebCore::networkStateNotifier):
20135        * workers/DefaultSharedWorkerRepository.cpp:
20136        (WebCore::DefaultSharedWorkerRepository::instance):
20137        * workers/DefaultSharedWorkerRepository.h:
20138        * workers/WorkerThread.cpp:
20139        (WebCore::threadSetMutex):
20140        * xml/XMLHttpRequest.cpp:
20141        (WebCore::staticData):
20142
201432014-06-01  Zalan Bujtas  <zalan@apple.com>
20144
20145        Subpixel rendering: Selection gap produces a pixel line overlap on inline boxes.
20146        https://bugs.webkit.org/show_bug.cgi?id=133429
20147
20148        Reviewed by Simon Fraser.
20149
20150        Do not floor logical right/left values when selection gap is calculated for RenderBlocks.
20151        It produces overlapping line/gap because the floored value is intersecting/too far from the
20152        non-floored content selection rect.
20153
20154        Tests: fast/inline/hidpi-selection-gap-and-inline-selection-have-gap-rtl.html
20155               fast/inline/hidpi-selection-gap-overlaps-inline-selection.html
20156
20157        * rendering/RenderBlock.cpp:
20158        (WebCore::RenderBlock::logicalLeftSelectionGap):
20159        (WebCore::RenderBlock::logicalRightSelectionGap):
20160
201612014-05-31  Timothy Horton  <timothy_horton@apple.com>
20162
20163        REGRESSION (r169412): Garbage pixels when vertical rubber-banding on http://yvoschaap.com/pmarca/
20164        https://bugs.webkit.org/show_bug.cgi?id=133418
20165        <rdar://problem/17065494>
20166
20167        Reviewed by Sam Weinig.
20168
20169        * WebCore.exp.in:
20170        * platform/graphics/FloatPoint.h:
20171        (WebCore::toFloatPoint):
20172        * platform/graphics/Image.cpp:
20173        (WebCore::Image::drawTiled):
20174        The manual tiling code previously adjusted the initial
20175        tiling source rect so that if the pattern was out of phase,
20176        the first row and column would paint only the necessary part
20177        of the tile. However, it did not also adjust the destination rect,
20178        so the tile was painted in entirely the wrong place.
20179        Additional testing (by enabling manual tiling mode for all patterned
20180        images and running all of the layout tests) exposed another bug
20181        where the last row and column would paint too much, which
20182        was resolved by clipping to the outer image's destination rect.
20183
201842014-05-31  Benjamin Poulain  <benjamin@webkit.org>
20185
20186        CSS JIT cleanup: move two utility functions out of the properties-matcher section
20187        https://bugs.webkit.org/show_bug.cgi?id=133427
20188
20189        Reviewed by Andreas Kling.
20190
20191        Just move the code, no other modification.
20192
20193        * cssjit/SelectorCompiler.cpp:
20194        (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNoPreviousAdjacentElement):
20195        (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNoNextAdjacentElement):
20196
201972014-05-31  Darin Adler  <darin@apple.com>
20198
20199        Viewport percentage tests that resize the viewport are flaky
20200        https://bugs.webkit.org/show_bug.cgi?id=133351
20201
20202        Reviewed by Anders Carlsson.
20203
20204        * page/FrameView.cpp:
20205        (WebCore::FrameView::setFrameRect): Removed code that explicitly sends a resize event here.
20206        The resize event will be sent as a side effect of layout instead.
20207        (WebCore::FrameView::sendResizeEventIfNeeded): Don't send a resize event until layout is done,
20208        since this is what propagates the new geometry in so the JavaScript code can detect it. Also
20209        simplified the logic and streamlined a little, and added a FIXME about the bad idea here where
20210        the code enqueues an event for an unknown time in the future. Removed the unneeded code that
20211        passes in the DOM window as the target to dispatchWindowEvent, since that gets filled in as the
20212        target by default.
20213
202142014-05-31  Anders Carlsson  <andersca@apple.com>
20215
20216        Don't use std::mutex::try_lock to check if we own a mutex
20217        https://bugs.webkit.org/show_bug.cgi?id=133421
20218
20219        Reviewed by Dan Bernstein.
20220
20221        According the C++ standard, calling try_lock on a mutex that's already owned by the current thread
20222        is undefined behavior, so don't do that.
20223
20224        * Modules/webdatabase/DatabaseBackendBase.cpp:
20225        (WebCore::guidToVersionMap):
20226        (WebCore::updateGuidVersionMap):
20227        (WebCore::guidToDatabaseMap):
20228        (WebCore::guidForOriginAndName):
20229
202302014-05-30  Enrica Casucci  <enrica@apple.com>
20231
20232        REGRESSION (WebKit2): space space to insert period doesn't work in web forms.
20233        https://bugs.webkit.org/show_bug.cgi?id=133413
20234        <rdar://problem/16948333>
20235
20236        Reviewed by Benjamin Poulain.
20237
20238        Adding utility functions and their exports.
20239
20240        * WebCore.exp.in:
20241        * editing/TextIterator.cpp:
20242        (WebCore::plainTextReplacingNoBreakSpace):
20243        * editing/TextIterator.h:
20244        * editing/VisibleUnits.cpp:
20245        (WebCore::charactersAroundPosition):
20246        (WebCore::characterBeforePosition): Deleted.
20247        * editing/VisibleUnits.h:
20248
202492014-05-30  Zalan Bujtas  <zalan@apple.com>
20250
20251        Cleanup temporary setting of image interpolation quality in GraphicsContext::drawImage*
20252        https://bugs.webkit.org/show_bug.cgi?id=133407
20253
20254        Reviewed by Darin Adler.
20255
20256        Add helper class to set/reset image interpolation quality value.
20257
20258        No change in functionality.
20259
20260        * platform/graphics/GraphicsContext.cpp:
20261        (WebCore::InterpolationQualityMaintainer::InterpolationQualityMaintainer):
20262        (WebCore::InterpolationQualityMaintainer::~InterpolationQualityMaintainer):
20263        (WebCore::GraphicsContext::drawImage):
20264        (WebCore::GraphicsContext::drawTiledImage):
20265        (WebCore::GraphicsContext::drawImageBuffer):
20266
202672014-05-30  Myles C. Maxfield  <mmaxfield@apple.com>
20268
20269        Support -apple-system-font on OS X
20270        https://bugs.webkit.org/show_bug.cgi?id=133382
20271
20272        Addressing post-review comments.
20273
20274        * platform/mac/WebFontCache.mm:
20275        (+[WebFontCache internalFontWithFamily:traits:weight:size:]):
20276
202772014-05-30  Prashant Hiremath  <hiremathprashants@gmail.com>
20278
20279        Remove repetitive header in HTMLInputElement.cpp
20280        https://bugs.webkit.org/show_bug.cgi?id=133376
20281
20282        Reviewed by Anders Carlsson.
20283
20284        It is just removal repeative headers hence no test needed.
20285
20286        * html/HTMLInputElement.cpp:
20287
202882014-05-30  Zalan Bujtas  <zalan@apple.com>
20289
20290        Remove redundant GraphicsContext::drawImage() function.
20291        https://bugs.webkit.org/show_bug.cgi?id=133347
20292
20293        Reviewed by Simon Fraser.
20294
20295        There are 2 GraphicsContext::drawImage functions with very similar parameter list. This looks
20296        to be a source of confusion and results in passing unneeded parameters.
20297
20298        No change in functionality.
20299
20300        * html/canvas/CanvasRenderingContext2D.cpp:
20301        (WebCore::CanvasRenderingContext2D::drawImage):
20302        (WebCore::drawImageToContext):
20303        * platform/graphics/GraphicsContext.cpp:
20304        (WebCore::GraphicsContext::drawImage):
20305        * platform/graphics/GraphicsContext.h:
20306        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
20307        (WebCore::MediaPlayerPrivateGStreamerBase::paint):
20308        * platform/graphics/texmap/TextureMapperImageBuffer.cpp:
20309        (WebCore::BitmapTextureImageBuffer::updateContents):
20310        * rendering/RenderBoxModelObject.cpp:
20311        (WebCore::RenderBoxModelObject::paintNinePieceImage):
20312
203132014-05-29  Alex Christensen  <achristensen@webkit.org>
20314
20315        Prepare css jit for arm64 and other architectures.
20316        https://bugs.webkit.org/show_bug.cgi?id=133394
20317
20318        Reviewed by Benjamin Poulain.
20319
20320        * cssjit/FunctionCall.h:
20321        (WebCore::FunctionCall::swapArguments):
20322        * cssjit/RegisterAllocator.h:
20323        Use a designated temporary register on arm64 to prevent using a deallocated argument register to swap argument registers in.
20324        * cssjit/SelectorCompiler.cpp:
20325        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
20326        Added assertion to make sure there are enough registers.
20327
203282014-05-29  Benjamin Poulain  <benjamin@webkit.org>
20329
20330        CSS JIT: add support for the pseudo classes :hover and :active
20331        https://bugs.webkit.org/show_bug.cgi?id=133295
20332
20333        Reviewed by Andreas Kling.
20334
20335        This patch adds compilation support for :hover and :active. The code generation of both of them is trivial,
20336        most of the patch is improving the infrastructure and safety.
20337
20338        The document compatibility mode is moved to its own typed enum. This ensure the values are exclusives and
20339        the native type is known (unsigned char here). The values are changes to binary flags to take advantage of
20340        test-and-branch on ARM64 (not used explicitely, it is automatically generated by the MacroAssembler).
20341
20342        The other important refactoring is the code updating the flags on RenderStyle::NonInheritedFlags.
20343        The code was duplicated in some places so it is move into its own function addFlagToElementStyleFromContext().
20344
20345        The generators themself are very simple. First we check the quirks-mode exceptions, that is generally excluded
20346        at compile time because the conditions are almost never met, even in strict mode.
20347        Then we have two cases: style resolution and query selector. Almost everything is just function calls.
20348
20349        * cssjit/SelectorCompiler.cpp:
20350        (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
20351        (WebCore::SelectorCompiler::addPseudoClassType):
20352        (WebCore::SelectorCompiler::SelectorCodeGenerator::addFlagToElementStyleFromContext):
20353        (WebCore::SelectorCompiler::fragmentOnlyMatchesLinksInQuirksMode):
20354        (WebCore::SelectorCompiler::getDocument):
20355        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSpecialFailureInQuirksModeForActiveAndHoverIfNeeded):
20356        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
20357        (WebCore::SelectorCompiler::elementIsActive):
20358        (WebCore::SelectorCompiler::elementIsActiveForStyleResolution):
20359        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsActive):
20360        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
20361        (WebCore::SelectorCompiler::elementIsHovered):
20362        (WebCore::SelectorCompiler::elementIsHoveredForStyleResolution):
20363        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsHovered):
20364        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLastChild):
20365        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsOnlyChild):
20366        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
20367        * dom/Document.cpp:
20368        (WebCore::Document::Document):
20369        (WebCore::Document::setCompatibilityMode):
20370        (WebCore::Document::implicitOpen):
20371        (WebCore::Document::cloneDataFromDocument):
20372        * dom/Document.h:
20373        (WebCore::Document::compatibilityModeMemoryOffset):
20374        (WebCore::Document::inQuirksMode):
20375        (WebCore::Document::inLimitedQuirksMode):
20376        (WebCore::Document::inNoQuirksMode):
20377        (WebCore::Document::compatibilityMode): Deleted.
20378        * html/ImageDocument.cpp:
20379        (WebCore::ImageDocument::ImageDocument):
20380        * html/MediaDocument.cpp:
20381        (WebCore::MediaDocument::MediaDocument):
20382        * html/PluginDocument.cpp:
20383        (WebCore::PluginDocument::PluginDocument):
20384        * html/TextDocument.cpp:
20385        (WebCore::TextDocument::TextDocument):
20386        * html/parser/HTMLConstructionSite.cpp:
20387        (WebCore::HTMLConstructionSite::setDefaultCompatibilityMode):
20388        (WebCore::HTMLConstructionSite::setCompatibilityMode):
20389        (WebCore::HTMLConstructionSite::setCompatibilityModeFromDoctype):
20390        (WebCore::HTMLConstructionSite::insertDoctype):
20391        * html/parser/HTMLConstructionSite.h:
20392        * loader/DocumentWriter.cpp:
20393        (WebCore::DocumentWriter::replaceDocument):
20394        * loader/SinkDocument.cpp:
20395        (WebCore::SinkDocument::SinkDocument):
20396        * page/ios/FrameIOS.mm:
20397        (WebCore::Frame::initWithSimpleHTMLDocument):
20398        * rendering/style/RenderStyle.h:
20399
204002014-05-28  Jon Honeycutt  <jhoneycutt@apple.com>
20401
20402        Roll r168668 back in.
20403
20404        <https://bugs.webkit.org/show_bug.cgi?id=132621>
20405
20406        Reviewed by Brent Fulgham.
20407
20408        Tests: fast/events/beforeload-assertion.html
20409               fast/events/beforeload-iframe-crash.html
20410               fast/events/beforeload-input-time-crash.html
20411
20412        * WebCore.exp.in:
20413        * dom/Document.cpp:
20414        (WebCore::Document::updateLayoutIgnorePendingStylesheets):
20415        * dom/Document.h:
20416        * html/HTMLAppletElement.cpp:
20417        (WebCore::HTMLAppletElement::renderWidgetForJSBindings):
20418        * html/HTMLEmbedElement.cpp:
20419        (WebCore::HTMLEmbedElement::renderWidgetForJSBindings):
20420        * html/HTMLObjectElement.cpp:
20421        (WebCore::HTMLObjectElement::renderWidgetForJSBindings):
20422        * page/FrameView.cpp:
20423        (WebCore::FrameView::FrameView):
20424        (WebCore::FrameView::reset):
20425        (WebCore::FrameView::updateEmbeddedObjectsTimerFired):
20426        (WebCore::FrameView::flushAnyPendingPostLayoutTasks):
20427        (WebCore::FrameView::performPostLayoutTasks):
20428        * page/FrameView.h:
20429        * testing/Internals.cpp:
20430        (WebCore::Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks):
20431        * testing/Internals.h:
20432        * testing/Internals.idl:
20433
204342014-05-29  Myles C. Maxfield  <mmaxfield@apple.com>
20435
20436        Support -apple-system-font on OS X
20437        https://bugs.webkit.org/show_bug.cgi?id=133382
20438
20439        Reviewed by Simon Fraser.
20440
20441        Guard on both family names: "-apple-system-font" and "-webkit-system-font"
20442
20443        Test: platform/mac/fast/text/systemFont.html
20444
20445        * platform/mac/WebFontCache.mm:
20446        (+[WebFontCache internalFontWithFamily:traits:weight:size:]):
20447
204482014-05-29  Alexey Proskuryakov  <ap@apple.com>
20449
20450        Loading <object> from WebArchive crashes
20451        https://bugs.webkit.org/show_bug.cgi?id=133386
20452        <rdar://problem/13345509>
20453
20454        Reviewed by Brady Eidson.
20455
20456        Test: webarchive/loading/object.html
20457
20458        This (a) fixes the crash, and (b) avoids the crash.
20459
20460        * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::continueAfterContentPolicy):
20461        Some types of substitute data - such as WebArchive - don't contain HTTP result codes,
20462        so let's not drop to <object> fallback content when status is 0.
20463        And if the load somehow failed anyway, don't crash by trying to deliver substitute data
20464        to a finished loader.
20465
204662014-05-29  Alex Christensen  <achristensen@webkit.org>
20467
20468        [iOS WebGL] Fix depth buffer clearing issue.
20469        https://bugs.webkit.org/show_bug.cgi?id=133388
20470
20471        Reviewed by Dean Jackson.
20472
20473        No new tests, but this fixes webgl/1.0.1/conformance/canvas/buffer-preserve-test.html.
20474
20475        * platform/graphics/mac/WebGLLayer.mm:
20476        (-[WebGLLayer display]):
20477        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
20478        (WebCore::GraphicsContext3D::prepareTexture):
20479        Moved marking the layer as composited from the mac-only prepareTexture to
20480        the end of [WebGLLayer display] which is called by mac and iOS.
20481
204822014-05-29  Jeremy Jones  <jeremyj@apple.com>
20483
20484        Perserve caption selection in fullscreen.
20485        https://bugs.webkit.org/show_bug.cgi?id=133350
20486
20487        Reviewed by Eric Carlson.
20488
20489        Use the logic from the inline player to calculate the selected caption index.
20490
20491        * html/HTMLMediaElement.h:
20492        (WebCore::HTMLMediaElement::mediaControlsHost):
20493        Expose mediaControlsHost() for use by WebVideoFullscreenModelMediaElement.
20494
20495        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
20496        (WebVideoFullscreenModelMediaElement::updateLegibleOptions):
20497        Use logic from buildCaptionsMenu from mediaControlsApple.js.
20498
204992014-05-29  Jeremy Jones  <jeremyj@apple.com>
20500
20501        Use correct version of requiresFullscreenForVideoPlayback().
20502        https://bugs.webkit.org/show_bug.cgi?id=133331
20503
20504        Reviewed by Eric Carlson.
20505
20506        Test: media/video-fullscreeen-only-controls.html
20507
20508        Update the last place not yet using m_mediaSession->requiresFullscreenForVideoPlayback.
20509
20510        * html/HTMLMediaElement.cpp:
20511        (WebCore::HTMLMediaElement::parseAttribute):
20512        switch to media session version for requriesFullscreenForVideoPlayback.
20513
205142014-05-29  Carlos Garcia Campos  <cgarcia@igalia.com>
20515
20516        [GTK] Add support for HiDPI icons
20517        https://bugs.webkit.org/show_bug.cgi?id=133377
20518
20519        Reviewed by Martin Robinson.
20520
20521        Use the GTK+ missing icon at 16 or 32 size depending on the device
20522        scale factor.
20523
20524        * platform/graphics/gtk/ImageGtk.cpp:
20525        (WebCore::loadMissingImageIconFromTheme):
20526        (WebCore::Image::loadPlatformResource):
20527
205282014-05-29  Owen Taylor  <otaylor@redhat.com>
20529
20530        [GTK] Add HighDPI support for non-accelerated compositing contents
20531        https://bugs.webkit.org/show_bug.cgi?id=131562
20532
20533        Reviewed by Anders Carlsson.
20534
20535        No new tests. This will be tested once we have the proper dependencies in the WebKit testing
20536        JHBuild.
20537
20538        * platform/cairo/WidgetBackingStore.h:
20539        (WebCore::WidgetBackingStore::WidgetBackingStore): Accept a device scale argument.
20540        * platform/cairo/WidgetBackingStoreCairo.cpp: Use the device scale argument to make the surface the proper size and set the surface device scale.
20541        * platform/cairo/WidgetBackingStoreCairo.h: Accept a device scale argument.
20542        * platform/graphics/cairo/CairoUtilities.cpp: Add a new helper to set the device scale if Cairo built against is new enough.
20543        * platform/graphics/cairo/CairoUtilities.h:
20544        * platform/gtk/GtkVersioning.h: Add the HAVE_GTK_SCALE_FACTOR macro.
20545        * platform/gtk/WidgetBackingStoreGtkX11.cpp: Use the device scale argument to make the surface the proper size and set the surface device scale.
20546        * platform/gtk/WidgetBackingStoreGtkX11.h: Accept a device scale argument.
20547
205482014-05-28  Brent Fulgham  <bfulgham@apple.com>
20549
20550        Captions during HLS playback flash/are difficult to readily
20551        https://bugs.webkit.org/show_bug.cgi?id=133365
20552        <rdar://problem/16584132>
20553
20554        Reviewed by Eric Carlson.
20555
20556        Correct two problems:
20557        1. Add new logic to handle cues that are identical to existing cues, except
20558           that they cover a slightly later moment in playback. For example, a cue
20559           encoding device might emit a cue at 24 fps, with many of the cues containing
20560           the same content but covering only 1/24th of a second.
20561           
20562           Rather than hiding and displaying our cues at the cue encoding rate, we should
20563           simply continue to display the same cue as long as the content is unchanged.
20564        2. The cue "isEqual" logic for TextTrackCueGeneric improperly short-circuited the
20565           VTTCue isEqual logic. This was done to avoid a false failure due to the cue
20566           type being 'generic' rather than 'vtt', but incorrectly treated cues with
20567           non-matching text as equal.
20568
20569        * html/track/DataCue.cpp:
20570        (WebCore::DataCue::cueContentsMatch): Move cue comparison code to new method that
20571        doesn't check that the 'type' of the cue is identical.
20572        (WebCore::DataCue::isEqual): Modified to use new 'cueContentsMatch' method.
20573        (WebCore::DataCue::isStartOfCue): Confirms cues match except for start and end times.
20574        * html/track/DataCue.h:
20575        * html/track/TextTrack.cpp:
20576        (WebCore::TextTrack::hasCue): Modify to check if a new cue is simply a continuation
20577        of an existing cue.
20578        * html/track/TextTrackCue.cpp:
20579        (WebCore::TextTrackCue::cueContentsMatch): New method containing the equality code
20580        that used to live in 'isEqual'.
20581        (WebCore::TextTrackCue::isEqual): Modified to use new 'cueContentsMatch' method.
20582        (WebCore::TextTrackCue::isStartOfCue): Confirms cues match except for start and
20583        end times.
20584        * html/track/TextTrackCue.h:
20585        * html/track/TextTrackCueGeneric.cpp:
20586        (WebCore::TextTrackCueGeneric::cueContentsMatch): New method containing the equality
20587        code that used to live in 'isEqual'.
20588        (WebCore::TextTrackCueGeneric::isEqual): Modified to use new 'cueContentsMatch' method.
20589        (WebCore::TextTrackCueGeneric::isStartOfCue): Confirms cues match except for start and
20590        end times.
20591        * html/track/TextTrackCueGeneric.h:
20592        * html/track/VTTCue.cpp:
20593        (WebCore::VTTCue::cueContentsMatch): New method containing the equality code that
20594        used to live in 'isEqual'.
20595        (WebCore::VTTCue::isEqual): Modified to use new 'cueContentsMatch' method.
20596        (WebCore::VTTCue::isStartOfCue): Confirms cues match except for start and end times.
20597        * html/track/VTTCue.h:
20598
205992014-05-28  Oliver Hunt  <oliver@apple.com>
20600
20601        Whoops, update bindings tests results.
20602
206032014-05-28  Oliver Hunt  <oliver@apple.com>
20604
20605        Make DOM properties exposed as instance properties use the base object instead of |this|
20606        https://bugs.webkit.org/show_bug.cgi?id=133353
20607
20608        Reviewed by Geoffrey Garen.
20609
20610        Make the bindings generator emit code that uses the base object for
20611        a property, rather than the this object. This means that attributes
20612        that we need to be treated as instance properties will match their old
20613        instance-based behaviour.
20614
20615        * bindings/scripts/CodeGeneratorJS.pm:
20616        (InterfaceRequiresAttributesOnInstanceForCompatibility):
20617        (InterfaceRequiresAttributesOnInstance):
20618        (GetCastingHelperForBaseObject):
20619        (GenerateImplementation):
20620        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
20621        (WebCore::jsTestActiveDOMObjectExcitingAttr):
20622        * bindings/scripts/test/JS/JSTestException.cpp:
20623        (WebCore::jsTestExceptionName):
20624        * bindings/scripts/test/JS/JSTestInterface.cpp:
20625        (WebCore::jsTestInterfaceImplementsStr3):
20626        (WebCore::jsTestInterfaceSupplementalStr3):
20627        (WebCore::setJSTestInterfaceConstructorImplementsStaticAttr):
20628        (WebCore::setJSTestInterfaceImplementsStr2):
20629        (WebCore::setJSTestInterfaceImplementsStr3):
20630        (WebCore::setJSTestInterfaceImplementsNode):
20631        (WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr):
20632        (WebCore::setJSTestInterfaceSupplementalStr2):
20633        (WebCore::setJSTestInterfaceSupplementalStr3):
20634        (WebCore::setJSTestInterfaceSupplementalNode):
20635        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
20636        (WebCore::setJSTestNondeterministicNondeterministicWriteableAttr):
20637        (WebCore::setJSTestNondeterministicNondeterministicExceptionAttr):
20638        (WebCore::setJSTestNondeterministicNondeterministicGetterExceptionAttr):
20639        (WebCore::setJSTestNondeterministicNondeterministicSetterExceptionAttr):
20640        (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
20641        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
20642        (WebCore::jsTestTypedefsConstructorTestSubObj):
20643        (WebCore::setJSTestTypedefsUnsignedLongLongAttr):
20644        (WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
20645        (WebCore::setJSTestTypedefsAttrWithGetterException):
20646        (WebCore::setJSTestTypedefsAttrWithSetterException):
20647        (WebCore::setJSTestTypedefsStringAttrWithGetterException):
20648        (WebCore::setJSTestTypedefsStringAttrWithSetterException):
20649
206502014-05-28  Simon Fraser  <simon.fraser@apple.com>
20651
20652        [iOS WK2] Improve behavior of position:fixed inside accelerated overflow-scroll
20653        https://bugs.webkit.org/show_bug.cgi?id=133352
20654
20655        Reviewed by Tim Horton.
20656
20657        When adjusting layers inside accelerated overflow-scroll, pass a delta
20658        down to descendant nodes. Fix behavior of sticky nodes inside fixed nodes
20659        inside overflow scroll (sticky should only be affected if the parent node
20660        is a scrolling node).
20661
20662        * page/scrolling/mac/ScrollingTreeFixedNode.mm:
20663        (WebCore::ScrollingTreeFixedNode::updateLayersAfterAncestorChange): Just remove
20664        some .get()
20665        * page/scrolling/mac/ScrollingTreeStickyNode.mm:
20666        (WebCore::ScrollingTreeStickyNode::updateLayersAfterAncestorChange): Remove .get()s.
20667        We never care about the cumulative delta here, because sticky nodes only respond to
20668        changes in their direct scrolling ancestors. Only adjust the layer if the parent
20669        is a scrolling node.
20670
206712014-05-27  Chris Fleizach  <cfleizach@apple.com>
20672
20673        AX: WebKit does not recognize ARIA 1.1 tables
20674        https://bugs.webkit.org/show_bug.cgi?id=133163
20675
20676        Reviewed by Darin Adler.
20677
20678        The AXObjectCache code that determines which object to create based on the role needs to be token fallback aware.
20679
20680        Test: accessibility/table-fallback-roles-expose-element-attributes.html
20681
20682        * accessibility/AXObjectCache.cpp:
20683        (WebCore::nodeHasRole):
20684
206852014-05-28  Radu Stavila  <stavila@adobe.com>
20686
20687        REGRESSION (r168046): Invalid layout in multicol
20688        https://bugs.webkit.org/show_bug.cgi?id=133322
20689
20690        Reviewed by Antti Koivisto.
20691
20692        In some situations, deleting the line boxes of a multicol element causes the line to region
20693        link to become invalid.
20694
20695        Test: fast/multicol/newmulticol/multicol-inside-multicol.html
20696
20697        * rendering/RenderFlowThread.cpp:
20698        (WebCore::RenderFlowThread::clearLinesToRegionMap):
20699        (WebCore::RenderFlowThread::deleteLines):
20700        (WebCore::RenderFlowThread::willBeDestroyed):
20701        * rendering/RenderFlowThread.h:
20702
207032014-05-28  Ryuan Choi  <ryuan.choi@samsung.com>
20704
20705        Remove DocumentThreadableLoaderClient.h
20706        https://bugs.webkit.org/show_bug.cgi?id=133341
20707
20708        Reviewed by Gyuyoung Kim.
20709
20710        DocumentThreadableLoaderClient is not used anymore.
20711
20712        * WebCore.order:
20713        * loader/DocumentThreadableLoader.cpp:
20714        (WebCore::DocumentThreadableLoader::redirectReceived):
20715        * loader/DocumentThreadableLoaderClient.h: Removed.
20716        * loader/ThreadableLoaderClient.h:
20717        (WebCore::ThreadableLoaderClient::isDocumentThreadableLoaderClient): Deleted.
20718
207192014-05-28  Carlos Garcia Campos  <cgarcia@igalia.com>
20720
20721        Unreviewed. Update GObject DOM bindings symbols file after r169017.
20722
20723        * bindings/gobject/webkitdom.symbols: Add webkit_dom_navigator_get_hardware_concurrency.
20724
207252014-05-28  Carlos Garcia Campos  <cgarcia@igalia.com>
20726
20727        REGRESSION(r168868): [GTK] Element.offset* client* scroll* API changed
20728        https://bugs.webkit.org/show_bug.cgi?id=133313
20729
20730        Reviewed by Philippe Normand.
20731
20732        Keep old API that uses long also for GObject bindings.
20733
20734        * dom/Element.idl:
20735
207362014-05-27  Commit Queue  <commit-queue@webkit.org>
20737
20738        Unreviewed, rolling out r169400.
20739        https://bugs.webkit.org/show_bug.cgi?id=133338
20740
20741        Broke the iOS build in
20742        LocalizedDateCache::calculateMaximumWidth() (Requested by smfr
20743        on #webkit).
20744
20745        Reverted changeset:
20746
20747        "SVG TextRuns do not always get RenderingContexts"
20748        https://bugs.webkit.org/show_bug.cgi?id=133198
20749        http://trac.webkit.org/changeset/169400
20750
207512014-05-27  Timothy Horton  <timothy_horton@apple.com>
20752
20753        REGRESSION (Margin tiles): Background gradient on dom.spec.whatwg.org is very slow to render
20754        https://bugs.webkit.org/show_bug.cgi?id=133335
20755        <rdar://problem/17011392>
20756
20757        Reviewed by Simon Fraser.
20758
20759        * platform/graphics/Image.cpp:
20760        (WebCore::Image::drawTiled):
20761        Make cross-platform and use some iOS code which avoids patterned drawing when the pattern buffer
20762        would be very large. Instead, it calls draw() repeatedly over the pattern space, avoiding the allocation
20763        of a huge (in the case of bug 133335, nearly 2GB) buffer.
20764
207652014-05-27  Simon Fraser  <simon.fraser@apple.com>
20766
20767        [iOS WK2] Fix behavior of position:sticky inside accelerated overflow-scroll
20768        https://bugs.webkit.org/show_bug.cgi?id=133334
20769        <rdar://problem/16462535>
20770
20771        Reviewed by Tim Horton.
20772
20773        When the scroll position changes in an accelerated overflow-scroll element, we have
20774        to update child nodes in the scrolling tree for position:sticky. That requires a
20775        more generic ability to update the scrolling tree after some arbitrary zoom or
20776        scroll. To do this, we need to know the current fixed position rect, rather than
20777        having it passed in.
20778        
20779        So make the fixed position rect available from ScrollingTree, and make it possible
20780        to get the current scrollPosition() from any ScrollingTreeScrollingNode.
20781        
20782        Also, implement updateLayersAfterDelegatedScroll() in ScrollingTreeOverflowScrollingNodeIOS,
20783        and have it update descendant layers.
20784        
20785        Finally, fix ScrollingTreeOverflowScrollingNode to use the correct rectangle for its
20786        constraints math, using the scroll position of the parent node if appropriate.
20787
20788        * page/scrolling/ScrollingTree.h:
20789        * page/scrolling/ScrollingTreeScrollingNode.h:
20790        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm:
20791        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateChildNodesAfterScroll):
20792        * page/scrolling/ios/ScrollingTreeIOS.cpp:
20793        (WebCore::ScrollingTreeIOS::fixedPositionRect):
20794        * page/scrolling/ios/ScrollingTreeIOS.h:
20795        * page/scrolling/mac/ScrollingTreeStickyNode.mm:
20796        (WebCore::ScrollingTreeStickyNode::updateLayersAfterAncestorChange):
20797
207982014-05-27  Simon Fraser  <simon.fraser@apple.com>
20799
20800        Do some renaming in the scrolling tree
20801        https://bugs.webkit.org/show_bug.cgi?id=133333
20802
20803        Reviewed by Tim Horton.
20804
20805        Rename ScrollingTreeNode::parentScrollPositionDidChange() to updateLayersAfterAncestorChange()
20806        since this goes deep and to indicate that it's about layer updating.
20807        
20808        Also rename the "viewportRect" parameter to "fixedPositionRect", since on iOS
20809        this is the custom fixed-position rect that changes on zooming.
20810
20811        * page/scrolling/ScrollingTree.cpp:
20812        (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling):
20813        * page/scrolling/ScrollingTree.h:
20814        * page/scrolling/ScrollingTreeFrameScrollingNode.h:
20815        * page/scrolling/ScrollingTreeNode.h:
20816        * page/scrolling/ScrollingTreeScrollingNode.h:
20817        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.h:
20818        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm:
20819        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateLayersAfterViewportChange):
20820        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateChildNodesAfterScroll):
20821        * page/scrolling/mac/ScrollingTreeFixedNode.h:
20822        * page/scrolling/mac/ScrollingTreeFixedNode.mm:
20823        (WebCore::ScrollingTreeFixedNode::updateLayersAfterAncestorChange):
20824        (WebCore::ScrollingTreeFixedNode::parentScrollPositionDidChange): Deleted.
20825        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
20826        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
20827        (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollLayerPosition):
20828        * page/scrolling/mac/ScrollingTreeStickyNode.h:
20829        * page/scrolling/mac/ScrollingTreeStickyNode.mm:
20830        (WebCore::ScrollingTreeStickyNode::updateLayersAfterAncestorChange):
20831        (WebCore::ScrollingTreeStickyNode::parentScrollPositionDidChange): Deleted.
20832
208332014-05-27  Simon Fraser  <simon.fraser@apple.com>
20834
20835        Instantiate a ScrollingTreeMac on Mac
20836        https://bugs.webkit.org/show_bug.cgi?id=133332
20837
20838        Reviewed by Tim Horton.
20839
20840        Mac previously instantiated a ThreadedScrollingTree, but this has no platform
20841        knowledge. To support future expansion, create a ScrollingTreeMac subclass and
20842        instantiate that on Mac.
20843        
20844        Also protect ScrollingCoordinatorMac in PLATFORM(MAC) #ifdefs and remove it from the
20845        EXCLUDED_SOURCE_FILE_NAMES list in the xcconfig file, following general trends.
20846
20847        * Configurations/WebCore.xcconfig:
20848        * WebCore.xcodeproj/project.pbxproj:
20849        * page/scrolling/ThreadedScrollingTree.cpp:
20850        (WebCore::ThreadedScrollingTree::create): Deleted.
20851        * page/scrolling/ThreadedScrollingTree.h:
20852        * page/scrolling/mac/ScrollingCoordinatorMac.h:
20853        * page/scrolling/mac/ScrollingCoordinatorMac.mm:
20854        (WebCore::ScrollingCoordinatorMac::ScrollingCoordinatorMac):
20855        * page/scrolling/mac/ScrollingTreeMac.cpp: Copied from Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.h.
20856        (ScrollingTreeMac::create):
20857        (ScrollingTreeMac::ScrollingTreeMac):
20858        * page/scrolling/mac/ScrollingTreeMac.h: Copied from Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.h.
20859
208602014-05-27  Simon Fraser  <simon.fraser@apple.com>
20861
20862        Prepare for position:sticky support inside accelerated overflow-scroll with WK2
20863        https://bugs.webkit.org/show_bug.cgi?id=133329
20864
20865        Reviewed by Tim Horton.
20866
20867        RenderLayerCompositor::computeStickyViewportConstraints() was always using
20868        the viewport rect as the constraining rect for sticky position. This is not
20869        correct when inside overflow:scroll.
20870        
20871        Refactor code in RenderBoxModelObject to make getting the rect easy, and use
20872        it to compute the constraints.
20873
20874        * rendering/RenderBoxModelObject.cpp:
20875        (WebCore::RenderBoxModelObject::constrainingRectForStickyPosition):
20876        (WebCore::RenderBoxModelObject::stickyPositionOffset):
20877        * rendering/RenderBoxModelObject.h:
20878        * rendering/RenderLayerCompositor.cpp:
20879        (WebCore::RenderLayerCompositor::computeStickyViewportConstraints):
20880
208812014-05-27  Bem Jones-Bey  <bjonesbe@adobe.com>
20882
20883        vw/vh units used as font/line-height values don't scale with the viewport
20884        https://bugs.webkit.org/show_bug.cgi?id=87846
20885
20886        Reviewed by Darin Adler.
20887
20888        This patch moves the resolution of viewport units to style recalc
20889        time. Currently viewport units are left unresolved during style
20890        recalcs, which leads to many problems with viewport units. Moving the
20891        resolution will fix these problems, as well as reduce the plumbing
20892        that goes on.
20893
20894        This patch touches a lot of files since the valueForLength functions
20895        no longer need a RenderView. The interesting changes are in:
20896
20897        - CSSToLengthConversionData -> CSSPrimitiveValue: for moving
20898            resolution to style recalc time.
20899        - Length / LengthFunctions: no longer needs to know about viewport
20900            units.
20901        - FrameView -> Document -> StyleResolver: for scheduling style recalcs
20902            upon resize
20903
20904        Note that getComputedStyle will now return pixel values when viewport
20905        units are used. This behavior matches Firefox and the css3-cascade
20906        spec.
20907
20908        This is based on a Blink patch by timloh@chromium.org.
20909
20910        Tests: css3/viewport-percentage-lengths/viewport-percentage-lengths-anonymous-block.html
20911               css3/viewport-percentage-lengths/viewport-percentage-lengths-calc.html
20912               css3/viewport-percentage-lengths/viewport-percentage-lengths-percent-size-child.html
20913               css3/viewport-percentage-lengths/viewport-percentage-lengths-relative-font-size.html
20914               css3/viewport-percentage-lengths/viewport-percentage-lengths-resize.html
20915
20916        * WebCore.exp.in: Remove RenderView argument to floatValueForLength.
20917        * accessibility/atk/WebKitAccessibleInterfaceText.cpp: 
20918        (getAttributeSetForAccessibilityObject): Remove RenderView argument.
20919        * css/BasicShapeFunctions.cpp:
20920        (WebCore::convertToLength): Ditto.
20921        (WebCore::floatValueForCenterCoordinate): Ditto.
20922        * css/BasicShapeFunctions.h: Ditto.
20923        * css/CSSCalculationValue.cpp:
20924        (WebCore::unitCategory): Remove special handling for viewport units,
20925            as they get resolved to pixels.
20926        (WebCore::createCSS): Ditto.
20927        * css/CSSComputedStyleDeclaration.cpp:
20928        (WebCore::positionOffsetValue): Remove RendewView argument.
20929        (WebCore::getBorderRadiusCornerValues): Remove handling of viewport
20930            units, as they are already resolve to pixels here.
20931        (WebCore::getBorderRadiusCornerValue): Remove RenderView argument.
20932        (WebCore::getBorderRadiusShorthandValue): Ditto.
20933        (WebCore::specifiedValueForGridTrackBreadth): Remove handling of
20934            viewport units, as they are already resolved to pixels here.
20935        (WebCore::specifiedValueForGridTrackSize): Remove RenderView argument.
20936        (WebCore::valueForGridTrackList): Ditto.
20937        (WebCore::lineHeightFromStyle): Ditto.
20938        (WebCore::ComputedStyleExtractor::propertyValue): Ditto.
20939        * css/CSSGradientValue.cpp:
20940        (WebCore::CSSLinearGradientValue::createGradient): Pass RenderView to
20941            CSSToLengthConversionData constructor.
20942        (WebCore::CSSRadialGradientValue::createGradient): Ditto.
20943        * css/CSSPrimitiveValue.cpp:
20944        (WebCore::CSSPrimitiveValue::unitCategory): Remove handling of
20945            viewport units, as they get resolved to pixels.
20946        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Ditto.
20947        (WebCore::CSSPrimitiveValue::init): Ditto.
20948        (WebCore::CSSPrimitiveValue::computeLengthDouble): Resolve viewport
20949            units to pixels.
20950        (WebCore::CSSPrimitiveValue::canonicalUnitTypeForCategory): Remove
20951        handling of viewport units, since they get resolved to pixels.
20952        (WebCore::CSSPrimitiveValue::viewportPercentageLength): Deleted.
20953        * css/CSSPrimitiveValue.h:
20954        (WebCore::CSSPrimitiveValue::isLength): Remove special handling of
20955            viewport units, since they get resolved to pixels.
20956        * css/CSSPrimitiveValueMappings.h:
20957        (WebCore::CSSPrimitiveValue::convertToLength): Ditto.
20958        * css/CSSToLengthConversionData.cpp:
20959        (WebCore::CSSToLengthConversionData::viewportWidthFactor): Caclulate
20960            conversion factor for viewport units to pixels. Note this does not
20961            set hasViewportUnits on the RenderStyle if computing the font
20962            size, because in the font size case, the RenderStyle is the
20963            parent's style, not the current renderer's style.
20964        (WebCore::CSSToLengthConversionData::viewportHeightFactor): Ditto.
20965        (WebCore::CSSToLengthConversionData::viewportMinFactor): Ditto.
20966        (WebCore::CSSToLengthConversionData::viewportMaxFactor): Ditto.
20967        * css/CSSToLengthConversionData.h:
20968        (WebCore::CSSToLengthConversionData::CSSToLengthConversionData): Add
20969            RenderView parameter, and make RenderStyle non-const so that
20970            hasViewportUnits can be set on the Style..
20971        (WebCore::CSSToLengthConversionData::style): style is now non-const.
20972        (WebCore::CSSToLengthConversionData::copyWithAdjustedZoom): Handle
20973            RenderView argument.
20974        * css/CSSToStyleMap.cpp:
20975        (WebCore::CSSToStyleMap::mapFillXPosition): Remove handling of
20976            viewport units, as they are already resolved to pixels here.
20977        (WebCore::CSSToStyleMap::mapFillYPosition): Ditto.
20978        * css/DeprecatedStyleBuilder.cpp:
20979        (WebCore::ApplyPropertyLength::applyValue): Ditto.
20980        (WebCore::ApplyPropertyBorderRadius::applyValue): Ditto.
20981        (WebCore::ApplyPropertyComputeLength::applyValue): Ditto.
20982        (WebCore::ApplyPropertyFontSize::applyValue): Ditto.
20983        (WebCore::ApplyPropertyLineHeight::applyValue): Ditto.
20984        (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyValue): Ditto.
20985        (WebCore::ApplyPropertyWordSpacing::applyValue): Ditto.
20986        (WebCore::ApplyPropertyVerticalAlign::applyValue): Ditto.
20987        (WebCore::ApplyPropertyTextIndent::applyValue): Ditto.
20988        * css/LengthFunctions.cpp:
20989        (WebCore::minimumIntValueForLength): Remove RenderView argument.
20990        (WebCore::intValueForLength): Remove RenderView argument and
20991            roundPecentages.
20992        (WebCore::minimumValueForLength): Remove RenderView argument, and
20993            special handling of viewport units.
20994        (WebCore::valueForLength): Ditto.
20995        (WebCore::floatValueForLength): Ditto.
20996        (WebCore::floatSizeForLengthSize): Remove RenderView argument.
20997        * css/LengthFunctions.h: Ditto.
20998        * css/MediaQueryEvaluator.cpp:
20999        (WebCore::MediaQueryEvaluator::eval): Add RenderView argument for
21000            CSSToLengthConversionData constuctor.
21001        * css/StyleResolver.cpp:
21002        (WebCore::StyleResolver::State::clear): Change to 0 arg constructor
21003            for CSSToLengthConversionData.
21004        (WebCore::StyleResolver::State::updateConversionData): In order to get
21005            the RenderView, we need to have a valid Element set on the state.
21006            Since this means that we need to set the conversion data in more
21007            places, move the contruction of conversion data into this helper
21008            method.
21009        (WebCore::StyleResolver::State::initElement): Make sure conversion
21010            data is up to date.
21011        (WebCore::StyleResolver::State::initForStyleResolve): Ditto.
21012        (WebCore::StyleResolver::State::setStyle): When the style is set, we
21013            need to make sure to update the conversion data.
21014        (WebCore::StyleResolver::styleForElement): If the style has viewport
21015            units, flage the document so that we can make sure to recalc the
21016            viewport unit values when the viewport is resized.
21017        (WebCore::StyleResolver::pseudoStyleForElement): Ditto.
21018        (WebCore::StyleResolver::updateFont): Make sure the font having
21019            viewport units updates the style.
21020        (WebCore::StyleResolver::convertToIntLength): Remove handling of
21021        viewport units, as they are resolved to pixels.
21022        (WebCore::StyleResolver::convertToFloatLength): Ditto.
21023        (WebCore::StyleResolver::clearCachedPropertiesAffectedByViewportUnits):
21024            Invalidate the matched properties cache for styles with viewport
21025            units when the viewport is resized.
21026        (WebCore::createGridTrackBreadth): Remove handling of viewport units,
21027            as they are resolved to pixels.
21028        (WebCore::StyleResolver::applyProperty): Ditto.
21029        (WebCore::StyleResolver::hasMediaQueriesAffectedByViewportChange):
21030            Rename to be less confusing, since it has nothing to do with
21031            viewport units.
21032        (WebCore::StyleResolver::createFilterOperations): Remove handling of
21033            viewport units, as they are resolved to pixels.
21034        (WebCore::StyleResolver::affectedByViewportChange): Deleted.
21035        (WebCore::StyleResolver::viewportPercentageValue): Deleted.
21036        * css/StyleResolver.h:
21037        (WebCore::StyleResolver::State::State): C++11 cleanup: 0 -> nullptr.
21038        (WebCore::StyleResolver::State::setFontSizeHasViewportUnits): Set if
21039            the font size is specified in viewport units.
21040        (WebCore::StyleResolver::State::fontSizeHasViewportUnits): Ditto.
21041        (WebCore::StyleResolver::State::setStyle): Deleted.
21042        * css/TransformFunctions.cpp:
21043        (WebCore::convertToFloatLength): Remove handling of viewport units,
21044            since they are resolved to pixels.
21045        * dom/Document.cpp:
21046        (WebCore::Document::Document): Add flag to determine if some style in
21047            the document has viewport units.
21048        (WebCore::Document::pageSizeAndMarginsInPixels): Remove RenderView
21049            argument.
21050        (WebCore::Document::updateViewportUnitsOnResize): Mark elements with
21051            viewport units for style recalc when the viewport size has
21052            changed.
21053        * dom/Document.h:
21054        (WebCore::Document::setHasStyleWithViewportUnits): Flag to determine
21055            if some style in the document has viewport units.
21056        (WebCore::Document::hasStyleWithViewportUnits): Ditto.
21057        * html/HTMLAreaElement.cpp:
21058        (WebCore::HTMLAreaElement::getRegion): Remove RenderView argument.
21059        * page/FrameView.cpp:
21060        (WebCore::FrameView::layout): When the viewport is resized, call
21061            updateViewportUnitsOnResize on the document.
21062        * platform/Length.h:
21063        (WebCore::Length::isSpecified): Remove handling of viewport units,
21064            since they are now resolved to pixels.
21065        (WebCore::Length::viewportPercentageLength): Deleted.
21066        (WebCore::Length::isViewportPercentage): Deleted.
21067        * rendering/ClipPathOperation.h:
21068        (WebCore::ShapeClipPathOperation::pathForReferenceRect): Remove
21069            RenderView argument.
21070        (WebCore::BoxClipPathOperation::pathForReferenceRect): Ditto.
21071        * rendering/RenderBlock.cpp:
21072        (WebCore::RenderBlock::updateBlockChildDirtyBitsBeforeLayout): Remove
21073            handling of viewport units, since they get updated by
21074            updateViewportUnitsOnResize when the viewport is resized.
21075        (WebCore::RenderBlock::nodeAtPoint): Remove RenderView argument.
21076        (WebCore::RenderBlock::lineHeight): Ditto.
21077        * rendering/RenderBox.cpp:
21078        (WebCore::RenderBox::paintBoxDecorations): Remove RenderView argument.
21079        (WebCore::RenderBox::computeContentAndScrollbarLogicalHeightUsing):
21080            Remove handling of viewport units, as they are resolved to pixels.
21081        (WebCore::RenderBox::computePercentageLogicalHeight): Ditto.
21082        (WebCore::RenderBox::computeReplacedLogicalWidthUsing): Ditto.
21083        (WebCore::RenderBox::computeReplacedLogicalHeightUsing): Ditto.
21084        (WebCore::RenderBox::hasViewportPercentageLogicalHeight): Deleted.
21085        * rendering/RenderBox.h:
21086        * rendering/RenderBoxModelObject.cpp:
21087        (WebCore::RenderBoxModelObject::getBackgroundRoundedRect): Remove
21088            RenderView argument.
21089        (WebCore::RenderBoxModelObject::calculateFillTileSize): Remove
21090            handling of viewport units, as they are resolved to pixels.
21091        (WebCore::computeBorderImageSide): Remove RenderView argument.
21092        (WebCore::RenderBoxModelObject::paintNinePieceImage): Ditto.
21093        (WebCore::RenderBoxModelObject::paintBorder): Ditto.
21094        (WebCore::RenderBoxModelObject::paintBoxShadow): Ditto.
21095        * rendering/RenderElement.cpp:
21096        (WebCore::RenderElement::repaintAfterLayoutIfNeeded): Ditto.
21097        * rendering/RenderElement.h:
21098        (WebCore::RenderElement::valueForLength): Remove unused
21099            roundPercentages argument.
21100        (WebCore::RenderElement::minimumValueForLength): Remove unused
21101            RoundPercentages and RenderView arguments.
21102        * rendering/RenderGrid.cpp:
21103        (WebCore::RenderGrid::layoutGridItems): Remove handling of viewport
21104            units as they are resolved to pixels.
21105        * rendering/RenderInline.cpp:
21106        (WebCore::computeMargin): Ditto.
21107        (WebCore::RenderInline::lineHeight): Remove RenderView argument.
21108        * rendering/RenderLayer.cpp:
21109        (WebCore::RenderLayer::setupClipPath): Ditto.
21110        * rendering/RenderLineBreak.cpp:
21111        (WebCore::RenderLineBreak::lineHeight): Ditto.
21112        * rendering/RenderScrollbarPart.cpp:
21113        (WebCore::calcScrollbarThicknessUsing): Ditto.
21114        (WebCore::RenderScrollbarPart::computeScrollbarWidth): Ditto.
21115        (WebCore::RenderScrollbarPart::computeScrollbarHeight): Ditto.
21116        * rendering/RenderTable.cpp:
21117        (WebCore::RenderTable::convertStyleLogicalHeightToComputedHeight):
21118            Remove handling of viewport units, since they are resolved to
21119            pixels.
21120        (WebCore::RenderTable::computePreferredLogicalWidths): Now that
21121            viewport unit values are resolved to pixels at style recalc time,
21122            no special checking is needed to handle them, so update the
21123            comment to reflect that.
21124        * rendering/RenderThemeIOS.mm:
21125        (WebCore::applyCommonButtonPaddingToStyle): Add RenderView argument to
21126            CSSToLengthConversionData constructor.
21127        (WebCore::RenderThemeIOS::adjustButtonStyle): Ditto.
21128        * rendering/RenderThemeMac.mm:
21129        (WebCore::RenderThemeMac::paintMenuListButtonGradients): Remove
21130            RenderView argument.
21131        * rendering/RenderView.cpp:
21132        (WebCore::RenderView::layout): Remove handling of viewport units,
21133            since they are resolved to pixels.
21134        * rendering/RootInlineBox.cpp:
21135        (WebCore::RootInlineBox::ascentAndDescentForBox): Remove RenderView
21136            argument.
21137        * rendering/shapes/Shape.cpp:
21138        (WebCore::Shape::createShape): Remove RenderView argument.
21139        * rendering/shapes/Shape.h:
21140        * rendering/shapes/ShapeOutsideInfo.cpp:
21141        (WebCore::ShapeOutsideInfo::computedShape): Ditto.
21142        * rendering/style/BasicShapes.cpp:
21143        (WebCore::BasicShapeCircle::floatValueForRadiusInBox): Ditto.
21144        (WebCore::BasicShapeCircle::path): Ditto.
21145        (WebCore::BasicShapeEllipse::floatValueForRadiusInBox): Ditto.
21146        (WebCore::BasicShapeEllipse::path): Ditto.
21147        (WebCore::BasicShapePolygon::path): Ditto.
21148        (WebCore::floatSizeForLengthSize): Ditto.
21149        (WebCore::BasicShapeInset::path): Ditto.
21150        * rendering/style/BasicShapes.h:
21151        * rendering/style/RenderStyle.cpp:
21152        (WebCore::calcRadiiFor): Ditto.
21153        (WebCore::RenderStyle::getRoundedBorderFor): Ditto.
21154        (WebCore::RenderStyle::computedLineHeight): Remove handling of
21155            viewport units since they are resolved to pixels.
21156        * rendering/style/RenderStyle.h:
21157        (WebCore::RenderStyle::setHasViewportUnits): Set if this style has
21158        a property set with viewport units.
21159        (WebCore::RenderStyle::hasViewportUnits): Ditto.
21160        * rendering/svg/RenderSVGRoot.cpp:
21161        (WebCore::resolveLengthAttributeForSVG): Remove RenderView argument.
21162        (WebCore::RenderSVGRoot::computeReplacedLogicalWidth): Ditto.
21163        (WebCore::RenderSVGRoot::computeReplacedLogicalHeight): Ditto.
21164        * rendering/svg/SVGRenderingContext.cpp:
21165        (WebCore::SVGRenderingContext::prepareToRenderSVGContent): Ditto.
21166
211672014-05-27  Zoltan Horvath  <zoltan@webkit.org>
21168
21169        [CSS Shapes] serialization of the computed value should omit the default radii
21170        https://bugs.webkit.org/show_bug.cgi?id=132747
21171
21172        Reviewed by Darin Adler.
21173
21174        We should omit closest-side value, whereever is possible. Specification:
21175        http://www.w3.org/TR/2014/CR-css-shapes-1-20140320/#basic-shape-computed-values 
21176        This change aligns the behavior to the specification.
21177
21178        Added new test cases for the shape-outside parsing tests.
21179
21180        * css/CSSBasicShapes.cpp:
21181        (WebCore::buildCircleString):
21182        (WebCore::CSSBasicShapeCircle::cssText):
21183        (WebCore::CSSBasicShapeEllipse::cssText):
21184
211852014-05-27  Commit Queue  <commit-queue@webkit.org>
21186
21187        Unreviewed, rolling out r169399.
21188        https://bugs.webkit.org/show_bug.cgi?id=133326
21189
21190        Causes assertion failures in tests.  See
21191        http://build.webkit.org/results/Apple%20Mavericks%20Debug%20WK1%20(Tests)/r169399%20(5622)/results.html
21192        (Requested by mlam on #webkit).
21193
21194        Reverted changeset:
21195
21196        "Caret's screen position does not update during an overflow
21197        scroll"
21198        https://bugs.webkit.org/show_bug.cgi?id=133256
21199        http://trac.webkit.org/changeset/169399
21200
212012014-05-27  Myles C. Maxfield  <mmaxfield@apple.com>
21202
21203        Lists styled with SVG fonts are not rendered as expected
21204        https://bugs.webkit.org/show_bug.cgi?id=133198
21205
21206        Reviewed by Simon Fraser.
21207
21208        There were a couple places in RenderListMarker and RenderMenuList that were
21209        implicitly creating TextRuns by passing a String to a function which
21210        expected a TextRun. Because TextRun has a constructor which takes a single
21211        String and isn't marked explicit, TextRuns were being created without
21212        any of the associated code that initializes the TextRun (such as creating
21213        a RenderingContext if necessary).
21214
21215        This patch marks the aforementioned constructor as "explicit" to discourage
21216        such behavior in the future.
21217
21218        Test: svg/custom/list-items-with-svg-font-family.html
21219
21220        * platform/graphics/TextRun.h:
21221        (WebCore::TextRun::TextRun): Mark constructors as explicit.
21222        * rendering/RenderListMarker.cpp:
21223        (WebCore::RenderListMarker::computePreferredLogicalWidths): Call
21224        RenderBlock::constructTextRun.
21225        (WebCore::RenderListMarker::getRelativeMarkerRect): Ditto.
21226        * rendering/RenderMenuList.cpp:
21227        (RenderMenuList::updateOptionsWidth): Ditto.
21228
212292014-05-23  Myles C. Maxfield  <mmaxfield@apple.com>
21230
21231        Caret's screen position does not update during an overflow scroll
21232        https://bugs.webkit.org/show_bug.cgi?id=133256
21233
21234        Reviewed by Simon Fraser.
21235
21236        During a scroll, we set a flag which caret position is gated on, but we never
21237        actually invalidate the caret's position. This patch does so.
21238
21239        Test: editing/input/caret-position-during-scroll.html
21240
21241        * editing/FrameSelection.h:
21242        * rendering/RenderLayer.cpp:
21243        (WebCore::RenderLayer::scrollTo):
21244
212452014-05-27  Timothy Horton  <timothy_horton@apple.com>
21246
21247        Turn on the LayerPool for iOS
21248        https://bugs.webkit.org/show_bug.cgi?id=133299
21249
21250        Reviewed by Antti Koivisto.
21251
21252        * Configurations/WebCore.xcconfig:
21253        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
21254        (WebCore::MemoryPressureHandler::platformReleaseMemory):
21255        * platform/graphics/ca/mac/TileController.mm:
21256        (WebCore::TileController::createTileLayer):
21257        * platform/graphics/ca/mac/TileGrid.mm:
21258        (WebCore::TileGrid::removeTiles):
21259        Turn on the LayerPool for iOS.
21260        We've used this on Mac for a long time, and the WebKit1
21261        ("legacy") iOS TileCache also had a similar pool.
21262        This helps a good bit with flashiness while scrolling.
21263
212642014-05-27  David Hyatt  <hyatt@apple.com>
21265
21266        REGRESSION: Audio volume scrubber does not show volume level thumb
21267        <rdar://problem/16902004>
21268        https://bugs.webkit.org/show_bug.cgi?id=133310
21269
21270        Reviewed by Dean Jackson.
21271
21272        This was just a silly mistake on my part with the setting of the pagination
21273        layers. Layers inside transforms are supposed to clear out their pagination
21274        status based off their ancestor containing block layers, and not off the
21275        enclosing pagination layer.
21276        
21277        Added fast/multicol/pagination/nested-transforms.html
21278
21279        * rendering/RenderLayer.cpp:
21280        (WebCore::RenderLayer::updatePagination):
21281
212822014-05-27  Eric Carlson  <eric.carlson@apple.com>
21283
21284        [Mac] media controls should prevent 'click' events from reaching the page
21285        https://bugs.webkit.org/show_bug.cgi?id=133268
21286
21287        Reviewed by Jer Noble.
21288
21289        Test: media/media-controls-cancel-events.html
21290
21291        * Modules/mediacontrols/mediaControlsApple.js:
21292        (Controller.prototype.handleEvent): Allow event handler to cancel event default action.
21293        (Controller.prototype.handleRewindButtonClicked): Cancel event default.
21294        (Controller.prototype.handlePlayButtonClicked): Ditto.
21295        (Controller.prototype.handleMuteButtonClicked): Ditto.
21296        (Controller.prototype.handleMinButtonClicked): Ditto.
21297        (Controller.prototype.handleCaptionButtonClicked): Ditto.
21298        (Controller.prototype.handleFullscreenButtonClicked): Ditto.
21299        * Modules/mediacontrols/mediaControlsiOS.js:
21300        (ControllerIOS.prototype.handlePlayButtonTouchEnd): Ditto.
21301        (ControllerIOS.prototype.handlePlayButtonTouchCancel): Ditto.
21302        (ControllerIOS.prototype.handleFullscreenTouchEnd): Ditto.
21303        (ControllerIOS.prototype.handleFullscreenTouchCancel): Ditto.
21304        (ControllerIOS.prototype.handleStartPlaybackButtonTouchEnd): Ditto.
21305        (ControllerIOS.prototype.handleStartPlaybackButtonTouchCancel): Ditto.
21306        (ControllerIOS.prototype.handleWirelessPickerButtonClicked): Ditto.
21307
213082014-05-27  Jon Lee  <jonlee@apple.com>
21309
21310        Fix Mavericks bots from r169383.
21311        https://bugs.webkit.org/show_bug.cgi?id=133311
21312
21313        Reviewed by Eric Carlson.
21314
21315        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.h: Update #ifdef to check for ENABLE(MEDIA_SOURCE).
21316        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm: Ditto.
21317
213182014-05-27  Radu Stavila  <stavila@adobe.com>
21319
21320        REGRESSION (r168046): Incorrect handling of multicol spanner
21321        https://bugs.webkit.org/show_bug.cgi?id=133249
21322
21323        Reviewed by David Hyatt.
21324
21325        When removing the child of an object, the removeChild method should return the next element
21326        following the one being deleted. This will ensure that proper iteration and destruction of
21327        an object's children is possible.
21328
21329        No new tests added. This is because the test that triggers this issue also triggers
21330        another assertion, in RenderMultiColumnSet::requiresBalancing(). However, that is a totally
21331        separate problem and will be handled in a separate bug: https://bugs.webkit.org/show_bug.cgi?id=133309
21332
21333        * rendering/RenderBlock.cpp:
21334        (WebCore::RenderBlock::removeChild):
21335        * rendering/RenderBlock.h:
21336        * rendering/RenderBlockFlow.cpp:
21337        (WebCore::RenderBlockFlow::removeChild):
21338        * rendering/RenderBlockFlow.h:
21339        * rendering/RenderButton.cpp:
21340        (WebCore::RenderButton::removeChild):
21341        * rendering/RenderButton.h:
21342        * rendering/RenderElement.cpp:
21343        (WebCore::RenderElement::removeChild):
21344        (WebCore::RenderElement::removeChildInternal):
21345        * rendering/RenderElement.h:
21346        * rendering/RenderMenuList.cpp:
21347        (RenderMenuList::removeChild):
21348        * rendering/RenderMenuList.h:
21349        * rendering/RenderMultiColumnFlowThread.cpp:
21350        (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantInserted):
21351        * rendering/RenderRuby.cpp:
21352        (WebCore::RenderRubyAsInline::removeChild):
21353        (WebCore::RenderRubyAsBlock::removeChild):
21354        * rendering/RenderRuby.h:
21355        * rendering/RenderRubyRun.cpp:
21356        (WebCore::RenderRubyRun::removeChild):
21357        * rendering/RenderRubyRun.h:
21358        * rendering/mathml/RenderMathMLScripts.cpp:
21359        (WebCore::RenderMathMLScripts::removeChildInternal):
21360        (WebCore::RenderMathMLScripts::removeChild):
21361        (WebCore::RenderMathMLScriptsWrapper::removeChildInternal):
21362        (WebCore::RenderMathMLScriptsWrapper::removeChild):
21363        * rendering/mathml/RenderMathMLScripts.h:
21364        * rendering/svg/RenderSVGContainer.cpp:
21365        (WebCore::RenderSVGContainer::removeChild):
21366        * rendering/svg/RenderSVGContainer.h:
21367        * rendering/svg/RenderSVGInline.cpp:
21368        (WebCore::RenderSVGInline::removeChild):
21369        * rendering/svg/RenderSVGInline.h:
21370        * rendering/svg/RenderSVGRoot.cpp:
21371        (WebCore::RenderSVGRoot::removeChild):
21372        * rendering/svg/RenderSVGRoot.h:
21373        * rendering/svg/RenderSVGText.cpp:
21374        (WebCore::RenderSVGText::removeChild):
21375        * rendering/svg/RenderSVGText.h:
21376
213772014-05-27  Jon Lee  <jonlee@apple.com>
21378
21379        Update ENABLE(MEDIA_SOURCE) on Mac
21380        https://bugs.webkit.org/show_bug.cgi?id=133141
21381
21382        Reviewed by Darin Adler.
21383
21384        * Configurations/FeatureDefines.xcconfig:
21385
213862014-05-27  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
21387
21388        Remove BLOB guards
21389        https://bugs.webkit.org/show_bug.cgi?id=132863
21390
21391        Reviewed by Csaba Osztrogonác.
21392
21393        * Configurations/FeatureDefines.xcconfig:
21394        * Modules/websockets/WebSocketChannel.cpp:
21395        (WebCore::WebSocketChannel::WebSocketChannel):
21396        (WebCore::WebSocketChannel::didFail):
21397        (WebCore::WebSocketChannel::processOutgoingFrameQueue):
21398        (WebCore::WebSocketChannel::abortOutgoingFrameQueue):
21399        * Modules/websockets/WebSocketChannel.h:
21400        * WebCore.exp.in:
21401        * WebCore.vcxproj/WebCore.vcxproj:
21402        * bindings/js/JSBlobCustom.cpp:
21403        (WebCore::JSBlobConstructor::constructJSBlob):
21404        * bindings/js/JSFileReaderCustom.cpp:
21405        * dom/DOMExceptions.in:
21406        * dom/EventTargetFactory.in:
21407        * dom/ScriptExecutionContext.cpp:
21408        (WebCore::ScriptExecutionContext::publicURLManager):
21409        * dom/ScriptExecutionContext.h:
21410        * fileapi/AsyncFileStream.cpp:
21411        * fileapi/AsyncFileStream.h:
21412        * fileapi/Blob.cpp:
21413        (WebCore::Blob::Blob):
21414        * fileapi/Blob.h:
21415        (WebCore::Blob::slice):
21416        * fileapi/Blob.idl:
21417        * fileapi/FileError.h:
21418        * fileapi/FileError.idl:
21419        * fileapi/FileException.cpp:
21420        * fileapi/FileException.h:
21421        * fileapi/FileException.idl:
21422        * fileapi/FileReader.cpp:
21423        * fileapi/FileReader.h:
21424        * fileapi/FileReader.idl:
21425        * fileapi/FileReaderLoader.cpp:
21426        * fileapi/FileReaderLoader.h:
21427        * fileapi/FileReaderLoaderClient.h:
21428        * fileapi/FileReaderSync.cpp:
21429        * fileapi/FileReaderSync.h:
21430        * fileapi/FileReaderSync.idl:
21431        * fileapi/FileThread.cpp:
21432        * fileapi/FileThread.h:
21433        * fileapi/ThreadableBlobRegistry.cpp:
21434        (WebCore::ThreadableBlobRegistry::registerFileBlobURL): Deleted.
21435        (WebCore::ThreadableBlobRegistry::registerBlobURL): Deleted.
21436        (WebCore::ThreadableBlobRegistry::registerBlobURLForSlice): Deleted.
21437        (WebCore::ThreadableBlobRegistry::unregisterBlobURL): Deleted.
21438        (WebCore::ThreadableBlobRegistry::blobSize): Deleted.
21439        (WebCore::ThreadableBlobRegistry::getCachedOrigin): Deleted.
21440        * fileapi/WebKitBlobBuilder.cpp:
21441        (WebCore::BlobBuilder::append):
21442        * fileapi/WebKitBlobBuilder.h:
21443        * html/DOMURL.cpp:
21444        * html/DOMURL.h:
21445        * html/DOMURL.idl:
21446        * html/PublicURLManager.cpp:
21447        * html/PublicURLManager.h:
21448        * loader/LoaderStrategy.cpp:
21449        (WebCore::LoaderStrategy::createBlobRegistry):
21450        * loader/LoaderStrategy.h:
21451        * page/DOMWindow.idl:
21452        * page/SecurityOrigin.cpp:
21453        (WebCore::SecurityOrigin::shouldUseInnerURL):
21454        (WebCore::getCachedOrigin):
21455        * platform/FileStream.cpp:
21456        * platform/FileStream.h:
21457        * platform/FileStreamClient.h:
21458        * platform/SchemeRegistry.cpp:
21459        (WebCore::canDisplayOnlyIfCanRequestSchemes):
21460        * platform/network/BlobRegistry.cpp:
21461        * platform/network/BlobRegistryImpl.cpp:
21462        * platform/network/BlobResourceHandle.cpp:
21463        * platform/network/BlobResourceHandle.h:
21464        * platform/network/FormData.cpp:
21465        (WebCore::FormData::deepCopy):
21466        (WebCore::FormData::appendFile):
21467        (WebCore::FormData::appendBlob):
21468        (WebCore::FormData::appendKeyValuePairItems):
21469        (WebCore::FormData::resolveBlobReferences):
21470        (WebCore::encodeElement):
21471        (WebCore::decodeElement):
21472        * platform/network/FormData.h:
21473        (WebCore::FormDataElement::FormDataElement):
21474        (WebCore::operator==):
21475        * platform/network/cf/FormDataStreamCFNet.cpp:
21476        (WebCore::closeCurrentStream):
21477        (WebCore::advanceCurrentStream):
21478        (WebCore::formCreate):
21479        (WebCore::formRead):
21480        (WebCore::setHTTPBody):
21481        * platform/network/curl/ResourceHandleManager.cpp:
21482        (WebCore::getFormElementsCount):
21483        * platform/network/soup/ResourceHandleSoup.cpp:
21484        (WebCore::addEncodedBlobToSoupMessageBody):
21485        (WebCore::addFormElementsToSoupMessage):
21486        * workers/WorkerGlobalScope.idl:
21487        * xml/XMLHttpRequest.cpp:
21488        (WebCore::XMLHttpRequest::send):
21489        (WebCore::XMLHttpRequest::createRequest):
21490
214912014-05-27  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
21492
21493        Allow building CMake based ports with WEB_REPLAY
21494        https://bugs.webkit.org/show_bug.cgi?id=133154
21495
21496        Reviewed by Csaba Osztrogonác.
21497
21498        * CMakeLists.txt:
21499
215002014-05-27  Adrian Perez de Castro  <aperez@igalia.com>
21501
21502        [GStreamer] Add missing <wtf/MathExtras.h> header
21503        https://bugs.webkit.org/show_bug.cgi?id=133236
21504
21505        Reviewed by Philippe Normand.
21506
21507        In some configurations, not including <wtf/MathExtras.h> will cause
21508        errors about undefined functions. In particular, this happens in
21509        Linux with glibc 2.19 and compiling with Clang. Having the header
21510        included is the correct thing to do anyway.
21511
21512        * platform/graphics/gstreamer/GStreamerUtilities.cpp:
21513        Include <wtf/MathExtras.h>
21514
215152014-05-27  Manuel Rego Casasnovas  <rego@igalia.com>
21516
21517        Setting up OrderIterator shouldn't require an extra Vector
21518        https://bugs.webkit.org/show_bug.cgi?id=119061
21519
21520        Reviewed by Darin Adler.
21521
21522        From Blink r153971 by <jchaffraix@chromium.org>
21523
21524        This patches reuse the OrderIterator's Vector. It provides a helper class OrderIteratorPopulator, used for
21525        manipulating the Vector directly. Which allows to consolidate the code into a single implementation across
21526        flexbox and grid.
21527
21528        No new tests, already covered by current tests.
21529
21530        * rendering/OrderIterator.cpp:
21531        (WebCore::OrderIteratorPopulator::~OrderIteratorPopulator): Reset OrderIterator and call
21532        removeDuplicatedOrderValues().
21533        (WebCore::OrderIteratorPopulator::removeDuplicatedOrderValues): Sorts the Vector and removes the duplicated
21534        order values.
21535        (WebCore::OrderIteratorPopulator::collectChild): Collect order value information from child.
21536        (WebCore::OrderIterator::setOrderValues): Deleted.
21537        * rendering/OrderIterator.h:
21538        (WebCore::OrderIteratorPopulator::OrderIteratorPopulator): Add helper class to manipulate OrderValues Vector.
21539        * rendering/RenderFlexibleBox.cpp:
21540        (WebCore::RenderFlexibleBox::layoutBlock): Remove unneeded code related to old OrderValues vector.
21541        (WebCore::RenderFlexibleBox::prepareOrderIteratorAndMargins): Populate OrderIterator using collectChild().
21542        (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes): Deleted.
21543        * rendering/RenderFlexibleBox.h: Rename computeMainAxisPreferredSizes() to prepareOrderIteratorAndMargins().
21544        * rendering/RenderGrid.cpp:
21545        (WebCore::RenderGrid::populateExplicitGridAndOrderIterator): Populate OrderIterator using collectChild().
21546
215472014-05-26  Tim Horton  <timothy_horton@apple.com>
21548
21549        [wk2] RemoteLayerBackingStore front buffers should be purgeable when unparented
21550        https://bugs.webkit.org/show_bug.cgi?id=133020
21551        <rdar://problem/16521736>
21552
21553        Reviewed by Simon Fraser.
21554
21555        * WebCore.exp.in:
21556        * platform/graphics/cg/IOSurfacePool.cpp:
21557        (WebCore::IOSurfacePool::willAddSurface):
21558        * platform/graphics/cocoa/IOSurface.h:
21559        * platform/graphics/cocoa/IOSurface.mm:
21560        (IOSurface::releaseGraphicsContext):
21561        Rename clearGraphicsContext to releaseGraphicsContext for clarity.
21562
215632014-05-26  Philip Rogers  <pdr@google.com>
21564
21565        Remove special case for transparent SVG root layers
21566        https://bugs.webkit.org/show_bug.cgi?id=116856
21567
21568        Reviewed by Dirk Schulze.
21569
21570        This patch removes a special case from RenderLayer for root SVG layers
21571        with opacity. Instead of checking whether a composited layer exists in
21572        SVGRenderingContext::prepareToRenderSVGContent we now exclude the root
21573        SVG renderobject from the opacity checks in prepareToRenderSVGContent.
21574
21575        This is a merge of https://src.chromium.org/viewvc/blink?view=rev&revision=174102
21576        by Philip Rogers <pdr@chromium.org>.
21577
21578        No new tests as this is covered by svg/custom/composited-svg-with-opacity.html.
21579
21580        * rendering/RenderLayer.cpp:
21581        (WebCore::RenderLayer::isTransparent): Deleted.
21582        * rendering/RenderLayer.h:
21583        * rendering/svg/SVGRenderingContext.cpp:
21584        (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
21585            The opacity case for root svg renderers is now handled by
21586            RenderLayer.
21587
215882014-05-26  Yusuke Suzuki  <utatane.tea@gmail.com>
21589
21590        CSS JIT: Fix build error raised when CSS_SELECTOR_JIT_DEBUGGING is 1
21591        https://bugs.webkit.org/show_bug.cgi?id=133266
21592
21593        Reviewed by Benjamin Poulain.
21594
21595        When CSS_SELECTOR_JIT_DEBUGGING is 1, build erros occur on x86_64.
21596
21597        * cssjit/SelectorCompiler.cpp:
21598        (WebCore::SelectorCompiler::SelectorCodeGenerator::generatePrologue):
21599        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateEpilogue):
21600
216012014-05-26  Benjamin Poulain  <benjamin@webkit.org>
21602
21603        Fix the quirks mode selector matching of the pseudo classes :hover and :active
21604        https://bugs.webkit.org/show_bug.cgi?id=133063
21605
21606        Reviewed by Antti Koivisto.
21607
21608        Our implementation of the quirks mode of :active and :hover was very wrong. The only
21609        thing it was doing is verify the pseudo class is not the first selector of a fragment
21610        (which was conveniently the only thing that was tested :)).
21611
21612        Since those pseudo class were only checking for the order of the filters, something like
21613            #target:hover
21614        would succeed because :hover is not the first simple selector, while
21615            :hover#target
21616        would fail.
21617
21618        That behavior is also a problem for the CSS JIT as it is an implementation detail of SelectorChecker
21619        and compiling something like that with our out-of-order matching would be nonsense.
21620
21621        This patch update the implementation to follow http://quirks.spec.whatwg.org/#the-:active-and-:hover-quirk
21622        Basically, the only cases that do not work in quirks mode are selectors composed only of "*, :hover and :active".
21623
21624        To implement this behavior, I needed to be able to inspect a complete selector fragment, including
21625        what is before and after :hover/:active.
21626        To do that, I replaced the boolean isSubSelector by a pointer to the first selector of the fragment.
21627        When we need to match :active/:hover in quirks mode, we just go over all the selectors in the fragment
21628        to find one of the qualifying match type.
21629
21630        Tests: fast/selectors/active-hover-quirks.html
21631               fast/selectors/active-quirks.html
21632               fast/selectors/hover-quirks.html
21633
21634        * css/SelectorChecker.cpp:
21635        (WebCore::SelectorChecker::matchRecursively):
21636        (WebCore::canMatchHoverOrActiveInQuirksMode):
21637        (WebCore::SelectorChecker::checkOne):
21638        * css/SelectorChecker.h:
21639        (WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext):
21640
216412014-05-26  Zalan Bujtas  <zalan@apple.com>
21642
21643        Split the call to adjustForLocalZoom out into a separate expression.
21644        https://bugs.webkit.org/show_bug.cgi?id=133286
21645
21646        Reviewed by Darin Adler.
21647
21648        This patch ensures that adjustForLocalZoom() always gets called before we look at
21649        zoomFactor's value. (and not rely on the undefined behavior of the order of function argument evaluation)
21650
21651        * dom/Element.cpp:
21652        (WebCore::Element::offsetLeft):
21653        (WebCore::Element::offsetTop):
21654
216552014-05-26  Darin Adler  <darin@apple.com>
21656
21657        Class name matching should use ASCII case-insensitive matching, not Unicode case folding
21658        https://bugs.webkit.org/show_bug.cgi?id=133292
21659
21660        Reviewed by Anders Carlsson.
21661
21662        Tests: fast/dom/getElementsByClassName/ASCII-case-insensitive.html
21663               fast/dom/getElementsByClassName/case-sensitive.html
21664
21665        * dom/SpaceSplitString.cpp:
21666        (WebCore::hasNonASCIIOrUpper): Deleted.
21667        (WebCore::tokenizeSpaceSplitString): Use a for loop instead of while.
21668        (WebCore::spaceSplitStringTable): Renamed from sharedDataMap; the new name is supposed
21669        to help us see the analogy with the atomic string table.
21670        (WebCore::SpaceSplitString::set): Removed unneeded special case for null and preflight
21671        since AtomicString::convertToASCIILowercase now handles both of those. Changed to call
21672        convertToASCIILowercase instead of foldCase, since we don't want to fold non-ASCII.
21673        (WebCore::SpaceSplitString::spaceSplitStringContainsValue): Ditto.
21674        (WebCore::SpaceSplitStringData::create): Marked this inline since it's only called in
21675        one place and that place is in this file. Also used auto a bit and used get instead of
21676        find since the value type is a simple pointer.
21677        (WebCore::SpaceSplitStringData::destroy): Removed unneeded check for null. We never
21678        create any SpaceSplitStringData with empty strings, and a null is a kind of empty string.
21679
21680        * dom/SpaceSplitString.h: Removed some unneeded includes and some unneeded uses of the
21681        inline keyword. Changed types from size_t to unsigned in a couple places; we had a mix
21682        of the types and there was no reason to use size_t there.
21683
216842014-05-26  Javier Fernandez  <jfernandez@igalia.com>
21685
21686        [CSS Grid Layout] Implementation of the "grid" shorthand.
21687        https://bugs.webkit.org/show_bug.cgi?id=132122
21688
21689        Reviewed by Darin Adler.
21690
21691        The grid property is a shorthand that sets all of the explicit
21692        grid properties (grid-template-rows, grid-template-columns, and
21693        grid-template-areas) as well as all the implicit grid properties
21694        (grid-auto-rows, grid-auto-columns, and grid-auto-flow) in a
21695        single declaration
21696
21697        Notice that either explicit or implicit grid can be specified,
21698        assigning the initial values to the omitted properties.
21699
21700        Test: fast/css-grid-layout/grid-shorthand-get-set.html
21701
21702        * css/CSSComputedStyleDeclaration.cpp:
21703        (WebCore::ComputedStyleExtractor::propertyValue):
21704        * css/CSSParser.cpp:
21705        (WebCore::CSSParser::parseValue):
21706        (WebCore::CSSParser::parseGridShorthand):
21707        * css/CSSParser.h:
21708        * css/CSSPropertyNames.in:
21709        * css/StylePropertyShorthand.cpp:
21710        (WebCore::webkitGridShorthand):
21711        * css/StylePropertyShorthand.h:
21712
217132014-05-26  Zalan Bujtas  <zalan@apple.com>
21714
21715        Subpixel layout: Legacy Element.offset* client* return values are invalid in certain cases.
21716        https://bugs.webkit.org/show_bug.cgi?id=133272
21717
21718        Reviewed by Simon Fraser.
21719
21720        Element.offset* client* functions applied various rounding strategies on the return values before r168868.
21721        (for example, offsetLeft/Top either floored through implicit integer arithmetics or rounded explicitly depending
21722        whether the zoom scale was 1. see http://trac.webkit.org/changeset/168868/trunk/Source/WebCore/dom/Element.cpp for details)
21723        This patch mimics the legacy behavior by either rounding or flooring the return value.
21724
21725        Not testable (legacy switch is not exposed)
21726
21727        * dom/Element.cpp:
21728        (WebCore::adjustForLocalZoom):
21729        (WebCore::convertToNonSubpixelValueIfNeeded):
21730        (WebCore::Element::offsetLeft):
21731        (WebCore::Element::offsetTop):
21732
217332014-05-26  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
21734
21735        [EFL] Input fields and text areas are not rendered correctly after r167771
21736        https://bugs.webkit.org/show_bug.cgi?id=133181
21737
21738        Reviewed by Gyuyoung Kim.
21739
21740        r167771 changed arguments of RenderTheme two virtual method arguments which were not reflected
21741        in changes in derived classes, which caused parent method to be called. Arguments in derived class
21742        were updated, also 'override' specifiers were added to all virtual methods to prevent similar errors.
21743
21744        Already covered by fast/forms/textarea-placeholder-wrapping.html
21745
21746        * platform/efl/RenderThemeEfl.cpp:
21747        (WebCore::RenderThemeEfl::paintTextField):
21748        (WebCore::RenderThemeEfl::paintTextArea):
21749        * platform/efl/RenderThemeEfl.h:
21750        (WebCore::RenderThemeEfl::supportsHover):
21751        (WebCore::RenderThemeEfl::supportsControlTints):
21752
217532014-05-20  Sergio Villar Senin  <svillar@igalia.com>
21754
21755        [CSS Grid Layout] Children of grid containers must be turned into grid items
21756        https://bugs.webkit.org/show_bug.cgi?id=132991
21757
21758        Reviewed by Darin Adler.
21759
21760        From Blink r150472 by <jchaffraix@chromium.org>
21761
21762        According to specs each child of a grid container must become a
21763        grid item meaning that grid items are grid level boxes and thus,
21764        do not participate in the block formatting context but in the grid
21765        formatting one.
21766
21767        This change updates the grid items' 'display' property after style
21768        resolution so that we match the specification (see section 4. Grid
21769        Items). The spec basically instructs us to compute the value of
21770        'display' by applying the table in CSS2.1 Chapter 9.7
21771        http://www.w3.org/TR/CSS2/visuren.html#dis-pos-flo
21772
21773        Test: fast/css-grid-layout/grid-item-display.html
21774
21775        * css/StyleResolver.cpp:
21776        (WebCore::isDisplayGridBox):
21777        (WebCore::StyleResolver::adjustRenderStyle):
21778
217792014-05-26  Zan Dobersek  <zdobersek@igalia.com>
21780
21781        Remove Vector copies in ShorthandPropertyWrapper implementation and use
21782        https://bugs.webkit.org/show_bug.cgi?id=133265
21783
21784        Reviewed by Simon Fraser.
21785
21786        * page/animation/CSSPropertyAnimation.cpp:
21787        (WebCore::ShorthandPropertyWrapper::ShorthandPropertyWrapper): Move the passed-in Vector
21788        into the member variable instead of using Vector<>::swap().
21789        (WebCore::ShorthandPropertyWrapper::propertyWrappers): Return a const reference of the member
21790        variable instead of a const value.
21791        (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap): Move the Vector
21792        object into the ShorthandProperthyWrapper constructor.
21793        (WebCore::gatherEnclosingShorthandProperties): Deploy a range-based for-loop.
21794
217952014-05-26  Tanay C  <tanay.c@samsung.com>
21796
21797        [EFL] Fix build error in blob.cpp after r168435
21798        https://bugs.webkit.org/show_bug.cgi?id=132678
21799
21800        Reviewed by Alexey Proskuryakov.
21801
21802        * fileapi/Blob.cpp:
21803        (WebCore::Blob::size): Using isInBound to check range of local var
21804        actualsize to resolve build error
21805
218062014-05-25  Ryuan Choi  <ryuan.choi@samsung.com>
21807
21808        [EFL] Remove TileCairo and TiledBackingStoreBackendCairo
21809        https://bugs.webkit.org/show_bug.cgi?id=133274
21810
21811        Reviewed by Gyuyoung Kim.
21812
21813        Now, TiledBackingStore is only used for CoordinatedGraphics and the EFL port.
21814        CoordinatedGraphics does not use TileCairo and TiledBackingStoreBackendCairo.
21815
21816        This patch removed them and refactored related files.
21817
21818        * PlatformEfl.cmake:
21819        * PlatformGTK.cmake:
21820        * WebCore.vcxproj/WebCore.vcxproj:
21821        * WebCore.vcxproj/WebCore.vcxproj.filters:
21822        * platform/graphics/TiledBackingStore.cpp:
21823        (WebCore::TiledBackingStore::TiledBackingStore): Deleted.
21824        * platform/graphics/TiledBackingStore.h:
21825        * platform/graphics/TiledBackingStoreBackend.h:
21826        * platform/graphics/cairo/TileCairo.cpp: Removed.
21827        * platform/graphics/cairo/TiledBackingStoreBackendCairo.cpp: Removed.
21828
218292014-05-25  Jinwoo Song  <jinwoo7.song@samsung.com>
21830
21831        setData() of DataTransfer has a void return type
21832        https://bugs.webkit.org/show_bug.cgi?id=133108
21833
21834        Reviewed by Alexey Proskuryakov.
21835
21836        According to HTML5 spec, setData() of DataTranfer interface does not return value.
21837        http://www.w3.org/TR/html/editing.html#the-datatransfer-interface
21838
21839        Test: editing/pasteboard/set_data_typeof_return.html
21840
21841        * dom/DataTransfer.cpp:
21842        (WebCore::DataTransfer::setData):
21843        * dom/DataTransfer.h:
21844        * dom/DataTransfer.idl:
21845        * platform/Pasteboard.h:
21846        * platform/efl/PasteboardEfl.cpp:
21847        (WebCore::Pasteboard::writeString):
21848        * platform/gtk/PasteboardGtk.cpp:
21849        (WebCore::Pasteboard::writeString):
21850        * platform/ios/PasteboardIOS.mm:
21851        (WebCore::Pasteboard::writeString):
21852        * platform/mac/PasteboardMac.mm:
21853        (WebCore::Pasteboard::writeString):
21854        * platform/win/PasteboardWin.cpp:
21855        (WebCore::Pasteboard::writeString):
21856
218572014-05-25  Benjamin Poulain  <bpoulain@apple.com>
21858
21859        [iOS][WK2] Use ScrollView's scrollOffset as the unobscuredContentRect
21860        https://bugs.webkit.org/show_bug.cgi?id=133262
21861
21862        Reviewed by Simon Fraser.
21863
21864        Since VisibleContentRect was fixed, we were no longer sending scroll events when updating the scrollOffset
21865        when updating the visible content rects. The reason is that the scrollOffset was defined as the top left of the
21866        VisibleContentRect, and as such was already at the end position after updating the unobscured rect.
21867
21868        This patch split the unobscuredContentRect in unobscuredContentSize (updated live on zoom) and the position defined
21869        by the ScrollView's scrollOffset (updated when scrolling).
21870
21871        * WebCore.exp.in:
21872        * platform/ScrollView.h:
21873        * platform/ios/ScrollViewIOS.mm:
21874        (WebCore::ScrollView::unobscuredContentRect):
21875        (WebCore::ScrollView::setUnobscuredContentSize):
21876        (WebCore::ScrollView::setUnobscuredContentRect): Deleted.
21877
218782014-05-25  David Kilzer  <ddkilzer@apple.com>
21879
21880        Add type-checked casts for TransformOperations
21881        <http://webkit.org/b/133217>
21882
21883        Reviewed by Simon Fraser.
21884
21885        * platform/graphics/GraphicsLayer.cpp:
21886        (WebCore::GraphicsLayer::validateTransformOperations):
21887        * platform/graphics/ca/GraphicsLayerCA.cpp:
21888        (WebCore::getTransformFunctionValue):
21889        - Switch to type-checked casts.
21890
21891        * platform/graphics/transforms/IdentityTransformOperation.h:
21892        * platform/graphics/transforms/Matrix3DTransformOperation.h:
21893        * platform/graphics/transforms/MatrixTransformOperation.h:
21894        * platform/graphics/transforms/PerspectiveTransformOperation.h:
21895        * platform/graphics/transforms/RotateTransformOperation.h:
21896        * platform/graphics/transforms/ScaleTransformOperation.h:
21897        * platform/graphics/transforms/SkewTransformOperation.h:
21898        * platform/graphics/transforms/TranslateTransformOperation.h:
21899        - Add 'final' to class declaration.
21900        - Add 'override' to overridden methods.
21901        - Add type-checked cast via TRANSFORMOPERATION_TYPE_CASTS macro.
21902        - Move implementation of operator==(const TransformOperation&)
21903          from header to source file so it is able to use a type-checked
21904          cast, and switch back to using a reference instead of a
21905          pointer.
21906        - Add or update ASSERT in private constructor to check for
21907          correct OperationType in classes that represent multiple
21908          types.
21909
21910        * platform/graphics/transforms/Matrix3DTransformOperation.cpp:
21911        (WebCore::Matrix3DTransformOperation::operator==): Added.
21912
21913        * platform/graphics/transforms/MatrixTransformOperation.cpp:
21914        (WebCore::Matrix3DTransformOperation::operator==): Added.
21915        (WebCore::MatrixTransformOperation::blend):
21916        - Switch to type-checked casts and use a reference.
21917
21918        * platform/graphics/transforms/PerspectiveTransformOperation.cpp:
21919        (WebCore::Matrix3DTransformOperation::operator==): Added.
21920        (WebCore::PerspectiveTransformOperation::blend):
21921        * platform/graphics/transforms/RotateTransformOperation.cpp:
21922        (WebCore::Matrix3DTransformOperation::operator==): Added.
21923        (WebCore::RotateTransformOperation::blend):
21924        * platform/graphics/transforms/ScaleTransformOperation.cpp:
21925        (WebCore::Matrix3DTransformOperation::operator==): Added.
21926        (WebCore::ScaleTransformOperation::blend):
21927        * platform/graphics/transforms/SkewTransformOperation.cpp:
21928        (WebCore::Matrix3DTransformOperation::operator==): Added.
21929        (WebCore::SkewTransformOperation::blend):
21930        * platform/graphics/transforms/TranslateTransformOperation.cpp:
21931        (WebCore::Matrix3DTransformOperation::operator==): Added.
21932        (WebCore::TranslateTransformOperation::blend):
21933        - Switch to type-checked casts.
21934
21935        * platform/graphics/transforms/TransformOperation.h:
21936        (WebCore::TransformOperation::isRotateTransformOperationType):
21937        (WebCore::TransformOperation::isScaleTransformOperationType):
21938        (WebCore::TransformOperation::isSkewTransformOperationType):
21939        (WebCore::TransformOperation::isTranslateTransformOperationType):
21940        - Add type-checking methods used in constructors and type-checked
21941          casts.
21942        - Define TRANSFORMOPERATION_TYPE_CASTS macro used by subclasses.
21943
219442014-05-25  David Kilzer  <ddkilzer@apple.com>
21945
21946        Crash in WebCore::TextResourceDecoder::checkForCSSCharset
21947        <http://webkit.org/b/133257>
21948        <rdar://problem/17027109>
21949
21950        Reviewed by Alexey Proskuryakov.
21951
21952        Test: fast/encoding/css-charset-missing-semi-colon-and-newline.html
21953
21954        * loader/TextResourceDecoder.cpp:
21955        (WebCore::TextResourceDecoder::checkForCSSCharset): Add early
21956        return.
21957
219582014-05-24  Eric Carlson  <eric.carlson@apple.com>
21959
21960        [Mac] preload AVAssetTrack properties before asking for them
21961        https://bugs.webkit.org/show_bug.cgi?id=133240
21962
21963        Reviewed by Jer Noble.
21964
21965        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
21966        (WebCore::assetTrackMetadataKeyNames): Add preferredTransform and naturalSize to the list
21967            of properties we preload.
21968
219692014-05-24  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
21970
21971        Remove one of the CSSProperty constructor
21972        https://bugs.webkit.org/show_bug.cgi?id=131094
21973
21974        Reviewed by Darin Adler.
21975
21976        Remove one of the CSSProperty constructor, because it is obsolete.
21977
21978        * css/CSSProperty.h:
21979        (WebCore::CSSProperty::CSSProperty): Deleted.
21980        * css/StyleProperties.h:
21981        (WebCore::StyleProperties::PropertyReference::toCSSProperty):
21982
219832014-05-23  Simon Fraser  <simon.fraser@apple.com>
21984
21985        Rename ScrollingTreeScrollingNode's m_scrollPosition to make it clear that it's the value committed from the state tree
21986        https://bugs.webkit.org/show_bug.cgi?id=133254
21987
21988        Reviewed by Tim Horton.
21989
21990        Make ScrollingTreeScrollingNode::scrollPosition() pure virtual, and rename
21991        the member variable and associated getter to make it clear that they relate
21992        to the last committed scroll position.
21993
21994        * page/scrolling/ScrollingTreeScrollingNode.cpp:
21995        (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
21996        * page/scrolling/ScrollingTreeScrollingNode.h:
21997        (WebCore::ScrollingTreeScrollingNode::lastCommittedScrollPosition):
21998        (WebCore::ScrollingTreeScrollingNode::scrollPosition): Deleted.
21999
220002014-05-23  Simon Fraser  <simon.fraser@apple.com>
22001
22002        Share some more ScrollingTreeScrollingNode code
22003        https://bugs.webkit.org/show_bug.cgi?id=133248
22004
22005        Reviewed by Sam Weinig.
22006
22007        Push scrollBy(), scrollByWithoutContentEdgeConstraints() and setScrollPosition()
22008        down to ScrollingTreeFrameScrollingNode.
22009        
22010        This requires that scrollPosition() return the right thing for each class, so make
22011        it virtual. Future patches will reduce the confusion between the committed scroll
22012        position and the one derived from layers.
22013
22014        * page/scrolling/ScrollingTreeFrameScrollingNode.cpp:
22015        (WebCore::ScrollingTreeFrameScrollingNode::scrollBy):
22016        (WebCore::ScrollingTreeFrameScrollingNode::scrollByWithoutContentEdgeConstraints):
22017        (WebCore::ScrollingTreeFrameScrollingNode::setScrollPosition):
22018        * page/scrolling/ScrollingTreeFrameScrollingNode.h:
22019        * page/scrolling/ScrollingTreeScrollingNode.h:
22020        (WebCore::ScrollingTreeScrollingNode::scrollPosition):
22021        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.h:
22022        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm:
22023        (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollPosition): Deleted.
22024        (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollBy): Deleted.
22025        (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollByWithoutContentEdgeConstraints): Deleted.
22026        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h:
22027        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
22028        (WebCore::ScrollingTreeFrameScrollingNodeMac::updateBeforeChildren):
22029        (WebCore::ScrollingTreeFrameScrollingNodeMac::immediateScrollBy):
22030        (WebCore::ScrollingTreeFrameScrollingNodeMac::immediateScrollByWithoutContentEdgeConstraints):
22031        (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollPosition):
22032        (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPosition):
22033        (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollBy): Deleted.
22034        (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollByWithoutContentEdgeConstraints): Deleted.
22035
220362014-05-24  Chris Fleizach  <cfleizach@apple.com>
22037
22038        AX: fix coordinate mapping for iOS accessibility
22039        https://bugs.webkit.org/show_bug.cgi?id=133188
22040
22041        Reviewed by Sam Weinig.
22042
22043        Make WebCore aware of the accessibility point/rect conversion methods.
22044
22045        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
22046        (-[WebAccessibilityObjectWrapper convertPointToScreenSpace:]):
22047        (-[WebAccessibilityObjectWrapper convertRectToScreenSpace:]):
22048        * loader/EmptyClients.h:
22049        * page/Chrome.cpp:
22050        (WebCore::Chrome::accessibilityScreenToRootView):
22051        (WebCore::Chrome::rootViewToAccessibilityScreen):
22052        * page/Chrome.h:
22053        * page/ChromeClient.h:
22054        * platform/HostWindow.h:
22055
220562014-05-24  Zalan Bujtas  <zalan@apple.com>
22057
22058        Subpixel rendering: Non-compositing transforms with subpixel coordinates paint to wrong position.
22059        https://bugs.webkit.org/show_bug.cgi?id=133184
22060        <rdar://problem/16745606>
22061
22062        Reviewed by Simon Fraser.
22063
22064        Snapping relative negative coordinate values should produce the same position as if they were
22065        positive absolute coordinates.
22066        When a child box gets positioned off of its containers towards top/left, its relative coordinates
22067        become negative. Pixel snapping those negative values should produce the same
22068        final painting position as if the child box was fixed positioned with positive coordinates.
22069        Since halfway values always round away from zero, negative and positive halfway values
22070        produce opposite rounding direction.
22071        This patch ensures that negative halfway values round to the direction as if they were positive.  
22072
22073        Test: fast/layers/hidpi-floor-negative-coordinate-values-to-maintain-rounding-direction.html
22074
22075        * platform/LayoutUnit.h:
22076        (WebCore::roundToDevicePixel):
22077        * rendering/RenderLayer.cpp:
22078        (WebCore::RenderLayer::paintLayerByApplyingTransform):
22079
220802014-05-24  Frédéric Wang  <fred.wang@free.fr>
22081
22082        Use size variants and glyph assembly from the MATH data.
22083        https://bugs.webkit.org/show_bug.cgi?id=130322
22084
22085        Reviewed by Chris Fleizach.
22086
22087        This patch modifies the RenderMathMLOperator code to use the MATH table
22088        when one is provided in the current font on the <math> tag. More
22089        precisely, the MathVariants table is used to draw a size variant or
22090        a glyph assembly. The displaystyle attribute is not supported yet, so
22091        for now large operators are always assumed to be in display style. The
22092        MATH support does not work well with all platforms+fonts, so at the
22093        moment the default font-family on the <math> is not changed.
22094
22095        Tests: mathml/opentype/large-operators-LatinModern.html
22096               mathml/opentype/opentype-stretchy.html
22097               mathml/opentype/vertical-LatinModern.html
22098
22099        * css/mathml.css: We only specify the default font-family on the math root, so that people can easily style the mathematics.
22100        For now, old fonts without the MATH table are still used as the default.
22101        (math):
22102        (math, mfenced > *): Deleted.
22103        (mo, mfenced): Deleted.
22104        * platform/graphics/SimpleFontData.cpp: don't return the math data if the font is loading.
22105        (WebCore::SimpleFontData::mathData):
22106        * platform/graphics/opentype/OpenTypeMathData.cpp: update #ifdef so that disabling ENABLE_OPENTYPE_MATH won't lead to errors with unused parameters.
22107        (WebCore::OpenTypeMathData::OpenTypeMathData):
22108        (WebCore::OpenTypeMathData::getMathConstant):
22109        (WebCore::OpenTypeMathData::getItalicCorrection):
22110        (WebCore::OpenTypeMathData::getMathVariants):
22111        * rendering/mathml/RenderMathMLOperator.cpp:
22112        (WebCore::RenderMathMLOperator::boundsForGlyph):
22113        (WebCore::RenderMathMLOperator::heightForGlyph):
22114        (WebCore::RenderMathMLOperator::advanceForGlyph):
22115        (WebCore::RenderMathMLOperator::computePreferredLogicalWidths): We handle preferred width of size variants.
22116        (WebCore::RenderMathMLOperator::shouldAllowStretching): This function now only returns whether the operator will stretch and no longer has side effect.
22117        (WebCore::RenderMathMLOperator::getGlyphAssemblyFallBack): We add a function to convert from the MathVariant table data to the format supported by RenderMathMLOperator.
22118        (WebCore::RenderMathMLOperator::getDisplayStyleLargeOperator): We add a function to get the glyph that will be used for large operators in display style.
22119        (WebCore::RenderMathMLOperator::findStretchyData): We make this function handle size variants.
22120        (WebCore::RenderMathMLOperator::updateStyle): We handle size variants.
22121        (WebCore::RenderMathMLOperator::paint): We handle size variants.
22122        * rendering/mathml/RenderMathMLOperator.h:
22123
221242014-05-23  Tim Horton  <timothy_horton@apple.com>
22125
22126        REGRESSION (iOS WebKit2): requestAnimationFrame fires more than once between layer tree commits
22127        https://bugs.webkit.org/show_bug.cgi?id=132794
22128        <rdar://problem/16877909>
22129
22130        Reviewed by Simon Fraser.
22131
22132        Virtualize DisplayRefreshMonitor so that WebKit2 can implement its own DisplayRefreshMonitor for UI-side compositing views.
22133        This allows the synchronization of requestAnimationFrame callbacks with UI-side compositing painting.
22134
22135        * WebCore.exp.in:
22136        * WebCore.xcodeproj/project.pbxproj:
22137        
22138        * page/ChromeClient.h:
22139        (WebCore::ChromeClient::graphicsLayerFactory):
22140        (WebCore::ChromeClient::createDisplayRefreshMonitor):
22141        * platform/graphics/DisplayRefreshMonitorFactory.h: Added.
22142        * platform/graphics/GraphicsLayerUpdater.cpp:
22143        (WebCore::GraphicsLayerUpdater::createDisplayRefreshMonitor):
22144        * platform/graphics/GraphicsLayerUpdater.h:
22145        * rendering/RenderLayerCompositor.cpp:
22146        (WebCore::RenderLayerCompositor::createDisplayRefreshMonitor):
22147        * rendering/RenderLayerCompositor.h:
22148        Give the ChromeClient a chance to provide us with a custom DisplayRefreshMonitor.
22149        If it does not, we'll fall back to making a DisplayRefreshMonitorMac or
22150        DisplayRefreshMonitorIOS depending on the platform.
22151
22152        * dom/ScriptedAnimationController.cpp:
22153        * dom/ScriptedAnimationController.h:
22154        * platform/graphics/DisplayRefreshMonitor.cpp:
22155        * platform/graphics/DisplayRefreshMonitor.h:
22156        * platform/graphics/DisplayRefreshMonitorClient.cpp: Added.
22157        * platform/graphics/DisplayRefreshMonitorClient.h: Added.
22158        * platform/graphics/DisplayRefreshMonitorManager.cpp: Added.
22159        * platform/graphics/DisplayRefreshMonitorManager.h: Added.
22160        Split DisplayRefreshMonitor.cpp into one file per class.
22161        Use references in a few places.
22162        Remove some useless comments.
22163
22164        * platform/graphics/DisplayRefreshMonitor.cpp:
22165        (WebCore::DisplayRefreshMonitor::displayDidRefresh):
22166        Use takeAny() and remove a FIXME about it not existing.
22167
22168        * platform/graphics/DisplayRefreshMonitorClient.cpp: Added.
22169        (WebCore::DisplayRefreshMonitorClient::fireDisplayRefreshIfNeeded):
22170        Use an early return instead of having the whole function body in an if().
22171
22172        * platform/graphics/ios/DisplayRefreshMonitorIOS.h: Added.
22173        * platform/graphics/ios/DisplayRefreshMonitorIOS.mm:
22174        * platform/graphics/mac/DisplayRefreshMonitorMac.cpp:
22175        * platform/graphics/mac/DisplayRefreshMonitorMac.h: Added.
22176        Virtualize DisplayRefreshMonitorIOS and DisplayRefreshMonitorMac,
22177        and move things specific to each of them out of DisplayRefreshMonitor itself.
22178
221792014-05-23  Yusuke Suzuki  <utatane.tea@gmail.com>
22180
22181        CSS JIT: Apply backtracking optimization to adjacent backtracking
22182        https://bugs.webkit.org/show_bug.cgi?id=132951
22183
22184        Reviewed by Benjamin Poulain.
22185
22186        Apply the backtracking optimization to the adjacent backtracking.
22187        This optimization is already done for the descendant backtracking.
22188        We apply this to the adjacent backtracking similarly.
22189
22190        Test: fast/selectors/backtracking-adjacent-optimized.html
22191
22192        * cssjit/SelectorCompiler.cpp:
22193        (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
22194        (WebCore::SelectorCompiler::solveAdjacentBacktrackingActionForDirectAdjacent):
22195        (WebCore::SelectorCompiler::solveBacktrackingAction):
22196        (WebCore::SelectorCompiler::computeBacktrackingStartOffsetInChain):
22197        (WebCore::SelectorCompiler::computeBacktrackingHeightFromDescendant):
22198        (WebCore::SelectorCompiler::computeBacktrackingWidthFromIndirectAdjacent):
22199        (WebCore::SelectorCompiler::SelectorCodeGenerator::computeBacktrackingInformation):
22200        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateIndirectAdjacentTreeWalker):
22201        (WebCore::SelectorCompiler::SelectorCodeGenerator::linkFailures):
22202        (WebCore::SelectorCompiler::computeBacktrackingStartHeightFromDescendant): Deleted.
22203
222042014-05-23  Alex Christensen  <achristensen@webkit.org>
22205
22206        Make CSS JIT run on ARM64.
22207        https://bugs.webkit.org/show_bug.cgi?id=133156
22208
22209        Reviewed by Benjamin Poulain.
22210
22211        * cssjit/FunctionCall.h:
22212        (WebCore::FunctionCall::saveAllocatedRegisters):
22213        (WebCore::FunctionCall::restoreAllocatedRegisters):
22214        Use StackAllocator's new push and pop functions to push and pop a vector instead of iterating it.
22215        * cssjit/RegisterAllocator.h:
22216        (WebCore::RegisterAllocator::reserveCalleeSavedRegisters):
22217        (WebCore::RegisterAllocator::restoreCalleeSavedRegisters):
22218        Return a vector of registers to allocate instead of doing the allocation to make the RegisterAllocator
22219        not need to know about the StackAllocator and to use the new vector push and pop functions.
22220        (WebCore::RegisterAllocator::~RegisterAllocator):
22221        Store RegisterIDs instead of StackReferences to avoid needing to know about the stack.
22222        * cssjit/SelectorCompiler.cpp:
22223        (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
22224        Removed the requirement for assert to be disabled to print disassembly when debugging css jit.
22225        (WebCore::SelectorCompiler::SelectorCodeGenerator::generatePrologue):
22226        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateEpilogue):
22227        Added to correctly push the link register and frame pointer.
22228        This is required if the jit code calls a function on arm64 and helpful for debugging tools on x86_64.
22229        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
22230        Generate the prologue and epilogue which respectively push and pop
22231        the link register, frame pointer, and callee saved registers if needed.
22232        * cssjit/StackAllocator.h:
22233        (WebCore::StackAllocator::push):
22234        (WebCore::StackAllocator::pop):
22235        Added new vector push and pop functions to use stp and ldb instructions on arm64.
22236
222372014-05-23  Jeremy Jones  <jeremyj@apple.com>
22238
22239        Hide fullscreen immediately when switching tabs.
22240        https://bugs.webkit.org/show_bug.cgi?id=133239
22241
22242        Reviewed by Eric Carlson.
22243
22244        This change allows fullscreen to disappear immediately while still cleaning
22245        up fullscreen normally.
22246
22247        * WebCore.exp.in:
22248        * platform/ios/WebVideoFullscreenControllerAVKit.h:
22249        renamed function to requestHideAndExitFullscreen
22250
22251        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
22252        renamed function to requestHideAndExitFullscreen
22253
22254        (-[WebVideoFullscreenController requestHideAndExitFullscreen]):
22255        rename of requestExitFullscreen that also hides.
22256
22257        (-[WebVideoFullscreenController requestExitFullscreen]): Deleted.
22258        * platform/ios/WebVideoFullscreenInterfaceAVKit.h: declare requestHideAndExitFullscreen()
22259        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
22260        (WebVideoFullscreenInterfaceAVKit::requestHideAndExitFullscreen):
22261        this hides the window before requesting exitfullscreen from the model.
22262
222632014-05-23  Tim Horton  <timothy_horton@apple.com>
22264
22265        [iOS] WKPDFView should have a page indicator
22266        https://bugs.webkit.org/show_bug.cgi?id=133109
22267        <rdar://problem/16383003>
22268
22269        Reviewed by Anders Carlsson.
22270
22271        * English.lproj/Localizable.strings:
22272
222732014-05-23  Enrica Casucci  <enrica@apple.com>
22274
22275        Remove invalid ASSERT in wordRangeForPosition.
22276        https://bugs.webkit.org/show_bug.cgi?id=133232
22277
22278        Reviewed by Ryosuke Niwa.
22279
22280        In WK2 for iOS this function is called on every selection change.
22281        The selection could be set by Javascript in an element that is not visible.
22282        In that case we won't be able to create a VisiblePosition therefore wordRangeForPosition
22283        should not ASSERT that the VisiblePosition is not null, but rather
22284        perform an early return if it is null.
22285
22286        * editing/VisibleUnits.cpp:
22287        (WebCore::wordRangeFromPosition):
22288
222892014-05-23  Manuel Rego Casasnovas  <rego@igalia.com>
22290
22291        [CSS Grid Layout] Use gridRowCount() and gridColumnCount() when possible
22292        https://bugs.webkit.org/show_bug.cgi?id=133213
22293
22294        Reviewed by Sergio Villar Senin.
22295
22296        Use gridRowCount() and gridColumnCount() instead of m_grid.size() and
22297        m_grid[0].size() to make the code more descriptive and easier to
22298        understand.
22299
22300        No new tests (No change in behavior).
22301
22302        * rendering/RenderGrid.cpp:
22303        (WebCore::RenderGrid::growGrid):
22304        (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid):
22305
223062014-05-23  Alexey Proskuryakov  <ap@apple.com>
22307
22308        REGRESSION (r153917): Chart for the Category Explorer within Quicken Essentials
22309        does not draw until you force a redraw
22310        https://bugs.webkit.org/show_bug.cgi?id=133228
22311        <rdar://problem/15221231>
22312
22313        Reviewed by Simon Fraser.
22314
22315        * platform/RuntimeApplicationChecks.cpp: (WebCore::applicationIsQuickenEssentials):
22316        * platform/RuntimeApplicationChecks.h:
22317        Added a check for Quicken Essentials.
22318
22319        * platform/mac/WidgetMac.mm: (WebCore::Widget::paint): Don't do an early return
22320        for Quicken Essentials, it depends on drawing to update its layer.
22321
223222014-05-23  Mihnea Ovidenie  <mihnea@adobe.com>
22323
22324        REGRESSION(r169105): fast/regions/cssom/region-range-for-box-crash.html is more crashy than before
22325        https://bugs.webkit.org/show_bug.cgi?id=133124
22326
22327        Reviewed by David Hyatt.
22328
22329        When adjusting the end points of a subtree selection in the case of a document
22330        with named flows, we have to make sure that we pass the computed end
22331        points to the visible selection algorithm only if the end points are
22332        part of the same subtree, otherwise assume a selection clear behavior.
22333
22334        The test fast/regions/cssom/region-range-for-box-crash.html is used to
22335        test this behavior.
22336
22337        * rendering/SelectionSubtreeRoot.cpp:
22338        (WebCore::SelectionSubtreeRoot::adjustForVisibleSelection):
22339        (WebCore::SelectionSubtreeRoot::selectionStartEndPositions): Moved to header file.
22340        * rendering/SelectionSubtreeRoot.h:
22341        (WebCore::SelectionSubtreeRoot::selectionStartEndPositions):
22342
223432014-05-23  Jeremy Jones  <jeremyj@apple.com>
22344
22345        reset m_havePreparedToPlay when changing media engines.
22346        https://bugs.webkit.org/show_bug.cgi?id=133199
22347
22348        Reviewed by Eric Carlson.
22349
22350        If a play request comes in before the media player is created, m_havePreparedToPlay
22351        is set to true. But when the player is created, this prevents the new player from
22352        getting the prepare call.
22353
22354        * html/HTMLMediaElement.cpp:
22355        (WebCore::HTMLMediaElement::mediaPlayerEngineUpdated): set m_havePreparedToPlay false.
22356
223572014-05-23  Oliver Hunt  <oliver@apple.com>
22358
22359        Navigator object needs to have properties directly on the instance object
22360        https://bugs.webkit.org/show_bug.cgi?id=133221
22361
22362        Reviewed by Mark Lam.
22363
22364        Flag the Navigator object as requiring properties to be on the instance
22365        as there were a few compatibility issues when on the prototype.
22366
22367        * bindings/scripts/CodeGeneratorJS.pm:
22368        (InterfaceRequiresAttributesOnInstance):
22369
223702014-05-23  Simon Fraser  <simon.fraser@apple.com>
22371
22372        Switch CSSGradientValue to use more references
22373        https://bugs.webkit.org/show_bug.cgi?id=133206
22374
22375        Reviewed by Andreas Kling.
22376
22377        Switch from pointers to references in various places.
22378
22379        * css/CSSGradientValue.cpp:
22380        (WebCore::CSSGradientValue::image):
22381        (WebCore::CSSGradientValue::addStops):
22382        (WebCore::positionFromValue):
22383        (WebCore::CSSGradientValue::computeEndPoint):
22384        (WebCore::CSSLinearGradientValue::createGradient):
22385        (WebCore::CSSRadialGradientValue::resolveRadius):
22386        (WebCore::CSSRadialGradientValue::createGradient):
22387        * css/CSSGradientValue.h:
22388
223892014-05-23  Zalan Bujtas  <zalan@apple.com>
22390
22391        Subpixel rendering: Make webkit-box-shadow painting subpixel aware.
22392        https://bugs.webkit.org/show_bug.cgi?id=133201
22393        <rdar://problem/16072830>
22394
22395        Reviewed by Simon Fraser.
22396
22397        This patch enables webkit-box-shadow to be painted on a subpixel position. However, we
22398        still truncate -webkit-box-shadow property values. Tracked here: http://webkit.org/b/133202
22399
22400        Test: fast/box-shadow/hidpi-webkit-box-shadow-subpixel-position.html
22401
22402        * platform/graphics/FloatRoundedRect.cpp:
22403        (WebCore::FloatRoundedRect::inflateWithRadii): same as in from RoundedRect.
22404        (WebCore::FloatRoundedRect::adjustRadii): same as in from RoundedRect.
22405        * platform/graphics/FloatRoundedRect.h:
22406        * rendering/RenderBoxModelObject.cpp:
22407        (WebCore::RenderBoxModelObject::paintBoxShadow):
22408
224092014-05-22  peavo@outlook.com  <peavo@outlook.com>
22410
22411        [Curl] Crash when exceeding maximum cache limit.
22412        https://bugs.webkit.org/show_bug.cgi?id=133185
22413
22414        Reviewed by Brent Fulgham.
22415
22416        When the maximum cache limit is exceeded, I get a crash.
22417        This happens when deleting cache entries, because a reference to the url string object in the LRU list
22418        is used as a parameter to invalidateCacheEntry(), when called from makeRoomForNewEntry().
22419        When the string is removed from the LRU list in makeRoomForNewEntry(), the string is deleted.
22420        Next, the string is accessed again to remove the url from the index, and we crash.
22421
22422        This can be fixed by removing the string from the LRU list after it is removed from the index.
22423
22424        Fixing the crash also revealed an infinite loop problem.
22425        If the url for some reason only exist in the LRU list, and not in the index,
22426        we will inifitely loop in makeRoomForNewEntry(), trying to remove this url from the cache, but never succeeding.
22427        This can be fixed by removing the url from the LRU list, also when it's not in the index.
22428
22429        * platform/network/curl/CurlCacheManager.cpp:
22430        (WebCore::CurlCacheManager::makeRoomForNewEntry): Avoid infinite loop by checking if there are more cache entries to remove.
22431        (WebCore::CurlCacheManager::invalidateCacheEntry): Avoid crash and infinite loop by removing url from LRU list last.
22432
224332014-05-22  Simon Fraser  <simon.fraser@apple.com>
22434
22435        Make viewport units work in CSS gradients
22436        https://bugs.webkit.org/show_bug.cgi?id=133204
22437        <rdar://problem/17012259>
22438        
22439        Reviewed by Tim Horton.
22440        
22441        Make viewport percentage lengths work in gradients.
22442
22443        Test: fast/gradients/viewport-units-gradient.html
22444
22445        * css/CSSGradientValue.cpp:
22446        (WebCore::CSSGradientValue::addStops):
22447        (WebCore::CSSLinearGradientValue::createGradient):
22448        (WebCore::CSSRadialGradientValue::createGradient):
22449        * css/CSSGradientValue.h:
22450
224512014-05-22  Benjamin Poulain  <bpoulain@apple.com>
22452
22453        [iOS][WK2] Add support for minimal-ui viewports
22454        https://bugs.webkit.org/show_bug.cgi?id=133162
22455
22456        Reviewed by Simon Fraser.
22457
22458        Add support for minimal-ui directly into the Viewport configuration.
22459
22460        ViewportConfiguration knows about two kinds of layout size in scrollview coordinates:
22461        -normal size
22462        -minimal ui size.
22463
22464        Initially, the page is initialized with resetMinimalUI() and starts with a normal layout.
22465
22466        At any time before the main resource is loaded, the Web page can update its viewport meta tag
22467        to include minimal-ui. The viewport configuration is updated immediately to reflect the minimal-ui
22468        layout size. Any layout after that takes minimal-ui into account.
22469
22470        * WebCore.exp.in:
22471        * css/LengthFunctions.cpp:
22472        (WebCore::minimumValueForLength):
22473        (WebCore::floatValueForLength):
22474        * css/StyleResolver.cpp:
22475        (WebCore::StyleResolver::viewportPercentageValue):
22476        * dom/ViewportArguments.h:
22477        (WebCore::ViewportArguments::operator==):
22478        * page/FrameView.cpp:
22479        (WebCore::FrameView::setViewportSizeForCSSViewportUnits):
22480        (WebCore::FrameView::viewportSizeForCSSViewportUnits):
22481        (WebCore::FrameView::setViewportSize): Deleted.
22482        (WebCore::FrameView::viewportSize): Deleted.
22483        * page/FrameView.h:
22484        * page/ViewportConfiguration.cpp:
22485        (WebCore::ViewportConfiguration::ViewportConfiguration):
22486        (WebCore::ViewportConfiguration::setMinimumLayoutSize):
22487        (WebCore::ViewportConfiguration::setMinimumLayoutSizeForMinimalUI):
22488        (WebCore::ViewportConfiguration::activeMinimumLayoutSizeInScrollViewCoordinates):
22489        (WebCore::ViewportConfiguration::resetMinimalUI):
22490        (WebCore::ViewportConfiguration::pageWillRenderFirstFrame):
22491        (WebCore::ViewportConfiguration::initialScale):
22492        (WebCore::ViewportConfiguration::minimumScale):
22493        (WebCore::ViewportConfiguration::updateConfiguration):
22494        (WebCore::ViewportConfiguration::layoutWidth):
22495        (WebCore::ViewportConfiguration::layoutHeight):
22496        (WebCore::ViewportConfiguration::description):
22497        * page/ViewportConfiguration.h:
22498        (WebCore::ViewportConfiguration::minimumLayoutSizeForMinimalUI):
22499        (WebCore::ViewportConfiguration::usesMinimalUI):
22500        * rendering/RenderView.cpp:
22501        (WebCore::RenderView::viewportSizeForCSSViewportUnits):
22502        (WebCore::RenderView::viewportSize): Deleted.
22503        * rendering/RenderView.h:
22504
225052014-05-22  Ryosuke Niwa  <rniwa@webkit.org>
22506
22507        Can't type in status in facebook.com on iOS Safari because keyboard disappears
22508        https://bugs.webkit.org/show_bug.cgi?id=133196
22509
22510        Reviewed by Geoffrey Garen.
22511
22512        Fixed the bug by rolling out r156252.
22513
22514        When the user taps on the status on facebook.com, the page focuses a textarea,
22515        which is then made momentarily invisible by setting display:none.
22516        The page then removes display:none later and expects the textarea to be still focused.
22517
22518        With r156252, the focus is removed after the page sets display:none and the keyboard disappears.
22519        Since the focus is never reset on the textarea, the user can never type in anything.
22520
22521        The specification may need to change here given that this (rather odd) behavior/expectation exists
22522        on one of the most popular websites on the Web.
22523
22524        * dom/Document.cpp:
22525        (WebCore::Document::Document):
22526        (WebCore::Document::recalcStyle):
22527        (WebCore::Document::updateLayout):
22528        (WebCore::Document::resetHiddenFocusElementSoon): Deleted.
22529        (WebCore::Document::resetHiddenFocusElementTimer): Deleted.
22530        * dom/Document.h:
22531
225322014-05-22  Myles C. Maxfield  <mmaxfield@apple.com>
22533
22534        http/tests/security/xss-DENIED-xsl-document-redirect.xml fails with NetworkProcess
22535        https://bugs.webkit.org/show_bug.cgi?id=132523
22536
22537        Reviewed by Alexey Proskuryakov.
22538
22539        We should not manufacture a response in the event of an error during a
22540        synchronous XHR. In addition, this test removes two places that are
22541        sensitive to such a manufactured response.
22542
22543        Updates test expectations.
22544
22545        * loader/DocumentThreadableLoader.cpp:
22546        (WebCore::DocumentThreadableLoader::loadRequest): Don't inspect a
22547        loader response if there is an error
22548        * platform/network/cf/ResourceHandleCFNet.cpp:
22549        (WebCore::ResourceHandle::platformLoadResourceSynchronously): Do not
22550        manufacture a response
22551        * platform/network/mac/ResourceHandleMac.mm:
22552        (WebCore::ResourceHandle::platformLoadResourceSynchronously): Do not
22553        manufacture a response
22554        * xml/XSLTProcessorLibxslt.cpp:
22555        (WebCore::docLoaderFunc): Only use the response's URL if no error
22556        occurred.
22557
225582014-05-22  Myles C. Maxfield  <litherum@gmail.com>
22559
22560        Unreviewed typo fix.
22561
22562        Reviewed by NOBODY.
22563
22564        No new tests.
22565
22566        * platform/graphics/mac/FontMac.mm:
22567        (WebCore::Font::dashesForIntersectionsWithRect): Accidentally said run.length() instead of glyphBuffer.size().
22568
225692014-05-22  Andreas Kling  <akling@apple.com>
22570
22571        [iOS WebKit2] Web process should try to shrink its memory footprint when going into background.
22572        <https://webkit.org/b/133197>
22573        <rdar://problem/17011561>
22574
22575        Make releaseMemory() public so we can call it from the process-will-suspend callback.
22576
22577        Reviewed by Gavin Barraclough.
22578
22579        * WebCore.exp.in:
22580        * platform/MemoryPressureHandler.h:
22581
225822014-05-22  Andreas Kling  <akling@apple.com>
22583
22584        Hook up a setting for showing detailed logging during memory pressure relief.
22585        <https://webkit.org/b/133194>
22586
22587        Make the pressure relief logger opt-in. Also make it flush memory back to the
22588        OS (for both malloc and FastMalloc) to get more accurate numbers at each step.
22589
22590        Reviewed by Gavin Barraclough.
22591
22592        * WebCore.exp.in:
22593        * platform/MemoryPressureHandler.cpp:
22594        * platform/MemoryPressureHandler.h:
22595        (WebCore::MemoryPressureHandler::ReliefLogger::ReliefLogger):
22596        (WebCore::MemoryPressureHandler::ReliefLogger::~ReliefLogger):
22597        (WebCore::MemoryPressureHandler::ReliefLogger::setLoggingEnabled):
22598        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
22599        (WebCore::MemoryPressureHandler::ReliefLogger::platformMemoryUsage):
22600
226012014-05-22  Brady Eidson  <beidson@apple.com>
22602
22603        Don't scan for phone numbers in editable regions
22604        <rdar://problem/16949846> and https://bugs.webkit.org/show_bug.cgi?id=133192
22605
22606        Reviewed by Enrica Casucci.
22607
22608        No new tests (Currently untested WK2-only feature)
22609
22610        * editing/Editor.cpp:
22611        (WebCore::Editor::scanRangeForTelephoneNumbers): Skip the range if the Node is editable.
22612
226132014-05-22  Jeremy Jones  <jeremyj@apple.com>
22614
22615        Captions layout incorrectly in fullscreen.
22616        https://bugs.webkit.org/show_bug.cgi?id=133175
22617
22618        Reviewed by Eric Carlson.
22619
22620        When doing layout for fullscreen, geometry should be absolute so it is not influenced
22621        by the rest of the page. This change adds style for CSSPropertyPosition, CSSPropertyLeft,
22622        and CSSPropertyTop.
22623
22624        * html/shadow/MediaControlElements.cpp:
22625        (WebCore::MediaControlTextTrackContainerElement::updateDisplay):
22626        Refactor style changes into updateStyleForTextTrackRepresentation().
22627        (WebCore::MediaControlTextTrackContainerElement::updateTimerFired):
22628        Refactor style changes into updateStyleForTextTrackRepresentation().
22629        (WebCore::MediaControlTextTrackContainerElement::clearTextTrackRepresentation):
22630        Refactor style changes into updateStyleForTextTrackRepresentation().
22631        (WebCore::MediaControlTextTrackContainerElement::updateStyleForTextTrackRepresentation):
22632        Consolidate style changes here. Include the two existing and three new style changes.
22633        * html/shadow/MediaControlElements.h:
22634        Declare updateStyleForTextTrackRepresentation().
22635
226362014-05-22  Simon Fraser  <simon.fraser@apple.com>
22637
22638        REGRESSION (r155977): Very stuttery 3D css animation on jtechcommunications.com
22639        https://bugs.webkit.org/show_bug.cgi?id=133179
22640        <rdar://problem/16864666>
22641
22642        Reviewed by Dean Jackson.
22643
22644        Revert code added in r155977 to try to pick a good contentsScale for layers
22645        based on a root-relative transform. This resulted in pages with too much 
22646        backing store, and too many cases where layers repainted during animations,
22647        causing stutter.
22648
22649        * platform/graphics/ca/GraphicsLayerCA.cpp:
22650        (WebCore::GraphicsLayerCA::GraphicsLayerCA):
22651        (WebCore::GraphicsLayerCA::flushCompositingState):
22652        (WebCore::GraphicsLayerCA::recursiveCommitChanges):
22653        (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
22654        (WebCore::GraphicsLayerCA::updateContentsOpaque):
22655        (WebCore::GraphicsLayerCA::updateAnimations):
22656        (WebCore::GraphicsLayerCA::appendToUncommittedAnimations):
22657        (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints):
22658        (WebCore::GraphicsLayerCA::setTransformAnimationKeyframes):
22659        (WebCore::GraphicsLayerCA::updateContentsScale):
22660        (WebCore::clampedContentsScaleForScale): Deleted.
22661        (WebCore::maxScaleFromTransform): Deleted.
22662        (WebCore::GraphicsLayerCA::updateRootRelativeScale): Deleted.
22663        (WebCore::GraphicsLayerCA::getTransformFromAnimationsWithMaxScaleImpact): Deleted.
22664        * platform/graphics/ca/GraphicsLayerCA.h:
22665
226662014-05-22  Martin Hock  <mhock@apple.com>
22667
22668        [iOS] Enable -apple-system- styled elements to respond to system font size changes.
22669        https://bugs.webkit.org/show_bug.cgi?id=133186
22670        <rdar://problem/16583782>
22671
22672        Reviewed by Enrica Casucci.
22673
22674        * WebCore.exp.in:
22675        * WebCore.xcodeproj/project.pbxproj:
22676        * rendering/RenderThemeIOS.h:
22677        * rendering/RenderThemeIOS.mm:
22678        (WebCore::_contentSizeCategory):
22679        (WebCore::RenderThemeIOS::contentSizeCategory):
22680        (WebCore::RenderThemeIOS::setContentSizeCategory):
22681
226822014-05-22  Jer Noble  <jer.noble@apple.com>
22683
22684        [MSE] Stored samples are not freed when SourceBuffer is removed from MediaSource
22685        https://bugs.webkit.org/show_bug.cgi?id=133174
22686
22687        Reviewed by Eric Carlson.
22688
22689        Clear out stored MediaSamples from SourceBuffer's TrackBuffer storage when
22690        aborting loading. Also, report the memory cost of those samples, so that the
22691        SourceBuffer will be GCd more readily.
22692
22693        Add a mechanism for reporting the size of a MediaSample:
22694        * Modules/mediasource/SourceBuffer.h:
22695        * platform/MediaSample.h:
22696        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
22697        * platform/mock/mediasource/MockSourceBufferPrivate.cpp:
22698
22699        Track the memory usage of a SampleMap when adding and removing samples, as well
22700        as allowing the SampleMap to be cleared wholesale:
22701        * Modules/mediasource/SampleMap.cpp:
22702        (WebCore::SampleMap::clear): Release all stored MediaSamples.
22703        (WebCore::SampleMap::addSample): Update m_totalSize.
22704        (WebCore::SampleMap::removeSample): Ditto.
22705        * Modules/mediasource/SampleMap.h:
22706        (WebCore::SampleMap::SampleMap): Initialize m_totalSize.
22707        (WebCore::SampleMap::sizeInBytes): Simple accessor.
22708
22709        Clear the stored samples when loading is aborted, and report the extra memory
22710        cost
22711        * Modules/mediasource/SourceBuffer.cpp:
22712        (WebCore::SourceBuffer::SourceBuffer): Initialize m_reportedExtraMemoryCost.
22713        (WebCore::SourceBuffer::removedFromMediaSource): Clear all stored samples.
22714        (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete): Call reportExtraMemoryCost().
22715        (WebCore::SourceBuffer::reportExtraMemoryCost): Inform the vm of the new
22716            extra memory cost incurred by the object.
22717
227182014-05-22  Enrica Casucci  <enrica@apple.com>
22719
22720        REGRESSION (WebKit2): Keyboard should have Search button in duckduckgo.com.
22721        https://bugs.webkit.org/show_bug.cgi?id=133183
22722        <rdar://problem/17004207>
22723
22724        Reviewed by Geoff Garen.
22725
22726        Adding new export.
22727
22728        * WebCore.exp.in:
22729
227302014-05-22  Carlos Garcia Campos  <cgarcia@igalia.com>
22731
22732        REGRESSION(r163712): [GTK] Misspelling and grammar underline marks are no longer drawn
22733        https://bugs.webkit.org/show_bug.cgi?id=133047
22734
22735        Reviewed by Darin Adler.
22736
22737        Change two conditions changed by mistake in r163712.
22738
22739        * editing/TextCheckingHelper.cpp:
22740        (WebCore::findMisspellings): Enter the loop also when wordStart is 0.
22741        (WebCore::TextCheckingHelper::findFirstMisspelling): Skip the work
22742        when the text is a single character. Also reworked it to use a for
22743        loop to improve the readability.
22744
227452014-05-22  Piotr Grad  <p.grad@samsung.com>
22746
22747        Video is resumed with old playback rate.
22748        https://bugs.webkit.org/show_bug.cgi?id=132905
22749
22750        Reviewed by Philippe Normand.
22751
22752        Setting '0' playback rate is causing pipeline to pause.
22753        GStreamer player impl. exposed this information to upper layers but it should not.
22754        Solution is to hidden such situation behind m_playbackRatePause flag.
22755
22756        Test: media/video-paused-0-rate.html
22757
22758        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
22759        (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
22760        (WebCore::MediaPlayerPrivateGStreamer::play):
22761        (WebCore::MediaPlayerPrivateGStreamer::pause):
22762        (WebCore::MediaPlayerPrivateGStreamer::doSeek):
22763        (WebCore::MediaPlayerPrivateGStreamer::updatePlaybackRate):
22764        (WebCore::MediaPlayerPrivateGStreamer::paused):
22765        (WebCore::MediaPlayerPrivateGStreamer::setRate):
22766        (WebCore::MediaPlayerPrivateGStreamer::updateStates):
22767        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
22768
227692014-05-22  Antti Koivisto  <antti@apple.com>
22770
22771        Text markers don't paint on simple lines
22772        https://bugs.webkit.org/show_bug.cgi?id=133177
22773
22774        Reviewed by Anders Carlsson.
22775        
22776        Marker painting code does not yet support simple lines.
22777
22778        Tests: fast/text/mark-matches-rendering-simple-lines.html
22779               fast/text/mark-matches-rendering.html
22780
22781        * dom/DocumentMarkerController.cpp:
22782        (WebCore::DocumentMarkerController::addMarker):
22783        
22784            Force text blocks with markers to use line boxes.
22785
22786        * testing/Internals.cpp:
22787        (WebCore::Internals::setMarkedTextMatchesAreHighlighted):
22788        
22789            Expose this so we can make reftests for marker rendering.
22790
22791        * testing/Internals.h:
22792        * testing/Internals.idl:
22793
227942014-05-22  Manuel Rego Casasnovas  <rego@igalia.com>
22795
22796        [CSS Grid Layout] Guard RenderObject::isRenderGrid() method
22797        https://bugs.webkit.org/show_bug.cgi?id=132380
22798
22799        Reviewed by Benjamin Poulain.
22800
22801        Guard RenderObject::isRenderGrid() method under ENABLE_CSS_GRID_LAYOUT compilation flag.
22802
22803        * rendering/RenderBox.cpp:
22804        (WebCore::RenderBox::computeLogicalWidthInRegion):
22805        * rendering/RenderObject.h:
22806
228072014-05-21  Antti Koivisto  <antti@apple.com>
22808
22809        REGRESSION(r167870): Crash in simple line layout code with :after
22810        https://bugs.webkit.org/show_bug.cgi?id=133155
22811        <rdar://problem/16977696>
22812
22813        Reviewed by Darin Adler.
22814        
22815        Fix https://bugs.webkit.org/show_bug.cgi?id=132241 in a safer way.
22816        The underline behavior is tested by the existing fast/text/simple-lines-hover-underline.html
22817
22818        Test: fast/text/simple-lines-hover-after.html
22819
22820        * rendering/RenderBlock.cpp:
22821        (WebCore::RenderBlock::invalidateLineLayoutPath): Deleted.
22822
22823            Move to RenderBlockFlow.
22824
22825        * rendering/RenderBlock.h:
22826        (WebCore::RenderBlock::invalidateLineLayoutPath):
22827        * rendering/RenderBlockFlow.cpp:
22828        (WebCore::RenderBlockFlow::styleDidChange):
22829        
22830            Invalidate layout if style changes in a manner that makes us ineligible to use the simple line layout path.
22831
22832        (WebCore::RenderBlockFlow::invalidateLineLayoutPath):
22833        
22834            Drop the simple line layout on path invalidation if it exists. It may not be valid anymore.
22835            Also invalidate the layout if this happens so we'll reconstruct the lines later.
22836
22837        (WebCore::RenderBlockFlow::simpleLineLayout): Deleted.
22838        (WebCore::RenderBlockFlow::ensureLineBoxes):
22839        (WebCore::RenderBlockFlow::createLineBoxes): Deleted.
22840                
22841            Revert some of the changes made it r167870.
22842
22843        * rendering/RenderBlockFlow.h:
22844        (WebCore::RenderBlockFlow::simpleLineLayout):
22845        
22846            Add strong validity assert.
22847
228482014-05-21  Eric Carlson  <eric.carlson@apple.com>
22849
22850        [iOS] two media control button strings are not localized
22851        https://bugs.webkit.org/show_bug.cgi?id=133160
22852
22853        Reviewed by Geoffrey Garen.
22854
22855        * English.lproj/mediaControlsLocalizedStrings.js:
22856
228572014-05-21  Dean Jackson  <dino@apple.com>
22858
22859        [iOS] Update some of the media controls buttons to be bigger
22860        https://bugs.webkit.org/show_bug.cgi?id=133158
22861        <rdar://problem/16475828>
22862
22863        Reviewed by Simon Fraser.
22864
22865        The buttons in the media controls on iOS are too small
22866        to be comfortably pressed. Make them the size of the controls
22867        panel and the expected iOS button size (44x44px).
22868
22869        The artwork for the buttons now includes the padding. I've
22870        added a file from which you can edit the artwork, then
22871        copy it into the CSS (because editing directly in CSS is
22872        a huge pain).
22873
22874        So far just the play/pause and fullscreen button have been
22875        updated. There will be a follow-up patch to fix the remaining
22876        buttons and the scrubber.
22877
22878        * Modules/mediacontrols/assets-apple-iOS.svg: Added.
22879        * Modules/mediacontrols/mediaControlsiOS.css:
22880        (audio::-webkit-media-controls-panel):
22881        (audio::-webkit-media-controls-fullscreen-button):
22882        (audio::-webkit-media-controls-play-button):
22883        (audio::-webkit-media-controls-play-button:active):
22884        (audio::-webkit-media-controls-play-button.paused):
22885        (audio::-webkit-media-controls-fullscreen-button:active):
22886        (@media only screen and (-webkit-min-device-pixel-ratio: 2)): Deleted.
22887
228882014-05-21  Zalan Bujtas  <zalan@apple.com>
22889
22890        Garbage when rubber-banding at the right edge of a page zoomed to non-integral scale.
22891        https://bugs.webkit.org/show_bug.cgi?id=133139
22892        <rdar://problem/16503353>
22893
22894        Reviewed by Simon Fraser.
22895
22896        Do not pixel align the root content layer. The alignment code expands the graphics's layer size
22897        which makes the right and bottom tiles bigger than the content.
22898        Painting the body's background color produces pixel cracks, because the content can not
22899        fill the expanded tiles completely.
22900
22901        Not testable.
22902
22903        * platform/graphics/GraphicsLayerClient.h:
22904        (WebCore::GraphicsLayerClient::needsPixelAligment):
22905        * platform/graphics/ca/GraphicsLayerCA.cpp:
22906        (WebCore::GraphicsLayerCA::updateGeometry):
22907        (WebCore::GraphicsLayerCA::computePixelAlignment):
22908        * platform/graphics/ca/mac/TileGrid.mm:
22909        (WebCore::TileGrid::rectForTileIndex):
22910        * rendering/RenderLayerBacking.cpp:
22911        (WebCore::RenderLayerBacking::needsPixelAligment):
22912        * rendering/RenderLayerBacking.h:
22913
229142014-05-21  Radu Stavila  <stavila@adobe.com>
22915
22916        REGRESSION (r168046): Invalid layout in WebCore::RenderBox::containingBlockLogicalWidthForPositioned
22917        https://bugs.webkit.org/show_bug.cgi?id=132933
22918
22919        Reviewed by Darin Adler.
22920
22921        Invalid layout is performed when calling containingBlockLogicalWidthForPositioned for a RenderTableSection object.
22922
22923        Test: fast/multicol/newmulticol/table-section-crash.html
22924
22925        * rendering/RenderBox.cpp:
22926        (WebCore::RenderBox::containingBlockLogicalWidthForPositioned):
22927
229282014-05-21  Simon Pena  <simon.pena@samsung.com>
22929
22930        [EFL] Ensure EGLOffScreenContext::initialize calls platformMakeCurrent on the surface
22931        https://bugs.webkit.org/show_bug.cgi?id=124832
22932
22933        Reviewed by Antonio Gomes.
22934
22935        The original code was only calling platformMakeCurrent when the
22936        GL_EXT_robustness extension is supported: the alternate code path
22937        would only create a context, but it wouldn't make that context
22938        current. This patch ensures platformMakeCurrent is also called for
22939        the alternate code path, and, if it fails to make the context
22940        current, will destroy the context. Effectively, this makes both
22941        code paths behave in the same way.
22942
22943        * platform/graphics/surfaces/egl/EGLContext.cpp:
22944        (WebCore::EGLOffScreenContext::initialize):
22945
229462014-05-20  Brent Fulgham  <bfulgham@apple.com>
22947
22948        [Mac] DataCues do not work properly when rewinding video
22949        https://bugs.webkit.org/show_bug.cgi?id=133138
22950        <rdar://problem/16979086>
22951
22952        Reviewed by Eric Carlson.
22953
22954        Make the TrackPrivateBase responsible for knowing if a type of track needs a non-zero
22955        startTimeVariance value.
22956
22957        Also, correct a bug in the equality test for DataCue objects.
22958
22959        * html/track/DataCue.cpp:
22960        (WebCore::DataCue::isEqual): Handle the JSValue data types consistently, so that we don't attempt
22961        to compare a JSNull against a default JSValue object.
22962        * html/track/InbandTextTrack.cpp:
22963        (WebCore::InbandTextTrack::startTimeVariance): Added.
22964        * html/track/InbandTextTrack.h:
22965        * html/track/TextTrack.cpp:
22966        (WebCore::TextTrack::hasCue): Use new startTimeVariance method location.
22967        * html/track/TextTrack.h:
22968        (WebCore::TextTrack::startTimeVariance): Added.
22969        * html/track/TextTrackCue.cpp:
22970        (WebCore::TextTrackCue::hasEquivalentStartTime): Use new startTimeVariance location.
22971        * html/track/TextTrackCue.h:
22972        (WebCore::TextTrackCue::startTimeVariance): Deleted.
22973        * html/track/TextTrackCueGeneric.h:
22974        * platform/graphics/TrackPrivateBase.h:
22975        (WebCore::TrackPrivateBase::startTimeVariance): Added.
22976        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
22977
229782014-05-20  Mark Hahnenberg  <mhahnenberg@apple.com>
22979
22980        Watchdog timer should be lazily allocated
22981        https://bugs.webkit.org/show_bug.cgi?id=133135
22982
22983        Reviewed by Geoffrey Garen.
22984
22985        No new tests.
22986
22987        We incur a noticeable amount of overhead on some benchmarks due to checking if the Watchdog ever fired. 
22988        There is no reason to do this checking if we never activated the Watchdog, which can only be done through 
22989        JSContextGroupSetExecutionTimeLimit or JSContextGroupClearExecutionTimeLimit. 
22990
22991        By allocating the Watchdog lazily on the VM we can avoid all of the associated overhead when we don't use 
22992        these two API functions (which is true of most clients).
22993
22994        * bindings/js/JSEventListener.cpp:
22995        (WebCore::JSEventListener::handleEvent):
22996        * bindings/js/WorkerScriptController.cpp:
22997        (WebCore::WorkerScriptController::evaluate):
22998        (WebCore::WorkerScriptController::scheduleExecutionTermination):
22999        (WebCore::WorkerScriptController::isExecutionTerminating):
23000
230012014-05-20  Dean Jackson  <dino@apple.com>
23002
23003        [Mac] Allow popup menus to override default appearance
23004        https://bugs.webkit.org/show_bug.cgi?id=133129
23005
23006        Reviewed by Tim Horton.
23007
23008        WebKitSystemInterface's WKPopupMenu has a flag to hide
23009        the arrows at the end of a popup-menu (e.g. <select>).
23010        Expose that via adding a hasDefaultAppearance flag to
23011        PopupMenuStyle, which then passes it on to WKSI.
23012
23013        * platform/PopupMenuStyle.h:
23014        (WebCore::PopupMenuStyle::PopupMenuStyle): New flag in constructor.
23015        (WebCore::PopupMenuStyle::hasDefaultAppearance): New flag.
23016        * platform/mac/WebCoreSystemInterface.h: wkPopupMenu signature has changed to accept
23017        the new flag.
23018        * platform/mac/WebCoreSystemInterface.mm: Ditto.
23019        * rendering/RenderMenuList.cpp:
23020        (RenderMenuList::itemStyle): Pass in true as default appearance when creating
23021        the PopupMenuStyle. We don't need it.
23022        (RenderMenuList::menuStyle): In this case we pass in the negated value of
23023        style().hasAppearance(), which indicates if we are overriding the built-in drawing.
23024        * rendering/RenderSearchField.cpp:
23025        (WebCore::RenderSearchField::menuStyle): Use true as the default value.
23026
230272014-05-20  Eric Carlson  <eric.carlson@apple.com>
23028
23029        [Mac] do not deactivate an audio session that has running I/O
23030        https://bugs.webkit.org/show_bug.cgi?id=133127
23031
23032        Reviewed by Jer Noble.
23033
23034        * page/Settings.h:
23035        (WebCore::Settings::setShouldManageAudioSessionCategory): Renamed from setShouldManageAudioSession.
23036        (WebCore::Settings::shouldManageAudioSessionCategory): Renamed from shouldManageAudioSession.
23037        (WebCore::Settings::setShouldManageAudioSession): Deleted.
23038        (WebCore::Settings::shouldManageAudioSession): Deleted.
23039
23040        * platform/audio/mac/MediaSessionManagerMac.cpp:
23041        (MediaSessionManager::updateSessionState): Don't deactivate the session if there are any
23042            Video or Audio sessions.
23043
23044        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
23045        (WebCore::MediaPlayerPrivateAVFoundationObjC::assetStatus): Drive-by change to log errors 
23046            returned by -statusOfValueForKey:error: in debug builds.
23047
230482014-05-20  Beth Dakin  <bdakin@apple.com>
23049
23050        REGRESSION: All non-mainframe scrollbars don't paint after r169065
23051        https://bugs.webkit.org/show_bug.cgi?id=133132
23052        -and corresponding-
23053        <rdar://problem/16968850>
23054
23055        Reviewed by Geoff Garen.
23056
23057        We should not universally return true here. This feature will only work for 
23058        scrollbars with layers.
23059        * platform/ScrollableArea.h:
23060        * platform/Scrollbar.cpp:
23061        (WebCore::Scrollbar::supportsUpdateOnSecondaryThread):
23062
230632014-05-20  Daniel Bates  <dabates@apple.com>
23064
23065        Element within flattened frame may update its scroll state during the layout phase of the wrong RenderView
23066        https://bugs.webkit.org/show_bug.cgi?id=133013
23067        <rdar://problem/16760154>
23068
23069        Reviewed by David Hyatt.
23070
23071        Fixes an issue where the scroll state of an element may be updated during the layout of the wrong
23072        RenderView. In particular, the scroll state of an element inside a CSS flex box in a flattened
23073        frame f is updated during the layout of the RenderView associated with the parent frame of f instead
23074        of during the layout of the RenderView associated with f.
23075
23076        The layout machinery assumes that the scroll state of each scrollable element is updated before the
23077        completion of layout for its associated RenderView. Currently we have logic to defer updating the scroll
23078        state of a scrollable element until completion of recursive layout. For a page with a flattened frame, we
23079        defer such updates until completion of layout for all RenderViews along the ancestor frame hierarchy of
23080        each flattened frame regardless of the RenderView associated with the element that originated the
23081        deferred scroll state request. Instead, only the RenderView associated with the element that deferred its
23082        scroll state update should dispatch the scroll state update.
23083
23084        Tests: fast/frames/flattening/scrollable-flexbox-inside-iframe-with-zero-height-and-needs-full-repaint-crash.html
23085               fast/frames/flattening/scrollable-flexbox-inside-iframe-with-zero-height-assertion-failure.html
23086
23087        * rendering/RenderBlock.cpp: Removed WTF::-prefix in typedef definition for ContinuationOutlineTableMap.
23088        (WebCore::UpdateScrollInfoAfterLayoutTransaction::UpdateScrollInfoAfterLayoutTransaction): Added; a struct
23089        that represents a RenderView v, nested transaction count, and a list of RenderBlocks in v that will need
23090        to have their scroll state updated.
23091        (WebCore::updateScrollInfoAfterLayoutTransactionStack): Added; returns the global stack of transactions.
23092        (WebCore::RenderBlock::willBeDestroyed): Call removeFromUpdateScrollInfoAfterLayoutTransaction(), which
23093        was formerly named as removeFromDelayedUpdateScrollInfoSet.
23094        (WebCore::currentUpdateScrollInfoAfterLayoutTransaction): Added; returns the top-most transaction in the
23095        global stack.
23096        (WebCore::RenderBlock::beginUpdateScrollInfoAfterLayoutTransaction): Modified as appropriate to make use
23097        of the global stack of transactions; formerly named startDelayUpdateScrollInfo.
23098        (WebCore::RenderBlock::endAndCommitUpdateScrollInfoAfterLayoutTransaction): Modified as appropriate to
23099        make use of the global stack of transactions; formerly named finishDelayUpdateScrollInfo.
23100        (WebCore::RenderBlock::removeFromUpdateScrollInfoAfterLayoutTransaction): Modified as appropriate to make
23101        use of the global stack of transactions; formerly named removeFromDelayedUpdateScrollInfoSet.
23102        (WebCore::RenderBlock::updateScrollInfoAfterLayout): Modified as appropriate to make use of the global
23103        stack of transactions.
23104        (WebCore::RenderBlock::layout): Ditto.
23105        (WebCore::RenderBlock::startDelayUpdateScrollInfo): Deleted.
23106        (WebCore::RenderBlock::finishDelayUpdateScrollInfo): Deleted.
23107        (WebCore::RenderBlock::removeFromDelayedUpdateScrollInfoSet): Deleted.
23108        * rendering/RenderBlock.h:
23109        * rendering/RenderBlockFlow.cpp:
23110        (WebCore::RenderBlockFlow::willBeDestroyed): Call removeFromUpdateScrollInfoAfterLayoutTransaction(), which
23111        was formerly named removeFromDelayedUpdateScrollInfoSet.
23112        * rendering/RenderDeprecatedFlexibleBox.cpp:
23113        (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox): Call {begin, end}UpdateScrollInfoAfterLayoutTransaction(),
23114        which was formerly named {start, end}DelayUpdateScrollInfo.
23115        (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox): Ditto.
23116        * rendering/RenderFlexibleBox.cpp:
23117        (WebCore::RenderFlexibleBox::layoutBlock): Ditto.
23118
231192014-05-20  Beth Dakin  <bdakin@apple.com>
23120
23121        REGRESSION (r169065): Mountain Lion run-api-tests failures: ASSERTION FAILED: 
23122        Uncaught exception - -[NSRegularLegacyScrollerImp setPresentationValue:]: 
23123        unrecognized selector sent to instance 0x7ff51aa38000
23124        https://bugs.webkit.org/show_bug.cgi?id=133121
23125
23126        Reviewed by Tim Horton.
23127
23128        * platform/mac/ScrollbarThemeMac.mm:
23129        (WebCore::ScrollbarThemeMac::setPaintCharacteristicsForScrollbar):
23130
231312014-05-19  Simon Fraser  <simon.fraser@apple.com>
23132
23133        REGRESSION (r169063) Fixed and sticky nodes misplaced on scrolling sometimes
23134        https://bugs.webkit.org/show_bug.cgi?id=133106
23135        <rdar://problem/16967648>
23136
23137        Reviewed by Sam Weinig.
23138
23139        Fix regression from r169063. That commit removed scrolledContentsLayers from 
23140        frame scrolling nodes, but they do actually use them.
23141        
23142        So put them back; not in the base class, because they have a somewhat different
23143        meaning for overflow scrolling and frame scrolling.
23144
23145        * WebCore.exp.in:
23146        * page/scrolling/AsyncScrollingCoordinator.cpp:
23147        (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
23148        (WebCore::AsyncScrollingCoordinator::updateFrameScrollingNode):
23149        * page/scrolling/AsyncScrollingCoordinator.h:
23150        * page/scrolling/ScrollingCoordinator.h:
23151        (WebCore::ScrollingCoordinator::updateFrameScrollingNode):
23152        * page/scrolling/ScrollingStateFrameScrollingNode.cpp:
23153        (WebCore::ScrollingStateFrameScrollingNode::ScrollingStateFrameScrollingNode):
23154        (WebCore::ScrollingStateFrameScrollingNode::setScrolledContentsLayer):
23155        * page/scrolling/ScrollingStateFrameScrollingNode.h:
23156        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
23157        (WebCore::ScrollingTreeFrameScrollingNodeMac::updateBeforeChildren):
23158        * rendering/RenderLayerCompositor.cpp:
23159        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
23160
231612014-05-20  Radu Stavila  <stavila@adobe.com>
23162
23163        REGRESSION: [CSS Regions] Content flowed directly into the flow thread that ends up in the second region is not properly repainted
23164        https://bugs.webkit.org/show_bug.cgi?id=133111
23165
23166        Reviewed by David Hyatt.
23167
23168        When computing the repaint rect of an element flowed into a flow thread, if the element is flowed directly into
23169        the flow thread (meaning its containing block is the flow thread itself), the region's position within the flow
23170        must no longer be taken into consideration, because its already included in the element's |topLeft|.
23171
23172        Test: fast/regions/hover-element-flowed-second-region.html
23173
23174        * rendering/RenderBox.cpp:
23175        (WebCore::RenderBox::computeRectForRepaint):
23176
231772014-05-20  Alex Christensen  <achristensen@webkit.org>
23178
23179        Fix web timing assertion failure.
23180        https://bugs.webkit.org/show_bug.cgi?id=133094
23181        <rdar://problem/16966032>
23182
23183        Reviewed by Alexey Proskuryakov.
23184
23185        * platform/network/mac/ResourceHandleMac.mm:
23186        (WebCore::ResourceHandle::getConnectionTimingData):
23187        Set requestStart and responseStart to 0 instead of -1 to match the 
23188        ResourceLoadTiming constructor and prevent the assertion failure in
23189        PerformanceTiming::responseStart.
23190
231912014-05-20  Prashant Hiremath  <hiremathprashants@gmail.com>
23192
23193        Only set title on SVG documents
23194        https://bugs.webkit.org/show_bug.cgi?id=133068
23195
23196        Reviewed by Dirk Schulze.
23197
23198        Test: svg/custom/html_document_set_title.html
23199
23200        * svg/SVGTitleElement.cpp:
23201        (WebCore::SVGTitleElement::insertedInto):
23202        (WebCore::SVGTitleElement::removedFrom):
23203        (WebCore::SVGTitleElement::childrenChanged):
23204
232052014-05-20  peavo@outlook.com  <peavo@outlook.com>
23206
23207        [Curl] Invalid content in cache file, causes broken rendering.
23208        https://bugs.webkit.org/show_bug.cgi?id=133069
23209
23210        Reviewed by Brent Fulgham.
23211
23212        When data for a url is received as multiple parts, the cache file for the url is truncated when opened for writing,
23213        and will only contain the last part of data received.
23214        This is fixed by only opening the file once, and close it after all data has been received.
23215
23216        * platform/network/curl/CurlCacheEntry.cpp:
23217        (WebCore::CurlCacheEntry::CurlCacheEntry): Initialize cache file handle member.
23218        (WebCore::CurlCacheEntry::~CurlCacheEntry): Close cache file.
23219        (WebCore::CurlCacheEntry::saveCachedData): Only open cache file once to avoid truncating.
23220        (WebCore::CurlCacheEntry::didFail): Close cache file.
23221        (WebCore::CurlCacheEntry::didFinishLoading): Ditto.
23222        (WebCore::CurlCacheEntry::openContentFile): Added method to open cache file.
23223        (WebCore::CurlCacheEntry::closeContentFile): Added method to close cache file.
23224        * platform/network/curl/CurlCacheEntry.h: Added file handle member, and methods to open and close cache file.
23225
232262014-05-20  Radu Stavila  <stavila@adobe.com>
23227
23228        [CSS Regions] Block incorrectly sized when containing an unsplittable box
23229        https://bugs.webkit.org/show_bug.cgi?id=132601
23230
23231        Reviewed by Antti Koivisto.
23232
23233        When laying out elements in a region, when an inline element is encountered
23234        the size of its parent must not be increased beyond the bottom of the current region,
23235        unless if its the last region. This will ensure that the next sibling of the
23236        inline element is correctly laid out at the top of the next region, instead
23237        of leaving an empty space equal to the height of the overflow, as it did until now.
23238
23239        Tests: fast/regions/inline-block-inside-anonymous-overflow.html
23240               fast/regions/inline-block-overflow.html
23241
23242        * rendering/RenderBlockFlow.cpp:
23243        (WebCore::RenderBlockFlow::adjustLinePositionForPagination):
23244        (WebCore::RenderBlockFlow::hasNextPage):
23245        * rendering/RenderBlockFlow.h:
23246        * rendering/RenderBlockLineLayout.cpp:
23247        (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
23248        (WebCore::RenderBlockFlow::linkToEndLineIfNeeded):
23249        (WebCore::RenderBlockFlow::determineStartPosition):
23250        (WebCore::RenderBlockFlow::checkPaginationAndFloatsAtEndLine):
23251
232522014-05-20  Mihnea Ovidenie  <mihnea@adobe.com>
23253
23254        [CSS Regions] Crash while painting block selection gaps in regions
23255        https://bugs.webkit.org/show_bug.cgi?id=132720
23256
23257        Reviewed by David Hyatt.
23258
23259        The fix for WebKit bug https://bugs.webkit.org/show_bug.cgi?id=131511
23260        allowed selection highlight to match the DOM selection when the start
23261        and end point of the selection were in different flow threads. In order
23262        to enable that, the selection was performed separately on view and
23263        render flow threads, considered selection subtrees.
23264
23265        However, the start and end points for each selection subtree were computed
23266        by means of Range class but it is not always possible to construct a valid
23267        Range from two pairs of RenderObjects and offsets.
23268
23269        This patch keeps the substrees approach but instead of storing the endpoints
23270        for each subtree in a Range and continuously extending the Range, it stores them
23271        using the already available SelectionSubtreeRoot class. After the end points are
23272        computed for each subtree and before processing the subtree selection, the end points
23273        are adjusted in a similar fashion as the one used in FrameSelection::updateAppearance(),
23274        to make sure we are passing the same expected information to the method implementing
23275        the visible selection processing.
23276
23277        Test: fast/regions/selection-gaps-paint-crash.html
23278
23279        * rendering/RenderView.cpp:
23280        (WebCore::RenderView::splitSelectionBetweenSubtrees):
23281        * rendering/SelectionSubtreeRoot.cpp:
23282        (WebCore::SelectionSubtreeRoot::adjustForVisibleSelection):
23283        * rendering/SelectionSubtreeRoot.h:
23284        (WebCore::SelectionSubtreeRoot::selectionClear):
23285
232862014-05-19  Simon Fraser  <simon.fraser@apple.com>
23287
23288        Scrolling pages with large TiledBacking content layers creates way too many tiles
23289        https://bugs.webkit.org/show_bug.cgi?id=133101
23290
23291        Reviewed by Tim Horton.
23292
23293        Fix the GraphicsLayerCA::adjustTiledLayerVisibleRect() logic to avoid making giant rects if the old
23294        and new visible rects don't overlap.
23295
23296        * platform/graphics/TiledBacking.h:
23297        * platform/graphics/ca/GraphicsLayerCA.cpp:
23298        (WebCore::GraphicsLayerCA::adjustTiledLayerVisibleRect):
23299        * platform/graphics/ca/mac/TileController.h:
23300
233012014-05-19  Simon Fraser  <simon.fraser@apple.com>
23302
23303        Correctly maintain the "isInWindow" state for all TiledBackings
23304        https://bugs.webkit.org/show_bug.cgi?id=133095
23305
23306        Reviewed by Tim Horton.
23307        
23308        We never updated the "isInWindow" state for TiledBacking that wasn't the RenderView's
23309        backing. Fix it by having RenderLayerCompositor::setIsInWindow() recurse through all
23310        layers (if necessary), updating their state. Also set the state on newly created
23311        TiledBackings.
23312
23313        * rendering/RenderLayerCompositor.cpp:
23314        (WebCore::RenderLayerCompositor::layerTiledBackingUsageChanged):
23315        (WebCore::RenderLayerCompositor::setIsInWindowForLayerIncludingDescendants):
23316        (WebCore::RenderLayerCompositor::setIsInWindow):
23317        (WebCore::RenderLayerCompositor::pageTiledBacking): Deleted.
23318        * rendering/RenderLayerCompositor.h:
23319
233202014-05-19  Dean Jackson  <dino@apple.com>
23321
23322        [iOS] Use status display for live streams
23323        https://bugs.webkit.org/show_bug.cgi?id=133097
23324
23325        Reviewed by Sam Weinig.
23326
23327        Follow-on from https://bugs.webkit.org/show_bug.cgi?id=131390
23328        Allow the iOS controls to use the status display field.
23329
23330        * Modules/mediacontrols/mediaControlsiOS.js:
23331        (ControllerIOS.prototype.configureInlineControls): Live streams should
23332        not have a timeline or rewind button.
23333
233342014-05-19  Myles C. Maxfield  <litherum@gmail.com>
23335
23336        Text decorations do not contribute to visual overflow
23337        https://bugs.webkit.org/show_bug.cgi?id=132773
23338
23339        Reviewed by Antti Koivisto.
23340
23341        This patch creates a function, visualOverflowForDecorations, which computes
23342        how much visual overflow to add around a text box due to text decorations. Most of the time,
23343        text decorations are fully contained within the text box, so the result is usually 0.
23344
23345        This function exists within style/InlineTextBoxStyle.cpp, which is an added file. This is
23346        so that it can be called from setLogicalWidthForTextRun() inside RenderBlockLineLayout.cpp
23347        and from RenderStyle::changeAffectsVisualOverflow(). The former case passes in the full
23348        InlineTextBox and the latter case just passes in a RenderStyle (because the InlineTextBox
23349        is unavailable.)
23350
23351        This patch also modifies RenderTableSection::spannedColumns() to fix an off-by-one error
23352        that was causing table borders to not be drawn when they existed right on the edge of
23353        a repaint rect.
23354
23355        Tests: fast/css3-text/css3-text-decoration/repaint/underline-outside-of-layout-rect.html
23356        Tests: fast/repaint/border-collapse-table-off-by-one-expected.html
23357
23358        * WebCore.vcxproj/WebCore.vcxproj: Adding reference to new InlineTextBoxStyle.cpp file
23359        * WebCore.vcxproj/WebCore.vcxproj.filters: Adding reference to new InlineTextBoxStyle files
23360        * WebCore.xcodeproj/project.pbxproj: Adding reference to new InlineTextBoxStyle files
23361        * rendering/InlineTextBox.cpp:
23362        (WebCore::computeUnderlineOffset): Moved to InlineTextBox.cpp
23363        (WebCore::getWavyStrokeParameters): Moved to InlineTextBox.cpp
23364        (WebCore::InlineTextBox::paintDecoration): Update to use newly refactored functions
23365        * rendering/RenderBlockLineLayout.cpp:
23366        (WebCore::setLogicalWidthForTextRun): Call visualOverflowForDecorations()
23367        * rendering/RenderTableSection.cpp:
23368        * rendering/RenderTableSelection.cpp: Fix off-by-one error when the boundary of a repaint
23369        rect lies exactly on top of a table column position
23370        * rendering/style/RenderStyle.cpp:
23371        (WebCore::RenderStyle::changeAffectsVisualOverflow): Inspects shadows and text decorations
23372        (WebCore::RenderStyle::changeRequiresLayout): Calls changeAffectsVisualOverflow()
23373        (WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline): Moved code from here
23374        to changeAffectsVisualOverflow().
23375        * rendering/style/RenderStyle.h: Function signature
23376        * style/InlineTextBoxStyle.cpp: Added.
23377        (WebCore::computeUnderlineOffset): Moved from InlineTextBox.cpp
23378        (WebCore::getWavyStrokeParameters): Moved from InlineTextBox.cpp
23379        (WebCore::extendIntToFloat): Convenience function for dealing with the fact that
23380        underline bounding boxes use floats and GlyphOverflow uses ints
23381        (WebCore::visualOverflowForDecorations): Given
23382        vertical overflow bounds, possibly extend those to include location of
23383        decorations.
23384        * style/InlineTextBoxStyle.h: Added. Function signatures.
23385        (WebCore::textDecorationStrokeThickness): Refactored from InlineTextBox.cpp
23386        (WebCore::wavyOffsetFromDecoration): Refactored from InlineTextBox.cpp
23387        * platform/graphics/Font.h:
23388        (WebCore::GlyphOverflow::isEmpty): Convenience function
23389        (WebCore::GlyphOverflow::extendTo): Convenience function
23390
233912014-05-19  Alex Christensen  <achristensen@webkit.org>
23392
23393        Unreviewed build fix after r169082
23394
23395        * platform/network/ResourceHandle.h:
23396        Added NSDictionary declaration.
23397
233982014-05-19  Beth Dakin  <bdakin@apple.com>
23399
23400        REGRESSION: Standalone images need to take topContentInset into account
23401        https://bugs.webkit.org/show_bug.cgi?id=133092
23402        -and corresponding-
23403        <rdar://problem/16945791>
23404
23405        Reviewed by Darin Adler.
23406
23407        The FrameView’s size is accurate in terms of the NSWindow size, but that is not 
23408        really what the ImageDocument code is looking for here. The ImageDocument wants to 
23409        know the size of the unobscured viewport area. We should use visibleSize() for 
23410        that.
23411        * html/ImageDocument.cpp:
23412        (WebCore::ImageDocument::scale):
23413        (WebCore::ImageDocument::imageFitsInWindow):
23414        (WebCore::ImageDocument::imageClicked):
23415
234162014-05-19  Alex Christensen  <achristensen@webkit.org>
23417
23418        Collect web timing data on iOS.
23419        https://bugs.webkit.org/show_bug.cgi?id=133075
23420
23421        Reviewed by Sam Weinig.
23422
23423        * platform/network/ResourceHandle.h:
23424        Added setCollectsTimingData wrapper and getConnectionTimingData declarations.
23425        getConnectionTimingData with a dictionary parameter is a private helper function.
23426        * platform/network/cf/ResourceHandleCFNet.cpp:
23427        (WebCore::ResourceHandle::start):
23428        Call setCollectsTimingData wrapper when creating a connection to ensure that timing data is collected.
23429        * platform/network/cf/ResourceHandleCFURLConnectionDelegate.cpp:
23430        (WebCore::ResourceHandleCFURLConnectionDelegate::didReceiveResponseCallback):
23431        * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h:
23432        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
23433        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse):
23434        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.h:
23435        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp:
23436        (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveResponse):
23437        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h:
23438        Pass the CFURLConnectionRef to didReceiveResponse to get timing data from.
23439        * platform/network/mac/ResourceHandleMac.mm:
23440        (WebCore::ResourceHandle::getConnectionTimingData):
23441        Moved from getTimingData to compile regardless of using CFNetwork and added wrapper with CFDictionaryRef.
23442        (WebCore::ResourceHandle::setCollectsTimingData):
23443        Added wrapper to call objc function from c++.
23444        (WebCore::ResourceHandle::getTimingData):
23445        Renamed to getConnectionTimingData.
23446        * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
23447        (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
23448        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
23449        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
23450        Updated function name from getTimingData to getConnectionTimingData.
23451
234522014-05-19  Chris Fleizach  <cfleizach@apple.com>
23453
23454        AX: VoiceOver sees the WebArea out of order when topContentInset is used
23455        https://bugs.webkit.org/show_bug.cgi?id=133091
23456
23457        Reviewed by Simon Fraser.
23458
23459        Modify the scroll view's frame so that it recognizes the content inset.
23460        This is needed so that when VoiceOver sorts elements to create an ordering,
23461        the web area is not ordered at the top of the screen.
23462
23463        Test: platform/mac-wk2/accessibility/content-inset-scrollview-frame.html
23464
23465        * accessibility/AccessibilityScrollView.cpp:
23466        (WebCore::AccessibilityScrollView::elementRect):
23467
234682014-05-19  Beth Dakin  <bdakin@apple.com>
23469
23470        Scrollbars display incorrectly after switching between fast and slow scrolling 
23471        mode, affects Find and real sites
23472        https://bugs.webkit.org/show_bug.cgi?id=133077
23473        -and corresponding-
23474        <rdar://problem/16888608>
23475
23476        Reviewed by Tim Horton.
23477
23478        We should always return true here when updating on the secondary thread is 
23479        supported. It does not need to be gated on whether we are actively taking 
23480        advantage of that support at this moment.
23481        * platform/Scrollbar.cpp:
23482        (WebCore::Scrollbar::supportsUpdateOnSecondaryThread):
23483
23484        Always update the presentationValue whenever we update the doubleValue just to 
23485        keep them in sync.
23486        * platform/mac/ScrollbarThemeMac.mm:
23487        (WebCore::ScrollbarThemeMac::setPaintCharacteristicsForScrollbar):
23488
234892014-05-19  Simon Fraser  <simon.fraser@apple.com>
23490
23491        Split scrolling tree ScrollingNodes into FrameScrollingNodes and OverflowScrollingNodes
23492        https://bugs.webkit.org/show_bug.cgi?id=133022
23493
23494        Reviewed by Sam Weinig.
23495
23496        In both the scrolling state tree and the scrolling tree, split the "scrolling nodes"
23497        into FrameScrolling and OverflowScrolling nodes.
23498        
23499        Move what was the "viewportSize" property onto the base class for the scrolling
23500        nodes, calling it "scrollableAreaSize".
23501        
23502        Make minimum/maximumScrollPosition() virtual so we can share more code (and there
23503        is more code sharing to be done in future).
23504
23505        * Configurations/WebCore.xcconfig: Remove ScrollingStateScrollingNodeMac.mm and ScrollingTreeScrollingNodeMac.mm
23506        from the list, using #ifdefs in the file instead.
23507        * WebCore.exp.in: Lots of exports.
23508        * WebCore.xcodeproj/project.pbxproj: New files.
23509        * page/scrolling/AsyncScrollingCoordinator.cpp:
23510        (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
23511        (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
23512        (WebCore::AsyncScrollingCoordinator::updateFrameScrollingNode):
23513        (WebCore::AsyncScrollingCoordinator::updateOverflowScrollingNode):
23514        (WebCore::AsyncScrollingCoordinator::recomputeWheelEventHandlerCountForFrameView):
23515        (WebCore::AsyncScrollingCoordinator::updateScrollingNode): Deleted.
23516        (WebCore::AsyncScrollingCoordinator::setScrollbarPaintersFromScrollbarsForNode): Deleted.
23517        This tiny function didn't need to exist.
23518        * page/scrolling/AsyncScrollingCoordinator.h:
23519        * page/scrolling/ScrollingCoordinator.h:
23520        (WebCore::ScrollingCoordinator::updateFrameScrollingNode):
23521        (WebCore::ScrollingCoordinator::updateOverflowScrollingNode):
23522        (WebCore::ScrollingCoordinator::updateScrollingNode): Deleted.
23523        * page/scrolling/ScrollingStateFrameScrollingNode.cpp: Copied from Source/WebCore/page/scrolling/ScrollingStateScrollingNode.cpp.
23524        (WebCore::ScrollingStateFrameScrollingNode::create):
23525        (WebCore::ScrollingStateFrameScrollingNode::ScrollingStateFrameScrollingNode):
23526        (WebCore::ScrollingStateFrameScrollingNode::~ScrollingStateFrameScrollingNode):
23527        (WebCore::ScrollingStateFrameScrollingNode::clone):
23528        (WebCore::ScrollingStateFrameScrollingNode::setFrameScaleFactor):
23529        (WebCore::ScrollingStateFrameScrollingNode::setNonFastScrollableRegion):
23530        (WebCore::ScrollingStateFrameScrollingNode::setWheelEventHandlerCount):
23531        (WebCore::ScrollingStateFrameScrollingNode::setSynchronousScrollingReasons):
23532        (WebCore::ScrollingStateFrameScrollingNode::setScrollBehaviorForFixedElements):
23533        (WebCore::ScrollingStateFrameScrollingNode::setHeaderHeight):
23534        (WebCore::ScrollingStateFrameScrollingNode::setFooterHeight):
23535        (WebCore::ScrollingStateFrameScrollingNode::setTopContentInset):
23536        (WebCore::ScrollingStateFrameScrollingNode::setCounterScrollingLayer):
23537        (WebCore::ScrollingStateFrameScrollingNode::setInsetClipLayer):
23538        (WebCore::ScrollingStateFrameScrollingNode::setContentShadowLayer):
23539        (WebCore::ScrollingStateFrameScrollingNode::setHeaderLayer):
23540        (WebCore::ScrollingStateFrameScrollingNode::setFooterLayer):
23541        (WebCore::ScrollingStateFrameScrollingNode::setScrollbarPaintersFromScrollbars):
23542        (WebCore::ScrollingStateFrameScrollingNode::dumpProperties):
23543        * page/scrolling/ScrollingStateFrameScrollingNode.h: Copied from Source/WebCore/page/scrolling/ScrollingStateScrollingNode.h.
23544        * page/scrolling/ScrollingStateNode.h:
23545        (WebCore::LayerRepresentation::layerID):
23546        (WebCore::ScrollingStateNode::isFrameScrollingNode):
23547        (WebCore::ScrollingStateNode::isOverflowScrollingNode):
23548        * page/scrolling/ScrollingStateOverflowScrollingNode.cpp: Added.
23549        (WebCore::ScrollingStateOverflowScrollingNode::create):
23550        (WebCore::ScrollingStateOverflowScrollingNode::ScrollingStateOverflowScrollingNode):
23551        (WebCore::ScrollingStateOverflowScrollingNode::~ScrollingStateOverflowScrollingNode):
23552        (WebCore::ScrollingStateOverflowScrollingNode::clone):
23553        (WebCore::ScrollingStateOverflowScrollingNode::setScrolledContentsLayer):
23554        (WebCore::ScrollingStateOverflowScrollingNode::dumpProperties):
23555        * page/scrolling/ScrollingStateOverflowScrollingNode.h: Copied from Source/WebCore/page/scrolling/mac/ScrollingStateScrollingNodeMac.mm.
23556        (WebCore::ScrollingStateOverflowScrollingNode::scrolledContentsLayer):
23557        * page/scrolling/ScrollingStateScrollingNode.cpp:
23558        (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
23559        (WebCore::ScrollingStateScrollingNode::setScrollableAreaSize):
23560        (WebCore::ScrollingStateScrollingNode::setTotalContentsSize):
23561        (WebCore::ScrollingStateScrollingNode::dumpProperties):
23562        (WebCore::ScrollingStateScrollingNode::create): Deleted.
23563        (WebCore::ScrollingStateScrollingNode::clone): Deleted.
23564        (WebCore::ScrollingStateScrollingNode::setViewportSize): Deleted.
23565        (WebCore::ScrollingStateScrollingNode::setFrameScaleFactor): Deleted.
23566        (WebCore::ScrollingStateScrollingNode::setNonFastScrollableRegion): Deleted.
23567        (WebCore::ScrollingStateScrollingNode::setWheelEventHandlerCount): Deleted.
23568        (WebCore::ScrollingStateScrollingNode::setSynchronousScrollingReasons): Deleted.
23569        (WebCore::ScrollingStateScrollingNode::setScrollBehaviorForFixedElements): Deleted.
23570        (WebCore::ScrollingStateScrollingNode::setHeaderHeight): Deleted.
23571        (WebCore::ScrollingStateScrollingNode::setFooterHeight): Deleted.
23572        (WebCore::ScrollingStateScrollingNode::setTopContentInset): Deleted.
23573        (WebCore::ScrollingStateScrollingNode::setScrolledContentsLayer): Deleted.
23574        (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayer): Deleted.
23575        (WebCore::ScrollingStateScrollingNode::setInsetClipLayer): Deleted.
23576        (WebCore::ScrollingStateScrollingNode::setContentShadowLayer): Deleted.
23577        (WebCore::ScrollingStateScrollingNode::setHeaderLayer): Deleted.
23578        (WebCore::ScrollingStateScrollingNode::setFooterLayer): Deleted.
23579        (WebCore::ScrollingStateScrollingNode::setScrollbarPaintersFromScrollbars): Deleted.
23580        * page/scrolling/ScrollingStateScrollingNode.h:
23581        (WebCore::ScrollingStateScrollingNode::scrollableAreaSize):
23582        (WebCore::ScrollingStateScrollingNode::totalContentsSize):
23583        * page/scrolling/ScrollingStateTree.cpp:
23584        (WebCore::ScrollingStateTree::attachNode):
23585        (WebCore::ScrollingStateTree::commit):
23586        * page/scrolling/ScrollingStateTree.h:
23587        (WebCore::ScrollingStateTree::rootStateNode):
23588        (WebCore::ScrollingStateTree::setRootStateNode):
23589        * page/scrolling/ScrollingTree.cpp:
23590        (WebCore::ScrollingTree::commitNewTreeState):
23591        * page/scrolling/ScrollingTreeFrameScrollingNode.cpp: Added.
23592        (WebCore::ScrollingTreeFrameScrollingNode::ScrollingTreeFrameScrollingNode):
23593        (WebCore::ScrollingTreeFrameScrollingNode::~ScrollingTreeFrameScrollingNode):
23594        (WebCore::ScrollingTreeFrameScrollingNode::updateBeforeChildren):
23595        * page/scrolling/ScrollingTreeFrameScrollingNode.h: Copied from Source/WebCore/page/scrolling/ScrollingTreeScrollingNode.h.
23596        (WebCore::ScrollingTreeFrameScrollingNode::updateLayersAfterDelegatedScroll):
23597        (WebCore::ScrollingTreeFrameScrollingNode::synchronousScrollingReasons):
23598        (WebCore::ScrollingTreeFrameScrollingNode::shouldUpdateScrollLayerPositionSynchronously):
23599        (WebCore::ScrollingTreeFrameScrollingNode::frameScaleFactor):
23600        (WebCore::ScrollingTreeFrameScrollingNode::headerHeight):
23601        (WebCore::ScrollingTreeFrameScrollingNode::footerHeight):
23602        (WebCore::ScrollingTreeFrameScrollingNode::topContentInset):
23603        (WebCore::ScrollingTreeFrameScrollingNode::scrollBehaviorForFixedElements):
23604        * page/scrolling/ScrollingTreeNode.h:
23605        (WebCore::ScrollingTreeNode::isFrameScrollingNode):
23606        (WebCore::ScrollingTreeNode::isOverflowScrollingNode):
23607        * page/scrolling/ScrollingTreeOverflowScrollingNode.cpp: Copied from Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h.
23608        (WebCore::ScrollingTreeOverflowScrollingNode::ScrollingTreeOverflowScrollingNode):
23609        (WebCore::ScrollingTreeOverflowScrollingNode::~ScrollingTreeOverflowScrollingNode):
23610        * page/scrolling/ScrollingTreeOverflowScrollingNode.h: Copied from Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h.
23611        * page/scrolling/ScrollingTreeScrollingNode.cpp:
23612        (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
23613        (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
23614        (WebCore::ScrollingTreeScrollingNode::updateAfterChildren):
23615        (WebCore::ScrollingTreeScrollingNode::setScrollPosition):
23616        (WebCore::ScrollingTreeScrollingNode::setScrollPositionWithoutContentEdgeConstraints):
23617        (WebCore::ScrollingTreeScrollingNode::minimumScrollPosition):
23618        (WebCore::ScrollingTreeScrollingNode::maximumScrollPosition):
23619        * page/scrolling/ScrollingTreeScrollingNode.h:
23620        (WebCore::ScrollingTreeScrollingNode::scrollableAreaSize):
23621        (WebCore::ScrollingTreeScrollingNode::totalContentsSize):
23622        (WebCore::ScrollingTreeScrollingNode::totalContentsSizeForRubberBand):
23623        (WebCore::ScrollingTreeScrollingNode::setTotalContentsSizeForRubberBand):
23624        (WebCore::ScrollingTreeScrollingNode::synchronousScrollingReasons): Deleted.
23625        (WebCore::ScrollingTreeScrollingNode::shouldUpdateScrollLayerPositionSynchronously): Deleted.
23626        (WebCore::ScrollingTreeScrollingNode::viewportSize): Deleted.
23627        (WebCore::ScrollingTreeScrollingNode::frameScaleFactor): Deleted.
23628        (WebCore::ScrollingTreeScrollingNode::headerHeight): Deleted.
23629        (WebCore::ScrollingTreeScrollingNode::footerHeight): Deleted.
23630        (WebCore::ScrollingTreeScrollingNode::scrollBehaviorForFixedElements): Deleted.
23631        (WebCore::ScrollingTreeScrollingNode::topContentInset): Deleted.
23632        * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
23633        (WebCore::ScrollingCoordinatorIOS::createScrollingTreeNode):
23634        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.h: Renamed from Source/WebCore/page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h.
23635        (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollLayer):
23636        * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm: Renamed from Source/WebCore/page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm.
23637        (WebCore::ScrollingTreeFrameScrollingNodeIOS::create):
23638        (WebCore::ScrollingTreeFrameScrollingNodeIOS::ScrollingTreeFrameScrollingNodeIOS):
23639        (WebCore::ScrollingTreeFrameScrollingNodeIOS::~ScrollingTreeFrameScrollingNodeIOS):
23640        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateBeforeChildren):
23641        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateAfterChildren):
23642        (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollPosition):
23643        (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollPosition):
23644        (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollPositionWithoutContentEdgeConstraints):
23645        (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollLayerPosition):
23646        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateLayersAfterViewportChange):
23647        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateLayersAfterDelegatedScroll):
23648        (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateChildNodesAfterScroll):
23649        (WebCore::ScrollingTreeFrameScrollingNodeIOS::minimumScrollPosition):
23650        (WebCore::ScrollingTreeFrameScrollingNodeIOS::maximumScrollPosition):
23651        (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollBy):
23652        (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollByWithoutContentEdgeConstraints):
23653        * page/scrolling/mac/ScrollingCoordinatorMac.mm:
23654        (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode):
23655        * page/scrolling/mac/ScrollingStateFrameScrollingNodeMac.mm: Renamed from Source/WebCore/page/scrolling/mac/ScrollingStateScrollingNodeMac.mm.
23656        (WebCore::ScrollingStateFrameScrollingNode::setScrollbarPaintersFromScrollbars):
23657        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h: Renamed from Source/WebCore/page/scrolling/mac/ScrollingTreeScrollingNodeMac.h.
23658        * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm: Renamed from Source/WebCore/page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm.
23659        (WebCore::ScrollingTreeFrameScrollingNodeMac::create):
23660        (WebCore::ScrollingTreeFrameScrollingNodeMac::ScrollingTreeFrameScrollingNodeMac):
23661        (WebCore::ScrollingTreeFrameScrollingNodeMac::~ScrollingTreeFrameScrollingNodeMac):
23662        (WebCore::ScrollingTreeFrameScrollingNodeMac::updateBeforeChildren):
23663        (WebCore::ScrollingTreeFrameScrollingNodeMac::updateAfterChildren):
23664        (WebCore::ScrollingTreeFrameScrollingNodeMac::handleWheelEvent):
23665        (WebCore::ScrollingTreeFrameScrollingNodeMac::allowsHorizontalStretching):
23666        (WebCore::ScrollingTreeFrameScrollingNodeMac::allowsVerticalStretching):
23667        (WebCore::ScrollingTreeFrameScrollingNodeMac::stretchAmount):
23668        (WebCore::ScrollingTreeFrameScrollingNodeMac::pinnedInDirection):
23669        (WebCore::ScrollingTreeFrameScrollingNodeMac::canScrollHorizontally):
23670        (WebCore::ScrollingTreeFrameScrollingNodeMac::canScrollVertically):
23671        (WebCore::ScrollingTreeFrameScrollingNodeMac::shouldRubberBandInDirection):
23672        (WebCore::ScrollingTreeFrameScrollingNodeMac::absoluteScrollPosition):
23673        (WebCore::ScrollingTreeFrameScrollingNodeMac::immediateScrollBy):
23674        (WebCore::ScrollingTreeFrameScrollingNodeMac::immediateScrollByWithoutContentEdgeConstraints):
23675        (WebCore::ScrollingTreeFrameScrollingNodeMac::startSnapRubberbandTimer):
23676        (WebCore::ScrollingTreeFrameScrollingNodeMac::stopSnapRubberbandTimer):
23677        (WebCore::ScrollingTreeFrameScrollingNodeMac::adjustScrollPositionToBoundsIfNecessary):
23678        (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollPosition):
23679        (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPosition):
23680        (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPositionWithoutContentEdgeConstraints):
23681        (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollLayerPosition):
23682        (WebCore::ScrollingTreeFrameScrollingNodeMac::updateLayersAfterViewportChange):
23683        (WebCore::ScrollingTreeFrameScrollingNodeMac::minimumScrollPosition):
23684        (WebCore::ScrollingTreeFrameScrollingNodeMac::maximumScrollPosition):
23685        (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollBy):
23686        (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollByWithoutContentEdgeConstraints):
23687        (WebCore::ScrollingTreeFrameScrollingNodeMac::updateMainFramePinState):
23688        (WebCore::ScrollingTreeFrameScrollingNodeMac::logExposedUnfilledArea):
23689        (WebCore::logThreadedScrollingMode):
23690        (WebCore::logWheelEventHandlerCountChanged):
23691        * rendering/RenderLayerCompositor.cpp:
23692        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
23693
236942014-05-19  Simon Fraser  <simon.fraser@apple.com>
23695
23696        Images missing sometimes with composited clipping layers
23697        https://bugs.webkit.org/show_bug.cgi?id=133065
23698        <rdar://problem/15224559>
23699
23700        Reviewed by Beth Dakin.
23701        
23702        When support for solid colors on layers was added, a layer was considered a candidate
23703        for the solid color optimization without regard to whether it had descendent layers
23704        with "paintsIntoCompositedAncestor" requirements.
23705        
23706        Fix hasVisibleNonCompositingDescendantLayers(), renaming it to isPaintDestinationForDescendentLayers()
23707        and having it take into account whether descendent layers need to paint into an
23708        ancestor.
23709        
23710        Also, this test has to happen after those descendent layers have had their
23711        compositing state updated, so move the isSimpleContainerCompositingLayer() to
23712        a new updateAfterDescendents() function which is called from the various
23713        places we do compositing-udpate-tree-walks.
23714
23715        Test: compositing/backing/solid-color-with-paints-into-ancestor.html
23716
23717        * rendering/RenderLayerBacking.cpp:
23718        (WebCore::RenderLayerBacking::updateGeometry):
23719        (WebCore::RenderLayerBacking::updateAfterDescendents):
23720        (WebCore::RenderLayerBacking::paintsChildren):
23721        (WebCore::compositedWithOwnBackingStore):
23722        (WebCore::descendentLayerPaintsIntoAncestor):
23723        (WebCore::RenderLayerBacking::isPaintDestinationForDescendentLayers):
23724        (WebCore::hasVisibleNonCompositingDescendant): Deleted.
23725        (WebCore::RenderLayerBacking::hasVisibleNonCompositingDescendantLayers): Deleted.
23726        * rendering/RenderLayerBacking.h:
23727        * rendering/RenderLayerCompositor.cpp:
23728        (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
23729        (WebCore::RenderLayerCompositor::updateLayerTreeGeometry):
23730        (WebCore::RenderLayerCompositor::updateCompositingDescendantGeometry):
23731
237322014-05-19  Zalan Bujtas  <zalan@apple.com>
23733
23734        REGRESSION (r133351, sub-pixel layout): Right-to-left block with text-overflow: ellipsis truncates prematurely (breaks facebook.com Hebrew UI)
23735        https://bugs.webkit.org/show_bug.cgi?id=112227
23736
23737        Reviewed by Maciej Stachowiak.
23738
23739        This patch removes unnecessary integral snapping of inlines at layout time.
23740
23741        The general rule of thumb of using round/floor/ceil at layout time is to not use them.
23742 
23743        When some computed values (x, y, width, height) get snapped during layout, while others don't,
23744        intersecting/measuring mismatches could occur and they could end up producing visual artifacts such as truncations.
23745        This patch also enables iframe content to be positioned on odd device pixel positions on retina displays.
23746        
23747        Tests: fast/frames/hidpi-position-iframe-on-device-pixel.html
23748               fast/inline/hidpi-rtl-text-does-not-fit-line-and-gets-cut-off.html
23749
23750        * rendering/RenderBlock.h:
23751        (WebCore::RenderBlock::logicalLeftOffsetForLine):
23752        (WebCore::RenderBlock::pixelSnappedLogicalLeftOffsetForLine): Deleted.
23753        (WebCore::RenderBlock::pixelSnappedLogicalRightOffsetForLine): Deleted.
23754        * rendering/RenderBlockLineLayout.cpp:
23755        (WebCore::updateLogicalInlinePositions):
23756        (WebCore::RenderBlockFlow::deleteEllipsisLineBoxes):
23757        (WebCore::RenderBlockFlow::checkLinesForTextOverflow):
23758
237592014-05-18  Chris Fleizach  <cfleizach@apple.com>
23760
23761        AX: iOS: using AXAttributeCacheEnabler is too slow for every accessibilityElementAtIndex:
23762        https://bugs.webkit.org/show_bug.cgi?id=133043
23763
23764        Reviewed by Mario Sanchez Prada.
23765
23766        iOS Accessibility code tries to improve performance by caching attributes when accessing
23767        elements through the platform API. However, those API calls can be used very frequently when 
23768        iterating elements. Creating the AXAttributeCacheEnabler object and tearing it down is proving
23769        to be the hottest code path in samples for accessibility access.
23770
23771        We need to move the logic for enabling/disabling the attribute cache to a level that can make
23772        a more informed decision about when to enable/disable.
23773
23774        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
23775        (-[WebAccessibilityObjectWrapper enableAttributeCaching]):
23776        (-[WebAccessibilityObjectWrapper disableAttributeCaching]):
23777        (-[WebAccessibilityObjectWrapper accessibilityElementCount]):
23778        (-[WebAccessibilityObjectWrapper accessibilityElementAtIndex:]):
23779        (-[WebAccessibilityObjectWrapper indexOfAccessibilityElement:]):
23780
237812014-05-18  Simon Fraser  <simon.fraser@apple.com>
23782
23783        Use RenderStyle& in more places in RenderLayerBacking
23784        https://bugs.webkit.org/show_bug.cgi?id=133061
23785
23786        Reviewed by Andreas Kling.
23787
23788        Convert several member functions to use references to RenderStyle rather
23789        than pointers. Move canCreateTiledImage() higher in the file (no code
23790        changes). Other minor cleanup.
23791
23792        * rendering/RenderLayerBacking.cpp:
23793        (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
23794        (WebCore::RenderLayerBacking::updateOpacity):
23795        (WebCore::RenderLayerBacking::updateTransform):
23796        (WebCore::RenderLayerBacking::updateFilters):
23797        (WebCore::RenderLayerBacking::updateBlendMode):
23798        (WebCore::RenderLayerBacking::updateGeometry):
23799        (WebCore::hasBoxDecorations):
23800        (WebCore::canCreateTiledImage):
23801        (WebCore::hasBoxDecorationsOrBackgroundImage):
23802        (WebCore::hasPerspectiveOrPreserves3D):
23803        (WebCore::supportsDirectBoxDecorationsComposition):
23804        (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
23805        (WebCore::RenderLayerBacking::contentChanged):
23806        (WebCore::RenderLayerBacking::startTransition):
23807        * rendering/RenderLayerBacking.h:
23808
238092014-05-17  Simon Fraser  <simon.fraser@apple.com>
23810
23811        Rename some RenderLayerBacking member functions
23812        https://bugs.webkit.org/show_bug.cgi?id=133030
23813
23814        Reviewed by Sam Weinig.
23815
23816        Remove "GraphicsLayer" from some member function names on RenderLayerBacking.
23817        
23818        No behavior change.
23819
23820        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
23821        (WebCore::AVFWrapper::createAVCFVideoLayer):
23822        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
23823        (WebCore::MediaPlayerPrivateQTKit::createQTMovieLayer):
23824        * rendering/RenderLayer.cpp:
23825        (WebCore::RenderLayer::calculateClipRects):
23826        * rendering/RenderLayerBacking.cpp:
23827        (WebCore::RenderLayerBacking::updateAfterLayout):
23828        (WebCore::RenderLayerBacking::updateConfiguration):
23829        (WebCore::RenderLayerBacking::updateGeometry):
23830        (WebCore::RenderLayerBacking::contentChanged):
23831        (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
23832        (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration): Deleted.
23833        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): Deleted.
23834        * rendering/RenderLayerBacking.h:
23835        * rendering/RenderLayerCompositor.cpp:
23836        (WebCore::RenderLayerCompositor::updateLayerCompositingState):
23837        (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
23838        (WebCore::RenderLayerCompositor::updateLayerTreeGeometry):
23839        (WebCore::RenderLayerCompositor::updateCompositingDescendantGeometry):
23840        (WebCore::RenderLayerCompositor::attachRootLayer):
23841
238422014-05-19  Antti Koivisto  <antti@apple.com>
23843
23844        Fix assertion failure with simple line layout debug borders enabled.
23845
23846        Rubber-stamped by Andreas Kling.
23847
23848        * rendering/SimpleLineLayoutFunctions.cpp:
23849        (WebCore::SimpleLineLayout::paintDebugBorders): We shoudn't try to paint empty rects.
23850
238512014-05-18  Andreas Kling  <akling@apple.com>
23852
23853        Reduce constructor copypasta in RenderText and RenderElement.
23854        <https://webkit.org/b/133056>
23855
23856        Use delegating constructors to remove duplicated initializer lists
23857        from the constructors of RenderText and RenderElement.
23858
23859        Reviewed by Anders Carlsson.
23860
23861        * rendering/RenderElement.cpp:
23862        (WebCore::RenderElement::RenderElement):
23863        * rendering/RenderElement.h:
23864        * rendering/RenderText.cpp:
23865        (WebCore::RenderText::RenderText):
23866        * rendering/RenderText.h:
23867
238682014-05-18  Brent Fulgham  <bfulgham@apple.com>
23869
23870        Crash during scroll when latched
23871        https://bugs.webkit.org/show_bug.cgi?id=133064
23872
23873        Reviewed by Simon Fraser.
23874
23875        * page/mac/EventHandlerMac.mm:
23876        (WebCore::EventHandler::platformPrepareForWheelEvents): Prevent dereference of NULL
23877        wheelEventTarget argument.
23878
238792014-05-18  Svetlana Redchenko  <redchenko@yandex-team.ru>
23880
23881        Input ::selection pseudo class does not work leading to hidden selection
23882        https://bugs.webkit.org/show_bug.cgi?id=38943
23883
23884        Reviewed by Darin Adler.
23885
23886        Test: fast/selectors/input-with-selection-pseudo-element.html
23887
23888        When text is selected inside input element, it should change the
23889        color and background color according to the ::selection pseudo element.
23890
23891        * rendering/RenderObject.cpp:
23892        (WebCore::RenderObject::selectionBackgroundColor):
23893        (WebCore::RenderObject::selectionColor):
23894        (WebCore::RenderObject::selectionPseudoStyle):
23895        * rendering/RenderObject.h:
23896
238972014-05-18  Sam Weinig  <sam@webkit.org>
23898
23899        [WebKit2] Implement ScriptMessageHandlers
23900        https://bugs.webkit.org/show_bug.cgi?id=133053
23901
23902        Reviewed by Anders Carlsson.
23903
23904        * DerivedSources.make:
23905        * WebCore.exp.in:
23906        * WebCore.xcodeproj/project.pbxproj:
23907        * bindings/js/JSDOMWindowBase.cpp:
23908        (WebCore::JSDOMWindowBase::finishCreation):
23909        * bindings/js/JSUserMessageHandlersNamespaceCustom.cpp: Added.
23910        (WebCore::JSUserMessageHandlersNamespace::getOwnPropertySlotDelegate):
23911        * page/DOMWindow.cpp:
23912        (WebCore::DOMWindow::shouldHaveWebKitNamespaceForWorld):
23913        (WebCore::DOMWindow::webkitNamespace):
23914        * page/DOMWindow.h:
23915        * page/UserContentController.cpp:
23916        (WebCore::UserContentController::addUserMessageHandlerDescriptor):
23917        (WebCore::UserContentController::removeUserMessageHandlerDescriptor):
23918        * page/UserContentController.h:
23919        (WebCore::UserContentController::userMessageHandlerDescriptors):
23920        * page/UserMessageHandler.cpp: Added.
23921        (WebCore::UserMessageHandler::UserMessageHandler):
23922        (WebCore::UserMessageHandler::~UserMessageHandler):
23923        (WebCore::UserMessageHandler::postMessage):
23924        (WebCore::UserMessageHandler::name):
23925        (WebCore::UserMessageHandler::world):
23926        * page/UserMessageHandler.h: Added.
23927        (WebCore::UserMessageHandler::create):
23928        * page/UserMessageHandler.idl: Added.
23929        * page/UserMessageHandlerDescriptor.cpp: Added.
23930        (WebCore::UserMessageHandlerDescriptor::UserMessageHandlerDescriptor):
23931        (WebCore::UserMessageHandlerDescriptor::~UserMessageHandlerDescriptor):
23932        (WebCore::UserMessageHandlerDescriptor::name):
23933        (WebCore::UserMessageHandlerDescriptor::world):
23934        * page/UserMessageHandlerDescriptor.h: Added.
23935        (WebCore::UserMessageHandlerDescriptor::Client::~Client):
23936        (WebCore::UserMessageHandlerDescriptor::create):
23937        (WebCore::UserMessageHandlerDescriptor::client):
23938        * page/UserMessageHandlerDescriptorTypes.h: Added.
23939        * page/UserMessageHandlersNamespace.cpp: Added.
23940        (WebCore::UserMessageHandlersNamespace::UserMessageHandlersNamespace):
23941        (WebCore::UserMessageHandlersNamespace::~UserMessageHandlersNamespace):
23942        (WebCore::UserMessageHandlersNamespace::handler):
23943        * page/UserMessageHandlersNamespace.h: Added.
23944        (WebCore::UserMessageHandlersNamespace::create):
23945        * page/UserMessageHandlersNamespace.idl: Added.
23946        * page/WebKitNamespace.cpp: Added.
23947        (WebCore::WebKitNamespace::WebKitNamespace):
23948        (WebCore::WebKitNamespace::~WebKitNamespace):
23949        (WebCore::WebKitNamespace::messageHandlers):
23950        * page/WebKitNamespace.h: Added.
23951        (WebCore::WebKitNamespace::create):
23952        * page/WebKitNamespace.idl: Added.
23953
239542014-05-18  Maciej Stachowiak  <mjs@apple.com>
23955
23956        REGRESSION (r156546): Default media controls are laid out incorrectly when media element is styled with direction:rtl
23957        https://bugs.webkit.org/show_bug.cgi?id=132531
23958        <rdar://problem/16806267>
23959        
23960        Reviewed by Mark Rowe.
23961
23962        This was already tested by the media/video-rtl.htm reftest, now unskipped.
23963
23964        * Modules/mediacontrols/mediaControlsApple.css:
23965        (audio::-webkit-media-controls-panel): Add missing direction: ltr
23966
239672014-05-18  Rik Cabanier  <cabanier@adobe.com>
23968
23969        support for navigator.hardwareConcurrency
23970        https://bugs.webkit.org/show_bug.cgi?id=132588
23971
23972        Reviewed by Filip Pizlo.
23973
23974        Added a new API that returns the number of CPU cores up to 8.
23975
23976        Test: fast/dom/navigator-hardwareConcurrency.html
23977
23978        * Configurations/FeatureDefines.xcconfig:
23979        * page/Navigator.cpp:
23980        (WebCore::Navigator::hardwareConcurrency):
23981        * page/Navigator.h:
23982        * page/Navigator.idl:
23983
239842014-05-18  Anders Carlsson  <andersca@apple.com>
23985
23986        Fix iOS build.
23987
23988        * WebCore.exp.in:
23989        Move UserContentController symbols to the right place.
23990
239912014-05-18  Jon Lee  <jonlee@apple.com>
23992
23993        Build fix for r169006.
23994
23995        Unreviewed.
23996
23997        * loader/ResourceLoader.h: Return didCreateQuickLookHandle() to public.
23998
239992014-05-18  Antti Koivisto  <antti@apple.com>
24000
24001        REGRESSION (r160259): text-combine glyphs are not rendered
24002        https://bugs.webkit.org/show_bug.cgi?id=127324
24003
24004        Reviewed by Andreas Kling.
24005        
24006        The original text gets overwritten by a change that is supposed to affect rendered text only.
24007        Fixed by giving the text update functions well-defined purposes.
24008
24009        Test: fast/text/text-combine-rendering.html
24010
24011        * rendering/RenderCombineText.cpp:
24012        (WebCore::RenderCombineText::styleDidChange):
24013        (WebCore::RenderCombineText::setRenderedText):
24014        (WebCore::RenderCombineText::combineText):
24015        (WebCore::RenderCombineText::setTextInternal): Deleted.
24016        * rendering/RenderCombineText.h:
24017        * rendering/RenderCounter.cpp:
24018        (WebCore::RenderCounter::computePreferredLogicalWidths):
24019        * rendering/RenderText.cpp:
24020        (WebCore::RenderText::setRenderedText):
24021        
24022            This function now updates the rendered text but does not change the original.
24023            Get the original text by calling originalText().
24024
24025        (WebCore::RenderText::setText):
24026        
24027            This the only place original text now changes.
24028
24029        (WebCore::RenderText::setTextInternal): Deleted.
24030        
24031            Renamed to setRenderedText.
24032
24033        * rendering/RenderText.h:
24034        * rendering/svg/RenderSVGInlineText.cpp:
24035        (WebCore::RenderSVGInlineText::setRenderedText):
24036        (WebCore::RenderSVGInlineText::setTextInternal): Deleted.
24037        * rendering/svg/RenderSVGInlineText.h:
24038
240392014-05-17  Maciej Stachowiak  <mjs@apple.com>
24040
24041        Don't attempt to update id or name for nodes that are already removed
24042        https://bugs.webkit.org/show_bug.cgi?id=133041
24043
24044        Reviewed by Sam Weinig.
24045
24046        Tests: fast/dom/remove-element-with-id-that-was-inserted-on-DOMNodeRemoved.html
24047               fast/dom/remove-element-with-name-that-was-inserted-on-DOMNodeRemoved.html
24048
24049        * dom/Element.cpp:
24050        (WebCore::Element::removedFrom): Skip updating ids and names for an element not
24051        in a treescope, as we already do for elements not in a document.
24052
240532014-05-17  Alexey Proskuryakov  <ap@apple.com>
24054
24055        REGRESSION (NetworkProcess): Trying to use appcache fallback crashes in ApplicationCacheHost::scheduleLoadFallbackResourceFromApplicationCache
24056        https://bugs.webkit.org/show_bug.cgi?id=133007
24057        <rdar://problem/13702706>
24058
24059        appcache tests often fail on the Mac WebKit2 bot
24060        https://bugs.webkit.org/show_bug.cgi?id=82061
24061
24062        Reviewed by Maciej Stachowiak.
24063
24064        Covered by existing tests, which this patch enables.
24065
24066        * WebCore.exp.in: Export ResourceLoader::cancel(const ResourceError&). It used
24067        to be virtual, but marking subclasses final has resulted in the compiler calling
24068        it directly from WebKitLegacy framework. Seeing that no subclass overrides it,
24069        I then made it non-virtual.
24070        Also export ApplicationCacheHost functions that are now used from WebKit2.
24071
24072        * loader/ResourceLoader.h: Made the class abstract (as I didn't realize at first
24073        that it's always either a SubresourceLoader or a NetscapePlugInStreamLoader).
24074        Made ResourceHandleClient functions private, as they should never be called other
24075        than via a ResourceHandleClient pointer.
24076
24077        * loader/NetscapePlugInStreamLoader.h:
24078        * loader/SubresourceLoader.h:
24079        Marked these final.
24080
24081        * loader/ResourceLoader.cpp: (WebCore::ResourceLoader::willSwitchToSubstituteResource):
24082        Added a function to be called when switching to a substitute resource. We still
24083        need a ResourceLoader at this point, as substitute resource will be delivered through
24084        it, but we don't want it to continue its current load.
24085
24086        * loader/appcache/ApplicationCacheHost.cpp:
24087        (WebCore::ApplicationCacheHost::scheduleLoadFallbackResourceFromApplicationCache):
24088        Call the ResourceLoader function instead of using handle, which is null when
24089        using out of process networking.
24090
240912014-05-17  Andreas Kling  <akling@apple.com>
24092
24093        We shouldn't make a ScrollingThread on iOS.
24094        <https://webkit.org/b/133038>
24095        <rdar://problem/16947589>
24096
24097        Don't call ScrollingThred::dispatch() from the pressure relief
24098        code on iOS since that will end up instantiating a scrolling thread
24099        which we'd otherwise never have.
24100
24101        Reviewed by Sam Weinig.
24102
24103        * platform/MemoryPressureHandler.cpp:
24104        (WebCore::MemoryPressureHandler::releaseMemory):
24105
241062014-05-17  Piotr Grad  <p.grad@samsung.com>
24107
24108        Setting playback rate on video with media controller is not ignored.
24109        https://bugs.webkit.org/show_bug.cgi?id=129048
24110
24111        Reviewed by Jer Noble.
24112
24113        Replaced queries for m_playbackRate with effectivePlaybackRate()
24114        which includes media controller playback rate.
24115
24116        Test: media/video-controller-child-rate.html
24117
24118        * html/HTMLMediaElement.cpp:
24119        (WebCore::HTMLMediaElement::parseAttribute):
24120        * html/HTMLMediaElement.h:
24121
241222014-05-16  Anders Carlsson  <andersca@apple.com>
24123
24124        Expose WKUserScript as API
24125        https://bugs.webkit.org/show_bug.cgi?id=133017
24126        <rdar://problem/16948059>
24127
24128        Reviewed by Sam Weinig.
24129
24130        * WebCore.exp.in:
24131        Export symbols.
24132
24133        * WebCore.xcodeproj/project.pbxproj:
24134        Change UserContentController.h to be a private header.
24135
24136        * page/Page.cpp:
24137        (WebCore::Page::Page):
24138        Set m_userContentController from the page configuration and add it if it's not null.
24139
24140        * page/Page.h:
24141        Add UserContentController to PageClients.
24142
24143        * page/PageGroup.cpp:
24144        (WebCore::PageGroup::addPage):
24145        Only try to add a user content controller if the page doesn't already have one.
24146
24147        (WebCore::PageGroup::removePage):
24148        Only try to remove the user content controller if it's the group one.
24149
241502014-05-17  Andreas Kling  <akling@apple.com>
24151
24152        REGRESSION (r166422): All RenderBox objects grew 104 bytes from adding repaint timers.
24153        <https://webkit.org/b/133027>
24154        <rdar://problem/16867410>
24155
24156        Instead of storing a rarely-used repaint timer on every RenderBox, store one
24157        on the RenderView, and keep a hash set of renderers needing repaint.
24158
24159        Renderers get a flag tracking whether they have a pending lazy repaint.
24160        This way we can avoid hash lookups in the common case.
24161
24162        Also added a static assertion to catch RenderBox growing in the future.
24163
24164        Reviewed by Antti Koivisto.
24165
24166        * rendering/RenderBox.cpp:
24167        (WebCore::SameSizeAsRenderBox::~SameSizeAsRenderBox):
24168        (WebCore::RenderBox::RenderBox):
24169        (WebCore::RenderBox::~RenderBox):
24170        (WebCore::RenderBox::paintBoxDecorations):
24171        (WebCore::RenderBox::layoutOverflowRectForPropagation):
24172        * rendering/RenderBox.h:
24173        * rendering/RenderElement.cpp:
24174        (WebCore::RenderElement::RenderElement):
24175        * rendering/RenderElement.h:
24176        (WebCore::RenderElement::setRenderBoxNeedsLazyRepaint):
24177        (WebCore::RenderElement::renderBoxNeedsLazyRepaint):
24178        * rendering/RenderView.cpp:
24179        (WebCore::RenderView::RenderView):
24180        (WebCore::RenderView::scheduleLazyRepaint):
24181        (WebCore::RenderView::unscheduleLazyRepaint):
24182        (WebCore::RenderView::lazyRepaintTimerFired):
24183        * rendering/RenderView.h:
24184
241852014-05-16  Jer Noble  <jer.noble@apple.com>
24186
24187        [Mac][MSE] setCurrentTime() goes down fastSeek path in MediaPlayerPrivateMediaSourceAVFObjC.
24188        https://bugs.webkit.org/show_bug.cgi?id=133023
24189
24190        Reviewed by Eric Carlson.
24191
24192        When seeking a MSE video, do not go down the fastSeekForMediaTime() path if the
24193        seek resulted from a setCurrentTime() call. The logic can lead to attempted seeks
24194        before buffered ranges.
24195
24196        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
24197        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
24198        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
24199        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
24200        (WebCore::MediaSourcePrivateAVFObjC::seekToTime):
24201
242022014-05-16  Benjamin Poulain  <bpoulain@apple.com>
24203
24204        [iOS] ScrollView::visibleContentRectInternal is bypassing the iOS code for unobscuredContentRect
24205        https://bugs.webkit.org/show_bug.cgi?id=133008
24206
24207        Reviewed by Simon Fraser.
24208
24209        * platform/ScrollView.cpp:
24210        (WebCore::ScrollView::visibleContentRectInternal):
24211        ScrollView::visibleContentRectInternal() was calling the internal implementation of visibleContentRect().
24212        That was skipping the iOS implementation and getting the framerect directly. That size is invalid on iOS
24213        when the exposed rect and unobscured rect are not the same.
24214
242152014-05-16  Jer Noble  <jer.noble@apple.com>
24216
24217        [Mac] naturalSize not updated when preload=metadata
24218        https://bugs.webkit.org/show_bug.cgi?id=132994
24219
24220        Reviewed by Eric Carlson.
24221
24222        Test: media/video-load-preload-metadata-naturalsize.html
24223
24224        When preload=metadata, we never create an AVPlayerItem, and therefore never receive a
24225        presentationSize KVO. When an AVAsset informs us that its tracks have changed, and there
24226        is no AVPlayerItem, recalculate presentation size based on the first video track's natural
24227        size.
24228
24229        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
24230        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged):
24231        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
24232        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
24233
242342014-05-16  Simon Fraser  <simon.fraser@apple.com>
24235
24236        Remove "region-based columns" prefs
24237        https://bugs.webkit.org/show_bug.cgi?id=133006
24238        <rdar://problem/16945824>
24239
24240        Reviewed by Dave Hyatt.
24241
24242        Remove "region-based columns" prefs and related code, since this is only
24243        way to render columns now.
24244
24245        * page/Settings.in:
24246
242472014-05-16  Antti Koivisto  <antti@apple.com>
24248
24249        Link search area for touch events is too large in some cases
24250        https://bugs.webkit.org/show_bug.cgi?id=132988
24251        <rdar://problem/16917843>
24252
24253        Reviewed by Simon Fraser.
24254
24255        * page/ios/FrameIOS.mm:
24256        (WebCore::Frame::qualifyingNodeAtViewportLocation):
24257        
24258            - Adjust the search area to screen ppi.
24259            - Remove cut-off at scale 1. This made us pick physically far-away elements when zoomed in.
24260            
24261        * platform/PlatformScreen.h:
24262        * platform/ios/PlatformScreenIOS.mm:
24263        (WebCore::mobileGestaltFloatValue):
24264        (WebCore::screenPPIFactor):
24265
24266            Figure out screens physical PPI relative to a base.
24267
242682014-05-16  Jer Noble  <jer.noble@apple.com>
24269
24270        [MSE] Crash at  WebCore::SourceBuffer::~SourceBuffer + 110
24271        https://bugs.webkit.org/show_bug.cgi?id=132973
24272
24273        Reviewed by Eric Carlson.
24274
24275        Change SourceBuffer::m_private into a Ref<>, and add an assertion to
24276        SourceBufferPrivateAVFObjC's destructor if its client has not been cleared.
24277
24278        Eliminate unnecessary churn in MediaSourcePrivateAVFObjC by having the predicate
24279        functor take bare pointers, rather than a PassRefPtr.
24280
24281        The underlying problem seems to be in WebAVStreamDataParserListener. RefPtrs were
24282        being created off the main thread to a non-thread safe ref counted class. In some
24283        situations, this would result in double decrementing the ref, which would cause an
24284        early destruction of the underlying object. Instead replace these RefPtr strong
24285        pointers with explicit weak ones. Ensure the parser and its delegate are not freed
24286        before the append operation completes by passing strong pointers into the async
24287        append operation lambda.
24288
24289        There were a few places where we weren't null checking m_mediaSource before using it,
24290        and at least one place where we weren't clearing m_mediaSource.
24291
24292        * Modules/mediasource/SourceBuffer.cpp:
24293        (WebCore::SourceBuffer::SourceBuffer): Use Ref instead of RefPtr.
24294        (WebCore::SourceBuffer::appendBufferTimerFired): Ditto.
24295        * Modules/mediasource/SourceBuffer.h:
24296        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
24297        (WebCore::MediaSourcePrivateAVFObjCHasAudio): Take a bare pointer, instead of a PassRefPtr.
24298        (WebCore::MediaSourcePrivateAVFObjCHasVideo): Ditto.
24299        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
24300        (WebCore::MediaSourcePrivateAVFObjC::removeSourceBuffer): Clear the back pointer when removing a buffer.
24301        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
24302        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
24303        (-[WebAVStreamDataParserListener initWithParser:parent:WebCore::]): Use WeakPtr instead of RefPtr.
24304        (-[WebAVStreamDataParserListener invalidate]): Ditto.
24305        (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:]): Ditto.
24306        (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:withDiscontinuity:]): Ditto.
24307        (-[WebAVStreamDataParserListener streamDataParser:didFailToParseStreamDataWithError:]): Ditto.
24308        (-[WebAVStreamDataParserListener streamDataParser:didProvideMediaData:forTrackID:mediaType:flags:]): Ditto.
24309        (-[WebAVStreamDataParserListener streamDataParser:didReachEndOfTrackWithTrackID:mediaType:]): Ditto.
24310        (-[WebAVStreamDataParserListener streamDataParser:didProvideContentKeyRequestInitializationData:forTrackID:]): Ditto.
24311        (WebCore::SourceBufferPrivateAVFObjC::~SourceBufferPrivateAVFObjC):
24312        (WebCore::SourceBufferPrivateAVFObjC::append): Ditto.
24313
243142014-05-16  Zalan Bujtas  <zalan@apple.com>
24315
24316        Subpixel rendering: Push named flows in region to device pixel when painting.
24317        https://bugs.webkit.org/show_bug.cgi?id=132986
24318
24319        Reviewed by Simon Fraser.
24320
24321        Remove integral rounding when named flow sets the painting offset on the graphics context.
24322        Use device pixel snapping instead to ensure that we can paint on odd device pixel positions on retina displays. 
24323
24324        Test: fast/regions/hidpi-region-with-auto-margin-on-subpixel-position.html
24325
24326        * rendering/RenderLayer.cpp:
24327        (WebCore::RenderLayer::calculateClipRects):
24328
243292014-05-16  Radu Stavila  <stavila@adobe.com>
24330
24331        [CSS Regions] Add ASSERT to make sure using the flowThread cache does not return incorrect results
24332        https://bugs.webkit.org/show_bug.cgi?id=132906
24333
24334        Reviewed by Simon Fraser.
24335
24336        If flowThreadContainingBlock() is called on an object which is in a different
24337        flow thread than the one currently being laid out, this method will return an incorrect
24338        result. I added an assertion for that to make sure we catch and treat any such scenarios.
24339        For the moment, this assertion is only validated for regions, as multicol still has some issues.
24340
24341        No new tests required.
24342
24343        * rendering/RenderObject.cpp:
24344        (WebCore::RenderObject::locateFlowThreadContainingBlockNoCache):
24345        (WebCore::RenderObject::locateFlowThreadContainingBlock):
24346        * rendering/RenderObject.h:
24347
243482014-05-16  Martin Hock  <mhock@apple.com>
24349
24350        MemoryCache::addImageToCache should return the result of add().
24351        https://bugs.webkit.org/show_bug.cgi?id=132928
24352        <rdar://problem/16651547>
24353
24354        Reviewed by Alexey Proskuryakov.
24355
24356        API test: WebKit1.MemoryCacheADdImageToCache (MemoryCacheAddImageToCacheIOS.mm)
24357
24358        * loader/cache/MemoryCache.cpp:
24359        (WebCore::MemoryCache::addImageToCache):
24360
243612014-05-16  Andrei Bucur  <abucur@adobe.com>
24362
24363        [CSS Regions] Reduce the RenderRegion invasiveness in rendering code
24364        https://bugs.webkit.org/show_bug.cgi?id=132121
24365
24366        Reviewed by Antti Koivisto.
24367
24368        Remove the RenderRegion / RenderNamedFlowFragment parameters and fields from
24369        the painting / hit testing data structures and use a stateful approach to
24370        correctly handle regions.
24371
24372        When painting or hit testing, the current flow thread is saved along the current
24373        region. They are accessed through the |currentRenderNamedFlowFragment| helper
24374        method on RenderObject or RenderLayer.
24375
24376        The patch also changes a bunch of 0s to nullptrs.
24377
24378        Tests: No new tests, no functional change.
24379
24380        * html/shadow/MediaControlElements.cpp:
24381        (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
24382        * rendering/HitTestLocation.cpp:
24383        (WebCore::HitTestLocation::HitTestLocation):
24384        (WebCore::HitTestLocation::operator=):
24385        * rendering/HitTestLocation.h:
24386        (WebCore::HitTestLocation::region): Deleted.
24387        * rendering/HitTestResult.h:
24388        * rendering/PaintInfo.h:
24389        (WebCore::PaintInfo::PaintInfo):
24390        * rendering/RenderBlock.cpp:
24391        (WebCore::RenderBlock::paint):
24392        (WebCore::RenderBlock::paintObject):
24393        (WebCore::RenderBlock::selectionGaps):
24394        (WebCore::RenderBlock::nodeAtPoint):
24395        * rendering/RenderBox.cpp:
24396        (WebCore::RenderBox::nodeAtPoint):
24397        (WebCore::RenderBox::paintBoxDecorations):
24398        (WebCore::RenderBox::pushContentsClip):
24399        * rendering/RenderBoxModelObject.cpp:
24400        (WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
24401        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
24402        * rendering/RenderBoxModelObject.h:
24403        * rendering/RenderLayer.cpp:
24404        (WebCore::RenderLayer::paint):
24405        (WebCore::RenderLayer::paintLayer):
24406        (WebCore::RenderLayer::paintLayerContents):
24407        (WebCore::RenderLayer::paintLayerByApplyingTransform):
24408        (WebCore::RenderLayer::collectFragments):
24409        (WebCore::RenderLayer::updatePaintingInfoForFragments):
24410        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
24411        (WebCore::RenderLayer::paintBackgroundForFragments):
24412        (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
24413        (WebCore::RenderLayer::paintOutlineForFragments):
24414        (WebCore::RenderLayer::paintMaskForFragments):
24415        (WebCore::RenderLayer::hitTest):
24416        (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
24417        (WebCore::RenderLayer::hitTestLayer):
24418        (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
24419        (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
24420        (WebCore::RenderLayer::calculateClipRects):
24421        * rendering/RenderLayer.h:
24422        * rendering/RenderLayerBacking.cpp:
24423        (WebCore::RenderLayerBacking::updateCompositedBounds):
24424        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
24425        * rendering/RenderLayerCompositor.cpp:
24426        (WebCore::RenderLayerCompositor::addToOverlapMap):
24427        (WebCore::RenderLayerCompositor::clippedByAncestor):
24428        * rendering/RenderObject.cpp:
24429        (WebCore::RenderObject::currentRenderNamedFlowFragment):
24430        * rendering/RenderObject.h:
24431        * rendering/RenderReplaced.cpp:
24432        (WebCore::RenderReplaced::shouldPaint):
24433        * rendering/RenderReplica.cpp:
24434        (WebCore::RenderReplica::paint):
24435        * rendering/RenderTable.cpp:
24436        (WebCore::RenderTable::nodeAtPoint):
24437        * rendering/RenderTableSection.cpp:
24438        (WebCore::RenderTableSection::nodeAtPoint):
24439        * rendering/RenderTreeAsText.cpp:
24440        (WebCore::writeLayers):
24441        * rendering/RootInlineBox.cpp:
24442        (WebCore::RootInlineBox::paint):
24443        * rendering/svg/RenderSVGRoot.cpp:
24444        (WebCore::RenderSVGRoot::paintReplaced):
24445
244462014-05-16  Kiran  <kiran.guduru@samsung.com>
24447
24448        RTCDtmfSender default values need to be updated.
24449        https://bugs.webkit.org/show_bug.cgi?id=132952
24450
24451        Reviewed by Eric Carlson.
24452
24453        The default ToneDuration and ToneGap values are modified in the updated spec.
24454        So these values need to be updated.
24455
24456        Test: fast/mediastream/RTCPeerConnection-dtmf.html.
24457
24458        * Modules/mediastream/RTCDTMFSender.cpp:
24459
244602014-05-15  Daniel Bates  <dabates@apple.com>
24461
24462        Attempt to fix the Apple Mavericks Release, Apple MountainLion Release,
24463        Apple MountainLion Release (32-bit Build), EFL, and GTK builds following
24464        <http://trac.webkit.org/changeset/168921> (https://bugs.webkit.org/show_bug.cgi?id=132669)
24465
24466        * dom/ContainerNode.cpp: Include SVGElement.h for the definition of Node::hasTagName(const SVGQualifiedName&).
24467
244682014-05-15  Daniel Bates  <dabates@apple.com>
24469
24470        ASSERT_NOT_REACHED() in DocumentOrderedMap::get() when removing SVG subtree
24471        https://bugs.webkit.org/show_bug.cgi?id=132669
24472        <rdar://problem/14931432>
24473
24474        Reviewed by Brent Fulgham and Ryosuke Niwa.
24475
24476        Fixes an assertion failure when removing an SVG element with a duplicate id.
24477
24478        When removing an SVG element with id A we synchronously instruct each element that references A
24479        to find the first element with id A, call this N, from the document root and register itself to
24480        either receive subsequent notifications from N (say, there is another element with id A) or as
24481        waiting for an element with id A (say, N = nullptr; => we removed the last element with id A from
24482        the document). Because the elements that reference A perform this operation synchronously when
24483        removing an element they consult an transient state of the DocumentOrderedMap when querying for the
24484        element with id A.
24485    
24486        Without loss of generality, let E, E_1, E_2, and E_3 be elements, where E_1, E_2, E_3 are children
24487        of E in that order and E_1.id = E_2.id = A and E_3.href = #A (that is, it references an element
24488        with id A). Suppose we remove E then we remove E_1, update DocumentOrderedMap to decrement its count
24489        for id A, and notify E_3 to look for an element with id A. This leads to an assertion failure since
24490        DocumentOrderedMap expects to find an element with id A, E_2, but cannot find such an element when
24491        traversing from the document root because E was unlinked from the document root (i.e. E_2 is in a
24492        disjoint subtree).
24493
24494        Tests: svg/custom/change-id-of-use-during-removal.html
24495               svg/custom/remove-subtree-including-path-with-duplicate-id-referenced-by-later-textpath.html
24496               svg/custom/remove-subtree-including-text-with-duplicate-id-referenced-by-later-tref.html
24497               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-earlier-use.html
24498               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-animate.html
24499               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-feimage.html
24500               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-mpath.html
24501               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-use.html
24502               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-use2.html
24503               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-use-in-different-subtree.html
24504               svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-use-with-duplicate-id-in-different-subtree.html
24505               svg/custom/remove-use-with-duplicate-id-referenced-by-later-use.html
24506
24507        * dom/ContainerNode.cpp:
24508        (WebCore::ContainerNode::removeChild): Call SVGDocumentExtensions::rebuildElements() after we remove
24509        a DOM subtree so that applicable SVG elements can update their referenced element when the DocumentOrderedMap
24510        is in a stable-state.
24511        (WebCore::ContainerNode::removeChildren): Ditto.
24512        * svg/SVGDocumentExtensions.cpp:
24513        (WebCore::SVGDocumentExtensions::rebuildElements): Added; notifies SVG elements that their href attribute
24514        changed so that they query the DocumentOrderedMap for the element they reference by id in their href attribute.
24515        (WebCore::SVGDocumentExtensions::clearTargetDependencies): Added; Called from removing
24516        an SVG element S from the DOM. Appends all elements that reference the id of S to the end of a Vector of
24517        elements to be rebuilt (when SVGDocumentExtensions::rebuildElements() is called) and notifies these elements
24518        that have been marked to be rebuilt so that they can invalidate their state (e.g. stop animating).
24519        (WebCore::SVGDocumentExtensions::rebuildAllElementReferencesForTarget): Changed to take its argument by reference
24520        (since it's always non-null) and simplified logic to synchronously notify SVG updates that their referenced element
24521        may have changed. Calling SVGElement::svgAttributeChanged() on an element E should at most remove the dependencies
24522        of E.
24523        * svg/SVGDocumentExtensions.h:
24524        * svg/SVGElement.cpp:
24525        (WebCore::SVGElement::~SVGElement): Substitute "*this" for "this" as SVGDocumentExtensions::rebuildAllElementReferencesForTarget()
24526        now takes a reference instead of a pointer.
24527        (WebCore::SVGElement::removedFrom): Modified to call SVGDocumentExtensions::clearTargetDependencies().
24528        (WebCore::SVGElement::attributeChanged): Substitute "*this" for "this" as SVGDocumentExtensions::rebuildAllElementReferencesForTarget()
24529        now takes a reference instead of a pointer.
24530        * svg/SVGElement.h:
24531        (WebCore::SVGElement::callClearTarget): Added; calls through to private virtual SVGElement::clearTarget().
24532        (WebCore::SVGElement::clearTarget): Added.
24533        * svg/SVGTRefElement.cpp:
24534        (WebCore::SVGTRefElement::clearTarget): Added.
24535        * svg/SVGTRefElement.h:
24536        * svg/animation/SVGSMILElement.cpp:
24537        (WebCore::SVGSMILElement::clearTarget): Added.
24538        * svg/animation/SVGSMILElement.h:
24539
245402014-05-15  Simon Fraser  <simon.fraser@apple.com>
24541
24542        [iOS WK2] When zoomed, fixed elements jump at the start of a scroll, and jump back at the end.
24543        https://bugs.webkit.org/show_bug.cgi?id=132978
24544        <rdar://problem/16894428>
24545
24546        Reviewed by Benjamin Poulain.
24547
24548        This was the actual cause of the bug; r168560 changed the rect passed in here
24549        to be the customFixedPositionRect rather than the unobscured rect, but we
24550        used it to call FrameView::rectForViewportConstrainedObjects() which gave back
24551        another bogus rect. So just use the rect passed in.
24552
24553        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
24554        (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterViewportChange):
24555
245562014-05-15  Daniel Bates  <dabates@apple.com>
24557
24558        SVG element may reference arbitrary DOM element before running its insertion logic
24559        https://bugs.webkit.org/show_bug.cgi?id=132757
24560        <rdar://problem/15703817>
24561
24562        Reviewed by Ryosuke Niwa.
24563
24564        Fixes an issue where an SVG element may reference an arbitrary DOM element e before e finished being
24565        inserted in the tree.
24566
24567        Currently when an SVG element A is inserted into a document we use document.getElementById() to find the
24568        element B it references (if any). If A is inserted before B and B has the same id as a later element in
24569        the document then A can find B before B is notified that its been inserted into the document (i.e. before
24570        Element::insertedFrom() is called on B). Instead, A should call document.getElementById() only after
24571        cessation of the insertion operation that inserted it to ensure that all inserted nodes (including B)
24572        processed their insertion-specific logic.
24573
24574        Tests: svg/custom/reparent-animate-element.html
24575               svg/custom/reparent-feimage-element.html
24576               svg/custom/reparent-mpath-element.html
24577               svg/custom/reparent-textpath-element.html
24578               svg/custom/reparent-tref-element.html
24579               svg/custom/reparent-use-element.html
24580
24581        * svg/SVGFEImageElement.cpp:
24582        (WebCore::SVGFEImageElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
24583        we are called back to resolve our target element (i.e. call SVGFEImageElement::buildPendingResources())
24584        after the subtree we're in is inserted.
24585        (WebCore::SVGFEImageElement::didNotifySubtreeInsertions): Added; turns around and calls SVGFEImageElement::buildPendingResources().
24586        * svg/SVGFEImageElement.h:
24587        * svg/SVGMPathElement.cpp:
24588        (WebCore::SVGMPathElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
24589        we are called back to resolve our target element (i.e. call SVGMPathElement::buildPendingResources())
24590        after the subtree we're in is inserted.
24591        (WebCore::SVGMPathElement::didNotifySubtreeInsertions): Added; turns around and calls SVGMPathElement::buildPendingResources().
24592        * svg/SVGMPathElement.h:
24593        * svg/SVGTRefElement.cpp:
24594        (WebCore::SVGTRefElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
24595        we are called back to resolve our target element (i.e. call SVGTRefElement::buildPendingResources())
24596        after the subtree we're in is inserted.
24597        (WebCore::SVGTRefElement::didNotifySubtreeInsertions): Added; turns around and calls SVGTRefElement::buildPendingResources().
24598        * svg/SVGTRefElement.h:
24599        * svg/SVGTextPathElement.cpp:
24600        (WebCore::SVGTextPathElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
24601        we are called back to resolve our target element (i.e. call SVGTextPathElement::buildPendingResources())
24602        after the subtree we're in is inserted.
24603        (WebCore::SVGTextPathElement::didNotifySubtreeInsertions): Added; turns around and calls SVGTextPathElement::buildPendingResources().
24604        * svg/SVGTextPathElement.h:
24605        * svg/SVGUseElement.cpp:
24606        (WebCore::SVGUseElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
24607        we are called back to resolve our target element (i.e. call SVGUseElement::buildPendingResources()) after its subtree is
24608        inserted.
24609        (WebCore::SVGUseElement::didNotifySubtreeInsertions): Added; turns around and calls SVGUseElement::buildPendingResources().
24610        * svg/SVGUseElement.h:
24611        * svg/animation/SVGSMILElement.cpp:
24612        (WebCore::SVGSMILElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
24613        we are called back to resolve our target element (i.e. call SVGSMILElement::buildPendingResources())
24614        after the subtree we're in is inserted.
24615        (WebCore::SVGSMILElement::didNotifySubtreeInsertions): Added; turns around and calls SVGSMILElement::buildPendingResources().
24616        * svg/animation/SVGSMILElement.h:
24617
246182014-05-15  Mark Hahnenberg  <mhahnenberg@apple.com>
24619
24620        JSDOMWindow should not claim HasImpureGetOwnPropertySlot
24621        https://bugs.webkit.org/show_bug.cgi?id=132918
24622
24623        Reviewed by Geoffrey Garen.
24624
24625        Tests: js/cached-window-properties.html
24626               js/cached-window-prototype-properties.html
24627
24628        We now correctly handle the impurity of JSDOMWindow's custom getOwnPropertySlot without needing the 
24629        blanket HasImpureGetOwnPropertySlot. We do this through the use of watchpoints and by explicitly forbidding
24630        any caching beyond a certain point using PropertySlot::disableCaching. Getting rid of this flag will allow 
24631        us to cache many properties/methods on both the JSDOMWindow and its prototype, which are very commonly used 
24632        across the web.
24633
24634        * bindings/js/JSDOMWindowCustom.cpp:
24635        (WebCore::JSDOMWindow::getOwnPropertySlot):
24636        * bindings/scripts/CodeGeneratorJS.pm:
24637        (HasComplexGetOwnProperty):
24638        (InterfaceRequiresAttributesOnInstance):
24639        (InstanceOverridesGetOwnPropertySlot):
24640        (GenerateHeader):
24641
246422014-05-15  Alexey Proskuryakov  <ap@apple.com>
24643
24644        NetworkProcess crashes at ResourceHandle::continueDidReceiveResponse
24645        https://bugs.webkit.org/show_bug.cgi?id=132966
24646        <rdar://problem/16373694>
24647
24648        Reviewed by Brady Eidson.
24649
24650        Covered by many fast/files tests.
24651
24652        * platform/network/BlobResourceHandle.cpp: (WebCore::BlobResourceHandle::continueDidReceiveResponse):
24653        * platform/network/BlobResourceHandle.h:
24654        * platform/network/ResourceHandle.h:
24655        Don't call delegate's continueDidReceiveResponse when loading a blob:// URL,
24656        the delegate is null. On the Mac, we used to lazily create it, which was also wrong,
24657        but at least not observable.
24658
246592014-05-15  Commit Queue  <commit-queue@webkit.org>
24660
24661        Unreviewed, rolling out r168899.
24662        https://bugs.webkit.org/show_bug.cgi?id=132965
24663
24664        Broke some compositing regions tests on Mavericks (Requested
24665        by mihnea___ on #webkit).
24666
24667        Reverted changeset:
24668
24669        "[CSS Regions] Reduce the RenderRegion invasiveness in
24670        rendering code"
24671        https://bugs.webkit.org/show_bug.cgi?id=132121
24672        http://trac.webkit.org/changeset/168899
24673
246742014-05-15  Alex Christensen  <achristensen@webkit.org>
24675
24676        Add pointer lock to features without enabling it.
24677        https://bugs.webkit.org/show_bug.cgi?id=132961
24678
24679        Reviewed by Sam Weinig.
24680
24681        * Configurations/FeatureDefines.xcconfig:
24682        Added ENABLE_POINTER_LOCK to list of features.
24683        * WebCore.exp.in:
24684        Added linker symbols which differ with pointer lock enabled.
24685        * WebCore.xcodeproj/project.pbxproj:
24686        Added PointerLockController.cpp to build.
24687
246882014-05-15  Mark Hahnenberg  <mhahnenberg@apple.com>
24689
24690        Move subframe name getter lookup later in JSDOMWindow::getOwnPropertySlot
24691        https://bugs.webkit.org/show_bug.cgi?id=132922
24692
24693        Reviewed by Geoffrey Garen.
24694
24695        No new tests.
24696
24697        In JSDOMWindow::getOwnPropertySlot, we currently look for the property on the JSDOMWindow, 
24698        then we search the window's subframes for name getters, then we look in the window's prototype 
24699        chain. Apparently we were doing the lookup in this order to be compatible with Mozilla, but 
24700        Mozilla no longer implements this behavior. Instead, they do the lookup on the prototype before 
24701        looking for subframe name getters. We should change this to match Mozilla. This has the convenient 
24702        side effect of allowing us to cache lookups in the window's prototype chain.
24703
24704        * bindings/js/JSDOMWindowCustom.cpp:
24705        (WebCore::JSDOMWindow::getOwnPropertySlot):
24706
247072014-05-15  Simon Fraser  <simon.fraser@apple.com>
24708
24709        [UI-side compositing] Fix copying animations between layers, and pausing them
24710        https://bugs.webkit.org/show_bug.cgi?id=132943
24711        <rdar://problem/16906369&16906541>
24712
24713        Reviewed by Tim Horton.
24714
24715        Pass the animation key back to animationStarted(), though this isn't used
24716        when animations are running in-process.
24717
24718        * platform/graphics/ca/PlatformCALayer.h:
24719        * platform/graphics/ca/mac/PlatformCALayerMac.h:
24720        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
24721        (-[WebAnimationDelegate animationDidStart:]):
24722        (PlatformCALayerMac::animationStarted):
24723        * platform/graphics/ca/win/PlatformCALayerWin.cpp:
24724        (PlatformCALayerWin::animationStarted):
24725        * platform/graphics/ca/win/PlatformCALayerWin.h:
24726
247272014-05-15  Andrei Bucur  <abucur@adobe.com>
24728
24729        [CSS Regions] Reduce the RenderRegion invasiveness in rendering code
24730        https://bugs.webkit.org/show_bug.cgi?id=132121
24731
24732        Reviewed by Antti Koivisto.
24733
24734        Remove the RenderRegion / RenderNamedFlowFragment parameters and fields from
24735        the painting / hit testing data structures and use a stateful approach to
24736        correctly handle regions.
24737
24738        When painting or hit testing, the current flow thread is saved along the current
24739        region. They are accessed through the |currentRenderNamedFlowFragment| helper
24740        method on RenderObject or RenderLayer.
24741
24742        The patch also changes a bunch of 0s to nullptrs.
24743
24744        Tests: No new tests, no functional change.
24745
24746        * html/shadow/MediaControlElements.cpp:
24747        (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
24748        * rendering/HitTestLocation.cpp:
24749        (WebCore::HitTestLocation::HitTestLocation):
24750        (WebCore::HitTestLocation::operator=):
24751        * rendering/HitTestLocation.h:
24752        (WebCore::HitTestLocation::region): Deleted.
24753        * rendering/HitTestResult.h:
24754        * rendering/PaintInfo.h:
24755        (WebCore::PaintInfo::PaintInfo):
24756        * rendering/RenderBlock.cpp:
24757        (WebCore::RenderBlock::paint):
24758        (WebCore::RenderBlock::paintObject):
24759        (WebCore::RenderBlock::selectionGaps):
24760        (WebCore::RenderBlock::nodeAtPoint):
24761        * rendering/RenderBox.cpp:
24762        (WebCore::RenderBox::nodeAtPoint):
24763        (WebCore::RenderBox::paintBoxDecorations):
24764        (WebCore::RenderBox::pushContentsClip):
24765        * rendering/RenderBoxModelObject.cpp:
24766        (WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
24767        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
24768        * rendering/RenderBoxModelObject.h:
24769        * rendering/RenderLayer.cpp:
24770        (WebCore::RenderLayer::paint):
24771        (WebCore::RenderLayer::paintLayer):
24772        (WebCore::RenderLayer::paintLayerContents):
24773        (WebCore::RenderLayer::paintLayerByApplyingTransform):
24774        (WebCore::RenderLayer::collectFragments):
24775        (WebCore::RenderLayer::updatePaintingInfoForFragments):
24776        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
24777        (WebCore::RenderLayer::paintBackgroundForFragments):
24778        (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
24779        (WebCore::RenderLayer::paintOutlineForFragments):
24780        (WebCore::RenderLayer::paintMaskForFragments):
24781        (WebCore::RenderLayer::hitTest):
24782        (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
24783        (WebCore::RenderLayer::hitTestLayer):
24784        (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
24785        (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
24786        (WebCore::RenderLayer::calculateClipRects):
24787        * rendering/RenderLayer.h:
24788        * rendering/RenderLayerBacking.cpp:
24789        (WebCore::RenderLayerBacking::updateCompositedBounds):
24790        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
24791        * rendering/RenderLayerCompositor.cpp:
24792        (WebCore::RenderLayerCompositor::addToOverlapMap):
24793        (WebCore::RenderLayerCompositor::clippedByAncestor):
24794        * rendering/RenderObject.cpp:
24795        (WebCore::RenderObject::currentRenderNamedFlowFragment):
24796        * rendering/RenderObject.h:
24797        * rendering/RenderReplaced.cpp:
24798        (WebCore::RenderReplaced::shouldPaint):
24799        * rendering/RenderReplica.cpp:
24800        (WebCore::RenderReplica::paint):
24801        * rendering/RenderTable.cpp:
24802        (WebCore::RenderTable::nodeAtPoint):
24803        * rendering/RenderTableSection.cpp:
24804        (WebCore::RenderTableSection::nodeAtPoint):
24805        * rendering/RenderTreeAsText.cpp:
24806        (WebCore::writeLayers):
24807        * rendering/RootInlineBox.cpp:
24808        (WebCore::RootInlineBox::paint):
24809        * rendering/svg/RenderSVGRoot.cpp:
24810        (WebCore::RenderSVGRoot::paintReplaced):
24811
248122014-05-14  Simon Fraser  <simon.fraser@apple.com>
24813
24814        Clean up "has non-zero begin time" terminology in animations
24815        https://bugs.webkit.org/show_bug.cgi?id=132942
24816
24817        Reviewed by Tim Horton.
24818
24819        Change the "non-zero beginTime" terminology in the platform CA animations
24820        code to "explicit beginTime": this flag really means that we explicitly set
24821        the beginTime of the animation, rather than let CA set the beginTime when
24822        committing the animation. This flag is used for animations with negative
24823        delay, and when pausing.
24824        
24825        The WKNonZeroBeginTimeFlag key was spread across PlatformCALayerMac and PlatformCAAnimationMac,
24826        so hide it behind getter/setter functions.
24827        
24828        Remove lots of m_layer.get() in PlatformCAAnimationMac.
24829
24830        * platform/graphics/ca/mac/PlatformCAAnimationMac.h:
24831        * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
24832        (WebCore::hasExplicitBeginTime):
24833        (WebCore::setHasExplicitBeginTime):
24834        (PlatformCAAnimationMac::copy):
24835        (PlatformCAAnimationMac::keyPath):
24836        (PlatformCAAnimationMac::beginTime):
24837        (PlatformCAAnimationMac::setBeginTime):
24838        (PlatformCAAnimationMac::duration):
24839        (PlatformCAAnimationMac::setDuration):
24840        (PlatformCAAnimationMac::speed):
24841        (PlatformCAAnimationMac::setSpeed):
24842        (PlatformCAAnimationMac::timeOffset):
24843        (PlatformCAAnimationMac::setTimeOffset):
24844        (PlatformCAAnimationMac::repeatCount):
24845        (PlatformCAAnimationMac::setRepeatCount):
24846        (PlatformCAAnimationMac::autoreverses):
24847        (PlatformCAAnimationMac::setAutoreverses):
24848        (PlatformCAAnimationMac::fillMode):
24849        (PlatformCAAnimationMac::setFillMode):
24850        (PlatformCAAnimationMac::setTimingFunction):
24851        (PlatformCAAnimationMac::copyTimingFunctionFrom):
24852        (PlatformCAAnimationMac::isRemovedOnCompletion):
24853        (PlatformCAAnimationMac::setRemovedOnCompletion):
24854        (PlatformCAAnimationMac::isAdditive):
24855        (PlatformCAAnimationMac::setAdditive):
24856        (PlatformCAAnimationMac::valueFunction):
24857        (PlatformCAAnimationMac::setValueFunction):
24858        (hasNonZeroBeginTimeFlag): Deleted.
24859        (setNonZeroBeginTimeFlag): Deleted.
24860        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
24861        (-[WebAnimationDelegate animationDidStart:]):
24862
248632014-05-15  Carlos Garcia Campos  <cgarcia@igalia.com>
24864
24865        [GTK] Compile all installed resources as GResources
24866        https://bugs.webkit.org/show_bug.cgi?id=131099
24867
24868        Reviewed by Philippe Normand.
24869
24870        * PlatformGTK.cmake: Do not install the resources.
24871        * platform/audio/gtk/AudioBusGtk.cpp:
24872        (WebCore::AudioBus::loadPlatformResource): Load the audio resource
24873        from GResources and use createBusFromInMemoryAudioFile().
24874        * platform/graphics/Image.h: Remove unsued function loadPlatformThemeIcon.
24875        * platform/graphics/gtk/ImageGtk.cpp:
24876        (WebCore::loadImageFromGResource): Load the given icon name from GResources.
24877        (WebCore::loadResourceSharedBuffer): Use char* instead of CString.
24878        (WebCore::loadMissingImageIconFromTheme): Try to load the missing
24879        icon from the current GTK icon theme.
24880        (WebCore::Image::loadPlatformResource): Call
24881        loadMissingImageIconFromTheme for missing icon or
24882        loadImageFromGResource for any other icon name.
24883        (WebCore::getPathToImageResource): Deleted.
24884        (WebCore::getThemeIconFileName): Deleted.
24885        (WebCore::loadImageFromFile): Deleted.
24886        (WebCore::Image::loadPlatformThemeIcon): Deleted.
24887
248882014-05-14  Beth Dakin  <bdakin@apple.com>
24889
24890        Tiled scrolling indicator needs to take topContentInset into account
24891        https://bugs.webkit.org/show_bug.cgi?id=132940
24892
24893        Reviewed by Simon Fraser.
24894
24895        The tiled scrolling indicator needs to move down by the value of the 
24896        topContentInset. This patch makes that happen by caching the topContentInset in 
24897        the TileController. This does feel a little silly since there is already a 
24898        function called setTiledScrollingIndicatorPosition() on TiledBacking. However, it 
24899        was often the case that calling that function had no effect because m_coverageMap 
24900        had not yet been created, and then the information was lost. So instead, we cache 
24901        the value.
24902
24903        Set TiledBacking’s copy of topContentInset whenever it changes for the FrameView.
24904        * page/FrameView.cpp:
24905        (WebCore::FrameView::topContentInsetDidChange):
24906
24907        New function to set the inset. Use the inset to position the coverage map.
24908        * platform/graphics/TiledBacking.h:
24909        * platform/graphics/ca/mac/TileController.h:
24910        * platform/graphics/ca/mac/TileController.mm:
24911        (WebCore::TileController::TileController):
24912        (WebCore::TileController::setTopContentInset):
24913
24914        When the coverage map is created, consult the value of the inset.
24915        * platform/graphics/ca/mac/TileCoverageMap.mm:
24916        (WebCore::TileCoverageMap::TileCoverageMap):
24917
24918        Once the backing has been ensured, set the inset.
24919        * rendering/RenderLayerCompositor.cpp:
24920        (WebCore::RenderLayerCompositor::updateBacking):
24921
249222014-05-14  Brent Fulgham  <bfulgham@apple.com>
24923
24924        Merge r1267628 from branch.
24925        <rdar://problem/15751219>
24926
24927            Pratik Solanki  <psolanki@apple.com>
24928
24929            Reviewed by Simon Fraser.",
24930
24931            TileController relied on the tiling mode in TileCache to determine if it should use low-res
24932            tiles when zooming. Unfortunately, sometimes the tiling mode gets set to Zooming even though
24933            it's actually a pan. Thus we can end up with blurry tiles. Fix this by adding a new flag on
24934            TileCache that controls this behavior and have UIKit set it only when we have an actual zoom
24935            operation.
24936 
24937        * platform/ios/LegacyTileCache.h:
24938        (WebCore::LegacyTileCache::tileControllerShouldUseLowScaleTiles):
24939        (WebCore::LegacyTileCache::setTileControllerShouldUseLowScaleTiles):
24940        * platform/ios/LegacyTileCache.mm:
24941        (WebCore::LegacyTileCache::LegacyTileCache):
24942        * platform/ios/wak/WAKWindow.h:
24943        * platform/ios/wak/WAKWindow.mm:
24944        (-[WAKWindow setTileControllerShouldUseLowScaleTiles:]):
24945        * rendering/RenderLayerCompositor.cpp:
24946        (WebCore::RenderLayerCompositor::contentsScaleMultiplierForNewTiles):
24947
249482014-05-14  Commit Queue  <commit-queue@webkit.org>
24949
24950        Unreviewed, rolling out r168750.
24951        https://bugs.webkit.org/show_bug.cgi?id=132935
24952
24953        Caused repaint bugs (Requested by weinig on #webkit).
24954
24955        Reverted changeset:
24956
24957        "Text decorations do not contribute to visual overflow"
24958        https://bugs.webkit.org/show_bug.cgi?id=132773
24959        http://trac.webkit.org/changeset/168750
24960
249612014-05-14  Simon Fraser  <simon.fraser@apple.com>
24962
24963        [New multicolumn] Spin in RenderMultiColumnSet::repaintFlowThreadContent()
24964        https://bugs.webkit.org/show_bug.cgi?id=132884
24965
24966        Reviewed by Beth Dakin.
24967
24968        On iOS, wikipedia pages can hang under RenderMultiColumnSet::repaintFlowThreadContent().
24969        It appears that computedColumnHeight is set to 0 in prepareForLayout, but layout never happens
24970        on the RenderMultiColumnSet in some cases, leaving the column height set to zero.
24971        This caused columnIndexAtOffset() to return bad values, which resulted in very long loops
24972        in repaintFlowThreadContent().
24973        
24974        This fix is a stop-gap.
24975
24976        * rendering/RenderMultiColumnSet.cpp:
24977        (WebCore::RenderMultiColumnSet::columnIndexAtOffset):
24978
249792014-05-14  Benjamin Poulain  <bpoulain@apple.com>
24980
24981        Remove FrameView::viewportConstrainedExtentRect, it is unused
24982        https://bugs.webkit.org/show_bug.cgi?id=132927
24983
24984        Reviewed by Simon Fraser.
24985
24986        * page/FrameView.cpp:
24987        (WebCore::FrameView::viewportConstrainedExtentRect): Deleted.
24988        * page/FrameView.h:
24989        Simon replaced this by viewportConstrainedVisibleContentRect, remove the old code.
24990
249912014-05-14  Matthew Hanson  <matthew_hanson@apple.com>
24992
24993        Only define MAX_GRID_TRACK_REPETITIONS if CSS_GRID_LAYOUT is enabled.
24994
24995        Reviewed by Dean Jackson.
24996
24997        This was causing -Wunused-const-variable errors.
24998
24999        * css/CSSParser.cpp: Add include guard.
25000
250012014-05-14  Beth Dakin  <bdakin@apple.com>
25002
25003        Tile cache has way too many tiles when pinch-zoomed in
25004        https://bugs.webkit.org/show_bug.cgi?id=132929
25005        -and corresponding-
25006        <rdar://problem/16527172>
25007
25008        Reviewed by Benjamin Poulain.
25009
25010        This patch makes the margin sizing functions return the set margin size scaled by 
25011        the TileGrid's scale. We also need to get rid of the old notion we used to have
25012        that margin tiles might be allowed to have a different size than the other tiles. 
25013        We don't want that. They should have the normal margin size, but they should
25014        affect the overall coverage area.
25015
25016        Scale by the TileGrid's scale.
25017        * platform/graphics/ca/mac/TileController.mm:
25018        (WebCore::TileController::topMarginHeight):
25019        (WebCore::TileController::bottomMarginHeight):
25020        (WebCore::TileController::leftMarginWidth):
25021        (WebCore::TileController::rightMarginWidth):
25022
25023        Get rid of adjustRectAtTileIndexForMargin() since we do not want to ever do this 
25024        adjustment. Use tileSize instead of margin size for all sizing computations.
25025        * platform/graphics/ca/mac/TileGrid.h:
25026        * platform/graphics/ca/mac/TileGrid.mm:
25027        (WebCore::TileGrid::rectForTileIndex):
25028        (WebCore::TileGrid::getTileIndexRangeForRect):
25029        (WebCore::TileGrid::adjustRectAtTileIndexForMargin): Deleted.
25030
250312014-05-14  Dean Jackson  <dino@apple.com>
25032
25033        [Mac] Search fields should not use centered look
25034        https://bugs.webkit.org/show_bug.cgi?id=132930
25035        <rdar://problem/16825842>
25036
25037        Reviewed by Beth Dakin.
25038
25039        We need to explicitly set the centeredLook property
25040        to NO on modern releases of Mac.
25041
25042        * rendering/RenderThemeMac.mm: Declare a new private property and set it to NO.
25043        (WebCore::RenderThemeMac::search):
25044
250452014-05-14  Zalan Bujtas  <zalan@apple.com>
25046
25047        Subpixel layout: Change Element.offset* client* scroll* return type to double.
25048        https://bugs.webkit.org/show_bug.cgi?id=132895
25049
25050        Reviewed by Simon Fraser.
25051
25052        This patch changes Element.offset*, Element.client* and Element.scroll* APIs return
25053        type from long to double to match the latest CSSOM View Module spec[1].
25054        Element.offset* and Element.client* do return subpixel values from now on.
25055        Element.scroll* still return integral values as the scrolling code hasn't adopted to subpixel rendering yet.
25056
25057        subpixelCSSOMElementMetricsEnabled setting is added to be able to turn this feature on/off
25058        from WK2 preferences. It toggles the return value from subpixel to floored integral.
25059        It does not change layout/rendering behavior.
25060
25061        Reference list of what other browsers do:
25062        IE: http://blogs.msdn.com/b/ie/archive/2012/02/17/sub-pixel-rendering-and-the-css-object-model.aspx
25063        Blink: http://www.chromestatus.com/features/5497402177880064
25064        Firefox: https://bugzilla.mozilla.org/show_bug.cgi?id=825607
25065
25066        [1] http://www.w3.org/TR/2013/WD-cssom-view-20131217/
25067
25068        Test: cssom/subpixel-offsetleft-top-width-height-values.html
25069
25070        * dom/Element.cpp:
25071        (WebCore::localZoomForRenderer):
25072        (WebCore::adjustForLocalZoom):
25073        (WebCore::convertToNonSubpixelValueIfNeeded):
25074        (WebCore::Element::offsetLeft):
25075        (WebCore::Element::offsetTop):
25076        (WebCore::Element::offsetWidth):
25077        (WebCore::Element::offsetHeight):
25078        (WebCore::Element::clientLeft):
25079        (WebCore::Element::clientTop):
25080        (WebCore::Element::clientWidth):
25081        (WebCore::Element::clientHeight):
25082        (WebCore::Element::scrollLeft):
25083        (WebCore::Element::scrollTop):
25084        (WebCore::Element::setScrollLeft):
25085        (WebCore::Element::setScrollTop):
25086        (WebCore::Element::scrollWidth):
25087        (WebCore::Element::scrollHeight):
25088        * dom/Element.h:
25089        * dom/Element.idl:
25090        * html/HTMLBodyElement.cpp:
25091        (WebCore::adjustForZoom):
25092        (WebCore::HTMLBodyElement::scrollLeft):
25093        (WebCore::HTMLBodyElement::setScrollLeft):
25094        (WebCore::HTMLBodyElement::scrollTop):
25095        (WebCore::HTMLBodyElement::setScrollTop):
25096        (WebCore::HTMLBodyElement::scrollHeight):
25097        (WebCore::HTMLBodyElement::scrollWidth):
25098        * html/HTMLBodyElement.h:
25099        * page/Settings.in:
25100
251012014-05-14  Brady Eidson  <beidson@apple.com>
25102
25103        Implement NSSharingServiceDelegate method "transitionImageForShareItem"
25104        <rdar://problem/16878020> and https://bugs.webkit.org/show_bug.cgi?id=132911
25105
25106        Reviewed by Tim Horton.
25107
25108        * WebCore.exp.in:
25109        * WebCore.xcodeproj/project.pbxproj:
25110
251112014-05-14  Alex Christensen  <achristensen@webkit.org>
25112
25113        Another unreviewed build fix.
25114
25115        * platform/network/mac/ResourceHandleMac.mm:
25116        (WebCore::ResourceHandle::getTimingData):
25117        Added necessary UNUSED_PARAMs.
25118
251192014-05-14  Alex Christensen  <achristensen@webkit.org>
25120
25121        Unreviewed build fix after r168849.
25122
25123        * platform/network/mac/ResourceHandleMac.mm:
25124        (WebCore::ResourceHandle::getTimingData):
25125        Protect use of timing data with ENABLE(WEB_TIMING).
25126
251272014-05-14  Alex Christensen  <achristensen@webkit.org>
25128
25129        Refactor duplicate code in web timing.
25130        https://bugs.webkit.org/show_bug.cgi?id=132917
25131
25132        Reviewed by Alexey Proskuryakov.
25133
25134        * platform/network/ResourceHandle.h:
25135        Added getTimingData declaration.
25136        * platform/network/mac/ResourceHandleMac.mm:
25137        (WebCore::ResourceHandle::getTimingData):
25138        * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
25139        (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
25140        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
25141        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
25142        Moved duplicate code to ResourceHandle.
25143
251442014-05-14  Alex Christensen  <achristensen@webkit.org>
25145
25146        Use references instead of pointers with ResourceLoadTiming.
25147        https://bugs.webkit.org/show_bug.cgi?id=132846
25148
25149        Reviewed by Alexey Proskuryakov.
25150
25151        * WebCore.exp.in:
25152        Removed ResourceResponseBase::setResourceLoadTiming linker symbol.
25153        * inspector/InspectorResourceAgent.cpp:
25154        (WebCore::buildObjectForResourceResponse):
25155        * page/PerformanceResourceTiming.cpp:
25156        (WebCore::PerformanceResourceTiming::domainLookupStart):
25157        (WebCore::PerformanceResourceTiming::domainLookupEnd):
25158        (WebCore::PerformanceResourceTiming::connectStart):
25159        (WebCore::PerformanceResourceTiming::connectEnd):
25160        (WebCore::PerformanceResourceTiming::secureConnectionStart):
25161        (WebCore::PerformanceResourceTiming::requestStart):
25162        Use references instead of pointers.
25163        * page/PerformanceResourceTiming.h:
25164        Make an instance instead of a RefPtr.
25165        * page/PerformanceTiming.cpp:
25166        (WebCore::PerformanceTiming::domainLookupStart):
25167        (WebCore::PerformanceTiming::domainLookupEnd):
25168        (WebCore::PerformanceTiming::connectStart):
25169        (WebCore::PerformanceTiming::connectEnd):
25170        (WebCore::PerformanceTiming::secureConnectionStart):
25171        (WebCore::PerformanceTiming::requestStart):
25172        (WebCore::PerformanceTiming::responseStart):
25173        Check to see if the loader exists, then use ResourceLoadTiming reference.
25174        (WebCore::PerformanceTiming::resourceLoadTiming): Deleted.
25175        * page/PerformanceTiming.h:
25176        Removed resourceLoadTiming declaration.
25177        * platform/network/ResourceLoadTiming.h:
25178        (WebCore::ResourceLoadTiming::ResourceLoadTiming):
25179        (WebCore::ResourceLoadTiming::operator=):
25180        Replaced reference counting with copy constructors.
25181        (WebCore::ResourceLoadTiming::create): Deleted.
25182        (WebCore::ResourceLoadTiming::deepCopy): Deleted.
25183        * platform/network/ResourceResponseBase.cpp:
25184        (WebCore::ResourceResponseBase::adopt):
25185        (WebCore::ResourceResponseBase::copyData):
25186        (WebCore::ResourceResponseBase::resourceLoadTiming):
25187        (WebCore::ResourceResponseBase::setResourceLoadTiming):
25188        (WebCore::ResourceResponseBase::compare):
25189        * platform/network/ResourceResponseBase.h:
25190        * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
25191        (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
25192        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
25193        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
25194        * platform/network/soup/ResourceHandleSoup.cpp:
25195        (WebCore::ResourceHandle::didStartRequest):
25196        (WebCore::networkEventCallback):
25197        Use references instead of pointers.
25198
251992014-05-14  Commit Queue  <commit-queue@webkit.org>
25200
25201        Unreviewed, rolling out r168837.
25202        https://bugs.webkit.org/show_bug.cgi?id=132913
25203
25204        The patch added an assertion which fires on 6 tests (Requested
25205        by ap on #webkit).
25206
25207        Reverted changeset:
25208
25209        "[CSS Regions] Add ASSERT to make sure using the flowThread
25210        cache does not return incorrect results"
25211        https://bugs.webkit.org/show_bug.cgi?id=132906
25212        http://trac.webkit.org/changeset/168837
25213
252142014-05-13  Jon Honeycutt  <jhoneycutt@apple.com>
25215
25216        Revert "Don't dispatch 'beforeload' event inside FrameView::layout()",
25217        commit 84fe8cf6fbe8b5de9a06300ca3ef6d0ffc96948c, and associated
25218        follow-up fixes:
25219
25220            "platform/mac/plugins/testplugin-onnew-onpaint.html failing after
25221                r168668", commit c17be3bf5127baf94310af4b4b9bf5a57d29aaf4
25222            "[Win] Unreviewed build fix after r168668.", commit
25223                4fa470ad12c38ee7d4c114541b6dd321181a8bc9
25224
25225        The original merged patch appears to have caused a regression in
25226        fast/dom/HTMLObjectElement/object-as-frame.html.
25227
25228        <https://bugs.webkit.org/show_bug.cgi?id=132886>
25229
25230        Reviewed by Alexey Proskuryakov.
25231
25232        * WebCore.exp.in:
25233        * dom/Document.cpp:
25234        (WebCore::Document::updateLayoutIgnorePendingStylesheets):
25235        * dom/Document.h:
25236        * html/HTMLAppletElement.cpp:
25237        (WebCore::HTMLAppletElement::renderWidgetForJSBindings):
25238        * html/HTMLEmbedElement.cpp:
25239        (WebCore::HTMLEmbedElement::renderWidgetForJSBindings):
25240        * html/HTMLObjectElement.cpp:
25241        (WebCore::HTMLObjectElement::renderWidgetForJSBindings):
25242        * page/FrameView.cpp:
25243        (WebCore::FrameView::FrameView):
25244        (WebCore::FrameView::reset):
25245        (WebCore::FrameView::flushAnyPendingPostLayoutTasks):
25246        (WebCore::FrameView::performPostLayoutTasks):
25247        (WebCore::FrameView::updateEmbeddedObjectsTimerFired): Deleted.
25248        * page/FrameView.h:
25249        * testing/Internals.cpp:
25250        (WebCore::Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks): Deleted.
25251        * testing/Internals.h:
25252        * testing/Internals.idl:
25253
252542014-05-14  Kiran  <kiran.guduru@samsung.com>
25255
25256        alidation for getUserMedia() errorCallback is missing.
25257        https://bugs.webkit.org/show_bug.cgi?id=132901
25258
25259        Reviewed by Darin Adler.
25260
25261        The patch adds the validation for getUserMedia errorCallBack
25262        and throws TypeMismatchError.
25263
25264        Test: fast/mediastream/getusermedia.html 
25265
25266        * Modules/mediastream/NavigatorUserMedia.cpp:
25267        (WebCore::NavigatorUserMedia::webkitGetUserMedia):
25268
252692014-05-14  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
25270
25271        Remove CSS_STICKY_POSITION guards
25272        https://bugs.webkit.org/show_bug.cgi?id=132676
25273
25274        Reviewed by Simon Fraser.
25275
25276        * Configurations/FeatureDefines.xcconfig:
25277        * css/CSSParser.cpp:
25278        (WebCore::isValidKeywordPropertyAndValue):
25279        * css/CSSPrimitiveValueMappings.h:
25280        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
25281        (WebCore::CSSPrimitiveValue::operator EPosition):
25282        * css/CSSValueKeywords.in:
25283        * editing/EditingStyle.cpp:
25284        (WebCore::EditingStyle::convertPositionStyle):
25285
252862014-05-14  Radu Stavila  <stavila@adobe.com>
25287
25288        [CSS Regions] Add ASSERT to make sure using the flowThread cache does not return incorrect results
25289        https://bugs.webkit.org/show_bug.cgi?id=132906
25290
25291        Reviewed by Andrei Bucur.
25292
25293        If flowThreadContainingBlock() is called on an object which is in a different
25294        flow thread than the one currently being laid out, this method will return an incorrect
25295        result. I added an assertion for that to make sure we catch and treat any such scenarios.
25296
25297        No new tests required.
25298
25299        * rendering/RenderObject.cpp:
25300        (WebCore::RenderObject::locateFlowThreadContainingBlockNoCache):
25301        (WebCore::RenderObject::locateFlowThreadContainingBlock):
25302        * rendering/RenderObject.h:
25303
253042014-05-14  Andrei Bucur  <abucur@adobe.com>
25305
25306        [CSS Regions] Don't relayout when updating the region range unless necessary
25307        https://bugs.webkit.org/show_bug.cgi?id=132120
25308
25309        Reviewed by Antti Koivisto.
25310
25311        The patch reduces the cases when a relayout is made for boxes that change the region range.
25312        This lowers the amount of nested layouts in most cases and produces big layout speedups for trees
25313        without overhanging floats.
25314
25315        Tests: Major performance improvement with speedups of 50-60% on:
25316        Layout/RegionsAuto.html, Layout/RegionsAutoMaxHeight.html and Layout/RegionsFixed.html
25317
25318        * rendering/RenderBlock.cpp:
25319        (WebCore::RenderBlock::updateRegionRangeForBoxChild): Ask the child box if it needs a relayout
25320        in case its region range changes.
25321        * rendering/RenderBlockFlow.cpp:
25322        (WebCore::RenderBlockFlow::layoutBlockChild): It's not necessary to do two layouts here because
25323        there's no block direction position change between them for the child.
25324        (WebCore::RenderBlockFlow::needsLayoutAfterRegionRangeChange): If the block doesn't have floats
25325        or if it expands to enclose the floats it doesn't need to relayout after a region range chage.
25326        It's not possible for it to have a float inside overflow that must be repositioned using the new
25327        range.
25328        * rendering/RenderBlockFlow.h:
25329        * rendering/RenderBox.h:
25330        (WebCore::RenderBox::needsLayoutAfterRegionRangeChange): By default don't relayout after a region
25331        range change.
25332
253332014-05-14  Antti Koivisto  <antti@apple.com>
25334
25335        RuleData should ref the StyleRule
25336        https://bugs.webkit.org/show_bug.cgi?id=132865
25337
25338        Reviewed by Andreas Kling.
25339
25340        As a defensive move make RuleData ref the StyleRule. 
25341        This adds some ref churn but the overall performance impact should be minimal.
25342
25343        * css/RuleSet.h:
25344        (WebCore::RuleData::rule):
25345
253462014-05-14  Antti Koivisto  <antti@apple.com>
25347
25348        GIF animations don't restart after scrolling on iOS WebKit1
25349        https://bugs.webkit.org/show_bug.cgi?id=132900
25350
25351        Reviewed by Andreas Kling.
25352
25353        * WebCore.exp.in:
25354
253552014-05-13  Andrei Bucur  <abucur@adobe.com>
25356
25357        [CSS Regions] Assertion failure in some cases with inline blocks
25358        https://bugs.webkit.org/show_bug.cgi?id=132859
25359
25360        Reviewed by Mihnea Ovidenie.
25361
25362        The patch hardens the conditions when the region range caches are
25363        populated to avoid desynchronizations when objects move during layout.
25364        This is true especially in the case of the boxes found inside
25365        inline blocks, that get their range from the containing line.
25366
25367        There is a new function |computedRegionRangeForBox| that will always
25368        return a region range for a box using a best effort algorithm. This should
25369        be used only when there's no need to cache region information.
25370
25371        This change also allows better control over the lifecycle of the
25372        |RenderBoxRegionInfo| objects stored on the regions. We can now iterate
25373        over the full range of the box when cleaning up the region box info. The
25374        same applies for the width change detection function.
25375
25376        Test: fast/regions/inline-block-shifted-region.html
25377
25378        * rendering/RenderBlockLineLayout.cpp:
25379        (WebCore::RenderBlockFlow::updateRegionForLine): Don't set the containing
25380        region if the block doesn't have a range. The returned value would not
25381        be correctly clamped.
25382        * rendering/RenderBox.cpp:
25383        (WebCore::RenderBlock::hasRegionRangeInFlowThread):
25384        * rendering/RenderBox.h:
25385        * rendering/RenderFlowThread.cpp:
25386        (WebCore::RenderFlowThread::removeRenderBoxRegionInfo): Iterate only over
25387        the range of the box, not from the start of the region chain.
25388        (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock): Same as
25389        above.
25390        (WebCore::RenderFlowThread::hasCachedRegionRangeForBox):
25391        (WebCore::RenderFlowThread::getRegionRangeForBoxFromCachedInfo):
25392        (WebCore::RenderFlowThread::getRegionRangeForBox):
25393        (WebCore::RenderFlowThread::computedRegionRangeForBox): Best effort function
25394        to determine the range of a box. It will always return something as long
25395        as the flow thread has regions.
25396        (WebCore::RenderFlowThread::objectShouldFragmentInFlowRegion): Use the new function
25397        to determine the range.
25398        * rendering/RenderFlowThread.h:
25399        * rendering/RenderNamedFlowThread.cpp:
25400        (WebCore::RenderNamedFlowThread::absoluteQuadsForBox): Use the new function to determine
25401        the range.
25402
254032014-05-13  Simon Fraser  <simon.fraser@apple.com>
25404
25405        Fix "ASSERTION FAILED: m_representation == PlatformLayerRepresentation" with UI-side compositing
25406        https://bugs.webkit.org/show_bug.cgi?id=132899
25407
25408        Reviewed by Beth Dakin.
25409
25410        Export some things
25411
25412        * WebCore.exp.in:
25413
254142014-05-13  Hans Muller  <hmuller@adobe.com>
25415
25416        [CSS Shapes] line height grows around polygon and incorrectly causes text to wrap to next line
25417        https://bugs.webkit.org/show_bug.cgi?id=131622
25418
25419        Reviewed by Bem Jones-Bey.
25420
25421        Corrected an earlier PolygonShape fix https://bugs.webkit.org/show_bug.cgi?id=132132
25422        When the top or bottom of a layout line is coincident with a polygon edge vertex, we
25423        only consider it an intersection if the edge extends into the line.
25424
25425        Test: fast/shapes/shape-outside-floats/shape-outside-edge-case.html
25426
25427        * rendering/shapes/PolygonShape.cpp:
25428        (WebCore::OffsetPolygonEdge::clippedEdgeXRange):
25429
254302014-05-13  Beth Dakin  <bdakin@apple.com>
25431
25432        m_layerForOverhangAreas is sometimes not positioned correctly when topContentInset 
25433        has changed
25434        https://bugs.webkit.org/show_bug.cgi?id=132898
25435        -and corresponding-
25436        <rdar://problem/16644710>
25437
25438        Reviewed by Anders Carlsson.
25439
25440        This function is called whenever the topContentInset changes, so use it as an 
25441        opportunity to ensure that m_layerForOverhangAreas has been positioned correctly.
25442        * rendering/RenderLayerCompositor.cpp:
25443        (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
25444
25445        Everyone gets an anchor point!
25446        (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
25447
254482014-05-13  Dean Jackson  <dino@apple.com>
25449
25450        Attempted build fix after https://bugs.webkit.org/show_bug.cgi?id=132891
25451
25452        * page/PageDebuggable.cpp:
25453
254542014-05-13  Timothy Hatcher  <timothy@apple.com>
25455
25456        Force developerExtrasEnabled when a remote Inspector client connects.
25457
25458        https://bugs.webkit.org/show_bug.cgi?id=132891
25459
25460        Reviewed by Joseph Pecoraro.
25461
25462        * page/PageDebuggable.cpp:
25463        (WebCore::PageDebuggable::PageDebuggable): Initialize m_forcedDeveloperExtrasEnabled to false.
25464        (WebCore::PageDebuggable::connect): Set m_forcedDeveloperExtrasEnabled if the setting is changed.
25465        (WebCore::PageDebuggable::disconnect): Switch developerExtrasEnabled back to false
25466        if m_forcedDeveloperExtrasEnabled is true.
25467        * page/PageDebuggable.h: Added m_forcedDeveloperExtrasEnabled.
25468
254692014-05-13  Beth Dakin  <bdakin@apple.com>
25470
25471        REGRESSION (topContentInset): Searching through Facebook Messenger's chat causes 
25472        scrolling in News Feed
25473        https://bugs.webkit.org/show_bug.cgi?id=132889
25474        -and corresponding-
25475        <rdar://problem/16715716>
25476
25477        Reviewed by Simon Fraser.
25478
25479        First of all, scrollOffsetRelativeToDocument() was very poorly named. This patch 
25480        re-names it to the much more accurate documentScrollOffsetRelativeToViewOrigin(). 
25481        Re-naming it makes it clear that ONE call site was not getting the right offset. 
25482        That call site does not want to know the document’s position relative to the view 
25483        origin, but rather it wants to know the Document’s position relative to the 
25484        scrolling origin.
25485
25486        Export new name.
25487        * WebCore.exp.in:
25488
25489        Use newly re-named documentScrollPositionRelativeToViewOrigin().
25490        * page/FrameView.cpp:
25491        (WebCore::FrameView::convertToRenderer):
25492        * platform/ScrollView.cpp:
25493        (WebCore::ScrollView::documentScrollOffsetRelativeToViewOrigin):
25494        (WebCore::ScrollView::documentScrollPositionRelativeToViewOrigin):
25495        (WebCore::ScrollView::documentScrollOffsetRelativeToScrollableAreaOrigin):
25496        (WebCore::ScrollView::rootViewToContents):
25497        (WebCore::ScrollView::windowToContents):
25498        (WebCore::ScrollView::scrollOffsetRelativeToDocument): Deleted.
25499        (WebCore::ScrollView::scrollPositionRelativeToDocument): Deleted.
25500        * platform/ScrollView.h:
25501
25502        THIS is the spot that needs the new function, 
25503        documentScrollOffsetRelativeToScrollableAreaOrigin()()
25504        * rendering/RenderLayer.cpp:
25505        (WebCore::RenderLayer::scrollRectToVisible):
25506
255072014-05-13  Dean Jackson  <dino@apple.com>
25508
25509        [iOS] Page scale update messages for media controls should only fire at the end of zooming
25510        https://bugs.webkit.org/show_bug.cgi?id=132857
25511        <rdar://problem/16631009>
25512
25513        Reviewed by Simon Fraser.
25514
25515        As the user was zooming, the media controls that responded
25516        to the page scale (and resized themselves) would do so
25517        slightly out of sync with the screen refreshes, and it looked
25518        terrible. They really only need to get told at the end
25519        of the zoom that they need to relayout.
25520
25521        Allow setPageScaleFactor to accept another parameter
25522        that indicates if the change is stable. That way, changes
25523        during a user triggers zoom gesture can be ignored for
25524        media controls.
25525
25526        * WebCore.exp.in: Page::setPageScaleFactor takes a new parameter.
25527        * dom/Document.cpp:
25528        (WebCore::Document::pageScaleFactorChangedAndStable): Renamed from pageScaleFactorChanged.
25529        (WebCore::Document::pageScaleFactorChanged): Deleted.
25530        * dom/Document.h:
25531        * page/Page.cpp:
25532        (WebCore::Page::setPageScaleFactor): Accepts a new inStableState parameter,
25533        and tells the main frame that the scale factor has changed if it's stable.
25534        * page/Page.h:
25535
255362014-05-13  Eric Carlson  <eric.carlson@apple.com>
25537
25538        Unreviewed build fix after r168755.
25539
25540        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
25541        (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive):
25542
255432014-05-13  Eric Carlson  <eric.carlson@apple.com>
25544
25545        [Mac] hasVideo should return true when video is ready to display
25546        https://bugs.webkit.org/show_bug.cgi?id=132885
25547
25548        Reviewed by Jer Noble.
25549
25550        * html/HTMLMediaElement.cpp:
25551        (WebCore::HTMLMediaElement::parseAttribute):
25552
25553        * platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm:
25554        (WebCore::AudioTrackPrivateAVFObjC::resetPropertiesFromTrack): Don't change the
25555            enabled state of the AVPlayerItemTrack during setup.
25556
25557        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
25558        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
25559        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize
25560            m_cachedIsReadyForDisplay.
25561        (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad): Remove "enabled" KVO observers.
25562        (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Observe "readyForDisplay"
25563            change notifications.
25564        (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoLayer): Remove for "readyForDisplay"
25565            observer.
25566        (WebCore::MediaPlayerPrivateAVFoundationObjC::hasAvailableVideoFrame): Return cached readyForDisplay
25567            state instead of polling every time.
25568        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Call setHasVideo(true) if the
25569            player layer is ready for display.
25570        (WebCore::MediaPlayerPrivateAVFoundationObjC::updateAudioTracks): Update logging.
25571        (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoTracks): Ditto.
25572        (WebCore::MediaPlayerPrivateAVFoundationObjC::firstFrameAvailableDidChange): Cache readyForDisplay
25573            state, call tracksChanged() if we haven't seen a video track yet.
25574        (WebCore::MediaPlayerPrivateAVFoundationObjC::trackEnabledDidChange): New.
25575        (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive): Correct logging.
25576        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksDidChange): Remove old "enabled" listeners
25577            before release tracks, add new ones to new tracks.
25578        (WebCore::assetTrackMetadataKeyNames): Add "enabled" to the list of properties we require to 
25579            be loaded before announcing that metadata has loaded.
25580        (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]): Observe 
25581            "readyForDisplay" and "enabled".
25582
25583        * platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.cpp:
25584        (WebCore::VideoTrackPrivateAVFObjC::resetPropertiesFromTrack): Don't change the
25585            enabled state of the AVPlayerItemTrack during setup.
25586
255872014-05-13  Myles C. Maxfield  <litherum@gmail.com>
25588
25589        Text decorations do not contribute to visual overflow
25590        https://bugs.webkit.org/show_bug.cgi?id=132773
25591
25592        Reviewed by Darin Adler.
25593
25594        Tests: fast/css3-text/css3-text-decoration/repaint/underline-outside-of-layout-rect.html
25595
25596        * rendering/InlineTextBox.cpp:
25597        (WebCore::textDecorationStrokeThickness): Refactor into a common function
25598        (WebCore::wavyOffsetFromDecoration): Ditto
25599        (WebCore::InlineTextBox::extendVerticalVisualOverflowForDecorations): Given
25600        vertical overflow bounds, possibly extend those to include location of
25601        decorations.
25602        (WebCore::InlineTextBox::paintDecoration): Use refactored functions.
25603        * rendering/InlineTextBox.h: Function signature
25604        * rendering/RenderBlockLineLayout.cpp:
25605        (WebCore::setLogicalWidthForTextRun): Call extendVerticalVisualOverflowForDecorations()
25606        * rendering/style/RenderStyle.cpp:
25607        (WebCore::RenderStyle::changeAffectsVisualOverflow): Inspects shadows and text decorations
25608        (WebCore::RenderStyle::changeRequiresLayout): Calls changeAffectsVisualOverflow()
25609        (WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline): Moved code from here
25610        to changeAffectsVisualOverflow().
25611        * rendering/style/RenderStyle.h: Function signature
25612
256132014-05-13  Enrica Casucci  <enrica@apple.com>
25614
25615        REGRESSION (WebKit2): Zooming to text field leaves it partially hidden by the form assistant.
25616        https://bugs.webkit.org/show_bug.cgi?id=132879
25617        <rdar://problem/16318049>
25618
25619        Reviewed by Benjamin Poulain.
25620
25621        Adding some exports. The fix to setScrollPosition is to avoid clamping the scroll
25622        position when using delegate scrolling.
25623
25624        * WebCore.exp.in:
25625        * platform/ScrollView.cpp:
25626        (WebCore::ScrollView::setScrollPosition):
25627
256282014-05-13  Brady Eidson  <beidson@apple.com>
25629
25630        Followup to: Update positioning/drawing of the image controls button.
25631        <rdar://problem/16885077> and https://bugs.webkit.org/show_bug.cgi?id=132883
25632
25633        Reviewed by Tim Horton.
25634
25635        Cleared up the actual intent behind review feedback on the original patch.
25636
25637        * html/shadow/mac/ImageControlsButtonElementMac.cpp:
25638        (WebCore::ImageControlsButtonElementMac::maybeCreate):
25639
256402014-05-13  Brady Eidson  <beidson@apple.com>
25641
25642        Update positioning/drawing of the image controls button.
25643        <rdar://problem/16885077> and https://bugs.webkit.org/show_bug.cgi?id=132883
25644
25645        Reviewed by Tim Horton.
25646
25647        * html/shadow/mac/ImageControlsButtonElementMac.cpp:
25648        (WebCore::ImageControlsButtonElementMac::maybeCreate): Add inline style for top/right
25649          positioning based on the metrics from the render theme.
25650
25651        * html/shadow/mac/imageControlsMac.css:
25652        (.x-webkit-image-controls-button): Can’t hard code any positioning.
25653
25654        * rendering/RenderTheme.h:
25655        (WebCore::RenderTheme::imageControlsButtonPositionOffset):
25656        * rendering/RenderThemeMac.h:
25657        * rendering/RenderThemeMac.mm:
25658        (WebCore::RenderThemeMac::servicesRolloverButtonCell):
25659        (WebCore::RenderThemeMac::imageControlsButtonPositionOffset):
25660
256612014-05-13  Simon Fraser  <simon.fraser@apple.com>
25662
25663        [iOS WK2] background-attachment:fixed behaves very poorly
25664        https://bugs.webkit.org/show_bug.cgi?id=132881
25665        <rdar://problem/16789526>
25666
25667        Reviewed by Beth Dakin.
25668
25669        Remove the old ENABLE_FAST_MOBILE_SCROLLING code, and add a setting that
25670        controls whether fixed backgrounds paint relative to the document, which
25671        is enabled for iOS (WK1 and WK2). This setting is consulted when we repaint
25672        fixed backgrounds on scrolling, when we paint them, and when we decide to make
25673        a layer for fixed backgrounds.
25674        
25675        * page/Settings.cpp:
25676        * page/Settings.in:
25677        * rendering/RenderBoxModelObject.cpp:
25678        (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
25679        * rendering/RenderElement.cpp:
25680        (WebCore::RenderElement::styleWillChange):
25681        (WebCore::RenderElement::willBeRemovedFromTree):
25682        (WebCore::shouldRepaintFixedBackgroundsOnScroll): Deleted.
25683        * rendering/RenderLayerCompositor.cpp:
25684        (WebCore::RenderLayerCompositor::needsFixedRootBackgroundLayer):
25685
256862014-05-13  Zalan Bujtas  <zalan@apple.com>
25687
25688        REGRESSSION(r168528) Subpixel rendering: Selection rect is not positioned properly when SVG text is selected.
25689        https://bugs.webkit.org/show_bug.cgi?id=132868
25690
25691        Reviewed by Dirk Schulze.
25692
25693        Scale the selection rect. r168528 missed applying this final transform on the selection/painting rect.
25694
25695        Test: svg/text/hidpi-text-selection-rect-position.html
25696
25697        * rendering/svg/SVGInlineTextBox.cpp:
25698        (WebCore::SVGInlineTextBox::selectionRectForTextFragment):
25699
257002014-05-13  Martin Hodovan  <mhodovan.u-szeged@partner.samsung.com>
25701
25702        ASSERTION FAILED: leftCategory != CalcOther && rightCategory != CalcOther
25703        in WebCore::CSSCalcBinaryOperation::createSimplified
25704        https://bugs.webkit.org/show_bug.cgi?id=132870
25705
25706        According to the standard, calc() should be able to handle angle, time
25707        and frequency values as well: http://www.w3.org/TR/css3-values/#calc
25708
25709        Reviewed by Darin Adler.
25710
25711        Test: fast/css/calc-with-angle-time-frequency.html
25712
25713        * css/CSSCalculationValue.cpp:
25714        (WebCore::unitCategory):
25715        (WebCore::CSSCalcPrimitiveValue::createCalcExpression):
25716        (WebCore::CSSCalcPrimitiveValue::computeLengthPx):
25717        (WebCore::CSSCalcPrimitiveValue::addSubtractResult):
25718        (WebCore::CSSCalcPrimitiveValue::determineCategory):
25719        (WebCore::CSSCalcBinaryOperation::primitiveType)
25720        * css/CSSCalculationValue.h: extending CalculationCategory
25721        * css/CSSParser.cpp:
25722        (WebCore::CSSParser::validCalculationUnit):
25723        * css/CSSPrimitiveValue.cpp:
25724        (WebCore::CSSPrimitiveValue::primitiveType):
25725
257262014-05-13  Darin Adler  <darin@apple.com>
25727
25728        Try to fix the !ENABLE(ICONDATABASE) build
25729
25730        * loader/icon/IconDatabase.h: Include WTFString.h.
25731
257322014-05-13  Carlos Garcia Campos  <cgarcia@igalia.com>
25733
25734        REGRESSION(r167771): [GTK] Text fields and areas are rendered unthemed
25735        https://bugs.webkit.org/show_bug.cgi?id=132864
25736
25737        Reviewed by Philippe Normand.
25738
25739        This is because the virtual methods changed the API in the parent,
25740        and since we don't have the methods marked as override we didn't
25741        noticed it. After using override keyword for all virtual methods
25742        in the derived class another problem showed up, the ActiveListBox
25743        selection methods were incorrectly named.
25744
25745        * platform/gtk/RenderThemeGtk.cpp:
25746        (WebCore::RenderThemeGtk::paintTextArea): Update to API changes in the
25747        parent class.
25748        * platform/gtk/RenderThemeGtk.h: Mark all virtual methods as
25749        override and the class as final.
25750        * platform/gtk/RenderThemeGtk2.cpp:
25751        (WebCore::RenderThemeGtk::paintTextField): Update to API changes
25752        in the parent class.
25753        (WebCore::RenderThemeGtk::platformActiveListBoxSelectionBackgroundColor):
25754        (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionBackgroundColor):
25755        (WebCore::RenderThemeGtk::platformActiveListBoxSelectionForegroundColor):
25756        (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionForegroundColor):
25757        (WebCore::RenderThemeGtk::activeListBoxSelectionBackgroundColor): Deleted.
25758        (WebCore::RenderThemeGtk::inactiveListBoxSelectionBackgroundColor): Deleted.
25759        (WebCore::RenderThemeGtk::activeListBoxSelectionForegroundColor): Deleted.
25760        (WebCore::RenderThemeGtk::inactiveListBoxSelectionForegroundColor): Deleted.
25761        * platform/gtk/RenderThemeGtk3.cpp:
25762        (WebCore::RenderThemeGtk::paintTextField): Update to API changes
25763        in the parent class.
25764        (WebCore::RenderThemeGtk::platformActiveListBoxSelectionBackgroundColor):
25765        (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionBackgroundColor):
25766        (WebCore::RenderThemeGtk::platformActiveListBoxSelectionForegroundColor):
25767        (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionForegroundColor):
25768        (WebCore::RenderThemeGtk::activeListBoxSelectionBackgroundColor): Deleted.
25769        (WebCore::RenderThemeGtk::inactiveListBoxSelectionBackgroundColor): Deleted.
25770        (WebCore::RenderThemeGtk::activeListBoxSelectionForegroundColor): Deleted.
25771        (WebCore::RenderThemeGtk::inactiveListBoxSelectionForegroundColor): Deleted.
25772
257732014-05-13  Xabier Rodriguez Calvar  <calvaris@igalia.com>
25774
25775        [GStreamer] Move toGstClockTime to utilities
25776        https://bugs.webkit.org/show_bug.cgi?id=132702
25777
25778        Reviewed by Philippe Normand.
25779
25780        toGstClockTime should be in GStreamerUtilities and corrected typo
25781        in getGstPlayFlag.
25782
25783        No new tests needed.
25784
25785        * platform/graphics/gstreamer/GStreamerUtilities.cpp:
25786        (WebCore::getGstPlayFlag): Renamed from getGstPlaysFlag.
25787        (WebCore::toGstClockTime): Moved from MediaPlayerPrivateGStreamer.
25788        (WebCore::getGstPlaysFlag): Deleted.
25789        * platform/graphics/gstreamer/GStreamerUtilities.h:
25790        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
25791        (WebCore::MediaPlayerPrivateGStreamer::setDownloadBuffering):
25792        Corrected getGstPlayFlag typo.
25793        (WebCore::toGstClockTime): Deleted.
25794
257952014-05-12  Darin Adler  <darin@apple.com>
25796
25797        Make a few icon database improvements
25798        https://bugs.webkit.org/show_bug.cgi?id=132812
25799
25800        Reviewed by Brady Eidson.
25801
25802        * WebCore.exp.in: Export more IconDatabase functions, since they are now called
25803        by WebKit2 through pointers to a class marked final.
25804
25805        * loader/icon/IconDatabase.cpp: Removed unneeded includes. Use override for
25806        virtual functions.
25807
25808        * loader/icon/IconDatabase.h: Removed unneeded includes. Marked the class final.
25809        Use override for virtual functions. Use a public constructor instead of a create
25810        function.
25811
25812        * loader/icon/IconDatabaseBase.h: Removed unneeded includes.
25813
258142014-05-13  Kiran  <kiran.guduru@samsung.com>
25815
25816        [MediaStream] MediaStream.addTrack Should not check for active state.
25817        https://bugs.webkit.org/show_bug.cgi?id=132558
25818
25819        Reviewed by Eric Carlson.
25820
25821        MediaStream.addTrack method is checking for active state of a
25822        MediaStream, but it should not check for active state while adding a Track.
25823
25824        Test: fast/mediastream/MediaStream-add-tracks-to-inactive-stream.html
25825
25826        * Modules/mediastream/MediaStream.cpp:
25827        (WebCore::MediaStream::addTrack):
25828
258292014-05-12  Mark Lam  <mark.lam@apple.com>
25830
25831        WebKit2 on iOS needs to capture the main thread's floating point environment.
25832        <https://webkit.org/b/132755>
25833
25834        Reviewed by Geoffrey Garen.
25835
25836        For iOS, WorkerThread::workerThread() expects to be able to initialize the
25837        worker thread's floating point environment to be the same as the one in the
25838        main thread.  The FP env of the main thread is expected to have been captured
25839        in the mainThreadFEnv global.  On WebKit2 for iOS, we neglected to initialize
25840        mainThreadFEnv.
25841
25842        We now introduce a FloatingPointEnvironment class that will encapsulate the main
25843        thread (aka "UIThread") fenv, and we'll call FloatingPointEnv::saveMainThreadEnvironment()
25844        from ChildProcess::platformInitialize() to ensure that the FloatingPointEnvironment
25845        singleton instance is initialized properly for WebKit2.
25846
25847        In the ChildProcess::platformInitialize(), we also need to initialize the ARMv7
25848        FP env to support denormalized numbers.  We'll do this before calling
25849        saveMainThreadEnvironment().
25850
25851        Tests: fast/workers/worker-floating-point.html
25852               js/floating-point-denormalized.html
25853
25854        * WebCore.exp.in:
25855        * WebCore.xcodeproj/project.pbxproj:
25856        * platform/ios/wak/FloatingPointEnvironment.cpp: Added.
25857        (WebCore::FloatingPointEnvironment::env):
25858        (WebCore::FloatingPointEnvironment::FloatingPointEnvironment):
25859        (WebCore::FloatingPointEnvironment::enableDenormalSupport):
25860        (WebCore::FloatingPointEnvironment::saveMainThreadEnvironment):
25861        (WebCore::FloatingPointEnvironment::propagateMainThreadEnvironment):
25862        * platform/ios/wak/FloatingPointEnvironment.h: Added.
25863        * platform/ios/wak/WebCoreThread.h:
25864        * platform/ios/wak/WebCoreThread.mm:
25865        (RunWebThread):
25866        (StartWebThread):
25867        * workers/WorkerThread.cpp:
25868        (WebCore::WorkerThread::workerThread):
25869
258702014-05-12  Dirk Schulze  <krit@webkit.org>
25871
25872        SVG root element accepts background color but fails to repaint it
25873        https://bugs.webkit.org/show_bug.cgi?id=63153
25874
25875        Reviewed by Dean Jackson.
25876
25877        This is back ported from Blink. Don't know the exact commit though.
25878        The patch checks if the SVGSVGElement is an outermost root element.
25879        If it is, mark the whole element for repaint.
25880
25881        Test: svg/custom/svg-root-background.html
25882
25883        * rendering/RenderBoxModelObject.cpp:
25884        (WebCore::RenderBoxModelObject::calculateHasBoxDecorations):
25885        (WebCore::RenderBoxModelObject::updateFromStyle):
25886        * rendering/RenderBoxModelObject.h:
25887        * rendering/svg/RenderSVGRoot.cpp:
25888        (WebCore::RenderSVGRoot::RenderSVGRoot):
25889        (WebCore::RenderSVGRoot::layout):
25890        (WebCore::RenderSVGRoot::paintReplaced):
25891        (WebCore::RenderSVGRoot::clippedOverflowRectForRepaint):
25892            This is a simple optimization by taking the necessary parts
25893            from RenderReplaced and SVGRenderSupport.
25894        * rendering/svg/RenderSVGRoot.h:
25895
258962014-05-12  Simon Fraser  <simon.fraser@apple.com>
25897
25898        [iOS] Fixed items are sometimes clipped after rubber-banding
25899        https://bugs.webkit.org/show_bug.cgi?id=132851
25900        <rdar://problem/16870790>
25901
25902        Reviewed by Benjamin Poulain.
25903
25904        On iOS fixed-position layers would get clipped to the document rect,
25905        but with rubber-banding, we can now have a custom fixed postion rect
25906        that extends outside the document rect.
25907        
25908        Another issue was that we would un-composite fixed elements sometimes
25909        when scrolling fast, again because they could fall outside of the document rect.
25910        
25911        A final issue was that pinching could reveal parts of fixed elements that should
25912        lie outside the viewport, rather than clipping the layers.
25913        
25914        Fix by converting both call points to use viewportConstrainedVisibleContentRect()
25915        rather than viewportConstrainedExtentRect(). On non-iOS platforms these are
25916        the same, but on iOS viewportConstrainedVisibleContentRect() uses the
25917        custom fixed position rect, which is the correct rect to intersect with.
25918
25919        * rendering/RenderLayerBacking.cpp:
25920        (WebCore::RenderLayerBacking::updateCompositedBounds):
25921        * rendering/RenderLayerCompositor.cpp:
25922        (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
25923
259242014-05-06  Jon Honeycutt  <jhoneycutt@apple.com>
25925
25926        Don't dispatch 'beforeload' event inside FrameView::layout()
25927
25928        https://bugs.webkit.org/show_bug.cgi?id=132621
25929        <rdar://problem/15661470>
25930
25931        This merges Blink revision 162073 with minor renaming and style
25932        changes. From that commit:
25933
25934        Executing JavaScript code inside FrameView::layout() is problematic.
25935        e.g. an assertion failure tested in fast/events/beforeload-assertion.html.
25936        We should avoid it.
25937
25938        This CL makes 'beforeload' event dispatching for plugins and iframes asynchronous,
25939        except plugin access from JavaScript code (HTMLPlugInElement::
25940        renderWidgetForJSBindings).
25941
25942        Reviewed by Brent Fulgham.
25943
25944        Tests: fast/events/beforeload-assertion.html
25945               fast/events/beforeload-iframe-crash.html
25946               fast/events/beforeload-input-time-crash.html
25947
25948        * WebCore.exp.in:
25949        * dom/Document.cpp:
25950        (WebCore::Document::updateLayoutIgnorePendingStylesheets):
25951        * dom/Document.h:
25952        * html/HTMLAppletElement.cpp:
25953        (WebCore::HTMLAppletElement::renderWidgetForJSBindings):
25954        * html/HTMLEmbedElement.cpp:
25955        (WebCore::HTMLEmbedElement::renderWidgetForJSBindings):
25956        * html/HTMLObjectElement.cpp:
25957        (WebCore::HTMLObjectElement::renderWidgetForJSBindings):
25958        * page/FrameView.cpp:
25959        (WebCore::FrameView::FrameView):
25960        (WebCore::FrameView::reset):
25961        (WebCore::FrameView::updateEmbeddedObjectsTimerFired):
25962        (WebCore::FrameView::flushAnyPendingPostLayoutTasks):
25963        (WebCore::FrameView::performPostLayoutTasks):
25964        * page/FrameView.h:
25965        * testing/Internals.cpp:
25966        (WebCore::Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks):
25967        * testing/Internals.h:
25968        * testing/Internals.idl:
25969
259702014-05-12  Roger Fong  <roger_fong@apple.com>
25971
25972        Limit number of active graphics contexts per web process.
25973        https://bugs.webkit.org/show_bug.cgi?id=132833.
25974        <rdar://problem/16888459>
25975
25976        Reviewed by Dean Jackson.
25977
25978        Test: webgl/many-contexts.html
25979
25980        * platform/graphics/GraphicsContext3D.h:
25981        * platform/graphics/mac/GraphicsContext3DMac.mm: Limit number of active contexts to 16.
25982        (WebCore::GraphicsContext3D::create):
25983        (WebCore::GraphicsContext3D::~GraphicsContext3D):
25984
259852014-05-12  Simon Fraser  <simon.fraser@apple.com>
25986
25987        Build fix fix.
25988
25989        * page/scrolling/ScrollingCoordinator.cpp:
25990        (WebCore::ScrollingCoordinator::contentShadowLayerForFrameView):
25991
259922014-05-12  Brent Fulgham  <bfulgham@apple.com>
25993
25994        DataDetectorUI doesn't update with resize
25995        https://bugs.webkit.org/show_bug.cgi?id=132830
25996        <rdar://problem/16871179>
25997
25998        Reviewed by Simon Fraser.
25999
26000        * editing/Editor.cpp:
26001        (WebCore::Editor::scanSelectionForTelephoneNumbers): Add public, no-argument
26002        version that can be called after layout changes.
26003        (WebCore::Editor::didLayout): Reprocess telephone number data
26004        since Ranges will have changed.
26005        * editing/Editor.h:
26006        * editing/FrameSelection.cpp:
26007        (WebCore::FrameSelection::updateDataDetectorsForSelection): Added.
26008        * editing/FrameSelection.h:
26009        * page/FrameView.cpp:
26010        (WebCore::FrameView::performPostLayoutTasks): Ask the FrameSelection to update the
26011        Range information for selected phone numbers.
26012
260132014-05-12  Simon Fraser  <simon.fraser@apple.com>
26014
26015        Fix the iOS build.
26016
26017        * page/scrolling/ScrollingCoordinator.cpp:
26018        (WebCore::ScrollingCoordinator::contentShadowLayerForFrameView):
26019
260202014-05-12  Simon Fraser  <simon.fraser@apple.com>
26021
26022        [iOS WK2] Fuzzy tiles on some sites on loading
26023        https://bugs.webkit.org/show_bug.cgi?id=132847
26024        <rdar://problem/16816178>
26025
26026        Reviewed by Benjamin Poulain.
26027
26028        Export WebCore::TileController::contentsScale() const
26029
26030        * WebCore.exp.in:
26031
260322014-05-12  Simon Fraser  <simon.fraser@apple.com>
26033
26034        Add debug dumping for ViewportConfiguration
26035        https://bugs.webkit.org/show_bug.cgi?id=132843
26036
26037        Reviewed by Benjamin Poulain.
26038
26039        Add some TextStream-based dumping for ViewportConfiguration.
26040
26041        * page/ViewportConfiguration.cpp:
26042        (WebCore::ViewportConfiguration::updateConfiguration):
26043        (WebCore::ViewportConfigurationTextStream::ViewportConfigurationTextStream):
26044        (WebCore::ViewportConfigurationTextStream::increaseIndent):
26045        (WebCore::ViewportConfigurationTextStream::decreaseIndent):
26046        (WebCore::dumpProperty):
26047        (WebCore::ViewportConfigurationTextStream::writeIndent):
26048        (WebCore::ViewportConfigurationTextStream::operator<<):
26049        (WebCore::ViewportConfiguration::description):
26050        (WebCore::ViewportConfiguration::dump):
26051        * page/ViewportConfiguration.h:
26052
260532014-05-12  Brady Eidson  <beidson@apple.com>
26054
26055        Followup to "Teach Editor to support more direct replacement of a Node"
26056        <rdar://problem/16817952> and https://bugs.webkit.org/show_bug.cgi?id=132834
26057
26058        Pair programmed and pair reviewed by Brady Eidson and Darin Adler.
26059
26060        * editing/mac/EditorMac.mm:
26061        (WebCore::maybeCopyNodeAttributesToFragment):
26062        (WebCore::Editor::replaceNodeFromPasteboard):
26063
260642014-05-12  Beth Dakin  <bdakin@apple.com>
26065
26066        Content shadow layer needs to move in sync with the content layer
26067        https://bugs.webkit.org/show_bug.cgi?id=132841
26068        -and corresponding-
26069        <rdar://problem/16641115>
26070
26071        Reviewed by Simon Fraser.
26072
26073        Now that the root content layer moves a little bit (for y scroll positions between 
26074        0 and topContentInset), the shadow layer needs to move along with it since the 
26075        shadow layer should always have the same position as the root content layer.
26076
26077        Set the root state node’s shadow layer, and update the position whenever the root 
26078        content layer’s position is updated.
26079        * page/scrolling/AsyncScrollingCoordinator.cpp:
26080        (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
26081        (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
26082
26083        Fetch the compositor’s layerForContentShadow().
26084        * page/scrolling/ScrollingCoordinator.cpp:
26085        (WebCore::ScrollingCoordinator::contentShadowLayerForFrameView):
26086        * page/scrolling/ScrollingCoordinator.h:
26087
26088        Hook up the contentShadowLayer in the state node.
26089        * page/scrolling/ScrollingStateScrollingNode.cpp:
26090        (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
26091        (WebCore::ScrollingStateScrollingNode::setContentShadowLayer):
26092
26093        Hook it up in the ScrollingTreeNode as well. Move the layer whenever the m
26094        _scrolledContentsLayer is moved.
26095        * page/scrolling/ScrollingStateScrollingNode.h:
26096        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
26097        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
26098        (WebCore::ScrollingTreeScrollingNodeMac::updateBeforeChildren):
26099        (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
26100
26101        The shadow layer needs an anchor point now that we are moving it around.
26102        * rendering/RenderLayerCompositor.cpp:
26103        (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
26104
261052014-05-12  Dirk Schulze  <krit@webkit.org>
26106
26107        <svg> with opacity and compositing double-applies its opacity
26108        https://bugs.webkit.org/show_bug.cgi?id=116856
26109
26110        Reviewed by Simon Fraser.
26111
26112        The opacity is applied by the compositor. However, all SVG elements
26113        create transparency layers on their own to apply opacity. So did
26114        SVGSVGElement.
26115
26116        Added a check if the current element has a compositing layer and skip
26117        creating transparency layer if it has.
26118
26119        Test: svg/custom/composited-svg-with-opacity.html
26120
26121        * rendering/svg/SVGRenderingContext.cpp:
26122        (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
26123
261242014-05-12  Brady Eidson  <beidson@apple.com>
26125
26126        Teach Editor to support more direct replacement of a Node
26127        <rdar://problem/16817952> and https://bugs.webkit.org/show_bug.cgi?id=132834
26128
26129        Reviewed by Enrica Casucci.
26130
26131        The new method "Editor::replaceNodeFromPasteboard" has the intent that the new DocumentFragment
26132        from the pasteboard is as similar to the old Node as possible.
26133
26134        In practice, the new DocumentFragment:
26135        1 - Can represent a single node that's missing various attributes the original Node had.
26136        2 - Can be an unwanted fragment of arbitrary depth when the replacement happens inside Mail.app
26137
26138        This fixes both of these issues.
26139
26140        Add a MailBlockquoteHandling enum class for various Editor operations to pass through to the
26141        ReplaceSelectionCommand:
26142        * editing/Editor.cpp:
26143        (WebCore::Editor::handleTextEvent):
26144        (WebCore::Editor::pasteAsFragment):
26145        (WebCore::Editor::pasteWithPasteboard):
26146        (WebCore::Editor::replaceSelectionWithFragment):
26147        * editing/Editor.h:
26148
26149        * dom/TextEvent.cpp:
26150        (WebCore::TextEvent::createForPlainTextPaste):
26151        (WebCore::TextEvent::createForFragmentPaste):
26152        (WebCore::TextEvent::TextEvent):
26153        * dom/TextEvent.h:
26154        (WebCore::TextEvent::mailBlockquoteHandling):
26155
26156        * editing/ReplaceSelectionCommand.cpp:
26157        (WebCore::ReplaceSelectionCommand::ReplaceSelectionCommand):
26158        (WebCore::ReplaceSelectionCommand::doApply): Consider whether or not this particular Editor
26159          operation was meant to give special consideration to Mail's Blockquotes.
26160        * editing/ReplaceSelectionCommand.h:
26161
26162        * editing/efl/EditorEfl.cpp:
26163        (WebCore::Editor::pasteWithPasteboard):
26164        * editing/ios/EditorIOS.mm:
26165        (WebCore::Editor::pasteWithPasteboard):
26166
26167        * editing/mac/EditorMac.mm:
26168        (WebCore::Editor::pasteWithPasteboard):
26169        (WebCore::Editor::readSelectionFromPasteboard):
26170        (WebCore::maybeCopyNodeAttributesToFragment): If the new DocumentFragment represents a single HTML node
26171          with the same tag name is the original HTML node, copy over most attributes from the original node.
26172        (WebCore::Editor::replaceNodeFromPasteboard): Create the fragment, run it through maybeCopyNodeAttributesToFragment.
26173
26174        * WebCore.exp.in:
26175
261762014-05-12  Alex Christensen  <achristensen@webkit.org>
26177
26178        Progress on web timing.
26179        https://bugs.webkit.org/show_bug.cgi?id=132574
26180
26181        Reviewed by Alexey Proskuryakov.
26182
26183        * CMakeLists.txt:
26184        Removed ResourceLoadTiming.cpp.
26185        * WebCore.exp.in:
26186        Added linker symbols for ResourceLoadTiming.
26187        * WebCore.xcodeproj/project.pbxproj:
26188        * WebCore.vcxproj/WebCore.vcxproj:
26189        * WebCore.vcxproj/WebCore.vcxproj.filters:
26190        Removed ResourceLoadTiming.cpp.
26191        * inspector/InspectorResourceAgent.cpp:
26192        (WebCore::buildObjectForTiming):
26193        * inspector/protocol/Network.json:
26194        Updated ResourceTiming structure.
26195        * loader/DocumentLoadTiming.cpp:
26196        (WebCore::DocumentLoadTiming::setNavigationStart):
26197        * loader/DocumentLoadTiming.h:
26198         Deleted unused setNavigationStart function.
26199        * page/Performance.idl:
26200        Updated spec URL.
26201        * page/PerformanceResourceTiming.cpp:
26202        (WebCore::PerformanceResourceTiming::domainLookupStart):
26203        (WebCore::PerformanceResourceTiming::domainLookupEnd):
26204        (WebCore::PerformanceResourceTiming::connectStart):
26205        (WebCore::PerformanceResourceTiming::secureConnectionStart):
26206        (WebCore::PerformanceResourceTiming::responseEnd):
26207        Updated ResourceLoadTiming member variable names.
26208        (WebCore::PerformanceResourceTiming::responseStart):
26209        * page/PerformanceResourceTiming.h:
26210        * page/PerformanceResourceTiming.idl:
26211        Deleted responseStart because it is not in the spec.
26212        * page/PerformanceTiming.cpp:
26213        (WebCore::PerformanceTiming::domainLookupStart):
26214        (WebCore::PerformanceTiming::domainLookupEnd):
26215        (WebCore::PerformanceTiming::connectStart):
26216        (WebCore::PerformanceTiming::secureConnectionStart):
26217        (WebCore::PerformanceTiming::requestStart):
26218        (WebCore::PerformanceTiming::responseStart):
26219        Updated ResourceLoadTiming member variable names.
26220        (WebCore::PerformanceTiming::resourceLoadTimeRelativeToAbsolute):
26221        Use navigationStart as base for resource load times.
26222        * page/PerformanceTiming.idl:
26223        Updated spec URL.
26224        * platform/network/HTTPParsers.h:
26225        Removed unused class declarations.
26226        * platform/network/ResourceHandle.h:
26227        Moved soup request time from ResourceLoadTiming to ResourceHandle.
26228        * platform/network/ResourceLoadTiming.cpp: Removed.
26229        * platform/network/ResourceLoadTiming.h:
26230        (WebCore::ResourceLoadTiming::deepCopy):
26231        (WebCore::ResourceLoadTiming::operator==):
26232        (WebCore::ResourceLoadTiming::ResourceLoadTiming):
26233        Updated ResourceLoadTiming member variable names.
26234        * platform/network/mac/ResourceHandleMac.mm:
26235        (WebCore::ResourceHandle::createNSURLConnection):
26236        Collect timing data.
26237        * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
26238        (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
26239        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
26240        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
26241        Save timing data to a ResourceLoadTiming on the ResourceResponse.
26242        * platform/network/soup/ResourceHandleSoup.cpp:
26243        (WebCore::gotHeadersCallback):
26244        (WebCore::restartedCallback):
26245        (WebCore::milisecondsSinceRequest):
26246        (WebCore::ResourceHandle::didStartRequest):
26247        (WebCore::networkEventCallback):
26248        (WebCore::createSoupMessageForHandleAndRequest):
26249        (WebCore::ResourceHandle::sendPendingRequest):
26250        Updated ResourceLoadTiming member variable names.
26251        (WebCore::wroteBodyCallback): Deleted.
26252
262532014-05-12  Dirk Schulze  <krit@webkit.org>
26254
26255        SVG outline property is broken and inefficient
26256        https://bugs.webkit.org/show_bug.cgi?id=113666
26257
26258        Reviewed by Dean Jackson.
26259
26260        Patch by Erik Dahlström backported from Blink.
26261
26262        "[SVG2] css 'outline' property should apply to svg elements 
26263
26264        The 'outline' property was only partially working in SVG before
26265        this patch, this makes it work on text and text content child
26266        elements too. 
26267
26268        This makes SVG render the outlines as part of the foreground paint
26269        phase. 
26270
26271        Partly based on Florin Malita's webkit patch https://bugs.webkit.org/show_bug.cgi?id=113666#c12."
26272
26273        Tests: svg/custom/outline-stacking-expected.svg
26274               svg/custom/outline-stacking.svg
26275               svg/custom/rgba-color-outline.svg
26276               svg/text/text-outline-expected.svg
26277               svg/text/text-outline-rgba.html
26278               svg/text/text-outline.html
26279               svg/text/textpath-outline-expected.svg
26280               svg/text/textpath-outline.svg
26281               svg/text/tspan-multiple-outline.svg
26282               svg/text/tspan-outline-2-expected.svg
26283               svg/text/tspan-outline-2.svg
26284               svg/text/tspan-outline-expected.svg
26285               svg/text/tspan-outline.html
26286
26287        * rendering/svg/RenderSVGContainer.cpp:
26288        (WebCore::RenderSVGContainer::paint): Draw outline in forground
26289            paint phase.
26290        * rendering/svg/RenderSVGImage.cpp:
26291        (WebCore::RenderSVGImage::paint): Draw outline in forground
26292            paint phase.
26293        * rendering/svg/RenderSVGRoot.cpp:
26294        (WebCore::RenderSVGRoot::paintReplaced): Pass paint offset.
26295        * rendering/svg/RenderSVGShape.cpp:
26296        (WebCore::RenderSVGShape::paint): Draw outline in forground
26297            paint phase.
26298        * rendering/svg/RenderSVGText.cpp:
26299        (WebCore::RenderSVGText::paint): Draw outline in forground
26300            paint phase.
26301        * rendering/svg/SVGInlineFlowBox.cpp:
26302        (WebCore::SVGInlineFlowBox::paint): Pass paint offset.
26303        * rendering/svg/SVGInlineTextBox.cpp:
26304        (WebCore::SVGInlineTextBox::paint): Draw outline in forground
26305            paint phase.
26306        * rendering/svg/SVGRootInlineBox.cpp:
26307        (WebCore::SVGRootInlineBox::paint): Pass paint offset.
26308
263092014-05-12  Beth Dakin  <bdakin@apple.com>
26310
26311        Layer for bottom overhang area needs to be offset by the topContentInset
26312        https://bugs.webkit.org/show_bug.cgi?id=132835
26313        -and corresponding-
26314        <rdar://problem/16641115>
26315
26316        Reviewed by Simon Fraser.
26317
26318        Push this layer down by the topContentInset in addition to the root layer height, 
26319        footer height, and header height.
26320        * rendering/RenderLayerCompositor.cpp:
26321        (WebCore::RenderLayerCompositor::updateLayerForBottomOverhangArea):
26322
263232014-05-09  Jon Honeycutt  <jhoneycutt@apple.com>
26324
26325        REGRESSION (r167818): editing/inserting/typing-space-to-trigger-smart-link.html fails on WebKit1 bots
26326
26327        <https://bugs.webkit.org/show_bug.cgi?id=132207>
26328        <rdar://problem/16730393>
26329
26330        Reverts the previous workaround in favor of a more specific fix for the
26331        null dereference.
26332
26333        Reviewed by Darin Adler.
26334
26335        * editing/ApplyStyleCommand.cpp:
26336        (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
26337        Check whether the run's start and end are still in the document, as
26338        removeConflictingInlineStyleFromRun() may have removed them.
26339
26340        * editing/CompositeEditCommand.cpp:
26341        (WebCore::CompositeEditCommand::apply):
26342        Reverted previous workaround.
26343        (WebCore::ApplyEditCommand::ReentrancyGuard::isRecursiveCall): Deleted.
26344        (WebCore::ApplyEditCommand::ReentrancyGuard::Scope::Scope): Deleted.
26345        (WebCore::ApplyEditCommand::ReentrancyGuard::Scope::~Scope): Deleted.
26346
263472014-05-12  Zan Dobersek  <zdobersek@igalia.com>
26348
26349        Clean up CrossThreadTask
26350        https://bugs.webkit.org/show_bug.cgi?id=132800
26351
26352        Reviewed by Darin Adler.
26353
26354        Remove the createCallbackTask overloads and the related CrossThreadTask helper classes.
26355
26356        Instead, have one simple CrossThreadTask class that derives from ScriptExecutionContext::Task.
26357        Its templated constructor takes in the method and the variadic pack of parameters. The cross-thread
26358        copies of the parameters are then bound to that method and the resulting bind expression is used to
26359        initialize the base class. The bind expression is constructed with a placeholder for the
26360        ScriptExecutionContext* parameter that's provided through ScriptExecutionContext::Task::performTask().
26361
26362        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
26363        (WebCore::ThreadableWebSocketChannelClientWrapper::didConnect):
26364        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessage):
26365        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
26366        (WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmount):
26367        (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshake):
26368        (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
26369        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageError):
26370        (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks):
26371        * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
26372        (WebCore::WorkerThreadableWebSocketChannel::Peer::send):
26373        (WebCore::WorkerThreadableWebSocketChannel::Peer::bufferedAmount):
26374        (WebCore::WorkerThreadableWebSocketChannel::Peer::didConnect):
26375        (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveMessage):
26376        (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData):
26377        (WebCore::WorkerThreadableWebSocketChannel::Peer::didUpdateBufferedAmount):
26378        (WebCore::WorkerThreadableWebSocketChannel::Peer::didStartClosingHandshake):
26379        (WebCore::WorkerThreadableWebSocketChannel::Peer::didClose):
26380        (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveMessageError):
26381        (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadInitialize):
26382        (WebCore::WorkerThreadableWebSocketChannel::Bridge::initialize):
26383        (WebCore::WorkerThreadableWebSocketChannel::Bridge::connect):
26384        (WebCore::WorkerThreadableWebSocketChannel::Bridge::send):
26385        (WebCore::WorkerThreadableWebSocketChannel::Bridge::bufferedAmount):
26386        (WebCore::WorkerThreadableWebSocketChannel::Bridge::close):
26387        (WebCore::WorkerThreadableWebSocketChannel::Bridge::fail):
26388        (WebCore::WorkerThreadableWebSocketChannel::Bridge::disconnect):
26389        (WebCore::WorkerThreadableWebSocketChannel::Bridge::suspend):
26390        (WebCore::WorkerThreadableWebSocketChannel::Bridge::resume):
26391        * dom/CrossThreadTask.h:
26392        (WebCore::CrossThreadTask::CrossThreadTask):
26393        (WebCore::CrossThreadTask1::CrossThreadTask1): Deleted.
26394        (WebCore::CrossThreadTask1::performTask): Deleted.
26395        (WebCore::CrossThreadTask2::CrossThreadTask2): Deleted.
26396        (WebCore::CrossThreadTask2::performTask): Deleted.
26397        (WebCore::CrossThreadTask3::CrossThreadTask3): Deleted.
26398        (WebCore::CrossThreadTask3::performTask): Deleted.
26399        (WebCore::CrossThreadTask4::CrossThreadTask4): Deleted.
26400        (WebCore::CrossThreadTask4::performTask): Deleted.
26401        (WebCore::CrossThreadTask5::CrossThreadTask5): Deleted.
26402        (WebCore::CrossThreadTask5::performTask): Deleted.
26403        (WebCore::CrossThreadTask6::CrossThreadTask6): Deleted.
26404        (WebCore::CrossThreadTask6::performTask): Deleted.
26405        (WebCore::CrossThreadTask7::CrossThreadTask7): Deleted.
26406        (WebCore::CrossThreadTask7::performTask): Deleted.
26407        (WebCore::CrossThreadTask8::CrossThreadTask8): Deleted.
26408        (WebCore::CrossThreadTask8::performTask): Deleted.
26409        (WebCore::createCallbackTask): Deleted.
26410        * fileapi/FileReader.cpp:
26411        (WebCore::FileReader::abort):
26412        * loader/WorkerThreadableLoader.cpp:
26413        (WebCore::WorkerThreadableLoader::MainThreadBridge::MainThreadBridge):
26414        (WebCore::WorkerThreadableLoader::MainThreadBridge::destroy):
26415        (WebCore::WorkerThreadableLoader::MainThreadBridge::cancel):
26416        (WebCore::WorkerThreadableLoader::MainThreadBridge::didSendData):
26417        (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveResponse):
26418        (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveData):
26419        (WebCore::WorkerThreadableLoader::MainThreadBridge::didFinishLoading):
26420        (WebCore::WorkerThreadableLoader::MainThreadBridge::didFail):
26421        (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailAccessControlCheck):
26422        (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailRedirectCheck):
26423        * loader/WorkerThreadableLoader.h:
26424        * loader/cache/MemoryCache.cpp:
26425        (WebCore::MemoryCache::removeRequestFromCache):
26426        (WebCore::MemoryCache::removeRequestFromSessionCaches):
26427        * workers/DefaultSharedWorkerRepository.cpp:
26428        (WebCore::SharedWorkerProxy::postExceptionToWorkerObject):
26429        (WebCore::SharedWorkerProxy::postConsoleMessageToWorkerObject):
26430        * workers/WorkerMessagingProxy.cpp:
26431        (WebCore::WorkerMessagingProxy::postConsoleMessageToWorkerObject):
26432        (WebCore::WorkerMessagingProxy::workerObjectDestroyed):
26433        (WebCore::WorkerMessagingProxy::connectToInspector):
26434        (WebCore::WorkerMessagingProxy::disconnectFromInspector):
26435        (WebCore::WorkerMessagingProxy::sendMessageToInspector):
26436
264372014-05-12  Alex Christensen  <achristensen@webkit.org>
26438
26439        Implement EXT_shader_texture_lod in WebGL.
26440        https://bugs.webkit.org/show_bug.cgi?id=128985
26441        <rdar://problem/16111396>
26442
26443        Based on Chromium patch by bajones@chromium.org.
26444        https://src.chromium.org/viewvc/blink?revision=171465&view=revision
26445
26446        Reviewed by Dean Jackson.
26447
26448        Test: webgl/conformance/extensions/ext-shader-texture-lod.html
26449        
26450        * CMakeLists.txt:
26451        * DerivedSources.cpp:
26452        * DerivedSources.make:
26453        * WebCore.vcxproj/WebCore.vcxproj:
26454        * WebCore.vcxproj/WebCore.vcxproj.filters:
26455        * WebCore.xcodeproj/project.pbxproj:
26456        Added new EXTShaderTextureLOD files.
26457        * bindings/js/JSWebGLRenderingContextCustom.cpp:
26458        (WebCore::toJS):
26459        Added EXTShaderTextureLOD.
26460        * html/canvas/EXTShaderTextureLOD.cpp: Added.
26461        (WebCore::EXTShaderTextureLOD::EXTShaderTextureLOD):
26462        (WebCore::EXTShaderTextureLOD::~EXTShaderTextureLOD):
26463        (WebCore::EXTShaderTextureLOD::getName):
26464        * html/canvas/EXTShaderTextureLOD.h: Added.
26465        * html/canvas/EXTShaderTextureLOD.idl: Added.
26466        * html/canvas/WebGLExtension.h:
26467        Added EXTShaderTextureLODName.
26468        * html/canvas/WebGLObject.cpp:
26469        Removed unused inclusion of EXTTextureFilterAnisotropic.h.
26470        * html/canvas/WebGLRenderingContext.cpp:
26471        (WebCore::WebGLRenderingContext::getExtension):
26472        Added EXT_shader_texture_lod.
26473        * html/canvas/WebGLRenderingContext.h:
26474        Added a EXTShaderTextureLOD member variable.
26475
264762014-05-12  Martin Hock  <mhock@apple.com>
26477
26478        Disallow drag and drop of non-displayable resources.
26479        https://bugs.webkit.org/show_bug.cgi?id=132745
26480        <rdar://problem/10562662>
26481
26482        Reviewed by Alexey Proskuryakov.
26483
26484        Test: http/tests/security/drag-drop-local-file.html
26485
26486        * page/DragController.cpp:
26487        (WebCore::DragController::startDrag):
26488
264892014-05-12  Jozsef Berta  <jberta.u-szeged@partner.samsung.com>
26490
26491        WinCairo buildfix after r168611
26492        https://bugs.webkit.org/show_bug.cgi?id=132825
26493
26494        Reviewed by Darin Adler.
26495
26496        * platform/network/curl/CurlDownload.cpp:
26497        (WebCore::CurlDownloadManager::downloadThread):
26498        (WebCore::CurlDownload::didReceiveHeader):
26499        (WebCore::CurlDownload::didReceiveData):
26500
265012014-05-12  Antti Koivisto  <antti@apple.com>
26502
26503        REGRESSION (r159560): Text clips on tile border if line-height < font-size
26504        https://bugs.webkit.org/show_bug.cgi?id=132822
26505
26506        Reviewed by Andreas Kling.
26507        
26508        The first line of simple line layout run range was miscomputed.
26509
26510        Test: fast/text/simple-lines-range-low-line-height.html
26511
26512        * rendering/SimpleLineLayoutResolver.h:
26513        (WebCore::SimpleLineLayout::RunResolver::lineIndexForHeight):
26514        
26515            Lines may overlap if line-height < font-size. Apply different adjustment when searching for range begin
26516            so that overflowing earlier lines are taken into account.
26517
26518        (WebCore::SimpleLineLayout::RunResolver::rangeForRect):
26519
265202014-05-12  Radu Stavila  <stavila@adobe.com>
26521
26522        Invalid information remaining in lineToRegion map of RenderFlowThread.
26523        https://bugs.webkit.org/show_bug.cgi?id=132690
26524
26525        Reviewed by Antti Koivisto.
26526
26527        Test: fast/multicol/newmulticol/lines-region-map-crash.html
26528
26529        * rendering/RenderFlowThread.cpp:
26530        (WebCore::RenderFlowThread::deleteLines):
26531        * rendering/RenderFlowThread.h:
26532
265332014-05-12  Zan Dobersek  <zdobersek@igalia.com>
26534
26535        Clean up MainThreadTask
26536        https://bugs.webkit.org/show_bug.cgi?id=132799
26537
26538        Reviewed by Darin Adler.
26539
26540        Only have one simple MainThreadTask class that derives from std::function<void ()>.
26541        Its templated constructor takes in the method and a variadic pack of parameters.
26542        The cross-thread copies of the parameter are then bound to the given method through
26543        std::bind(), with the resulting bind expression used to initialize the base
26544        std::function<void ()> class.
26545
26546        The WebCore::callOnMainThread() functions and the helper classes are removed in favor
26547        of passing MainThreadTask rvalues directly to WTF::callOnMainThread().
26548
26549        * fileapi/AsyncFileStream.cpp:
26550        (WebCore::AsyncFileStream::startOnFileThread):
26551        (WebCore::AsyncFileStream::stopOnFileThread):
26552        (WebCore::AsyncFileStream::getSizeOnFileThread):
26553        (WebCore::AsyncFileStream::openForReadOnFileThread):
26554        (WebCore::AsyncFileStream::openForWriteOnFileThread):
26555        (WebCore::AsyncFileStream::readOnFileThread):
26556        (WebCore::AsyncFileStream::writeOnFileThread):
26557        (WebCore::AsyncFileStream::truncateOnFileThread):
26558        * platform/MainThreadTask.h:
26559        (WebCore::MainThreadTask::MainThreadTask):
26560        (WebCore::MainThreadTaskBase::MainThreadTaskBase): Deleted.
26561        (WebCore::MainThreadTaskBase::~MainThreadTaskBase): Deleted.
26562        (WebCore::MainThreadTask1::create): Deleted.
26563        (WebCore::MainThreadTask1::MainThreadTask1): Deleted.
26564        (WebCore::MainThreadTask2::create): Deleted.
26565        (WebCore::MainThreadTask2::MainThreadTask2): Deleted.
26566        (WebCore::MainThreadTask3::create): Deleted.
26567        (WebCore::MainThreadTask3::MainThreadTask3): Deleted.
26568        (WebCore::MainThreadTask4::create): Deleted.
26569        (WebCore::MainThreadTask4::MainThreadTask4): Deleted.
26570        (WebCore::MainThreadTask5::create): Deleted.
26571        (WebCore::MainThreadTask5::MainThreadTask5): Deleted.
26572        (WebCore::MainThreadTask6::create): Deleted.
26573        (WebCore::MainThreadTask6::MainThreadTask6): Deleted.
26574        (WebCore::MainThreadTask7::create): Deleted.
26575        (WebCore::MainThreadTask7::MainThreadTask7): Deleted.
26576        (WebCore::MainThreadTask8::create): Deleted.
26577        (WebCore::MainThreadTask8::MainThreadTask8): Deleted.
26578        (WebCore::executeMainThreadTask): Deleted.
26579        (WebCore::callOnMainThread): Deleted.
26580
265812014-05-11  Zan Dobersek  <zdobersek@igalia.com>
26582
26583        Simplify FileThread::Task usage
26584        https://bugs.webkit.org/show_bug.cgi?id=132798
26585
26586        Reviewed by Darin Adler.
26587
26588        Remove the createFileThreadTask functions and the related FileThreadTask helper classes.
26589
26590        Instead, the FileThread::Task class now has a templated constructor that takes in a pointer
26591        to the object instance, a method, and a variadic pack of parameters. The pointer and the
26592        cross-thread copies of all the parameters are then bound to the given method through std::bind().
26593
26594        Instead of createFileThreadTask, std::make_unique<>() should be used to construct unique pointers
26595        that wrap FileThread::Task objects.
26596
26597        * WebCore.vcxproj/WebCore.vcxproj:
26598        * WebCore.vcxproj/WebCore.vcxproj.filters:
26599        * WebCore.xcodeproj/project.pbxproj:
26600        * fileapi/AsyncFileStream.cpp:
26601        (WebCore::AsyncFileStream::create):
26602        (WebCore::AsyncFileStream::stop):
26603        (WebCore::AsyncFileStream::getSize):
26604        (WebCore::AsyncFileStream::openForRead):
26605        (WebCore::AsyncFileStream::openForWrite):
26606        (WebCore::AsyncFileStream::close):
26607        (WebCore::AsyncFileStream::read):
26608        (WebCore::AsyncFileStream::write):
26609        (WebCore::AsyncFileStream::truncate):
26610        * fileapi/FileThread.h:
26611        (WebCore::FileThread::Task::Task):
26612        (WebCore::FileThread::Task::performTask):
26613        (WebCore::FileThread::Task::~Task): Deleted.
26614        * fileapi/FileThreadTask.h: Removed.
26615
266162014-05-11  Benjamin Poulain  <benjamin@webkit.org>
26617
26618        Do not create a temporary string to append the SVGLength's unit
26619        https://bugs.webkit.org/show_bug.cgi?id=132807
26620
26621        Reviewed by Geoffrey Garen.
26622
26623        * svg/SVGLength.cpp:
26624        (WebCore::lengthTypeToString):
26625        The caller just append the string to a number string. The function
26626        lengthTypeToString() was creating a new WTF::String from scratch,
26627        copied the characters to make a new string, and destroyed the WTF::String.
26628
26629        Instead, just append the string literal.
26630
266312014-05-11  Yusuke Suzuki  <utatane.tea@gmail.com>
26632
26633        CSS JIT: reduce cost of computing backtracking height
26634        https://bugs.webkit.org/show_bug.cgi?id=132546
26635
26636        Reviewed by Benjamin Poulain.
26637
26638        Because compiler previously compute backtracking height for
26639        previous child fragment, by leveraging this, we can limit the
26640        `maxPrefixSize` for `computeBacktrackingHeightFromDescendant`.
26641
26642        For example, consider selector "c>a>b>d>a>b e"'s descendant chain,
26643        "c>a>b>d>a>b".
26644
26645        At the <a> position, we have matching pattern [b, a, d, b, a] and
26646        calculate the backtracking height by following method.
26647
26648        pattern:    [b, a, d, b, a]
26649        candidate0:    [b, a, d, b]  => Not matched.
26650        candidate1:       [b, a, d]  => Not matched.
26651        candidate2:          [b, a]  => Matched against the pattern.
26652
26653        At this time, first candidate0's pattern size is `pattern.size() - 1`.
26654        And get backtracking height from descendant 3, that is
26655        `pattern.size() - candidate.size()`, `5 - 2`.
26656
26657        And next, at the <c> position, we calcucate the backtracking height
26658        for this pattern.
26659
26660        pattern:    [b, a, d, b, a, c]
26661        candidate0:    [b, a, d, b, a]  => Not matched.
26662        candidate1:       [b, a, d, b]  => Not matched.
26663        candidate2:          [b, a, d]  => Not matched.
26664        candidate3:             [b, a]  => Not matched.
26665        candidate4:                [b]  => Not matched.
26666        candidate5:                 []  => Matched against the pattern.
26667
26668        Then, we get the backtracking height, which is 6 (6 - 0).
26669        However, in the above case, we already know that attempts from candidate0
26670        to candidate1 always fail, since parts of these are already tested at
26671        the <b> position trial and we know they don't match.
26672
26673        So in this case, we should start this computation from candidate2,
26674        such as,
26675
26676        pattern:    [b, a, d, b, a, c]
26677        candidate2:          [b, a, d]  => Not matched.
26678        candidate3:             [b, a]  => Not matched.
26679        candidate4:                [b]  => Not matched.
26680        candidate5:                 []  => Matched against the pattern.
26681
26682        We can start computation with candidate size
26683        `pattern.size() - previousChildFragmentBacktrackingHeight`.
26684        In this example, `pattern.size()` is 6 and
26685        `previousChildFragmentBacktrackingHeight` is 3, so candidate size is
26686        3, that is candidate2.
26687
26688        * cssjit/SelectorCompiler.cpp:
26689        (WebCore::SelectorCompiler::computeBacktrackingStartHeightFromDescendant):
26690        (WebCore::SelectorCompiler::computeBacktrackingHeightFromDescendant):
26691
266922014-05-11  Beth Dakin  <bdakin@apple.com>
26693
26694        Headers and footers are not positioned correctly with topContentInset
26695        https://bugs.webkit.org/show_bug.cgi?id=132787
26696        -and corresponding-
26697        <rdar://problem/16641115>
26698
26699        Reviewed by Tim Horton.
26700
26701        Headers and footers need to take the inset into account, and they also need to 
26702        factor in the fact that the root layer moves around now too.
26703
26704        The existing yPositionForRootContentLayer() is actually the right calculation for 
26705        the header layer. The root content layer wants that value, but pushed down by the 
26706        header height. Now there are static functions for both of them and the footer to 
26707        avoid duplicated code in the three spots where we need this information.
26708        * page/FrameView.cpp:
26709        (WebCore::FrameView::yPositionForHeaderLayer):
26710        (WebCore::FrameView::yPositionForRootContentLayer):
26711        (WebCore::FrameView::yPositionForFooterLayer):
26712        * page/FrameView.h:
26713
26714        Use the static functions to compute the layer positions.
26715        * page/scrolling/AsyncScrollingCoordinator.cpp:
26716        (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
26717
26718        How did headers ever work with this bug?? I don’t know. We need to return that 
26719        layer.
26720        * page/scrolling/ScrollingCoordinator.cpp:
26721        (WebCore::ScrollingCoordinator::headerLayerForFrameView):
26722
26723        Use the static functions to compute the layer positions.
26724        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
26725        (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
26726        * rendering/RenderLayerCompositor.cpp:
26727        (WebCore::RenderLayerCompositor::updateRootLayerPosition):
26728        (WebCore::RenderLayerCompositor::updateLayerForHeader):
26729        (WebCore::RenderLayerCompositor::updateLayerForFooter):
26730
267312014-05-11  Zalan Bujtas  <zalan@apple.com>
26732
26733        Subpixel rendering[iOS]: <select> decoration is misaligned when the renderer is on subpixel position.
26734        https://bugs.webkit.org/show_bug.cgi?id=132779
26735        <rdar://problem/16631071>
26736
26737        Reviewed by Simon Fraser.
26738
26739        Push <select> theme decoration's rect to device pixel position to ensure
26740        that the theme bounds are aligned with the renderer's bounds. (in painting terms)
26741        However, as the decoration code paints multiple items, they all need to use snapped 
26742        final coordinates for painting : tracked here https://bugs.webkit.org/show_bug.cgi?id=132780
26743        This patch also changes the padding values for <select> [iOS] to compensate for the integer
26744        truncation that happened before subpixel. 
26745
26746        Not testable.
26747
26748        * css/html.css:
26749        (select):
26750        * platform/efl/RenderThemeEfl.cpp:
26751        (WebCore::RenderThemeEfl::paintMenuListButtonDecorations):
26752        * platform/efl/RenderThemeEfl.h:
26753        * platform/gtk/RenderThemeGtk.cpp:
26754        (WebCore::RenderThemeGtk::paintMenuListButtonDecorations):
26755        * platform/gtk/RenderThemeGtk.h:
26756        * rendering/RenderTheme.cpp:
26757        (WebCore::RenderTheme::paintDecorations):
26758        * rendering/RenderTheme.h:
26759        (WebCore::RenderTheme::paintMenuListButtonDecorations):
26760        * rendering/RenderThemeIOS.h:
26761        * rendering/RenderThemeIOS.mm:
26762        (WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
26763        * rendering/RenderThemeMac.h:
26764        * rendering/RenderThemeMac.mm:
26765        (WebCore::RenderThemeMac::paintMenuListButtonDecorations):
26766        * rendering/RenderThemeSafari.cpp:
26767        (WebCore::RenderThemeSafari::paintMenuListButtonDecorations):
26768        * rendering/RenderThemeSafari.h:
26769        * rendering/RenderThemeWin.cpp:
26770        (WebCore::RenderThemeWin::paintMenuList):
26771        (WebCore::RenderThemeWin::paintMenuListButtonDecorations):
26772        * rendering/RenderThemeWin.h:
26773
267742014-05-11  Zan Dobersek  <zdobersek@igalia.com>
26775
26776        Move Source/WebCore/workers/ code to std::unique_ptr
26777        https://bugs.webkit.org/show_bug.cgi?id=132401
26778
26779        Reviewed by Darin Adler.
26780
26781        Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/workers (and related places)
26782        with std::unique_ptr.
26783
26784        * bindings/js/JSDOMWindowCustom.cpp:
26785        (WebCore::JSDOMWindow::setTimeout):
26786        (WebCore::JSDOMWindow::setInterval):
26787        * bindings/js/JSWorkerGlobalScopeCustom.cpp:
26788        (WebCore::JSWorkerGlobalScope::setTimeout):
26789        (WebCore::JSWorkerGlobalScope::setInterval):
26790        * bindings/js/ScheduledAction.cpp:
26791        (WebCore::ScheduledAction::create):
26792        * bindings/js/ScheduledAction.h:
26793        * page/DOMTimer.cpp:
26794        (WebCore::DOMTimer::DOMTimer):
26795        (WebCore::DOMTimer::install):
26796        (WebCore::DOMTimer::fired):
26797        (WebCore::DOMTimer::didStop):
26798        * page/DOMTimer.h:
26799        * page/DOMWindow.cpp:
26800        (WebCore::DOMWindow::setTimeout):
26801        (WebCore::DOMWindow::setInterval):
26802        * page/DOMWindow.h:
26803        * workers/WorkerEventQueue.h:
26804        * workers/WorkerGlobalScope.cpp:
26805        (WebCore::WorkerGlobalScope::WorkerGlobalScope):
26806        (WebCore::WorkerGlobalScope::setTimeout):
26807        (WebCore::WorkerGlobalScope::setInterval):
26808        * workers/WorkerGlobalScope.h:
26809        (WebCore::WorkerGlobalScope::clearScript):
26810        * workers/WorkerLoaderProxy.h:
26811        * workers/WorkerMessagingProxy.h:
26812        * workers/WorkerRunLoop.cpp:
26813        (WebCore::WorkerRunLoop::WorkerRunLoop):
26814        * workers/WorkerRunLoop.h:
26815        * workers/WorkerScriptLoader.cpp:
26816        (WebCore::WorkerScriptLoader::loadSynchronously):
26817        (WebCore::WorkerScriptLoader::loadAsynchronously):
26818        (WebCore::WorkerScriptLoader::createResourceRequest):
26819        * workers/WorkerScriptLoader.h:
26820        * workers/WorkerThread.cpp:
26821        (WebCore::WorkerThread::WorkerThread):
26822        (WebCore::WorkerThread::workerThread):
26823        (WebCore::WorkerThreadStartupData::create): Deleted.
26824        * workers/WorkerThread.h:
26825
268262014-05-09  Myles C. Maxfield  <litherum@gmail.com>
26827
26828        [Mac] [iOS] Underlines are too low
26829        https://bugs.webkit.org/show_bug.cgi?id=132770
26830
26831        Reviewed by Darin Adler.
26832
26833        computeUnderlineOffset() inside InlineTextBox.cpp lowers underlines from text
26834        baseline by a value that is proportional to the font size. However, this
26835        lowering was done a second time in
26836        GraphicsContext::computeLineBoundsAndAntialiasingModeForText(). This patch
26837        removes this second, platform-dependent lowering.
26838
26839        This duplication was caused by merging iOS into open source, where iOS used
26840        the GraphicsContext approach and open source used the InlineTextBox approach.
26841
26842        Covered by fast/css3-text/css3-text-decoration/text-decoration-thickness.html.
26843
26844        * platform/graphics/GraphicsContext.cpp:
26845        (WebCore::GraphicsContext::computeLineBoundsAndAntialiasingModeForText): Remove
26846        redundant lowering code
26847        * rendering/InlineTextBox.cpp:
26848        (WebCore::InlineTextBox::paintDecoration): Clean up textDecorationThickness
26849        variable
26850
268512014-05-11  Antti Koivisto  <antti@apple.com>
26852
26853        Text with simple line layout not getting pushed below float when there is not enough space for it
26854        https://bugs.webkit.org/show_bug.cgi?id=126991
26855
26856        Reviewed by Andreas Kling.
26857
26858        Tests: fast/text/simple-lines-intruding-wide-float-dynamic.html
26859               fast/text/simple-lines-intruding-wide-float.html
26860
26861        * rendering/RenderBlockFlow.cpp:
26862        (WebCore::RenderBlockFlow::markLinesDirtyInBlockRange):
26863        
26864            Invalidate the line layout path when floats change. We need to check SimpleLineLayout::canUseFor again as
26865            intruding floats may make this flow ineligible to use the path.
26866
26867        * rendering/RenderBlockFlow.h:
26868        (WebCore::RenderBlockFlow::floatingObjectSet):
26869        * rendering/SimpleLineLayout.cpp:
26870        (WebCore::SimpleLineLayout::canUseFor):
26871        
26872            Test the top positions of all floats for case that would push text below the float instead of just testing 
26873            the first line. We may have floats in the middle of the paragraph too.
26874
268752014-05-11  peavo@outlook.com  <peavo@outlook.com>
26876
26877        WinCairo crashes on acid3 test
26878        https://bugs.webkit.org/show_bug.cgi?id=131364
26879
26880        Reviewed by Brent Fulgham.
26881
26882        When the 304 (Not-modified) response is received, the Curl backend should look up the cached response,
26883        and call the client method didReceiveResponse with the cached response, instead of the 304 response.
26884        Otherwise the response will contain an empty MIME type, which causes the request to be cancelled, and the client deleted.
26885        When the Curl cache manager then accesses the client afterwards, it is deleted, and we crash.
26886
26887        * platform/network/curl/CurlCacheManager.cpp:
26888        (WebCore::CurlCacheManager::didReceiveResponse): Return early if request is cancelled.
26889        (WebCore::CurlCacheManager::getCachedResponse): Added method to get cached response.
26890        * platform/network/curl/CurlCacheManager.h: Ditto.
26891        * platform/network/curl/ResourceHandleManager.cpp:
26892        (WebCore::headerCallback): When 304 response is received, look up cached response, and use it.
26893
268942014-05-10  Tim Horton  <timothy_horton@apple.com>
26895
26896        [WKWebView _updateScrollViewBackground] churns UI-and-CGColors while repainting
26897        https://bugs.webkit.org/show_bug.cgi?id=132793
26898        <rdar://problem/16877870>
26899
26900        Reviewed by Dan Bernstein.
26901
26902        * WebCore.exp.in:
26903        Export a Color convenience function.
26904
269052014-05-10  Commit Queue  <commit-queue@webkit.org>
26906
26907        Unreviewed, rolling out r168578.
26908        https://bugs.webkit.org/show_bug.cgi?id=132789
26909
26910        Speculative rollout since this appears to break PLT3.
26911        (Requested by kling on #webkit).
26912
26913        Reverted changeset:
26914
26915        "Move Source/WebCore/workers/ code to std::unique_ptr"
26916        https://bugs.webkit.org/show_bug.cgi?id=132401
26917        http://trac.webkit.org/changeset/168578
26918
269192014-05-10  Darin Adler  <darin@apple.com>
26920
26921        REGRESSION (r166853): fast/preloader/document-write.html is very flaky
26922        https://bugs.webkit.org/show_bug.cgi?id=130942
26923
26924        Reviewed by Anders Carlsson.
26925
26926        * style/StyleResolveTree.cpp:
26927        (WebCore::Style::suspendMemoryCacheClientCalls): Use a RefPtr to the main
26928        frame as a weak pointer to a Page that will work unless the page is destroyed.
26929        The old code tried to do it with a RefPtr to a document, but as the FIXME
26930        points out, that won't work if the document is disassociated with its frame.
26931
269322014-05-10  Anders Carlsson  <andersca@apple.com>
26933
26934        Block exceptions when trying to convert attributed strings to RTF and RTFD
26935        https://bugs.webkit.org/show_bug.cgi?id=132778
26936        <rdar://problem/16675805>
26937
26938        Reviewed by Darin Adler.
26939
26940        When the iOS WebHTMLConverter was upstreamed, converting some attributed strings to RTF and RTFD
26941        started throwing Objective-C exceptions (see <rdar://problem/16876920>).
26942        
26943        In WebKit2, we now crash on unhandled exceptions so work around that crash by adding exception blocking macros.
26944
26945        * editing/ios/EditorIOS.mm:
26946        (WebCore::dataInRTFDFormat):
26947        (WebCore::dataInRTFFormat):
26948        * editing/mac/EditorMac.mm:
26949        (WebCore::dataInRTFDFormat):
26950        (WebCore::dataInRTFFormat):
26951
269522014-05-10  Zan Dobersek  <zdobersek@igalia.com>
26953
26954        Move Source/WebCore/workers/ code to std::unique_ptr
26955        https://bugs.webkit.org/show_bug.cgi?id=132401
26956
26957        Reviewed by Andreas Kling.
26958
26959        Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/workers (and related places)
26960        with std::unique_ptr.
26961
26962        * bindings/js/JSDOMWindowCustom.cpp:
26963        (WebCore::JSDOMWindow::setTimeout):
26964        (WebCore::JSDOMWindow::setInterval):
26965        * bindings/js/JSWorkerGlobalScopeCustom.cpp:
26966        (WebCore::JSWorkerGlobalScope::setTimeout):
26967        (WebCore::JSWorkerGlobalScope::setInterval):
26968        * bindings/js/ScheduledAction.cpp:
26969        (WebCore::ScheduledAction::create):
26970        * bindings/js/ScheduledAction.h:
26971        * page/DOMTimer.cpp:
26972        (WebCore::DOMTimer::DOMTimer):
26973        (WebCore::DOMTimer::install):
26974        (WebCore::DOMTimer::fired):
26975        (WebCore::DOMTimer::didStop):
26976        * page/DOMTimer.h:
26977        * page/DOMWindow.cpp:
26978        (WebCore::DOMWindow::setTimeout):
26979        (WebCore::DOMWindow::setInterval):
26980        * page/DOMWindow.h:
26981        * workers/WorkerEventQueue.h:
26982        * workers/WorkerGlobalScope.cpp:
26983        (WebCore::WorkerGlobalScope::WorkerGlobalScope):
26984        (WebCore::WorkerGlobalScope::setTimeout):
26985        (WebCore::WorkerGlobalScope::setInterval):
26986        * workers/WorkerGlobalScope.h:
26987        (WebCore::WorkerGlobalScope::clearScript):
26988        * workers/WorkerLoaderProxy.h:
26989        * workers/WorkerMessagingProxy.h:
26990        * workers/WorkerRunLoop.cpp:
26991        (WebCore::WorkerRunLoop::WorkerRunLoop):
26992        * workers/WorkerRunLoop.h:
26993        * workers/WorkerScriptLoader.cpp:
26994        (WebCore::WorkerScriptLoader::loadSynchronously):
26995        (WebCore::WorkerScriptLoader::loadAsynchronously):
26996        (WebCore::WorkerScriptLoader::createResourceRequest):
26997        * workers/WorkerScriptLoader.h:
26998        * workers/WorkerThread.cpp:
26999        (WebCore::WorkerThread::WorkerThread):
27000        (WebCore::WorkerThread::workerThread):
27001        (WebCore::WorkerThreadStartupData::create): Deleted.
27002        * workers/WorkerThread.h:
27003
270042014-05-09  Dean Jackson  <dino@apple.com>
27005
27006        -webkit-filter prevents rendering at retina scale
27007        https://bugs.webkit.org/show_bug.cgi?id=93471
27008
27009        Reviewed by Dirk Schulze.
27010
27011        Implement 2x support for filters that go through
27012        the -webkit-filter property. This includes all
27013        shorthand filters, and any referenced SVG-style filters
27014        (as long as they use only the supported subset of
27015        operations - basically the same as is exposed for
27016        the shorthands).
27017
27018        Tests: fast/hidpi/filters-blur.html
27019               fast/hidpi/filters-hue-rotate.html
27020               fast/hidpi/filters-invert.html
27021               fast/hidpi/filters-multiple.html
27022               fast/hidpi/filters-reference.html
27023               fast/hidpi/filters-shadow.html
27024
27025        * platform/graphics/cg/ImageBufferCG.cpp:
27026        (WebCore::ImageBuffer::getUnmultipliedImageData): Scale the source rectangle if the method was
27027        called using LogicalCoordinates.
27028        (WebCore::ImageBuffer::getPremultipliedImageData): Ditto.
27029        (WebCore::ImageBuffer::putByteArray): Ditto.
27030
27031        * platform/graphics/filters/FEDropShadow.cpp:
27032        (WebCore::FEDropShadow::platformApplySoftware): Make sure to scale the blur radius by the filter
27033        resolution, and call the byte-array methods with the native coordinate system.
27034        * platform/graphics/filters/FEGaussianBlur.cpp:
27035        (WebCore::FEGaussianBlur::calculateUnscaledKernelSize): Fix typo.
27036        (WebCore::FEGaussianBlur::platformApplySoftware): Scale the kernel and paint rectangles
27037        by the filter scale.
27038
27039        * platform/graphics/filters/Filter.h:
27040        (WebCore::Filter::Filter): Initialise the filter scale.
27041        (WebCore::Filter::filterScale): New property which reflects the mapping between logical pixels
27042        and device pixels.
27043        (WebCore::Filter::setFilterScale):
27044
27045        * platform/graphics/filters/FilterEffect.cpp:
27046        (WebCore::FilterEffect::asImageBuffer): Make sure buffer creation takes scale into account.
27047        (WebCore::FilterEffect::asUnmultipliedImage): Ditto.
27048        (WebCore::FilterEffect::asPremultipliedImage): Ditto.
27049        (WebCore::FilterEffect::copyImageBytes): Scale any incoming regions if they are talking about
27050        device pixels rather than logical pixels.
27051        (WebCore::FilterEffect::copyUnmultipliedImage): Ditto.
27052        (WebCore::FilterEffect::copyPremultipliedImage): Ditto.
27053        (WebCore::FilterEffect::createImageBufferResult): Take scale into account when creating byte array.
27054        (WebCore::FilterEffect::createUnmultipliedImageResult): Ditto.
27055        (WebCore::FilterEffect::createPremultipliedImageResult): Ditto.
27056
27057        * rendering/FilterEffectRenderer.cpp:
27058        (WebCore::FilterEffectRenderer::allocateBackingStoreIfNeeded): Pass filter scale into buffer creation.
27059
27060        * rendering/RenderLayer.cpp:
27061        (WebCore::RenderLayer::updateOrRemoveFilterEffectRenderer): Make sure to set the filter scale to
27062        the device scale factor, and notice if we ever change scales.
27063
270642014-05-10  Praveen R Jadhav  <praveen.j@samsung.com>
27065
27066        [MediaStream] Rename NavigatorMediaStream as NavigatorUserMedia.
27067        https://bugs.webkit.org/show_bug.cgi?id=132734
27068
27069        Reviewed by Eric Carlson.
27070
27071        Spec: http://www.w3.org/TR/mediacapture-streams/#navigatorusermedia
27072
27073        This patch replaces 'NavigatorMediaStream' with 'NavigatorUserMedia'
27074        throughout the code to be consistent with W3C specifications.
27075        Test cases remain the same as 'Navigator' implies 'NavigatorUserMedia'.
27076
27077        * CMakeLists.txt: Compiles NavigatorUserMedia.cpp
27078        * DerivedSources.make: Compiles NavigatorUserMedia.idl
27079        * Modules/mediastream/NavigatorMediaStream.cpp: Removed.
27080        * Modules/mediastream/NavigatorMediaStream.h: Removed.
27081        * Modules/mediastream/NavigatorMediaStream.idl: Removed.
27082        * Modules/mediastream/NavigatorUserMedia.cpp: Added.
27083        (WebCore::NavigatorUserMedia::NavigatorUserMedia):
27084        (WebCore::NavigatorUserMedia::~NavigatorUserMedia):
27085        (WebCore::NavigatorUserMedia::webkitGetUserMedia):
27086        * Modules/mediastream/NavigatorUserMedia.h: Added.
27087        * Modules/mediastream/NavigatorUserMedia.idl: Added.
27088        * WebCore.xcodeproj/project.pbxproj:
27089        * bindings/js/JSNavigatorCustom.cpp:
27090        (WebCore::JSNavigator::webkitGetUserMedia): NavigatorUserMedia
27091        class is used instead of NavigatorMediaStream.
27092
270932014-05-10  Zalan Bujtas  <zalan@apple.com>
27094
27095        Subpixel rendering: Empty rects should remain empty after integrally enclosing them.
27096        https://bugs.webkit.org/show_bug.cgi?id=132753
27097        <rdar://problem/16846801>
27098
27099        Reviewed by Simon Fraser.
27100
27101        This patch ensures that empty LayoutRects remain empty after converting to integral enclosing rect.
27102        LayoutRects with fractional position get expanded even if they are empty. This makes rectangle
27103        operations unreliable and can result in undesired side effects.
27104
27105        No testable/covered by existing tests.
27106
27107        * platform/graphics/LayoutRect.cpp:
27108        (WebCore::enclosingIntRect):
27109        * rendering/InlineTextBox.cpp:
27110        (WebCore::InlineTextBox::localSelectionRect):
27111        (WebCore::InlineTextBox::paintDocumentMarker):
27112        (WebCore::InlineTextBox::paintTextMatchMarker):
27113        (WebCore::InlineTextBox::computeRectForReplacementMarker):
27114        (WebCore::integralEnclosingRectForSelection): Deleted.
27115
271162014-05-09  Joseph Pecoraro  <pecoraro@apple.com>
27117
27118        Web Inspector: Allow Remote Inspector to entitlement check UIProcess through WebProcess
27119        https://bugs.webkit.org/show_bug.cgi?id=132409
27120
27121        Reviewed by Timothy Hatcher.
27122
27123        * inspector/InspectorClient.h:
27124        (WebCore::InspectorClient::parentProcessIdentifier): Deleted.
27125        * page/PageDebuggable.cpp:
27126        (WebCore::PageDebuggable::parentProcessIdentifier): Deleted.
27127        * page/PageDebuggable.h:
27128        pid per debuggable is no longer needed.
27129
271302014-05-09  Dean Jackson  <dino@apple.com>
27131
27132        [fullscreen] cursor should auto-hide when over video
27133        https://bugs.webkit.org/show_bug.cgi?id=132758
27134
27135        Unreviewed followup based on test failure.
27136
27137        * css/fullscreen.css: Append the previous rule - video children of fullscreen elements.
27138
271392014-05-09  Dean Jackson  <dino@apple.com>
27140
27141        [fullscreen] cursor should auto-hide when over video
27142        https://bugs.webkit.org/show_bug.cgi?id=132758
27143
27144        Reviewed by Brent Fulgham.
27145
27146        Cursors were not auto-hiding over fullscreen video. There was
27147        a small error in the CSS we load for fullscreen content.
27148
27149        * css/fullscreen.css: Don't hide when video is a child of the fullscreen element - hide when it *is* the fullscreen element.
27150        (video:-webkit-full-screen):
27151        (:-webkit-full-screen video:hover): Deleted.
27152
271532014-05-09  Zalan Bujtas  <zalan@apple.com>
27154
27155        Subpixel rendering[iOS]: Top bar on apple.com/support jiggles when the swoosh animates.
27156        https://bugs.webkit.org/show_bug.cgi?id=132750
27157        <rdar://problem/16803281>
27158
27159        Reviewed by Simon Fraser.
27160
27161        This patch ensures that GraphicsLayer and RemoteLayerBackingStore have the same dimensions.
27162        
27163        Remove integral enclosing when we set the size on RemoteLayerBackingStore. It makes the layer's size
27164        different from the backingstore when the passed value is fractional.
27165        We scale and integral round this value to size the shareable bitmap later. Rounding ensures that
27166        the final size value matches what we calculated at GraphicsLayerCA::updateGeometry()
27167
27168        Currently not testable.
27169
27170        * platform/graphics/ca/GraphicsLayerCA.cpp:
27171        (WebCore::GraphicsLayerCA::updateGeometry):
27172        (WebCore::GraphicsLayerCA::computePixelAlignment): include device scale factor to be able calculate the final content scale.
27173        * platform/graphics/ca/GraphicsLayerCA.h:
27174
271752014-05-09  Mark Hahnenberg  <mhahnenberg@apple.com>
27176
27177        JSDOMWindow should disable property caching after a certain point
27178        https://bugs.webkit.org/show_bug.cgi?id=132751
27179
27180        Reviewed by Filip Pizlo.
27181
27182        No new tests.
27183
27184        This is part of removing HasImpureGetOwnPropertySlot from JSDOMWindow. After the lookup in the static 
27185        hash table for JSDOMWindow fails we want to disable property caching even if the code that follows thinks 
27186        that it has provided a cacheable value.
27187
27188        * bindings/js/JSDOMWindowCustom.cpp:
27189        (WebCore::JSDOMWindow::getOwnPropertySlot):
27190
271912014-05-09  Benjamin Poulain  <bpoulain@apple.com>
27192
27193        Fix the export file after r168556
27194
27195        * WebCore.exp.in: I forgot to fix the export file before landing.
27196
271972014-05-09  Benjamin Poulain  <bpoulain@apple.com>
27198
27199        [iOS][WK2] Set up the resize events
27200        https://bugs.webkit.org/show_bug.cgi?id=132726
27201
27202        Reviewed by Darin Adler and Simon Fraser.
27203
27204        Let the WebKit2 layer override the size used for resize events.
27205
27206        * WebCore.exp.in:
27207        * page/FrameView.cpp:
27208        (WebCore::FrameView::layout):
27209        (WebCore::FrameView::sizeForResizeEvent):
27210        (WebCore::FrameView::sendResizeEventIfNeeded):
27211        (WebCore::FrameView::setCustomSizeForResizeEvent):
27212        * page/FrameView.h:
27213
272142014-05-09  Alexey Proskuryakov  <ap@apple.com>
27215
27216        REGRESSION (r168518): Multiple tests for workers in blobs assert
27217        https://bugs.webkit.org/show_bug.cgi?id=132728
27218
27219        Reviewed by Geoffrey Garen.
27220
27221        Change File serialization to include name, so that we don't have to regenerate anything
27222        on a secondary thread after deserialization.
27223
27224        Files and Blobs can't be stored persistently, because URLs are transient (IndexedDB
27225        has an explicit check, and fails if there were any blob URLs). API doesn't have the
27226        check, but given that anyone who tried to use these to serialize a File would fail,
27227        it seems OK to change the format.
27228
27229        * bindings/js/SerializedScriptValue.cpp:
27230        (WebCore::CloneSerializer::write):
27231        (WebCore::CloneDeserializer::readFile):
27232        * fileapi/File.cpp:
27233        (WebCore::File::File):
27234        * fileapi/File.h:
27235
272362014-05-08  Mark Hahnenberg  <mhahnenberg@apple.com>
27237
27238        JSDOMWindow should have a WatchpointSet to fire on window close
27239        https://bugs.webkit.org/show_bug.cgi?id=132721
27240
27241        Reviewed by Filip Pizlo.
27242
27243        No new tests.
27244
27245        This patch allows us to reset the inline caches that assumed they could skip 
27246        the first part of JSDOMWindow::getOwnPropertySlot that checks if the window has 
27247        been closed. This is part of getting rid of HasImpureGetOwnPropertySlot on JSDOMWindow.
27248
27249        JSDOMWindowBase now has a WatchpointSet that the underlying DOMWindow fires when its
27250        frame is cleared. In getOwnPropertySlot, we now pass this WatchpointSet to PropertySlot
27251        which will shepherd it back up to the code that generates the inline cache (and the 
27252        Watchpoint for clearing it).
27253
27254        * bindings/js/JSDOMWindowBase.cpp:
27255        (WebCore::JSDOMWindowBase::JSDOMWindowBase):
27256        (WebCore::JSDOMWindowBase::fireFrameClearedWatchpointsForWindow):
27257        * bindings/js/JSDOMWindowBase.h:
27258        * bindings/js/JSDOMWindowCustom.cpp:
27259        (WebCore::JSDOMWindow::getOwnPropertySlot):
27260        * page/DOMWindow.cpp:
27261        (WebCore::DOMWindow::frameDestroyed):
27262
272632014-05-09  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
27264
27265        ASSERTION FAILED: object->style()->overflowX() == object->style()->overflowY()
27266        https://bugs.webkit.org/show_bug.cgi?id=121682
27267
27268        Reviewed by Dirk Schulze.
27269
27270        Add more overflow freedom to the SVG element:
27271        -overflow-x and overflow-y for controlling each scrollbar independently is now supported
27272        -overflow:scroll will display scrollbars regardless of the svg overflowing or not (as required by CSS)
27273        -overflow:hidden will cause overflow to be clipped away and scrollbars to be hidden
27274
27275        Merged from Blink r172126 by <ed@opera.com>
27276
27277        Tests: svg/W3C-SVG-1.1-SE/painting-marker-05-f.svg
27278               svg/W3C-SVG-1.1-SE/painting-marker-06-f.svg
27279               svg/animations/animate-viewport-overflow-2.html
27280               svg/animations/animate-viewport-overflow.html
27281               svg/in-html/overflow-repaint.html
27282               svg/in-html/overflow-svg-root-attr.html
27283               svg/in-html/overflow-svg-root-style.html
27284               svg/in-html/overflow-svg-root.html
27285               svg/overflow/overflow-on-outermost-svg-element-horizontal-auto.svg
27286               svg/overflow/overflow-on-outermost-svg-element-vertical-auto.svg
27287               svg/overflow/overflow-scroll-on-outermost-svg-element.svg
27288               svg/overflow/overflow-x-hidden-on-outermost-svg-element-expected.svg
27289               svg/overflow/overflow-x-hidden-on-outermost-svg-element.svg
27290               svg/overflow/overflow-y-hidden-on-outermost-svg-element-expected.svg
27291               svg/overflow/overflow-y-hidden-on-outermost-svg-element.svg
27292
27293        * css/StyleResolver.cpp:
27294        (WebCore::StyleResolver::adjustRenderStyle):
27295        * page/FrameView.cpp:
27296        (WebCore::FrameView::applyOverflowToViewport):
27297        * rendering/svg/RenderSVGRoot.cpp:
27298        (WebCore::RenderSVGRoot::layout):
27299        (WebCore::RenderSVGRoot::shouldApplyViewportClip):
27300        (WebCore::RenderSVGRoot::paintReplaced):
27301        (WebCore::RenderSVGRoot::computeFloatRectForRepaint):
27302        * rendering/svg/RenderSVGRoot.h:
27303        * rendering/svg/SVGRenderSupport.cpp:
27304        (WebCore::SVGRenderSupport::isOverflowHidden):
27305
273062014-05-09  Jer Noble  <jer.noble@apple.com>
27307
27308        [MSE][Mac] Destroy the AVStreamDataParser when the SourceBuffer is removed from its MediaSource.
27309        https://bugs.webkit.org/show_bug.cgi?id=132710
27310
27311        Reviewed by Eric Carlson.
27312
27313        The AVStreamDataParser should be destroyed when the SourceBuffer is removed, so that subsequent
27314        SourceBuffers can utilize resources released by the parser on destruction.
27315
27316        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
27317        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
27318        (-[WebAVStreamDataParserListener invalidate]):
27319        (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:]):  Protect against _parent being invalidated.
27320        (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:withDiscontinuity:]): Ditto.
27321        (-[WebAVStreamDataParserListener streamDataParser:didFailToParseStreamDataWithError:]): Ditto.
27322        (-[WebAVStreamDataParserListener streamDataParser:didProvideMediaData:forTrackID:mediaType:flags:]): Ditto.
27323        (WebCore::SourceBufferPrivateAVFObjC::~SourceBufferPrivateAVFObjC): Call destroyParser();.
27324        (WebCore::SourceBufferPrivateAVFObjC::removedFromMediaSource): Ditto.
27325        (WebCore::SourceBufferPrivateAVFObjC::destroyParser): Call -[WebAVStreamDataParserListener invalidate].
27326
273272014-05-09  Andrei Bucur  <abucur@adobe.com>
27328
27329        [CSS Regions] 1-2% performance regression in html5-full-render after r168286
27330        https://bugs.webkit.org/show_bug.cgi?id=132672
27331
27332        Reviewed by Mihnea Ovidenie.
27333
27334        The patch optimizes the search of regions when there's a single region in the chain.
27335        There's no need to execute advanced search logic, we can directly return that region.
27336
27337        Tests: No function change, no tests.
27338
27339        * rendering/RenderBlock.cpp:
27340        (WebCore::canComputeRegionRangeForBox):
27341        * rendering/RenderFlowThread.cpp:
27342        (WebCore::RenderFlowThread::regionAtBlockOffset):
27343        (WebCore::RenderFlowThread::hasCachedRegionRangeForBox): Renamed from hasRegionRangeForBox to
27344        better suggest what the function does.
27345        (WebCore::RenderFlowThread::getRegionRangeForBox):
27346        (WebCore::RenderFlowThread::hasRegionRangeForBox): Deleted.
27347        * rendering/RenderFlowThread.h:
27348
273492014-05-09  Jer Noble  <jer.noble@apple.com>
27350
27351        [EME] Call suspendIfNeeded() in the MediaKeySession create() method to avoid an ASSERT.
27352        https://bugs.webkit.org/show_bug.cgi?id=132712
27353
27354        Reviewed by Eric Carlson.
27355
27356        All ActiveDOMObject subclasses must call suspendIfNeeded() immediately after creation.
27357
27358        * Modules/encryptedmedia/MediaKeySession.cpp:
27359        (WebCore::MediaKeySession::MediaKeySession):
27360
273612014-05-09  Zalan Bujtas  <zalan@apple.com>
27362
27363        Unreviewed. Another attempt to fix Windows build after r168528.
27364
27365        * platform/graphics/win/FontWin.cpp:
27366        (WebCore::Font::adjustSelectionRectForComplexText):
27367
273682014-05-09  Zalan Bujtas  <zalan@apple.com>
27369
27370        Unreviewed build fix for Win after r168528.
27371
27372        * platform/graphics/win/FontWin.cpp:
27373        (WebCore::Font::adjustSelectionRectForComplexText):
27374
273752014-05-09  Zalan Bujtas  <zalan@apple.com>
27376
27377        REGRESSION (r168095): 1-pixel gap between adjacent selection inlines
27378        https://bugs.webkit.org/show_bug.cgi?id=132474
27379        <rdar://problem/16797394>
27380
27381        Reviewed by David Hyatt.
27382
27383        This patch changes text selection rectangle calculation from integral to device
27384        pixel snapping. It ensures that selection rect painting matches box boundaries for inline elements.
27385        Directional rounding (horizontal only atm) is moved out from Font class and now accessible
27386        to all the painting code. RTL snapping strategy is changed from floor to round to match ltr behavior.
27387        However this patch does not address all the integral snapping across inline elements. There are
27388        a few places where we still calculate enclosing rects where snapping is sufficient.
27389
27390        Test: fast/inline/hidpi-pixel-gap-between-adjacent-selection-inlines.html
27391
27392        * platform/LayoutUnit.h:
27393        (WebCore::roundToDevicePixel): added fudge factor to change rounding direction as directed.
27394        * platform/graphics/Font.cpp:
27395        (WebCore::Font::adjustSelectionRectForText):
27396        (WebCore::Font::selectionRectForText): Deleted.
27397        * platform/graphics/Font.h:
27398        * platform/graphics/FontFastPath.cpp:
27399        (WebCore::Font::adjustSelectionRectForSimpleText): removed directional rounding.
27400        (WebCore::Font::selectionRectForSimpleText): Deleted.
27401        * platform/graphics/GraphicsContext.cpp:
27402        (WebCore::GraphicsContext::drawHighlightForText): Deleted.
27403        * platform/graphics/GraphicsContext.h:
27404        * platform/graphics/LayoutPoint.h:
27405        (WebCore::roundedForPainting):
27406        * platform/graphics/LayoutRect.h:
27407        (WebCore::directionalPixelSnappedForPainting): Snap top right corner for rtl direction.
27408        * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
27409        (WebCore::Font::adjustSelectionRectForComplexText):
27410        (WebCore::Font::selectionRectForComplexText): Deleted.
27411        * platform/graphics/mac/FontComplexTextMac.cpp:
27412        (WebCore::Font::adjustSelectionRectForComplexText): removed directional rounding.
27413        (WebCore::Font::selectionRectForComplexText): Deleted.
27414        * platform/graphics/win/FontWin.cpp:
27415        (WebCore::Font::adjustSelectionRectForComplexText):
27416        (WebCore::Font::selectionRectForComplexText): Deleted.
27417        * rendering/EllipsisBox.cpp:
27418        (WebCore::EllipsisBox::selectionRect):
27419        (WebCore::EllipsisBox::paintSelection):
27420        * rendering/InlineTextBox.cpp:
27421        (WebCore::integralEnclosingRectForSelection): helper to address enclosing empty rect problem.
27422        (WebCore::InlineTextBox::localSelectionRect):
27423        (WebCore::InlineTextBox::paintSelection):
27424        (WebCore::InlineTextBox::paintCompositionBackground):
27425        (WebCore::InlineTextBox::paintDocumentMarker):
27426        (WebCore::InlineTextBox::paintTextMatchMarker):
27427        (WebCore::InlineTextBox::computeRectForReplacementMarker):
27428        (WebCore::InlineTextBox::positionForOffset):
27429        * rendering/svg/SVGInlineTextBox.cpp:
27430        (WebCore::SVGInlineTextBox::selectionRectForTextFragment):
27431
274322014-05-09  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
27433
27434        ASSERTION FAILED: !m_code || m_code == defaultExceptionCode
27435        in WebCore::constructQualifiedName
27436        https://bugs.webkit.org/show_bug.cgi?id=132343
27437
27438        'Remove bad assertion in SVGSMILElement's constructQualifiedName() by passing
27439        IGNORE_EXCEPTION instead ASSERT_NO_EXCEPTION to Document::parseQualifiedName().
27440        The constructQualifiedName() function handles parseQualifiedName() failures
27441        propertly by returning early so there is no reason to assert on parsing
27442        failures.'
27443
27444        Blink merge: http://src.chromium.org/viewvc/blink?view=revision&revision=173564
27445        Based on the patch made by Christophe Dumez <ch.dumez@samsung.com>.
27446
27447        Reviewed by Dirk Schulze.
27448
27449        Test: svg/custom/bad-attributeName-crash.html
27450
27451        * svg/animation/SVGSMILElement.cpp:
27452        (WebCore::constructQualifiedName):
27453
274542014-05-08  Brent Fulgham  <bfulgham@apple.com>
27455
27456        Multiple (stacked) cues when shuttling through video while playing closed captions
27457        https://bugs.webkit.org/show_bug.cgi?id=132715
27458        <rdar://problem/16795782>
27459
27460        Reviewed by Eric Carlson.
27461
27462        Tests: media/track/track-in-band-cues-added-once.html
27463
27464        * html/track/TextTrack.cpp:
27465        (WebCore::TextTrack::hasCue): Revise to use a relaxed time equality.
27466        * html/track/TextTrackCue.cpp:
27467        (WebCore::TextTrackCue::isEqual): Ditto.
27468        (WebCore::TextTrackCue::hasEquivalentStartTime): Added.
27469        * html/track/TextTrackCue.h:
27470        (WebCore::TextTrackCue::startTimeVariance): Added.
27471        * html/track/TextTrackCueGeneric.h:
27472        * html/track/TextTrackCueGeneric.cpp:
27473        (WebCore::TextTrackCueGeneric::isEqual): Do not call the VTTCue::isEqual method from
27474        this class, since cueType() will not equal VTTCue, and the equality will fail.
27475
274762014-05-08  Alexey Proskuryakov  <ap@apple.com>
27477
27478        Automatically zip document bundles used via File API
27479        https://bugs.webkit.org/show_bug.cgi?id=132713
27480        <rdar://problem/13397892>
27481
27482        Reviewed by Anders Carlsson.
27483
27484        Tests: fast/files/filereader-zip-bundle.html
27485               http/tests/local/fileapi/upload-zip-bundle-as-blob.html
27486
27487        * FileMac.mm: Added.
27488        (WebCore::File::shouldReplaceFile):
27489        (WebCore::File::computeNameAndContentTypeForReplacedFile):
27490        Added code that decides what to do with a bundle. We need this to happen in
27491        WebProcess, because HTML5 dropzone depends on this, it needs to know file type
27492        even before a File object can be created.
27493
27494        * WebCore.exp.in: Export new functions.
27495
27496        * WebCore.xcodeproj/project.pbxproj: Added new files.
27497
27498        * dom/DataTransfer.cpp: (WebCore::DataTransfer::hasFileOfType): Updated for File
27499        interface change.
27500
27501        * fileapi/File.h:
27502        * fileapi/File.cpp:
27503        (WebCore::File::File):
27504        (WebCore::File::computeNameAndContentType):
27505        (WebCore::File::contentTypeForFile):
27506        (WebCore::File::contentTypeFromFilePathOrName): Deleted.
27507        Make it possible for a subclass to affect file name and content type calculation.
27508
27509        * platform/network/BlobDataFileReference.cpp:
27510        (WebCore::BlobDataFileReference::BlobDataFileReference):
27511        (WebCore::BlobDataFileReference::~BlobDataFileReference):
27512        (WebCore::BlobDataFileReference::path):
27513        (WebCore::BlobDataFileReference::size):
27514        (WebCore::BlobDataFileReference::expectedModificationTime):
27515        (WebCore::BlobDataFileReference::startTrackingModifications):
27516        * platform/network/BlobDataFileReference.h:
27517        (WebCore::BlobDataFileReference::path): Deleted.
27518        (WebCore::BlobDataFileReference::BlobDataFileReference): Deleted.
27519        Use original or replaced file, as appropriate. 
27520
27521        * platform/network/mac/BlobDataFileReferenceMac.mm: Added.
27522        (WebCore::BlobDataFileReference::generateReplacementFile): Implements generateReplacementFile().
27523
27524        * platform/network/FormData.h: Added a FIXME.
27525
27526        * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::send): Always use Blob code path
27527        for blobs, don't unwrap them into a file path.
27528
275292014-05-08  Simon Fraser  <simon.fraser@apple.com>
27530
27531        Occasional crash under AsyncScrollingCoordinator::frameViewRootLayerDidChange() on history navigation
27532        https://bugs.webkit.org/show_bug.cgi?id=132723
27533
27534        Reviewed by Sam Weinig.
27535        
27536        Crash reports suggest that when we call AsyncScrollingCoordinator::frameViewRootLayerDidChange()
27537        from HistoryController::restoreScrollPositionAndViewState(), the FrameView may not have a 
27538        scrolling node ID, which suggests that either the FrameView doesn't have a RenderView,
27539        or compositing hasn't happened yet.
27540        
27541        So if we enter AsyncScrollingCoordinator::frameViewRootLayerDidChange()
27542        and the FrameView has no scrollLayerID, just return. We'll fix things up
27543        when compositing kicks in later.
27544
27545        * page/scrolling/AsyncScrollingCoordinator.cpp:
27546        (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
27547
275482014-05-08  Simon Fraser  <simon.fraser@apple.com>
27549
27550        [iOS WK2] Bottom-relative position:fixed elements are misplaced on page load
27551        https://bugs.webkit.org/show_bug.cgi?id=132719
27552        <rdar://problem/16860837>
27553
27554        Reviewed by Benjamin Poulain.
27555
27556        Add a couple of functions, and sort.
27557
27558        * WebCore.exp.in:
27559
275602014-05-08  Jer Noble  <jer.noble@apple.com>
27561
27562        [Mac, iOS] Add source application accounting to AVURLAsset.
27563        https://bugs.webkit.org/show_bug.cgi?id=132637
27564
27565        Reviewed by Eric Carlson.
27566
27567        Properly account for the application responisble for data loading by passing the source
27568        application identifier through to AVFoundation through AVURLAsset options.
27569
27570        * html/HTMLMediaElement.cpp:
27571        (WebCore::HTMLMediaElement::parseAttribute):
27572        * html/HTMLMediaElement.h:
27573        * platform/graphics/MediaPlayer.cpp:
27574        (WebCore::MediaPlayer::sourceApplicationIdentifier):
27575        * platform/graphics/MediaPlayer.h:
27576        (WebCore::MediaPlayerClient::mediaPlayerSourceApplicationIdentifier):
27577        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
27578        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL):
27579        * platform/network/NetworkingContext.h:
27580
275812014-05-08  Jer Noble  <jer.noble@apple.com>
27582
27583        [MSE][Mac] Move AVStreamDataParser off-main-thread.
27584        https://bugs.webkit.org/show_bug.cgi?id=132698
27585
27586        Reviewed by Eric Carlson.
27587
27588        -[AVStreamDataParser appendStreamData:] can casue the main thread to hang when a
27589        large amount of media data is appended at once. Move the actual parsing of data
27590        to a background (synchronous) dispatch queue, and split SourceBuffer::appendBufferTimerFired
27591        into two functions, the latter of which will be called after the background queue
27592        completes.
27593
27594        * Modules/mediasource/SourceBuffer.cpp:
27595        (WebCore::SourceBuffer::appendBufferTimerFired): Split into sourceBufferPrivateAppendComplete.
27596        (WebCore::SourceBuffer::sourceBufferPrivateAppendComplete): Split from appendBufferTimerFired.
27597        * Modules/mediasource/SourceBuffer.h:
27598        * platform/graphics/SourceBufferPrivate.h:
27599        * platform/graphics/SourceBufferPrivateClient.h:
27600        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
27601        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
27602        (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:]): Re-dispatch to the
27603                web thread.
27604        (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:withDiscontinuity:]): Ditto.
27605        (-[WebAVStreamDataParserListener streamDataParser:didFailToParseStreamDataWithError:]): Ditto.
27606        (-[WebAVStreamDataParserListener streamDataParser:didProvideMediaData:forTrackID:mediaType:flags:]): Ditto.
27607        (-[WebAVStreamDataParserListener streamDataParser:didReachEndOfTrackWithTrackID:mediaType:]): Ditto.
27608        (-[WebAVStreamDataParserListener streamDataParser:didProvideContentKeyRequestInitializationData:forTrackID:]): Ditto.
27609        (WebCore::globalDataParserQueue): Added.
27610        (WebCore::SourceBufferPrivateAVFObjC::append): Dispatch to the globalDataParserQueue.
27611        (WebCore::SourceBufferPrivateAVFObjC::appendCompleted): Added.
27612        * platform/mock/mediasource/MockSourceBufferPrivate.cpp:
27613        (WebCore::MockSourceBufferPrivate::append): Adopt sourceBufferPrivateAppendComplete.
27614        * platform/mock/mediasource/MockSourceBufferPrivate.h:
27615
27616        Update SourceBufferPrivateGStreamer to match the new append return value:
27617        * platform/graphics/gstreamer/SourceBufferPrivateGStreamer.cpp:
27618        (WebCore::SourceBufferPrivateGStreamer::append):
27619        * platform/graphics/gstreamer/SourceBufferPrivateGStreamer.h:
27620
276212014-05-08  Commit Queue  <commit-queue@webkit.org>
27622
27623        Unreviewed, rolling out r168498.
27624        https://bugs.webkit.org/show_bug.cgi?id=132714
27625
27626        broke Mavericks WK2 (Requested by litherum on #webkit).
27627
27628        Reverted changeset:
27629
27630        "http/tests/security/xss-DENIED-xsl-document-redirect.xml
27631        fails with NetworkProcess"
27632        https://bugs.webkit.org/show_bug.cgi?id=132523
27633        http://trac.webkit.org/changeset/168498
27634
276352014-05-08  Myles C. Maxfield  <mmaxfield@apple.com>
27636
27637        http/tests/security/xss-DENIED-xsl-document-redirect.xml fails with NetworkProcess
27638        https://bugs.webkit.org/show_bug.cgi?id=132523
27639
27640        Reviewed by Alexey Proskuryakov.
27641
27642        We should not manufacture a response in the event of an error during a
27643        synchronous XHR. In addition, this test removes one place that is
27644        sensitive to such a manufactured response.
27645
27646        Updates test expectations.
27647
27648        * platform/network/cf/ResourceHandleCFNet.cpp:
27649        (WebCore::ResourceHandle::platformLoadResourceSynchronously): Do not
27650        manufacture a response
27651        * platform/network/mac/ResourceHandleMac.mm:
27652        (WebCore::ResourceHandle::platformLoadResourceSynchronously): Do not
27653        manufacture a response
27654        * xml/XSLTProcessorLibxslt.cpp:
27655        (WebCore::docLoaderFunc): Only use the response's URL if no error
27656        occurred.
27657
276582014-05-08  Andreas Kling  <akling@apple.com>
27659
27660        [iOS] WebKit should listen to critical memory warnings.
27661        <https://webkit.org/b/132704>
27662        <rdar://problem/16857112>
27663
27664        Listen for DISPATCH_MEMORYSTATUS_PRESSURE_CRITICAL in addition to
27665        DISPATCH_MEMORYSTATUS_PRESSURE_WARN, since we may only get the critical
27666        notification on some systems.
27667
27668        Reviewed by Gavin Barraclough.
27669
27670        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
27671        (WebCore::MemoryPressureHandler::install):
27672
276732014-05-08  Joseph Pecoraro  <pecoraro@apple.com>
27674
27675        Web Inspector: InspectorDOMAgent::getAccessibilityPropertiesForNode should gracefully handle bad node
27676        https://bugs.webkit.org/show_bug.cgi?id=132697
27677
27678        Reviewed by Timothy Hatcher.
27679
27680        * inspector/InspectorDOMAgent.cpp:
27681        (WebCore::InspectorDOMAgent::getAccessibilityPropertiesForNode):
27682        Gracefully handle no node.
27683
276842014-05-08  Tim Horton  <timothy_horton@apple.com>
27685
27686        Fix the iOS build after r168476.
27687
27688        * platform/graphics/mac/GraphicsContextMac.mm:
27689        (WebCore::GraphicsContext::drawFocusRing):
27690
276912014-05-08  Bem Jones-Bey  <bjonesbe@adobe.com>
27692
27693        [CSS Shapes] Shapes do not resolve dimensions specified in viewport units
27694        https://bugs.webkit.org/show_bug.cgi?id=124052
27695
27696        Reviewed by Dirk Schulze.
27697
27698        Viewport unit resolution doesn't work unless the RenderView is passed
27699        down into the floatValueForLength methods. All this does is plumb down
27700        a RenderView in all of these cases.
27701
27702        Tests: css3/masking/clip-path-polygon-viewport-units.html
27703               fast/shapes/shape-outside-floats/shape-outside-floats-viewport-units.html
27704
27705        * css/BasicShapeFunctions.cpp:
27706        (WebCore::floatValueForCenterCoordinate):
27707        * css/BasicShapeFunctions.h:
27708        * css/LengthFunctions.cpp:
27709        (WebCore::floatSizeForLengthSize):
27710        * css/LengthFunctions.h:
27711        * rendering/ClipPathOperation.h:
27712        (WebCore::ShapeClipPathOperation::pathForReferenceRect):
27713        (WebCore::BoxClipPathOperation::pathForReferenceRect):
27714        * rendering/RenderLayer.cpp:
27715        (WebCore::RenderLayer::setupClipPath):
27716        * rendering/shapes/Shape.cpp:
27717        (WebCore::Shape::createShape):
27718        * rendering/shapes/Shape.h:
27719        * rendering/shapes/ShapeOutsideInfo.cpp:
27720        (WebCore::ShapeOutsideInfo::computedShape):
27721        * rendering/style/BasicShapes.cpp:
27722        (WebCore::BasicShapeCircle::floatValueForRadiusInBox):
27723        (WebCore::BasicShapeCircle::path):
27724        (WebCore::BasicShapeEllipse::floatValueForRadiusInBox):
27725        (WebCore::BasicShapeEllipse::path):
27726        (WebCore::BasicShapePolygon::path):
27727        (WebCore::floatSizeForLengthSize):
27728        (WebCore::BasicShapeInset::path):
27729        * rendering/style/BasicShapes.h:
27730        * rendering/svg/SVGRenderingContext.cpp:
27731        (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
27732
277332014-05-08  Brent Fulgham  <bfulgham@apple.com>
27734
27735        Cue display events may not be registered during page load.
27736        https://bugs.webkit.org/show_bug.cgi?id=132696
27737        <rdar://problem/16652874>
27738
27739        Reviewed by Eric Carlson.
27740
27741        * Modules/mediacontrols/mediaControlsApple.js:
27742        (Controller.prototype.handleTextTrackAdd): Don't register
27743        for 'cuechange' events anymore.
27744        (Controller.prototype.handleTextTrackRemove): Ditto.
27745        (Controller.prototype.updateCaptionContainer): Reduce CSS
27746        churn by not adding/removing 'Hidden' class every time a
27747        new cue is processed. Only do this when transitioning
27748        track display state.
27749        (Controller.prototype.handleTextTrackCueChange): Deleted.
27750        * html/HTMLMediaElement.cpp:
27751        (WebCore::HTMLMediaElement::updateTextTrackDisplay): Call
27752        'updateTextTrackContainer' directory when processing cues,
27753        rather than trampolining through the JS layer.
27754
277552014-05-08  Alexey Proskuryakov  <ap@apple.com>
27756
27757        Make BlobDataFileReference manage its sandbox extension
27758        https://bugs.webkit.org/show_bug.cgi?id=132689
27759
27760        Reviewed by Anders Carlsson.
27761
27762        * WebCore.exp.in: Export symbols that are now needed in WebKit2 to subclass BlobDataFileReference.
27763
27764        * fileapi/ThreadableBlobRegistry.cpp: (WebCore::ThreadableBlobRegistry::registerFileBlobURL):
27765        * platform/network/BlobData.cpp: (WebCore::BlobData::appendFile):
27766        * platform/network/BlobData.h: (WebCore::BlobDataItem::BlobDataItem):
27767        * platform/network/BlobRegistry.h:
27768        * platform/network/BlobRegistryImpl.cpp: (WebCore::BlobRegistryImpl::registerFileBlobURL):
27769        * platform/network/BlobRegistryImpl.h:
27770        BlobRegistry now takes a BlobDataFileReference and not a path, so that WebKit2
27771        could pass objects that include sandbox extensions.
27772
27773        * platform/network/BlobDataFileReference.h:
27774        * platform/network/BlobDataFileReference.cpp:
27775        (WebCore::BlobDataFileReference::~BlobDataFileReference): Added a virtual destructor.
27776        (WebCore::BlobDataFileReference::size): We now record the size and modification time right away, no need to lazily calculate them.
27777        (WebCore::BlobDataFileReference::expectedModificationTime): Ditto.
27778        (WebCore::BlobDataFileReference::startTrackingModifications): Record time and size
27779        (since it's a single call). However, size calculation will become complicated again soon.
27780        (WebCore::BlobDataFileReference::prepareForFileAccess): A hook for subclasses.
27781        (WebCore::BlobDataFileReference::revokeFileAccess): Ditto.
27782        (WebCore::BlobDataFileReference::computeFileSystemData): Deleted.
27783
277842014-05-08  Rik Cabanier  <cabanier@adobe.com>
27785
27786        Add support for drawFocusIfNeeded
27787        https://bugs.webkit.org/show_bug.cgi?id=132584
27788
27789        Reviewed by Dirk Schulze.
27790
27791        The drawFocusIfNeeded API will draw a focus ring if the element that is passed
27792        in is focused and a child element of the canvas.
27793
27794        Test: fast/canvas/draw-focus-if-needed.html
27795
27796        * html/canvas/CanvasRenderingContext2D.cpp:
27797        (WebCore::CanvasRenderingContext2D::drawFocusIfNeeded):
27798        * html/canvas/CanvasRenderingContext2D.h:
27799        * html/canvas/CanvasRenderingContext2D.idl:
27800
278012014-05-08  Antti Koivisto  <antti@apple.com>
27802
27803        [iOS WebKit2] Can't activate text fields on Facebook
27804        https://bugs.webkit.org/show_bug.cgi?id=132682
27805
27806        Reviewed by Enrica Casucci.
27807
27808        * page/DOMTimer.cpp:
27809        (WebCore::DOMTimer::fired):
27810        
27811            The isDocument() test here had reversed in the merge breaking content change observer callback.
27812
278132014-05-07  Sergio Villar Senin  <svillar@igalia.com>
27814
27815        Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in svg/
27816        https://bugs.webkit.org/show_bug.cgi?id=132647
27817
27818        Reviewed by Darin Adler.
27819
27820        * svg/SVGAElement.cpp:
27821        (WebCore::SVGAElement::isSupportedAttribute):
27822        * svg/SVGAnimateMotionElement.cpp:
27823        (WebCore::SVGAnimateMotionElement::isSupportedAttribute):
27824        * svg/SVGAnimateTransformElement.cpp:
27825        (WebCore::SVGAnimateTransformElement::isSupportedAttribute):
27826        * svg/SVGAnimatedLength.cpp:
27827        (WebCore::sharedSVGLength):
27828        * svg/SVGAnimationElement.cpp:
27829        (WebCore::SVGAnimationElement::isSupportedAttribute):
27830        * svg/SVGCircleElement.cpp:
27831        (WebCore::SVGCircleElement::isSupportedAttribute):
27832        * svg/SVGClipPathElement.cpp:
27833        (WebCore::SVGClipPathElement::isSupportedAttribute):
27834        * svg/SVGComponentTransferFunctionElement.cpp:
27835        (WebCore::SVGComponentTransferFunctionElement::isSupportedAttribute):
27836        * svg/SVGCursorElement.cpp:
27837        (WebCore::SVGCursorElement::isSupportedAttribute):
27838        * svg/SVGElement.cpp:
27839        (WebCore::SVGElement::instancesForElement):
27840        (WebCore::SVGElement::childShouldCreateRenderer):
27841        * svg/SVGEllipseElement.cpp:
27842        (WebCore::SVGEllipseElement::isSupportedAttribute):
27843        * svg/SVGFEBlendElement.cpp:
27844        (WebCore::SVGFEBlendElement::isSupportedAttribute):
27845        * svg/SVGFEColorMatrixElement.cpp:
27846        (WebCore::SVGFEColorMatrixElement::isSupportedAttribute):
27847        * svg/SVGFEComponentTransferElement.cpp:
27848        (WebCore::SVGFEComponentTransferElement::isSupportedAttribute):
27849        * svg/SVGFECompositeElement.cpp:
27850        (WebCore::SVGFECompositeElement::isSupportedAttribute):
27851        * svg/SVGFEConvolveMatrixElement.cpp:
27852        (WebCore::SVGFEConvolveMatrixElement::isSupportedAttribute):
27853        * svg/SVGFEDiffuseLightingElement.cpp:
27854        (WebCore::SVGFEDiffuseLightingElement::isSupportedAttribute):
27855        * svg/SVGFEDisplacementMapElement.cpp:
27856        (WebCore::SVGFEDisplacementMapElement::isSupportedAttribute):
27857        * svg/SVGFEDropShadowElement.cpp:
27858        (WebCore::SVGFEDropShadowElement::isSupportedAttribute):
27859        * svg/SVGFEGaussianBlurElement.cpp:
27860        (WebCore::SVGFEGaussianBlurElement::isSupportedAttribute):
27861        * svg/SVGFEImageElement.cpp:
27862        (WebCore::SVGFEImageElement::isSupportedAttribute):
27863        * svg/SVGFELightElement.cpp:
27864        (WebCore::SVGFELightElement::isSupportedAttribute):
27865        * svg/SVGFEMergeNodeElement.cpp:
27866        (WebCore::SVGFEMergeNodeElement::isSupportedAttribute):
27867        * svg/SVGFEMorphologyElement.cpp:
27868        (WebCore::SVGFEMorphologyElement::isSupportedAttribute):
27869        * svg/SVGFEOffsetElement.cpp:
27870        (WebCore::SVGFEOffsetElement::isSupportedAttribute):
27871        * svg/SVGFESpecularLightingElement.cpp:
27872        (WebCore::SVGFESpecularLightingElement::isSupportedAttribute):
27873        * svg/SVGFETileElement.cpp:
27874        (WebCore::SVGFETileElement::isSupportedAttribute):
27875        * svg/SVGFETurbulenceElement.cpp:
27876        (WebCore::SVGFETurbulenceElement::isSupportedAttribute):
27877        * svg/SVGFilterElement.cpp:
27878        (WebCore::SVGFilterElement::isSupportedAttribute):
27879        (WebCore::SVGFilterElement::childShouldCreateRenderer):
27880        * svg/SVGFilterPrimitiveStandardAttributes.cpp:
27881        (WebCore::SVGFilterPrimitiveStandardAttributes::isSupportedAttribute):
27882        * svg/SVGForeignObjectElement.cpp:
27883        (WebCore::SVGForeignObjectElement::isSupportedAttribute):
27884        * svg/SVGGElement.cpp:
27885        (WebCore::SVGGElement::isSupportedAttribute):
27886        * svg/SVGGradientElement.cpp:
27887        (WebCore::SVGGradientElement::isSupportedAttribute):
27888        * svg/SVGGraphicsElement.cpp:
27889        (WebCore::SVGGraphicsElement::isSupportedAttribute):
27890        * svg/SVGImageElement.cpp:
27891        (WebCore::SVGImageElement::isSupportedAttribute):
27892        * svg/SVGLength.cpp:
27893        (WebCore::SVGLength::lengthModeForAnimatedLengthAttribute):
27894        * svg/SVGLineElement.cpp:
27895        (WebCore::SVGLineElement::isSupportedAttribute):
27896        * svg/SVGLinearGradientElement.cpp:
27897        (WebCore::SVGLinearGradientElement::isSupportedAttribute):
27898        * svg/SVGMPathElement.cpp:
27899        (WebCore::SVGMPathElement::isSupportedAttribute):
27900        * svg/SVGMarkerElement.cpp:
27901        (WebCore::SVGMarkerElement::isSupportedAttribute):
27902        * svg/SVGMaskElement.cpp:
27903        (WebCore::SVGMaskElement::isSupportedAttribute):
27904        * svg/SVGPathElement.cpp:
27905        (WebCore::SVGPathElement::isSupportedAttribute):
27906        * svg/SVGPatternElement.cpp:
27907        (WebCore::SVGPatternElement::isSupportedAttribute):
27908        * svg/SVGPolyElement.cpp:
27909        (WebCore::SVGPolyElement::isSupportedAttribute):
27910        * svg/SVGRadialGradientElement.cpp:
27911        (WebCore::SVGRadialGradientElement::isSupportedAttribute):
27912        * svg/SVGRectElement.cpp:
27913        (WebCore::SVGRectElement::isSupportedAttribute):
27914        * svg/SVGScriptElement.cpp:
27915        (WebCore::SVGScriptElement::isSupportedAttribute):
27916        * svg/SVGStopElement.cpp:
27917        (WebCore::SVGStopElement::isSupportedAttribute):
27918        * svg/SVGStyleElement.cpp:
27919        (WebCore::SVGStyleElement::isSupportedAttribute):
27920        * svg/SVGSymbolElement.cpp:
27921        (WebCore::SVGSymbolElement::isSupportedAttribute):
27922        * svg/SVGTRefElement.cpp:
27923        (WebCore::SVGTRefElement::isSupportedAttribute):
27924        * svg/SVGTests.cpp:
27925        (WebCore::SVGTests::attributeToPropertyMap):
27926        * svg/SVGTextContentElement.cpp:
27927        (WebCore::SVGTextContentElement::textLengthAnimated):
27928        (WebCore::SVGTextContentElement::isSupportedAttribute):
27929        * svg/SVGTextPathElement.cpp:
27930        (WebCore::SVGTextPathElement::isSupportedAttribute):
27931        * svg/SVGTextPositioningElement.cpp:
27932        (WebCore::SVGTextPositioningElement::isSupportedAttribute):
27933        * svg/SVGUseElement.cpp:
27934        (WebCore::SVGUseElement::isSupportedAttribute):
27935        (WebCore::isDisallowedElement):
27936        * svg/SVGViewElement.cpp:
27937        (WebCore::SVGViewElement::isSupportedAttribute):
27938
279392014-05-08  Ion Rosca  <rosca@adobe.com>
27940
27941        [CSS Blending] Replacing Unisolated with NotIsolated in variables and methods names
27942        https://bugs.webkit.org/show_bug.cgi?id=132677
27943
27944        Reviewed by Dirk Schulze.
27945
27946        No new tests required.
27947
27948        * rendering/RenderLayer.cpp:
27949        (WebCore::RenderLayer::RenderLayer):
27950        (WebCore::RenderLayer::updateAncestorChainHasBlendingDescendants):
27951        (WebCore::RenderLayer::dirtyAncestorChainHasBlendingDescendants):
27952        (WebCore::RenderLayer::updateDescendantDependentFlags):
27953        hasUnisolatedBlendingDescendants -> hasNotIsolatedBlendingDescendants
27954        (WebCore::RenderLayer::addChild):
27955        (WebCore::RenderLayer::removeChild):
27956        (WebCore::RenderLayer::updateStackingContextsAfterStyleChange):
27957        * rendering/RenderLayer.h:
27958        m_hasUnisolatedBlendingDescendants -> m_hasNotIsolatedBlendingDescendants
27959        m_hasUnisolatedBlendingDescendantsStatusDirty -> m_hasNotIsolatedBlendingDescendantsStatusDirty
27960        hasUnisolatedBlendingDescendants() -> hasNotIsolatedBlendingDescendants()
27961        hasUnisolatedBlendingDescendantsStatusDirty() -> hasNotIsolatedBlendingDescendantsStatusDirty()
27962        m_hasUnisolatedCompositedBlendingDescendants -> m_hasNotIsolatedCompositedBlendingDescendants
27963        hasUnisolatedCompositedBlendingDescendants() -> hasNotIsolatedCompositedBlendingDescendants()
27964        setHasUnisolatedCompositedBlendingDescendants() -> setHasNotIsolatedCompositedBlendingDescendants
27965        * rendering/RenderLayerCompositor.cpp:
27966        (WebCore::CompositingState::CompositingState):
27967        m_hasUnisolatedCompositedBlendingDescendants -> m_hasNotIsolatedCompositedBlendingDescendants
27968        (WebCore::RenderLayerCompositor::computeCompositingRequirements):
27969
279702014-05-08  Xabier Rodriguez Calvar  <calvaris@igalia.com>
27971
27972        [GTK] Enable skipped http/tests/media/hls/video-controls-live-stream.html
27973        https://bugs.webkit.org/show_bug.cgi?id=132329
27974
27975        Reviewed by Eric Carlson.
27976
27977        GTK port needed to define what happened with live stream media
27978        controls. Now we disable and dim the timeline and tweak the
27979        timers.
27980
27981        Test: http/tests/media/hls/video-controls-live-stream.html.
27982
27983        * Modules/mediacontrols/mediaControlsGtk.js:
27984        (ControllerGtk.prototype.configureControls): Moved logic from
27985        setControlsType and changed to use an early return.
27986        (ControllerGtk.prototype.reconnectControls): Redefined to just
27987        configure the controls.
27988        (ControllerGtk.prototype.handlePlay): If stream is live we don't
27989        activate the current time just in case.
27990        (ControllerGtk.prototype.updateDuration): Calls the superclass and
27991        sets timeline.max to 0.
27992        (ControllerGtk.prototype.setControlsType): Deleted.
27993        (ControllerGtk.prototype.setIsLive): Configures controls and
27994        disables the timeline if stream is live.
27995        * css/mediaControlsGtk.css:
27996        (audio::-webkit-media-controls-timeline[disabled])
27997        (video::-webkit-media-controls-timeline[disabled]): Dimmed the
27998        timeline by setting opacity to 0.3.
27999
280002014-05-08  Ion Rosca  <rosca@adobe.com>
28001
28002        [CSS Blending] Changing isolation CSS property should not trigger repaint in RenderStyle::changeRequiresLayerRepaint
28003        https://bugs.webkit.org/show_bug.cgi?id=131436
28004
28005        Reviewed by Dirk Schulze.
28006
28007        The isolation:isolate property will create a stacking context. This is done in
28008        StyleResolver::adjustRenderStyle where z-index is forced to 0.
28009        If the element is already a stacking context for any other reason,
28010        changing the isolation flag should not have any effect.
28011
28012        Tests: css3/blending/repaint/blend-mode-turn-off-isolation-no-effect.html
28013               css3/blending/repaint/blend-mode-turn-off-isolation.html
28014
28015        * rendering/style/RenderStyle.cpp:
28016        (WebCore::RenderStyle::changeRequiresLayerRepaint):
28017        do not request repaint if isolation has changed.
28018
280192014-05-08  Manuel Rego Casasnovas  <rego@igalia.com>
28020
28021        REGRESSION (r167652): SelectionState is not set properly for non leaf objects in pages with regions
28022        https://bugs.webkit.org/show_bug.cgi?id=132493
28023
28024        Reviewed by David Hyatt.
28025
28026        Non selection leaf elements were not included in the selection ranges,
28027        that was causing that their selection state was not set properly and
28028        when one of the element was removed as it was marked as SelectionNone
28029        current selection was not removed.
28030
28031        Due to this fix, the regression detected in bug #131982 arose again.
28032        Reverted changes from r167675 and reopened bug as previous fix was not
28033        right. Updated TestExpectations accordingly.
28034
28035        Test: fast/regions/selection/crash-select-all.html
28036
28037        * rendering/RenderView.cpp:
28038        (WebCore::RenderView::splitSelectionBetweenSubtrees): We need to include
28039        non selection leafs in the range, otherwise we won't be marking
28040        selection state of some elements properly.
28041
280422014-05-08  Zoltan Horvath  <zoltan@webkit.org>
28043
28044        [CSS Shapes] Can't select content within the area of the floating box when clip-path is applied
28045        https://bugs.webkit.org/show_bug.cgi?id=131375
28046
28047        Reviewed by Dirk Schulze.
28048
28049        According to http://www.w3.org/TR/css-masking-1/, the clipped part of the element should
28050        not have pointer event dispatching. So add this logic to RenderBlock::nodeAtPoint. This
28051        fixes the bug as it disallows selection on any clipped parts.
28052
28053        I implemented the proper selection for the various CSS box types and added testing
28054        for them. Also, I made and run performance tests for exposing mouse events over the
28055        clipped/non-clipped area, which results can be seen in bugzilla.
28056
28057        Based on the patch made by Rob Buis <rob.buis@samsung.com>
28058        Blink revision: http://src.chromium.org/viewvc/blink?view=revision&revision=172619
28059
28060        Tests: fast/masking/clip-path-selection.html
28061               fast/shapes/shape-outside-floats/shape-outside-clip-path-selection.html
28062
28063        * rendering/RenderBlock.cpp:
28064        (WebCore::RenderBlock::nodeAtPoint):
28065
280662014-05-07  Ion Rosca  <rosca@adobe.com>
28067
28068        [CSS Blending] Blending doesn't work if the parent stacking context is not a self painting layer
28069        https://bugs.webkit.org/show_bug.cgi?id=130891
28070
28071        Reviewed by Dean Jackson.
28072
28073        The stacking context layers having unisolated blending descendants should be able
28074        to create transparency layers or to become composited in order to restrict blending 
28075        content to accessing the information outside the current stacking context.
28076        Some layers are not self painting layers and these layers cannot crate transparency
28077        layers and cannot be composited, thus they are not able to isolate blending descendants
28078        when it's required.
28079        
28080        The solution in this patch is to make a layer isSelfPaintingLayer when
28081        it needs to isolate blending descendants (hasUnisolatedBlendingDescendants).
28082
28083        Tests: css3/blending/blend-mode-isolation-accelerated-overflow-hidden.html
28084               css3/blending/blend-mode-isolation-overflow-hidden.html
28085               css3/blending/blend-mode-isolation-turn-off-self-painting-layer.html
28086               css3/blending/blend-mode-isolation-turn-off-self-painting-layer1.html
28087               css3/blending/blend-mode-isolation-turn-off-self-painting-layer2.html
28088               css3/blending/blend-mode-isolation-turn-on-self-painting-layer.html
28089
28090        * rendering/RenderLayer.cpp:
28091        (WebCore::RenderLayer::updateAncestorChainHasBlendingDescendants):
28092        When hasUnisolatedBlendingDescendants is set we make sure that isSelfPaintingLayer flag is set too.
28093        (WebCore::RenderLayer::updateDescendantDependentFlags):
28094        The flags might be read or changed while walking the descendants, so we don't want to reset
28095        them before traversing the tree.
28096        (WebCore::RenderLayer::shouldBeSelfPaintingLayer):
28097        Adding isolatesBlending() condition for a layer to be self painting.
28098        * rendering/RenderLayer.h:
28099        Removing ASSERT from hasUnisolatedBlendingDescendants(). It crashes in minibrowser
28100        and in layout tests when painting contents. Similar bugs on other flags: #71044, #71277.
28101        * rendering/RenderLayerModelObject.cpp:
28102        (WebCore::RenderLayerModelObject::styleDidChange):
28103        Telling ancestors that blend mode property has been removed from CSS when the layer for
28104        this element is going to be removed; styleChanged will not be called anymore.
28105
281062014-05-06  Myles C. Maxfield  <mmaxfield@apple.com>
28107
28108        Dragging text from one paragraph to another does not render as expected
28109        https://bugs.webkit.org/show_bug.cgi?id=132633
28110
28111        Reviewed by Darin Adler and Ryosuke Niwa.
28112
28113        When we are dragging and dropping into a content editable field, we detect
28114        if we are trying to put a <p> into an existing <p>, and if so, split the
28115        outer <p> and insert the new <p> as its sibling. However, the outer <p>
28116        might not be editable, so we don't want to do any splitting and inserting
28117        at that location.
28118
28119        Test: editing/pasteboard/drag-drop-paragraph-crasher.html
28120
28121        * editing/ReplaceSelectionCommand.cpp:
28122        (WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
28123
281242014-05-07  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
28125
28126        [CoordinatedGraphics][WK2] Scale factor and scroll position is not being restored properly in a back/forward load
28127        https://bugs.webkit.org/show_bug.cgi?id=126022
28128
28129        Reviewed by Benjamin Poulain.
28130
28131        Original author : Thiago de Barros Lacerda, and finished by Gyuyoung Kim.
28132
28133        When user is navigating back/forward to a page that has been scrolled and/or scaled, that page must be shown
28134        with its last scroll position and scale factor. However, when fixed layout was enabled with CoordinatedGraphics
28135        and TILED_BACKING_STORE, Page::setPageScaleFactor() doesn't send previous scroll position since r165652 and r165913.
28136
28137        This patch allows the Page::setPageScaleFactor() send stored position to WK2 implementation by calling delegatedScrollRequested()
28138        directly when delegatesScrolling() is on.
28139
28140        * page/Page.cpp:
28141        (WebCore::Page::setPageScaleFactor): TILED_BACKING_STORE and delegateScrolling are enabled, we pass new scroll position to WK2 though
28142        delegateScrolling is disabled.
28143        * platform/ScrollView.cpp: delegatedScrollRequested() call is moved from ScrollView::setScrollPosition() to Page::setPageScaleFactor().
28144        (WebCore::ScrollView::setScrollPosition): 
28145
281462014-05-07  Dean Jackson  <dino@apple.com>
28147
28148        Using a fill pattern much larger than actual canvas reliably segfaults browser
28149        https://bugs.webkit.org/show_bug.cgi?id=132635
28150
28151        Reviewed by Simon Fraser.
28152
28153        Make sure that createPattern checks that the canvas it is about to use
28154        as a source is valid.
28155
28156        Test: fast/canvas/pattern-too-large-to-create.html
28157
28158        * html/canvas/CanvasRenderingContext2D.cpp:
28159        (WebCore::CanvasRenderingContext2D::createPattern): Check that the source canvas has
28160        an ok ImageBuffer.
28161
281622014-05-07  Pratik Solanki  <psolanki@apple.com>
28163
28164        Use system defaults for hardware jpeg decoding
28165        https://bugs.webkit.org/show_bug.cgi?id=132661
28166        <rdar://problem/11348201>
28167
28168        Reviewed by Tim Horton.
28169
28170        Remove code that explicitly disabled hardware image decoding. Let the system decide what to do.
28171
28172        * WebCore.exp.in:
28173        * platform/graphics/ImageSource.h:
28174        (WebCore::ImageSource::acceleratedImageDecodingEnabled): Deleted.
28175        (WebCore::ImageSource::setAcceleratedImageDecodingEnabled): Deleted.
28176        * platform/graphics/cg/ImageSourceCG.cpp:
28177        (WebCore::ImageSource::imageSourceOptions):
28178
281792014-05-07  Radu Stavila  <stavila@adobe.com>
28180
28181        Use after free in WebCore::RenderObject::nextSibling / WebCore::RenderBoxModelObject::moveChildrenTo
28182        https://bugs.webkit.org/show_bug.cgi?id=132625
28183
28184        Reviewed by David Hyatt.
28185
28186        Fixed problem with dynamically inserting first letter elements.
28187
28188        Test: fast/multicol/newmulticol/first-letter-create.html
28189
28190        * rendering/RenderBlock.cpp:
28191        (WebCore::RenderBlock::getFirstLetter):
28192        (WebCore::RenderBlock::updateFirstLetter):
28193        * rendering/RenderBlock.h:
28194        * rendering/RenderBoxModelObject.cpp:
28195        (WebCore::RenderBoxModelObject::moveChildrenTo):
28196
281972014-05-07  Enrica Casucci  <enrica@apple.com>
28198
28199        WK2: Programatic scroll requests during scroll or zoom animation to reveal focused element are ignored.
28200        https://bugs.webkit.org/show_bug.cgi?id=132657
28201        <rdar://problem/16468462>
28202
28203        Reviewed by Benjamin Poulain.
28204
28205        With the scrolling model we use on iOS, a programatic scroll
28206        request can be received while we are still animating to reveal
28207        the focused input element. The WebProcess is unaware that the
28208        scroll position is being changed in the UIProcess, and does not
28209        honor the scroll request from JavaScript.
28210        This is patch changes the behavior for clients using scroll delegates
28211        to always send the scroll request to the UIProcess without checking
28212        the current scroll position.
28213
28214        * page/FrameView.h:
28215        * platform/ScrollView.cpp:
28216        (WebCore::ScrollView::setScrollPosition):
28217        * platform/ScrollView.h:
28218        (WebCore::ScrollView::inProgrammaticScroll):
28219
282202014-05-07  Brent Fulgham  <bfulgham@apple.com>
28221
28222        [Mac, iOS] REGRESSION: WK2 YouTube support
28223        https://bugs.webkit.org/show_bug.cgi?id=132568
28224        <rdar://problem/11464344>
28225
28226        Reviewed by Darin Adler.
28227
28228        Move the custom YouTube loader code out of the WebFrameLoaderClient into a
28229        PluginReplacement-based class.
28230
28231        * Modules/plugins/PluginReplacement.h:
28232        (WebCore::PluginReplacement::supportsURL): New predicate so we can restrict
28233        use of a plugin to a particular category of URLs.
28234        * Modules/plugins/QuickTimePluginReplacement.mm:
28235        (WebCore::QuickTimePluginReplacement): Updated for new registrar signature.
28236        * Modules/plugins/YouTubePluginReplacement.h: Added.
28237        (WebCore::YouTubePluginReplacement::parentElement):
28238        * Modules/plugins/YouTubePluginReplacement.cpp: Added.
28239        (WebCore::YouTubePluginReplacement::registerPluginReplacement):
28240        (WebCore::YouTubePluginReplacement::create):
28241        (WebCore::YouTubePluginReplacement::supportsMimeType):
28242        (WebCore::YouTubePluginReplacement::supportsFileExtension):
28243        (WebCore::kit):
28244        (WebCore::YouTubePluginReplacement::YouTubePluginReplacement):
28245        (WebCore::YouTubePluginReplacement::createElementRenderer):
28246        (WebCore::objectForKey):
28247        (WebCore::YouTubePluginReplacement::installReplacement):
28248        (WebCore::createYouTubeURL):
28249        (WebCore::processAndCreateYouTubeURL):
28250        (WebCore::YouTubePluginReplacement::youTubeURL):
28251        * WebCore.exp.in: Add new export from WebCore.
28252        * WebCore.xcodeproj/project.pbxproj:
28253        * html/HTMLPlugInElement.cpp:
28254        (WebCore::pluginReplacementForType): Update to also check that the URL is supported
28255        by the plugin.
28256        (WebCore::registeredPluginReplacements): Add new YouTubePluginReplacement to registry.
28257        * html/HTMLPlugInImageElement.cpp:
28258        (WebCore::HTMLPlugInImageElement::createElementRenderer): Remove custom YouTube code
28259        now that this logic is handled in the plugin replacement class.
28260        (WebCore::HTMLPlugInImageElement::createShadowIFrameSubtree): Deleted.
28261        * html/HTMLPlugInImageElement.h:
28262        * html/shadow/YouTubeEmbedShadowElement.cpp:
28263        (WebCore::YouTubeEmbedShadowElement::YouTubeEmbedShadowElement):
28264        (WebCore::YouTubeEmbedShadowElement::shadowPseudoId): Use correct pseudoID for the
28265        plugin replacement architecture.
28266        * html/shadow/YouTubeEmbedShadowElement.h:
28267        * platform/mac/WebCoreNSURLExtras.h:
28268        * platform/mac/WebCoreNSURLExtras.mm:
28269        (WebCore::unescapedQueryValue): Moved from WebKit/Misc/WebNSURLExtras.
28270        (WebCore::queryKeysAndValues): Ditto.
28271
282722014-05-07  Simon Fraser  <simon.fraser@apple.com>
28273
28274        [iOS] Acclerated overflow-scrolling broken in WK1
28275        https://bugs.webkit.org/show_bug.cgi?id=132665
28276        <rdar://problem/16842909>
28277
28278        Reviewed by Tim Horton.
28279
28280        r168301 added a CALayer delegate to disable implicit animations,
28281        but for some layers we wrap them in UIViews (which are themselves
28282        layer delegates), so bad things happened.
28283        
28284        Fix by falling back to setting the null actions dictionary for
28285        layers with custom scrolling behavior.
28286
28287        * platform/graphics/GraphicsLayer.h:
28288        * platform/graphics/ca/mac/PlatformCALayerMac.h:
28289        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
28290        (PlatformCALayerMac::updateCustomBehavior):
28291        * rendering/RenderLayerBacking.cpp:
28292        (WebCore::RenderLayerBacking::updateScrollingLayers):
28293
282942014-05-07  Jeremy Jones  <jeremyj@apple.com>
28295
28296        HTMLMediaElement should exitFullscreen when view is removed from the window.
28297        https://bugs.webkit.org/show_bug.cgi?id=132506
28298
28299        Reviewed by Tim Horton.
28300
28301        * platform/ios/WebVideoFullscreenControllerAVKit.h:
28302        Add -requestExitFullscreen.
28303
28304        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
28305        (-[WebVideoFullscreenController requestExitFullscreen]):
28306        Forward request onto WebVideoFullscreenModelMediaElement.
28307
28308        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
28309        (WebVideoFullscreenModelMediaElement::requestExitFullscreen):
28310        Add some protection here since this may be called when not in fullscreen.
28311
283122014-05-07  Dean Jackson  <dino@apple.com>
28313
28314        Clean up the difference between painting focus rings and adding PDF annotations
28315        https://bugs.webkit.org/show_bug.cgi?id=132638
28316
28317        Follow-up comments from Darin Adler.
28318
28319        * rendering/RenderInline.cpp:
28320        (WebCore::RenderInline::paintOutline): Move "else if" to a separate "if" for clarity.
28321        * rendering/RenderObject.cpp:
28322        (WebCore::RenderObject::paintFocusRing): Don't guard against outlineIsAuto(). ASSERT instead.
28323        (WebCore::RenderObject::addPDFURLRect): Give "rect" variable a better name.
28324        (WebCore::RenderObject::paintOutline): Move "else if" to a separate "if" for clarity.
28325
283262014-05-07  Alexey Proskuryakov  <ap@apple.com>
28327
28328        Make blob size computation lazy
28329        https://bugs.webkit.org/show_bug.cgi?id=132653
28330
28331        Reviewed by Anders Carlsson.
28332
28333        * fileapi/Blob.cpp:
28334        (WebCore::Blob::Blob):
28335        (WebCore::Blob::size):
28336        * fileapi/Blob.h:
28337        (WebCore::Blob::size): Deleted.
28338        * fileapi/File.cpp:
28339        (WebCore::File::size): Deleted.
28340        * fileapi/File.h:
28341        * fileapi/ThreadableBlobRegistry.cpp:
28342        (WebCore::ThreadableBlobRegistry::registerFileBlobURL):
28343        (WebCore::ThreadableBlobRegistry::registerBlobURL):
28344        (WebCore::ThreadableBlobRegistry::registerBlobURLForSlice):
28345        (WebCore::ThreadableBlobRegistry::blobSize):
28346        (WebCore::ThreadableBlobRegistry::unregisterBlobURL):
28347        (WebCore::unregisterBlobURLTask): Deleted.
28348        * fileapi/ThreadableBlobRegistry.h:
28349        * platform/network/BlobData.cpp:
28350        (WebCore::BlobData::appendData):
28351        * platform/network/BlobRegistry.h:
28352        * platform/network/BlobRegistryImpl.cpp:
28353        (WebCore::BlobRegistryImpl::registerBlobURL):
28354        (WebCore::BlobRegistryImpl::registerBlobURLForSlice):
28355        * platform/network/BlobRegistryImpl.h:
28356
283572014-05-06  Simon Fraser  <simon.fraser@apple.com>
28358
28359        Add scrolling tree logging to RemoteLayerTree output
28360        https://bugs.webkit.org/show_bug.cgi?id=132640
28361
28362        Reviewed by Beth Dakin.
28363
28364        Support scrolling tree logging in the RemoteLayerTree log channel
28365        output.
28366        
28367        ScrollingStateTree::commit() unconditionally set treeStateClone->m_hasChangedProperties
28368        to true, but we should set it based on original scrolling state tree's 
28369        m_hasChangedProperties.
28370        
28371        We have to encode all of the scrolling state nodes anyway (they only encode
28372        changed properties), but we can use this for future optimizations, and to
28373        avoid spurious logging.
28374        
28375        * WebCore.exp.in: Export a couple of things we need.
28376        * page/scrolling/ScrollingStateTree.cpp:
28377        (WebCore::ScrollingStateTree::commit):
28378
283792014-05-07  Chris Fleizach  <cfleizach@apple.com>
28380
28381        AX: aria-expanded changes are not communicated to clients
28382        https://bugs.webkit.org/show_bug.cgi?id=132642
28383
28384        Reviewed by Mario Sanchez Prada.
28385
28386        When aria-expanded changes on non list/tree items, send out a generic
28387        AXExpandedChange notification.
28388
28389        Test: platform/mac/accessibility/expanded-notification.html
28390
28391        * accessibility/AXObjectCache.h:
28392        * accessibility/AccessibilityRenderObject.cpp:
28393        (WebCore::AccessibilityRenderObject::handleAriaExpandedChanged):
28394        * accessibility/mac/AXObjectCacheMac.mm:
28395        (WebCore::AXObjectCache::postPlatformNotification):
28396
283972014-05-07  Alexey Proskuryakov  <ap@apple.com>
28398
28399        Release build fix.
28400
28401        * platform/MIMETypeRegistry.cpp: (WebCore::initializeSupportedImageMIMETypes):
28402        Removed unused globals.
28403
284042014-05-07  Alexey Proskuryakov  <ap@apple.com>
28405
28406        Eliminate "well known MIME type" support
28407        https://bugs.webkit.org/show_bug.cgi?id=132654
28408
28409        Reviewed by Anders Carlsson.
28410
28411        Vestiges of FileSystem API.
28412
28413        * dom/DataTransfer.cpp:
28414        (WebCore::DataTransfer::files):
28415        (WebCore::DataTransfer::hasFileOfType):
28416        * fileapi/File.cpp:
28417        (WebCore::File::File):
28418        (WebCore::File::contentTypeFromFilePathOrName):
28419        * fileapi/File.h:
28420        * html/FileInputType.cpp:
28421        (WebCore::FileInputType::createFileList):
28422        * platform/MIMETypeRegistry.cpp:
28423        (WebCore::initializeSupportedImageMIMETypes):
28424        (WebCore::findMimeType): Deleted.
28425        (WebCore::MIMETypeRegistry::getWellKnownMIMETypeForExtension): Deleted.
28426        * platform/MIMETypeRegistry.h:
28427
284282014-05-07  Christophe Dumez  <ch.dumez@samsung.com>
28429
28430        [HTML] Default argument to HTMLTableElement.insertRow() should be -1
28431        https://bugs.webkit.org/show_bug.cgi?id=132651
28432
28433        Reviewed by Alexey Proskuryakov.
28434
28435        HTMLTableElement.insertRow()'s argument default value should be -1, not 0,
28436        as per the specification:
28437        http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#htmltableelement
28438
28439        The new behavior matches the one of Firefox 29 and IE11, and soon Blink:
28440        https://codereview.chromium.org/270213007/
28441
28442        Test: fast/dom/HTMLTableElement/insertRow-default-argument.html
28443
28444        * html/HTMLTableElement.h:
28445        * html/HTMLTableElement.idl:
28446
284472014-05-07  Chris Fleizach  <cfleizach@apple.com>
28448
28449        AX: AXSelectTextWithCriteria should support capitalize/lowercase/uppercase
28450        https://bugs.webkit.org/show_bug.cgi?id=132622
28451
28452        Reviewed by Mario Sanchez Prada.
28453
28454        The select text with criteria mechanism used through accessibility needs to support
28455        a few more parameters to be complete (including capitalize, lowercase and uppercase).
28456
28457        Updated: accessibility/select-text.html
28458
28459        * accessibility/AccessibilityObject.cpp:
28460        (WebCore::AccessibilityObject::selectText):
28461        * accessibility/AccessibilityObject.h:
28462        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
28463        (accessibilitySelectTextCriteriaForCriteriaParameterizedAttribute):
28464        * rendering/RenderText.cpp:
28465        (WebCore::makeCapitalized):
28466        * rendering/RenderText.h:
28467
284682014-05-07  peavo@outlook.com  <peavo@outlook.com>
28469
28470        DocumentLoader::dataReceived assertion failed
28471        https://bugs.webkit.org/show_bug.cgi?id=132017
28472
28473        Reviewed by Brent Fulgham.
28474
28475        We need to call didReceiveResponse client method before the didReceiveData client method, otherwise we get a lot of asserts.
28476        This patch also fixes frequent crashes in downloadTimerCallback method on page loading.
28477
28478        * platform/network/curl/ResourceHandleManager.cpp:
28479        (WebCore::calculateWebTimingInformations): Initialize local variables.
28480        (WebCore::headerCallback): Call didReceiveResponse client method here instead of in downloadTimerCallback.
28481        (WebCore::ResourceHandleManager::downloadTimerCallback): Remove call to didReceiveResponse method.
28482        (WebCore::ResourceHandleManager::dispatchSynchronousJob): Removed empty line.
28483
284842014-05-06  Antti Koivisto  <antti@apple.com>
28485
28486        REGRESSION: Animated GIF inside compositing layer never resumes animation when scrolled back into view
28487        https://bugs.webkit.org/show_bug.cgi?id=132608
28488
28489        Reviewed by Simon Fraser.
28490
28491        Test: fast/repaint/animation-after-layer-scroll.html
28492
28493        * rendering/RenderLayer.cpp:
28494        (WebCore::RenderLayer::scrollTo):
28495        
28496            Check if any animations need to be restarted after layer scroll.
28497
284982014-05-07  Hyowon Kim  <hw1008.kim@samsung.com>
28499
28500        GraphicsLayer::client() should return a reference.
28501        https://bugs.webkit.org/show_bug.cgi?id=126372
28502
28503        Reviewed by Simon Fraser.
28504
28505        GraphicsLayers always have a GraphicsLayerClient attached,
28506        so make client() a reference and remove some unnecessary branches.
28507        The author of the changes in the mac port is Andreas Kling <akling@apple.com>.
28508
28509        * WebCore.exp.in:
28510        * platform/graphics/GraphicsLayer.cpp:
28511        (WebCore::GraphicsLayer::GraphicsLayer):
28512        (WebCore::GraphicsLayer::willBeDestroyed):
28513        (WebCore::GraphicsLayer::paintGraphicsLayerContents):
28514        (WebCore::GraphicsLayer::addRepaintRect):
28515        (WebCore::dumpChildren):
28516        (WebCore::GraphicsLayer::dumpProperties):
28517        * platform/graphics/GraphicsLayer.h:
28518        (WebCore::GraphicsLayer::client):
28519        (WebCore::GraphicsLayer::pageScaleFactor):
28520        (WebCore::GraphicsLayer::deviceScaleFactor):
28521        * platform/graphics/GraphicsLayerFactory.h:
28522        * platform/graphics/ca/GraphicsLayerCA.cpp:
28523        (WebCore::GraphicsLayer::create):
28524        (WebCore::GraphicsLayerCA::GraphicsLayerCA):
28525        (WebCore::GraphicsLayerCA::initialize):
28526        (WebCore::GraphicsLayerCA::platformCALayerAnimationStarted):
28527        (WebCore::GraphicsLayerCA::computePositionRelativeToBase):
28528        (WebCore::GraphicsLayerCA::flushCompositingStateForThisLayerOnly):
28529        (WebCore::GraphicsLayerCA::computeVisibleRect):
28530        (WebCore::GraphicsLayerCA::recursiveCommitChanges):
28531        (WebCore::GraphicsLayerCA::platformCALayerContentsScaleMultiplierForNewTiles):
28532        (WebCore::GraphicsLayerCA::platformCALayerShouldAggressivelyRetainTiles):
28533        (WebCore::GraphicsLayerCA::platformCALayerShouldTemporarilyRetainTileCohorts):
28534        (WebCore::GraphicsLayerCA::updateContentsOpaque):
28535        (WebCore::GraphicsLayerCA::updateContentsScale):
28536        (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
28537        (WebCore::GraphicsLayerCA::noteLayerPropertyChanged):
28538        * platform/graphics/ca/GraphicsLayerCA.h:
28539        * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
28540        (WebCore::GraphicsLayer::create):
28541        (WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
28542        (WebCore::GraphicsLayerTextureMapper::notifyChange):
28543        (WebCore::GraphicsLayerTextureMapper::commitLayerChanges):
28544        * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
28545        * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
28546        (WebCore::CompositingCoordinator::createRootLayer):
28547        (WebCore::CompositingCoordinator::createGraphicsLayer):
28548        * platform/graphics/texmap/coordinated/CompositingCoordinator.h:
28549        * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
28550        (WebCore::CoordinatedGraphicsLayer::notifyFlushRequired):
28551        (WebCore::CoordinatedGraphicsLayer::CoordinatedGraphicsLayer):
28552        (WebCore::CoordinatedGraphicsLayer::computeTransformedVisibleRect):
28553        (WebCore::CoordinatedGraphicsLayer::animationStartedTimerFired):
28554        * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
28555        * rendering/RenderLayerBacking.cpp:
28556        (WebCore::RenderLayerBacking::createGraphicsLayer):
28557        * rendering/RenderLayerCompositor.cpp:
28558        (WebCore::RenderLayerCompositor::updateLayerForTopOverhangArea):
28559        (WebCore::RenderLayerCompositor::updateLayerForBottomOverhangArea):
28560        (WebCore::RenderLayerCompositor::updateLayerForHeader):
28561        (WebCore::RenderLayerCompositor::updateLayerForFooter):
28562        (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
28563        (WebCore::RenderLayerCompositor::ensureRootLayer):
28564
285652014-05-07  Xabier Rodriguez Calvar  <calvaris@igalia.com>
28566
28567        [GStreamer] Corrected typo
28568        https://bugs.webkit.org/show_bug.cgi?id=132609
28569
28570        Reviewed by Martin Robinson.
28571
28572        Corrected m_canFallBackToLastFinishedSeekPositon typo and
28573        initialized in the constructor to prevent problems in the future.
28574
28575        No test needed.
28576
28577        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
28578        (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
28579        Initialized m_canFallBackToLastFinishedSeekPosition as false.
28580        (WebCore::MediaPlayerPrivateGStreamer::playbackPosition):
28581        (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
28582        (WebCore::MediaPlayerPrivateGStreamer::asyncStateChangeDone):
28583        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
28584        m_canFallBackToLastFinishedSeekPositon ->
28585        m_canFallBackToLastFinishedSeekPosition
28586
285872014-05-07  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
28588
28589        Convert PassOwnPtr to unique_ptr in CrossThreadTask.h
28590        https://bugs.webkit.org/show_bug.cgi?id=132605
28591
28592        Reviewed by Dirk Schulze.
28593
28594        * dom/CrossThreadTask.h: Converted.
28595
285962014-05-07  Carlos Garcia Campos  <cgarcia@igalia.com>
28597
28598        [SOUP] TLSErrors do not cause page load to fail when not ignored
28599        https://bugs.webkit.org/show_bug.cgi?id=121548
28600
28601        Reviewed by Sergio Villar Senin.
28602
28603        This only happens in case of redirection, when the initial URL is
28604        an HTTPS site with an invalid certificate, that redirects to
28605        another location. We are starting the redirection without checking
28606        the TLS errors.
28607
28608        * platform/network/soup/ResourceHandleSoup.cpp:
28609        (WebCore::sendRequestCallback): Check TLS errors before starting a
28610        possible redirection.
28611
286122014-05-07  Manuel Rego Casasnovas  <rego@igalia.com>
28613
28614        [CSS Grid Layout] Remove runtime feature
28615        https://bugs.webkit.org/show_bug.cgi?id=132382
28616
28617        Reviewed by Benjamin Poulain.
28618
28619        Remove cssGridLayoutEnabled setting. Update methods using it accordingly.
28620
28621        * WebCore.order:
28622        * css/CSSParser.cpp:
28623        (WebCore::CSSParserContext::CSSParserContext):
28624        (WebCore::operator==):
28625        (WebCore::isValidKeywordPropertyAndValue):
28626        (WebCore::CSSParser::parseValue):
28627        (WebCore::CSSParser::parseGridTemplateShorthand):
28628        (WebCore::CSSParser::parseGridAreaShorthand):
28629        (WebCore::CSSParser::cssGridLayoutEnabled): Deleted.
28630        * css/CSSParser.h:
28631        * css/CSSParserMode.h:
28632        * dom/Document.cpp:
28633        (WebCore::Document::cssGridLayoutEnabled): Deleted.
28634        * dom/Document.h:
28635        * page/Settings.in:
28636
286372014-05-07  Praveen R Jadhav  <praveen.j@samsung.com>
28638
28639        Fix build errors for BlobDataItem after r168391.
28640        https://bugs.webkit.org/show_bug.cgi?id=132643
28641
28642        Reviewed by Carlos Garcia Campos.
28643
28644        Patch updates BlobDataItem params usage in ResourceHandleSoup.cpp
28645        to be inline with r168391.
28646
28647        * platform/network/soup/ResourceHandleSoup.cpp:
28648        (WebCore::blobIsOutOfDate): BlobDataItem class is updated in r168391.
28649        Corresponding parameter changes are done to resolve build error.
28650        (WebCore::addEncodedBlobItemToSoupMessageBody): BlobDataItem class is updated
28651        in r168391. Corresponding parameter changes are done to resolve build error.
28652
286532014-05-06  Dean Jackson  <dino@apple.com>
28654
28655        Clean up the difference between painting focus rings and adding PDF annotations
28656        https://bugs.webkit.org/show_bug.cgi?id=132638
28657
28658        Reviewed by Simon Fraser.
28659
28660        The code to add a PDF annotation when printing was called from
28661        drawFocusRing, which is quite confusing. With just little movement
28662        of code, we can detect an annotation and call addPDFURLRect in the
28663        paint phase, and drawFocusRing becomes something that only
28664        draws focus rings.
28665
28666        * rendering/RenderInline.cpp:
28667        (WebCore::RenderInline::paintOutline): Split calls to drawFocusRing
28668        and addPDFURLRect.
28669        * rendering/RenderObject.cpp:
28670        (WebCore::RenderObject::paintFocusRing): Get rid of call to PDF.
28671        (WebCore::RenderObject::addPDFURLRect): Change the signature so it
28672        can be called externally, and calculates the rectangle itself.
28673        (WebCore::RenderObject::paintOutline): Split the calls.
28674        * rendering/RenderObject.h:
28675
286762014-05-06  Rik Cabanier  <cabanier@adobe.com>
28677
28678        Calling createPattern with a broken image must throw an invalidstate error
28679        https://bugs.webkit.org/show_bug.cgi?id=132407
28680
28681        Reviewed by Darin Adler.
28682
28683        Updated createPattern so it throws an invalidState exception
28684        if you pass it an image that is in the broken state.
28685
28686        Tests:
28687        * canvas/philip/tests/2d.pattern.image.broken.html:
28688        * canvas/philip/tests/2d.pattern.image.incomplete.empty.html:
28689        * fast/canvas/canvas-empty-image-pattern.html:
28690
28691        * html/canvas/CanvasRenderingContext2D.cpp:
28692        (WebCore::CanvasRenderingContext2D::createPattern):
28693
286942014-05-06  Jer Noble  <jer.noble@apple.com>
28695
28696        [iOS][Mac] Display sleeps while playing <video> content.
28697        https://bugs.webkit.org/show_bug.cgi?id=132624
28698
28699        Reviewed by Darin Adler.
28700
28701        On iOS and Mac, create a DisplaySleepDisablerCocoa rather than an (no-op) DisplaySleepDisabler.
28702
28703        * platform/cocoa/DisplaySleepDisablerCocoa.cpp:
28704        (WebCore::DisplaySleepDisabler::create):
28705        * platform/cocoa/DisplaySleepDisablerCocoa.h:
28706
287072014-05-06  Dean Jackson  <dino@apple.com>
28708
28709        [Mac] Allow focus rings to redraw themselves if necessary
28710        https://bugs.webkit.org/show_bug.cgi?id=132593
28711
28712        Fix iOS build.
28713
28714        * platform/graphics/mac/GraphicsContextMac.mm:
28715        (WebCore::GraphicsContext::drawFocusRing): We no longer use the color parameter.
28716
287172014-05-06  Dean Jackson  <dino@apple.com>
28718
28719        [Mac] Allow focus rings to redraw themselves if necessary
28720        https://bugs.webkit.org/show_bug.cgi?id=132593
28721
28722        Reviewed by Simon Fraser.
28723
28724        Mac allows focus rings to change rendering over time. Expose this
28725        functionality to WebKit by having the rendering code detect that
28726        a focused element has asked to repaint itself, and also have
28727        the FocusController object remember how long it has been since
28728        an element was focused.
28729
28730        This patch removes WebCoreNSCellExtras, since a better version is
28731        available in WebKitSystemInterface, and it was going to be cumbersome
28732        to port the code from there into WebKit.
28733
28734        * WebCore.exp.in: Export _wkDrawFocusRingAtTime and _wkDrawCellFocusRingWithFrameAtTime.
28735        * WebCore.xcodeproj/project.pbxproj: Remove WebCoreNSCellExtras.
28736        * page/FocusController.cpp:
28737        (WebCore::FocusController::FocusController): Initialize the repaint timer.
28738        (WebCore::FocusController::~FocusController): Stop the repaint timer on deletion.
28739        (WebCore::FocusController::setFocusedElement): Keep track of the current time when focused.
28740        (WebCore::FocusController::focusedElementNeedsRepaint): Start the repaint timer.
28741        (WebCore::FocusController::focusRepaintTimerFired): Ask the focused element to repaint itself.
28742        (WebCore::FocusController::timeSinceFocusWasSet):
28743        * page/FocusController.h: Expose timeSinceFocusWasSet() and focusedElementNeedsRepaint(), as
28744        well as add the timer for repainting.
28745
28746        * platform/ControlStates.h: Add timeSinceControlWasFocused member variable, allowing the platform
28747        code such as Theme to obtain the value from FocusController.
28748        (WebCore::ControlStates::ControlStates):
28749        (WebCore::ControlStates::timeSinceControlWasFocused):
28750        (WebCore::ControlStates::setTimeSinceControlWasFocused):
28751
28752        * platform/graphics/GraphicsContext.h:
28753        (WebCore::GraphicsContext::drawFocusRing): New Mac-only method that uses timeOffset.
28754
28755        * platform/graphics/mac/GraphicsContextMac.mm:
28756        (WebCore::drawFocusRingToContext): No need to pass in color and radius - these are now
28757        ignored in WKDrawFocusRing. However, I didn't want to change the signature of the
28758        WKSI function.
28759        (WebCore::drawFocusRingToContextAtTime): Call into the new method WKDrawFocusRingAtTime.
28760        (WebCore::GraphicsContext::drawFocusRing): Color and radius no longer used.
28761
28762        * platform/mac/ThemeMac.mm:
28763        (WebCore::checkboxMargins): Update the margins since our focus ring can be a lot bigger.
28764        (WebCore::radioMargins): Ditto.
28765        (WebCore::paintToggleButton): Drawing a focus ring might trigger a repaint too.
28766        (WebCore::buttonMargins): Increase the margins.
28767        (WebCore::paintButton): If our focus ring wants to be drawn again, set the ControlStates flag.
28768
28769        * platform/mac/WebCoreNSCellExtras.h: Removed.
28770        * platform/mac/WebCoreNSCellExtras.m: Removed.
28771
28772        * platform/mac/WebCoreSystemInterface.h: Declare the new methods.
28773        * platform/mac/WebCoreSystemInterface.mm:
28774
28775        * rendering/RenderElement.cpp:
28776        (WebCore::RenderElement::initializeStyle): Expand the overflow rects by the maximum
28777        focus ring width. This might be different from the current outline size.
28778        (WebCore::RenderElement::setStyle): Ditto.
28779
28780        * rendering/RenderObject.cpp:
28781        (WebCore::RenderObject::paintFocusRing): If we're on Mac, use the new drawFocusRing method,
28782        which sets a parameter to true if the focused element needs a repaint.
28783
28784        * rendering/RenderTheme.cpp:
28785        (WebCore::RenderTheme::updateControlStatesForRenderer): Copy the value from FocusController
28786        so that the platform Theme code can use it.
28787
28788        * rendering/RenderTheme.h:
28789        (WebCore::RenderTheme::platformFocusRingMaxWidth): Add a way to get the maximum width
28790        of a focus ring for the platform. This is used to extend the overflow rects.
28791        * rendering/RenderThemeMac.h: Override the focus ring width.
28792        * rendering/RenderThemeMac.mm: On newer versions of OS X, we have a larger focus ring.
28793        (WebCore::RenderThemeMac::platformFocusRingMaxWidth):
28794        (WebCore::RenderThemeMac::paintMenuList): If a menu is focused, and needs a repaint, mark
28795        it as such.
28796
287972014-05-06  Jer Noble  <jer.noble@apple.com>
28798
28799        [iOS] Animate AVPlayerLayer into and out of full screen
28800        https://bugs.webkit.org/show_bug.cgi?id=132603
28801
28802        Reviewed by Simon Fraser.
28803
28804        Rather than synchronize animations across the WebProcess / UIProcess boundary, animate
28805        the AVPlayerLayer into place by first resizing the full screen layer to occupy the
28806        entire screen in the WebProcess, and use a sublayerTransform animation in the UIProcess
28807        to scale the AVPlayer from its initial screen location, as well as back to its final screen
28808        location.
28809
28810        * platform/graphics/GeometryUtilities.cpp:
28811        (WebCore::largestRectWithAspectRatioInsideRect): Added utility method.
28812        * platform/graphics/GeometryUtilities.h:
28813        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
28814        (-[WebAVVideoLayer init]): Added, initialize video gravity and enable child layer masking.
28815        (-[WebAVVideoLayer setBounds:]): Create a transform to scale the video area.
28816        (WebVideoFullscreenInterfaceAVKit::enterFullscreen): Block implicit animations during setup.
28817        (WebVideoFullscreenInterfaceAVKit::exitFullscreen): Reset the gravity to ResizeAspect
28818            if necessary.
28819
288202014-05-06  Alexey Proskuryakov  <ap@apple.com>
28821
28822        Make BlobDataItem use a refcounted object for files
28823        https://bugs.webkit.org/show_bug.cgi?id=132628
28824
28825        Reviewed by Anders Carlsson.
28826
28827        * CMakeLists.txt:
28828        * WebCore.vcxproj/WebCore.vcxproj:
28829        * WebCore.vcxproj/WebCore.vcxproj.filters:
28830        * WebCore.xcodeproj/project.pbxproj:
28831        Added BlobDataFileReference.{h|cpp}
28832
28833        * WebCore.exp.in: Removed unused exports.
28834
28835        * platform/network/BlobData.h:
28836        (WebCore::BlobDataItem::offset):
28837        (WebCore::BlobDataItem::BlobDataItem):
28838        Use a wrapper class for files, not a path. Changed to be more class-like accordingly.
28839
28840        * platform/network/BlobData.cpp:
28841        (WebCore::BlobData::appendData):
28842        (WebCore::BlobData::appendFile):
28843        (WebCore::BlobData::appendBlob): Deleted.
28844        (WebCore::BlobData::BlobData): Deleted.
28845        We never add blobs to BlobData, they are always resolved to data of file references.
28846        Lots of very confusing code to delete.
28847
28848        * platform/network/BlobDataFileReference.h: Added.
28849        * platform/network/BlobDataFileReference.cpp: Added.
28850        (WebCore::BlobDataFileReference::size):
28851        (WebCore::BlobDataFileReference::expectedModificationTime):
28852        (WebCore::BlobDataFileReference::computeFileSystemData):
28853        A unique reference to a file referenced by blob, to be preserved when you slice
28854        or combine blobs.
28855
28856        * platform/network/BlobRegistryImpl.cpp:
28857        (WebCore::BlobRegistryImpl::appendStorageItems):
28858        (WebCore::BlobRegistryImpl::registerFileBlobURL):
28859        (WebCore::BlobRegistryImpl::registerBlobURL):
28860        (WebCore::BlobRegistryImpl::blobSize):
28861        * platform/network/BlobResourceHandle.cpp:
28862        (WebCore::BlobResourceHandle::getSizeForNext):
28863        (WebCore::BlobResourceHandle::didGetSize):
28864        (WebCore::BlobResourceHandle::readDataSync):
28865        (WebCore::BlobResourceHandle::readFileSync):
28866        (WebCore::BlobResourceHandle::readDataAsync):
28867        (WebCore::BlobResourceHandle::readFileAsync):
28868        * platform/network/BlobResourceHandle.h:
28869        * platform/network/FormData.cpp:
28870        (WebCore::appendBlobResolved):
28871        Updated for BlobDataItem interface changes.
28872
288732014-05-06  Christophe Dumez  <ch.dumez@samsung.com>
28874
28875        [HTML] Default argument to HTMLTableRowElement.insertCell() should be -1
28876        https://bugs.webkit.org/show_bug.cgi?id=132615
28877
28878        Reviewed by Darin Adler.
28879
28880        HTMLTableRowElement.insertCell()'s argument default value should be -1, not
28881        0, as per the specification:
28882        http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-tr-element
28883
28884        The new behavior matches the one of Firefox 29 and IE11, and soon Blink:
28885        https://codereview.chromium.org/263323004/
28886
28887        Test: fast/dom/HTMLTableRowElement/insertCell-default-argument.html
28888
28889        * html/HTMLTableRowElement.h:
28890        * html/HTMLTableRowElement.idl:
28891
288922014-05-06  Oliver Hunt  <oliver@apple.com>
28893
28894        Fix build.
28895
28896        * WebCore.exp.in:
28897
288982014-05-06  Andreas Kling  <akling@apple.com>
28899
28900        Add missing line from r168384.
28901
28902        * dom/ContainerNode.h:
28903        (WebCore::ChildNodesLazySnapshot::~ChildNodesLazySnapshot):
28904
289052014-05-06  Oliver Hunt  <oliver@apple.com>
28906
28907        Can't make a booking at virginamerica.com
28908        https://bugs.webkit.org/show_bug.cgi?id=132626
28909
28910        Reviewed by Geoffrey Garen.
28911
28912        Test: fast/dom/assign-to-prototype-accessor-on-prototype-should-be-silent.html
28913
28914        We can't throw an exception when a site incorrectly attempts
28915        to use a dom property setter directly on the prototype as
28916        there are sites that do this as compatibility workarounds
28917        for old browsers. Instead we treat use of the setter on
28918        the prototype object in the same way we do getters, and just
28919        log a warning to the console.
28920
28921        * bindings/js/JSDOMBinding.cpp:
28922        (WebCore::reportDeprecatedSetterError):
28923        * bindings/js/JSDOMBinding.h:
28924        * bindings/scripts/CodeGeneratorJS.pm:
28925        (GenerateImplementation):
28926        * bindings/scripts/test/JS/JSTestInterface.cpp:
28927        (WebCore::setJSTestInterfaceImplementsStr2):
28928        (WebCore::setJSTestInterfaceImplementsStr3):
28929        (WebCore::setJSTestInterfaceImplementsNode):
28930        (WebCore::setJSTestInterfaceSupplementalStr2):
28931        (WebCore::setJSTestInterfaceSupplementalStr3):
28932        (WebCore::setJSTestInterfaceSupplementalNode):
28933        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
28934        (WebCore::setJSTestNondeterministicNondeterministicWriteableAttr):
28935        (WebCore::setJSTestNondeterministicNondeterministicExceptionAttr):
28936        (WebCore::setJSTestNondeterministicNondeterministicGetterExceptionAttr):
28937        (WebCore::setJSTestNondeterministicNondeterministicSetterExceptionAttr):
28938        * bindings/scripts/test/JS/JSTestObj.cpp:
28939        (WebCore::setJSTestObjTestSubObjEnabledBySettingConstructor):
28940        (WebCore::setJSTestObjEnumAttr):
28941        (WebCore::setJSTestObjByteAttr):
28942        (WebCore::setJSTestObjOctetAttr):
28943        (WebCore::setJSTestObjShortAttr):
28944        (WebCore::setJSTestObjUnsignedShortAttr):
28945        (WebCore::setJSTestObjLongAttr):
28946        (WebCore::setJSTestObjLongLongAttr):
28947        (WebCore::setJSTestObjUnsignedLongLongAttr):
28948        (WebCore::setJSTestObjStringAttr):
28949        (WebCore::setJSTestObjTestObjAttr):
28950        (WebCore::setJSTestObjXMLObjAttr):
28951        (WebCore::setJSTestObjCreate):
28952        (WebCore::setJSTestObjReflectedStringAttr):
28953        (WebCore::setJSTestObjReflectedIntegralAttr):
28954        (WebCore::setJSTestObjReflectedUnsignedIntegralAttr):
28955        (WebCore::setJSTestObjReflectedBooleanAttr):
28956        (WebCore::setJSTestObjReflectedURLAttr):
28957        (WebCore::setJSTestObjReflectedCustomIntegralAttr):
28958        (WebCore::setJSTestObjReflectedCustomBooleanAttr):
28959        (WebCore::setJSTestObjReflectedCustomURLAttr):
28960        (WebCore::setJSTestObjTypedArrayAttr):
28961        (WebCore::setJSTestObjAttrWithGetterException):
28962        (WebCore::setJSTestObjAttrWithSetterException):
28963        (WebCore::setJSTestObjStringAttrWithGetterException):
28964        (WebCore::setJSTestObjStringAttrWithSetterException):
28965        (WebCore::setJSTestObjCustomAttr):
28966        (WebCore::setJSTestObjWithScriptStateAttribute):
28967        (WebCore::setJSTestObjWithScriptExecutionContextAttribute):
28968        (WebCore::setJSTestObjWithScriptStateAttributeRaises):
28969        (WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
28970        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
28971        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
28972        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
28973        (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
28974        (WebCore::setJSTestObjConditionalAttr1):
28975        (WebCore::setJSTestObjConditionalAttr2):
28976        (WebCore::setJSTestObjConditionalAttr3):
28977        (WebCore::setJSTestObjConditionalAttr4Constructor):
28978        (WebCore::setJSTestObjConditionalAttr5Constructor):
28979        (WebCore::setJSTestObjConditionalAttr6Constructor):
28980        (WebCore::setJSTestObjAnyAttribute):
28981        (WebCore::setJSTestObjMutablePoint):
28982        (WebCore::setJSTestObjImmutablePoint):
28983        (WebCore::setJSTestObjStrawberry):
28984        (WebCore::setJSTestObjStrictFloat):
28985        (WebCore::setJSTestObjId):
28986        (WebCore::setJSTestObjReplaceableAttribute):
28987        (WebCore::setJSTestObjNullableLongSettableAttribute):
28988        (WebCore::setJSTestObjNullableStringValue):
28989        (WebCore::setJSTestObjAttributeWithReservedEnumType):
28990        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
28991        (WebCore::setJSTestSerializedScriptValueInterfaceValue):
28992        (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
28993        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
28994        (WebCore::setJSTestTypedefsUnsignedLongLongAttr):
28995        (WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
28996        (WebCore::setJSTestTypedefsAttrWithGetterException):
28997        (WebCore::setJSTestTypedefsAttrWithSetterException):
28998        (WebCore::setJSTestTypedefsStringAttrWithGetterException):
28999        (WebCore::setJSTestTypedefsStringAttrWithSetterException):
29000
290012014-05-06  Andreas Kling  <akling@apple.com>
29002
29003        ChildNodesLazySnapshot::m_childNodes needs two heap allocations.
29004        <https://webkit.org/b/132616>
29005
29006        This seems a bit silly, since ChildNodesLazySnapshot is always
29007        allocated on the stack.
29008
29009        Change it to be a bool + a Vector instead of using the nullity
29010        as a presence indicator. This way we also don't end up with an
29011        out-of-line ~OwnPtr for the Vector.
29012
29013        Reviewed by Geoff Garen.
29014
29015        * dom/ContainerNode.h:
29016        (WebCore::ChildNodesLazySnapshot::ChildNodesLazySnapshot):
29017        (WebCore::ChildNodesLazySnapshot::nextNode):
29018        (WebCore::ChildNodesLazySnapshot::takeSnapshot):
29019        (WebCore::ChildNodesLazySnapshot::hasSnapshot):
29020
290212014-05-06  Alexey Proskuryakov  <ap@apple.com>
29022
29023        Eliminate BlobStorageData
29024        https://bugs.webkit.org/show_bug.cgi?id=132617
29025
29026        Reviewed by Anders Carlsson.
29027
29028        * WebCore.vcxproj/WebCore.vcxproj:
29029        * WebCore.vcxproj/WebCore.vcxproj.filters:
29030        * WebCore.xcodeproj/project.pbxproj:
29031        * platform/network/BlobData.h:
29032        (WebCore::BlobData::create):
29033        (WebCore::BlobData::BlobData):
29034        * platform/network/BlobRegistryImpl.cpp:
29035        (WebCore::loadResourceSynchronously):
29036        (WebCore::BlobRegistryImpl::appendStorageItems):
29037        (WebCore::BlobRegistryImpl::registerFileBlobURL):
29038        (WebCore::BlobRegistryImpl::registerBlobURL):
29039        (WebCore::BlobRegistryImpl::registerBlobURLForSlice):
29040        (WebCore::BlobRegistryImpl::getBlobDataFromURL):
29041        (WebCore::BlobRegistryImpl::blobSize):
29042        * platform/network/BlobRegistryImpl.h:
29043        * platform/network/BlobResourceHandle.cpp:
29044        (WebCore::BlobResourceHandle::createAsync):
29045        (WebCore::BlobResourceHandle::loadResourceSynchronously):
29046        (WebCore::BlobResourceHandle::BlobResourceHandle):
29047        (WebCore::BlobResourceHandle::doStart):
29048        (WebCore::BlobResourceHandle::getSizeForNext):
29049        (WebCore::BlobResourceHandle::didGetSize):
29050        (WebCore::BlobResourceHandle::seek):
29051        (WebCore::BlobResourceHandle::readSync):
29052        (WebCore::BlobResourceHandle::readDataSync):
29053        (WebCore::BlobResourceHandle::readFileSync):
29054        (WebCore::BlobResourceHandle::readAsync):
29055        (WebCore::BlobResourceHandle::readDataAsync):
29056        (WebCore::BlobResourceHandle::readFileAsync):
29057        (WebCore::BlobResourceHandle::notifyResponseOnSuccess):
29058        * platform/network/BlobResourceHandle.h:
29059        * platform/network/BlobStorageData.h: Removed.
29060        * platform/network/FormData.cpp:
29061        (WebCore::appendBlobResolved):
29062        * platform/network/soup/ResourceHandleSoup.cpp:
29063        (WebCore::addEncodedBlobToSoupMessageBody):
29064
290652014-05-06  Simon Fraser  <simon.fraser@apple.com>
29066
29067        Fix the iOS build.
29068
29069        WebCore::Editor::replaceNodeFromPasteboard(WebCore::Node*, WTF::String const&) is Mac-only.
29070        Also sort the export file.
29071
29072        * WebCore.exp.in:
29073
290742014-05-06  David Hyatt  <hyatt@apple.com>
29075
29076        Begin Removal of Old Multi-Column Code.
29077        https://bugs.webkit.org/show_bug.cgi?id=132480
29078
29079        Reviewed by Andreas Kling.
29080
29081        * dom/Document.cpp:
29082        (WebCore::Document::regionBasedColumnsEnabled): Deleted.
29083        * dom/Document.h:
29084        * page/FrameView.cpp:
29085        (WebCore::updateLayerPositionFlags):
29086        * page/Settings.in:
29087        * rendering/LayoutState.cpp:
29088        (WebCore::LayoutState::LayoutState):
29089        (WebCore::LayoutState::clearPaginationInformation):
29090        (WebCore::LayoutState::addForcedColumnBreak): Deleted.
29091        * rendering/LayoutState.h:
29092        (WebCore::LayoutState::LayoutState):
29093        (WebCore::LayoutState::isPaginatingColumns): Deleted.
29094        * rendering/RenderBlock.cpp:
29095        (WebCore::RenderBlock::~RenderBlock):
29096        (WebCore::RenderBlock::addChildToContinuation):
29097        (WebCore::RenderBlock::addChild):
29098        (WebCore::RenderBlock::addChildIgnoringContinuation):
29099        (WebCore::RenderBlock::removeLeftoverAnonymousBlock):
29100        (WebCore::canMergeContiguousAnonymousBlocks):
29101        (WebCore::RenderBlock::removeChild):
29102        (WebCore::RenderBlock::recomputeLogicalWidth):
29103        (WebCore::RenderBlock::addOverflowFromChildren):
29104        (WebCore::RenderBlock::expandsToEncloseOverhangingFloats):
29105        (WebCore::RenderBlock::simplifiedLayout):
29106        (WebCore::RenderBlock::layoutPositionedObjects):
29107        (WebCore::RenderBlock::paintObject):
29108        (WebCore::RenderBlock::selectionGaps):
29109        (WebCore::RenderBlock::nodeAtPoint):
29110        (WebCore::RenderBlock::offsetForContents):
29111        (WebCore::RenderBlock::computeIntrinsicLogicalWidths):
29112        (WebCore::RenderBlock::createAnonymousBoxWithSameTypeAs):
29113        (WebCore::RenderBlock::childBoxIsUnsplittableForFragmentation):
29114        (WebCore::RenderBlock::renderName):
29115        (WebCore::RenderBlock::addChildToAnonymousColumnBlocks): Deleted.
29116        (WebCore::RenderBlock::containingColumnsBlock): Deleted.
29117        (WebCore::RenderBlock::splitFlow): Deleted.
29118        (WebCore::RenderBlock::makeChildrenAnonymousColumnBlocks): Deleted.
29119        (WebCore::RenderBlock::columnsBlockForSpanningElement): Deleted.
29120        (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks): Deleted.
29121        (WebCore::RenderBlock::updateLogicalWidthAndColumnWidth): Deleted.
29122        (WebCore::RenderBlock::isTopLayoutOverflowAllowed): Deleted.
29123        (WebCore::RenderBlock::isLeftLayoutOverflowAllowed): Deleted.
29124        (WebCore::RenderBlock::paintColumnRules): Deleted.
29125        (WebCore::RenderBlock::initialBlockOffsetForPainting): Deleted.
29126        (WebCore::RenderBlock::blockDeltaForPaintingNextColumn): Deleted.
29127        (WebCore::RenderBlock::paintColumnContents): Deleted.
29128        (WebCore::ColumnRectIterator::ColumnRectIterator): Deleted.
29129        (WebCore::ColumnRectIterator::advance): Deleted.
29130        (WebCore::ColumnRectIterator::columnRect): Deleted.
29131        (WebCore::ColumnRectIterator::hasMore): Deleted.
29132        (WebCore::ColumnRectIterator::adjust): Deleted.
29133        (WebCore::ColumnRectIterator::update): Deleted.
29134        (WebCore::RenderBlock::hitTestColumns): Deleted.
29135        (WebCore::RenderBlock::adjustForColumnRect): Deleted.
29136        (WebCore::RenderBlock::availableLogicalWidth): Deleted.
29137        (WebCore::RenderBlock::columnGap): Deleted.
29138        (WebCore::RenderBlock::computeColumnCountAndWidth): Deleted.
29139        (WebCore::RenderBlock::requiresColumns): Deleted.
29140        (WebCore::RenderBlock::setComputedColumnCountAndWidth): Deleted.
29141        (WebCore::RenderBlock::updateColumnProgressionFromStyle): Deleted.
29142        (WebCore::RenderBlock::computedColumnWidth): Deleted.
29143        (WebCore::RenderBlock::computedColumnCount): Deleted.
29144        (WebCore::RenderBlock::columnInfo): Deleted.
29145        (WebCore::RenderBlock::columnCount): Deleted.
29146        (WebCore::RenderBlock::columnRectAt): Deleted.
29147        (WebCore::RenderBlock::adjustPointToColumnContents): Deleted.
29148        (WebCore::RenderBlock::adjustRectForColumns): Deleted.
29149        (WebCore::RenderBlock::flipForWritingModeIncludingColumns): Deleted.
29150        (WebCore::RenderBlock::adjustStartEdgeForWritingModeIncludingColumns): Deleted.
29151        (WebCore::RenderBlock::adjustForColumns): Deleted.
29152        (WebCore::RenderBlock::adjustIntrinsicLogicalWidthsForColumns): Deleted.
29153        (WebCore::RenderBlock::paginationUnit): Deleted.
29154        (WebCore::RenderBlock::createAnonymousColumnsWithParentRenderer): Deleted.
29155        (WebCore::RenderBlock::createAnonymousColumnSpanWithParentRenderer): Deleted.
29156        (WebCore::RenderBlock::computeLineGridPaginationOrigin): Deleted.
29157        * rendering/RenderBlock.h:
29158        (WebCore::RenderBlock::pixelSnappedLogicalRightOffsetForLine):
29159        (WebCore::RenderBlock::createAnonymousBlock):
29160        (WebCore::RenderBlock::paintColumnRules):
29161        (WebCore::RenderBlock::createAnonymousColumnsBlock): Deleted.
29162        (WebCore::RenderBlock::createAnonymousColumnSpanBlock): Deleted.
29163        * rendering/RenderBlockFlow.cpp:
29164        (WebCore::RenderBlockFlow::adjustIntrinsicLogicalWidthsForColumns):
29165        (WebCore::RenderBlockFlow::computeIntrinsicLogicalWidths):
29166        (WebCore::RenderBlockFlow::recomputeLogicalWidthAndColumnWidth):
29167        (WebCore::RenderBlockFlow::columnGap):
29168        (WebCore::RenderBlockFlow::computeColumnCountAndWidth):
29169        (WebCore::RenderBlockFlow::layoutBlock):
29170        (WebCore::inNormalFlow):
29171        (WebCore::RenderBlockFlow::applyBeforeBreak):
29172        (WebCore::RenderBlockFlow::applyAfterBreak):
29173        (WebCore::RenderBlockFlow::updateMinimumPageHeight):
29174        (WebCore::RenderBlockFlow::computeOverflow):
29175        (WebCore::RenderBlockFlow::addOverhangingFloats):
29176        (WebCore::RenderBlockFlow::hasOverhangingFloat):
29177        (WebCore::RenderBlockFlow::relayoutForPagination):
29178        (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
29179        (WebCore::RenderBlockFlow::requiresColumns):
29180        (WebCore::RenderBlockFlow::setComputedColumnCountAndWidth):
29181        (WebCore::RenderBlockFlow::updateColumnProgressionFromStyle):
29182        (WebCore::RenderBlockFlow::computedColumnWidth):
29183        (WebCore::RenderBlockFlow::computedColumnCount):
29184        * rendering/RenderBlockFlow.h:
29185        (WebCore::RenderBlockFlow::hasOverhangingFloats):
29186        * rendering/RenderBox.cpp:
29187        (WebCore::RenderBox::styleDidChange):
29188        (WebCore::RenderBox::offsetFromContainer):
29189        (WebCore::RenderBox::computeRectForRepaint):
29190        (WebCore::RenderBox::layoutOverflowRectForPropagation):
29191        * rendering/RenderBox.h:
29192        * rendering/RenderBoxModelObject.cpp:
29193        (WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
29194        (WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
29195        * rendering/RenderBoxModelObject.h:
29196        (WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion):
29197        * rendering/RenderFlexibleBox.cpp:
29198        (WebCore::RenderFlexibleBox::layoutBlock):
29199        * rendering/RenderFlowThread.h:
29200        * rendering/RenderGeometryMap.cpp:
29201        (WebCore::canMapBetweenRenderers):
29202        * rendering/RenderInline.cpp:
29203        (WebCore::RenderInline::clippedOverflowRectForRepaint):
29204        (WebCore::RenderInline::computeRectForRepaint):
29205        (WebCore::RenderInline::offsetFromContainer):
29206        (WebCore::RenderInline::mapLocalToContainer):
29207        * rendering/RenderLayer.cpp:
29208        (WebCore::RenderLayer::RenderLayer):
29209        (WebCore::RenderLayer::updateLayerPositions):
29210        (WebCore::RenderLayer::updatePagination):
29211        (WebCore::accumulateOffsetTowardsAncestor):
29212        (WebCore::RenderLayer::paintList):
29213        (WebCore::RenderLayer::hitTestList):
29214        (WebCore::checkContainingBlockChainForPagination): Deleted.
29215        (WebCore::RenderLayer::useRegionBasedColumns): Deleted.
29216        (WebCore::RenderLayer::paintPaginatedChildLayer): Deleted.
29217        (WebCore::RenderLayer::paintChildLayerIntoColumns): Deleted.
29218        (WebCore::RenderLayer::hitTestPaginatedChildLayer): Deleted.
29219        (WebCore::RenderLayer::hitTestChildLayerColumns): Deleted.
29220        * rendering/RenderLayer.h:
29221        * rendering/RenderMultiColumnFlowThread.cpp:
29222        (WebCore::RenderMultiColumnFlowThread::shouldCheckColumnBreaks):
29223        * rendering/RenderMultiColumnFlowThread.h:
29224        * rendering/RenderObject.cpp:
29225        (WebCore::RenderObject::computeRectForRepaint):
29226        (WebCore::RenderObject::mapLocalToContainer):
29227        (WebCore::RenderObject::pushMappingToContainer):
29228        (WebCore::RenderObject::offsetFromContainer):
29229        * rendering/RenderObject.h:
29230        (WebCore::RenderObject::isAnonymousBlock):
29231        (WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
29232        (WebCore::RenderObject::hasColumns): Deleted.
29233        (WebCore::RenderObject::setHasColumns): Deleted.
29234        (WebCore::RenderObject::isAnonymousColumnsBlock): Deleted.
29235        (WebCore::RenderObject::isAnonymousColumnSpanBlock): Deleted.
29236        (WebCore::RenderObject::adjustForColumns): Deleted.
29237        (WebCore::RenderObject::offsetForColumns): Deleted.
29238        * rendering/RenderText.cpp:
29239        (WebCore::RenderText::selectionRectForRepaint):
29240        * rendering/RenderView.cpp:
29241        (WebCore::RenderView::availableLogicalHeight):
29242        (WebCore::RenderView::pageOrViewLogicalHeight):
29243        (WebCore::RenderView::unextendedBackgroundRect):
29244        (WebCore::RenderView::backgroundRect):
29245        (WebCore::RenderView::shouldDisableLayoutStateForSubtree):
29246        (WebCore::RenderView::pageNumberForBlockProgressionOffset):
29247        (WebCore::RenderView::pageCount):
29248        (WebCore::RenderView::paginationUnit): Deleted.
29249        * rendering/RenderView.h:
29250        (WebCore::LayoutStateMaintainer::LayoutStateMaintainer):
29251        (WebCore::LayoutStateMaintainer::push):
29252        * rendering/SimpleLineLayout.cpp:
29253        (WebCore::SimpleLineLayout::canUseFor):
29254        * rendering/svg/RenderSVGText.cpp:
29255        (WebCore::RenderSVGText::layout):
29256        * style/StyleResolveForDocument.cpp:
29257        (WebCore::Style::resolveForDocument):
29258
292592014-05-06  Brady Eidson  <beidson@apple.com>
29260
29261        Don't select an image that is about to have its menu shown.
29262        <rdar://problem/16807845> and https://bugs.webkit.org/show_bug.cgi?id=132579
29263
29264        Reviewed by Tim Horton.
29265
29266        * WebCore.exp.in:
29267
29268        * editing/Editor.h:
29269        * editing/mac/EditorMac.mm:
29270        (WebCore::Editor::replaceNodeFromPasteboard): New method that first selects
29271          the Node and then immediately pastes over it. Since it’s synchronous the 
29272          selection never has a chance to paint.
29273
29274        * html/shadow/mac/ImageControlsButtonElementMac.cpp:
29275        (WebCore::ImageControlsButtonElementMac::defaultEventHandler): Don’t select the image.
29276
292772014-05-06  Eric Carlson  <eric.carlson@apple.com>
29278
29279        [Mac] make metadata cue attributes consistent
29280        https://bugs.webkit.org/show_bug.cgi?id=132610
29281
29282        Reviewed by Jer Noble.
29283
29284        No new tests, updated http/tests/media/track-in-band-hls-metadata.html.
29285
29286        * platform/mac/SerializedPlatformRepresentationMac.mm:
29287        (WebCore::jsValueWithAVMetadataItemInContext): Don't include keys @dataTypeNamespace
29288            or @pictureType, @dataType -> @type.
29289
292902014-05-06  Brady Eidson  <beidson@apple.com>
29291
29292        "Flash of content without image" when pasting a raw image from the pasteboard
29293        <rdar://problem/16826199> and https://bugs.webkit.org/show_bug.cgi?id=132612
29294
29295        Reviewed by Tim Horton.
29296
29297        Let an ArchiveResource be flagged as "should load immediately":
29298        * loader/archive/ArchiveResource.cpp:
29299        (WebCore::ArchiveResource::ArchiveResource):
29300        * loader/archive/ArchiveResource.h:
29301        (WebCore::ArchiveResource::setShouldLoadImmediately):
29302        (WebCore::ArchiveResource::shouldLoadImmediately):
29303
29304        Set that flag on the ArchiveResource for the image.
29305        Note we quite explicitly do this only in the "read a single image" from the pasteboard
29306        case, because we don't want to do this synchronous step for multiple images at once
29307        such as when pasting a WebArchive:
29308        * editing/mac/EditorMac.mm:
29309        (WebCore::Editor::WebContentReader::readImage):
29310
29311        When creating a new CachedResource, if there is an ArchiveResource that is set to
29312        load immediately, populate the CachedResource immediately instead of scheduling a load:
29313        * loader/cache/CachedResourceLoader.cpp:
29314        (WebCore::CachedResourceLoader::requestResource):
29315
293162014-05-06  Alex Christensen  <achristensen@webkit.org>
29317
29318        Unreviewed build fix for debug after r168367.
29319
29320        * platform/NotImplemented.cpp:
29321        Added include NotImplemented.h.
29322
293232014-05-06  Alex Christensen  <achristensen@webkit.org>
29324
29325        Removed unnecessary notImplemented.h includes.
29326        https://bugs.webkit.org/show_bug.cgi?id=132587
29327
29328        Reviewed by Anders Carlsson.
29329
29330        * Modules/webdatabase/Database.cpp:
29331        * accessibility/AccessibilityObject.cpp:
29332        * bindings/js/Dictionary.h:
29333        * bindings/js/SerializedScriptValue.cpp:
29334        * html/HTMLMediaSession.cpp:
29335        * html/ImageDocument.cpp:
29336        * html/parser/HTMLFormattingElementList.cpp:
29337        * loader/appcache/ApplicationCacheStorage.cpp:
29338        * page/mac/EventHandlerMac.mm:
29339        * platform/NotImplemented.cpp:
29340        * platform/audio/ios/MediaSessionManagerIOS.mm:
29341        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
29342        * platform/graphics/mac/GraphicsContext3DMac.mm:
29343        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
29344        * platform/ios/PlatformScreenIOS.mm:
29345        * platform/mac/PlatformScreenMac.mm:
29346        * platform/mac/WidgetMac.mm:
29347        * platform/mediastream/MediaStreamTrackPrivate.cpp:
29348        * platform/mediastream/mac/AVCaptureDeviceManager.mm:
29349        * platform/mediastream/mac/AVMediaCaptureSource.mm:
29350        * rendering/RenderGrid.cpp:
29351        * workers/SharedWorkerGlobalScope.cpp:
29352        * workers/WorkerGlobalScope.cpp:
29353        * workers/WorkerMessagingProxy.cpp:
29354        Removed notImplemented from list of includes.
29355
293562014-05-06  Enrica Casucci  <enrica@apple.com>
29357
29358        Unreviewed build fix after http://trac.webkit.org/changeset/168364
29359
29360        * rendering/RenderLineBreak.cpp:
29361
293622014-05-06  Christophe Dumez  <ch.dumez@samsung.com>
29363
29364        [HTML] Default argument to HTMLTableSectionElement.insertRow() should be -1
29365        https://bugs.webkit.org/show_bug.cgi?id=132570
29366
29367        Reviewed by Darin Adler.
29368
29369        HTMLTableSectionElement.insertRow()'s argument default value should be -1, not
29370        0, as per the specification:
29371        http://www.whatwg.org/specs/web-apps/current-work/multipage/tabular-data.html#the-tbody-element
29372
29373        The new behavior matches the one of Firefox 29 and IE11, and soon Blink:
29374        https://code.google.com/p/chromium/issues/detail?id=369803
29375
29376        Test: fast/dom/HTMLTableSectionElement/insertRow-default-argument.html
29377
29378        * html/HTMLTableSectionElement.h:
29379        * html/HTMLTableSectionElement.idl:
29380
293812014-05-05  Enrica Casucci  <enrica@apple.com>
29382
29383        REGRESSION(r155957): Selection rects are incorrect when the selection contains BR elements.
29384        https://bugs.webkit.org/show_bug.cgi?id=132596
29385        <rdar://problem/16692206>
29386
29387        Reviewed by Antti Koivisto.
29388
29389        This patch adds an implementation of collectSelectionRects to RenderLineBreak.
29390        It uses the same logic used by RenderText to compute and annotate the returned rect
29391        which is computed, like the caret rect, using information from the rootline box.
29392
29393        * rendering/RenderLineBreak.cpp:
29394        (WebCore::RenderLineBreak::collectSelectionRects):
29395        * rendering/RenderLineBreak.h:
29396
293972014-05-06  Andrei Bucur  <abucur@adobe.com>
29398
29399        [CSS Regions] Optimize the number of regions invalidations
29400        https://bugs.webkit.org/show_bug.cgi?id=132611
29401
29402        Reviewed by David Hyatt.
29403
29404        It is possible to invalidate the region chain of a flow thread
29405        during the layout of the region when its height is not final.
29406
29407        This patch places the check after the height of the region
29408        is determined, reducing the number of invalidations.
29409
29410        Tests: Less invalidations and repaints in the repaint tests for
29411        the flow threads.
29412
29413        * rendering/RenderBlockFlow.cpp:
29414        (WebCore::RenderBlockFlow::updateLogicalHeight):
29415        * rendering/RenderNamedFlowFragment.cpp:
29416        (WebCore::RenderNamedFlowFragment::layoutBlock):
29417        (WebCore::RenderNamedFlowFragment::invalidateRegionIfNeeded):
29418        * rendering/RenderNamedFlowFragment.h:
29419
294202014-05-03  Sam Weinig  <sam@webkit.org>
29421
29422        [Extended Background] Respect repeat-x/repeat-y when creating margin tiles
29423        https://bugs.webkit.org/show_bug.cgi?id=132534
29424
29425        Reviewed by Beth Dakin.
29426
29427        If the background image that is causing margin tiles only repeats in dimension only create
29428        the tiles in that dimension.
29429
29430        * page/FrameView.cpp:
29431        (WebCore::FrameView::updateExtendBackgroundIfNecessary):
29432        (WebCore::FrameView::calculateExtendedBackgroundMode):
29433        (WebCore::FrameView::updateTilesForExtendedBackgroundMode):
29434        (WebCore::FrameView::setBackgroundExtendsBeyondPage): Deleted.
29435        (WebCore::FrameView::needsExtendedBackgroundRectForPainting): Deleted.
29436        (WebCore::FrameView::setHasExtendedBackgroundRectForPainting): Deleted.
29437        * page/FrameView.h:
29438        * page/Settings.cpp:
29439        (WebCore::Settings::setBackgroundShouldExtendBeyondPage):
29440        * platform/graphics/TiledBacking.h:
29441        * platform/graphics/ca/mac/TileController.h:
29442        * platform/graphics/ca/mac/TileController.mm:
29443        (WebCore::TileController::hasHorizontalMargins):
29444        (WebCore::TileController::hasVerticalMargins):
29445        * rendering/RenderElement.cpp:
29446        (WebCore::RenderElement::styleWillChange):
29447        * rendering/RenderLayerBacking.cpp:
29448        (WebCore::RenderLayerBacking::setTiledBackingHasMargins):
29449        * rendering/RenderLayerBacking.h:
29450
294512014-05-06  Chris Fleizach  <cfleizach@apple.com>
29452
29453        AX: VoiceOver does not announce text changes for content editable regions in Safari
29454        https://bugs.webkit.org/show_bug.cgi?id=132577
29455
29456        Reviewed by Mario Sanchez Prada.
29457
29458        When text or children are changed inside of a contenteditable region, we need to 
29459        convert those actions into AXValueChange notifications.
29460
29461        Test: accessibility/content-editable-set-inner-text-generates-axvalue-notification.html
29462
29463        * accessibility/AccessibilityNodeObject.cpp:
29464        (WebCore::AccessibilityNodeObject::childrenChanged):
29465        (WebCore::AccessibilityNodeObject::hasContentEditableAttributeSet): Deleted.
29466        * accessibility/AccessibilityNodeObject.h:
29467        * accessibility/AccessibilityObject.cpp:
29468        (WebCore::AccessibilityObject::hasContentEditableAttributeSet):
29469        * accessibility/AccessibilityObject.h:
29470        * accessibility/AccessibilityRenderObject.cpp:
29471        (WebCore::AccessibilityRenderObject::textChanged):
29472
294732014-05-06  Dirk Schulze  <krit@webkit.org>
29474
29475        [SVG2] Share "on"- event attributes with HTMLElement
29476        https://bugs.webkit.org/show_bug.cgi?id=132604
29477
29478        Reviewed by Mihnea Ovidenie.
29479
29480        Share "on" event attribute parsing between SVGElement and HTMLElement.
29481
29482        Tests: fast/dom/script-tests/event-attribute-availability.js:
29483
29484        * html/HTMLElement.cpp:
29485        (WebCore::HTMLElement::populateEventNameForAttributeLocalNameMap):
29486        (WebCore::populateEventNameForAttributeLocalNameMap): Deleted.
29487        * html/HTMLElement.h: Make populateEventNameForAttributeLocalNameMap
29488            public for use in SVGElement.
29489        * svg/SVGElement.cpp: Use HTMLElement code to parse "on" event
29490            attributes.
29491        (WebCore::SVGElement::parseAttribute):
29492
294932014-05-05  Zan Dobersek  <zdobersek@igalia.com>
29494
29495        [Soup] Use std::unique_ptr<char[]> for the read buffer in SocketStreamHandle
29496        https://bugs.webkit.org/show_bug.cgi?id=132559
29497
29498        Reviewed by Carlos Garcia Campos.
29499
29500        Manage the read buffer array through a std::unique_ptr<char[]> object.
29501        This avoids handling with the raw pointer and also ensures that the memory
29502        allocated with the new[] operator is deleted with the delete[] operator,
29503        a problem exposed by the AddressSanitizer in WebSocket tests.
29504
29505        * platform/network/soup/SocketStreamHandle.h:
29506        * platform/network/soup/SocketStreamHandleSoup.cpp:
29507        (WebCore::SocketStreamHandle::SocketStreamHandle):
29508        (WebCore::SocketStreamHandle::connected):
29509        (WebCore::SocketStreamHandle::readBytes):
29510        (WebCore::SocketStreamHandle::platformClose):
29511
295122014-05-05  Dirk Schulze  <krit@webkit.org>
29513
29514        Adapt inline SVG sizing behavior to Firefox and Blink
29515        https://bugs.webkit.org/show_bug.cgi?id=132569
29516
29517        Reviewed by Dean Jackson.
29518
29519        This patch is ported from Blink CR 308992. Thanks to David Vest for helping
29520        with back porting his Blink patch. From the commit message:
29521
29522        "The basis of this change is to map explicit width and height
29523        attributes to CSS properties, essentially promoting them to
29524        presentation attributes. Note that implicit "100%" width and height
29525        are not mapped.
29526        
29527        This enables us to remove the concept of "percentage intrinsic size"
29528        and rely on normal CSS rules to resolve percentage values.
29529        
29530        The change has been approved by the SVG WG and the spec is being
29531        updated. Minutes here:
29532        
29533        http://www.w3.org/2014/04/07-svg-minutes.html#item03"
29534
29535        The new model was indeed approved by the SVG WG and is basically following
29536        the CSS 2.1 model for replaced elements.
29537
29538        With this patch WebKit, Firefox and Blink have the same behavior for inline SVG.
29539        This is the first successful approach to unify the sizing behavior of SVG
29540        across UAs.
29541
29542        Tests: svg/as-object/sizing/svg-in-object-placeholder-height-auto.html
29543               svg/as-object/sizing/svg-in-object-placeholder-height-fixed.html
29544               svg/as-object/sizing/svg-in-object-placeholder-height-percentage.html
29545               svg/in-html/sizing/svg-inline.html
29546
29547        * css/svg.css: Root SVG elements still need to be sized with height: 100% and
29548            width: 100%. This is necessary since width and height are presentation
29549            attributes now.
29550        (svg:root):
29551        * rendering/RenderBox.h:
29552        (WebCore::RenderBox::computeIntrinsicRatioInformation): Remove all special
29553            behavior for intrinsic and percentage based sizes in SVG. This simplifies and
29554            unifies the code a lot. Most of the logic that is used is in RenderBox and
29555            RenderReplaced now. RenderSVGRoot was cleaned up a lot and is much lighter. 
29556            And so it SVGSVGElement.
29557        * rendering/RenderBoxModelObject.cpp:
29558        (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight):
29559        (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
29560        * rendering/RenderImage.cpp:
29561        (WebCore::RenderImage::computeIntrinsicRatioInformation):
29562        * rendering/RenderImage.h:
29563        * rendering/RenderReplaced.cpp:
29564        (WebCore::RenderReplaced::computeAspectRatioInformationForRenderBox):
29565        (WebCore::RenderReplaced::computeIntrinsicRatioInformation):
29566        (WebCore::RenderReplaced::computeReplacedLogicalWidth):
29567        (WebCore::RenderReplaced::computeReplacedLogicalHeight):
29568        (WebCore::RenderReplaced::computePreferredLogicalWidths):
29569        * rendering/RenderReplaced.h:
29570        * rendering/svg/RenderSVGRoot.cpp:
29571        (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation):
29572        (WebCore::RenderSVGRoot::computeReplacedLogicalWidth):
29573        (WebCore::RenderSVGRoot::computeReplacedLogicalHeight):
29574        (WebCore::RenderSVGRoot::hasRelativeDimensions):
29575        (WebCore::RenderSVGRoot::hasRelativeIntrinsicLogicalWidth): Deleted.
29576        (WebCore::RenderSVGRoot::hasRelativeLogicalHeight): Deleted.
29577        * rendering/svg/RenderSVGRoot.h:
29578        * svg/SVGElement.h:
29579        (WebCore::SVGElement::invalidateSVGPresentationAttributeStyle):
29580        * svg/SVGSVGElement.cpp:
29581        (WebCore::SVGSVGElement::isPresentationAttribute):
29582        (WebCore::SVGSVGElement::collectStyleForPresentationAttribute):
29583        (WebCore::SVGSVGElement::svgAttributeChanged):
29584        (WebCore::SVGSVGElement::currentViewportSize):
29585        (WebCore::SVGSVGElement::hasIntrinsicWidth):
29586        (WebCore::SVGSVGElement::hasIntrinsicHeight):
29587        (WebCore::SVGSVGElement::intrinsicWidth):
29588        (WebCore::SVGSVGElement::intrinsicHeight):
29589        (WebCore::SVGSVGElement::widthAttributeEstablishesViewport): Deleted.
29590        (WebCore::SVGSVGElement::heightAttributeEstablishesViewport): Deleted.
29591        * svg/SVGSVGElement.h:
29592        * svg/graphics/SVGImage.cpp:
29593        (WebCore::SVGImage::containerSize):
29594        * xml/XMLErrors.cpp: If an error occurs in a stand alone SVG file, we create
29595            an XHTML document with the error message and append the SVG file.
29596            This SVG file now follows the CSS sizing behavior as inline SVG.
29597            Therefore, we need to set width and height to 100% explicitly.
29598        (WebCore::XMLErrors::insertErrorMessageBlock):
29599
296002014-05-05  Ryuan Choi  <ryuan.choi@samsung.com>
29601
29602        [EFL] REGRESSION(167145): JavaScript media controls are broken
29603        https://bugs.webkit.org/show_bug.cgi?id=131573
29604
29605        Reviewed by Brent Fulgham.
29606
29607        * PlatformEfl.cmake: Add the localized strings file to the list of user agent scripts.
29608        * platform/efl/RenderThemeEfl.cpp:
29609        (WebCore::RenderThemeEfl::mediaControlsScript): Include the localized strings file in the script body.
29610
296112014-05-05  Jeremy Jones  <jeremyj@apple.com>
29612
29613        Implement scan backward and forward in video fullscreen.
29614        https://bugs.webkit.org/show_bug.cgi?id=132517
29615
29616        Reviewed by Simon Fraser.
29617
29618        Implement scanning forward and backward. This implements methods in 
29619        WebAVPlayerController and forwards them through WebVideoFullscreenModelMediaElement
29620        and on to HTMLMediaElement.
29621
29622        * WebCore.exp.in: necessary exports.
29623        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
29624        (-[WebAVPlayerController seekToTime:]):
29625        Use fastSeek in this case.
29626        (-[WebAVPlayerController canScanForward]): If you can play, you can scan.
29627        (+[WebAVPlayerController keyPathsForValuesAffectingCanScanForward]): ditto
29628        (-[WebAVPlayerController beginScanningForward:]): ditto
29629        (-[WebAVPlayerController endScanningForward:]): ditto
29630        (-[WebAVPlayerController canScanBackward]): If you can play, you can scan.
29631        (+[WebAVPlayerController keyPathsForValuesAffectingCanScanBackward]): ditto
29632        (-[WebAVPlayerController beginScanningBackward:]): ditto
29633        (-[WebAVPlayerController endScanningBackward:]): ditto
29634        (-[WebAVPlayerController canSeekToBeginning]):
29635        This looks at seekableRanges to determine if any seeking is possible.
29636        (+[WebAVPlayerController keyPathsForValuesAffectingCanSeekToBeginning]):
29637        depends on seekableRanges.
29638        (-[WebAVPlayerController seekToBeginning:]): seek to -ininity
29639        (-[WebAVPlayerController canSeekToEnd]):
29640        This looks at seekableRanges to determine if any seeking is possible.
29641        (+[WebAVPlayerController keyPathsForValuesAffectingCanSeekToEnd]):
29642        depends on seekableRanges.
29643        (-[WebAVPlayerController seekToEnd:]): seek to INFINITY.
29644        * platform/ios/WebVideoFullscreenModel.h:
29645        Add 4 new functions.
29646        * platform/ios/WebVideoFullscreenModelMediaElement.h:
29647        ditto
29648        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
29649        (WebVideoFullscreenModelMediaElement::fastSeek): forwards to HTMLMediaEelement
29650        (WebVideoFullscreenModelMediaElement::beginScanningForward): forwards to HTMLMediaEelement
29651        (WebVideoFullscreenModelMediaElement::beginScanningBackward): forwards to HTMLMediaEelement
29652        (WebVideoFullscreenModelMediaElement::endScanning): forwards to HTMLMediaEelement
29653
296542014-05-05  Benjamin Poulain  <bpoulain@apple.com>
29655
29656        [iOS][WK2] Prefetch DNS hostnames on tap highlight
29657        https://bugs.webkit.org/show_bug.cgi?id=132509
29658
29659        Reviewed by Alexey Proskuryakov.
29660
29661        * WebCore.exp.in:
29662        * dom/Element.cpp:
29663        * dom/Element.h:
29664        (WebCore::Element::absoluteLinkURL()):
29665
296662014-05-05  Simon Fraser  <simon.fraser@apple.com>
29667
29668        [iOS WK2] Flickery scrolling inside overflow-scrolling: touch
29669        https://bugs.webkit.org/show_bug.cgi?id=132591
29670        <rdar://problem/16760466>
29671
29672        Reviewed by Tim Horton.
29673
29674        Avoid triggering layer tree commits that touch the layer's boundsOrigin
29675        while the user is scrolling in the UI process.
29676        
29677        Fix the WKOverflowScrollViewDelegate to pass along an "inUserInteration"
29678        flag to the ScrollingTree to say that we're in the middle of a user interaction
29679        (and also to send a final non-interactive update). That gets passed along
29680        to the web process, and turned into "SyncScrollingLayerPosition" update.
29681        AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll() consults
29682        this, and uses it to set a flag on the ScrollableArea to say that the scroll
29683        is a user scroll.
29684        
29685        RenderLayerBacking then makes use of this (in existing code, shared with WK1)
29686        to avoid triggering layer bounds setting. Instead, it now just calls syncBoundsOrigin(),
29687        which updates the GraphicsLayer without touching platform layers. This is necessary
29688        so that GraphicsLayer geometry is up-to-date (used for tiled layer visibility
29689        computations).
29690        
29691        Finally, a hack in GraphicsLayerCA::computeVisibleRect() is conditionalized
29692        for WebKit1 by checking the type of platform layer.
29693
29694        * WebCore.exp.in:
29695        * page/scrolling/AsyncScrollingCoordinator.cpp:
29696        (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
29697        * page/scrolling/ScrollingTree.cpp:
29698        (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling):
29699        * page/scrolling/ScrollingTree.h:
29700        * platform/graphics/GraphicsLayer.h:
29701        (WebCore::GraphicsLayer::syncBoundsOrigin):
29702        * platform/graphics/ca/GraphicsLayerCA.cpp:
29703        (WebCore::GraphicsLayerCA::computeVisibleRect):
29704        * rendering/RenderLayerBacking.cpp:
29705        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
29706
297072014-05-05  Alexey Proskuryakov  <ap@apple.com>
29708
29709        Stop using BlobData on client side
29710        https://bugs.webkit.org/show_bug.cgi?id=132582
29711
29712        Reviewed by Sam Weinig.
29713
29714        Blob registration now uses either a single file path, or a vector of much simpler
29715        BlobPart objects, not an array with arbitrarily sliced blobs or files, which can't happen.
29716
29717        * Modules/websockets/WebSocket.cpp:(WebCore::WebSocket::didReceiveBinaryData):
29718        Use a new simpler Blob constructor.
29719
29720        * WebCore.xcodeproj/project.pbxproj: Added BlobPart, removed BlobRegistrationData.
29721
29722        * bindings/js/JSBlobCustom.cpp: (WebCore::JSBlobConstructor::constructJSBlob):
29723        Use Vector<BlobPart> instead of BlobData (1 line of code instead of 5).
29724
29725        * dom/DataTransfer.cpp: (WebCore::DataTransfer::hasFileOfType): Updated for
29726        File::contentTypeFromFilePathOrName rename.
29727
29728        * fileapi/Blob.cpp: (WebCore::Blob::Blob):
29729        * fileapi/Blob.h:
29730        (WebCore::Blob::create):
29731        (WebCore::Blob::deserialize):
29732        * fileapi/File.cpp:
29733        (WebCore::File::File):
29734        (WebCore::File::contentTypeFromFilePathOrName):
29735        (WebCore::createBlobDataForFileWithType): Deleted.
29736        (WebCore::createBlobDataForFile): Deleted.
29737        (WebCore::createBlobDataForFileWithName): Deleted.
29738        (WebCore::File::contentTypeFromFilePath): Deleted.
29739        * fileapi/File.h: (WebCore::File::deserialize): Deleted.
29740        Added and updated constructors to not use BlobData. Changed special case constructors
29741        to use name tags instead of non-enforced comments.
29742
29743        * fileapi/ThreadableBlobRegistry.h:
29744        * fileapi/ThreadableBlobRegistry.cpp:
29745        (WebCore::BlobRegistryContext::BlobRegistryContext): Updated with new data members
29746        that were split out of BlobData.
29747        (WebCore::ThreadableBlobRegistry::registerFileBlobURL): Added.
29748        (WebCore::ThreadableBlobRegistry::registerBlobURL): Updated to pass Content-Type
29749        explicitly, as it's no longer hidden in BlobData.
29750
29751        * fileapi/WebKitBlobBuilder.h:
29752        * fileapi/WebKitBlobBuilder.cpp:
29753        (WebCore::BlobBuilder::append):
29754        (WebCore::BlobBuilder::finalize):
29755        (WebCore::BlobBuilder::appendBytesData): Deleted.
29756        Updated to use BlobPart. There is no longer any need to special case Files,
29757        the registry takes care of that.
29758
29759        * platform/network/BlobData.h:
29760        * platform/network/BlobData.cpp:
29761        (WebCore::BlobDataItem::detachFromCurrentThread): Deleted.
29762        (WebCore::BlobData::detachFromCurrentThread): Deleted.
29763        BlobData will only be used on main thread by the registry.
29764
29765        * platform/network/BlobPart.h: Added. A new class to encapsulate a list of blobs
29766        that are combined into a new blob, as exposed to JS via Blob constructor.
29767
29768        * platform/network/BlobRegistry.h:
29769        * platform/network/BlobRegistryImpl.cpp:
29770        (WebCore::BlobRegistryImpl::registerFileBlobURL):
29771        (WebCore::BlobRegistryImpl::registerBlobURL):
29772        * platform/network/BlobRegistryImpl.h:
29773        Updated for the new registration methods. We no longer have arbitrary BlobDatas
29774        coming in.
29775
29776        * platform/network/FormData.cpp: Don't include BlobData for now (but really,
29777        BlobStorageData is the same thing, and they will be merged soon).
29778        Unfortunately, FormData is used by both client and registry side, and there is
29779        no clear delimitation at the time.
29780 
29781        * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::responseBlob): Use the new simpler
29782        way to create a Blob.
29783
297842014-05-05  Benjamin Poulain  <benjamin@webkit.org>
29785
29786        Clean up Image Document and tweak the layout and viewport
29787        https://bugs.webkit.org/show_bug.cgi?id=132552
29788
29789        Reviewed by Sam Weinig.
29790
29791        The #ifdef in every function was making quite a mess. A lot of that code does
29792        not make sense on iOS.
29793
29794        This patch make a clean split between mouse related stuff and iOS.
29795
29796        Also:
29797        -Change the viewport to be only width based, and avoid scaling in portrait.
29798        -Center the image horizontally in the view.
29799
29800        * html/ImageDocument.cpp:
29801        (WebCore::ImageDocument::ImageDocument):
29802        (WebCore::ImageDocument::createDocumentStructure):
29803        (WebCore::ImageDocument::imageUpdated):
29804        (WebCore::ImageDocument::scale):
29805        (WebCore::ImageDocument::resizeImageToFit):
29806        (WebCore::ImageDocument::imageFitsInWindow):
29807        (WebCore::ImageDocument::windowSizeChanged):
29808        (WebCore::ImageDocument::imageClicked):
29809        * html/ImageDocument.h:
29810
298112014-05-05  Beth Dakin  <bdakin@apple.com>
29812
29813        Need a delegate that informs the UI process when the page's pin state changes
29814        https://bugs.webkit.org/show_bug.cgi?id=132583
29815        -and corresponding-
29816        <rdar://problem/16806231>
29817
29818        Reviewed by Anders Carlsson.
29819
29820        We should default all of these pin-state value to true.
29821        * page/scrolling/ScrollingTree.cpp:
29822        (WebCore::ScrollingTree::ScrollingTree):
29823
298242014-05-05  Christophe Dumez  <ch.dumez@samsung.com>
29825
29826        Named element cache can become invalid during HTMLCollection::updateNamedElementCache()
29827        https://bugs.webkit.org/show_bug.cgi?id=132575
29828
29829        Reviewed by Ryosuke Niwa.
29830
29831        Make sure the named element cache object stays valid in
29832        HTMLCollection::updateNamedElementCache() while it is populating it.
29833
29834        The method was previously creating and setting the cache first, and then start
29835        traversing the DOM tree to populate it. As a consequence, hasNamedElementCache()
29836        would start returning true before the cache is actually populated.
29837        The issue is that finding matches in the DOM tree can cause
29838        HTMLCollection::invalidateCache() to be called under certain circumstances and
29839        thus the named element cache object can become invalid while
29840        updateNamedElementCache() is populating it.
29841
29842        To avoid the issue, this patch updates updateNamedElementCache() so that the
29843        named element cache map is set *after* traversing the DOM tree. This way,
29844        hasNamedElementCache() returns false while the cache is being populated and
29845        there is no chance of it being invalidated too early.
29846
29847        Test: fast/dom/htmlcollection-selectedOptions-namedItem-crash.html
29848
29849        * html/HTMLCollection.cpp:
29850        (WebCore::HTMLCollection::updateNamedElementCache):
29851        * html/HTMLCollection.h:
29852        (WebCore::HTMLCollection::setNameItemCache):
29853        (WebCore::HTMLCollection::createNameItemCache): Deleted.
29854        * html/HTMLFormControlsCollection.cpp:
29855        (WebCore::HTMLFormControlsCollection::updateNamedElementCache):
29856
298572014-05-05  Benjamin Poulain  <benjamin@webkit.org>
29858
29859        [iOS][WK2] Special case ViewGestureGeometryCollector::collectGeometryForSmartMagnificationGesture() for image documents
29860        https://bugs.webkit.org/show_bug.cgi?id=132553
29861
29862        Reviewed by Tim Horton.
29863
29864        * WebCore.exp.in:
29865        * WebCore.xcodeproj/project.pbxproj:
29866        * html/ImageDocument.cpp:
29867        (WebCore::ImageDocument::imageElement):
29868        * html/ImageDocument.h:
29869
298702014-05-05  Ion Rosca  <rosca@adobe.com>
29871
29872        [CSS Blending] Webkit-blend-mode fails for accelerated parent with overflow:hidden
29873        https://bugs.webkit.org/show_bug.cgi?id=126160
29874
29875        When the isolating layer has overflow:hidden, it will create a descendant clipping layer
29876        (m_childContainmentLayer), which will restrict the bleding layer to reading the backdrop
29877        from the isolating layer.
29878        The solution in this patch is to forbid the isolating layer to create a descendant clipping
29879        layer and make all the children to get their own ancestor clipping layers instead.
29880
29881        Reviewed by Dean Jackson.
29882
29883        Tests: css3/compositing/blend-mode-accelerated-parent-overflow-hidden.html
29884               css3/compositing/blend-mode-clip-accelerated-blending-canvas.html
29885               css3/compositing/blend-mode-clip-accelerated-blending-child.html
29886               css3/compositing/blend-mode-clip-accelerated-blending-double.html
29887               css3/compositing/blend-mode-clip-accelerated-blending-with-siblings.html
29888               css3/compositing/blend-mode-clip-accelerated-transformed-blending.html
29889               css3/compositing/blend-mode-clip-rect-accelerated-blending.html
29890
29891        * rendering/RenderLayerBacking.cpp:
29892        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
29893        when the compositing ancestor isolates blending we take it into account for computing
29894        the clipping rect for this layer, because it was not allowed to create the descendant
29895        clipping layer. 
29896        * rendering/RenderLayerCompositor.cpp:
29897        (WebCore::RenderLayerCompositor::clippedByAncestor):
29898        when the compositing ancestor isolates blending we decide if a layer is clipped by ancestor
29899        by computing the clipping rect taking into account all the ancestors up to and including
29900        the compositing ancestor.
29901        (WebCore::RenderLayerCompositor::clipsCompositingDescendants):
29902        if a layer isolates blending, it is not allowed to create a descendant clipping layer.
29903
299042014-05-05  Dirk Schulze  <krit@webkit.org>
29905
29906        AX: tabindex support in SVG2
29907        https://bugs.webkit.org/show_bug.cgi?id=130212
29908
29909        Reviewed by Chris Fleizach.
29910
29911        The patch is mainly based on a patch for Blink by Erik Dahlström.
29912        https://src.chromium.org/viewvc/blink?revision=172964&view=revision
29913
29914        It adds support for tabindex to SVG by reusing the HTML code.
29915
29916        Spec: https://svgwg.org/svg2-draft/interact.html#sequential-focus-navigation-and-the-tabindex-attribute
29917        IDL attribute: https://svgwg.org/svg2-draft/types.html#__svg__SVGElement__tabIndex
29918
29919        Test: svg/custom/tabindex-order.html
29920
29921        * dom/Element.cpp:
29922        (WebCore::Element::setTabIndex): Moved from HTMLElement and shared with all elements.
29923        * dom/Element.h:
29924        * html/HTMLAnchorElement.cpp: Remove outdated comment.
29925        (WebCore::HTMLAnchorElement::canStartSelection):
29926        * html/HTMLElement.cpp:
29927        (WebCore::HTMLElement::setTabIndex): Deleted.
29928        * html/HTMLElement.h:
29929        * svg/SVGAElement.cpp: Uses the same logic as HTMLAnchorElement now.
29930        (WebCore::SVGAElement::tabIndex):
29931        (WebCore::SVGAElement::supportsFocus):
29932        (WebCore::SVGAElement::isMouseFocusable):
29933        (WebCore::SVGAElement::isKeyboardFocusable):
29934        (WebCore::SVGAElement::canStartSelection):
29935        * svg/SVGAElement.h:
29936        * svg/SVGCircleElement.h:
29937        * svg/SVGClipPathElement.h:
29938        * svg/SVGDefsElement.h:
29939        * svg/SVGElement.cpp:
29940        (WebCore::SVGElement::tabIndex): Return -1 if element can not be focused.
29941        (WebCore::SVGElement::parseAttribute):
29942        (WebCore::SVGElement::isMouseFocusable):
29943        (WebCore::SVGElement::isKeyboardFocusable): Deleted. Use function on Element.
29944        * svg/SVGElement.h:
29945        * svg/SVGElement.idl:
29946        * svg/SVGEllipseElement.h:
29947        * svg/SVGGElement.h:
29948        * svg/SVGGraphicsElement.h: Remove supportsFocus() from inheriting functions.
29949            Don't just return true. SVG elements should not be focusable by default.
29950            Instead check if tabindex was set explicitly.
29951        * svg/SVGImageElement.h:
29952        * svg/SVGLineElement.h:
29953        * svg/SVGPathElement.h:
29954        * svg/SVGPolyElement.h:
29955        * svg/SVGRectElement.h:
29956        * svg/SVGSVGElement.h:
29957        * svg/SVGSwitchElement.h:
29958        * svg/SVGSymbolElement.h:
29959        * svg/SVGTextElement.h:
29960
299612014-05-05  Jeremy Jones  <jeremyj@apple.com>
29962
29963        Implement beginScrubbing and endScrubbing for video fullscreen.
29964        https://bugs.webkit.org/show_bug.cgi?id=132520
29965
29966        Reviewed by Eric Carlson.
29967
29968        Plumb through beginScrubbing and endScrubbing from AVKit down to HTMLMediaElement.
29969        This keeps the playback state consistent while scrubbing and allows playback state
29970        to return to the original state when scrubbing is complete.
29971
29972        * WebCore.exp.in:
29973        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
29974        (-[WebAVPlayerController beginScrubbing:]):
29975        (-[WebAVPlayerController endScrubbing:]):
29976        * platform/ios/WebVideoFullscreenModel.h:
29977        * platform/ios/WebVideoFullscreenModelMediaElement.h:
29978        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
29979        (WebVideoFullscreenModelMediaElement::beginScrubbing):
29980        (WebVideoFullscreenModelMediaElement::endScrubbing):
29981
299822014-05-05  Tim Horton  <timothy_horton@apple.com>
29983
29984        More long hangs under IOSurfacePool::evict
29985        https://bugs.webkit.org/show_bug.cgi?id=132576
29986        <rdar://problem/16769469>
29987
29988        Reviewed by Simon Fraser.
29989
29990        * platform/graphics/cg/IOSurfacePool.cpp:
29991        (WebCore::IOSurfacePool::evict):
29992        If the pool is too full, we should be evicting in-use surfaces
29993        even if the size of the in-use surfaces has dropped below maximumInUseBytes,
29994        otherwise we can get stuck in an infinite loop with 0 cached surfaces
29995        and 1+ in-use surfaces.
29996
299972014-05-05  Radu Stavila  <stavila@adobe.com>
29998
29999        [CSS Regions] Remove regionLayoutUpdate event
30000        https://bugs.webkit.org/show_bug.cgi?id=132564
30001
30002        Reviewed by Simon Fraser.
30003
30004        The regionLayoutUpdate event was removed from the regions spec and was replaced by two other events: 
30005        regionOversetChange and regionFragmentChange.
30006
30007        No new tests needed, this patch removes a feature.
30008
30009        * dom/EventNames.h:
30010        * dom/WebKitNamedFlow.cpp:
30011        (WebCore::WebKitNamedFlow::dispatchRegionLayoutUpdateEvent): Deleted.
30012        * dom/WebKitNamedFlow.h:
30013        * inspector/InspectorCSSAgent.cpp:
30014        (WebCore::InspectorCSSAgent::resetNonPersistentData):
30015        (WebCore::InspectorCSSAgent::willRemoveNamedFlow):
30016        (WebCore::UpdateRegionLayoutTask::UpdateRegionLayoutTask): Deleted.
30017        (WebCore::UpdateRegionLayoutTask::scheduleFor): Deleted.
30018        (WebCore::UpdateRegionLayoutTask::unschedule): Deleted.
30019        (WebCore::UpdateRegionLayoutTask::reset): Deleted.
30020        (WebCore::UpdateRegionLayoutTask::timerFired): Deleted.
30021        (WebCore::InspectorCSSAgent::didUpdateRegionLayout): Deleted.
30022        (WebCore::InspectorCSSAgent::regionLayoutUpdated): Deleted.
30023        * inspector/InspectorCSSAgent.h:
30024        * inspector/InspectorInstrumentation.cpp:
30025        (WebCore::InspectorInstrumentation::didUpdateRegionLayoutImpl): Deleted.
30026        * inspector/InspectorInstrumentation.h:
30027        (WebCore::InspectorInstrumentation::didUpdateRegionLayout): Deleted.
30028        * inspector/protocol/CSS.json:
30029        * rendering/RenderNamedFlowFragment.cpp:
30030        (WebCore::RenderNamedFlowFragment::updateOversetState):
30031        * rendering/RenderNamedFlowThread.cpp:
30032        (WebCore::RenderNamedFlowThread::RenderNamedFlowThread):
30033        (WebCore::RenderNamedFlowThread::removeRegionFromThread):
30034        (WebCore::RenderNamedFlowThread::layout):
30035        (WebCore::RenderNamedFlowThread::dispatchRegionLayoutUpdateEventIfNeeded): Deleted.
30036        (WebCore::RenderNamedFlowThread::regionLayoutUpdateEventTimerFired): Deleted.
30037        * rendering/RenderNamedFlowThread.h:
30038
300392014-05-05  Rik Cabanier  <cabanier@adobe.com>
30040
30041        Enhance IDL compiler so it supports unrestricted float and double
30042        https://bugs.webkit.org/show_bug.cgi?id=132460
30043
30044        Reviewed by Dirk Schulze.
30045
30046        Updated IDL compiler so it supports unrestricted types.
30047        Also updated the IDL files so they use unrestricted float and
30048        double.
30049
30050        Tests:
30051        * canvas/philip/tests/2d.gradient.linear.nonfinite.html:
30052        * canvas/philip/tests/2d.gradient.object.invalidoffset.html:
30053        * canvas/philip/tests/2d.gradient.radial.nonfinite.html:
30054        * canvas/philip/tests/2d.imageData.get.nonfinite.html:
30055        * canvas/philip/tests/2d.imageData.put.nonfinite.html:
30056        * canvas/philip/tests/2d.missingargs.html:
30057        * fast/canvas/canvas-getImageData-invalid-expected.txt:
30058        * fast/canvas/canvas-putImageData-expected.txt:
30059        * fast/canvas/canvas-putImageData.js:
30060
30061        * Modules/battery/BatteryManager.idl:
30062        * Modules/gamepad/Gamepad.idl:
30063        * Modules/geolocation/Coordinates.idl:
30064        * Modules/mediasource/MediaSource.idl:
30065        * Modules/mediasource/SourceBuffer.idl:
30066        * Modules/mediasource/VideoPlaybackQuality.idl:
30067        * Modules/mediastream/MediaSourceStates.idl:
30068        * Modules/proximity/DeviceProximityEvent.idl:
30069        * Modules/speech/SpeechGrammar.idl:
30070        * Modules/speech/SpeechGrammarList.idl:
30071        * Modules/speech/SpeechRecognitionAlternative.idl:
30072        * Modules/speech/SpeechSynthesisEvent.idl:
30073        * Modules/speech/SpeechSynthesisUtterance.idl:
30074        * Modules/webaudio/AnalyserNode.idl:
30075        * Modules/webaudio/AudioBuffer.idl:
30076        * Modules/webaudio/AudioBufferSourceNode.idl:
30077        * Modules/webaudio/AudioContext.idl:
30078        * Modules/webaudio/AudioListener.idl:
30079        * Modules/webaudio/AudioParam.idl:
30080        * Modules/webaudio/AudioProcessingEvent.idl:
30081        * Modules/webaudio/OfflineAudioContext.idl:
30082        * Modules/webaudio/OscillatorNode.idl:
30083        * Modules/webaudio/PannerNode.idl:
30084        * bindings/scripts/CodeGenerator.pm:
30085        * bindings/scripts/CodeGeneratorGObject.pm:
30086        (GetGValueTypeName):
30087        (GetGlibTypeName):
30088        * bindings/scripts/CodeGeneratorJS.pm:
30089        (GenerateImplementation):
30090        (GenerateParametersCheck):
30091        (JSValueToNative):
30092        * bindings/scripts/CodeGeneratorObjC.pm:
30093        (GetObjCType):
30094        (GenerateHeader):
30095        * bindings/scripts/test/TestObj.idl:
30096        * bindings/scripts/test/TestTypedefs.idl:
30097        * css/CSSPrimitiveValue.idl:
30098        * css/WebKitCSSMatrix.idl:
30099        * dom/ClientRect.idl:
30100        * dom/DeviceMotionEvent.idl:
30101        * dom/DeviceOrientationEvent.idl:
30102        * dom/Document.idl:
30103        * dom/RequestAnimationFrameCallback.idl:
30104        * dom/Touch.idl:
30105        * dom/TransitionEvent.idl:
30106        * dom/WebKitAnimationEvent.idl:
30107        * dom/WebKitTransitionEvent.idl:
30108        * dom/WheelEvent.idl:
30109        * html/HTMLInputElement.idl:
30110        * html/HTMLMediaElement.idl:
30111        * html/HTMLMeterElement.idl:
30112        * html/HTMLProgressElement.idl:
30113        * html/MediaController.idl:
30114        * html/TextMetrics.idl:
30115        * html/TimeRanges.idl:
30116        * html/canvas/CanvasRenderingContext2D.idl:
30117        * html/canvas/WebGLRenderingContext.idl:
30118        * html/track/DataCue.idl:
30119        * html/track/TextTrackCue.idl:
30120        * html/track/VTTCue.idl:
30121        * html/track/VTTRegion.idl:
30122        * inspector/InspectorFrontendHost.idl:
30123        * inspector/ScriptProfile.idl:
30124        * inspector/ScriptProfileNode.idl:
30125        * page/DOMWindow.idl:
30126        * page/Performance.idl:
30127        * page/PerformanceEntry.idl:
30128        * page/PerformanceResourceTiming.idl:
30129        * page/SpeechInputResult.idl:
30130        * page/WebKitPoint.idl:
30131        * svg/SVGAngle.idl:
30132        * svg/SVGAnimatedNumber.idl:
30133        * svg/SVGAnimationElement.idl:
30134        * svg/SVGFEDropShadowElement.idl:
30135        * svg/SVGFEGaussianBlurElement.idl:
30136        * svg/SVGFEMorphologyElement.idl:
30137        * svg/SVGGlyphRefElement.idl:
30138        * svg/SVGLength.idl:
30139        * svg/SVGMatrix.idl:
30140        * svg/SVGNumber.idl:
30141        * svg/SVGPathElement.idl:
30142        * svg/SVGPathSegArcAbs.idl:
30143        * svg/SVGPathSegArcRel.idl:
30144        * svg/SVGPathSegCurvetoCubicAbs.idl:
30145        * svg/SVGPathSegCurvetoCubicRel.idl:
30146        * svg/SVGPathSegCurvetoCubicSmoothAbs.idl:
30147        * svg/SVGPathSegCurvetoCubicSmoothRel.idl:
30148        * svg/SVGPathSegCurvetoQuadraticAbs.idl:
30149        * svg/SVGPathSegCurvetoQuadraticRel.idl:
30150        * svg/SVGPathSegCurvetoQuadraticSmoothAbs.idl:
30151        * svg/SVGPathSegCurvetoQuadraticSmoothRel.idl:
30152        * svg/SVGPathSegLinetoAbs.idl:
30153        * svg/SVGPathSegLinetoHorizontalAbs.idl:
30154        * svg/SVGPathSegLinetoHorizontalRel.idl:
30155        * svg/SVGPathSegLinetoRel.idl:
30156        * svg/SVGPathSegLinetoVerticalAbs.idl:
30157        * svg/SVGPathSegLinetoVerticalRel.idl:
30158        * svg/SVGPathSegMovetoAbs.idl:
30159        * svg/SVGPathSegMovetoRel.idl:
30160        * svg/SVGPoint.idl:
30161        * svg/SVGRect.idl:
30162        * svg/SVGSVGElement.idl:
30163        * svg/SVGTextContentElement.idl:
30164        * svg/SVGTransform.idl:
30165        * svg/SVGZoomEvent.idl:
30166        * testing/InternalSettings.idl:
30167        * testing/Internals.idl:
30168        * xml/XPathResult.idl:
30169
301702014-05-05  Tim Horton  <timothy_horton@apple.com>
30171
30172        Use a layer delegate instead of web_disableAllActions wherever possible
30173        https://bugs.webkit.org/show_bug.cgi?id=132560
30174        <rdar://problem/16459284>
30175
30176        Reviewed by Simon Fraser.
30177
30178        * WebCore.exp.in:
30179        * WebCore.xcodeproj/project.pbxproj:
30180        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
30181        (PlatformCALayerMac::commonInit):
30182        If we own the platform layer, set its delegate to the action-disabling WebActionDisablingCALayerDelegate.
30183        If we don't, its actual owner might want to control the delegate, so continue using web_disableAllActions.
30184
30185        * platform/graphics/cocoa/WebActionDisablingCALayerDelegate.h: Added.
30186        * platform/graphics/cocoa/WebActionDisablingCALayerDelegate.mm: Added.
30187        (+[WebActionDisablingCALayerDelegate shared]):
30188        (-[WebActionDisablingCALayerDelegate actionForLayer:forKey:]):
30189        Add a class that can act as the delegate of a CALayer, and disables all actions.
30190
30191        * platform/graphics/cocoa/WebCoreCALayerExtras.h: Renamed from Source/WebCore/platform/graphics/mac/WebCoreCALayerExtras.h.
30192        * platform/graphics/cocoa/WebCoreCALayerExtras.mm: Renamed from Source/WebCore/platform/graphics/mac/WebCoreCALayerExtras.mm.
30193        (-[CALayer web_disableAllActions]):
30194        Move WebCoreCALayerExtras from mac/ to cocoa/.
30195
301962014-05-05  Martin Hock  <mhock@apple.com>
30197
30198        Session-aware plugin autostart data
30199        https://bugs.webkit.org/show_bug.cgi?id=131758
30200        <rdar://problem/15906540>
30201
30202        Reviewed by Alexey Proskuryakov.
30203
30204        * html/HTMLPlugInImageElement.cpp:
30205        (WebCore::HTMLPlugInImageElement::userDidClickSnapshot):
30206        * page/PlugInClient.h:
30207
302082014-05-05  Radu Stavila  <stavila@adobe.com>
30209
30210        [CSS Regions] Elements with overflow:auto are not painted inside regions when following a float
30211        https://bugs.webkit.org/show_bug.cgi?id=131161
30212
30213        Reviewed by David Hyatt.
30214
30215        When a float-avoiding element (such as overflow:auto) is flowed into a flow thread after a float, its 
30216        logical left is not set on its frameRect or its layer's topLeft, but is instead kept in its RenderBoxRegionInfo
30217        structure. In some situation, this causes paint rejection to kick-in because intersecting the layer's rect
30218        (which DOESN'T contain the logical left from the region info object) with the computed background rect 
30219        (which contains the logical left from the region info object) results in an empty rect.
30220
30221        Test: fast/regions/overflow-auto-after-float.html
30222
30223        * rendering/RenderLayer.cpp:
30224        (WebCore::RenderLayer::calculateClipRects):
30225
302262014-05-05  Andrei Bucur  <abucur@adobe.com>
30227
30228        [CSSRegions] Slider displayed wrong in regions
30229        https://bugs.webkit.org/show_bug.cgi?id=132243
30230
30231        Reviewed by Mihnea Ovidenie.
30232
30233        In case a box didn't have a range, getRegionRangeForBox was searching for
30234        the top-most unplittable ancestor. This is not correct in every case. It's
30235        possible to have a box with range that has children without ranges (e.g. an
30236        absolutely positioned inline box with shadow descendants).
30237
30238        I've modified getRegionRangeForBox to search for the first ancestor that
30239        has a cached range and use that instead of looking for an unsplittable box.
30240        The range of the box is the region at the top of the box, clamped by the
30241        range of the ancestor. This will be correct all the time once all the layout
30242        systems are region range aware and are able to cache it.
30243
30244        Test: fast/regions/positioned-slider-in-regions.html
30245
30246        * rendering/RenderFlowThread.cpp:
30247        (WebCore::RenderFlowThread::hasRegionRangeForBox):
30248        (WebCore::RenderFlowThread::getRegionRangeForBox):
30249        * rendering/RenderFlowThread.h:
30250
302512014-05-05  Andrei Bucur  <abucur@adobe.com>
30252
30253        [CSS Regions] ASSERT when hovering over region
30254        https://bugs.webkit.org/show_bug.cgi?id=128809
30255
30256        Reviewed by Mihnea Ovidenie.
30257
30258        There's no point in hit-testing a box for a region if it's not contained inside
30259        that region.
30260
30261        Test: fast/regions/hit-test-box-non-containing-region.html
30262
30263        * rendering/RenderBox.cpp:
30264        (WebCore::RenderBox::nodeAtPoint):
30265
302662014-05-04  Andreas Kling  <akling@apple.com>
30267
30268        Optimize JSRopeString for resolving directly to AtomicString.
30269        <https://webkit.org/b/132548>
30270
30271        Add two bindings generator attributes for parameters to influence
30272        the way that JS rope strings are resolved:
30273
30274        - AtomicString
30275
30276            Generates code that avoids allocating a new StringImpl if there
30277            is already an existing AtomicString we can reuse.
30278
30279        - RequiresExistingAtomicString
30280
30281            Generates code that fails immediately if the provided string
30282            is not found in the AtomicString table. This is now used for
30283            document.getElementById(), and works because any existing ID
30284            is guaranteed to be in the table.
30285
30286        Reviewed by Filip Pizlo.
30287
30288        * bindings/scripts/CodeGeneratorJS.pm:
30289        (GenerateParametersCheck):
30290        (JSValueToNative):
30291        * bindings/scripts/IDLAttributes.txt:
30292        * dom/Document.idl:
30293
302942014-05-04  Simon Fraser  <simon.fraser@apple.com>
30295
30296        [iOS WK2] Compositing layers in iframes are misplaced
30297        https://bugs.webkit.org/show_bug.cgi?id=132554
30298        <rdar://problem/16203027>
30299
30300        Reviewed by Benjamin Poulain.
30301
30302        Have requiresScrollLayer() only consider frameView.delegatesScrolling()
30303        for the main frame, so that iframes get scroll layers (even though they
30304        will never scroll), so that the rest of geometry code works as on other
30305        platforms.
30306
30307        * rendering/RenderLayerCompositor.cpp:
30308        (WebCore::RenderLayerCompositor::requiresScrollLayer):
30309
303102014-05-04  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
30311
30312        Use std::unique_ptr in m_taskTimer of Notification class
30313        https://bugs.webkit.org/show_bug.cgi?id=132544
30314
30315        Reviewed by Andreas Kling.
30316
30317        No new tests, no behavior change.
30318
30319        * Modules/notifications/Notification.cpp:
30320        (WebCore::Notification::Notification):
30321        * Modules/notifications/Notification.h: Use std::unique_ptr instead of OwnPtr.
30322
303232014-05-04  Tim Horton  <timothy_horton@apple.com>
30324
30325        Long hangs under IOSurfacePool::evict
30326        https://bugs.webkit.org/show_bug.cgi?id=132549
30327        <rdar://problem/16769469>
30328
30329        Reviewed by Simon Fraser.
30330
30331        * platform/graphics/cg/IOSurfacePool.cpp:
30332        (WebCore::IOSurfacePool::willAddSurface):
30333        Run eviction before adding the new surface to m_bytesCached/m_inUseBytesCached.
30334        We use the additionalSize parameter to make space for the new surface.
30335
30336        (WebCore::IOSurfacePool::evict):
30337        If we want to free up the entire pool, we can do so by throwing away everything.
30338        This also avoids an underflow if additionalSize is larger than the maximum pool size.
30339
303402014-05-04  Pratik Solanki  <psolanki@apple.com>
30341
30342        Shortcircuit shouldUseCredentialStorage callback
30343        https://bugs.webkit.org/show_bug.cgi?id=132308
30344        <rdar://problem/16806708>
30345
30346        Reviewed by Alexey Proskuryakov.
30347
30348        If we are going to return true from the shouldUseCredentialStorage callback then we don't
30349        really need to have CFNetwork/Foundation call us. We can just disable the callback and
30350        CFNetwork will assume true. Add a separate subclass that implements this callback when we
30351        need to return false. We can also eliminate the corresponding async callbacks. This avoids
30352        pingponging between dispatch queue and main thread in the common case.
30353
30354        No new tests because no change in functionality.
30355
30356        * WebCore.exp.in:
30357        * platform/network/ResourceHandle.cpp:
30358        * platform/network/ResourceHandle.h:
30359        * platform/network/ResourceHandleClient.cpp:
30360        * platform/network/ResourceHandleClient.h:
30361        * platform/network/cf/ResourceHandleCFNet.cpp:
30362        (WebCore::ResourceHandle::createCFURLConnection):
30363        (WebCore::ResourceHandle::shouldUseCredentialStorage):
30364        * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h:
30365        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
30366        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::shouldUseCredentialStorage):
30367        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.h:
30368        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp:
30369        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h:
30370        * platform/network/mac/ResourceHandleMac.mm:
30371        (WebCore::ResourceHandle::start):
30372        (WebCore::ResourceHandle::makeDelegate):
30373        (WebCore::ResourceHandle::delegate):
30374        (WebCore::ResourceHandle::platformLoadResourceSynchronously):
30375        (WebCore::ResourceHandle::shouldUseCredentialStorage):
30376        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.h:
30377        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
30378        (-[WebCoreResourceHandleWithCredentialStorageAsOperationQueueDelegate connectionShouldUseCredentialStorage:]):
30379        * platform/network/soup/ResourceHandleSoup.cpp:
30380
303812014-05-04  Brent Fulgham  <bfulgham@apple.com>
30382
30383        [iOS] deviceScaleFactor is being double-applied when rendering captions in full screen mode 
30384        https://bugs.webkit.org/show_bug.cgi?id=132481
30385        <rdar://problem/16507482>
30386
30387        Reviewed by Jer Noble.
30388
30389        Add a new 'syncTextTrackBounds' method (and relaying functions) to keep the text track container in sync
30390        with changes to the video player's display layer.
30391
30392        * html/HTMLMediaElement.cpp:
30393        (WebCore::HTMLMediaElement::syncTextTrackBounds: Added.
30394        * html/HTMLMediaElement.h:
30395        * html/shadow/MediaControlElements.cpp:
30396        (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Don't set the platform scale factor here. It is already
30397        being accounted for in the createTextTrackRepresentationImage method.
30398        (WebCore::MediaControlTextTrackContainerElement::updateSizes): Synchronize the text track representation
30399        with any new video layer changes.
30400        * platform/graphics/MediaPlayer.cpp:
30401        (WebCore::MediaPlayer::syncTextTrackBounds): Added.
30402        * platform/graphics/MediaPlayer.h:
30403        * platform/graphics/MediaPlayerPrivate.h:
30404        (WebCore::MediaPlayerPrivateInterface::syncTextTrackBounds): Added.
30405        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
30406        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
30407        (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenLayer): Use new sync function.
30408        (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenFrame): Ditto.
30409        (WebCore::MediaPlayerPrivateAVFoundationObjC::syncTextTrackBounds): Added. Keep the text track layer size in sync with
30410        the current video layer size. This may change during animations, rotations, etc.
30411        (WebCore::MediaPlayerPrivateAVFoundationObjC::setTextTrackRepresentation): Use new sync function.
30412
304132014-05-04  Beth Dakin  <bdakin@apple.com>
30414
30415        Top content inset: Margin tiles should not display in the inset area when pinned 
30416        to the top of the page
30417        https://bugs.webkit.org/show_bug.cgi?id=132535
30418        -and corresponding-
30419        <rdar://problem/16613039>
30420
30421        Reviewed by Simon Fraser.
30422
30423        Prior to this change, topContentInset was implemented by positioning 
30424        RenderLayerCompositor’s m_rootContentLayer based on the inset value. In order to 
30425        ensure that no content is displayed in the inset area when we are pinned to the 
30426        top of the page, we’ll have to take a different approach. In this patch, when you 
30427        are pinned to the top of the page, the m_rootContentLayer is positioned at (0,0), 
30428        much like it would be without an inset, but the m_clip layer IS positioned at (0, 
30429        topContentInset). Then for all y-scroll values between 0 and topContentInset, the 
30430        positions of the clip layer and the contents layer are adjusted so that the clip 
30431        layer approaches a position of (0,0), and the root layer approaches a position of 
30432        (0, topContentInset). This makes sure that any content above the top the document 
30433        is aways clipped out of the inset area.
30434
30435        In order to achieve this, the scrolling thread needs to know about the 
30436        topContentInset, the clip layer, and the root contents layer.
30437
30438        AsyncScrollingCoordinator::updateScrollingNode() now takes an additional parameter 
30439        for the clip layer. Also export the topContentInset symbol for UI-side 
30440        compositing.
30441        * WebCore.exp.in:
30442
30443        Here is the new computation. Implemented in one spot that can be called from the 
30444        scrolling thread, AsyncScrollingCoordinator and RenderLayerCompositor.
30445        * page/FrameView.cpp:
30446        (WebCore::FrameView::yPositionForInsetClipLayer):
30447        (WebCore::FrameView::yPositionForRootContentLayer):
30448        * page/FrameView.h:
30449
30450        Set the topContentInset, the insetClipLayer, and the scrolledContentsLayer when 
30451        appropriate.
30452        * page/scrolling/AsyncScrollingCoordinator.cpp:
30453        (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
30454        (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
30455
30456        Set or sync the positions for the inset layer and the contents layer.
30457        (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
30458        (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
30459        * page/scrolling/AsyncScrollingCoordinator.h:
30460
30461        Convenience functions for getting the clipLayer() and the rootContentLayer() from 
30462        the RenderLayerCompositor.
30463        * page/scrolling/ScrollingCoordinator.cpp:
30464        (WebCore::ScrollingCoordinator::insetClipLayerForFrameView):
30465        (WebCore::ScrollingCoordinator::rootContentLayerForFrameView):
30466        * page/scrolling/ScrollingCoordinator.h:
30467        (WebCore::ScrollingCoordinator::updateScrollingNode):
30468
30469        ScrollingStateScrolling nodes have two new members now. m_insetClipLayer and 
30470        m_topContentInset. We can use m_scrolledContentsLayer for the rootContentsLayer 
30471        since previously that member was not used for FrameViews; it was only used for 
30472        accelerated overflow:scroll nodes.
30473        * page/scrolling/ScrollingStateScrollingNode.cpp:
30474        (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
30475        (WebCore::ScrollingStateScrollingNode::setTopContentInset):
30476        (WebCore::ScrollingStateScrollingNode::setInsetClipLayer):
30477        * page/scrolling/ScrollingStateScrollingNode.h:
30478
30479        Similarly, ScrollingTreeScrollingNode has two new members for m_topContentInset 
30480        and m_clipLayer.
30481        * page/scrolling/ScrollingTreeScrollingNode.cpp:
30482        (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
30483        (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
30484        * page/scrolling/ScrollingTreeScrollingNode.h:
30485        (WebCore::ScrollingTreeScrollingNode::topContentInset):
30486        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
30487        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
30488        (WebCore::ScrollingTreeScrollingNodeMac::updateBeforeChildren):
30489
30490        Compute positions for the two new layers.
30491        (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
30492
30493        Now use the static FrameView functions to compute the positions for these layers.
30494        * rendering/RenderLayerCompositor.cpp:
30495        (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
30496        (WebCore::RenderLayerCompositor::positionForClipLayer):
30497        (WebCore::RenderLayerCompositor::clipLayer):
30498        (WebCore::RenderLayerCompositor::rootContentLayer):
30499        (WebCore::RenderLayerCompositor::updateRootLayerPosition):
30500        (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
30501        (WebCore::RenderLayerCompositor::ensureRootLayer):
30502        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
30503        * rendering/RenderLayerCompositor.h:
30504
305052014-05-04  Benjamin Poulain  <benjamin@webkit.org>
30506
30507        Clear the Selector Query caches on memory pressure
30508        https://bugs.webkit.org/show_bug.cgi?id=132545
30509
30510        Reviewed by Andreas Kling.
30511
30512        The Selector Query Cache can use quite a bit of memory if many
30513        complex selectors are compiled. This patch makes sure the cache gets
30514        cleared on memory pressure.
30515
30516        * dom/Document.cpp:
30517        (WebCore::Document::clearSelectorQueryCache):
30518        (WebCore::Document::setCompatibilityMode):
30519        (WebCore::Document::updateBaseURL):
30520        * dom/Document.h:
30521        * dom/SelectorQuery.cpp:
30522        (WebCore::SelectorQueryCache::invalidate): Deleted.
30523        * dom/SelectorQuery.h:
30524        * platform/MemoryPressureHandler.cpp:
30525        (WebCore::MemoryPressureHandler::releaseMemory):
30526
305272014-05-04  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
30528
30529        Convert OwnPtr to std::unique_ptr in CDM
30530        https://bugs.webkit.org/show_bug.cgi?id=132467
30531
30532        Reviewed by Andreas Kling.
30533
30534        Use std::unique_ptr in CDM class.
30535
30536        No new tests, no behavior change.
30537
30538        * Modules/encryptedmedia/CDM.cpp:
30539        (WebCore::CDM::create):
30540        (WebCore::CDM::CDM):
30541        * Modules/encryptedmedia/CDM.h:
30542        * Modules/encryptedmedia/CDMPrivateMediaPlayer.h:
30543        (WebCore::CDMPrivateMediaPlayer::CDMPrivateMediaPlayer):
30544        (WebCore::CDMPrivateMediaPlayer::create):
30545        * Modules/encryptedmedia/MediaKeys.cpp:
30546        (WebCore::MediaKeys::create):
30547        (WebCore::MediaKeys::MediaKeys):
30548        * Modules/encryptedmedia/MediaKeys.h:
30549        * WebCore.exp.in:
30550
305512014-05-03  Commit Queue  <commit-queue@webkit.org>
30552
30553        Unreviewed, rolling out r168232.
30554        https://bugs.webkit.org/show_bug.cgi?id=132543
30555
30556        broke ~15 tests on WK2 debug (Requested by kling on #webkit).
30557
30558        Reverted changeset:
30559
30560        "Shortcircuit shouldUseCredentialStorage callback"
30561        https://bugs.webkit.org/show_bug.cgi?id=132308
30562        http://trac.webkit.org/changeset/168232
30563
305642014-05-03  Andreas Kling  <akling@apple.com>
30565
30566        RenderSVGResourcePattern should deal in RenderElement&.
30567        <https://webkit.org/b/132536>
30568
30569        Tweak buildPattern() and buildTileImageTransform() to take RenderElement&
30570        instead of RenderObject* since we know that these functions will always
30571        be called with non-null RenderElement subclasses.
30572
30573        Reviewed by Sam Weinig.
30574
30575        * rendering/svg/RenderSVGResourceContainer.cpp:
30576        (WebCore::RenderSVGResourceContainer::shouldTransformOnTextPainting):
30577        * rendering/svg/RenderSVGResourceContainer.h:
30578        * rendering/svg/RenderSVGResourceGradient.cpp:
30579        (WebCore::RenderSVGResourceGradient::applyResource):
30580        * rendering/svg/RenderSVGResourcePattern.cpp:
30581        (WebCore::RenderSVGResourcePattern::buildPattern):
30582        (WebCore::RenderSVGResourcePattern::applyResource):
30583        (WebCore::RenderSVGResourcePattern::buildTileImageTransform):
30584        * rendering/svg/RenderSVGResourcePattern.h:
30585
305862014-05-03  Yusuke Suzuki  <utatane.tea@gmail.com>
30587
30588        CSS JIT: optimize direct / indirect adjacent's traversal backtracking
30589        https://bugs.webkit.org/show_bug.cgi?id=132319
30590
30591        Reviewed by Benjamin Poulain.
30592
30593        Since adjacent backtracking stack reference is pre-allocated
30594        in prologue in http://trac.webkit.org/changeset/166834,
30595        clearing stack phase is not needed. So we can drop
30596        JumpToClearAdjacentTail from backtracking action and simplify
30597        backtracking handling.
30598        And optimize direct / indirect adjacent's traversal backtracking by
30599        using appropriate backtracking height.
30600
30601        When solving adjacent traversal backtracking action,
30602        1) When there's no descendant relation on the right, traversal
30603        failure becomes global failure.
30604        2) When `tagNameMatchedBacktrackingStartHeightFromDescendant` ==
30605        `heightFromDescendant` + 1, the descendant backtracking starts with
30606        the parent of the current element. So we can use the current element
30607        and the backtracking action is JumpToDescendantTreeWalkerEntryPoint.
30608        3) Otherwise, currently we take the conservative approach,
30609        JumpToDescendantTail.
30610
30611        NOTE:
30612        And if `hasDescendantRelationOnTheRight` is true and there's no child
30613        fragment on the right, the backtracking element register is not
30614        effective. So we should ensure that fragment doesn't use the
30615        backtracking element register. Such a fragment fulfills the following
30616        conditions. 1. tagNameMatchedBacktrackingStartHeightFromDescendant is
30617        always 1 (tagNames.size(), that contains only descendant fragment) 2.
30618        heightFromDescendant is always 0 (-- See
30619        computeBacktrackingHeightFromDescendant implementation) Therefore such
30620        a fragment's action always becomes
30621        JumpToDescendantTreeWalkerEntryPoint. So we can ensure that the
30622        backtracking element register is not used.
30623
30624        Test: fast/selectors/backtracking-adjacent.html
30625
30626        * cssjit/SelectorCompiler.cpp:
30627        (WebCore::SelectorCompiler::solveDescendantBacktrackingActionForChild):
30628        (WebCore::SelectorCompiler::solveAdjacentTraversalBacktrackingAction):
30629        (WebCore::SelectorCompiler::solveBacktrackingAction):
30630        (WebCore::SelectorCompiler::SelectorCodeGenerator::computeBacktrackingInformation):
30631        (WebCore::SelectorCompiler::SelectorCodeGenerator::linkFailures):
30632        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAdjacentBacktrackingTail):
30633        (WebCore::SelectorCompiler::isAfterChildRelation): Deleted.
30634
306352014-05-03  Andreas Kling  <akling@apple.com>
30636
30637        Clear the JSString cache when under memory pressure.
30638        <https://webkit.org/b/132539>
30639
30640        The WeakGCMap used for fast mapping from StringImpl* to JSString*
30641        can actually get pretty big, and if we find ourselves under memory
30642        pressure, it's entirely inessential.
30643
30644        1.1 MB progression on Membuster3.
30645
30646        Reviewed by Sam Weinig.
30647
30648        * platform/MemoryPressureHandler.cpp:
30649        (WebCore::MemoryPressureHandler::releaseMemory):
30650
306512014-05-03  Benjamin Poulain  <benjamin@webkit.org>
30652
30653        [iOS][WK2] Support disabling speculative tiling
30654        https://bugs.webkit.org/show_bug.cgi?id=132512
30655
30656        Reviewed by Tim Horton.
30657
30658        Move ScrollView::setScrollVelocity() and ScrollView::computeCoverageRect() to FrameView.
30659        When speculative tiling is disabled, return an unmodified exposed rect.
30660
30661        Time/velocity adjusments are completely unnecessary at the moment since speculative tiling
30662        is enabled as soon as the view scrolls.
30663
30664        * WebCore.exp.in:
30665        * page/FrameView.cpp:
30666        (WebCore::FrameView::setScrollVelocity):
30667        (WebCore::FrameView::computeCoverageRect):
30668        * page/FrameView.h:
30669        * platform/ScrollView.h:
30670        * platform/ios/ScrollViewIOS.mm:
30671        (WebCore::ScrollView::setScrollVelocity): Deleted.
30672        (WebCore::ScrollView::computeCoverageRect): Deleted.
30673
306742014-05-02  Pratik Solanki  <psolanki@apple.com>
30675
30676        Shortcircuit shouldUseCredentialStorage callback
30677        https://bugs.webkit.org/show_bug.cgi?id=132308
30678        <rdar://problem/16806708>
30679
30680        Reviewed by Alexey Proskuryakov.
30681
30682        If we are going to return true from the shouldUseCredentialStorage callback then we don't
30683        really need to have CFNetwork/Foundation call us. We can just disable the callback and
30684        CFNetwork will assume true. Add a separate subclass that implements this callback when we
30685        need to return false. We can also eliminate the corresponding async callbacks. This avoids
30686        pingponging between dispatch queue and main thread in the common case.
30687
30688        No new tests because no change in functionality.
30689
30690        * WebCore.exp.in:
30691        * platform/network/ResourceHandle.cpp:
30692        * platform/network/ResourceHandle.h:
30693        * platform/network/ResourceHandleClient.cpp:
30694        * platform/network/ResourceHandleClient.h:
30695        * platform/network/cf/ResourceHandleCFNet.cpp:
30696        (WebCore::ResourceHandle::createCFURLConnection):
30697        (WebCore::ResourceHandle::shouldUseCredentialStorage):
30698        * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h:
30699        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
30700        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::shouldUseCredentialStorage):
30701        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.h:
30702        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp:
30703        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h:
30704        * platform/network/mac/ResourceHandleMac.mm:
30705        (WebCore::ResourceHandle::start):
30706        (WebCore::ResourceHandle::makeDelegate):
30707        (WebCore::ResourceHandle::delegate):
30708        (WebCore::ResourceHandle::platformLoadResourceSynchronously):
30709        (WebCore::ResourceHandle::shouldUseCredentialStorage):
30710        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.h:
30711        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
30712        (-[WebCoreResourceHandleWithCredentialStorageAsOperationQueueDelegate connectionShouldUseCredentialStorage:]):
30713        * platform/network/soup/ResourceHandleSoup.cpp:
30714
307152014-05-03  Andreas Kling  <akling@apple.com>
30716
30717        Invalidate scrollbars when custom scrollbar style changes dynamically.
30718        <https://webkit.org/b/132529>
30719
30720        Add a ScrollView::styleDidChange() and call that from RenderView::styleDidChange()
30721        so that the scrollbars are sure to get repainted with potentially different style.
30722
30723        Reviewed by Antti Koivisto.
30724
30725        Test: fast/css/scrollbar-dynamic-style-change.html
30726
30727        * platform/ScrollView.cpp:
30728        (WebCore::ScrollView::styleDidChange):
30729        * platform/ScrollView.h:
30730        * rendering/RenderView.cpp:
30731        (WebCore::RenderView::styleDidChange):
30732
307332014-05-03  Simon Fraser  <simon.fraser@apple.com>
30734
30735        Very fuzzy layers under non-decompasable matrices
30736        https://bugs.webkit.org/show_bug.cgi?id=132516
30737        <rdar://problem/16717478>
30738
30739        Reviewed by Sam Weinig.
30740        
30741        r155977 added code to modify layer contentsScale based on a root-relative
30742        scale, so that scaled-up layers remained sharp. It does this by decomposing
30743        an accumulated matrix, but failed to test whether the decomposition
30744        succeeded. This would result in contentsScale of 0, which is clamped to 0.1,
30745        resulting in very fuzzy layers.
30746        
30747        Fix by testing for success of decomposition.
30748
30749        Test: compositing/contents-scale/non-decomposable-matrix.html
30750
30751        * platform/graphics/ca/GraphicsLayerCA.cpp:
30752        (WebCore::maxScaleFromTransform):
30753        * platform/graphics/transforms/TransformationMatrix.cpp:
30754        (WebCore::TransformationMatrix::decompose2): Return early for identity matrices,
30755        with fix for m11 and m22.
30756        (WebCore::TransformationMatrix::decompose4): Return early for identity matrices.
30757        * platform/graphics/transforms/TransformationMatrix.h:
30758        Make Decomposed2Type and Decomposed4Type into C++ structs.
30759        (WebCore::TransformationMatrix::Decomposed2Type::operator==): Added to make it easier
30760        to write code that asserts that decomposition is correct.
30761        (WebCore::TransformationMatrix::Decomposed4Type::operator==): Ditto.
30762
307632014-05-03  Simon Fraser  <simon.fraser@apple.com>
30764
30765        Fix crash in WebKit client app when zooming
30766        https://bugs.webkit.org/show_bug.cgi?id=132475
30767        <rdar://problem/16703405>
30768
30769        Reviewed by Tim Horton.
30770
30771        It's possible for a WebTiledBackingLayer CALayer to remain in the CALayer
30772        hierarchy after we've called -invalidate on it, which clears the _tileController.
30773        Project the getters against null derefs to handle this.
30774
30775        * platform/graphics/ca/mac/WebTiledBackingLayer.mm:
30776        (-[WebTiledBackingLayer isOpaque]):
30777        (-[WebTiledBackingLayer acceleratesDrawing]):
30778        (-[WebTiledBackingLayer contentsScale]):
30779
307802014-05-03  Carlos Garcia Campos  <cgarcia@igalia.com>
30781
30782        Unreviewed. Fix GTK+ build after r168209.
30783
30784        * platform/leveldb/LevelDBDatabase.cpp:
30785        (WebCore::LevelDBDatabase::write):
30786
307872014-05-03  Zalan Bujtas  <zalan@apple.com>
30788
30789        Subpixel rendering: Fieldset legend has a horizontal line through, when the fieldset is painted on odd device pixel position.
30790        https://bugs.webkit.org/show_bug.cgi?id=132521
30791        <rdar://problem/16803305>
30792
30793        Reviewed by Simon Fraser.
30794
30795        Use device pixel snapping when the fieldset's border gets clipped out for the legend's text. It ensures that
30796        the device pixel snapped border gets properly clipped out.
30797
30798        Existing fieldset tests cover it.
30799
30800        * rendering/RenderFieldset.cpp:
30801        (WebCore::RenderFieldset::paintBoxDecorations):
30802
308032014-05-02  Zalan Bujtas  <zalan@apple.com>
30804
30805        CodeCleanup: Remove *MaintainsPixelAlignment from GraphicsLayer*.
30806        https://bugs.webkit.org/show_bug.cgi?id=132501
30807
30808        Reviewed by Simon Fraser.
30809
30810        * WebCore.exp.in:
30811        * platform/graphics/GraphicsLayer.cpp:
30812        (WebCore::GraphicsLayer::GraphicsLayer):
30813        * platform/graphics/GraphicsLayer.h:
30814        (WebCore::GraphicsLayer::setMaintainsPixelAlignment): Deleted.
30815        (WebCore::GraphicsLayer::maintainsPixelAlignment): Deleted.
30816        (WebCore::GraphicsLayer::pixelAlignmentOffset): Deleted.
30817        * platform/graphics/ca/GraphicsLayerCA.cpp:
30818        (WebCore::GraphicsLayerCA::updateGeometry):
30819        (WebCore::GraphicsLayerCA::computePixelAlignment):
30820        (WebCore::GraphicsLayerCA::setMaintainsPixelAlignment): Deleted.
30821        * platform/graphics/ca/GraphicsLayerCA.h:
30822        * rendering/RenderLayerBacking.cpp:
30823        (WebCore::RenderLayerBacking::createGraphicsLayer):
30824        * rendering/RenderLayerCompositor.cpp:
30825        (WebCore::RenderLayerCompositor::keepLayersPixelAligned): Deleted.
30826        * rendering/RenderLayerCompositor.h:
30827
308282014-05-02  Simon Fraser  <simon.fraser@apple.com>
30829
30830        [iOS WK2] Tiled layer content missing on pages with animated tiled layers
30831        https://bugs.webkit.org/show_bug.cgi?id=132507
30832        <rdar://problem/16765740>
30833
30834        Reviewed by Tim Horton.
30835
30836        Updating the tiling area of content TileControllers while
30837        CSS animations are running depends on GraphicsLayerUpdater
30838        triggering repeated layer flushes. With UI-side compositing, those
30839        flushes were happening, but nothing triggered RemoteLayerTreeDrawingArea
30840        to flush changes to the UI process.
30841        
30842        Fix by having RenderLayerCompositor schedule a flush, rather
30843        than just doing a flush, in response to GraphicsLayerUpdater.
30844        
30845        Also change the name of the GraphicsLayerUpdaterClient function
30846        to indicate that it suggests that a flush is required soon, rather than
30847        that the flushing has to be synchronous.
30848
30849        * platform/graphics/GraphicsLayerUpdater.cpp:
30850        (WebCore::GraphicsLayerUpdater::displayRefreshFired):
30851        * platform/graphics/GraphicsLayerUpdater.h:
30852        * rendering/RenderLayerCompositor.cpp:
30853        (WebCore::RenderLayerCompositor::flushLayersSoon):
30854        (WebCore::RenderLayerCompositor::flushLayers): Deleted.
30855        * rendering/RenderLayerCompositor.h:
30856
308572014-05-02  Jeremy Jones  <jeremyj@apple.com>
30858
30859        Use displayNameForTrack instead of textTrack->label() for captions.
30860        https://bugs.webkit.org/show_bug.cgi?id=131311
30861
30862        Reviewed by Darin Adler.
30863
30864        Use the same mechanism as the desktop to build the captions list so it has the correct
30865        names in the correct order including none and automatic.
30866
30867        * platform/ios/WebVideoFullscreenModelMediaElement.h:
30868        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
30869        (WebVideoFullscreenModelMediaElement::setMediaElement):
30870        move legible track code into updateLegibleOptions()
30871
30872        (WebVideoFullscreenModelMediaElement::handleEvent):
30873        updateLegibleOptions on addTrack and removeTrack
30874
30875        (WebVideoFullscreenModelMediaElement::selectLegibleMediaOption):
30876        select the corresponding TextTrack on HTMLMediaElement.
30877
30878        (WebVideoFullscreenModelMediaElement::updateLegibleOptions):
30879        use the same mechanism as desktop to build the captions menu.
30880
308812014-05-02  Jeremy Jones  <jeremyj@apple.com>
30882
30883        CSS-based Media Controls Show Different times content longer than 1 hour.
30884        https://bugs.webkit.org/show_bug.cgi?id=132443
30885
30886        Reviewed by Jer Noble.
30887
30888        * Modules/mediacontrols/mediaControlsApple.css:
30889        (audio::-webkit-media-controls-timeline-container .hour-long-time):
30890        This class has a wider width for longer duration times.
30891
30892        * Modules/mediacontrols/mediaControlsApple.js:
30893        (Controller.prototype.updateDuration):
30894        Apply .hour-long-time class as appropriate.
30895
30896        (Controller.prototype.formatTime):
30897        More robust formatting to handle hours.
30898
30899        * Modules/mediacontrols/mediaControlsiOS.css:
30900        (audio::-webkit-media-controls-timeline-container .hour-long-time):
30901        This class has a wider width for longer duration times.
30902
30903        * Modules/mediacontrols/mediaControlsiOS.js:
30904        (ControllerIOS.prototype.formatTime):
30905        More robust formatting to handle hours.
30906
309072014-05-02  Jer Noble  <jer.noble@apple.com>
30908
30909        [MSE][Mac] AVAssetTrack returns incorrect track size
30910        https://bugs.webkit.org/show_bug.cgi?id=132469
30911
30912        Reviewed by Brent Fulgham.
30913
30914        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
30915        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
30916        (WebCore::SourceBufferPrivateAVFObjC::didParseStreamDataAsAsset):  Remove the sizeChanged() notification.
30917        (WebCore::SourceBufferPrivateAVFObjC::processCodedFrame): Cache the last parsed video frame size.
30918        (WebCore::SourceBufferPrivateAVFObjC::naturalSize): Return the cached value.
30919
309202014-05-02  Zalan Bujtas  <zalan@apple.com>
30921
30922        Subpixel rendering[iOS]: Use pixelSnappedRoundedRectForPainting() to clip text area rect.
30923        https://bugs.webkit.org/show_bug.cgi?id=132499
30924        <rdar://problem/16631050>
30925
30926        Reviewed by Simon Fraser.
30927
30928        Snap to device pixels properly instead of relying on float arithmetics while converting from RoundedRect
30929        to FloatRoundedRect. This is the second, cleanup part of the text-area decoration is off-by-one painting issue.
30930
30931        Currently not testable.
30932
30933        * rendering/RenderThemeIOS.mm:
30934        (WebCore::RenderThemeIOS::paintTextFieldDecorations):
30935
309362014-05-02  Andreas Kling  <akling@apple.com>
30937
30938        Remove HistogramSupport.
30939        <https://webkit.org/b/132354>
30940
30941        Prune some leftover Chromium gunk that no other ports ever used.
30942
30943        Reviewed by Simon Fraser.
30944
30945        * CMakeLists.txt:
30946        * Modules/indexeddb/IDBDatabase.cpp:
30947        (WebCore::IDBDatabase::createObjectStore):
30948        (WebCore::IDBDatabase::deleteObjectStore):
30949        (WebCore::IDBDatabase::transaction):
30950        * Modules/indexeddb/IDBFactory.cpp:
30951        (WebCore::IDBFactory::openInternal):
30952        (WebCore::IDBFactory::deleteDatabase):
30953        * Modules/indexeddb/IDBHistograms.h: Removed.
30954        * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp:
30955        (WebCore::IDBBackingStoreLevelDB::open):
30956        (WebCore::IDBBackingStoreLevelDB::openInMemory):
30957        (WebCore::recordInternalError): Deleted.
30958        * Modules/indexeddb/leveldb/IDBBackingStoreTransactionLevelDB.cpp:
30959        * WebCore.vcxproj/WebCore.vcxproj:
30960        * WebCore.vcxproj/WebCore.vcxproj.filters:
30961        * WebCore.xcodeproj/project.pbxproj:
30962        * css/CSSParser.cpp:
30963        (WebCore::cssPropertyID):
30964        * dom/Document.cpp:
30965        (WebCore::Document::~Document):
30966        (WebCore::histogramMutationEventUsage): Deleted.
30967        * dom/ShadowRoot.cpp:
30968        * fileapi/Blob.cpp:
30969        * fileapi/WebKitBlobBuilder.cpp:
30970        (WebCore::BlobBuilder::append):
30971        * history/PageCache.cpp:
30972        (WebCore::logCanCacheFrameDecision):
30973        (WebCore::logCanCachePageDecision):
30974        * platform/HistogramSupport.cpp: Removed.
30975        * platform/HistogramSupport.h: Removed.
30976        * platform/leveldb/LevelDBDatabase.cpp:
30977        (WebCore::LevelDBDatabase::open):
30978        (WebCore::histogramLevelDBError): Deleted.
30979        * rendering/RenderLayer.cpp:
30980        (WebCore::RenderLayer::updateNeedsCompositedScrolling):
30981        * xml/XMLHttpRequest.cpp:
30982        (WebCore::XMLHttpRequest::send):
30983
309842014-05-02  Brady Eidson  <beidson@apple.com>
30985
30986        Stop flipping the ImageControlsButton
30987        <rdar://problem/16773238> and https://bugs.webkit.org/show_bug.cgi?id=132502
30988
30989        Reviewed by Tim Horton.
30990
30991        * rendering/RenderThemeMac.mm:
30992        (WebCore::RenderThemeMac::paintImageControlsButton):
30993
309942014-05-02  Jeremy Jones  <jeremyj@apple.com>
30995
30996        Fullscreen UI does not appear after WebProcess has crashed
30997        https://bugs.webkit.org/show_bug.cgi?id=132442
30998
30999        Reviewed by Darin Adler.
31000
31001        Clean up immediately when there is a WebProcess crash.
31002
31003        * WebCore.exp.in:
31004        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
31005        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
31006        (WebVideoFullscreenInterfaceAVKit::invalidate):
31007        Clean-up resources immediately.
31008
310092014-05-02  Commit Queue  <commit-queue@webkit.org>
31010
31011        Unreviewed, rolling out r168192.
31012        https://bugs.webkit.org/show_bug.cgi?id=132498
31013
31014        Was not the correct fix (blurry!) (Requested by bfulgham_ on
31015        #webkit).
31016
31017        Reverted changeset:
31018
31019        "[iOS] deviceScaleFactor is being double-applied when
31020        rendering captions in full screen mode"
31021        https://bugs.webkit.org/show_bug.cgi?id=132481
31022        http://trac.webkit.org/changeset/168192
31023
310242014-05-02  Alexey Proskuryakov  <ap@apple.com>
31025
31026        Remove Blob contentDisposition handling
31027        https://bugs.webkit.org/show_bug.cgi?id=132490
31028
31029        Reviewed by Sam Weinig.
31030
31031        Dead code.
31032
31033        * platform/network/BlobData.h:
31034        (WebCore::BlobData::contentDisposition): Deleted.
31035        (WebCore::BlobData::setContentDisposition): Deleted.
31036        * platform/network/BlobRegistryImpl.cpp:
31037        (WebCore::BlobRegistryImpl::registerBlobURL):
31038        (WebCore::BlobRegistryImpl::registerBlobURLForSlice):
31039        * platform/network/BlobResourceHandle.cpp:
31040        (WebCore::BlobResourceHandle::notifyResponseOnSuccess):
31041        * platform/network/BlobStorageData.h:
31042        (WebCore::BlobStorageData::create):
31043        (WebCore::BlobStorageData::contentType):
31044        (WebCore::BlobStorageData::BlobStorageData):
31045        (WebCore::BlobStorageData::contentDisposition): Deleted.
31046
310472014-05-02  Anders Carlsson  <andersca@apple.com>
31048
31049        Implement FormData decoding using KeyedDecoder
31050        https://bugs.webkit.org/show_bug.cgi?id=132494
31051
31052        Reviewed by Tim Horton.
31053
31054        * platform/KeyedCoding.h:
31055        (WebCore::KeyedDecoder::decodeEnum):
31056        * platform/network/FormData.cpp:
31057        (WebCore::decodeElement):
31058        (WebCore::FormData::decode):
31059        * platform/network/FormData.h:
31060
310612014-05-02  Brent Fulgham  <bfulgham@apple.com>
31062
31063        [iOS] deviceScaleFactor is being double-applied when rendering captions in full screen mode
31064        https://bugs.webkit.org/show_bug.cgi?id=132481
31065
31066        Reviewed by Jer Noble.
31067
31068        * html/shadow/MediaControlElements.cpp:
31069        (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Don't set the platform scale factor here. It is already
31070        being accounted for in the createTextTrackRepresentationImage method.
31071
310722014-05-02  Simon Fraser  <simon.fraser@apple.com>
31073
31074        [iOS WK2] Don't create backing store for -webkit-overflow-scrolling:touch that can't scroll
31075        https://bugs.webkit.org/show_bug.cgi?id=132487
31076        <rdar://problem/16758041>
31077
31078        Reviewed by Sam Weinig.
31079
31080        Previously, -webkit-overflow-scrolling:touch would cause us to make compositing
31081        layers for any element that had overflow: auto or scroll on either axis. This
31082        created lots of backing store when not required.
31083        
31084        Improve this to only create compositing for scrolling when there is actually
31085        scrollable overflow. This makes things slightly more complex, because we can
31086        only know when layout is up to date.
31087
31088        * rendering/RenderBox.cpp:
31089        (WebCore::RenderBox::computeRectForRepaint): usesCompositedScrolling() tells
31090        us if we're actually doing composited overflow.
31091        * rendering/RenderLayer.cpp:
31092        (WebCore::RenderLayer::hasTouchScrollableOverflow):
31093        (WebCore::RenderLayer::handleTouchEvent):
31094        * rendering/RenderLayer.h:
31095        * rendering/RenderLayerBacking.cpp:
31096        (WebCore::layerOrAncestorIsTransformedOrUsingCompositedScrolling):
31097        (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration): Only update
31098        scrolling and clipping layers if layout is not pending.
31099        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
31100        (WebCore::RenderLayerBacking::updateScrollingLayers): The caller calls
31101        updateInternalHierarchy(), so no need to do it here.
31102        * rendering/RenderLayerCompositor.cpp:
31103        (WebCore::RenderLayerCompositor::requiresCompositingForScrolling): We
31104        can only determine that we're scrollable after layout.
31105        (WebCore::isStickyInAcceleratedScrollingLayerOrViewport):
31106        (WebCore::isMainFrameScrollingOrOverflowScrolling):
31107
311082014-05-02  Anders Carlsson  <andersca@apple.com>
31109
31110        Clean up FormDataElement
31111        https://bugs.webkit.org/show_bug.cgi?id=132483
31112
31113        Reviewed by Sam Weinig.
31114
31115        * platform/network/FormData.cpp:
31116        (WebCore::FormData::FormData):
31117        (WebCore::FormData::deepCopy):
31118        (WebCore::FormData::expandDataStore):
31119        (WebCore::FormData::flatten):
31120        (WebCore::FormData::resolveBlobReferences):
31121        (WebCore::FormData::generateFiles):
31122        (WebCore::FormData::hasGeneratedFiles):
31123        (WebCore::FormData::hasOwnedGeneratedFiles):
31124        (WebCore::FormData::removeGeneratedFilesIfNeeded):
31125        (WebCore::encodeElement):
31126        (WebCore::decodeElement):
31127        * platform/network/FormData.h:
31128        (WebCore::FormDataElement::FormDataElement):
31129        (WebCore::operator==):
31130        * platform/network/cf/FormDataStreamCFNet.cpp:
31131        (WebCore::advanceCurrentStream):
31132        (WebCore::setHTTPBody):
31133        * platform/network/curl/FormDataStreamCurl.cpp:
31134        (WebCore::FormDataStream::read):
31135        * platform/network/curl/ResourceHandleManager.cpp:
31136        (WebCore::setupFormData):
31137        * platform/network/soup/ResourceHandleSoup.cpp:
31138        (WebCore::addFormElementsToSoupMessage):
31139
311402014-05-02  Jer Noble  <jer.noble@apple.com>
31141
31142        [iOS] Wireless playback button not blue when active
31143        https://bugs.webkit.org/show_bug.cgi?id=132473
31144
31145        Reviewed by Simon Fraser.
31146
31147        The playback button's class was being set to 'undefined', due to Controller.ClassNames.active being undefined.
31148
31149        * Modules/mediacontrols/mediaControlsApple.js:
31150
311512014-05-02  Alexey Proskuryakov  <ap@apple.com>
31152
31153        Don't abuse Blob deserialization constructor in WebSocket
31154        https://bugs.webkit.org/show_bug.cgi?id=132478
31155
31156        Reviewed by Sam Weinig.
31157
31158        * Modules/websockets/WebSocketChannel.cpp:
31159        (WebCore::WebSocketChannel::send):
31160        (WebCore::WebSocketChannel::enqueueBlobFrame): This is the important change -
31161        Blob::create was called for no reason. If the blob came from a worker, it was
31162        already cloned for cross-thread messaging, otherwise there is no reason to make
31163        a new one.
31164
31165        * fileapi/Blob.h:
31166        (WebCore::Blob::deserialize):
31167        (WebCore::Blob::create): Deleted.
31168        * fileapi/File.h:
31169        (WebCore::File::deserialize):
31170        (WebCore::File::create): Deleted.
31171        Renamed a special case of "create" function to avoid explaining what it is for.
31172
31173        * Modules/websockets/ThreadableWebSocketChannel.h:
31174        * Modules/websockets/WebSocket.cpp:
31175        (WebCore::WebSocket::send):
31176        * Modules/websockets/WebSocketChannel.h:
31177        * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
31178        (WebCore::WorkerThreadableWebSocketChannel::send): Print a full URL in LOG(),
31179        not one shortened to 1024 characters.
31180        (WebCore::WorkerThreadableWebSocketChannel::Peer::send):
31181        (WebCore::WorkerThreadableWebSocketChannel::mainThreadSendBlob):
31182        (WebCore::WorkerThreadableWebSocketChannel::Bridge::send):
31183        * Modules/websockets/WorkerThreadableWebSocketChannel.h:
31184        * bindings/js/SerializedScriptValue.cpp:
31185        (WebCore::CloneDeserializer::readFile):
31186        (WebCore::CloneDeserializer::readTerminal):
31187
311882014-05-02  Anders Carlsson  <andersca@apple.com>
31189
31190        Add and implement KeyedDecoder::decodeBytes
31191        https://bugs.webkit.org/show_bug.cgi?id=132479
31192
31193        Reviewed by Tim Horton.
31194
31195        * platform/KeyedCoding.h:
31196        (WebCore::KeyedDecoder::decodeBytes):
31197
311982014-05-02  Joseph Pecoraro  <pecoraro@apple.com>
31199
31200        [iOS] WebKit2 File Upload Support
31201        https://bugs.webkit.org/show_bug.cgi?id=132024
31202
31203        Reviewed by Enrica Casucci.
31204
31205        * English.lproj/Localizable.strings:
31206        New localized strings for <input type="file"> on iOS.
31207
312082014-05-02  Chris Fleizach  <cfleizach@apple.com>
31209
31210        AX: WK2: iOS web page scrolling doesn't work with VoiceOver
31211        https://bugs.webkit.org/show_bug.cgi?id=132028
31212
31213        Reviewed by Mario Sanchez Prada.
31214
31215        With the AX tree residing in the WebProcess, scrolling needs to be implemented in
31216        WebCore using accessibilityScroll: in order for accessibility clients to scroll through the AX API.
31217
31218        * accessibility/AccessibilityObject.cpp:
31219        (WebCore::AccessibilityObject::scrollViewAncestor):
31220        (WebCore::AccessibilityObject::scrollToMakeVisibleWithSubFocus):
31221        * accessibility/AccessibilityObject.h:
31222        * accessibility/ios/WebAccessibilityObjectWrapperIOS.h:
31223        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
31224        (-[WebAccessibilityObjectWrapper _accessibilityConvertPointToViewSpace:]):
31225        (-[WebAccessibilityObjectWrapper _accessibilityScrollToVisible]):
31226        (-[WebAccessibilityObjectWrapper accessibilityScroll:]):
31227        (-[WebAccessibilityObjectWrapper postScrollStatusChangeNotification]):
31228        (-[WebAccessibilityObjectWrapper _accessibilityScrollPosition]):
31229        (-[WebAccessibilityObjectWrapper _accessibilityScrollSize]):
31230        (-[WebAccessibilityObjectWrapper _accessibilityScrollVisibleRect]):
31231
312322014-05-02  Jeremy Jones  <jeremyj@apple.com>
31233
31234        Pause playback on exit fullscreen when inline playback not allowed.
31235        https://bugs.webkit.org/show_bug.cgi?id=132450
31236
31237        Reviewed by Jer Noble.
31238
31239        Use correct method of determining if inline playback is allowed.
31240
31241        * html/HTMLMediaElement.cpp:
31242        (WebCore::HTMLMediaElement::parseAttribute):
31243        Use m_mediaSession->requiresFullscreenForVideoPlayback to detect if inline playback is allowed.
31244
31245        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
31246        (WebVideoFullscreenModelMediaElement::requestExitFullscreen):
31247        Prevent duplicate exit requests.
31248
312492014-05-02  Ion Rosca  <rosca@adobe.com>
31250
31251        [CSS Blending] Remove support for non-separable blend modes from background-blend-mode
31252        https://bugs.webkit.org/show_bug.cgi?id=132327
31253
31254        Reviewed by Dean Jackson.
31255
31256        Removed support for non-separable background blend modes from the CSS parser.
31257        Covered by existing tests.
31258
31259        * css/CSSParser.cpp:
31260        (WebCore::CSSParser::parseFillProperty):
31261
312622014-05-02  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
31263
31264        Clean up #include <OwnPtr.h>|<PassOwnPtr.h> in Supplementable classes
31265        https://bugs.webkit.org/show_bug.cgi?id=132466
31266
31267        Reviewed by Tim Horton.
31268
31269        Since r168144, Supplementable classes don't need to include OwnPtr.h or PassOwnPtr.h.
31270        Clean up those inclusions.
31271
31272        No new tests, just clean up patch.
31273
31274        * Modules/encryptedmedia/CDMPrivate.h:
31275        * Modules/gamepad/NavigatorGamepad.cpp:
31276        * Modules/geolocation/GeolocationController.cpp:
31277        (WebCore::GeolocationController::create): Deleted. Don't need to have a factory function.
31278        * Modules/geolocation/GeolocationController.h:
31279        * Modules/mediasource/MediaSource.h:
31280        * Modules/mediastream/UserMediaController.h:
31281        * Modules/notifications/NotificationCenter.h:
31282        * Modules/notifications/NotificationController.cpp:
31283        * Modules/quota/StorageErrorCallback.h:
31284        * Modules/vibration/Vibration.h:
31285        * Modules/webdatabase/Database.cpp:
31286        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
31287        * Modules/websockets/WebSocket.cpp:
31288        * Modules/websockets/WebSocket.h:
31289
312902014-05-01  Ryuan Choi  <ryuan.choi@samsung.com>
31291
31292        Remove TiledBackingStore stuff from Frame
31293        https://bugs.webkit.org/show_bug.cgi?id=132458
31294
31295        Reviewed by Andreas Kling.
31296
31297        Although TiledBackingStore is using for the CoordinatedGraphics,
31298        CoordinatedGraphics does not use tiledBackingStore of Frame.
31299
31300        This patch removed TiledBackingStore related code of the Frame.
31301
31302        * page/Frame.cpp:
31303        (WebCore::Frame::Frame):
31304        (WebCore::Frame::setView):
31305        (WebCore::Frame::setTiledBackingStoreEnabled): Deleted.
31306        (WebCore::Frame::tiledBackingStorePaintBegin): Deleted.
31307        (WebCore::Frame::tiledBackingStorePaint): Deleted.
31308        (WebCore::Frame::tiledBackingStorePaintEnd): Deleted.
31309        (WebCore::Frame::tiledBackingStoreContentsRect): Deleted.
31310        (WebCore::Frame::tiledBackingStoreVisibleRect): Deleted.
31311        (WebCore::Frame::tiledBackingStoreBackgroundColor): Deleted.
31312        * page/Frame.h:
31313        (WebCore::Frame::tiledBackingStore): Deleted.
31314        * page/FrameView.cpp:
31315        (WebCore::FrameView::repaintContentRectangle):
31316        * page/Settings.cpp:
31317        (WebCore::Settings::Settings):
31318        (WebCore::Settings::setTiledBackingStoreEnabled): Deleted.
31319        * page/Settings.h:
31320        (WebCore::Settings::tiledBackingStoreEnabled): Deleted.
31321
313222014-05-01  Myles C. Maxfield  <mmaxfield@apple.com>
31323
31324        Migrate all uses of DeviceMotionController and DeviceOrientationController to std::unique_ptr
31325        https://bugs.webkit.org/show_bug.cgi?id=132461
31326
31327        Unreviewed build fix.
31328
31329        No new tests.
31330
31331        * dom/Document.cpp:
31332        (WebCore::Document::Document):
31333        * dom/Document.h:
31334        * platform/ios/DeviceMotionClientIOS.h:
31335        (WebCore::DeviceMotionClientIOS::create): Deleted.
31336        * platform/ios/DeviceOrientationClientIOS.h:
31337        (WebCore::DeviceOrientationClientIOS::create): Deleted.
31338
313392014-05-01  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
31340
31341        Convert OwnPtr and PassOwnPtr uses to std::unique_ptr in Supplement
31342        https://bugs.webkit.org/show_bug.cgi?id=132165
31343
31344        Reviewed by Darin Adler.
31345
31346        According to convert from PassOwnPtr to std::unique_ptr, provideTo() callers also begin
31347        to use std::make_unique.
31348
31349        * Modules/battery/BatteryController.cpp:
31350        (WebCore::provideBatteryTo):
31351        * Modules/battery/BatteryController.h:
31352        * Modules/battery/NavigatorBattery.cpp:
31353        (WebCore::NavigatorBattery::from):
31354        * Modules/gamepad/NavigatorGamepad.cpp:
31355        (WebCore::NavigatorGamepad::from):
31356        * Modules/geolocation/GeolocationController.cpp:
31357        (WebCore::provideGeolocationTo):
31358        * Modules/geolocation/GeolocationController.h:
31359        * Modules/geolocation/NavigatorGeolocation.cpp:
31360        (WebCore::NavigatorGeolocation::from):
31361        * Modules/indexeddb/DOMWindowIndexedDatabase.cpp:
31362        (WebCore::DOMWindowIndexedDatabase::from):
31363        * Modules/indexeddb/PageGroupIndexedDatabase.cpp:
31364        (WebCore::PageGroupIndexedDatabase::from):
31365        * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.cpp:
31366        (WebCore::WorkerGlobalScopeIndexedDatabase::from):
31367        * Modules/mediastream/UserMediaController.cpp:
31368        (WebCore::provideUserMediaTo):
31369        (WebCore::UserMediaController::create): Deleted.
31370        * Modules/mediastream/UserMediaController.h:
31371        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
31372        (WebCore::provideNavigatorContentUtilsTo):
31373        (WebCore::NavigatorContentUtils::create): Deleted.
31374        * Modules/navigatorcontentutils/NavigatorContentUtils.h:
31375        * Modules/notifications/DOMWindowNotifications.cpp:
31376        (WebCore::DOMWindowNotifications::from):
31377        * Modules/notifications/NotificationController.cpp:
31378        (WebCore::provideNotification):
31379        (WebCore::NotificationController::create): Deleted.
31380        * Modules/notifications/NotificationController.h:
31381        * Modules/notifications/WorkerGlobalScopeNotifications.cpp:
31382        (WebCore::WorkerGlobalScopeNotifications::from):
31383        * Modules/proximity/DeviceProximityController.cpp:
31384        (WebCore::provideDeviceProximityTo):
31385        (WebCore::DeviceProximityController::create): Deleted.
31386        * Modules/proximity/DeviceProximityController.h:
31387        * Modules/quota/DOMWindowQuota.cpp:
31388        (WebCore::DOMWindowQuota::from):
31389        * Modules/quota/NavigatorStorageQuota.cpp:
31390        (WebCore::NavigatorStorageQuota::from):
31391        * Modules/quota/WorkerNavigatorStorageQuota.cpp:
31392        (WebCore::WorkerNavigatorStorageQuota::from):
31393        * Modules/speech/DOMWindowSpeechSynthesis.cpp:
31394        (WebCore::DOMWindowSpeechSynthesis::from):
31395        * Modules/speech/SpeechRecognitionController.cpp:
31396        (WebCore::provideSpeechRecognitionTo):
31397        * Modules/vibration/Vibration.cpp:
31398        (WebCore::provideVibrationTo):
31399        (WebCore::Vibration::create): Deleted.
31400        * Modules/vibration/Vibration.h:
31401        * dom/DeviceMotionController.cpp:
31402        (WebCore::provideDeviceMotionTo):
31403        (WebCore::DeviceMotionController::create): Deleted.
31404        * dom/DeviceMotionController.h:
31405        * dom/DeviceOrientationController.cpp:
31406        (WebCore::provideDeviceOrientationTo):
31407        (WebCore::DeviceOrientationController::create): Deleted.
31408        * dom/DeviceOrientationController.h:
31409        * page/SpeechInput.cpp:
31410        (WebCore::provideSpeechInputTo):
31411        (WebCore::SpeechInput::create): Deleted.
31412        * page/SpeechInput.h:
31413        * platform/Supplementable.h:
31414        (WebCore::Supplement::provideTo):
31415        (WebCore::Supplementable::provideSupplement):
31416        * testing/InternalSettings.cpp:
31417        (WebCore::InternalSettings::from):
31418
314192014-05-01  Andreas Kling  <akling@apple.com>
31420
31421        HTMLMediaElement: Remove two unnecessary virtual overrides.
31422        <https://webkit.org/b/132445>
31423
31424        Now that ENABLE_PLUGIN_PROXY_FOR_VIDEO is gone, we can remove
31425        these overrides:
31426
31427            - defaultEventHandler()
31428            - willRespondToMouseClickEvents()
31429
31430        Reviewed by Darin Adler.
31431
31432        * html/HTMLMediaElement.cpp:
31433        * html/HTMLMediaElement.h:
31434
314352014-05-01  Benjamin Poulain  <bpoulain@apple.com>
31436
31437        ViewportConfiguration::minimumScale() uses the initial scale as initial value
31438        https://bugs.webkit.org/show_bug.cgi?id=132451
31439        <rdar://problem/16780111>
31440
31441        Reviewed by Enrica Casucci.
31442
31443        * page/ViewportConfiguration.cpp:
31444        (WebCore::ViewportConfiguration::minimumScale):
31445        The initial minimum scale was set to the initial scale, preventing some pages from zooming
31446        out.
31447
314482014-05-01  Alexey Proskuryakov  <ap@apple.com>
31449
31450        Build fix for !ENABLE(BLOB) builds.
31451
31452        * fileapi/ThreadableBlobRegistry.cpp:
31453        (WebCore::ThreadableBlobRegistry::registerBlobURL):
31454        (WebCore::ThreadableBlobRegistry::registerBlobURLForSlice):
31455
314562014-05-01  Alexey Proskuryakov  <ap@apple.com>
31457
31458        Move size computation for Blob constructor into BlobRegistryImpl
31459        https://bugs.webkit.org/show_bug.cgi?id=132439
31460
31461        Reviewed by Sam Weinig.
31462
31463        * Modules/websockets/WebSocket.cpp: (WebCore::WebSocket::didReceiveBinaryData):
31464        Don't pass the size, anyone who cares can get it from BlobData.
31465
31466        * bindings/js/JSBlobCustom.cpp: (WebCore::JSBlobConstructor::constructJSBlob):
31467        Updated for BlobBuilder changes.
31468
31469        * fileapi/Blob.cpp: (WebCore::Blob::Blob):
31470        * fileapi/Blob.h: (WebCore::Blob::create):
31471        No longer take a precomputed size with BlobData, BlobRegistry will compute it as
31472        part of registration.
31473
31474        * fileapi/File.h:
31475        * fileapi/File.cpp:
31476        (WebCore::File::File): Don't pass a size (that's unknown anyway).
31477        (WebCore::File::captureSnapshot): Deleted. Finally, only the registry is responsible
31478        for snapshot tracking now (I doubt that either new or old code is particularly compliant).
31479
31480        * fileapi/ThreadableBlobRegistry.cpp:
31481        (WebCore::ThreadableBlobRegistry::registerBlobURL):
31482        * fileapi/ThreadableBlobRegistry.h:
31483        Plumbing to make this version of registerBlobURL return a size. I may make size
31484        calculation lazy and the function async later, but this is needed to move the behavior
31485        to the right place first.
31486
31487        * fileapi/WebKitBlobBuilder.h:
31488        * fileapi/WebKitBlobBuilder.cpp:
31489        (WebCore::BlobBuilder::BlobBuilder):
31490        (WebCore::BlobBuilder::append):
31491        (WebCore::BlobBuilder::appendBytesData):
31492        (WebCore::BlobBuilder::finalize):
31493        (WebCore::BlobBuilder::getBlob): Deleted.
31494        Don't track sizes or modification times, registry will do that with appropriate laziness.
31495        Cleaned up the API - now that BlobBuilder is not exposed to JS as an object, it
31496        does not need to be reusable.
31497
31498        * platform/network/BlobRegistry.h: Made this version of registerBlobURL return a size.
31499        * platform/network/BlobRegistryImpl.h:
31500        * platform/network/BlobRegistryImpl.cpp:
31501        (WebCore::BlobRegistryImpl::appendStorageItems): Assert that length computations are accurate.
31502        (WebCore::BlobRegistryImpl::registerBlobURL): Compute a size to return, and record
31503        modification time as necessary.
31504
31505        * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::responseBlob): Don't pass the
31506        size, which can be computed from data. Soon, I want to add a constructor that doesn't
31507        require wrapping a single Vector as BlobData to construct a Blob.
31508
315092014-05-01  Eric Carlson  <eric.carlson@apple.com>
31510
31511        [iOS] audio and video should automatically play to active external device
31512        https://bugs.webkit.org/show_bug.cgi?id=132428
31513
31514        Reviewed by Jer Noble.
31515
31516        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
31517        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Set 
31518            AVPlayer.usesExternalPlaybackWhileExternalScreenIsActive.
31519
315202014-05-01  David Hyatt  <hyatt@apple.com>
31521
31522        REGRESSION (r168046): [New Multicolumn] Selection into and out of column-span elements doesn't work
31523        https://bugs.webkit.org/show_bug.cgi?id=132066
31524
31525        Reviewed by Oliver Hunt.
31526
31527        Make a new SelectionIterator struct that knows how to drill into and out of
31528        column span placeholders. Also change spans to be selection roots (in the painting
31529        sense).
31530
31531        * rendering/RenderBlock.cpp:
31532        (WebCore::RenderBlock::isSelectionRoot):
31533        (WebCore::RenderBlock::selectionGaps):
31534        * rendering/RenderView.cpp:
31535        (WebCore::SelectionIterator::SelectionIterator):
31536        (WebCore::SelectionIterator::checkForSpanner):
31537        (WebCore::SelectionIterator::current):
31538        (WebCore::SelectionIterator::next):
31539        (WebCore::RenderView::subtreeSelectionBounds):
31540        (WebCore::RenderView::repaintSubtreeSelection):
31541        (WebCore::RenderView::setSubtreeSelection):
31542
315432014-05-01  Simon Fraser  <simon.fraser@apple.com>
31544
31545        Don't always make backing store for -webkit-backface-visibility:hidden
31546        https://bugs.webkit.org/show_bug.cgi?id=132420
31547
31548        Reviewed by Sam Weinig.
31549        
31550        Previously, -webkit-backface-visibility:hidden unconditionally created
31551        compositing layers with backing store. This results in high memory use
31552        on pages with this style applied to many elements (a cargo-cult "optimization").
31553        
31554        Fix by only having -webkit-backface-visibility:hidden create compositing layers
31555        if some ancestor has a 3D transform. That's the only scenario in which the
31556        element can be flipped around to reveal the back side, so the only time we need
31557        to do compositing for this property. In future, we could be smarter, and only
31558        consider 3D transforms in the current preserve-3d context.
31559
31560        Tests: compositing/backing/backface-visibility-in-3dtransformed.html
31561               compositing/backing/backface-visibility-in-transformed.html
31562               compositing/backing/backface-visibility.html
31563
31564        * rendering/RenderLayer.cpp:
31565        (WebCore::RenderLayer::RenderLayer):
31566        (WebCore::RenderLayer::updateLayerPositions):
31567        (WebCore::RenderLayer::hitTestLayer):
31568        * rendering/RenderLayer.h:
31569        * rendering/RenderLayerCompositor.cpp:
31570        (WebCore::RenderLayerCompositor::requiresCompositingLayer):
31571        (WebCore::RenderLayerCompositor::requiresOwnBackingStore):
31572        (WebCore::RenderLayerCompositor::requiresCompositingForBackfaceVisibility):
31573        * rendering/RenderLayerCompositor.h:
31574
315752014-05-01  Alex Christensen  <achristensen@webkit.org>
31576
31577        Finish updating ANGLE.
31578        https://bugs.webkit.org/show_bug.cgi?id=132434
31579
31580        Reviewed by Dean Jackson.
31581
31582        * CMakeLists.txt:
31583        Removed Uniform.cpp which is no longer in ANGLE.
31584
315852014-05-01  David Hyatt  <hyatt@apple.com>
31586
31587        REGRESSION (new multi-column): WebKit2.ResizeReversePaginatedWebView fails on debug bots
31588        https://bugs.webkit.org/show_bug.cgi?id=132429
31589
31590        Reviewed by Alexey Proskuryakov.
31591        
31592        Make sure to get the column count directly from the column set.
31593        I was returning the theoretical column count from the flow thread,
31594        and that wasn't the right value.
31595
31596        * rendering/RenderMultiColumnSet.h:
31597        * rendering/RenderView.cpp:
31598        (WebCore::RenderView::pageCount):
31599
316002014-05-01  Brent Fulgham  <bfulgham@apple.com>
31601
31602        Fix handling of attributes prior to compiling shader
31603        https://bugs.webkit.org/show_bug.cgi?id=132430
31604
31605        Reviewed by Dean Jackson.
31606
31607        WebGL programs that called bindAttribLocations prior to compiling shader sources
31608        would perform the bind using the non-hashed symbol name, but would later create
31609        the attributes as hashed names. Consequently, the program would refer to
31610        attributes that were never actually part of any shader, resulting in some amazing
31611        display artifacts.
31612
31613        This patch adds a dictionary of hashed symbol names so that we can tell the WebGL
31614        program the proper name that will be used when the shader is eventually compiled,
31615        allowing the WebGL program to link against the proper symbol after compiling and
31616        linking completes.
31617
31618        * platform/graphics/GraphicsContext3D.h:
31619        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
31620        (WebCore::generateHashedName): Function uses the ANGLE hashing
31621        function to generate correct symbol.
31622        (WebCore::GraphicsContext3D::mappedSymbolName): If we haven't compiled shaders yet, look
31623        in our set of potentially unused attributes.
31624        (WebCore::GraphicsContext3D::originalSymbolName): Ditto, for reverse lookup.
31625
316262014-05-01  Zalan Bujtas  <zalan@apple.com>
31627
31628        Subpixel rendering: Make selection gaps painting subpixel aware.
31629        https://bugs.webkit.org/show_bug.cgi?id=132169
31630
31631        Reviewed by Simon Fraser.
31632
31633        Push selection gaps painting to device pixel boundaries instead of integral CSS pixel positions.
31634
31635        Test: fast/inline/hidpi-selection-gap-on-subpixel-position.html
31636
31637        * rendering/RenderBlock.cpp:
31638        (WebCore::RenderBlock::blockSelectionGap):
31639        (WebCore::RenderBlock::logicalLeftSelectionGap):
31640        (WebCore::RenderBlock::logicalRightSelectionGap):
31641
316422014-05-01  David Kilzer  <ddkilzer@apple.com>
31643
31644        Really remove ENABLE_PLUGIN_PROXY_FOR_VIDEO
31645        <http://webkit.org/b/132432>
31646
31647        Reviewed by Tim Horton.
31648
31649        * platform/graphics/wince/MediaPlayerPrivateWinCE.h: Remove
31650        methods and ivar in ENABLE(PLUGIN_PROXY_FOR_VIDEO).
31651
316522014-05-01  Javier Fernandez  <jfernandez@igalia.com>
31653
31654        [CSS Grid Layout] Clamping the number of repetitions in repeat()
31655        https://bugs.webkit.org/show_bug.cgi?id=131023
31656
31657        Reviewed by Brent Fulgham.
31658
31659        The ED suggests now to be able to clamp the number of repetitions when
31660        using the repeat() function, taking precautions about excessive memory
31661        usage.
31662
31663        The implemented max repetitions is 10K.
31664
31665        Test: fast/css-grid-layout/grid-element-repeat-max-repetitions.html
31666
31667        * css/CSSParser.cpp:
31668        (WebCore::CSSParser::parseGridTrackRepeatFunction):
31669
316702014-04-30  Jer Noble  <jer.noble@apple.com>
31671
31672        [MSE] Seeking between two buffered ranges enquues incorrect buffers.
31673        https://bugs.webkit.org/show_bug.cgi?id=132416
31674
31675        Reviewed by Eric Carlson.
31676
31677        std::equal_range(begin, end, value) will return an empty range if equal values cannot
31678        be found. But the range is not necessarily [end, end).  It may be some other value n,
31679        such that the empty range is [n, n). Check to see if the returned range is empty in
31680        findSampleContainingPresentationTime() and its reverse version, and if so, explicitly
31681        return presentationEnd() or reversePresentationEnd() respectively.
31682
31683        Drive-by fix: make the comparator functions take const& arguments to minimize object
31684        creation.
31685
31686        * Modules/mediasource/SampleMap.cpp:
31687        (WebCore::SampleIsLessThanMediaTimeComparator::operator()):
31688        (WebCore::SampleIsGreaterThanMediaTimeComparator::operator()):
31689        (WebCore::SampleMap::findSampleContainingPresentationTime):
31690        (WebCore::SampleMap::reverseFindSampleContainingPresentationTime):
31691
316922014-05-01  Zalan Bujtas  <zalan@apple.com>
31693
31694        Subpixel rendering: Inline text selection painting should not snap to integral CSS pixel position.
31695        https://bugs.webkit.org/show_bug.cgi?id=132164
31696
31697        Reviewed by Darin Adler.
31698
31699        Inline text selection painting now snaps to device pixels. It uses the same rounding logic as
31700        other painting functions.
31701
31702        Test: fast/inline/hidpi-select-inline-on-subpixel-position.html
31703
31704        * rendering/EllipsisBox.cpp:
31705        (WebCore::EllipsisBox::paintSelection):
31706        * rendering/InlineTextBox.cpp:
31707        (WebCore::InlineTextBox::paintSelection):
31708        (WebCore::alignSelectionRectToDevicePixels): Deleted.
31709        * rendering/InlineTextBox.h:
31710
317112014-05-01  Ryuan Choi  <ryuan.choi@samsung.com>
31712
31713        [EFL] There are many warnings with software backend
31714        https://bugs.webkit.org/show_bug.cgi?id=132422
31715
31716        Reviewed by Gyuyoung Kim.
31717
31718        ecore_evas_gl_x11_window_get should be called when only engine is opengl_x11.
31719
31720        This patch refactors not to call unnecessary API by checking engine type.
31721        In addition, removed unnecessary isUsingEcoreX().
31722
31723        * platform/efl/EflScreenUtilities.cpp:
31724        (WebCore::applyFallbackCursor):
31725        (WebCore::getEcoreXWindow):
31726        (WebCore::isUsingEcoreX): Deleted.
31727        * platform/efl/EflScreenUtilities.h:
31728
317292014-05-01  Rik Cabanier  <cabanier@adobe.com>
31730
31731        Calling createPattern with a broken image must throw an invalidstate error
31732        https://bugs.webkit.org/show_bug.cgi?id=132407
31733
31734        Reviewed by Dirk Schulze.
31735
31736        Per the WebIDL spec, passing non-finite parameter to a method that
31737        takes doubles, should generate a type error.
31738
31739        Tests:
31740        * canvas/philip/tests/2d.imageData.create2.nonfinite.html:
31741        * fast/canvas/canvas-2d-imageData-create-nonfinite.html:
31742
31743        * html/canvas/CanvasRenderingContext2D.cpp:
31744        (WebCore::CanvasRenderingContext2D::createImageData):
31745
317462014-04-30  David Hyatt  <hyatt@apple.com>
31747
31748        REGRESSION (r168046): [New Multicolumn] LeftToRight-rl.html (and all the other reversed/block-axis pagination tests) fail
31749        https://bugs.webkit.org/show_bug.cgi?id=132419
31750
31751        Reviewed by Andreas Kling.
31752
31753        * rendering/RenderMultiColumnSet.cpp:
31754        (WebCore::RenderMultiColumnSet::initialBlockOffsetForPainting):
31755        Don't flip here. The old code needed to do that, but the new code doesn't.
31756
317572014-04-30  Alexey Proskuryakov  <ap@apple.com>
31758
31759        Roll out fix for https://bugs.webkit.org/show_bug.cgi?id=131637:
31760        Clean up unnecessary methods in the BackForwardClient interface
31761
31762        It broke a regression test and an API test.
31763
31764        * WebCore.exp.in:
31765        * history/BackForwardClient.h:
31766        (WebCore::BackForwardClient::backItem):
31767        (WebCore::BackForwardClient::currentItem):
31768        (WebCore::BackForwardClient::forwardItem):
31769        * history/BackForwardController.cpp:
31770        (WebCore::BackForwardController::BackForwardController):
31771        * history/BackForwardController.h:
31772        (WebCore::BackForwardController::client):
31773        * history/BackForwardList.cpp:
31774        (WebCore::BackForwardList::BackForwardList):
31775        (WebCore::BackForwardList::close):
31776        * history/BackForwardList.h:
31777        (WebCore::BackForwardList::create):
31778        (WebCore::BackForwardList::page):
31779        * page/Page.cpp:
31780        (WebCore::Page::Page):
31781        (WebCore::Page::PageClients::PageClients):
31782        * page/Page.h:
31783
317842014-04-30  Simon Fraser  <simon.fraser@apple.com>
31785
31786        More iOS build fixing. MediaPlayerPrivateIOS is defunct and can be removed.
31787        Fix some build errors in other media files.
31788
31789        * WebCore.xcodeproj/project.pbxproj:
31790        * platform/graphics/MediaPlayer.cpp:
31791        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
31792        * platform/graphics/ios/MediaPlayerPrivateIOS.h: Removed.
31793        * platform/graphics/ios/MediaPlayerPrivateIOS.mm: Removed.
31794
317952014-04-30  Simon Fraser  <simon.fraser@apple.com>
31796
31797        Fix the iOS build, which no longer needs these calls
31798        to enter/exitFullscreen.
31799
31800        * html/HTMLMediaElement.cpp:
31801        (WebCore::HTMLMediaElement::parseAttribute):
31802
318032014-04-30  Simon Fraser  <simon.fraser@apple.com>
31804
31805        Remove ENABLE_PLUGIN_PROXY_FOR_VIDEO
31806        https://bugs.webkit.org/show_bug.cgi?id=132396
31807
31808        Reviewed by Eric Carlson.
31809
31810        Remove ENABLE_PLUGIN_PROXY_FOR_VIDEO and related code.
31811
31812        * Configurations/FeatureDefines.xcconfig:
31813        * WebCore.exp.in:
31814        * css/StyleResolver.cpp:
31815        (WebCore::StyleResolver::canShareStyleWithElement):
31816        * dom/DOMImplementation.cpp:
31817        (WebCore::DOMImplementation::createDocument):
31818        * editing/TextIterator.cpp:
31819        (WebCore::isRendererReplacedElement):
31820        * html/HTMLMediaElement.cpp:
31821        (WebCore::HTMLMediaElement::HTMLMediaElement):
31822        (WebCore::HTMLMediaElement::parseAttribute):
31823        * html/HTMLMediaElement.h:
31824        (WebCore::HTMLMediaElement::setNeedWidgetUpdate): Deleted.
31825        * html/HTMLMediaSession.cpp:
31826        (WebCore::HTMLMediaSession::showPlaybackTargetPicker):
31827        (WebCore::HTMLMediaSession::hasWirelessPlaybackTargets):
31828        (WebCore::HTMLMediaSession::setHasPlaybackTargetAvailabilityListeners):
31829        * html/HTMLVideoElement.cpp:
31830        (WebCore::HTMLVideoElement::createElementRenderer):
31831        (WebCore::HTMLVideoElement::didAttachRenderers):
31832        (WebCore::HTMLVideoElement::parseAttribute):
31833        (WebCore::HTMLVideoElement::setDisplayMode):
31834        * html/shadow/MediaControlElements.cpp:
31835        (WebCore::MediaControlTextTrackContainerElement::updateSizes):
31836        * loader/EmptyClients.cpp:
31837        (WebCore::EmptyFrameLoaderClient::createMediaPlayerProxyPlugin): Deleted.
31838        * loader/EmptyClients.h:
31839        * loader/FrameLoaderClient.h:
31840        * loader/SubframeLoader.cpp:
31841        (WebCore::SubframeLoader::loadPlugin):
31842        (WebCore::SubframeLoader::loadMediaPlayerProxyPlugin): Deleted.
31843        * loader/SubframeLoader.h:
31844        * page/FrameView.cpp:
31845        (WebCore::FrameView::updateEmbeddedObject):
31846        * page/Settings.cpp:
31847        (WebCore::Settings::setVideoPluginProxyEnabled): Deleted.
31848        * page/Settings.h:
31849        (WebCore::Settings::isVideoPluginProxyEnabled): Deleted.
31850        * platform/graphics/GraphicsLayerClient.h:
31851        (WebCore::GraphicsLayerClient::mediaLayerMustBeUpdatedOnMainThread): Deleted.
31852        * platform/graphics/MediaPlayer.cpp:
31853        (WebCore::installedMediaEngines):
31854        (WebCore::MediaPlayer::MediaPlayer):
31855        (WebCore::MediaPlayer::loadWithNextMediaEngine):
31856        (WebCore::NullMediaPlayerPrivate::deliverNotification): Deleted.
31857        (WebCore::NullMediaPlayerPrivate::setMediaPlayerProxy): Deleted.
31858        (WebCore::NullMediaPlayerPrivate::setControls): Deleted.
31859        (WebCore::MediaPlayer::deliverNotification): Deleted.
31860        (WebCore::MediaPlayer::setMediaPlayerProxy): Deleted.
31861        (WebCore::MediaPlayer::setControls): Deleted.
31862        * platform/graphics/MediaPlayer.h:
31863        * platform/graphics/MediaPlayerPrivate.h:
31864        (WebCore::MediaPlayerPrivateInterface::deliverNotification): Deleted.
31865        (WebCore::MediaPlayerPrivateInterface::setMediaPlayerProxy): Deleted.
31866        (WebCore::MediaPlayerPrivateInterface::setControls): Deleted.
31867        * platform/graphics/ca/GraphicsLayerCA.cpp:
31868        (WebCore::GraphicsLayerCA::updateGeometry):
31869        (WebCore::GraphicsLayerCA::updateContentsRects):
31870        (WebCore::GraphicsLayerCA::mediaLayerMustBeUpdatedOnMainThread): Deleted.
31871        * platform/graphics/ca/GraphicsLayerCA.h:
31872        * rendering/RenderEmbeddedObject.cpp:
31873        (WebCore::RenderEmbeddedObject::canHaveChildren):
31874        * rendering/RenderLayerBacking.cpp:
31875        (WebCore::RenderLayerBacking::mediaLayerMustBeUpdatedOnMainThread): Deleted.
31876        * rendering/RenderLayerBacking.h:
31877        * rendering/RenderLayerCompositor.cpp:
31878        (WebCore::RenderLayerCompositor::requiresCompositingForVideo):
31879
318802014-04-30  Simon Fraser  <simon.fraser@apple.com>
31881
31882        [iOS WK2] Some accerated overflow-scroll doesn't scroll correctly
31883        https://bugs.webkit.org/show_bug.cgi?id=132375
31884
31885        Reviewed by Tim Horton.
31886        
31887        We set the size of the scrolling layer (which becomes the bounds of
31888        the UIScrollView) to a non-pixel-snapped padding box size, but the
31889        size of the contents layer is an integral-snapped scroll size.
31890        This would result in a fractional difference between the two, which
31891        makes us thing that the element is scrollable when it really is not.
31892        
31893        Fix by setting the size of the scroll layer to pixel snapped client size,
31894        which is what we also use for scrollability computation.
31895        
31896        Added some FIXMEs in code that requires pixel snapping.
31897        
31898        Also use #if PLATFORM(IOS)/#else to bracket some code that never runs on iOS
31899        but tries to do something similar to iOS-only code.
31900
31901        * rendering/RenderLayerBacking.cpp:
31902        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
31903
319042014-04-30  David Hyatt  <hyatt@apple.com>
31905
31906        REGRESSION (r168046): [New Multicolumn] Painting order is wrong for columns and fixed positioned elements
31907        https://bugs.webkit.org/show_bug.cgi?id=132377
31908
31909        Reviewed by Simon Fraser.
31910
31911        Added fast/multicol/fixed-stack.html
31912
31913        * rendering/RenderLayer.cpp:
31914        (WebCore::RenderLayer::shouldBeSelfPaintingLayer):
31915        (WebCore::RenderLayer::shouldBeNormalFlowOnly):
31916        Change the flow thread layer for multicolumn layout to be normal flow only and to
31917        stay self-painting. This has the effect of keeping the flow thread layer grouped
31918        with the enclosing multicolumn layer, and this keeps the paint order correct when
31919        compositing kicks in (or when something would otherwise try to get between the
31920        two layers).
31921
319222014-04-30  Eric Carlson  <eric.carlson@apple.com>
31923
31924        [iOS] do not pause video when entering background while playing to external device
31925        https://bugs.webkit.org/show_bug.cgi?id=132374
31926
31927        Reviewed by Jer Noble.
31928
31929        * WebCore.exp.in: Update beginInterruption signature.
31930
31931        * html/HTMLMediaElement.cpp:
31932        (WebCore::HTMLMediaElement::canOverrideBackgroundPlaybackRestriction): New, return true when
31933            playing to external device.
31934        * html/HTMLMediaElement.h:
31935
31936        * platform/audio/MediaSession.cpp:
31937        (WebCore::MediaSession::beginInterruption): Add interruption type to beginInterruption.
31938        * platform/audio/MediaSession.h:
31939
31940        * platform/audio/MediaSessionManager.cpp:
31941        (WebCore::MediaSessionManager::beginInterruption): Ditto.
31942        (WebCore::MediaSessionManager::applicationWillEnterBackground): Ditto.
31943        (WebCore::MediaSessionManager::systemWillSleep): Ditto.
31944        * platform/audio/MediaSessionManager.h:
31945
31946        * platform/audio/ios/AudioDestinationIOS.h:
31947        * platform/audio/ios/MediaSessionManagerIOS.mm:
31948        (-[WebMediaSessionHelper interruption:]): Ditto.
31949
31950        * platform/audio/mac/AudioDestinationMac.h: Make most methods private. Add 
31951            canOverrideBackgroundPlaybackRestriction. Add missing overrides.
31952        * testing/Internals.cpp:
31953        (WebCore::Internals::beginMediaSessionInterruption): Pass interruption type.
31954
319552014-04-30  Manuel Rego Casasnovas  <rego@igalia.com>
31956
31957        Unreviewed, rolling out r167879 and r167942.
31958        https://bugs.webkit.org/show_bug.cgi?id=132408
31959
31960        OrderIterator changes caused regressions in flexbox (Requested
31961        by rego on #webkit).
31962
31963        We're keeping the new layout test introduced in r167942
31964        (fast/flexbox/order-iterator-crash.html) to avoid similar
31965        regressions in the future.
31966
31967        Reverted changesets:
31968
31969        "OrderIterator refactoring to avoid extra loops"
31970        https://bugs.webkit.org/show_bug.cgi?id=119061
31971        http://trac.webkit.org/changeset/167879
31972
31973        "REGRESSION (r167879): Heap-use-after-free in
31974        WebCore::RenderFlexibleBox"
31975        https://bugs.webkit.org/show_bug.cgi?id=132337
31976        http://trac.webkit.org/changeset/167942
31977
319782014-04-30  Enrica Casucci  <enrica@apple.com>
31979
31980        Cursor gets thinner on empty lines.
31981        https://bugs.webkit.org/show_bug.cgi?id=132411
31982        <rdar://problem/15994556>
31983
31984        Reviewed by Benjamin Poulain.
31985
31986        RenderLineBreak::localCaretRect should not define
31987        locally the constant caretWidth, but use the one from
31988        RenderObject.h which knows about the differences between
31989        iOS and the other platforms.
31990
31991        * rendering/RenderLineBreak.cpp:
31992        (WebCore::RenderLineBreak::localCaretRect):
31993
319942014-04-30  Víctor Manuel Jáquez Leal  <vjaquez@igalia.com>
31995
31996        [GStreamer] Use GstMetaVideo
31997        https://bugs.webkit.org/show_bug.cgi?id=132247
31998
31999        Reviewed by Philippe Normand.
32000
32001        In WebKitVideoSink we announce the usage of GstMetaVideo, but we do
32002        not use it when handling the video frames. This might break
32003        some decoders and filters that rely on buffer's meta, rather
32004        that in the caps structures.
32005
32006        This patch enables the use of GstMetaVideo through the GstVideoFrame
32007        API. And it is used everywhere the buffer mapping is required.
32008
32009        Also this patch changes to nullptr where zeros were used.
32010
32011        Also, compile conditionally the video buffer conversion when it is
32012        ARGB/BGRA, since it is only required for the Cairo backend.
32013
32014        No new tests, already covered by current tests.
32015
32016        * platform/graphics/gstreamer/GStreamerUtilities.cpp:
32017        (WebCore::getVideoSizeAndFormatFromCaps): init the GstVideoInfo before
32018        used and remove caps fixate check since it is done by
32019        gst_video_info_from_caps().
32020        * platform/graphics/gstreamer/ImageGStreamer.h:
32021        * platform/graphics/gstreamer/ImageGStreamerCairo.cpp:
32022        (ImageGStreamer::ImageGStreamer): use GstVideoFrame for buffer mapping
32023        and unmapping.
32024        (ImageGStreamer::~ImageGStreamer): ditto.
32025        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
32026        (WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): ditto.
32027        (WebCore::MediaPlayerPrivateGStreamerBase::currentVideoSinkCaps):
32028        return nullptr if failed.
32029        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
32030        (webkitVideoSinkRender): rely on GstVideoInfo rather than on the
32031        caps. Use GstVideoFrame for buffer mapping and unmapping. Add guards
32032        for buffer transformation, since it's only used by Cairo.
32033        (webkitVideoSinkDispose): remove glib version guards.
32034        (webkitVideoSinkSetCaps): update the value of the private
32035        GstVideoInfo.
32036
320372014-04-30  Víctor Manuel Jáquez Leal  <vjaquez@igalia.com>
32038
32039        [GTK][GStreamer] Remove unnecessary GLIB_CHECK_VERSION #ifdefs
32040        https://bugs.webkit.org/show_bug.cgi?id=132390
32041
32042        Reviewed by Philippe Normand.
32043
32044        Since EFL port use GLib 2.38 and GTK+, 2.33.2, I assume it is OK
32045        remove, in GTK+ and GST, the existing glib version guards.
32046
32047        No new tests, already covered by current tests.
32048
32049        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
32050        (WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
32051        (WebCore::MediaPlayerPrivateGStreamerBase::~MediaPlayerPrivateGStreamerBase):
32052        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
32053        (webkitVideoSinkDispose):
32054        (webkitVideoSinkFinalize): Deleted.
32055
320562014-04-30  Alex Christensen  <achristensen@webkit.org>
32057
32058        Updated ANGLE.
32059        https://bugs.webkit.org/show_bug.cgi?id=132367
32060        <rdar://problem/16211451>
32061
32062        Reviewed by Dean Jackson.
32063
32064        * CMakeLists.txt
32065        Fixed ANGLE compiling with the update.
32066        * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
32067        (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE):
32068        Removed SH_MAP_LONG_VARIABLE_NAMES which is no longer defined in ANGLE.
32069        See https://chromium.googlesource.com/angle/angle/+/3cdfcce86b38ef31a0afd71855887193a7924468
32070        * platform/graphics/opengl/Extensions3DOpenGLES.h:
32071        * platform/graphics/opengl/Extensions3DOpenGLES.cpp:
32072        Updated type names from ANGLE.
32073
320742014-04-30  Alexey Proskuryakov  <ap@apple.com>
32075
32076        Move Blob.slice() implementation into BlobRegistryImpl
32077        https://bugs.webkit.org/show_bug.cgi?id=132402
32078
32079        Reviewed by Anders Carlsson.
32080
32081        Part or centralizing the responsibility for file size tracking.
32082
32083        * fileapi/Blob.cpp:
32084        (WebCore::Blob::Blob):
32085        (WebCore::Blob::slice): Deleted.
32086        * fileapi/Blob.h:
32087        (WebCore::Blob::slice):
32088        * fileapi/ThreadableBlobRegistry.cpp:
32089        (WebCore::ThreadableBlobRegistry::registerBlobURL):
32090        (WebCore::ThreadableBlobRegistry::registerBlobURLForSlice):
32091        (WebCore::registerBlobURLTask): Deleted.
32092        (WebCore::registerBlobURLFromTask): Deleted.
32093        * fileapi/ThreadableBlobRegistry.h:
32094        * platform/network/BlobRegistry.h:
32095        * platform/network/BlobRegistryImpl.cpp:
32096        (WebCore::BlobRegistryImpl::appendStorageItems):
32097        (WebCore::BlobRegistryImpl::registerBlobURLForSlice):
32098        (WebCore::BlobRegistryImpl::blobSize):
32099        * platform/network/BlobRegistryImpl.h:
32100
321012014-04-30  Brent Fulgham  <bfulgham@apple.com>
32102
32103        Unreviewed build fix after r168041.
32104
32105        * WebCore.exp.in: Add missing iOS exports.
32106
321072014-04-30  Beth Dakin  <bdakin@apple.com>
32108
32109        Always-visible scrollbars continuously repaint after non-momentum scrollling
32110        https://bugs.webkit.org/show_bug.cgi?id=132403
32111        -and corresponding-
32112        <rdar://problem/16553878>
32113
32114        Reviewed by Simon Fraser.
32115
32116        No longer universally opt into presentation value mode whenever the scroll 
32117        position changes on the scrolling thread. We really only want it for momentum 
32118        scrolls, and this will ensure that we always set it to NO once we have set it to 
32119        YES.
32120        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
32121        (WebCore::ScrollingTreeScrollingNodeMac::handleWheelEvent):
32122        (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
32123
32124        Expose shouldUsePresentationValue.
32125        * platform/mac/NSScrollerImpDetails.h:
32126
321272014-04-30  Anders Carlsson  <andersca@apple.com>
32128
32129        Move the legacy WebKit API into WebKitLegacy.framework and move it inside WebKit.framework
32130        https://bugs.webkit.org/show_bug.cgi?id=132399
32131        <rdar://problem/15920046>
32132
32133        Reviewed by Dan Bernstein.
32134
32135        Allow WebKitLegacy to link against WebCore.
32136
32137        * Configurations/WebCore.xcconfig:
32138
321392014-04-30  David Hyatt  <hyatt@apple.com>
32140
32141        [New Multicolumn] ASSERTs in fast/dynamic/continuation-detach-crash.html
32142        https://bugs.webkit.org/show_bug.cgi?id=132392
32143
32144        Reviewed by Dean Jackson.
32145
32146        * rendering/RenderFlowThread.cpp:
32147        (WebCore::RenderFlowThread::setRegionRangeForBox):
32148        Add ASSERTs in case we ever try to set regions from the wrong flow thread
32149        as part of the box's region range.
32150
32151        * rendering/RenderMultiColumnFlowThread.cpp:
32152        (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantInserted):
32153        Add a bunch of code that handles the discovery of a span from an outer flow thread
32154        being inserted into an inner flow thread. This forces us to delete that placeholder
32155        and shift the outer spanning content into the inner flow thread in order to get a new
32156        mapping/placeholder created in the inner flow thread.
32157
32158        (WebCore::RenderMultiColumnFlowThread::flowThreadRelativeWillBeRemoved):
32159        Tighten this code to use the parent() just in case we change the invariant of
32160        parent = containingBlock later.
32161
32162        * rendering/RenderMultiColumnFlowThread.h:
32163        Add a static guard when shifting a spanner to prevent the outer flow thread from
32164        thinking the spanner belongs to it when it gets punted out of the inner flow thread.
32165        A better long-term solution might be to make the spanner map global instead of
32166        per-flow thread.
32167
32168        * rendering/RenderMultiColumnSpannerPlaceholder.cpp:
32169        (WebCore::RenderMultiColumnSpannerPlaceholder::RenderMultiColumnSpannerPlaceholder):
32170        * rendering/RenderMultiColumnSpannerPlaceholder.h:
32171        Cache the flow thread so that we can get back to it in order to detect if the
32172        placeholder belongs to us or not.
32173
32174        * rendering/RenderObject.cpp:
32175        (WebCore::RenderObject::insertedIntoTree):
32176        Notifications from insertedIntoTree are problematic, since this can be called during
32177        the layout of the outer flow thread for content inside an inner flow thread that is
32178        not getting a layout yet. This makes the currentFlowThread in the flow thread controller
32179        inaccurate, so we have to add code to clear it out and put it back.
32180
321812014-04-29  Chris Fleizach  <cfleizach@apple.com>
32182
32183        AX: Make "contenteditable" regions into AXTextAreas
32184        https://bugs.webkit.org/show_bug.cgi?id=132379
32185
32186        Reviewed by Mario Sanchez Prada.
32187
32188        Make contenteditable regions into AXTextAreas. This will allow for a more standardized
32189        interface for interaction with assistive technologies.
32190
32191        Test: accessibility/content-editable-as-textarea.html
32192
32193        * accessibility/AccessibilityNodeObject.cpp:
32194        (WebCore::AccessibilityNodeObject::hasContentEditableAttributeSet):
32195        * accessibility/AccessibilityObject.cpp:
32196        (WebCore::AccessibilityObject::contentEditableAttributeIsEnabled):
32197        * accessibility/AccessibilityObject.h:
32198        * accessibility/AccessibilityRenderObject.cpp:
32199        (WebCore::AccessibilityRenderObject::documentBasedSelectedTextRange):
32200        (WebCore::AccessibilityRenderObject::selectedText):
32201        (WebCore::AccessibilityRenderObject::selectedTextRange):
32202        (WebCore::AccessibilityRenderObject::renderObjectIsObservable):
32203        (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
32204        (WebCore::AccessibilityRenderObject::ariaSelectedTextRange): Deleted.
32205        * accessibility/AccessibilityRenderObject.h:
32206
322072014-04-30  Brian J. Burg  <burg@cs.washington.edu>
32208
32209        Clean up unnecessary methods in the BackForwardClient interface
32210        https://bugs.webkit.org/show_bug.cgi?id=131637
32211
32212        Reviewed by Andreas Kling.
32213
32214        Demote back/current/forwardItem and iOS-specific methods from the
32215        BackForwardClient interface. Convert the class to not be refcounted.
32216
32217        No new tests, no behavior was changed.
32218
32219        * WebCore.exp.in:
32220        * history/BackForwardClient.h:
32221        (WebCore::BackForwardClient::~BackForwardClient): Deleted.
32222        (WebCore::BackForwardClient::backItem): Deleted.
32223        (WebCore::BackForwardClient::currentItem): Deleted.
32224        (WebCore::BackForwardClient::forwardItem): Deleted.
32225        * history/BackForwardController.cpp:
32226        (WebCore::BackForwardController::BackForwardController):
32227        * history/BackForwardController.h: Take ownership of the passed BackForwardClient.
32228        (WebCore::BackForwardController::client): Return a reference.
32229        * history/BackForwardList.h: Remove the Page field, since it isn't used any more.
32230        (WebCore::BackForwardList::create): Deleted.
32231        * page/Page.h: Remove RefPtr from PageClient.
32232        * page/Page.cpp:
32233        (WebCore::PageClients::PageClients): Initialize client to nullptr.
32234
322352014-04-30  Brent Fulgham  <bfulgham@apple.com>
32236
32237        [Mac, iOS] Support caption activation via JS webkitHasClosedCaptions method
32238        https://bugs.webkit.org/show_bug.cgi?id=132320
32239
32240        Reviewed by Eric Carlson.
32241
32242        * Modules/mediacontrols/mediaControlsApple.css:
32243        (video::-webkit-media-text-track-container .hidden): Added.
32244        * html/HTMLMediaElement.cpp:
32245        (WebCore::HTMLMediaElement::configureTextTrackGroup): Added call to
32246        new 'updateCaptionsContainer'.
32247        (WebCore::HTMLMediaElement::updateCaptionContainer): Added.
32248        * html/HTMLMediaElement.h:
32249
322502014-04-30  Alexey Proskuryakov  <ap@apple.com>
32251
32252        https://bugs.webkit.org/show_bug.cgi?id=132363
32253        Make Blob RawData immutable
32254
32255        Reviewed by Anders Carlsson.
32256
32257        * Modules/websockets/WebSocket.cpp: (WebCore::WebSocket::didReceiveBinaryData):
32258        Create RawData in one step.
32259
32260        * WebCore.exp.in: Don't export a constructor that we no longer have (and the new one is inline).
32261
32262        * fileapi/Blob.cpp: Removed entirely dead code.
32263
32264        * fileapi/WebKitBlobBuilder.cpp:
32265        * fileapi/WebKitBlobBuilder.h:
32266        Updated to collect data in a plain Vector, so that we don't have to modify RawData.
32267        Removed FIXMEs about renaming - there used to be a BlobBuilder exposed to JS, but
32268        now this is just a helper to implement JS Blob constructor. We should probably
32269        still rename it, but not how the FIXME suggested.
32270
32271        * platform/network/BlobData.cpp:
32272        (WebCore::BlobDataItem::detachFromCurrentThread): RawData::detachFromCurrentThread()
32273        was a no-op.
32274        (WebCore::BlobDataHandle::BlobDataHandle): Deleted. This was entirely dead code.
32275        (WebCore::BlobDataHandle::~BlobDataHandle): Ditto.
32276
32277        * platform/network/BlobData.h: Made RawData immutable.
32278
32279        * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::responseBlob):
32280        Create RawData in one step.
32281
322822014-04-30  David Hyatt  <hyatt@apple.com>
32283
32284        [New Multicolumn] Region offset not factored in when mapping to local coords
32285        https://bugs.webkit.org/show_bug.cgi?id=132383
32286
32287        Reviewed by Anders Carlsson.
32288
32289        Make sure to cache the offset of the multicolumn set from its parent and then
32290        add that in to the translation offset.
32291
32292        * rendering/RenderMultiColumnFlowThread.cpp:
32293        (WebCore::RenderMultiColumnFlowThread::mapAbsoluteToLocalPoint):
32294
322952014-04-30  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
32296
32297        Move removeEquivalentProperties functions to EditingStyle
32298        https://bugs.webkit.org/show_bug.cgi?id=131093
32299
32300        Reviewed by Csaba Osztrogonác.
32301
32302        A follow-up to r167967. Use single line declaration for template methods.
32303
32304        * editing/EditingStyle.h:
32305
323062014-04-30  Manuel Rego Casasnovas  <rego@igalia.com>
32307
32308        [CSS Grid Layout] Enable runtime feature by default
32309        https://bugs.webkit.org/show_bug.cgi?id=132189
32310
32311        Reviewed by Benjamin Poulain.
32312
32313        * page/Settings.in: Set cssGridLayoutEnabled to true.
32314
323152014-04-30  Manuel Rego Casasnovas  <rego@igalia.com>
32316
32317        [CSS Grid Layout] Wrap some specific grid code under compilation flag
32318        https://bugs.webkit.org/show_bug.cgi?id=132341
32319
32320        Reviewed by Benjamin Poulain.
32321
32322        Some static variables in RenderBox are only used for CSS Grid Layout code. Wrap them and the related methods
32323        under ENABLE_CSS_GRID_LAYOUT compilation flag.
32324
32325        * rendering/RenderBox.cpp:
32326        (WebCore::RenderBox::willBeDestroyed):
32327        (WebCore::RenderBox::containingBlockLogicalWidthForContent):
32328        (WebCore::RenderBox::containingBlockLogicalHeightForContent):
32329        (WebCore::RenderBox::perpendicularContainingBlockLogicalHeight):
32330        (WebCore::RenderBox::computePercentageLogicalHeight):
32331        * rendering/RenderBox.h:
32332
323332014-04-29  Commit Queue  <commit-queue@webkit.org>
32334
32335        Unreviewed, rolling out r167962 and r167975.
32336        https://bugs.webkit.org/show_bug.cgi?id=132376
32337
32338        Mysteriously broke many tests (Requested by ap on #webkit).
32339
32340        Reverted changesets:
32341
32342        "[Mac, iOS] Support caption activation via JS
32343        webkitHasClosedCaptions method"
32344        https://bugs.webkit.org/show_bug.cgi?id=132320
32345        http://trac.webkit.org/changeset/167962
32346
32347        "Unreviewed test fix after r167962."
32348        http://trac.webkit.org/changeset/167975
32349
323502014-04-29  David Hyatt  <hyatt@apple.com>
32351
32352        [New Multicolumn] Multiple tests assert in RenderGeometryMap
32353        https://bugs.webkit.org/show_bug.cgi?id=132285
32354
32355        Reviewed by Simon Fraser.
32356
32357        Implement offsetFromContainer for RenderMultiColumnFlowThread so that the
32358        geometry map gets the right offsets. This is really only relevant for the 
32359        geometry map, since I already overrode mapAbsoluteToLocalPoint and multicolumn
32360        flow threads are repaint containers (so mapLocalToAbsolute never needs offsetFromContainer).
32361
32362        * rendering/RenderMultiColumnFlowThread.cpp:
32363        (WebCore::RenderMultiColumnFlowThread::offsetFromContainer):
32364        * rendering/RenderMultiColumnFlowThread.h:
32365
323662014-04-29  Benjamin Poulain  <bpoulain@apple.com>
32367
32368        [iOS][WK2] When pageScaleFactor * deviceScaleFactor = 1, the tile grid is completely messed up
32369        https://bugs.webkit.org/show_bug.cgi?id=132368
32370
32371        Reviewed by Simon Fraser.
32372
32373        * platform/graphics/ca/mac/TileController.mm:
32374        (WebCore::TileController::TileController):
32375        The initial device scale factor was initialized to 1. We were returning the wrong zoomedOutContentsScale() and
32376        contentsScale() on retina devices until the next successful scale update.
32377
323782014-04-29  Alexey Proskuryakov  <ap@apple.com>
32379
32380        Remove an unused override of BlobRegistryImpl::appendStorageItems
32381        https://bugs.webkit.org/show_bug.cgi?id=132365
32382
32383        Reviewed by Andreas Kling.
32384
32385        * platform/network/BlobRegistryImpl.cpp:
32386        (WebCore::BlobRegistryImpl::appendStorageItems): Deleted.
32387        * platform/network/BlobRegistryImpl.h:
32388
323892014-04-29  Eric Carlson  <eric.carlson@apple.com>
32390
32391        [Mac] tag the video layers with descriptive name to aid debugging
32392        https://bugs.webkit.org/show_bug.cgi?id=132371
32393
32394        Reviewed by Darin Adler.
32395
32396        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
32397        (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Set the AVPlayerLayer
32398            name in a debug build.
32399
324002014-04-29  Nikos Andronikos  <nikos.andronikos-webkit@cisra.canon.com.au>
32401
32402        [GTK][cmake] CMake variable (non)expansion causing 'File name too long' build error.
32403        https://bugs.webkit.org/show_bug.cgi?id=132244
32404
32405        Reviewed by Martin Robinson.
32406
32407        Removing quotes around include directory variable ${WebCore_INCLUDE_DIRECTORIES} in
32408        the include_directories cmake macro enables the variable to be expanded correctly.
32409
32410        No tests created as this fixes a platform specific build issue.
32411
32412        * PlatformGTK.cmake:
32413
324142014-04-29  Brent Fulgham  <bfulgham@apple.com>
32415
32416        Unreviewed test fix after r167962.
32417        * Modules/mediacontrols/mediaControlsApple.css:
32418        (.hidden): Use common '.hidden' class for controls.
32419        (video::-webkit-media-text-track-container .hidden): Deleted.
32420
324212014-04-29  Brady Eidson  <beidson@apple.com>
32422
32423        Handle selection services menu.
32424        <rdar://problem/16727798> and https://bugs.webkit.org/show_bug.cgi?id=132362
32425
32426        Reviewed by Tim Horton.
32427
32428        * WebCore.exp.in:
32429
324302014-04-29  Myles C. Maxfield  <mmaxfield@apple.com>
32431
32432        Removing unused argument in InlineFlowBox::placeBoxesInInlineDirection()
32433        https://bugs.webkit.org/show_bug.cgi?id=132369
32434
32435        Reviewed by Darin Adler.
32436
32437        This was not caught by our compiler because placeBoxesInInlineDirection()
32438        is mutually-recursive with placeBoxRangeInInlineDirection().
32439
32440        No new tests are necessary because there should be no behavior change.
32441
32442        * rendering/InlineFlowBox.cpp:
32443        (WebCore::InlineFlowBox::placeBoxesInInlineDirection):
32444        (WebCore::InlineFlowBox::placeBoxRangeInInlineDirection):
32445        * rendering/InlineFlowBox.h:
32446        * rendering/RenderBlockLineLayout.cpp:
32447        (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForLine):
32448
324492014-04-29  Alex Christensen  <achristensen@webkit.org>
32450
32451        [WinCairo] Switch video from GStreamer to Media Foundation.
32452        https://bugs.webkit.org/show_bug.cgi?id=132358
32453
32454        Reviewed by Brent Fulgham.
32455
32456        * WebCore.vcxproj/WebCore.vcxproj:
32457        Removed dependencies on GStreamer.
32458
324592014-04-29  Simon Fraser  <simon.fraser@apple.com>
32460
32461        Remove some PLATFORM(IOS) #ifdefs related to hasAcceleratedTouchScrolling()
32462        https://bugs.webkit.org/show_bug.cgi?id=132353
32463
32464        Reviewed by Tim Horton & Darin Adler.
32465
32466        Minor cleanup and refactoring to remove #idefs.
32467
32468        * rendering/RenderLayer.cpp:
32469        (WebCore::RenderLayer::scrollTo): No need for this #ifdef, usesCompositedScrolling()
32470        gives the right answser already.
32471        (WebCore::RenderLayer::visibleContentRectInternal): Use showsOverflowControls() to
32472        avoid #ifdef.
32473        (WebCore::RenderLayer::invalidateScrollbarRect): Ditto.
32474        (WebCore::RenderLayer::invalidateScrollCornerRect): Ditto.
32475        (WebCore::RenderLayer::verticalScrollbarWidth): Ditto.
32476        (WebCore::RenderLayer::horizontalScrollbarHeight): Ditto.
32477        (WebCore::RenderLayer::showsOverflowControls): Return false on iOS.
32478        (WebCore::RenderLayer::paintOverflowControls): Ditto.
32479        (WebCore::RenderLayer::calculateClipRects): Ditto.
32480        * rendering/RenderLayer.h:
32481        * rendering/RenderLayerBacking.cpp:
32482        (WebCore::layerOrAncestorIsTransformedOrUsingCompositedScrolling):
32483        Just #ifdef in side of this function rather than having two similar functions.
32484        (WebCore::RenderLayerBacking::shouldClipCompositedBounds):
32485        (WebCore::hasNonZeroTransformOrigin):
32486        (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration): Use a local bool
32487        to reduce #ifdefs.
32488        (WebCore::layerOrAncestorIsTransformedOrScrolling): Deleted.
32489
324902014-04-29  Simon Fraser  <simon.fraser@apple.com>
32491
32492        Remove Settings::compositedScrollingForFramesEnabled
32493        https://bugs.webkit.org/show_bug.cgi?id=132352
32494
32495        Reviewed by Andreas Kling.
32496
32497        The usesCompositedScrolling setting was only used by Chromium, so
32498        remove it and associated code.
32499
32500        * page/FrameView.cpp:
32501        (WebCore::FrameView::usesCompositedScrolling): Deleted.
32502        * page/FrameView.h:
32503        * page/Settings.in:
32504        * rendering/RenderLayerCompositor.cpp:
32505        (WebCore::RenderLayerCompositor::updateScrollLayerPosition):
32506
325072014-04-29  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
32508
32509        Move removeEquivalentProperties functions to EditingStyle
32510        https://bugs.webkit.org/show_bug.cgi?id=131093
32511
32512        Reviewed by Darin Adler.
32513
32514        Moved the removeEquivalentProperties functions
32515        from StyleProperties to EditingStyle class.
32516
32517        * css/StyleProperties.cpp:
32518        (WebCore::MutableStyleProperties::removeEquivalentProperties): Deleted.
32519        * css/StyleProperties.h:
32520        * editing/EditingStyle.cpp:
32521        (WebCore::EditingStyle::removeStyleAddedByNode):
32522        (WebCore::EditingStyle::removeStyleConflictingWithStyleOfNode):
32523        (WebCore::EditingStyle::prepareToApplyAt):
32524        (WebCore::EditingStyle::removeEquivalentProperties):
32525        (WebCore::extractPropertiesNotIn):
32526        * editing/EditingStyle.h:
32527
325282014-04-29  David Hyatt  <hyatt@apple.com>
32529
32530        [New Multicolumn] Implement support for compositing
32531        https://bugs.webkit.org/show_bug.cgi?id=132298
32532
32533        Reviewed by Simon Fraser.
32534
32535        * rendering/RenderLayer.cpp:
32536        (WebCore::accumulateOffsetTowardsAncestor):
32537        Add in a case for the new columns that calls into the multi-column flow thread
32538        to get an offset to adjust by.
32539
32540        * rendering/RenderLayerBacking.cpp:
32541        (WebCore::RenderLayerBacking::adjustAncestorCompositingBoundsForFlowThread):
32542        Make sure this code only runs for named flow threads.
32543
32544        * rendering/RenderLayerCompositor.cpp:
32545        (WebCore::RenderLayerCompositor::canBeComposited):
32546        Turn on compositing support for in-flow RenderFlowThreads instead of always returning
32547        false
32548
32549        * rendering/RenderMultiColumnFlowThread.cpp:
32550        (WebCore::RenderMultiColumnFlowThread::physicalTranslationOffsetFromFlowToRegion):
32551        Changed this function to fix a couple of bugs exposed by compositing/columns tests. Its
32552        end goal is the same, but the approach is improved.
32553
32554        * rendering/RenderMultiColumnSet.cpp:
32555        (WebCore::RenderMultiColumnSet::endFlow):
32556        Don't pad out to a multiple of column height. You can't flip around a flow thread
32557        to get back to accurate physical coordinates if bogus padding is introduced. This
32558        seemed to have no effect on any layout tests when removed, so I don't think it 
32559        was really serving any useful purpose.
32560
32561        (WebCore::RenderMultiColumnSet::columnTranslationForOffset):
32562        Don't factor in the overall flow thread portion, since this is handled by the callers
32563        now.
32564
32565        (WebCore::RenderMultiColumnSet::adjustRegionBoundsFromFlowThreadPortionRect):
32566        * rendering/RenderMultiColumnSet.h:
32567        Change this function to be ASSERT_NOT_REACHED(), since we want to know if someone calls
32568        it. It only runs for named flow thread compositing code, so it would be a mistake if
32569        this ever gets invoked.
32570
325712014-04-29  Mark Hahnenberg  <mhahnenberg@apple.com>
32572
32573        JSProxies should be cacheable
32574        https://bugs.webkit.org/show_bug.cgi?id=132351
32575
32576        Reviewed by Geoffrey Garen.
32577
32578        No new tests.
32579
32580        Whenever we encounter a proxy in an inline cache we should try to cache on the 
32581        proxy's target instead of giving up.
32582
32583        This patch adds support for a simple "recursive" inline cache if the base object
32584        we're accessing is a pure forwarding proxy. JSGlobalObject and its subclasses 
32585        are the only ones to benefit from this right now.
32586
32587        This is performance neutral on the benchmarks we track. Currently we won't
32588        cache on JSDOMWindow due to HasImpureGetOwnPropertySlot, but this issue will be fixed soon.
32589
32590        * bindings/js/JSDOMWindowShell.h:
32591        (WebCore::JSDOMWindowShell::createStructure):
32592
325932014-04-29  Brent Fulgham  <bfulgham@apple.com>
32594
32595        [Mac, iOS] Support caption activation via JS webkitHasClosedCaptions method
32596        https://bugs.webkit.org/show_bug.cgi?id=132320
32597
32598        Reviewed by Eric Carlson.
32599
32600        * Modules/mediacontrols/mediaControlsApple.css:
32601        (video::-webkit-media-text-track-container .hidden): Added.
32602        * html/HTMLMediaElement.cpp:
32603        (WebCore::HTMLMediaElement::configureTextTrackGroup): Added call to
32604        new 'updateCaptionsContainer'.
32605        (WebCore::HTMLMediaElement::updateCaptionContainer): Added.
32606        * html/HTMLMediaElement.h:
32607        * html/shadow/MediaControlElements.cpp:
32608        (WebCore::MediaControlTextTrackContainerElement::hide): Use CSS class .hidden instead of
32609        hard-coded "display:none".
32610        (WebCore::MediaControlTextTrackContainerElement::show): Ditto.
32611        * html/shadow/MediaControlElements.h:
32612
326132014-04-28  Roger Fong  <roger_fong@apple.com>
32614
32615        Plugins hidden by images should autoplay.
32616        https://bugs.webkit.org/show_bug.cgi?id=132222.
32617        <rdar://problem/16653536>
32618
32619        Reviewed by Jon Lee and Darin Adler.
32620
32621        * WebCore.exp.in: Add exports needed by WK2.
32622
326232014-04-29  Filip Pizlo  <fpizlo@apple.com>
32624
32625        Use LLVM as a backend for the fourth-tier DFG JIT (a.k.a. the FTL JIT)
32626        https://bugs.webkit.org/show_bug.cgi?id=112840
32627
32628        Rubber stamped by Geoffrey Garen.
32629
32630        It already has a lot of tests.
32631
32632        * Configurations/FeatureDefines.xcconfig:
32633
326342014-04-29  Brady Eidson  <beidson@apple.com>
32635
32636        Change Image Controls replacement to use selection and paste
32637        <rdar://problem/16302722> and https://bugs.webkit.org/show_bug.cgi?id=131992
32638
32639        Reviewed by Tim Horton.
32640
32641        * WebCore.exp.in: Remove deleted symbol.
32642
32643        * html/shadow/mac/ImageControlsButtonElementMac.cpp:
32644        (WebCore::ImageControlsButtonElementMac::defaultEventHandler):
32645
32646        * page/ContextMenuController.cpp:
32647        (WebCore::ContextMenuController::showImageControlsMenu): Select the image element
32648          before showing the menu.
32649        (WebCore::ContextMenuController::replaceControlledImage): Deleted.
32650        * page/ContextMenuController.h:
32651
326522014-04-29  Jer Noble  <jer.noble@apple.com>
32653
32654        [iOS] Remove workaround for <rdar://problem/16578727>.
32655        https://bugs.webkit.org/show_bug.cgi?id=132338
32656
32657        Reviewed by Darin Adler.
32658
32659        Now that <rdar://problem/16578727> is fixed, remove the workaround by replacing the
32660        call to -_updatePlaybackControlsViewController with one to -layoutIfNeeded.
32661
32662        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
32663        (WebVideoFullscreenInterfaceAVKit::enterFullscreen):
32664
326652014-04-29  Zan Dobersek  <zdobersek@igalia.com>
32666
32667        ScriptExecutionContext::Task should work well with C++11 lambdas
32668        https://bugs.webkit.org/show_bug.cgi?id=129795
32669
32670        Reviewed by Darin Adler.
32671
32672        Instead of having classes that subclass ScriptExecutionContext::Task and override
32673        the performTask(ScriptExecutionContext*) method, have the ScriptExecutionContext::Task
32674        take in a std::function<void (ScriptExecutionContext*)>-like object trough the constructor
32675        which would contain the code currently kept in the performTask() methods.
32676
32677        This enables inlining C++11 lambdas into ScriptExecutionContext::postTask() calls. For
32678        cleanup tasks, the Task object can be implicitly constructed by using the initializer list
32679        constructor with the first argument being the ScriptExecutionContext::Task::CleanupTask tag.
32680        The ScriptExecutionContext class remains non-copyable and now stores the passed-in invokable
32681        object in the std::function wrapper, along with a boolean member that indicates whether the
32682        task is of cleanup nature.
32683
32684        * Modules/quota/StorageErrorCallback.cpp:
32685        (WebCore::StorageErrorCallback::CallbackTask::CallbackTask):
32686        (WebCore::StorageErrorCallback::CallbackTask::performTask): Deleted.
32687        * Modules/quota/StorageErrorCallback.h:
32688        (WebCore::StorageErrorCallback::CallbackTask::create): Deleted.
32689        * Modules/webdatabase/Database.cpp:
32690        (WebCore::Database::~Database):
32691        (WebCore::Database::runTransaction):
32692        (WebCore::Database::scheduleTransactionCallback):
32693        (WebCore::DerefContextTask::create): Deleted.
32694        (WebCore::DerefContextTask::performTask): Deleted.
32695        (WebCore::DerefContextTask::isCleanupTask): Deleted.
32696        (WebCore::DerefContextTask::DerefContextTask): Deleted.
32697        (WebCore::callTransactionErrorCallback): Deleted.
32698        (WebCore::DeliverPendingCallbackTask::create): Deleted.
32699        (WebCore::DeliverPendingCallbackTask::performTask): Deleted.
32700        (WebCore::DeliverPendingCallbackTask::DeliverPendingCallbackTask): Deleted.
32701        * Modules/webdatabase/DatabaseManager.cpp:
32702        (WebCore::DatabaseManager::openDatabase):
32703        (WebCore::DatabaseCreationCallbackTask::create): Deleted.
32704        (WebCore::DatabaseCreationCallbackTask::performTask): Deleted.
32705        (WebCore::DatabaseCreationCallbackTask::DatabaseCreationCallbackTask): Deleted.
32706        * Modules/webdatabase/DatabaseSync.cpp:
32707        (WebCore::CloseSyncDatabaseOnContextThreadTask::create): Deleted.
32708        (WebCore::CloseSyncDatabaseOnContextThreadTask::performTask): Deleted.
32709        (WebCore::CloseSyncDatabaseOnContextThreadTask::CloseSyncDatabaseOnContextThreadTask): Deleted.
32710        * Modules/webdatabase/SQLCallbackWrapper.h:
32711        (WebCore::SQLCallbackWrapper::clear):
32712        (WebCore::SQLCallbackWrapper::SafeReleaseTask::create): Deleted.
32713        (WebCore::SQLCallbackWrapper::SafeReleaseTask::performTask): Deleted.
32714        (WebCore::SQLCallbackWrapper::SafeReleaseTask::isCleanupTask): Deleted.
32715        (WebCore::SQLCallbackWrapper::SafeReleaseTask::SafeReleaseTask): Deleted.
32716        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
32717        (WebCore::ThreadableWebSocketChannelClientWrapper::didConnect):
32718        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessage):
32719        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
32720        (WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmount):
32721        (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshake):
32722        (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
32723        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageError):
32724        (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks):
32725        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
32726        * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
32727        (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadInitialize):
32728        (WebCore::WorkerThreadableWebSocketChannel::mainThreadDestroy):
32729        (WebCore::WorkerThreadableWebSocketChannel::Bridge::disconnect):
32730        (WebCore::WorkerThreadableWebSocketChannel::WorkerGlobalScopeDidInitializeTask::create): Deleted.
32731        (WebCore::WorkerThreadableWebSocketChannel::WorkerGlobalScopeDidInitializeTask::~WorkerGlobalScopeDidInitializeTask): Deleted.
32732        (WebCore::WorkerThreadableWebSocketChannel::WorkerGlobalScopeDidInitializeTask::WorkerGlobalScopeDidInitializeTask): Deleted.
32733        * Modules/websockets/WorkerThreadableWebSocketChannel.h:
32734        * bindings/js/JSCallbackData.h:
32735        (WebCore::DeleteCallbackDataTask::DeleteCallbackDataTask):
32736        (WebCore::DeleteCallbackDataTask::create): Deleted.
32737        (WebCore::DeleteCallbackDataTask::performTask): Deleted.
32738        (WebCore::DeleteCallbackDataTask::isCleanupTask): Deleted.
32739        * bindings/js/JSDOMGlobalObjectTask.cpp:
32740        (WebCore::JSGlobalObjectTask::JSGlobalObjectTask):
32741        (WebCore::JSGlobalObjectTask::~JSGlobalObjectTask): Deleted.
32742        (WebCore::JSGlobalObjectTask::performTask): Deleted.
32743        * bindings/js/JSDOMGlobalObjectTask.h:
32744        * bindings/js/JSDOMWindowBase.cpp:
32745        (WebCore::JSDOMWindowBase::queueTaskToEventLoop):
32746        * bindings/js/JSWorkerGlobalScopeBase.cpp:
32747        (WebCore::JSWorkerGlobalScopeBase::queueTaskToEventLoop):
32748        * bindings/scripts/CodeGeneratorJS.pm:
32749        * bindings/scripts/test/JS/JSTestCallback.cpp:
32750        (WebCore::JSTestCallback::~JSTestCallback):
32751        (GenerateCallbackImplementation):
32752        * dom/CrossThreadTask.h:
32753        (WebCore::CrossThreadTask1::performTask):
32754        (WebCore::CrossThreadTask2::performTask):
32755        (WebCore::CrossThreadTask3::performTask):
32756        (WebCore::CrossThreadTask4::performTask):
32757        (WebCore::CrossThreadTask5::performTask):
32758        (WebCore::CrossThreadTask6::performTask):
32759        (WebCore::CrossThreadTask7::performTask):
32760        (WebCore::CrossThreadTask8::performTask):
32761        (WebCore::createCallbackTask):
32762        (WebCore::CrossThreadTask1::create): Deleted.
32763        (WebCore::CrossThreadTask2::create): Deleted.
32764        (WebCore::CrossThreadTask3::create): Deleted.
32765        (WebCore::CrossThreadTask4::create): Deleted.
32766        (WebCore::CrossThreadTask5::create): Deleted.
32767        (WebCore::CrossThreadTask6::create): Deleted.
32768        (WebCore::CrossThreadTask7::create): Deleted.
32769        (WebCore::CrossThreadTask8::create): Deleted.
32770        * dom/Document.cpp:
32771        (WebCore::Document::addConsoleMessage):
32772        (WebCore::Document::addMessage):
32773        (WebCore::Document::postTask):
32774        (WebCore::Document::pendingTasksTimerFired):
32775        (WebCore::PerformTaskContext::PerformTaskContext): Deleted.
32776        (WebCore::Document::didReceiveTask): Deleted.
32777        * dom/Document.h:
32778        * dom/ScriptExecutionContext.cpp:
32779        (WebCore::ScriptExecutionContext::processMessagePortMessagesSoon):
32780        (WebCore::ScriptExecutionContext::timerAlignmentInterval):
32781        (WebCore::ProcessMessagesSoonTask::create): Deleted.
32782        (WebCore::ScriptExecutionContext::AddConsoleMessageTask::performTask): Deleted.
32783        (WebCore::ScriptExecutionContext::Task::~Task): Deleted.
32784        * dom/ScriptExecutionContext.h:
32785        (WebCore::ScriptExecutionContext::Task::Task):
32786        (WebCore::ScriptExecutionContext::Task::performTask):
32787        (WebCore::ScriptExecutionContext::Task::isCleanupTask):
32788        (WebCore::ScriptExecutionContext::AddConsoleMessageTask::AddConsoleMessageTask):
32789        (WebCore::ScriptExecutionContext::AddConsoleMessageTask::create): Deleted.
32790        * dom/StringCallback.cpp:
32791        (WebCore::StringCallback::scheduleCallback):
32792        * loader/appcache/ApplicationCacheGroup.cpp:
32793        (WebCore::ApplicationCacheGroup::postListenerTask):
32794        (WebCore::CallCacheListenerTask::create): Deleted.
32795        (WebCore::CallCacheListenerTask::CallCacheListenerTask): Deleted.
32796        * workers/DefaultSharedWorkerRepository.cpp:
32797        (WebCore::SharedWorkerProxy::postTaskToLoader):
32798        (WebCore::SharedWorkerProxy::postTaskForModeToWorkerGlobalScope):
32799        (WebCore::SharedWorkerConnectTask::SharedWorkerConnectTask):
32800        (WebCore::DefaultSharedWorkerRepository::workerScriptLoaded):
32801        (WebCore::DefaultSharedWorkerRepository::connectToWorker):
32802        (WebCore::SharedWorkerConnectTask::create): Deleted.
32803        (WebCore::SharedWorkerConnectTask::performTask): Deleted.
32804        * workers/WorkerEventQueue.cpp:
32805        (WebCore::WorkerEventQueue::EventDispatcher::EventDispatcher):
32806        (WebCore::WorkerEventQueue::EventDispatcher::~EventDispatcher):
32807        (WebCore::WorkerEventQueue::EventDispatcher::dispatch):
32808        (WebCore::WorkerEventQueue::enqueueEvent):
32809        (WebCore::WorkerEventQueue::cancelEvent):
32810        (WebCore::WorkerEventQueue::close):
32811        * workers/WorkerEventQueue.h:
32812        * workers/WorkerGlobalScope.cpp:
32813        (WebCore::WorkerGlobalScope::close):
32814        (WebCore::WorkerGlobalScope::postTask):
32815        (WebCore::WorkerGlobalScope::addConsoleMessage):
32816        (WebCore::WorkerGlobalScope::addMessage):
32817        (WebCore::CloseWorkerGlobalScopeTask::create): Deleted.
32818        (WebCore::CloseWorkerGlobalScopeTask::performTask): Deleted.
32819        (WebCore::CloseWorkerGlobalScopeTask::isCleanupTask): Deleted.
32820        * workers/WorkerGlobalScope.h:
32821        * workers/WorkerLoaderProxy.h:
32822        * workers/WorkerMessagingProxy.cpp:
32823        (WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
32824        (WebCore::WorkerMessagingProxy::postMessageToWorkerGlobalScope):
32825        (WebCore::WorkerMessagingProxy::postTaskForModeToWorkerGlobalScope):
32826        (WebCore::WorkerMessagingProxy::postTaskToLoader):
32827        (WebCore::WorkerMessagingProxy::postExceptionToWorkerObject):
32828        (WebCore::WorkerMessagingProxy::workerThreadCreated):
32829        (WebCore::WorkerMessagingProxy::notifyNetworkStateChange):
32830        (WebCore::WorkerMessagingProxy::workerGlobalScopeDestroyed):
32831        (WebCore::WorkerMessagingProxy::workerGlobalScopeClosed):
32832        (WebCore::WorkerMessagingProxy::postMessageToPageInspector):
32833        (WebCore::WorkerMessagingProxy::confirmMessageFromWorkerObject):
32834        (WebCore::WorkerMessagingProxy::reportPendingActivity):
32835        (WebCore::MessageWorkerGlobalScopeTask::create): Deleted.
32836        (WebCore::MessageWorkerGlobalScopeTask::MessageWorkerGlobalScopeTask): Deleted.
32837        (WebCore::MessageWorkerGlobalScopeTask::performTask): Deleted.
32838        (WebCore::MessageWorkerTask::create): Deleted.
32839        (WebCore::MessageWorkerTask::MessageWorkerTask): Deleted.
32840        (WebCore::MessageWorkerTask::performTask): Deleted.
32841        (WebCore::WorkerExceptionTask::create): Deleted.
32842        (WebCore::WorkerExceptionTask::WorkerExceptionTask): Deleted.
32843        (WebCore::WorkerExceptionTask::performTask): Deleted.
32844        (WebCore::WorkerGlobalScopeDestroyedTask::create): Deleted.
32845        (WebCore::WorkerGlobalScopeDestroyedTask::WorkerGlobalScopeDestroyedTask): Deleted.
32846        (WebCore::WorkerGlobalScopeDestroyedTask::performTask): Deleted.
32847        (WebCore::WorkerTerminateTask::create): Deleted.
32848        (WebCore::WorkerTerminateTask::WorkerTerminateTask): Deleted.
32849        (WebCore::WorkerTerminateTask::performTask): Deleted.
32850        (WebCore::WorkerThreadActivityReportTask::create): Deleted.
32851        (WebCore::WorkerThreadActivityReportTask::WorkerThreadActivityReportTask): Deleted.
32852        (WebCore::WorkerThreadActivityReportTask::performTask): Deleted.
32853        (WebCore::PostMessageToPageInspectorTask::create): Deleted.
32854        (WebCore::PostMessageToPageInspectorTask::PostMessageToPageInspectorTask): Deleted.
32855        (WebCore::PostMessageToPageInspectorTask::performTask): Deleted.
32856        (WebCore::NotifyNetworkStateChangeTask::create): Deleted.
32857        (WebCore::NotifyNetworkStateChangeTask::NotifyNetworkStateChangeTask): Deleted.
32858        (WebCore::NotifyNetworkStateChangeTask::performTask): Deleted.
32859        * workers/WorkerMessagingProxy.h:
32860        * workers/WorkerRunLoop.cpp:
32861        (WebCore::WorkerRunLoop::postTask):
32862        (WebCore::WorkerRunLoop::postTaskAndTerminate):
32863        (WebCore::WorkerRunLoop::postTaskForMode):
32864        (WebCore::WorkerRunLoop::Task::create):
32865        (WebCore::WorkerRunLoop::Task::performTask):
32866        (WebCore::WorkerRunLoop::Task::Task):
32867        * workers/WorkerRunLoop.h:
32868        * workers/WorkerThread.cpp:
32869        (WebCore::WorkerThread::stop):
32870        (WebCore::WorkerThread::releaseFastMallocFreeMemoryInAllThreads):
32871        (WebCore::WorkerThreadShutdownFinishTask::create): Deleted.
32872        (WebCore::WorkerThreadShutdownFinishTask::performTask): Deleted.
32873        (WebCore::WorkerThreadShutdownFinishTask::isCleanupTask): Deleted.
32874        (WebCore::WorkerThreadShutdownStartTask::create): Deleted.
32875        (WebCore::WorkerThreadShutdownStartTask::performTask): Deleted.
32876        (WebCore::WorkerThreadShutdownStartTask::isCleanupTask): Deleted.
32877
328782014-04-29  Manuel Rego Casasnovas  <rego@igalia.com>
32879
32880        REGRESSION (r167879): Heap-use-after-free in WebCore::RenderFlexibleBox
32881        https://bugs.webkit.org/show_bug.cgi?id=132337
32882
32883        Reviewed by Simon Fraser.
32884
32885        From Blink r154582 by <jchaffraix@chromium.org>
32886
32887        This is a regression from the changes in OrderIterator. The issue is
32888        that we don't invalidate our iterator when a child is removed. This
32889        means that we could hold onto free'd memory until the next layout
32890        when we will recompute the iterator.
32891
32892        The solution is simple: just clear the memory when we remove a child.
32893
32894        Note that RenderGrid is not impacted by this bug as we don't use the
32895        iterator outside layout yet, but if we do it at some point the very same
32896        problem will arise, so the same treatment was applied to the class.
32897
32898        Test: fast/flexbox/order-iterator-crash.html
32899
32900        * rendering/OrderIterator.cpp:
32901        (WebCore::OrderIterator::invalidate): Clear m_children Vector.
32902        * rendering/OrderIterator.h:
32903        (WebCore::OrderIteratorPopulator::OrderIteratorPopulator): Use
32904        invalidate() method.
32905        * rendering/RenderFlexibleBox.cpp:
32906        (WebCore::RenderFlexibleBox::removeChild): Invalidate m_orderIterator.
32907        * rendering/RenderFlexibleBox.h: Add removeChild() signature.
32908        * rendering/RenderGrid.cpp: Invalidate m_orderIterator.
32909        (WebCore::RenderGrid::removeChild):
32910        * rendering/RenderGrid.h: Add removeChild() header.
32911
329122014-04-29  Enrica Casucci  <enrica@apple.com>
32913
32914        iOS build fix after http://trac.webkit.org/changeset/167937.
32915        Unreviewed.
32916
32917        * rendering/RenderThemeIOS.mm:
32918        (WebCore::RenderThemeIOS::adjustButtonStyle):
32919
329202014-04-29  Hans Muller  <hmuller@adobe.com>
32921
32922        [CSS Shapes] off-by-one error in Shape::createRasterShape()
32923        https://bugs.webkit.org/show_bug.cgi?id=132154
32924
32925        Reviewed by Bem Jones-Bey.
32926
32927        This is a port of a patch for a bug that was reported by and fixed in Blink by
32928        David Vest: https://codereview.chromium.org/237123002/.  Shape::createRasterShape()
32929        now consistently reports "end-point exclusive" intervals. Before the patch
32930        an entire row of pixels was above the shape-image-threshold, the interval's end
32931        index was reported as image.width. Now it's image.width + 1, which is consistent
32932        with the way the end index is reported if the last above threshold pixel is within
32933        an image row.
32934
32935        Two existing tests were revised to account for this change.
32936
32937        * rendering/shapes/RasterShape.cpp:
32938        (WebCore::RasterShape::getExcludedIntervals):
32939        * rendering/shapes/Shape.cpp:
32940        (WebCore::Shape::createRasterShape):
32941
329422014-04-29  Bem Jones-Bey  <bjonesbe@adobe.com>
32943
32944        Wrap CSS length conversion arguments in an object
32945        https://bugs.webkit.org/show_bug.cgi?id=131552
32946
32947        Reviewed by Andreas Kling.
32948
32949        This patch introduces a class CSSToLengthConversionData to wrap the
32950        data required to convert CSS lengths to Lengths. This simplifies the
32951        plumbing that goes on whenever we need to resolve CSS lengths and
32952        makes it easier to update the arguments needed for resolving these (in
32953        particular adding a RenderView for resolving viewport units at style
32954        recalc time; removing the computingFontSize bool also appears
32955        possible).
32956
32957        Note that the zoom argument, which was previously a float in some
32958        places and a double in others is now a float.
32959
32960        This is a port of a Blink patch by timloh@chromium.org.
32961
32962        No new tests, no behavior change.
32963
32964        * CMakeLists.txt:
32965        * WebCore.vcxproj/WebCore.vcxproj:
32966        * WebCore.xcodeproj/project.pbxproj:
32967        * css/BasicShapeFunctions.cpp:
32968        (WebCore::convertToLength):
32969        (WebCore::convertToLengthSize):
32970        (WebCore::convertToCenterCoordinate):
32971        (WebCore::cssValueToBasicShapeRadius):
32972        (WebCore::basicShapeForValue):
32973        * css/BasicShapeFunctions.h:
32974        * css/CSSCalculationValue.cpp:
32975        (WebCore::CSSCalcValue::computeLengthPx):
32976        (WebCore::determineCategory):
32977        * css/CSSCalculationValue.h:
32978        (WebCore::CSSCalcValue::createCalculationValue):
32979        * css/CSSGradientValue.cpp:
32980        (WebCore::CSSGradientValue::addStops):
32981        (WebCore::positionFromValue):
32982        (WebCore::CSSGradientValue::computeEndPoint):
32983        (WebCore::CSSLinearGradientValue::createGradient):
32984        (WebCore::CSSRadialGradientValue::resolveRadius):
32985        (WebCore::CSSRadialGradientValue::createGradient):
32986        * css/CSSGradientValue.h:
32987        * css/CSSPrimitiveValue.cpp:
32988        (WebCore::CSSPrimitiveValue::computeLength):
32989        (WebCore::CSSPrimitiveValue::computeLengthDouble):
32990        * css/CSSPrimitiveValue.h:
32991        * css/CSSPrimitiveValueMappings.h:
32992        (WebCore::CSSPrimitiveValue::convertToLength):
32993        * css/CSSToLengthConversionData.cpp: Added.
32994        (WebCore::CSSToLengthConversionData::zoom):
32995        * css/CSSToLengthConversionData.h: Added.
32996        (WebCore::CSSToLengthConversionData::CSSToLengthConversionData):
32997        (WebCore::CSSToLengthConversionData::style):
32998        (WebCore::CSSToLengthConversionData::rootStyle):
32999        (WebCore::CSSToLengthConversionData::computingFontSize):
33000        (WebCore::CSSToLengthConversionData::copyWithAdjustedZoom):
33001        * css/CSSToStyleMap.cpp:
33002        (WebCore::CSSToStyleMap::CSSToStyleMap):
33003        (WebCore::CSSToStyleMap::mapFillSize):
33004        (WebCore::CSSToStyleMap::mapFillXPosition):
33005        (WebCore::CSSToStyleMap::mapFillYPosition):
33006        (WebCore::CSSToStyleMap::mapNinePieceImageQuad):
33007        * css/CSSToStyleMap.h:
33008        (WebCore::CSSToStyleMap::CSSToStyleMap): Deleted.
33009        * css/DeprecatedStyleBuilder.cpp:
33010        (WebCore::ApplyPropertyAuto::applyValue):
33011        (WebCore::ApplyPropertyClip::convertToLength):
33012        (WebCore::ApplyPropertyLength::applyValue):
33013        (WebCore::ApplyPropertyBorderRadius::applyValue):
33014        (WebCore::ApplyPropertyComputeLength::applyValue):
33015        (WebCore::ApplyPropertyFontSize::applyValue):
33016        (WebCore::csstoLengthConversionDataWithTextZoomFactor):
33017        (WebCore::ApplyPropertyMarqueeIncrement::applyValue):
33018        (WebCore::ApplyPropertyLineHeight::applyValue):
33019        (WebCore::ApplyPropertyLineHeightForIOSTextAutosizing::applyValue):
33020        (WebCore::ApplyPropertyWordSpacing::applyValue):
33021        (WebCore::ApplyPropertyPageSize::mmLength):
33022        (WebCore::ApplyPropertyPageSize::inchLength):
33023        (WebCore::ApplyPropertyPageSize::applyValue):
33024        (WebCore::ApplyPropertyVerticalAlign::applyValue):
33025        (WebCore::ApplyPropertyClipPath::applyValue):
33026        (WebCore::ApplyPropertyShape::applyValue):
33027        (WebCore::ApplyPropertyTextIndent::applyValue):
33028        * css/MediaQueryEvaluator.cpp:
33029        (WebCore::colorMediaFeatureEval):
33030        (WebCore::color_indexMediaFeatureEval):
33031        (WebCore::monochromeMediaFeatureEval):
33032        (WebCore::orientationMediaFeatureEval):
33033        (WebCore::aspect_ratioMediaFeatureEval):
33034        (WebCore::device_aspect_ratioMediaFeatureEval):
33035        (WebCore::device_pixel_ratioMediaFeatureEval):
33036        (WebCore::resolutionMediaFeatureEval):
33037        (WebCore::gridMediaFeatureEval):
33038        (WebCore::computeLength):
33039        (WebCore::device_heightMediaFeatureEval):
33040        (WebCore::device_widthMediaFeatureEval):
33041        (WebCore::heightMediaFeatureEval):
33042        (WebCore::widthMediaFeatureEval):
33043        (WebCore::min_colorMediaFeatureEval):
33044        (WebCore::max_colorMediaFeatureEval):
33045        (WebCore::min_color_indexMediaFeatureEval):
33046        (WebCore::max_color_indexMediaFeatureEval):
33047        (WebCore::min_monochromeMediaFeatureEval):
33048        (WebCore::max_monochromeMediaFeatureEval):
33049        (WebCore::min_aspect_ratioMediaFeatureEval):
33050        (WebCore::max_aspect_ratioMediaFeatureEval):
33051        (WebCore::min_device_aspect_ratioMediaFeatureEval):
33052        (WebCore::max_device_aspect_ratioMediaFeatureEval):
33053        (WebCore::min_device_pixel_ratioMediaFeatureEval):
33054        (WebCore::max_device_pixel_ratioMediaFeatureEval):
33055        (WebCore::min_heightMediaFeatureEval):
33056        (WebCore::max_heightMediaFeatureEval):
33057        (WebCore::min_widthMediaFeatureEval):
33058        (WebCore::max_widthMediaFeatureEval):
33059        (WebCore::min_device_heightMediaFeatureEval):
33060        (WebCore::max_device_heightMediaFeatureEval):
33061        (WebCore::min_device_widthMediaFeatureEval):
33062        (WebCore::max_device_widthMediaFeatureEval):
33063        (WebCore::min_resolutionMediaFeatureEval):
33064        (WebCore::max_resolutionMediaFeatureEval):
33065        (WebCore::animationMediaFeatureEval):
33066        (WebCore::transitionMediaFeatureEval):
33067        (WebCore::transform_2dMediaFeatureEval):
33068        (WebCore::transform_3dMediaFeatureEval):
33069        (WebCore::view_modeMediaFeatureEval):
33070        (WebCore::video_playable_inlineMediaFeatureEval):
33071        (WebCore::hoverMediaFeatureEval):
33072        (WebCore::pointerMediaFeatureEval):
33073        (WebCore::MediaQueryEvaluator::eval):
33074        * css/SVGCSSStyleSelector.cpp:
33075        (WebCore::StyleResolver::applySVGProperty):
33076        * css/StyleResolver.cpp:
33077        (WebCore::StyleResolver::State::clear):
33078        (WebCore::StyleResolver::State::initForStyleResolve):
33079        (WebCore::StyleResolver::convertToIntLength):
33080        (WebCore::StyleResolver::convertToFloatLength):
33081        (WebCore::createGridTrackBreadth):
33082        (WebCore::StyleResolver::applyProperty):
33083        (WebCore::StyleResolver::createFilterOperations):
33084        * css/StyleResolver.h:
33085        (WebCore::StyleResolver::State::setStyle):
33086        (WebCore::StyleResolver::State::cssToLengthConversionData):
33087        * css/TransformFunctions.cpp:
33088        (WebCore::convertToFloatLength):
33089        (WebCore::transformsForValue):
33090        * css/TransformFunctions.h:
33091        * css/WebKitCSSMatrix.cpp:
33092        (WebCore::WebKitCSSMatrix::setMatrixValue):
33093        * rendering/RenderThemeIOS.mm:
33094        (WebCore::applyCommonButtonPaddingToStyle):
33095        (WebCore::RenderThemeIOS::adjustButtonStyle):
33096
330972014-04-29  Zoltan Horvath  <zoltan@webkit.org>
33098
33099        [CSS Shapes] complex calc args for inset round vanish
33100        https://bugs.webkit.org/show_bug.cgi?id=132293
33101
33102        Reviewed by Bem Jones-Bey.
33103
33104        In order to use calc in the rounded parameters for inset shapes, we need
33105        to pass RenderStyle for the value creation as we did for the width arguments.
33106        Without taking RenderStyle into account, we hit an assert not reache
33107        in CSSPrimitiveValue::init in the debug builds.
33108
33109        I've added new parsing test.
33110
33111        * css/BasicShapeFunctions.cpp:
33112        (WebCore::valueForBasicShape):
33113        * css/CSSPrimitiveValue.cpp:
33114        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
33115        (WebCore::CSSPrimitiveValue::init):
33116        * css/CSSPrimitiveValue.h:
33117        (WebCore::CSSPrimitiveValue::create):
33118        * css/CSSValuePool.h:
33119        (WebCore::CSSValuePool::createValue):
33120
331212014-04-29  Zoltan Horvath  <zoltan@webkit.org>
33122
33123        [CSS Shapes] complex calc values for shape-margin return null for computed style
33124        https://bugs.webkit.org/show_bug.cgi?id=132313
33125
33126        Reviewed by Bem Jones-Bey.
33127
33128        We need to pass RenderStyle* to the cssValuePool when parsing
33129        shape-margin in order to use calc() as a parameter.
33130
33131        I've added the new test case to parsing-shape-margin.html
33132
33133        * css/CSSComputedStyleDeclaration.cpp:
33134        (WebCore::ComputedStyleExtractor::propertyValue):
33135
331362014-04-29  Chris Fleizach  <cfleizach@apple.com>
33137
33138        AX: Row span info is wrong for table cells when a footer section is placed above a body section
33139        https://bugs.webkit.org/show_bug.cgi?id=131832
33140
33141        Reviewed by Mario Sanchez Prada.
33142
33143        If a <footer> section is placed before the body, it renders AX row information and order incorrectly.
33144        This also affects ARIA tables because they add their children by looking at renderer children, instead
33145        interrogating the RenderTable directly.
33146
33147        Test: accessibility/table-with-footer-section-above-body.html
33148
33149        * accessibility/AccessibilityARIAGrid.cpp:
33150        (WebCore::AccessibilityARIAGrid::addTableCellChild):
33151        (WebCore::AccessibilityARIAGrid::addChildren):
33152        * accessibility/AccessibilityTable.cpp:
33153        (WebCore::AccessibilityTable::addChildren):
33154        (WebCore::AccessibilityTable::addChildrenFromSection):
33155        * accessibility/AccessibilityTable.h:
33156        * accessibility/AccessibilityTableCell.cpp:
33157        (WebCore::AccessibilityTableCell::rowIndexRange):
33158        (WebCore::AccessibilityTableCell::columnIndexRange):
33159
331602014-04-29  Chris Fleizach  <cfleizach@apple.com>
33161
33162        AX: SpeechSynthesisUtterance cannot addEventListener
33163        https://bugs.webkit.org/show_bug.cgi?id=132321
33164
33165        Reviewed by Mario Sanchez Prada.
33166
33167        Modified an existing test (speech-synthesis-speak.html) to use addEventTarget.
33168
33169        * Modules/speech/SpeechSynthesisUtterance.idl:
33170
331712014-04-29  Hans Muller  <hmuller@adobe.com>
33172
33173        [CSS Shapes] shape-outside polygon fails when first vertex is 0,0
33174        https://bugs.webkit.org/show_bug.cgi?id=132132
33175
33176        Reviewed by Bem Jones-Bey.
33177
33178        ShapeInterval now distinguishes between x1==x2 - isEmpty() and x1,x2 haven't been
33179        set yet - isUndefined(). Removed the ShapeInterval setX1() and setX2() methods, since
33180        they're no longer used.
33181
33182        The polygon algorithm for computing excluded intervals now ignores horizontal
33183        edges. It also ignores edges whose lower vertex matches the top of the line, if
33184        the edge's Y direction is upwards (away from the top of the line). The rationale
33185        for this was explained here:
33186        http://hansmuller-webkit.blogspot.com/2012/11/revised-horizontal-box-algorithm.html
33187
33188        Test: fast/shapes/shape-outside-floats/shape-outside-polygon-zero-vertex.html
33189
33190        * rendering/shapes/PolygonShape.cpp:
33191        (WebCore::OffsetPolygonEdge::clippedEdgeXRange):
33192        (WebCore::PolygonShape::getExcludedIntervals):
33193        * rendering/shapes/ShapeInterval.h:
33194        (WebCore::ShapeInterval::ShapeInterval):
33195        (WebCore::ShapeInterval::isUndefined):
33196        (WebCore::ShapeInterval::x1):
33197        (WebCore::ShapeInterval::x2):
33198        (WebCore::ShapeInterval::width):
33199        (WebCore::ShapeInterval::isEmpty):
33200        (WebCore::ShapeInterval::setX1):
33201        (WebCore::ShapeInterval::setX2):
33202        (WebCore::ShapeInterval::overlaps):
33203        (WebCore::ShapeInterval::contains):
33204        (WebCore::ShapeInterval::unite):
33205
332062014-04-29  Andrei Bucur  <abucur@adobe.com>
33207
33208        [CSS Regions] Fix getClientRects() for content nodes
33209        https://bugs.webkit.org/show_bug.cgi?id=117407
33210
33211        Reviewed by David Hyatt.
33212
33213        This patch modifies getClientRects() to return a list of fragments
33214        for a fragmented box instead of a single rectangle positioned inside
33215        the region where the box center would appear.
33216
33217        The approach is to split the border box of the element in regions using
33218        the layout positioning. Then each fragment is mapped to the view coordinates
33219        and the result added to the list of rectangles. To preserve the originating
33220        region when mapping the fragment through the ancestor tree I've introduced
33221        the concept of a current region. The current region is stored inside a
33222        CurrentRenderRegionMaintainer object, created whenever an algorithm needing
33223        it needs to run. When the maintainer is destroyed, the cleanup is made
33224        automatically. The RenderFlowThread holds a pointer to this structure for
33225        easy access.
33226
33227        Tests: fast/regions/cssom/client-rects-fixed-content.html
33228               fast/regions/cssom/client-rects-forced-breaks.html
33229               fast/regions/cssom/client-rects-inline-complex.html
33230               fast/regions/cssom/client-rects-inline.html
33231               fast/regions/cssom/client-rects-nested-regions.html
33232               fast/regions/cssom/client-rects-positioned.html
33233               fast/regions/cssom/client-rects-relative-position.html
33234               fast/regions/cssom/client-rects-simple-block.html
33235               fast/regions/cssom/client-rects-transforms.html
33236               fast/regions/cssom/client-rects-unsplittable-float.html
33237
33238        * rendering/RenderBlock.cpp:
33239        (WebCore::RenderBlock::absoluteQuads): Split the box in fragments.
33240        * rendering/RenderBox.cpp:
33241        (WebCore::RenderBox::absoluteQuads): Split the box in fragments.
33242        * rendering/RenderFlowThread.cpp:
33243        (WebCore::RenderFlowThread::RenderFlowThread):
33244        (WebCore::RenderFlowThread::mapFromFlowToRegion):
33245        (WebCore::RenderFlowThread::mapLocalToContainer):
33246        (WebCore::RenderFlowThread::currentRegion):
33247        * rendering/RenderFlowThread.h:
33248        * rendering/RenderNamedFlowFragment.cpp:
33249        (WebCore::RenderNamedFlowFragment::absoluteQuadsForBoxInRegion): Get
33250        the fragments for this box in the region.
33251        * rendering/RenderNamedFlowFragment.h:
33252        * rendering/RenderNamedFlowThread.cpp:
33253        (WebCore::RenderNamedFlowThread::absoluteQuadsForBox): Virtual function
33254        that can be used to implement fragments to client rects mapping.
33255        * rendering/RenderNamedFlowThread.h:
33256        * rendering/RenderRegion.cpp:
33257        (WebCore::RenderRegion::rectFlowPortionForBox): Small change to correctly
33258        map empty rectangles to containers.
33259        (WebCore::CurrentRenderRegionMaintainer::CurrentRenderRegionMaintainer):
33260        (WebCore::CurrentRenderRegionMaintainer::~CurrentRenderRegionMaintainer):
33261        * rendering/RenderRegion.h:
33262        (WebCore::RenderRegion::absoluteQuadsForBoxInRegion):
33263        (WebCore::CurrentRenderRegionMaintainer::region):
33264
332652014-04-29  Andrei Bucur  <abucur@adobe.com>
33266
33267        Store the containing region map inside the flow thread
33268        https://bugs.webkit.org/show_bug.cgi?id=131647
33269
33270        Reviewed by Mihnea Ovidenie.
33271
33272        The patch moves the containing region map inside the flow thread where
33273        it can be better handled in case the region chain changes and the map
33274        needs to be cleared.
33275
33276        As a result of this move we are able to also cleanup the lines region
33277        information of a block flow when it is removed from the tree.
33278
33279        Test: fast/regions/inline-strike-through.html
33280
33281        * rendering/InlineFlowBox.h:
33282        (WebCore::InlineFlowBox::InlineFlowBox):
33283        * rendering/RenderBlockLineLayout.cpp:
33284        (WebCore::RenderBlockFlow::addOverflowFromInlineChildren):
33285        * rendering/RenderFlowThread.cpp:
33286        (WebCore::RenderFlowThread::removeFlowChildInfo):
33287        (WebCore::RenderFlowThread::invalidateRegions):
33288        (WebCore::RenderFlowThread::removeLineRegionInfo):
33289        (WebCore::RenderFlowThread::checkLinesConsistency):
33290        (WebCore::RenderFlowThread::containingRegionMap):
33291        * rendering/RenderFlowThread.h:
33292        * rendering/RootInlineBox.cpp:
33293        (WebCore::containingRegionMap):
33294        (WebCore::RootInlineBox::~RootInlineBox):
33295        (WebCore::RootInlineBox::paint):
33296        (WebCore::RootInlineBox::containingRegion):
33297        (WebCore::RootInlineBox::clearContainingRegion):
33298        (WebCore::RootInlineBox::setContainingRegion):
33299
333002014-04-28  Benjamin Poulain  <benjamin@webkit.org>
33301
33302        SelectorCodeGenerator::generateElementIsNthChild() leaks the parent register :nth-child() is non-filtering
33303        https://bugs.webkit.org/show_bug.cgi?id=132311
33304
33305        Reviewed by Andreas Kling.
33306
33307        In two cases, the parent register was never returned to the register allocator:
33308        -Non filtering selectors (the early return).
33309        -Non marking selectors (at the moment: only querySelector API).
33310
33311        Unfortunately, generateElementIsNthChild() makes function call, which forces us to do this manual allocation
33312        of the parentElement register. Long term, I want RegisterAllocator and FunctionCall to have a special type for that.
33313
33314        Test: fast/selectors/several-nth-child.html
33315
33316        * cssjit/SelectorCompiler.cpp:
33317        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
33318
333192014-04-28  Yusuke Suzuki  <utatane.tea@gmail.com>
33320
33321        CSS JIT: backtracking with current / parent element for child
33322        https://bugs.webkit.org/show_bug.cgi?id=132057
33323
33324        Reviewed by Benjamin Poulain.
33325
33326        Calculate appropriate backtracking start height from the closest
33327        descendant. And at first, we use it for a simple optimization.
33328
33329        1. When backtracking start height equals to current height, we
33330        can simply jump to a descendant element check phase.
33331        2. When backtracking start height equals to current height + 1, we
33332        can simply jump to a descendant element traversing phase.
33333
33334        We can apply this optimization to fragments with adjacent combinators.
33335        But, in the meantime, we start to implement it for a fragment with
33336        child combinator.
33337
33338        * cssjit/SelectorCompiler.cpp:
33339        (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
33340        (WebCore::SelectorCompiler::TagNamePattern::TagNamePattern):
33341        (WebCore::SelectorCompiler::solveDescendantBacktrackingActionForChild):
33342        (WebCore::SelectorCompiler::solveBacktrackingAction):
33343        (WebCore::SelectorCompiler::equalTagNames):
33344        (WebCore::SelectorCompiler::equalTagNamePatterns):
33345        (WebCore::SelectorCompiler::computeBacktrackingStartHeightFromDescendant):
33346        (WebCore::SelectorCompiler::computeBacktrackingHeightFromDescendant):
33347        (WebCore::SelectorCompiler::requiresAdjacentTail):
33348        (WebCore::SelectorCompiler::requiresDescendantTail):
33349        (WebCore::SelectorCompiler::SelectorCodeGenerator::computeBacktrackingInformation):
33350        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
33351        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToParentNode):
33352        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToParentElement):
33353        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateParentElementTreeWalker):
33354        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAncestorTreeWalker):
33355        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
33356        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateIndirectAdjacentTreeWalker):
33357        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
33358
333592014-04-28  Benjamin Poulain  <bpoulain@apple.com>
33360
33361        [iOS][WK2] Restore the scroll position and scale from the HistoryItem (mostly)
33362        https://bugs.webkit.org/show_bug.cgi?id=132307
33363
33364        Reviewed by Simon Fraser.
33365
33366        * WebCore.exp.in:
33367
333682014-04-28  Beth Dakin  <bdakin@apple.com>
33369
33370        Scrollbars do not update properly when topContentInset changes dynamically
33371        https://bugs.webkit.org/show_bug.cgi?id=132309
33372        -and corresponding-
33373        <rdar://problem/16642232>
33374
33375        Reviewed by Tim Horton.
33376
33377        It is not sufficient to do a layout and call updateScrollbars(). We must also call 
33378        RenderLayerCompositor::frameViewDidChangeSize() in order to properly adjust the 
33379        size and position of all of the scrolling-related layers.
33380        * page/FrameView.cpp:
33381        (WebCore::FrameView::topContentInsetDidChange):
33382
333832014-04-28  David Hyatt  <hyatt@apple.com>
33384
33385        [New Multicolumn] event.offsetX/offsetY don't work correctly
33386        https://bugs.webkit.org/show_bug.cgi?id=132284
33387
33388        Reviewed by Simon Fraser.
33389
33390        * rendering/RenderBoxModelObject.cpp:
33391        (WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
33392        Change the code here to only trigger for CSS Regions and not for
33393        multi-column. Add a FIXME pointing out that the code is broken even for
33394        CSS regions.
33395
33396         * rendering/RenderMultiColumnFlowThread.cpp:
33397        (WebCore::RenderMultiColumnFlowThread::mapAbsoluteToLocalPoint):
33398        Override mapAbsoluteToLocalPoint in order to guess a region and attempt
33399        to translate the point from that region to the flow thread local coordinate
33400        space.
33401
33402        (WebCore::RenderMultiColumnFlowThread::physicalTranslationFromRegionToFlow):
33403        * rendering/RenderMultiColumnFlowThread.h:
33404        New helper function that just wraps calling the region's logical translation
33405        function and converting to/from physical coordinates.
33406
334072014-04-28  Commit Queue  <commit-queue@webkit.org>
33408
33409        Unreviewed, rolling out r167857.
33410        https://bugs.webkit.org/show_bug.cgi?id=132305
33411
33412        the change was rolled out, roll out the new expectations as
33413        well (Requested by thorton on #webkit).
33414
33415        Reverted changeset:
33416
33417        "Unreviewed. Updating one bindings test baseline after
33418        r167855."
33419        http://trac.webkit.org/changeset/167857
33420
334212014-04-28  Dean Jackson  <dino@apple.com>
33422
33423        [Mac] Use the animated version of setHighlighted on NSButtonCell where available
33424        https://bugs.webkit.org/show_bug.cgi?id=132295
33425        <rdar://problem/16747240>
33426
33427        Reviewed by Beth Dakin.
33428
33429        Like setState, there is an animated version of setHighlighted available.
33430
33431        * platform/mac/ThemeMac.mm:
33432        (WebCore::updateStates): Use private version of _setHighlighted where possible.
33433
334342014-04-28  Commit Queue  <commit-queue@webkit.org>
33435
33436        Unreviewed, rolling out r167855.
33437        https://bugs.webkit.org/show_bug.cgi?id=132301
33438
33439        Broke the windows build (Requested by bfulgham on #webkit).
33440
33441        Reverted changeset:
33442
33443        "ScriptExecutionContext::Task should work well with C++11
33444        lambdas"
33445        https://bugs.webkit.org/show_bug.cgi?id=129795
33446        http://trac.webkit.org/changeset/167855
33447
334482014-04-24  Andy Estes  <aestes@apple.com>
33449
33450        [iOS] Implement WebQuickLookHandleClient for WebKit2
33451        https://bugs.webkit.org/show_bug.cgi?id=132157
33452
33453        Reviewed by Darin Adler.
33454
33455        * WebCore.exp.in: Exported QuickLookHandle::previewUTI().
33456        * platform/network/ios/QuickLook.h:
33457        * platform/network/ios/QuickLook.mm:
33458        (WebCore::QuickLookHandle::previewFileName): Changed to return a WTF::String.
33459        (WebCore::QuickLookHandle::previewUTI): Added.
33460
334612014-04-28  Chris Fleizach  <cfleizach@apple.com>
33462
33463        REGRESSION: Intermittent crash in SpeechSynthesis::didFinishSpeaking
33464        https://bugs.webkit.org/show_bug.cgi?id=111613
33465
33466        Reviewed by Mark Lam.
33467
33468        I think it's possible that didFinishSpeaking ends up calling directly back into start speaking, and the utterance reference
33469        we were holding can get cleared, so protecting this should avoid a few asserts.
33470
33471        * platform/mock/PlatformSpeechSynthesizerMock.cpp:
33472        (WebCore::PlatformSpeechSynthesizerMock::speakingFinished):
33473
334742014-04-28  Commit Queue  <commit-queue@webkit.org>
33475
33476        Unreviewed, rolling out r167871.
33477        https://bugs.webkit.org/show_bug.cgi?id=132290
33478
33479        broke a newmulticol test (spanner-nested-dynamic) (Requested
33480        by thorton on #webkit).
33481
33482        Reverted changeset:
33483
33484        "Store the containing region map inside the flow thread"
33485        https://bugs.webkit.org/show_bug.cgi?id=131647
33486        http://trac.webkit.org/changeset/167871
33487
334882014-04-28  Commit Queue  <commit-queue@webkit.org>
33489
33490        Unreviewed, rolling out r167853.
33491        https://bugs.webkit.org/show_bug.cgi?id=132288
33492
33493        caused crashes+timeouts+layout test failures described in the
33494        bug (Requested by thorton on #webkit).
33495
33496        Reverted changeset:
33497
33498        "Coalesce responses on network process side"
33499        https://bugs.webkit.org/show_bug.cgi?id=132229
33500        http://trac.webkit.org/changeset/167853
33501
335022014-04-24  Simon Fraser  <simon.fraser@apple.com>
33503
33504        [iOS WK2] flickery scrolling with overflow-scrolling:touch
33505        https://bugs.webkit.org/show_bug.cgi?id=132150
33506
33507        Reviewed by Tim Horton.
33508
33509        Fix typo in a comment.
33510
33511        * page/scrolling/AsyncScrollingCoordinator.cpp:
33512        (WebCore::AsyncScrollingCoordinator::scheduleUpdateScrollPositionAfterAsyncScroll):
33513
335142014-04-28  Martin Robinson  <mrobinson@igalia.com>
33515
33516        [GTK] Builtin cursors do not properly handle transparency
33517        https://bugs.webkit.org/show_bug.cgi?id=131866
33518
33519        Reviewed by Gustavo Noronha Silva.
33520
33521        Tested by ManualTests/cursor.html.
33522
33523        * platform/gtk/CursorGtk.cpp:
33524        (WebCore::createNamedCursor): Instead of interpreting the source bitmap as an A1 image, use
33525        it as a 1-bit black and white image. We do this by:
33526            1. Painting the result to a full color image with transparency instead of an alpha-only surface.
33527            2. Masking a white background using the cursor alpha surface.
33528            3. Painting the black parts of the cursor by painting the source surface, where black pixels
33529            will be interpreted as full opaque pixels.
33530
335312014-04-28  Carlos Garcia Campos  <cgarcia@igalia.com>
33532
33533        Unreviewed. Update GObject DOM bindings symbols file.
33534
33535        * bindings/gobject/webkitdom.symbols: Add missing symbols.
33536
335372014-04-28  Manuel Rego Casasnovas  <rego@igalia.com>
33538
33539        OrderIterator refactoring to avoid extra loops
33540        https://bugs.webkit.org/show_bug.cgi?id=119061
33541
33542        Reviewed by Darin Adler.
33543
33544        This patch removes order values Vector and use a Vector of pairs instead. The pairs are formed by a child
33545        (RenderBox) and the index of this child. In addition, OrderIterator code is simplified.
33546
33547        It provides a helper class OrderIteratorPopulator, used for manipulating the Vector directly. Which allows to
33548        consolidate the code into a single implementation across flexbox and grid. OrderIteratorPopulator part is based
33549        on a patch from Blink r153971 by <jchaffraix@chromium.org>.
33550
33551        Current implementation is O(number of children * number of order values). Now it will just do a sort operation
33552        and then a regular loop. So if you have different order values in a flexbox or grid the performance will
33553        improve.
33554
33555        Comparing results of perf-tests:
33556        * Layout/auto-grid-lots-of-data: ~0.5% worse.
33557        * Layout/fixed-grid-lots-of-data: ~0.5% worse.
33558        * Layout/fixed-grid-lots-of-data (setting 100 different order values): ~50% better.
33559        * Layout/flexbox-lots-of-data: ~5% better.
33560
33561        No new tests, already covered by current tests.
33562
33563        * rendering/OrderIterator.cpp:
33564        (WebCore::OrderIterator::currentChild): Return current child according to m_childrenIndex.
33565        (WebCore::OrderIterator::first): Initialize m_childrenIndex and return current child.
33566        (WebCore::OrderIterator::next): Increase m_childrenIndex and return current child.
33567        (WebCore::compareByOrderValueAndIndex): Sorts the Vector by order value and index.
33568        (WebCore::OrderIteratorPopulator::~OrderIteratorPopulator): Calls compareByOrderValueAndIndex() if there is any
33569        child with non default order value.
33570        (WebCore::OrderIteratorPopulator::collectChild): Adds the child and index to the Vector. Update
33571        m_allChildrenHaveDefaultOrderValue accordingly.
33572        (WebCore::OrderIterator::OrderIterator): Deleted.
33573        (WebCore::OrderIterator::setOrderValues): Deleted.
33574        (WebCore::OrderIterator::reset): Deleted.
33575        * rendering/OrderIterator.h:
33576        (WebCore::OrderIteratorPopulator::OrderIteratorPopulator): New helper class to manipulate the Vector.
33577        (WebCore::OrderIterator::currentChild): Deleted.
33578        * rendering/RenderFlexibleBox.cpp:
33579        (WebCore::RenderFlexibleBox::RenderFlexibleBox): Remove OrderIterator intialization.
33580        (WebCore::RenderFlexibleBox::layoutBlock): Remove unneeded code related to old OrderValues vector.
33581        (WebCore::RenderFlexibleBox::prepareOrderIteratorAndMargins): Populate OrderIterator using collectChild().
33582        (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes): Deleted.
33583        * rendering/RenderFlexibleBox.h: Rename computeMainAxisPreferredSizes() to prepareOrderIteratorAndMargins().
33584        * rendering/RenderGrid.cpp:
33585        (WebCore::RenderGrid::RenderGrid): Remove OrderIterator initialization.
33586        (WebCore::RenderGrid::populateExplicitGridAndOrderIterator): Populate OrderIterator using collectChild().
33587
335882014-04-28  Zan Dobersek  <zdobersek@igalia.com>
33589
33590        std::bitset<>::test() does unnecessary bounds checks on CSSPropertyID bitsets
33591        https://bugs.webkit.org/show_bug.cgi?id=131685
33592
33593        Reviewed by Darin Adler.
33594
33595        Use std::bitset<>::operator[]() instead of std::bitset<>::test() to avoid
33596        bounds checks which are not necessary as long as a CSSPropertyID value is used.
33597
33598        * css/CSSParser.cpp:
33599        (WebCore::filterProperties):
33600        * css/StyleProperties.cpp:
33601        (WebCore::StyleProperties::asText):
33602        * css/StyleResolver.cpp:
33603        (WebCore::StyleResolver::CascadedProperties::hasProperty):
33604        (WebCore::StyleResolver::CascadedProperties::set):
33605
336062014-04-28  Carlos Garcia Campos  <cgarcia@igalia.com>
33607
33608        [GTK] TextTrack kind and mode attributes are enums since r166180
33609        https://bugs.webkit.org/show_bug.cgi?id=132228
33610
33611        Reviewed by Martin Robinson.
33612
33613        Improve coding style according to review comments, that I forgot
33614        to do before landing previous commit.
33615
33616        * bindings/gobject/WebKitDOMCustom.cpp:
33617        (webkit_dom_text_track_get_kind):
33618        (webkit_dom_text_track_get_mode):
33619        (webkit_dom_text_track_set_mode):
33620
336212014-04-28  Carlos Garcia Campos  <cgarcia@igalia.com>
33622
33623        [GTK] TextTrack kind and mode attributes are enums since r166180
33624        https://bugs.webkit.org/show_bug.cgi?id=132228
33625
33626        Reviewed by Martin Robinson.
33627
33628        We don't support enum values yet in GObject DOM bindings, but they
33629        are internally strings anyway, so we can keep the old
33630        implementations using strings as custom functions until we
33631        properly support enums.
33632
33633        * bindings/gobject/WebKitDOMCustom.cpp:
33634        (webkit_dom_text_track_get_kind):
33635        (webkit_dom_text_track_get_mode):
33636        (webkit_dom_text_track_set_mode):
33637        * bindings/gobject/WebKitDOMCustom.h:
33638        * bindings/gobject/WebKitDOMCustom.symbols:
33639
336402014-04-28  Carlos Garcia Campos  <cgarcia@igalia.com>
33641
33642        [GTK] TextTrack::addCue can raise an exception since r163974
33643        https://bugs.webkit.org/show_bug.cgi?id=132227
33644
33645        Reviewed by Martin Robinson.
33646
33647        webkit_dom_text_track_add_cue() now receives a GError paramater
33648        which is an API break. Add
33649        webkit_dom_text_track_add_cue_with_error and keep
33650        webkit_dom_text_track_add_cue as deprecated to keep API
33651        compatibility.
33652
33653        * bindings/gobject/WebKitDOMDeprecated.cpp:
33654        (webkit_dom_text_track_add_cue):
33655        * bindings/gobject/WebKitDOMDeprecated.h:
33656        * bindings/gobject/WebKitDOMDeprecated.symbols:
33657        * bindings/gobject/webkitdom.symbols:
33658        * bindings/scripts/CodeGeneratorGObject.pm:
33659        (GetEffectiveFunctionName):
33660
336612014-04-28  Carlos Garcia Campos  <cgarcia@igalia.com>
33662
33663        [GTK] TextTrackCue API changed in r163649
33664        https://bugs.webkit.org/show_bug.cgi?id=132226
33665
33666        Reviewed by Martin Robinson.
33667
33668        TextTrackCue is now a base class and part of its API was moved to
33669        the derived class VTTCue. Update the GObject DOM bindings to keep
33670        backwards compatibility.
33671
33672        * PlatformGTK.cmake: Generate bindings for DataCue and VTTCue.
33673        * bindings/gobject/WebKitDOMDeprecated.cpp:
33674        (webkit_dom_text_track_cue_get_cue_as_html): Mark as deprecated in
33675        favor of VTTCue API.
33676        (webkit_dom_text_track_cue_get_vertical): Ditto.
33677        (webkit_dom_text_track_cue_set_vertical): Ditto.
33678        (webkit_dom_text_track_cue_get_snap_to_lines): Ditto.
33679        (webkit_dom_text_track_cue_set_snap_to_lines): Ditto.
33680        (webkit_dom_text_track_cue_get_line): Ditto.
33681        (webkit_dom_text_track_cue_set_line): Ditto.
33682        (webkit_dom_text_track_cue_get_position): Ditto.
33683        (webkit_dom_text_track_cue_set_position): Ditto.
33684        (webkit_dom_text_track_cue_get_size): Ditto.
33685        (webkit_dom_text_track_cue_set_size): Ditto.
33686        (webkit_dom_text_track_cue_get_align): Ditto.
33687        (webkit_dom_text_track_cue_set_align): Ditto.
33688        (webkit_dom_text_track_cue_get_text): Ditto.
33689        (webkit_dom_text_track_cue_set_text): Ditto.
33690        * bindings/gobject/WebKitDOMDeprecated.h:
33691        * bindings/gobject/WebKitDOMDeprecated.symbols: Add new deprecated symbols.
33692        * bindings/gobject/WebKitDOMPrivate.cpp:
33693        (WebKit::wrap): Add generic wrap for TextTrackCue now that it's a
33694        base class to generate DataCue or VTTCue objects.
33695        * bindings/gobject/WebKitDOMPrivate.h:
33696        * bindings/gobject/webkitdom.symbols: Add DataCue symbols.
33697        * bindings/scripts/CodeGeneratorGObject.pm:
33698        (IsPolymorphic): Add TextTrackCue to the list of polymorphic classes.
33699
337002014-04-27  Andrei Bucur  <abucur@adobe.com>
33701
33702        Store the containing region map inside the flow thread
33703        https://bugs.webkit.org/show_bug.cgi?id=131647
33704
33705        Reviewed by Mihnea Ovidenie.
33706
33707        The patch moves the containing region map inside the flow thread where
33708        it can be better handled in case the region chain changes and the map
33709        needs to be cleared.
33710
33711        As a result of this move we are able to also cleanup the lines region
33712        information of a block flow when it is removed from the tree.
33713
33714        Test: fast/regions/inline-strike-through.html
33715
33716        * rendering/InlineFlowBox.h:
33717        (WebCore::InlineFlowBox::InlineFlowBox):
33718        * rendering/RenderBlockLineLayout.cpp:
33719        (WebCore::RenderBlockFlow::addOverflowFromInlineChildren):
33720        * rendering/RenderFlowThread.cpp:
33721        (WebCore::RenderFlowThread::removeFlowChildInfo):
33722        (WebCore::RenderFlowThread::invalidateRegions):
33723        (WebCore::RenderFlowThread::removeLineRegionInfo):
33724        (WebCore::RenderFlowThread::checkLinesConsistency):
33725        (WebCore::RenderFlowThread::containingRegionMap):
33726        * rendering/RenderFlowThread.h:
33727        * rendering/RootInlineBox.cpp:
33728        (WebCore::containingRegionMap):
33729        (WebCore::RootInlineBox::~RootInlineBox):
33730        (WebCore::RootInlineBox::paint):
33731        (WebCore::RootInlineBox::containingRegion):
33732        (WebCore::RootInlineBox::clearContainingRegion):
33733        (WebCore::RootInlineBox::setContainingRegion):
33734
337352014-04-27  Darin Adler  <darin@apple.com>
33736
33737        REGRESSION (r159345): The hover state for links in the top navigation of Yahoo.com doesn't work
33738        https://bugs.webkit.org/show_bug.cgi?id=132241
33739        rdar://problem/16501924
33740
33741        Reviewed by Andreas Kling.
33742
33743        Test: fast/text/simple-lines-hover-underline.html
33744
33745        Checked that this does not hurt performance by running the
33746        run-perf-tests PerformanceTests/Layout/line-layout.html command before and after.
33747
33748        * rendering/RenderBlockFlow.cpp:
33749        (WebCore::RenderBlockFlow::hitTestInlineChildren): Use simpleLineLayout function rather than
33750        getting at the data member directly.
33751        (WebCore::RenderBlockFlow::firstLineBaseline): Ditto.
33752        (WebCore::RenderBlockFlow::inlineBlockBaseline): Ditto.
33753        (WebCore::RenderBlockFlow::lineCount): Ditto.
33754        (WebCore::RenderBlockFlow::paintInlineChildren): Ditto.
33755        (WebCore::RenderBlockFlow::hasLines): Ditto.
33756        (WebCore::RenderBlockFlow::simpleLineLayout): Added logic to determine which path to use if
33757        m_lineLayoutPath is undetermined, and call createLineBoxes if it's not simple.
33758        (WebCore::RenderBlockFlow::ensureLineBoxes): Factored out most of the code into a new
33759        createLineBoxes function.
33760        (WebCore::RenderBlockFlow::createLineBoxes): Ditto.
33761
33762        * rendering/RenderBlockFlow.h: Made simpleLineLayout function no longer an inline.
33763        Added a private createLineBoxes function.
33764
337652014-04-27  Praveen R Jadhav  <praveen.j@samsung.com>
33766
33767        [MediaStream] .ended shouldn't be part of MediaStream IDL
33768        https://bugs.webkit.org/show_bug.cgi?id=132104
33769
33770        Reviewed by Eric Carlson.
33771
33772        .ended attribute is spec'ed out of MediaStream IDL. Instead, .active
33773        is introduced to handle more scenarios. This patch replaces all 'ended'
33774        attribute calls with corresponding 'active' attributes. 
33775
33776        MediaStream-add-remove-tracks.html is updated.
33777
33778        * Modules/mediastream/MediaStream.cpp:
33779        (WebCore::MediaStream::addTrack): Replaced ended() with active().
33780        (WebCore::MediaStream::removeTrack): setEnded() isn't called. setActive()
33781        is retained which propagates oninactive event.
33782        (WebCore::MediaStream::trackDidEnd): setEnded() isn't called.
33783        (WebCore::MediaStream::removeRemoteSource): Replaced ended() with active().
33784        (WebCore::MediaStream::addRemoteTrack): Replaced ended() with active().
33785        (WebCore::MediaStream::removeRemoteTrack): Replaced ended() with active().
33786        (WebCore::MediaStream::ended): Deleted.
33787        (WebCore::MediaStream::setEnded): Deleted.
33788        (WebCore::MediaStream::streamDidEnd): Deleted.
33789        * Modules/mediastream/MediaStream.h:
33790        * Modules/mediastream/MediaStream.idl:
33791        * Modules/mediastream/RTCPeerConnection.cpp:
33792        (WebCore::RTCPeerConnection::didRemoveRemoteStream): Replaced setEnded()
33793        with setActive().
33794        * platform/mediastream/MediaStreamPrivate.cpp:
33795        (WebCore::MediaStreamPrivate::MediaStreamPrivate):
33796        (WebCore::MediaStreamPrivate::setActive): Updated comment from bug 
33797        https://bugs.webkit.org/show_bug.cgi?id=131973
33798        (WebCore::MediaStreamPrivate::setEnded): Deleted.
33799        * platform/mediastream/MediaStreamPrivate.h:
33800        (WebCore::MediaStreamPrivate::ended): Deleted.
33801
338022014-04-25  Andy Estes  <aestes@apple.com>
33803
33804        [iOS] Stop creating a WKWebResourceQuickLookDelegate for every WebResourceLoader
33805        https://bugs.webkit.org/show_bug.cgi?id=132215
33806
33807        Reviewed by Dan Bernstein.
33808
33809        * WebCore.exp.in: Moved QuickLook symbols to the USE(QUICK_LOOK) stanza.
33810        * platform/network/ios/QuickLook.h: Changed one of the create() overloads to no longer take a delegate argument.
33811        * platform/network/ios/QuickLook.mm: Moved WKWebResourceQuickLookDelegate to here and renamed to WebResourceLoaderQuickLookDelegate.
33812        (WebCore::QuickLookHandle::create): Created a WebResourceLoaderQuickLookDelegate only if QuickLook can handle the response.
33813
338142014-04-27  Sam Weinig  <sam@webkit.org>
33815
33816        [iOS WebKit2] Add support for text autosizing
33817        <rdar://problem/16545245>
33818        https://bugs.webkit.org/show_bug.cgi?id=132237
33819
33820        Reviewed by Tim Horton.
33821
33822        Move text autosizing width from Frame to Page, as it is a Page level concept.
33823
33824        * WebCore.exp.in:
33825        * page/Frame.cpp:
33826        (WebCore::Frame::textAutosizingWidth): Deleted.
33827        (WebCore::Frame::setTextAutosizingWidth): Deleted.
33828        * page/Frame.h:
33829        * page/FrameView.cpp:
33830        (WebCore::FrameView::layout):
33831        * page/Page.cpp:
33832        (WebCore::Page::Page):
33833        * page/Page.h:
33834        (WebCore::Page::textAutosizingWidth):
33835        (WebCore::Page::setTextAutosizingWidth):
33836
338372014-04-27  Zan Dobersek  <zdobersek@igalia.com>
33838
33839        Unreviewed. Updating one bindings test baseline after r167855.
33840
33841        * bindings/scripts/test/JS/JSTestCallback.cpp:
33842        (WebCore::JSTestCallback::~JSTestCallback):
33843
338442014-04-27  Darin Adler  <darin@apple.com>
33845
33846        Webpages can trigger loads with invalid URLs
33847        https://bugs.webkit.org/show_bug.cgi?id=132224
33848        rdar://problem/16697142
33849
33850        Reviewed by Alexey Proskuryakov.
33851
33852        Invalid URLs can be a way to trick the user about what website they
33853        are looking at.  Still trying to figure out a good way to regression-test this.
33854
33855        * dom/Document.cpp:
33856        (WebCore::Document::processHttpEquiv): Pass a URL rather than a String to
33857        the navigation scheduler.
33858        * loader/FrameLoader.cpp:
33859        (WebCore::FrameLoader::receivedFirstData): Ditto.
33860
33861        * loader/NavigationScheduler.cpp:
33862        (WebCore::ScheduledURLNavigation::ScheduledURLNavigation): Take a URL rather
33863        than a string.
33864        (WebCore::ScheduledURLNavigation::url): Ditto.
33865        (WebCore::ScheduledRedirect::ScheduledRedirect): Ditto.
33866        (WebCore::ScheduledLocationChange::ScheduledLocationChange): Ditto.
33867        (WebCore::ScheduledRefresh::ScheduledRefresh): Ditto.
33868        (WebCore::NavigationScheduler::shouldScheduleNavigation): Added a check that
33869        prevents navigation to any URL that is invalid, except for JavaScript URLs,
33870        which need not be valid.
33871        (WebCore::NavigationScheduler::scheduleRedirect): Use URL instead of String.
33872        (WebCore::NavigationScheduler::scheduleLocationChange): Use URL instead of
33873        String. Also got rid of empty string check since empty URLs are also invalid,
33874        and so shouldScheduleNavigation will take care of it.
33875        (WebCore::NavigationScheduler::scheduleRefresh): Use URL instead of String.
33876
33877        * loader/NavigationScheduler.h: Take URL instead of String. Also removed some
33878        unneeded incldues and uses of WTF_MAKE_NONCOPYABLE. NavigationScheduler is
33879        already noncopyable because it has a reference for a data member, and the
33880        disabler doesn't have any real reason to be noncopyable.
33881
33882        * loader/SubframeLoader.cpp:
33883        (WebCore::SubframeLoader::loadOrRedirectSubframe): Pass a URL rather than a
33884        String to the NavigationScheduler.
33885        * page/DOMWindow.cpp:
33886        (WebCore::DOMWindow::createWindow): Ditto.
33887
33888        * page/SecurityOrigin.cpp:
33889        (WebCore::SecurityOrigin::urlWithUniqueSecurityOrigin): Return a URL instead
33890        of a String.
33891        * page/SecurityOrigin.h: Updated for above change.
33892
338932014-04-27  Zan Dobersek  <zdobersek@igalia.com>
33894
33895        ScriptExecutionContext::Task should work well with C++11 lambdas
33896        https://bugs.webkit.org/show_bug.cgi?id=129795
33897
33898        Reviewed by Darin Adler.
33899
33900        Instead of having classes that subclass ScriptExecutionContext::Task and override
33901        the performTask(ScriptExecutionContext*) method, have the ScriptExecutionContext::Task
33902        take in a std::function<void (ScriptExecutionContext*)>-like object trough the constructor
33903        which would contain the code currently kept in the performTask() methods.
33904
33905        This enables inlining C++11 lambdas into ScriptExecutionContext::postTask() calls. For
33906        cleanup tasks, the Task object can be implicitly constructed by using the initializer list
33907        constructor with the first argument being the ScriptExecutionContext::Task::CleanupTask tag.
33908        The ScriptExecutionContext class remains non-copyable and now stores the passed-in invokable
33909        object in the std::function wrapper, along with a boolean member that indicates whether the
33910        task is of cleanup nature.
33911
33912        * Modules/quota/StorageErrorCallback.cpp:
33913        (WebCore::StorageErrorCallback::CallbackTask::CallbackTask):
33914        (WebCore::StorageErrorCallback::CallbackTask::performTask): Deleted.
33915        * Modules/quota/StorageErrorCallback.h:
33916        (WebCore::StorageErrorCallback::CallbackTask::create): Deleted.
33917        * Modules/webdatabase/Database.cpp:
33918        (WebCore::Database::~Database):
33919        (WebCore::Database::runTransaction):
33920        (WebCore::Database::scheduleTransactionCallback):
33921        (WebCore::DerefContextTask::create): Deleted.
33922        (WebCore::DerefContextTask::performTask): Deleted.
33923        (WebCore::DerefContextTask::isCleanupTask): Deleted.
33924        (WebCore::DerefContextTask::DerefContextTask): Deleted.
33925        (WebCore::callTransactionErrorCallback): Deleted.
33926        (WebCore::DeliverPendingCallbackTask::create): Deleted.
33927        (WebCore::DeliverPendingCallbackTask::performTask): Deleted.
33928        (WebCore::DeliverPendingCallbackTask::DeliverPendingCallbackTask): Deleted.
33929        * Modules/webdatabase/DatabaseManager.cpp:
33930        (WebCore::DatabaseManager::openDatabase):
33931        (WebCore::DatabaseCreationCallbackTask::create): Deleted.
33932        (WebCore::DatabaseCreationCallbackTask::performTask): Deleted.
33933        (WebCore::DatabaseCreationCallbackTask::DatabaseCreationCallbackTask): Deleted.
33934        * Modules/webdatabase/DatabaseSync.cpp:
33935        (WebCore::CloseSyncDatabaseOnContextThreadTask::create): Deleted.
33936        (WebCore::CloseSyncDatabaseOnContextThreadTask::performTask): Deleted.
33937        (WebCore::CloseSyncDatabaseOnContextThreadTask::CloseSyncDatabaseOnContextThreadTask): Deleted.
33938        * Modules/webdatabase/SQLCallbackWrapper.h:
33939        (WebCore::SQLCallbackWrapper::clear):
33940        (WebCore::SQLCallbackWrapper::SafeReleaseTask::create): Deleted.
33941        (WebCore::SQLCallbackWrapper::SafeReleaseTask::performTask): Deleted.
33942        (WebCore::SQLCallbackWrapper::SafeReleaseTask::isCleanupTask): Deleted.
33943        (WebCore::SQLCallbackWrapper::SafeReleaseTask::SafeReleaseTask): Deleted.
33944        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
33945        (WebCore::ThreadableWebSocketChannelClientWrapper::didConnect):
33946        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessage):
33947        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
33948        (WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmount):
33949        (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshake):
33950        (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
33951        (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageError):
33952        (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks):
33953        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.h:
33954        * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
33955        (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadInitialize):
33956        (WebCore::WorkerThreadableWebSocketChannel::mainThreadDestroy):
33957        (WebCore::WorkerThreadableWebSocketChannel::Bridge::disconnect):
33958        (WebCore::WorkerThreadableWebSocketChannel::WorkerGlobalScopeDidInitializeTask::create): Deleted.
33959        (WebCore::WorkerThreadableWebSocketChannel::WorkerGlobalScopeDidInitializeTask::~WorkerGlobalScopeDidInitializeTask): Deleted.
33960        (WebCore::WorkerThreadableWebSocketChannel::WorkerGlobalScopeDidInitializeTask::WorkerGlobalScopeDidInitializeTask): Deleted.
33961        * Modules/websockets/WorkerThreadableWebSocketChannel.h:
33962        * bindings/js/JSCallbackData.h:
33963        (WebCore::DeleteCallbackDataTask::DeleteCallbackDataTask):
33964        (WebCore::DeleteCallbackDataTask::create): Deleted.
33965        (WebCore::DeleteCallbackDataTask::performTask): Deleted.
33966        (WebCore::DeleteCallbackDataTask::isCleanupTask): Deleted.
33967        * bindings/js/JSDOMGlobalObjectTask.cpp:
33968        (WebCore::JSGlobalObjectTask::JSGlobalObjectTask):
33969        (WebCore::JSGlobalObjectTask::~JSGlobalObjectTask): Deleted.
33970        (WebCore::JSGlobalObjectTask::performTask): Deleted.
33971        * bindings/js/JSDOMGlobalObjectTask.h:
33972        * bindings/js/JSDOMWindowBase.cpp:
33973        (WebCore::JSDOMWindowBase::queueTaskToEventLoop):
33974        * bindings/js/JSWorkerGlobalScopeBase.cpp:
33975        (WebCore::JSWorkerGlobalScopeBase::queueTaskToEventLoop):
33976        * bindings/scripts/CodeGeneratorJS.pm:
33977        (GenerateCallbackImplementation):
33978        * dom/CrossThreadTask.h:
33979        (WebCore::CrossThreadTask1::performTask):
33980        (WebCore::CrossThreadTask2::performTask):
33981        (WebCore::CrossThreadTask3::performTask):
33982        (WebCore::CrossThreadTask4::performTask):
33983        (WebCore::CrossThreadTask5::performTask):
33984        (WebCore::CrossThreadTask6::performTask):
33985        (WebCore::CrossThreadTask7::performTask):
33986        (WebCore::CrossThreadTask8::performTask):
33987        (WebCore::createCallbackTask):
33988        (WebCore::CrossThreadTask1::create): Deleted.
33989        (WebCore::CrossThreadTask2::create): Deleted.
33990        (WebCore::CrossThreadTask3::create): Deleted.
33991        (WebCore::CrossThreadTask4::create): Deleted.
33992        (WebCore::CrossThreadTask5::create): Deleted.
33993        (WebCore::CrossThreadTask6::create): Deleted.
33994        (WebCore::CrossThreadTask7::create): Deleted.
33995        (WebCore::CrossThreadTask8::create): Deleted.
33996        * dom/Document.cpp:
33997        (WebCore::Document::addConsoleMessage):
33998        (WebCore::Document::addMessage):
33999        (WebCore::Document::postTask):
34000        (WebCore::Document::pendingTasksTimerFired):
34001        (WebCore::PerformTaskContext::PerformTaskContext): Deleted.
34002        (WebCore::Document::didReceiveTask): Deleted.
34003        * dom/Document.h:
34004        * dom/ScriptExecutionContext.cpp:
34005        (WebCore::ScriptExecutionContext::processMessagePortMessagesSoon):
34006        (WebCore::ScriptExecutionContext::timerAlignmentInterval):
34007        (WebCore::ProcessMessagesSoonTask::create): Deleted.
34008        (WebCore::ScriptExecutionContext::AddConsoleMessageTask::performTask): Deleted.
34009        (WebCore::ScriptExecutionContext::Task::~Task): Deleted.
34010        * dom/ScriptExecutionContext.h:
34011        (WebCore::ScriptExecutionContext::Task::Task):
34012        (WebCore::ScriptExecutionContext::Task::performTask):
34013        (WebCore::ScriptExecutionContext::Task::isCleanupTask):
34014        (WebCore::ScriptExecutionContext::AddConsoleMessageTask::AddConsoleMessageTask):
34015        (WebCore::ScriptExecutionContext::AddConsoleMessageTask::create): Deleted.
34016        * dom/StringCallback.cpp:
34017        (WebCore::StringCallback::scheduleCallback):
34018        * loader/appcache/ApplicationCacheGroup.cpp:
34019        (WebCore::ApplicationCacheGroup::postListenerTask):
34020        (WebCore::CallCacheListenerTask::create): Deleted.
34021        (WebCore::CallCacheListenerTask::CallCacheListenerTask): Deleted.
34022        * workers/DefaultSharedWorkerRepository.cpp:
34023        (WebCore::SharedWorkerProxy::postTaskToLoader):
34024        (WebCore::SharedWorkerProxy::postTaskForModeToWorkerGlobalScope):
34025        (WebCore::SharedWorkerConnectTask::SharedWorkerConnectTask):
34026        (WebCore::DefaultSharedWorkerRepository::workerScriptLoaded):
34027        (WebCore::DefaultSharedWorkerRepository::connectToWorker):
34028        (WebCore::SharedWorkerConnectTask::create): Deleted.
34029        (WebCore::SharedWorkerConnectTask::performTask): Deleted.
34030        * workers/WorkerEventQueue.cpp:
34031        (WebCore::WorkerEventQueue::EventDispatcher::EventDispatcher):
34032        (WebCore::WorkerEventQueue::EventDispatcher::~EventDispatcher):
34033        (WebCore::WorkerEventQueue::EventDispatcher::dispatch):
34034        (WebCore::WorkerEventQueue::enqueueEvent):
34035        (WebCore::WorkerEventQueue::cancelEvent):
34036        (WebCore::WorkerEventQueue::close):
34037        * workers/WorkerEventQueue.h:
34038        * workers/WorkerGlobalScope.cpp:
34039        (WebCore::WorkerGlobalScope::close):
34040        (WebCore::WorkerGlobalScope::postTask):
34041        (WebCore::WorkerGlobalScope::addConsoleMessage):
34042        (WebCore::WorkerGlobalScope::addMessage):
34043        (WebCore::CloseWorkerGlobalScopeTask::create): Deleted.
34044        (WebCore::CloseWorkerGlobalScopeTask::performTask): Deleted.
34045        (WebCore::CloseWorkerGlobalScopeTask::isCleanupTask): Deleted.
34046        * workers/WorkerGlobalScope.h:
34047        * workers/WorkerLoaderProxy.h:
34048        * workers/WorkerMessagingProxy.cpp:
34049        (WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
34050        (WebCore::WorkerMessagingProxy::postMessageToWorkerGlobalScope):
34051        (WebCore::WorkerMessagingProxy::postTaskForModeToWorkerGlobalScope):
34052        (WebCore::WorkerMessagingProxy::postTaskToLoader):
34053        (WebCore::WorkerMessagingProxy::postExceptionToWorkerObject):
34054        (WebCore::WorkerMessagingProxy::workerThreadCreated):
34055        (WebCore::WorkerMessagingProxy::notifyNetworkStateChange):
34056        (WebCore::WorkerMessagingProxy::workerGlobalScopeDestroyed):
34057        (WebCore::WorkerMessagingProxy::workerGlobalScopeClosed):
34058        (WebCore::WorkerMessagingProxy::postMessageToPageInspector):
34059        (WebCore::WorkerMessagingProxy::confirmMessageFromWorkerObject):
34060        (WebCore::WorkerMessagingProxy::reportPendingActivity):
34061        (WebCore::MessageWorkerGlobalScopeTask::create): Deleted.
34062        (WebCore::MessageWorkerGlobalScopeTask::MessageWorkerGlobalScopeTask): Deleted.
34063        (WebCore::MessageWorkerGlobalScopeTask::performTask): Deleted.
34064        (WebCore::MessageWorkerTask::create): Deleted.
34065        (WebCore::MessageWorkerTask::MessageWorkerTask): Deleted.
34066        (WebCore::MessageWorkerTask::performTask): Deleted.
34067        (WebCore::WorkerExceptionTask::create): Deleted.
34068        (WebCore::WorkerExceptionTask::WorkerExceptionTask): Deleted.
34069        (WebCore::WorkerExceptionTask::performTask): Deleted.
34070        (WebCore::WorkerGlobalScopeDestroyedTask::create): Deleted.
34071        (WebCore::WorkerGlobalScopeDestroyedTask::WorkerGlobalScopeDestroyedTask): Deleted.
34072        (WebCore::WorkerGlobalScopeDestroyedTask::performTask): Deleted.
34073        (WebCore::WorkerTerminateTask::create): Deleted.
34074        (WebCore::WorkerTerminateTask::WorkerTerminateTask): Deleted.
34075        (WebCore::WorkerTerminateTask::performTask): Deleted.
34076        (WebCore::WorkerThreadActivityReportTask::create): Deleted.
34077        (WebCore::WorkerThreadActivityReportTask::WorkerThreadActivityReportTask): Deleted.
34078        (WebCore::WorkerThreadActivityReportTask::performTask): Deleted.
34079        (WebCore::PostMessageToPageInspectorTask::create): Deleted.
34080        (WebCore::PostMessageToPageInspectorTask::PostMessageToPageInspectorTask): Deleted.
34081        (WebCore::PostMessageToPageInspectorTask::performTask): Deleted.
34082        (WebCore::NotifyNetworkStateChangeTask::create): Deleted.
34083        (WebCore::NotifyNetworkStateChangeTask::NotifyNetworkStateChangeTask): Deleted.
34084        (WebCore::NotifyNetworkStateChangeTask::performTask): Deleted.
34085        * workers/WorkerMessagingProxy.h:
34086        * workers/WorkerRunLoop.cpp:
34087        (WebCore::WorkerRunLoop::postTask):
34088        (WebCore::WorkerRunLoop::postTaskAndTerminate):
34089        (WebCore::WorkerRunLoop::postTaskForMode):
34090        (WebCore::WorkerRunLoop::Task::create):
34091        (WebCore::WorkerRunLoop::Task::performTask):
34092        (WebCore::WorkerRunLoop::Task::Task):
34093        * workers/WorkerRunLoop.h:
34094        * workers/WorkerThread.cpp:
34095        (WebCore::WorkerThread::stop):
34096        (WebCore::WorkerThread::releaseFastMallocFreeMemoryInAllThreads):
34097        (WebCore::WorkerThreadShutdownFinishTask::create): Deleted.
34098        (WebCore::WorkerThreadShutdownFinishTask::performTask): Deleted.
34099        (WebCore::WorkerThreadShutdownFinishTask::isCleanupTask): Deleted.
34100        (WebCore::WorkerThreadShutdownStartTask::create): Deleted.
34101        (WebCore::WorkerThreadShutdownStartTask::performTask): Deleted.
34102        (WebCore::WorkerThreadShutdownStartTask::isCleanupTask): Deleted.
34103
341042014-04-27  Antti Koivisto  <antti@apple.com>
34105
34106        Coalesce responses on network process side
34107        https://bugs.webkit.org/show_bug.cgi?id=132229
34108
34109        Reviewed by Andreas Kling.
34110
34111        * WebCore.exp.in:
34112
341132014-04-27  David Kilzer  <ddkilzer@apple.com>
34114
34115        Roll out changes not part of the patch reviewed for Bug 132089
34116        <http://webkit.org/b/132089>
34117
34118        * loader/SubframeLoader.cpp:
34119        (WebCore::SubframeLoader::loadOrRedirectSubframe):
34120        * page/DOMWindow.cpp:
34121        (WebCore::DOMWindow::setLocation):
34122        (WebCore::DOMWindow::createWindow):
34123        (WebCore::DOMWindow::open):
34124
341252014-04-26  Darin Adler  <darin@apple.com>
34126
34127        Frame and page lifetime fixes in WebCore::createWindow
34128        https://bugs.webkit.org/show_bug.cgi?id=132089
34129
34130        Reviewed by Sam Weinig.
34131
34132        Speculative fix because I was unable to reproduce the crash that was
34133        reported with the test case attached to this bug.
34134
34135        * loader/FrameLoader.cpp:
34136        (WebCore::createWindow): Changed code to remove the assumption that calls
34137        out will not destroy the page or frame. Use RefPtr for the frame, and
34138        added early exits if frame->page() becomes null at any point before we
34139        use a page pointer.
34140
341412014-04-26  Alexey Proskuryakov  <ap@apple.com>
34142
34143        Local files should not be allowed to read pasteboard data during drag
34144        https://bugs.webkit.org/show_bug.cgi?id=131767
34145
34146        Reviewed by Sam Weinig.
34147
34148        Test: fast/files/local-file-drag-security.html
34149
34150        * page/DragController.cpp:
34151        (WebCore::DragController::dragExited):
34152        (WebCore::DragController::tryDHTMLDrag):
34153        Make an old Dashboard quirk really Dashboard only.
34154
341552014-04-24  Darin Adler  <darin@apple.com>
34156
34157        REGRESSION (r164133): Selection doesn't paint when scrolling some pages
34158        https://bugs.webkit.org/show_bug.cgi?id=132172
34159        rdar://problem/16719473
34160
34161        Reviewed by Brent Fulgham.
34162
34163        Tests: fast/dynamic/remove-invisible-node-inside-selection.html
34164               fast/dynamic/remove-node-inside-selection.html
34165
34166        * editing/FrameSelection.cpp:
34167        (WebCore::clearRenderViewSelection): Changed to take a Node& because having
34168        this take a Position& was unnecessary and strange, when really it just needs
34169        to take a document as an argument.
34170        (WebCore::DragCaretController::nodeWillBeRemoved): Updated for the above.
34171        (WebCore::FrameSelection::respondToNodeModification): Added code to set the
34172        m_pendingSelectionUpdate flag and call RenderView::setNeedsLayout so the
34173        selection will be recomputed after it's temporarily cleared when one of
34174        the selected nodes is removed.
34175
341762014-04-25  Ryosuke Niwa  <rniwa@webkit.org>
34177
34178        REGRESSION (r167689): Hovering file name in a file input causes a crash
34179        https://bugs.webkit.org/show_bug.cgi?id=132214
34180
34181        Reviewed by Andreas Kling.
34182
34183        The bug was caused by callDefaultEventHandlersInTheBubblingOrder unconditionally
34184        accessing path.contextAt(0) even if the event path was empty.
34185
34186        Fixed the bug by exiting early when the event path is empty.
34187
34188        Test: fast/events/shadow-event-path-2.html
34189
34190        * dom/EventDispatcher.cpp:
34191        (WebCore::callDefaultEventHandlersInTheBubblingOrder):
34192
341932014-04-25  Tim Horton  <timothy_horton@apple.com>
34194
34195        REGRESSION (r167828): http/tests/media/hls/video-controls-live-stream.html fails
34196
34197        * English.lproj/mediaControlsLocalizedStrings.js:
34198        Add 'Live Broadcast' to the localized strings list.
34199
342002014-04-25  Brady Eidson  <beidson@apple.com>
34201
34202        Add a selection overlay.
34203        <rdar://problem/16727797> and https://bugs.webkit.org/show_bug.cgi?id=132200
34204
34205        Reviewed by David Hyatt.
34206
34207        No new tests (WK2 feature in development).
34208
34209        * WebCore.xcodeproj/project.pbxproj:
34210
34211        Add a SelectionRectGathterer class.
34212        It creates a Notifier (given a RenderView) then accepts Rects from the RenderView.
34213        When the Notifier is destroyed, the appropriate EditorClient is notified of the gathered rects.
34214        * editing/SelectionRectGatherer.cpp: Added.
34215        (WebCore::SelectionRectGatherer::SelectionRectGatherer):
34216        (WebCore::SelectionRectGatherer::addRect):
34217        (WebCore::SelectionRectGatherer::addRects):
34218        (WebCore::SelectionRectGatherer::Notifier::Notifier):
34219        (WebCore::SelectionRectGatherer::Notifier::~Notifier):
34220        (WebCore::SelectionRectGatherer::clearAndCreateNotifier):
34221        * editing/SelectionRectGatherer.h: Added.
34222
34223        * page/EditorClient.h:
34224        (WebCore::EditorClient::selectionRectsDidChange):
34225
34226        * rendering/RenderView.cpp:
34227        (WebCore::RenderView::RenderView):
34228        (WebCore::RenderView::setSelection): Clear the gatherer’s rects then create a Notifier.
34229        (WebCore::RenderView::setSubtreeSelection): Give all the selection rects to be painted to
34230          the SelectionRectGatherer.
34231        * rendering/RenderView.h:
34232
342332014-04-08  Jer Noble  <jer.noble@apple.com>
34234
34235        Support "Live" streams in media controls.
34236        https://bugs.webkit.org/show_bug.cgi?id=131390
34237
34238        Reviewed by Brent Fulgham.
34239
34240        Test: http/tests/media/hls/video-controls-live-stream.html
34241
34242        Support "Live" streams by adding an isLive property to our media controls.
34243
34244        * Modules/mediacontrols/mediaControlsApple.css:
34245        (audio::-webkit-media-controls-status-display):
34246        (video:-webkit-full-screen::-webkit-media-controls-status-display):
34247        * Modules/mediacontrols/mediaControlsApple.js:
34248        (Controller): isLive defaults to false.
34249        (Controller.prototype.setIsLive): Set the isLive property and conditionally reconfigure the controls.
34250        (Controller.prototype.configureInlineControls): Don't add the timeline if we are live.
34251        (Controller.prototype.configureFullScreenControls): Ditto.
34252        (Controller.prototype.updateStatusDisplay): Added.
34253        (Controller.prototype.handleLoadStart): Call updateStatusDisplay().
34254        (Controller.prototype.handleError): Ditto.
34255        (Controller.prototype.handleAbort): Ditto.
34256        (Controller.prototype.handleSuspend): Ditto.
34257        (Controller.prototype.handleStalled): Ditto.
34258        (Controller.prototype.handleWaiting): Ditto.
34259        (Controller.prototype.updateDuration): Ditto.
34260        (Controller.prototype.updateReadyState): Ditto.
34261
342622014-04-25  Dean Jackson  <dino@apple.com>
34263
34264        Allow a platform-specific size enumeration to be passed into popup-menu display
34265        https://bugs.webkit.org/show_bug.cgi?id=132195
34266
34267        Reviewed by Brent Fulgham. With some in-person review comments from Sam Weinig.
34268
34269        Platforms like OS X use a set of predefined sizes for built-in controls
34270        used for <select>: normal, small and mini. Expose that information to
34271        the PopupMenuClient via the PopupMenuStyle, allowing it to be passed
34272        into the platform code in WebKitSystemInterface.
34273
34274        * platform/PopupMenuStyle.h: Add a menu size enum.
34275        (WebCore::PopupMenuStyle::PopupMenuStyle):
34276        (WebCore::PopupMenuStyle::menuSize):
34277        * platform/mac/WebCoreSystemInterface.h: Pass in NSControlSize as a parameter
34278        to WKPopupMenu.
34279        * platform/mac/WebCoreSystemInterface.mm: Ditto.
34280        * rendering/RenderMenuList.cpp:
34281        (RenderMenuList::menuStyle): Ask the RenderTheme to calculate the size
34282        of the menu button, so that it can be added to the PopupMenuStyle.
34283        * rendering/RenderTheme.h: New method to retrieve the menu size.
34284        (WebCore::RenderTheme::popupMenuSize): Convert an NSControlSize into a PopupMenuSize.
34285        * rendering/RenderThemeMac.h: Override the base function, and add a
34286        controlSizeForCell helper.
34287        * rendering/RenderThemeMac.mm:
34288        (WebCore::RenderThemeMac::controlSizeForCell): Used by this new
34289        code and the old setControlSizeForCell to calculate the NSControlSize
34290        that would be used for the button.
34291        (WebCore::RenderThemeMac::setControlSize): Call the new helper.
34292        (WebCore::RenderThemeMac::popupMenuSize): Return the value from the helper.
34293
342942014-04-25  Javier Fernandez  <jfernandez@igalia.com>
34295
34296        REGRESSION(r167799): ASSERTION in parseGridTemplateShorthand in fast/css-grid-layout/grid-template-shorthand-get-set.html
34297        https://bugs.webkit.org/show_bug.cgi?id=132194
34298
34299        Reviewed by Martin Robinson.
34300
34301        Properly resolving the grid-template shorthand for the corresponding longhand
34302        properties.
34303
34304        No new tests, grid-template-shorthand-get-set.html already covers this case.
34305
34306        * css/StyleProperties.cpp:
34307        (WebCore::StyleProperties::getPropertyValue):
34308        * css/StylePropertyShorthand.cpp:
34309        (WebCore::shorthandForProperty):
34310        (WebCore::matchingShorthandsForLonghand):
34311        * css/StyleResolver.cpp:
34312        (WebCore::StyleResolver::applyProperty):
34313
343142014-04-25  David Hyatt  <hyatt@apple.com>
34315
34316        Column rules not respecting scroll offsets.
34317        https://bugs.webkit.org/show_bug.cgi?id=109683
34318
34319        Reviewed by Dean Jackson.
34320
34321        Added fast/multicol/scrolling-column-rules.html
34322
34323        * rendering/RenderBlock.cpp:
34324        (WebCore::RenderBlock::paintColumnRules):
34325        Make paintColumnRules virtual so that it works with both column implementations.
34326
34327        (WebCore::RenderBlock::paintObject):
34328        Changed to call paintColumnRules with the adjusted scroll offset and to do it after
34329        bailing on the root background only check.
34330
34331        * rendering/RenderBlock.h:
34332        paintColumnRules is now virtual.
34333
34334        * rendering/RenderBlockFlow.cpp:
34335        (WebCore::RenderBlockFlow::paintColumnRules):
34336        (WebCore::RenderBlockFlow::paintBoxDecorations): Deleted.
34337        * rendering/RenderBlockFlow.h:
34338        Got rid of paintBoxDecorations override since it failed when hasBoxDecorations was false
34339        anyway. Override paintColumnRules instead to paint at the right time.
34340
343412014-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
34342
34343        Crash applying editing commands from iframe onload event
34344
34345        <https://bugs.webkit.org/show_bug.cgi?id=132103>
34346        <rdar://problem/15696351>
34347
34348        This patch merges the Chromium bug workaround from
34349        <http://src.chromium.org/viewvc/blink?revision=162080&view=revision>,
34350        which prevents reentrancy in CompositeEditCommand::apply().
34351
34352        Reviewed by Darin Adler.
34353
34354        Test: editing/apply-style-iframe-crash.html
34355
34356        * editing/CompositeEditCommand.cpp:
34357        (WebCore::HTMLNames::ReentrancyGuard::isRecursiveCall):
34358        (WebCore::HTMLNames::ReentrancyGuard::Scope::Scope):
34359        (WebCore::HTMLNames::ReentrancyGuard::Scope::~Scope):
34360        (WebCore::CompositeEditCommand::apply):
34361        If this is a recursive call, return early.
34362
343632014-04-25  David Hyatt  <hyatt@apple.com>
34364
34365        [New Multicolumn] fast/multicol/hit-test-* layout tests all fail
34366        https://bugs.webkit.org/show_bug.cgi?id=132081
34367
34368        Reviewed by Dean Jackson.
34369
34370        Added a bunch of tests in fast/multicol/newmulticol/compare-with-old-impl/hit-test-*.html
34371
34372        * rendering/RenderBlock.h:
34373        Make offsetForContents public, since I need to call it from RenderMultiColumnSet.
34374
34375        * rendering/RenderMultiColumnFlowThread.cpp:
34376        (WebCore::RenderMultiColumnFlowThread::populate):
34377        Stop an ASSERT in the new columns code on the hit tests by making sure layout state is
34378        disabled when moving children around.
34379
34380        * rendering/RenderMultiColumnSet.cpp:
34381        (WebCore::RenderMultiColumnSet::positionForPoint):
34382        Refactor this function to call a helper function instead, translateRegionPointToFlowThread.
34383
34384        (WebCore::RenderMultiColumnSet::translateRegionPointToFlowThread):
34385        This function is logical (unlike the mistaken physical function I first implemented in
34386        positionForPoint).
34387
34388        (WebCore::RenderMultiColumnSet::updateHitTestResult):
34389        * rendering/RenderMultiColumnSet.h:
34390        Overridden to fill in the correct local coordinate when the HTML document is inside a paginated
34391        RenderView. Note that column spans don't actually work, but once we move over to a 
34392        non-column based pagination API, that will become irrelevant.
34393
343942014-04-25  Andreas Kling  <akling@apple.com>
34395
34396        Mark some things with WTF_MAKE_FAST_ALLOCATED.
34397        <https://webkit.org/b/132198>
34398
34399        Use FastMalloc for more things.
34400
34401        Reviewed by Anders Carlsson.
34402
34403        * bindings/js/ScriptController.h:
34404        * dom/DocumentOrderedMap.h:
34405        * inspector/InspectorCSSAgent.h:
34406        * inspector/InspectorDOMAgent.h:
34407        * inspector/InspectorDOMDebuggerAgent.h:
34408        * inspector/InspectorDOMStorageAgent.h:
34409        * inspector/InspectorDatabaseAgent.h:
34410        * inspector/InspectorLayerTreeAgent.h:
34411        * inspector/InspectorPageAgent.h:
34412        * inspector/InspectorResourceAgent.h:
34413        * inspector/InspectorTimelineAgent.h:
34414        * inspector/InspectorWorkerAgent.h:
34415        * inspector/PageRuntimeAgent.h:
34416        * loader/HistoryController.h:
34417        * page/DeviceClient.h:
34418        * page/DeviceController.h:
34419        * page/EventHandler.h:
34420        * page/Page.h:
34421        * page/scrolling/ScrollingStateNode.h:
34422        * platform/graphics/FontGenericFamilies.h:
34423        * platform/graphics/FontPlatformData.h:
34424
344252014-04-25  Radu Stavila  <stavila@adobe.com>
34426
34427        [CSS Regions] Rename objectShouldPaintInFlowRegion to something more clear
34428        https://bugs.webkit.org/show_bug.cgi?id=132050
34429
34430        Reviewed by Andreas Kling.
34431
34432        The objectShouldPaintInFlowRegion is no longer used only by the painting process
34433        but also for hit-testing, so it was renamed to something more generic (objectShouldFragmentInFlowRegion).
34434
34435        No new tests required, it's just a method rename.
34436
34437        * rendering/RenderBlock.cpp:
34438        (WebCore::RenderBlock::paint):
34439        (WebCore::RenderBlock::selectionGaps):
34440        (WebCore::RenderBlock::nodeAtPoint):
34441        * rendering/RenderBox.cpp:
34442        (WebCore::RenderBox::positionForPoint):
34443        * rendering/RenderFlowThread.cpp:
34444        (WebCore::RenderFlowThread::objectShouldFragmentInFlowRegion):
34445        (WebCore::RenderFlowThread::objectShouldPaintInFlowRegion): Deleted.
34446        * rendering/RenderFlowThread.h:
34447        * rendering/RenderLayer.cpp:
34448        (WebCore::RenderLayer::paintLayer):
34449        (WebCore::RenderLayer::hitTestLayer):
34450        * rendering/RenderRegion.cpp:
34451        (WebCore::RenderRegion::ensureOverflowForBox):
34452        * rendering/RenderReplaced.cpp:
34453        (WebCore::RenderReplaced::shouldPaint):
34454
344552014-04-25  Enrica Casucci  <enrica@apple.com>
34456
34457        iOS build fix after http://trac.webkit.org/changeset/167803
34458        Unreviewed.
34459
34460        * page/Frame.cpp:
34461        (WebCore::Frame::checkOverflowScroll):
34462        * rendering/RenderBlock.cpp:
34463        (WebCore::positionForPointRespectingEditingBoundaries):
34464
344652014-04-24  David Hyatt  <hyatt@apple.com>
34466
34467        [New Multicolumn] Add support for offsetLeft and offsetTop.
34468        https://bugs.webkit.org/show_bug.cgi?id=132080
34469
34470        Reviewed by Andrei Bucur.
34471
34472        Added fast/multicol/client-spanners-complex.html and offset-top-left.html
34473
34474        * rendering/RenderBoxModelObject.cpp:
34475        (WebCore::RenderBoxModelObject::adjustedPositionRelativeToOffsetParent):
34476        Patch the offsetLeft/Top loop to handle calling into RenderMultiColumnFlowThread
34477        in order to adjust the coordinates for the new multicolumn layout.
34478
34479        * rendering/RenderMultiColumnFlowThread.cpp:
34480        (WebCore::RenderMultiColumnFlowThread::mapFromFlowToRegion):
34481        Modified to use a helper that can be shared by offsetLeft/Top code. This code
34482        ran for client rects, and I'm moving/refactoring it for more sharing.
34483
34484        (WebCore::RenderMultiColumnFlowThread::physicalTranslationOffsetFromFlowToRegion):
34485        (WebCore::RenderMultiColumnFlowThread::physicalTranslationFromFlowToRegion):
34486        * rendering/RenderMultiColumnFlowThread.h:
34487        New functions that beef up what was in mapFromFlowToRegion and fix some bugs
34488        with the translation code.
34489
34490        * rendering/RenderMultiColumnSet.cpp:
34491        (WebCore::RenderMultiColumnSet::columnTranslationForOffset):
34492        Patched to factor in the flow thread portion rect of the specific multicolumn set.
34493
34494        * rendering/RenderObject.h:
34495        (WebCore::RenderObject::isRenderMultiColumnFlowThread):
34496        Added for toRenderMultiColumnFlowThread capability.
34497
344982014-04-25  Brent Fulgham  <bfulgham@apple.com>
34499
34500        ScrollingCoordinator is unaware of topContentInset
34501        https://bugs.webkit.org/show_bug.cgi?id=132158
34502        <rdar://problem/16706152>
34503
34504        Reviewed by Darin Adler.
34505
34506        Test: platform/mac/fast/scrolling/scroll-select-bottom-test.html
34507
34508        The calculation of non-fast-scrollable regions does not currently take
34509        the topContentOffset into account. Consequently, the logic that decides
34510        whether to stay on the scrolling thread, or drop down to an individual
34511        page element, can make the wrong choice. This is especially true for
34512        small scrollable regions (such as <select> elements), where the
34513        topContentInset may be quite close to the size of the scrollable
34514         element itself.
34515
34516        * page/scrolling/ScrollingCoordinator.cpp:
34517        (WebCore::ScrollingCoordinator::computeNonFastScrollableRegion): Also
34518        include the topContentInset value in our calculation.
34519
345202014-04-25  Javier Fernandez  <jfernandez@igalia.com>
34521
34522        REGRESSION(r167799): Breaks debug build
34523        https://bugs.webkit.org/show_bug.cgi?id=132194
34524
34525        Reviewed by Andrei Bucur.
34526
34527        Fix the debug bots after r167799
34528
34529        No new tests, no new functionality.
34530
34531        * css/CSSParser.cpp:
34532        (WebCore::CSSParser::parseGridTemplateShorthand):
34533
345342014-04-25  Miyoung Shin  <myid.shin@samsung.com>
34535
34536        Web process is crashed during dispatching touchEvent created by JS.
34537        https://bugs.webkit.org/show_bug.cgi?id=113225
34538
34539        Reviewed by Benjamin Poulain.
34540
34541        TouchEvent created by JS should have the necessary attributes
34542        of touches, targetTouches and changedTouches.
34543        It should be verified weather there are touchLists before dispatching touch event.
34544
34545        Test: fast/events/touch/create-touch-event-without-touchList.html
34546
34547        * dom/EventDispatcher.cpp:
34548        (WebCore::EventDispatcher::dispatchEvent):
34549        (WebCore::EventPath::updateTouchLists):
34550        (WebCore::addRelatedNodeResolversForTouchList): Deleted.
34551
345522014-04-25  Philippe Normand  <pnormand@igalia.com>
34553
34554        [GTK] File webkitRelativePath attribute was removed in r163483
34555        https://bugs.webkit.org/show_bug.cgi?id=132193
34556
34557        Reviewed by Carlos Garcia Campos.
34558
34559        Add the removed getter as deprecated API to keep backwards compatibility.
34560
34561        * bindings/gobject/WebKitDOMDeprecated.cpp:
34562        (webkit_dom_file_get_webkit_relative_path):
34563        * bindings/gobject/WebKitDOMDeprecated.h:
34564        * bindings/gobject/WebKitDOMDeprecated.symbols:
34565
345662014-04-25  Radu Stavila  <stavila@adobe.com>
34567
34568        [CSS Regions] Overflow selection doesn't work properly
34569        https://bugs.webkit.org/show_bug.cgi?id=130715
34570
34571        Reviewed by David Hyatt.
34572
34573        When hit-testing, painting block selection gaps and searching for the node at a specific point inside a flow thread,
34574        the region range of the box being checked must be validated in order to not return false positives. Otherwise, hit-testing
34575        at the top of region B could hit elements that overflow the bottom of region A.
34576
34577        Tests: fast/regions/selection-in-overflow-hit-testing.html
34578               fast/regions/selection-in-overflow.html
34579               fast/regions/selection-in-text-after-overflow-hit-testing.html
34580
34581        * accessibility/AccessibilityRenderObject.cpp:
34582        (WebCore::AccessibilityRenderObject::visiblePositionRangeForLine):
34583        (WebCore::AccessibilityRenderObject::visiblePositionForPoint):
34584        * dom/Document.cpp:
34585        (WebCore::Document::caretRangeFromPoint):
34586        * editing/FrameSelection.cpp:
34587        (WebCore::FrameSelection::contains):
34588        * editing/VisibleUnits.cpp:
34589        (WebCore::previousLinePosition):
34590        (WebCore::nextLinePosition):
34591        * page/EventHandler.cpp:
34592        (WebCore::EventHandler::selectClosestWordFromHitTestResult):
34593        (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent):
34594        (WebCore::EventHandler::handleMousePressEventTripleClick):
34595        (WebCore::EventHandler::handleMousePressEventSingleClick):
34596        (WebCore::selectionExtentRespectingEditingBoundary):
34597        (WebCore::EventHandler::updateSelectionForMouseDrag):
34598        (WebCore::EventHandler::handleMouseReleaseEvent):
34599        * page/Frame.cpp:
34600        (WebCore::Frame::visiblePositionForPoint):
34601        * rendering/RenderBlock.cpp:
34602        (WebCore::RenderBlock::selectionGaps):
34603        (WebCore::RenderBlock::nodeAtPoint):
34604        (WebCore::positionForPointRespectingEditingBoundaries):
34605        (WebCore::RenderBlock::positionForPointWithInlineChildren):
34606        (WebCore::isChildHitTestCandidate):
34607        (WebCore::RenderBlock::positionForPoint):
34608        * rendering/RenderBlock.h:
34609        * rendering/RenderBlockFlow.cpp:
34610        (WebCore::RenderBlockFlow::positionForPointWithInlineChildren):
34611        (WebCore::RenderBlockFlow::positionForPoint):
34612        * rendering/RenderBlockFlow.h:
34613        * rendering/RenderBox.cpp:
34614        (WebCore::RenderBox::positionForPoint):
34615        * rendering/RenderBox.h:
34616        * rendering/RenderFileUploadControl.cpp:
34617        (WebCore::RenderFileUploadControl::positionForPoint):
34618        * rendering/RenderFileUploadControl.h:
34619        * rendering/RenderInline.cpp:
34620        (WebCore::RenderInline::positionForPoint):
34621        * rendering/RenderInline.h:
34622        * rendering/RenderLineBreak.cpp:
34623        (WebCore::RenderLineBreak::positionForPoint):
34624        * rendering/RenderLineBreak.h:
34625        * rendering/RenderMultiColumnSet.cpp:
34626        (WebCore::RenderMultiColumnSet::positionForPoint):
34627        * rendering/RenderMultiColumnSet.h:
34628        * rendering/RenderObject.cpp:
34629        (WebCore::RenderObject::positionForPoint):
34630        * rendering/RenderObject.h:
34631        * rendering/RenderRegion.cpp:
34632        (WebCore::RenderRegion::positionForPoint):
34633        * rendering/RenderRegion.h:
34634        * rendering/RenderReplaced.cpp:
34635        (WebCore::RenderReplaced::positionForPoint):
34636        * rendering/RenderReplaced.h:
34637        * rendering/RenderText.cpp:
34638        (WebCore::RenderText::positionForPoint):
34639        * rendering/RenderText.h:
34640        * rendering/svg/RenderSVGInlineText.cpp:
34641        (WebCore::RenderSVGInlineText::positionForPoint):
34642        * rendering/svg/RenderSVGInlineText.h:
34643        * rendering/svg/RenderSVGText.cpp:
34644        (WebCore::RenderSVGText::positionForPoint):
34645        * rendering/svg/RenderSVGText.h:
34646
346472014-04-25  Philippe Normand  <pnormand@igalia.com>
34648
34649        [GTK] Iframe seamless support was removed in r163427
34650        https://bugs.webkit.org/show_bug.cgi?id=132192
34651
34652        Reviewed by Carlos Garcia Campos.
34653
34654        Add the removed get and set methods as deprecated API to keep
34655        backwards compatibility.
34656
34657        * bindings/gobject/WebKitDOMDeprecated.cpp:
34658        (webkit_dom_processing_instruction_set_data):
34659        (webkit_dom_html_iframe_element_get_seamless):
34660        (webkit_dom_html_iframe_element_set_seamless):
34661        * bindings/gobject/WebKitDOMDeprecated.h:
34662        * bindings/gobject/WebKitDOMDeprecated.symbols:
34663
346642014-04-25  Philippe Normand  <pnormand@igalia.com>
34665
34666        [GTK] HTMLInputElement webkitdirectory property was removed in r163483
34667        https://bugs.webkit.org/show_bug.cgi?id=132191
34668
34669        Reviewed by Carlos Garcia Campos.
34670
34671        Add the removed get and set methods as deprecated API to keep
34672        backwards compatibility.
34673
34674        * bindings/gobject/WebKitDOMDeprecated.cpp:
34675        (webkit_dom_html_input_element_get_webkitdirectory):
34676        (webkit_dom_html_input_element_set_webkitdirectory):
34677        * bindings/gobject/WebKitDOMDeprecated.h:
34678        * bindings/gobject/WebKitDOMDeprecated.symbols:
34679
346802014-04-25  Javier Fernandez  <jfernandez@igalia.com>
34681
34682        [CSS Grid Layout] Implementation of the grid-template shorthand.
34683        https://bugs.webkit.org/show_bug.cgi?id=128980
34684
34685        Reviewed by Darin Adler.
34686
34687        This shorthand sets the values for the grid-template-columns,
34688        grid-template-rows and grid-template-areas, so the implementation
34689        tries to reuse as much available parsing functions as possible.
34690
34691        The "parsingGridTrackList" was refactored to return a CSSValue and
34692        let the "parseValue" function to assign the property value. The
34693        "forwardSlash" operator is now valid when the track-list clause is
34694        part of a shorthand. The "parseValue" function checkouts that only
34695        additional clauses are allowed when processing shorthands; the
34696        grid-columns-rows-get-set.html tests was modified to verify this.
34697
34698        The "parseGridTemplateAreas" was refactored too, in order to
34699        process single areas's rows. This is very useful for the
34700        gris-template secondary syntax, which mixes areas and rows values.
34701
34702        Finally, the "parseGirdLineNames" function was modified as well by
34703        defining an new argument to concatenate head/tail custom-ident
34704        elements and ensure the identList is at the heading index, since
34705        it's now possible the parseList was rewound.
34706
34707        The implementation of the grid-template shorthand tries first to
34708        match the <grid-template-columns> / <grid-template-rows> syntax,
34709        failing back to the secondary syntax if needed.  This approach
34710        requires to rewind the parseList but it produces a clearer code.
34711
34712        Test: fast/css-grid-layout/grid-template-shorthand-get-set.html
34713
34714        * css/CSSComputedStyleDeclaration.cpp:
34715        (WebCore::ComputedStyleExtractor::propertyValue):
34716        * css/CSSParser.cpp:
34717        (WebCore::CSSParser::parseValue):
34718        (WebCore::CSSParser::parseGridTemplateRowsAndAreas):
34719        (WebCore::CSSParser::parseGridTemplateShorthand):
34720        (WebCore::CSSParser::parseGridLineNames):
34721        (WebCore::CSSParser::parseGridTrackList):
34722        (WebCore::CSSParser::parseGridTemplateAreasRow):
34723        (WebCore::CSSParser::parseGridTemplateAreas):
34724        * css/CSSParser.h:
34725        * css/CSSParserValues.h:
34726        (WebCore::CSSParserValueList::setCurrentIndex):
34727        * css/CSSPropertyNames.in:
34728        * css/StylePropertyShorthand.cpp:
34729        (WebCore::webkitGridTemplateShorthand):
34730        * css/StylePropertyShorthand.h:
34731
347322014-04-25  Andreas Kling  <akling@apple.com>
34733
34734        Remove two unused SVGDocument functions.
34735        <https://webkit.org/b/132178>
34736
34737        Reviewed by Antti Koivisto.
34738
34739        * svg/SVGDocument.cpp:
34740        (WebCore::SVGDocument::dispatchZoomEvent): Deleted.
34741        (WebCore::SVGDocument::dispatchScrollEvent): Deleted.
34742        * svg/SVGDocument.h:
34743
347442014-04-25  Ion Rosca  <rosca@adobe.com>
34745
34746        Incomplete body painting when using blend modes
34747        https://bugs.webkit.org/show_bug.cgi?id=131889
34748
34749        The incomplete painting was caused by the transparency layer created for
34750        the root renderer. We can safely skip creating this transparency layer at
34751        the root level, as there is nothing else being painted behind this layer that
34752        could be used erroneously as a backdrop.
34753
34754        Reviewed by Simon Fraser.
34755
34756        Test: css3/compositing/blend-mode-with-body.html
34757
34758        * rendering/RenderLayer.h:
34759        Changing RenderLayer::paintsWithTransparency so that it will not
34760        return true when the root renderer needs to isolate blending.
34761
347622014-04-25  Darin Adler  <darin@apple.com>
34763
34764        ASSERTION FAILED: "!m_isolatedWorld->isNormal() || m_wrapper || !m_jsFunction" in svg/custom/use-instanceRoot-event-listeners.xhtml
34765        https://bugs.webkit.org/show_bug.cgi?id=132148
34766
34767        Reviewed by Andreas Kling.
34768
34769        Changed how JSCustomMarkFunction generation works. Instead of leaving out
34770        the generated visitChildren function, just generate a call to visitAdditionalChildren.
34771        This eliminates the need to repeat boilerplate.
34772
34773        The fix for the above bug was to correct mistaken logic where JSSVGElementInstance
34774        had a visitChildren that did not properly mark event listeners because it explicitly
34775        did not call through to the base class visitChildren. The new arrangement makes that
34776        mistake impossible.
34777
34778        * bindings/js/JSAttrCustom.cpp:
34779        (WebCore::JSAttr::visitAdditionalChildren): Use this instead of visitChildren.
34780        * bindings/js/JSAudioTrackCustom.cpp:
34781        (WebCore::JSAudioTrack::visitAdditionalChildren): Ditto.
34782        * bindings/js/JSAudioTrackListCustom.cpp:
34783        (WebCore::JSAudioTrackList::visitAdditionalChildren): Ditto.
34784        * bindings/js/JSCSSRuleCustom.cpp:
34785        (WebCore::JSCSSRule::visitAdditionalChildren): Ditto.
34786        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
34787        (WebCore::JSCSSStyleDeclaration::visitAdditionalChildren): Ditto.
34788        * bindings/js/JSCanvasRenderingContextCustom.cpp:
34789        (WebCore::JSCanvasRenderingContext::visitAdditionalChildren): Ditto.
34790        * bindings/js/JSCryptoKeyPairCustom.cpp:
34791        (WebCore::JSCryptoKeyPair::visitAdditionalChildren): Ditto.
34792        * bindings/js/JSDOMWindowCustom.cpp:
34793        (WebCore::JSDOMWindow::visitAdditionalChildren): Ditto.
34794        * bindings/js/JSMessageChannelCustom.cpp:
34795        (WebCore::JSMessageChannel::visitAdditionalChildren): Ditto.
34796        * bindings/js/JSMessagePortCustom.cpp:
34797        (WebCore::JSMessagePort::visitAdditionalChildren): Ditto.
34798        * bindings/js/JSNodeCustom.cpp:
34799        (WebCore::JSNode::visitAdditionalChildren): Ditto.
34800        * bindings/js/JSNodeFilterCustom.cpp:
34801        (WebCore::JSNodeFilter::visitAdditionalChildren): Ditto.
34802        * bindings/js/JSNodeIteratorCustom.cpp:
34803        (WebCore::JSNodeIterator::visitAdditionalChildren): Ditto.
34804        * bindings/js/JSSVGElementInstanceCustom.cpp:
34805        (WebCore::JSSVGElementInstance::visitAdditionalChildren): Ditto.
34806        * bindings/js/JSSharedWorkerCustom.cpp:
34807        (WebCore::JSSharedWorker::visitAdditionalChildren): Ditto.
34808        * bindings/js/JSStyleSheetCustom.cpp:
34809        (WebCore::JSStyleSheet::visitAdditionalChildren): Ditto.
34810        * bindings/js/JSTextTrackCueCustom.cpp:
34811        (WebCore::JSTextTrackCue::visitAdditionalChildren): Ditto.
34812        * bindings/js/JSTextTrackCustom.cpp:
34813        (WebCore::JSTextTrack::visitAdditionalChildren): Ditto.
34814        * bindings/js/JSTextTrackListCustom.cpp:
34815        (WebCore::JSTextTrackList::visitAdditionalChildren): Ditto.
34816        * bindings/js/JSTreeWalkerCustom.cpp:
34817        (WebCore::JSTreeWalker::visitAdditionalChildren): Ditto.
34818        * bindings/js/JSVideoTrackCustom.cpp:
34819        (WebCore::JSVideoTrack::visitAdditionalChildren): Ditto.
34820        * bindings/js/JSVideoTrackListCustom.cpp:
34821        (WebCore::JSVideoTrackList::visitAdditionalChildren): Ditto.
34822        * bindings/js/JSWebGLRenderingContextCustom.cpp:
34823        (WebCore::JSWebGLRenderingContext::visitAdditionalChildren): Ditto.
34824        * bindings/js/JSWorkerGlobalScopeCustom.cpp:
34825        (WebCore::JSWorkerGlobalScope::visitAdditionalChildren): Ditto.
34826        * bindings/js/JSXMLHttpRequestCustom.cpp:
34827        (WebCore::JSXMLHttpRequest::visitAdditionalChildren): Ditto.
34828        * bindings/js/JSXPathResultCustom.cpp:
34829        (WebCore::JSXPathResult::visitAdditionalChildren): Ditto.
34830
34831        * bindings/js/JSDOMGlobalObject.cpp:
34832        (WebCore::JSDOMGlobalObject::visitChildren): Rewrote to use modern for loops.
34833
34834        * bindings/scripts/CodeGeneratorJS.pm:
34835        (GenerateHeader): Generate declaration of visitAdditionalChildren.
34836        (GenerateImplementation): Generate call to visitAdditionalChildren.
34837
348382014-04-24  Andreas Kling  <akling@apple.com>
34839
34840        [iOS WebKit2] Enable optimization to mmap downloaded resources once they become file-backed.
34841        <https://webkit.org/b/132171>
34842        <rdar://problem/16720733>
34843
34844        Add a missing export for the USE(CFNETWORK) + WebKit2 combo.
34845
34846        Reviewed by Antti Koivisto.
34847
34848        * WebCore.exp.in:
34849
348502014-04-24  Darin Adler  <darin@apple.com>
34851
34852        FrameLoader::checkCompleted can hit the "ref'ing while destroyed" assertion
34853        https://bugs.webkit.org/show_bug.cgi?id=132163
34854        rdar://problem/16720640
34855
34856        Reviewed by Brady Eidson.
34857
34858        Couldn't find a way to test this yet. Would be nice to have a test.
34859
34860        * loader/FrameLoader.cpp:
34861        (WebCore::FrameLoader::checkCompleted): Move protector until after we check
34862        if the frame is already complete. That can happen in practice when this is
34863        called from within the frame's destructor. All the code that runs before the
34864        protector simply checks state and does not require protection.
34865
348662014-04-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
34867
34868        Mark Supplement instead of RefCountedSupplement in NavigatorContentUtils 
34869        https://bugs.webkit.org/show_bug.cgi?id=132151
34870
34871        Reviewed by Darin Adler.
34872
34873        Though Original goal was to make it sharable across navigator instances, the NavigatorContentUtils
34874        has used RefCountedSupplement<Page> instead of RefCountedSupplement<Navigator>. This patch makes it
34875        use Supplement<Page> because there is no scenario which needs to be shared across navigator instances.
34876
34877        Blink merge from https://src.chromium.org/viewvc/blink?view=rev&revision=171403.
34878
34879        No new tests, no behavior changes.
34880
34881        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
34882        (WebCore::NavigatorContentUtils::from):
34883        (WebCore::NavigatorContentUtils::create):
34884        (WebCore::provideNavigatorContentUtilsTo):
34885        * Modules/navigatorcontentutils/NavigatorContentUtils.h:
34886
348872014-04-24  Commit Queue  <commit-queue@webkit.org>
34888
34889        Unreviewed, rolling out r167700.
34890        https://bugs.webkit.org/show_bug.cgi?id=132142
34891
34892        Incorrectly reverted the change in r167547 for
34893        webkit.org/b/131898 (Requested by rniwa on #webkit).
34894
34895        Reverted changeset:
34896
34897        "Cursor doesn't change back to pointer when leaving the Safari
34898        window"
34899        https://bugs.webkit.org/show_bug.cgi?id=132038
34900        http://trac.webkit.org/changeset/167700
34901
349022014-04-24  Brady Eidson  <beidson@apple.com>
34903
34904        Rename "IMAGE_CONTROLS" feature to "SERVICE_CONTROLS"
34905        https://bugs.webkit.org/show_bug.cgi?id=132155
34906
34907        Reviewed by Tim Horton.
34908
34909        No new tests (No change in behavior).
34910
34911        * Configurations/FeatureDefines.xcconfig:
34912        * DerivedSources.make:
34913        * WebCore.exp.in:
34914        * css/CSSDefaultStyleSheets.cpp:
34915        (WebCore::CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement):
34916        * css/CSSPrimitiveValueMappings.h:
34917        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
34918        * css/CSSValueKeywords.in:
34919        * dom/Node.h:
34920        * html/HTMLImageElement.cpp:
34921        (WebCore::HTMLImageElement::HTMLImageElement):
34922        (WebCore::HTMLImageElement::parseAttribute):
34923        (WebCore::HTMLImageElement::didAttachRenderers):
34924        * html/HTMLImageElement.h:
34925        * html/shadow/ImageControlsRootElement.cpp:
34926        * html/shadow/ImageControlsRootElement.h:
34927        * html/shadow/mac/ImageControlsButtonElementMac.cpp:
34928        * html/shadow/mac/ImageControlsButtonElementMac.h:
34929        * html/shadow/mac/ImageControlsRootElementMac.cpp:
34930        * html/shadow/mac/ImageControlsRootElementMac.h:
34931        * page/ContextMenuContext.cpp:
34932        (WebCore::ContextMenuContext::ContextMenuContext):
34933        * page/ContextMenuContext.h:
34934        * page/ContextMenuController.cpp:
34935        (WebCore::ContextMenuController::maybeCreateContextMenu):
34936        (WebCore::ContextMenuController::populate):
34937        * page/ContextMenuController.h:
34938        * page/Settings.in:
34939        * platform/ThemeTypes.h:
34940        * rendering/RenderImage.cpp:
34941        (WebCore::RenderImage::canHaveChildren):
34942        * rendering/RenderTheme.cpp:
34943        (WebCore::RenderTheme::adjustStyle):
34944        (WebCore::RenderTheme::paint):
34945        (WebCore::RenderTheme::paintBorderOnly):
34946        (WebCore::RenderTheme::paintDecorations):
34947        * rendering/RenderTheme.h:
34948        * rendering/RenderThemeMac.h:
34949        * rendering/RenderThemeMac.mm:
34950        (WebCore::RenderThemeMac::servicesRolloverButtonCell):
34951        (WebCore::RenderThemeMac::paintImageControlsButton):
34952        (WebCore::RenderThemeMac::imageControlsButtonSize):
34953
349542014-04-24  Timothy Hatcher  <timothy@apple.com>
34955
34956        Web Inspector: Restore PageDebuggerAgent::enable / disable
34957        https://bugs.webkit.org/show_bug.cgi?id=132156
34958
34959        Restore functions that were eroniously removed in r167530.
34960
34961        Reviewed by Joseph Pecoraro.
34962
34963        * inspector/PageDebuggerAgent.cpp:
34964        (WebCore::PageDebuggerAgent::enable): Added.
34965        (WebCore::PageDebuggerAgent::disable): Added.
34966        * inspector/PageDebuggerAgent.h:
34967
349682014-04-24  Alexey Proskuryakov  <ap@apple.com>
34969
34970        Dropzone effects don't work in non-file documents
34971        https://bugs.webkit.org/show_bug.cgi?id=131770
34972
34973        Reviewed by Darin Adler.
34974
34975        File documents have two quirks that were making dropzone work in these before:
34976        1. An ancient hack for Dashboard allows pasteboard access from JS.
34977        2. On Mac, sandbox doesn't prevent File object creation, as we already have the access.
34978
34979        * dom/DataTransfer.cpp:
34980        (WebCore::DataTransfer::hasFileOfType):
34981        (WebCore::DataTransfer::hasStringOfType):
34982        * dom/DataTransfer.h:
34983        Moved these functions from EventHandler to DataTransfer. We can't create a DataTransfer
34984        with Files while dragging, security doesn't permit us to. But we can get the file name.
34985
34986        * fileapi/File.cpp:
34987        (WebCore::createBlobDataForFile):
34988        (WebCore::createBlobDataForFileWithName):
34989        (WebCore::File::contentTypeFromFilePath):
34990        (WebCore::getContentTypeFromFileName): Deleted.
34991        * fileapi/File.h:
34992        Exposed a function to get file type from path without creating a File first.
34993        This is much cheaper than creating a File, and works even when sandbox disallows
34994        read access to content, such as when dragging over a target.
34995
34996        * page/EventHandler.cpp:
34997        (WebCore::hasDropZoneType):
34998        (WebCore::hasFileOfType): Deleted.
34999        (WebCore::hasStringOfType): Deleted.
35000
350012014-04-24  Commit Queue  <commit-queue@webkit.org>
35002
35003        Unreviewed, rolling out r167441.
35004        https://bugs.webkit.org/show_bug.cgi?id=132152
35005
35006        Caused full screen regressions on vimeo, youtube, and others.
35007        (Requested by jernoble on #webkit).
35008
35009        Reverted changeset:
35010
35011        "Fullscreen media controls are unusable in pagination mode"
35012        https://bugs.webkit.org/show_bug.cgi?id=131705
35013        http://trac.webkit.org/changeset/167441
35014
350152014-04-24  Adenilson Cavalcanti  <cavalcantii@gmail.com>
35016
35017        Unused class forward declarations in Page
35018        https://bugs.webkit.org/show_bug.cgi?id=132141
35019
35020        Reviewed by Benjamin Poulain.
35021
35022        No new tests, no change on behavior.
35023
35024        * page/Page.h:
35025
350262014-04-24  Eric Carlson  <eric.carlson@apple.com>
35027
35028        [Mac] don't ask for AVAssetTrack properties before they are available
35029        https://bugs.webkit.org/show_bug.cgi?id=131902
35030        <rdar://problem/16505076>
35031
35032        Reviewed by Brent Fulgham.
35033
35034        No new tests, the behavior this changes can not be tested with a layout test.
35035
35036        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
35037        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
35038        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize
35039            m_cachedTotalBytes.
35040        (WebCore::MediaPlayerPrivateAVFoundationObjC::beginLoadingMetadata): Don't report that
35041            metadata has been loaded until the track properties we need have been loaded too.
35042        (WebCore::MediaPlayerPrivateAVFoundationObjC::totalBytes): Cache totalBytes instead
35043            of recalculating it every time.
35044        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksDidChange): Invalidate cached
35045            total bytes.
35046        (WebCore::assetTrackMetadataKeyNames): Array of AVAssetTrack properties we use.
35047
350482014-04-24  Myles C. Maxfield  <mmaxfield@apple.com>
35049
35050        Unify platformWidthForGlyph across OS X and iOS
35051        https://bugs.webkit.org/show_bug.cgi?id=132036
35052
35053        Reviewed by Darin Adler.
35054
35055        This patch creates on shared SimpleFontData::platformWidthForGlyph() function for both OS X and iOS.
35056
35057        No new tests are necessary because there should be no behavior changes.
35058
35059        * platform/graphics/SimpleFontData.h: Signatures for two helper functions
35060        * platform/graphics/ios/SimpleFontDataIOS.mm: Replace iOS implementation of platformWidthForGlyph() with
35061        implementations of only the two helper functions
35062        (WebCore::SimpleFontData::getRenderingStyle): Compute style argument to CGFontGetGlyphAdvancesForStyle()
35063        (WebCore::SimpleFontData::advanceForColorBitmapFont): iOS doesn't have color bitmap fonts
35064        (WebCore::SimpleFontData::platformWidthForGlyph): Deleted.
35065        * platform/graphics/mac/SimpleFontDataMac.mm:
35066        (WebCore::SimpleFontData::getRenderingStyle): Compute style argument to CGFontGetGlyphAdvancesForStyle()
35067        (WebCore::SimpleFontData::advanceForColorBitmapFont): Use [NSFont advancementForGlyph] to compute the advance
35068        (WebCore::hasCustomTracking): Removed #if
35069        (WebCore::isEmoji): Only relevant on iOS
35070        (WebCore::SimpleFontData::platformWidthForGlyph): Shared implementation. Calls helper functions.
35071
350722014-04-24  Zalan Bujtas  <zalan@apple.com>
35073
35074        Subpixel rendering: Clipping on text areas when shifted by one device pixel.
35075        https://bugs.webkit.org/show_bug.cgi?id=132008
35076
35077        Reviewed by Darin Adler.
35078
35079        Make RenderTheme paint* functions LayoutRect aware. Textarea is device pixel snapped, while
35080        other theme controls are still on integral size/positions.
35081
35082        Test: fast/forms/hidpi-textarea-on-subpixel-position.html
35083
35084        * rendering/RenderBox.cpp:
35085        (WebCore::RenderBox::paintBoxDecorations):
35086        * rendering/RenderTheme.cpp:
35087        (WebCore::RenderTheme::paint):
35088        (WebCore::RenderTheme::paintBorderOnly):
35089        (WebCore::RenderTheme::paintDecorations):
35090        * rendering/RenderTheme.h:
35091        (WebCore::RenderTheme::paintTextField):
35092        (WebCore::RenderTheme::paintTextFieldDecorations):
35093        (WebCore::RenderTheme::paintTextArea):
35094        (WebCore::RenderTheme::paintTextAreaDecorations):
35095        * rendering/RenderThemeIOS.h:
35096        * rendering/RenderThemeIOS.mm:
35097        (WebCore::RenderThemeIOS::paintTextFieldDecorations):
35098        (WebCore::RenderThemeIOS::paintTextAreaDecorations):
35099        * rendering/RenderThemeMac.h:
35100        * rendering/RenderThemeMac.mm:
35101        (WebCore::RenderThemeMac::paintTextField):
35102        (WebCore::RenderThemeMac::paintTextArea):
35103
351042014-04-24  Myles C. Maxfield  <mmaxfield@apple.com>
35105
35106        FontCache::fontCache() never returns nullptr so it can be made to return a reference instead
35107        https://bugs.webkit.org/show_bug.cgi?id=132110
35108
35109        Reviewed by Tim Horton.
35110
35111        Updates callers to use '.' instead of '->'.
35112
35113        No new tests are necessary because there should be no behavior change.
35114
35115        * css/CSSFontFaceSource.cpp:
35116        (WebCore::CSSFontFaceSource::getFontData):
35117        * css/CSSFontSelector.cpp:
35118        (WebCore::CSSFontSelector::CSSFontSelector):
35119        (WebCore::CSSFontSelector::~CSSFontSelector):
35120        (WebCore::CSSFontSelector::addFontFaceRule):
35121        (WebCore::fontDataForGenericFamily):
35122        (WebCore::CSSFontSelector::getFallbackFontData):
35123        * platform/MemoryPressureHandler.cpp:
35124        (WebCore::MemoryPressureHandler::releaseMemory):
35125        * platform/graphics/FontCache.cpp:
35126        (WebCore::fontCache): Return a reference
35127        * platform/graphics/FontCache.h:
35128        (WebCore::FontCachePurgePreventer::FontCachePurgePreventer):
35129        (WebCore::FontCachePurgePreventer::~FontCachePurgePreventer):
35130        * platform/graphics/FontGlyphs.cpp:
35131        (WebCore::FontGlyphs::FontGlyphs):
35132        (WebCore::FontGlyphs::releaseFontData):
35133        (WebCore::FontGlyphs::realizeFontDataAt):
35134        (WebCore::FontGlyphs::glyphDataAndPageForCharacter):
35135        * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
35136        (WebCore::FontPlatformData::verticalData):
35137        * platform/graphics/ios/SimpleFontDataIOS.mm:
35138        (WebCore::SimpleFontData::platformCreateScaledFontData):
35139        * platform/graphics/mac/ComplexTextControllerCoreText.mm:
35140        (WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
35141        * platform/graphics/mac/FontCacheMac.mm:
35142        (WebCore::invalidateFontCache):
35143        (WebCore::fontCacheRegisteredFontsChangedNotificationCallback):
35144        * platform/graphics/mac/SimpleFontDataMac.mm:
35145        (WebCore::SimpleFontData::platformDestroy):
35146        (WebCore::SimpleFontData::platformCreateScaledFontData):
35147        * platform/graphics/win/FontCacheWin.cpp:
35148        (WebCore::getCJKCodePageMasks):
35149        * platform/graphics/win/SimpleFontDataWin.cpp:
35150        (WebCore::SimpleFontData::containsCharacters):
35151        * platform/graphics/wince/FontCacheWinCE.cpp:
35152        (WebCore::getCJKCodePageMasks):
35153        * platform/graphics/wince/FontPlatformData.cpp:
35154        (WebCore::FontFamilyCodePageInfo::codePages):
35155        (WebCore::FixedSizeFontData::create):
35156        * platform/graphics/wince/GlyphPageTreeNodeWinCE.cpp:
35157        (WebCore::GlyphPage::fill):
35158        * platform/graphics/wince/SimpleFontDataWinCE.cpp:
35159        (WebCore::SimpleFontData::platformCreateScaledFontData):
35160        (WebCore::SimpleFontData::containsCharacters):
35161
351622014-04-24  Eric Carlson  <eric.carlson@apple.com>
35163
35164        [iOS] Manage AudioSession category according to media type
35165        https://bugs.webkit.org/show_bug.cgi?id=132096
35166
35167        Reviewed by Jer Noble.
35168
35169        * WebCore.exp.in: Export setting.
35170
35171        * html/HTMLMediaSession.cpp:
35172        (WebCore::HTMLMediaSession::HTMLMediaSession):
35173        (WebCore::initializeAudioSession): Deleted.
35174
35175        * page/Settings.cpp:
35176        * page/Settings.h:
35177        (WebCore::Settings::setShouldManageAudioSession): New.
35178        (WebCore::Settings::shouldManageAudioSession): Ditto.
35179
35180        * platform/audio/ios/AudioDestinationIOS.cpp:
35181        (WebCore::AudioDestinationIOS::AudioDestinationIOS): Use a MediaSession instead of inheriting
35182            from AudioListener and calling the AudioSession directly.
35183        (WebCore::AudioDestinationIOS::~AudioDestinationIOS): Ditto.
35184        (WebCore::AudioDestinationIOS::start): Notify session.
35185        (WebCore::AudioDestinationIOS::stop): Ditto.
35186        (WebCore::AudioDestinationIOS::beganAudioInterruption): Deleted.
35187        (WebCore::AudioDestinationIOS::endedAudioInterruption): Deleted.
35188        * platform/audio/ios/AudioDestinationIOS.h:
35189        (WebCore::AudioDestinationIOS::mediaType):
35190        (WebCore::AudioDestinationIOS::canReceiveRemoteControlCommands):
35191        (WebCore::AudioDestinationIOS::didReceiveRemoteControlCommand):
35192        (WebCore::AudioDestinationIOS::isPlaying): Deleted.
35193
35194        * platform/audio/ios/AudioSessionIOS.mm:
35195        (WebCore::categoryName): Debug-only logging function.
35196        (WebCore::AudioSession::setCategory): Don't stick with "media" once it is set.
35197
35198        * platform/audio/ios/MediaSessionManagerIOS.mm:
35199        (WebCore::MediaSessionManageriOS::resetRestrictions): Set up restrictions for WebAudio.
35200        (WebCore::MediaSessionManageriOS::updateNowPlayingInfo): Don't set invalid start time.
35201
35202        * platform/audio/mac/MediaSessionManagerMac.cpp:
35203        (MediaSessionManager::updateSessionState): Manage AudioSession.active when WebAudio clients
35204            come and go. Manage AudioSession.category according to the number of WebAudio and
35205            HTMLMediaElement clients.
35206
352072014-04-24  David Hyatt  <hyatt@apple.com>
35208
35209        [New Multicolumn] Client rects don't work with column spans.
35210        https://bugs.webkit.org/show_bug.cgi?id=132131
35211
35212        Reviewed by Dean Jackson.
35213        
35214        Don't factor in the offset of the multicolumn set from the top
35215        of the multicolumn block. This was added already, and it doesn't
35216        need to be a part of columnTranslationForOffset.
35217
35218        Added fast/multicol/client-rects-spanners.html
35219
35220        * rendering/RenderMultiColumnSet.cpp:
35221        (WebCore::RenderMultiColumnSet::columnTranslationForOffset):
35222
352232014-04-24  Praveen R Jadhav  <praveen.j@samsung.com>
35224
35225        [EFL] WebKit build fails when MEDIA_SOURCE is enabled
35226        https://bugs.webkit.org/show_bug.cgi?id=132118
35227
35228        Reviewed by Brent Fulgham.
35229
35230        Files MediaSourceGStreamer.cpp, SourceBufferPrivateGStreamer.cpp and
35231        WebKitMediaSourceGStreamer.cpp are included for EFL port build.
35232
35233        No new tests. No change in behaviour.
35234
35235        * PlatformEfl.cmake: MediaSourceGStreamer.cpp, SourceBufferPrivateGStreamer.cpp
35236        and WebKitMediaSourceGStreamer.cpp are included for compilation.
35237
352382014-04-24  Tamas Gergely  <tgergely.u-szeged@partner.samsung.com>
35239
35240        ASSERTION FAILED: !begin.isIndefinite() in WebCore::SVGSMILElement::resolveFirstInterval.
35241        https://bugs.webkit.org/show_bug.cgi?id=131097
35242
35243        Reviewed by Darin Adler.
35244
35245        According to smil animation reference, max attribute cannot be 0.
35246
35247        Test: svg/animations/smil-animation-max-attribute-zero-crash.svg
35248
35249        * svg/animation/SVGSMILElement.cpp:
35250        (WebCore::SVGSMILElement::maxValue):
35251          changed (result < 0) to (result <= 0)
35252
352532014-04-24  Ryuan Choi  <ryuan.choi@samsung.com>
35254
35255        Remove screenColorProfile()
35256        https://bugs.webkit.org/show_bug.cgi?id=132035
35257
35258        Reviewed by Darin Adler.
35259
35260        Only chromium used screenColorProfile() since r120789.
35261
35262        * platform/PlatformScreen.h:
35263        * platform/efl/PlatformScreenEfl.cpp:
35264        (WebCore::screenColorProfile): Deleted.
35265        * platform/gtk/PlatformScreenGtk.cpp:
35266        (WebCore::screenColorProfile): Deleted.
35267        * platform/image-decoders/ImageDecoder.h:
35268        (WebCore::ImageDecoder::qcmsOutputDeviceProfile):
35269        * platform/ios/PlatformScreenIOS.mm:
35270        (WebCore::screenColorProfile): Deleted.
35271        * platform/mac/PlatformScreenMac.mm:
35272        (WebCore::screenColorProfile): Deleted.
35273        * platform/win/PlatformScreenWin.cpp:
35274        (WebCore::screenColorProfile): Deleted.
35275
352762014-04-24  Zalan Bujtas  <zalan@apple.com>
35277
35278        One more unreviewed build fix after r167755.
35279
35280        * html/shadow/mac/ImageControlsButtonElementMac.cpp:
35281        (WebCore::RenderImageControlsButton::updateLogicalWidth):
35282        (WebCore::RenderImageControlsButton::computeLogicalHeight):
35283
352842014-04-24  Zalan Bujtas  <zalan@apple.com>
35285
35286        Unreviewed build fix after r167755.
35287
35288        * rendering/RenderThemeMac.h:
35289
352902014-04-24  Zalan Bujtas  <zalan@apple.com>
35291
35292        Transition RenderTheme API from RenderObject* to const RenderObject&
35293        https://bugs.webkit.org/show_bug.cgi?id=132037
35294
35295        Reviewed by Andreas Kling.
35296
35297        Using const references provides better encapsulation and improve security.
35298
35299        No change in behavior.
35300
35301        * accessibility/AccessibilityObject.cpp:
35302        (WebCore::AccessibilityObject::boundingBoxForQuads):
35303        * dom/Element.cpp:
35304        (WebCore::Element::setActive):
35305        (WebCore::Element::setHovered):
35306        * editing/FrameSelection.cpp:
35307        (WebCore::FrameSelection::focusedOrActiveStateChanged):
35308        * html/HTMLFormControlElement.cpp:
35309        (WebCore::HTMLFormControlElement::disabledStateChanged):
35310        (WebCore::HTMLFormControlElement::readOnlyAttributeChanged):
35311        * html/HTMLInputElement.cpp:
35312        (WebCore::HTMLInputElement::setChecked):
35313        (WebCore::HTMLInputElement::setIndeterminate):
35314        * html/HTMLOptionElement.cpp:
35315        (WebCore::HTMLOptionElement::parseAttribute):
35316        * rendering/RenderBlock.cpp:
35317        (WebCore::RenderBlock::addVisualOverflowFromTheme):
35318        (WebCore::RenderBlock::baselinePosition):
35319        * rendering/RenderBox.cpp:
35320        (WebCore::RenderBox::paintBoxDecorations):
35321        * rendering/RenderButton.cpp:
35322        (WebCore::RenderButton::styleDidChange):
35323        * rendering/RenderFileUploadControl.cpp:
35324        (WebCore::RenderFileUploadControl::paintObject):
35325        * rendering/RenderFlowThread.cpp:
35326        (WebCore::RenderFlowThread::addRegionsVisualOverflowFromTheme):
35327        * rendering/RenderObject.cpp:
35328        (WebCore::RenderObject::drawLineForBoxSide):
35329        * rendering/RenderObject.h:
35330        * rendering/RenderProgress.cpp:
35331        (WebCore::RenderProgress::computeLogicalHeight):
35332        * rendering/RenderTextControlSingleLine.cpp:
35333        (WebCore::RenderTextControlSingleLine::paint):
35334        * rendering/RenderTheme.cpp:
35335        (WebCore::RenderTheme::paint):
35336        (WebCore::RenderTheme::paintBorderOnly):
35337        (WebCore::RenderTheme::paintDecorations):
35338        (WebCore::RenderTheme::baselinePosition):
35339        (WebCore::RenderTheme::adjustRepaintRect):
35340        (WebCore::RenderTheme::stateChanged):
35341        (WebCore::RenderTheme::updateControlStatesForRenderer):
35342        (WebCore::RenderTheme::extractControlStatesForRenderer):
35343        (WebCore::RenderTheme::isActive):
35344        (WebCore::RenderTheme::isChecked):
35345        (WebCore::RenderTheme::isIndeterminate):
35346        (WebCore::RenderTheme::isEnabled):
35347        (WebCore::RenderTheme::isFocused):
35348        (WebCore::RenderTheme::isPressed):
35349        (WebCore::RenderTheme::isSpinUpButtonPartPressed):
35350        (WebCore::RenderTheme::isReadOnlyControl):
35351        (WebCore::RenderTheme::isHovered):
35352        (WebCore::RenderTheme::isSpinUpButtonPartHovered):
35353        (WebCore::RenderTheme::isDefault):
35354        (WebCore::RenderTheme::paintInputFieldSpeechButton):
35355        (WebCore::RenderTheme::paintMeter):
35356        (WebCore::RenderTheme::paintSliderTicks):
35357        (WebCore::RenderTheme::progressBarRectForBounds):
35358        * rendering/RenderTheme.h:
35359        (WebCore::RenderTheme::controlSupportsTints):
35360        (WebCore::RenderTheme::paintCapsLockIndicator):
35361        (WebCore::RenderTheme::paintFileUploadIconDecorations):
35362        (WebCore::RenderTheme::imageControlsButtonSize):
35363        (WebCore::RenderTheme::paintCheckbox):
35364        (WebCore::RenderTheme::paintRadio):
35365        (WebCore::RenderTheme::paintButton):
35366        (WebCore::RenderTheme::paintInnerSpinButton):
35367        (WebCore::RenderTheme::paintCheckboxDecorations):
35368        (WebCore::RenderTheme::paintRadioDecorations):
35369        (WebCore::RenderTheme::paintButtonDecorations):
35370        (WebCore::RenderTheme::paintTextField):
35371        (WebCore::RenderTheme::paintTextFieldDecorations):
35372        (WebCore::RenderTheme::paintTextArea):
35373        (WebCore::RenderTheme::paintTextAreaDecorations):
35374        (WebCore::RenderTheme::paintMenuList):
35375        (WebCore::RenderTheme::paintMenuListDecorations):
35376        (WebCore::RenderTheme::paintMenuListButtonDecorations):
35377        (WebCore::RenderTheme::paintPushButtonDecorations):
35378        (WebCore::RenderTheme::paintSquareButtonDecorations):
35379        (WebCore::RenderTheme::paintProgressBar):
35380        (WebCore::RenderTheme::paintSliderTrack):
35381        (WebCore::RenderTheme::paintSliderThumb):
35382        (WebCore::RenderTheme::paintSliderThumbDecorations):
35383        (WebCore::RenderTheme::paintSearchField):
35384        (WebCore::RenderTheme::paintSearchFieldDecorations):
35385        (WebCore::RenderTheme::paintSearchFieldCancelButton):
35386        (WebCore::RenderTheme::paintSearchFieldDecorationPart):
35387        (WebCore::RenderTheme::paintSearchFieldResultsDecorationPart):
35388        (WebCore::RenderTheme::paintSearchFieldResultsButton):
35389        (WebCore::RenderTheme::paintMediaFullscreenButton):
35390        (WebCore::RenderTheme::paintMediaPlayButton):
35391        (WebCore::RenderTheme::paintMediaOverlayPlayButton):
35392        (WebCore::RenderTheme::paintMediaMuteButton):
35393        (WebCore::RenderTheme::paintMediaSeekBackButton):
35394        (WebCore::RenderTheme::paintMediaSeekForwardButton):
35395        (WebCore::RenderTheme::paintMediaSliderTrack):
35396        (WebCore::RenderTheme::paintMediaSliderThumb):
35397        (WebCore::RenderTheme::paintMediaVolumeSliderContainer):
35398        (WebCore::RenderTheme::paintMediaVolumeSliderTrack):
35399        (WebCore::RenderTheme::paintMediaVolumeSliderThumb):
35400        (WebCore::RenderTheme::paintMediaRewindButton):
35401        (WebCore::RenderTheme::paintMediaReturnToRealtimeButton):
35402        (WebCore::RenderTheme::paintMediaToggleClosedCaptionsButton):
35403        (WebCore::RenderTheme::paintMediaControlsBackground):
35404        (WebCore::RenderTheme::paintMediaCurrentTime):
35405        (WebCore::RenderTheme::paintMediaTimeRemaining):
35406        (WebCore::RenderTheme::paintMediaFullScreenVolumeSliderTrack):
35407        (WebCore::RenderTheme::paintMediaFullScreenVolumeSliderThumb):
35408        (WebCore::RenderTheme::paintSnapshottedPluginOverlay):
35409        (WebCore::RenderTheme::paintImageControlsButton):
35410        * rendering/RenderThemeIOS.h:
35411        * rendering/RenderThemeIOS.mm:
35412        (WebCore::RenderThemeIOS::addRoundedBorderClip):
35413        (WebCore::RenderThemeIOS::paintCheckboxDecorations):
35414        (WebCore::RenderThemeIOS::baselinePosition):
35415        (WebCore::RenderThemeIOS::paintRadioDecorations):
35416        (WebCore::RenderThemeIOS::paintTextFieldDecorations):
35417        (WebCore::RenderThemeIOS::paintTextAreaDecorations):
35418        (WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
35419        (WebCore::RenderThemeIOS::paintSliderTrack):
35420        (WebCore::RenderThemeIOS::paintSliderThumbDecorations):
35421        (WebCore::RenderThemeIOS::paintProgressBar):
35422        (WebCore::RenderThemeIOS::paintSearchFieldDecorations):
35423        (WebCore::RenderThemeIOS::paintButtonDecorations):
35424        (WebCore::RenderThemeIOS::paintPushButtonDecorations):
35425        (WebCore::RenderThemeIOS::paintFileUploadIconDecorations):
35426        * rendering/RenderThemeMac.h:
35427        (WebCore::RenderThemeMac::updateActiveState):
35428        * rendering/RenderThemeMac.mm:
35429        (WebCore::RenderThemeMac::documentViewFor):
35430        (WebCore::RenderThemeMac::adjustRepaintRect):
35431        (WebCore::RenderThemeMac::convertToPaintingRect):
35432        (WebCore::RenderThemeMac::updateCheckedState):
35433        (WebCore::RenderThemeMac::updateEnabledState):
35434        (WebCore::RenderThemeMac::updateFocusedState):
35435        (WebCore::RenderThemeMac::updatePressedState):
35436        (WebCore::RenderThemeMac::controlSupportsTints):
35437        (WebCore::RenderThemeMac::paintTextField):
35438        (WebCore::RenderThemeMac::paintCapsLockIndicator):
35439        (WebCore::RenderThemeMac::paintTextArea):
35440        (WebCore::RenderThemeMac::paintMenuList):
35441        (WebCore::RenderThemeMac::paintMeter):
35442        (WebCore::RenderThemeMac::progressBarRectForBounds):
35443        (WebCore::RenderThemeMac::paintProgressBar):
35444        (WebCore::RenderThemeMac::paintMenuListButtonGradients):
35445        (WebCore::RenderThemeMac::paintMenuListButtonDecorations):
35446        (WebCore::RenderThemeMac::setPopupButtonCellState):
35447        (WebCore::RenderThemeMac::paintSliderTrack):
35448        (WebCore::RenderThemeMac::paintSliderThumb):
35449        (WebCore::RenderThemeMac::paintSearchField):
35450        (WebCore::RenderThemeMac::setSearchCellState):
35451        (WebCore::RenderThemeMac::paintSearchFieldCancelButton):
35452        (WebCore::RenderThemeMac::paintSearchFieldDecorationPart):
35453        (WebCore::RenderThemeMac::paintSearchFieldResultsDecorationPart):
35454        (WebCore::RenderThemeMac::paintSearchFieldResultsButton):
35455        (WebCore::RenderThemeMac::paintSnapshottedPluginOverlay):
35456        (WebCore::RenderThemeMac::paintImageControlsButton):
35457        (WebCore::RenderThemeMac::imageControlsButtonSize):
35458
354592014-04-23  Carlos Garcia Campos  <cgarcia@igalia.com>
35460
35461        [GTK] HTML Media capture attribute is a boolean since r163958
35462        https://bugs.webkit.org/show_bug.cgi?id=132061
35463
35464        Reviewed by Gustavo Noronha Silva.
35465
35466        Add new methods webkit_dom_html_input_element_get_capture_enabled
35467        and webkit_dom_html_input_element_set_capture_enabled using a
35468        boolean and deprecate the old methods.
35469
35470        * bindings/gobject/WebKitDOMDeprecated.cpp:
35471        (webkit_dom_html_input_element_get_capture):
35472        (webkit_dom_html_input_element_set_capture):
35473        * bindings/gobject/WebKitDOMDeprecated.h:
35474        * bindings/gobject/WebKitDOMDeprecated.symbols:
35475        * bindings/gobject/webkitdom.symbols:
35476        * bindings/scripts/CodeGeneratorGObject.pm:
35477        (GetEffectiveFunctionName): Helper function to rename API methods
35478        for special cases.
35479        (GenerateFunction): Use GetEffectiveFunctionName().
35480
354812014-04-23  Praveen R Jadhav  <praveen.j@samsung.com>
35482
35483        [MediaStream] Implement MediaStream active attribute
35484        https://bugs.webkit.org/show_bug.cgi?id=131973
35485
35486        Reviewed by Eric Carlson.
35487
35488        MediaStream .active attribute are introduced which will replace
35489        .ended attribute. This patch implements the newly introduced attributes.
35490
35491        MediaStream-add-remove-tracks.html is updated to handle this scenario.
35492
35493        * Modules/mediastream/MediaStream.cpp:
35494        (WebCore::MediaStream::active): Added.
35495        (WebCore::MediaStream::setActive): Added.
35496        (WebCore::MediaStream::addTrack): Propagates 'onactive' event when required.
35497        (WebCore::MediaStream::removeTrack): Propagates 'oninactive' event when required.
35498        (WebCore::MediaStream::trackDidEnd): Propagates 'oninactive' event when required.
35499        (WebCore::MediaStream::streamDidEnd):
35500        (WebCore::MediaStream::setStreamIsActive): Added.
35501        * Modules/mediastream/MediaStream.h:
35502        * Modules/mediastream/MediaStream.idl:
35503        * dom/EventNames.h:
35504        * platform/mediastream/MediaStreamPrivate.cpp:
35505        (WebCore::MediaStreamPrivate::MediaStreamPrivate): Initialize .active attribute
35506        (WebCore::MediaStreamPrivate::setEnded):
35507        (WebCore::MediaStreamPrivate::setActive): Added.
35508        * platform/mediastream/MediaStreamPrivate.h:
35509        (WebCore::MediaStreamPrivate::active): Added.
35510
355112014-04-23  Darin Adler  <darin@apple.com>
35512
35513        [Cocoa] fix CF leaks found by code inspection
35514        https://bugs.webkit.org/show_bug.cgi?id=132106
35515
35516        Reviewed by Andreas Kling.
35517
35518        * page/CaptionUserPreferencesMediaAF.cpp:
35519        (WebCore::trackDisplayName): Added a missing adoptCF.
35520
35521        * platform/Language.cpp:
35522        (WebCore::displayNameForLanguageLocale): Added a missing adoptCF.
35523
35524        * platform/graphics/FontPlatformData.cpp:
35525        (WebCore::FontPlatformData::openTypeTable): Added a missing adoptCF.
35526
35527        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.cpp:
35528        (WebCore::InbandTextTrackPrivateAVCF::label): Added two missing adoptCF.
35529
35530        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
35531        (WebCore::AVFWrapper::createImageForTimeInRect): Added two missing adoptCF.
35532
35533        * platform/graphics/cg/PDFDocumentImage.cpp:
35534        (WebCore::PDFDocumentImage::createPDFDocument): Added missing adoptCF.
35535
35536        * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
35537        (WebCore::cascadeToLastResortFontDescriptor): Added two missing adoptCF.
35538
35539        * platform/graphics/mac/FontMac.mm:
35540        (WebCore::Font::primaryFontDataIsSystemFont): Added missing adoptCF.
35541
35542        * platform/graphics/mac/SimpleFontDataMac.mm:
35543        (WebCore::hasCustomTracking): Added missing adoptCF.
35544
35545        * platform/image-decoders/ImageDecoder.h:
35546        (WebCore::ImageDecoder::qcmsOutputDeviceProfile): Added CFRelease.
35547
35548        * plugins/mac/PluginPackageMac.cpp:
35549        (WebCore::readPListFile): Added two missing adoptCF.
35550
355512014-04-23  Ryosuke Niwa  <rniwa@webkit.org>
35552
35553        REGRESSION (r157328): popover to check into flight ba.com dismisses instantly when focusing form
35554        https://bugs.webkit.org/show_bug.cgi?id=131949
35555
35556        Address the review comment.
35557
35558        * dom/EventDispatcher.cpp:
35559        (WebCore::EventRelatedNodeResolver::findHostOfTreeScopeInTargetTreeScope):
35560
355612014-04-23  Andreas Kling  <akling@apple.com>
35562
35563        CachedResourceLoader hoards URLs indefinitely for no good reason.
35564        <https://webkit.org/b/132102>
35565        <rdar://problem/16708265>
35566
35567        Since we don't care about CachedResourceLoader::m_validatedURL's after
35568        the Document has finished dispatching its initial load event, clear the
35569        set at that point, and don't add any new URLs to it.
35570
35571        Reviewed by Anders Carlsson.
35572
35573        * dom/Document.cpp:
35574        (WebCore::Document::dispatchWindowLoadEvent):
35575        * loader/cache/CachedResourceLoader.cpp:
35576        (WebCore::CachedResourceLoader::requestResource):
35577        (WebCore::CachedResourceLoader::documentDidFinishLoadEvent):
35578        * loader/cache/CachedResourceLoader.h:
35579
355802014-04-23  Andreas Kling  <akling@apple.com>
35581
35582        Canvas cache of clean URLs can grow without bounds.
35583        <https://webkit.org/b/132091>
35584        <rdar://problem/16695665>
35585
35586        Remove a silly "optimization" that kept a cache of clean URLs
35587        that can be drawn into a canvas without tainting it, all to avoid
35588        the "expensive" checks to determine whether it would taint.
35589
35590        Reviewed by Benjamin Poulain.
35591
35592        * html/canvas/CanvasRenderingContext.cpp:
35593        (WebCore::CanvasRenderingContext::wouldTaintOrigin):
35594        * html/canvas/CanvasRenderingContext.h:
35595
355962014-04-23  Benjamin Poulain  <bpoulain@apple.com>
35597
35598        [iOS][WK2] Fix a few mistakes affecting the initial layout and the initial unobscured rect
35599        https://bugs.webkit.org/show_bug.cgi?id=132093
35600
35601        Reviewed by Tim Horton.
35602
35603        Change the minimum layout size to float point values to account for size defined on retina displays.
35604        The minimum layout size supports half-pixels, the value is rounded later when computing the layout size
35605        in document coordinates.
35606
35607        * WebCore.exp.in:
35608        * page/ViewportConfiguration.cpp:
35609        (WebCore::ViewportConfiguration::ViewportConfiguration):
35610        Setting the initial content size is incorrect. The layout size computation already take into account
35611        empty size for the first layout.
35612
35613        Setting the content size upfront make the first computation incorrect when the viewport arguments specify
35614        the initial scale.
35615
35616        (WebCore::ViewportConfiguration::setMinimumLayoutSize):
35617        * page/ViewportConfiguration.h:
35618        (WebCore::ViewportConfiguration::minimumLayoutSize):
35619
356202014-04-23  Brent Fulgham  <bfulgham@apple.com>
35621
35622        [Mac, iOS] Stop buffering media when on an inactive tab. 
35623        https://bugs.webkit.org/show_bug.cgi?id=132077
35624
35625        Reviewed by Eric Carlson.
35626
35627        * html/HTMLMediaElement.cpp: Rename 'm_isDisplaySleepDisablingSuspended'
35628        to 'm_elementIsHidden'.
35629        (WebCore::HTMLMediaElement::HTMLMediaElement):
35630        (WebCore::HTMLMediaElement::visibilityStatusChanged): Notify the
35631        media session that the element is (or is not) hidden.
35632        (WebCore::HTMLMediaElement::setShouldBufferData): Added.
35633        * html/HTMLMediaElement.h:
35634        * platform/audio/MediaSession.cpp:
35635        (WebCore::MediaSession::clientWillBeginPlayback): Tell media to
35636        buffer if not hidden or playing.
35637        (WebCore::MediaSession::clientWillPausePlayback): Ditto.
35638        (WebCore::MediaSession::visibilityChanged): Added. Client API, just relays call
35639        to updateClientDataBuffering.
35640        (WebCore::MediaSession::updateClientDataBuffering): Tell client it should only
35641        buffer data if it's currently playing, or not hidden.
35642        * platform/audio/MediaSession.h:
35643        * platform/graphics/MediaPlayer.cpp:
35644        (WebCore::MediaPlayer::setShouldBufferData): Added: Just relays to
35645        MediaPlayerPrivate object.
35646        * platform/graphics/MediaPlayer.h:
35647        * platform/graphics/MediaPlayerPrivate.h:
35648        (WebCore::MediaPlayerPrivateInterface::setShouldBufferData):
35649        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
35650        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
35651        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
35652        (WebCore::MediaPlayerPrivateAVFoundationObjC::setShouldBufferData): Added.
35653        Detach the player item from the player if we don't want to continue
35654        buffering or other background tasks.
35655
356562014-04-23  Alexey Proskuryakov  <ap@apple.com>
35657
35658        Eliminate internals.setMockScrollbarsEnabled()
35659        https://bugs.webkit.org/show_bug.cgi?id=132085
35660
35661        Reviewed by Tim Horton.
35662
35663        This was essentially unused, and also didnt work.
35664
35665        * testing/InternalSettings.cpp:
35666        (WebCore::InternalSettings::Backup::restoreTo):
35667        (WebCore::InternalSettings::setMockScrollbarsEnabled): Deleted.
35668        * testing/InternalSettings.h:
35669        * testing/InternalSettings.idl:
35670
356712014-04-23  Anders Carlsson  <andersca@apple.com>
35672
35673        Don't migrate the WKView.h header from WebCore to WebKit
35674        https://bugs.webkit.org/show_bug.cgi?id=132086
35675
35676        Reviewed by Dan Bernstein.
35677
35678        * WebCore.xcodeproj/project.pbxproj:
35679        Add WAKViewInternal.h.
35680
35681        * platform/WAKViewInternal.h: Added.
35682
35683        * platform/ios/wak/WAKClipView.m:
35684        Import WAKViewInternal.h instead of WAKViewPrivate.h.
35685
35686        * platform/ios/wak/WAKScrollView.mm:
35687        Import WAKViewInternal.h instead of WAKViewPrivate.h.
35688
35689        * platform/ios/wak/WAKView.h:
35690        Move ivars to a class extension in WAKViewInternal.h and remove WKView.h import.
35691
35692        * platform/ios/wak/WAKView.mm:
35693        Import WAKViewInternal.h instead of WAKViewPrivate.h.
35694
35695        * platform/ios/wak/WAKViewPrivate.h:
35696        Import WKViewPrivate.h.
35697
356982014-04-23  David Hyatt  <hyatt@apple.com>
35699
35700        [New Multicolumn] fast/multicol/fixed-column-percent-logical-height-orthogonal-writing-mode.html fails
35701        https://bugs.webkit.org/show_bug.cgi?id=132078
35702
35703        Reviewed by Anders Carlsson.
35704
35705        * rendering/RenderBox.cpp:
35706        (WebCore::RenderBox::skipContainingBlockForPercentHeightCalculation):
35707        Add a parameter to test for orthogonal writing modes. If we're perpendicular,
35708        then we should not skip the flow thread, since we resolve relative to the column width,
35709        and that is always set.
35710
35711        (WebCore::RenderBox::computePercentageLogicalHeight):
35712        Patched to pass in whether or not the box and the ancestor block are perpendicular.
35713
35714        * rendering/RenderBox.h:
35715        Patched the signature of skipContainingBlockForPercentHeightCalculation
35716
357172014-04-23  Myles C. Maxfield  <mmaxfield@apple.com>
35718
35719        [OS X] Make checking if a font is the system font more robust
35720        https://bugs.webkit.org/show_bug.cgi?id=132030
35721
35722        Reviewed by Dean Jackson.
35723
35724        Instead of inspecting a font's name to determine if it is a system font,
35725        on OS X we can ask the system directly.
35726
35727        This patch also moves a platform-specific check into platform-specific
35728        code, so that other platforms don't check for OS X-specific behavior.
35729
35730        Covered by existing tests.
35731
35732        * platform/graphics/Font.cpp:
35733        (WebCore::Font::hasValidAverageCharWidth):
35734        * platform/graphics/Font.h:
35735        * platform/graphics/mac/FontMac.mm:
35736        (WebCore::Font::primaryFontDataIsSystemFont):
35737
357382014-04-23  David Hyatt  <hyatt@apple.com>
35739
35740        [New Multicolumn] Assertion failure in huge-column-count.html
35741        https://bugs.webkit.org/show_bug.cgi?id=132071
35742
35743        Reviewed by Dean Jackson.
35744
35745        * rendering/RenderBlock.cpp:
35746        (WebCore::RenderBlock::regionAtBlockOffset):
35747        Back out this change, since it wasn't general enough.
35748
35749        * rendering/RenderFlowThread.cpp:
35750        (WebCore::RenderFlowThread::getRegionRangeForBox):
35751        The real issue was that this loop needed to consider the actual box
35752        rather than starting from the parent. This was a non-issue for normal
35753        regions (which cannot have nested flow threads), but for columns, you 
35754        have to consider the fact that the box could itself be a flow thread.
35755
357562014-04-23  Andreas Kling  <akling@apple.com>
35757
35758        [iOS] Memory pressure notification should fire on main thread.
35759        <https://webkit.org/b/132074>
35760
35761        Rejig the memory pressure notification to fire on the main queue
35762        directly instead of rerouting it manually.
35763
35764        Reviewed by Mark Rowe.
35765
35766        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
35767        (WebCore::MemoryPressureHandler::install):
35768
357692014-04-23  Commit Queue  <commit-queue@webkit.org>
35770
35771        Unreviewed, rolling out r167720.
35772        https://bugs.webkit.org/show_bug.cgi?id=132075
35773
35774        broke eight newmulticol tests (Requested by thorton on
35775        #webkit).
35776
35777        Reverted changeset:
35778
35779        "[New Multicolumn] Assertion failure in huge-column-
35780        count.html"
35781        https://bugs.webkit.org/show_bug.cgi?id=132071
35782        http://trac.webkit.org/changeset/167720
35783
357842014-04-23  David Hyatt  <hyatt@apple.com>
35785
35786        [New Multicolumn] Assertion failure in huge-column-count.html
35787        https://bugs.webkit.org/show_bug.cgi?id=132071
35788
35789        Reviewed by Dean Jackson.
35790
35791        * rendering/RenderBlock.cpp:
35792        (WebCore::RenderBlock::regionAtBlockOffset):
35793        Remove the code that returned 0 here, since we're going to patch a lower-level
35794        function to catch all cases.
35795
35796        * rendering/RenderFlowThread.cpp:
35797        (WebCore::RenderFlowThread::getRegionRangeForBox):
35798        Don't allow in-flow RenderFlowThreads to ever have a region range. The sets
35799        are what should have ranges... the flow thread needs to just be ignored.
35800
358012014-04-23  David Hyatt  <hyatt@apple.com>
35802
35803        [New Multicolumn] Crasher when clearing out a flow thread in multicolumn layout.
35804        https://bugs.webkit.org/show_bug.cgi?id=132069
35805
35806        Reviewed by Dean Jackson.
35807
35808        This is imported from a patch Morten did for Blink, but I had to change it a fair
35809        bit. deleteLines() is used to handle simple line box layout instead of just calling
35810        deleteLineBoxTree.
35811        
35812        I also had to disable the layout state to stop asserts on repaint when the children
35813        get moved. Not sure why Blink didn't hit this, but it's simple enough to add a
35814        LayoutStateDisabler to stop the assert.
35815
35816        Added fast/multicol/inline-children-crash.html
35817
35818        * rendering/RenderMultiColumnFlowThread.cpp:
35819        (WebCore::RenderMultiColumnFlowThread::evacuateAndDestroy):
35820
358212014-04-23  Andreas Kling  <akling@apple.com>
35822
35823        [iOS WebKit2] IOSurfacePool should force CA to actually garbage collect surfaces.
35824        <https://webkit.org/b/132065>
35825        <rdar://problem/16110687>
35826
35827        Add a platformGarbageCollectNow() helper function to IOSurfacePool that
35828        triggers a sweep of the IOSurfaces. Call this from collectionTimerFired()
35829        and discardAllSurfaces().
35830
35831        This lets us drop all otherwise-unused 420f surfaces on memory pressure.
35832
35833        Reviewed by Tim Horton.
35834
35835        * WebCore.xcodeproj/project.pbxproj:
35836        * platform/graphics/cg/IOSurfacePool.cpp:
35837        (WebCore::IOSurfacePool::collectionTimerFired):
35838        (WebCore::IOSurfacePool::discardAllSurfaces):
35839        * platform/graphics/cg/IOSurfacePool.h:
35840        * platform/graphics/cocoa/IOSurfacePoolCocoa.mm: Added.
35841        (WebCore::IOSurfacePool::platformGarbageCollectNow):
35842
358432014-04-23  Morten Stenshorne  <mstensho@opera.com>
35844
35845        REGRESSION (Safari 6 - ToT): Incorrectly assumes that RenderStyle data can be shared
35846        https://bugs.webkit.org/show_bug.cgi?id=113058
35847
35848        Reviewed by David Hyatt.
35849
35850        Before sharing CSS properties with an element in the cache, we need to
35851        check that the new element is suitable for this, just like we check
35852        elements before inserting them into the cache.
35853
35854        Test: fast/css/identical-logical-height-decl.html
35855
35856        * css/StyleResolver.cpp:
35857        (WebCore::StyleResolver::applyMatchedProperties):
35858
358592014-04-23  Commit Queue  <commit-queue@webkit.org>
35860
35861        Unreviewed, rolling out r167713.
35862        https://bugs.webkit.org/show_bug.cgi?id=132070
35863
35864        broke hundreds of tests (Requested by thorton on #webkit).
35865
35866        Reverted changeset:
35867
35868        "[OS X] Make checking if a font is the system font more
35869        robust"
35870        https://bugs.webkit.org/show_bug.cgi?id=132030
35871        http://trac.webkit.org/changeset/167713
35872
358732014-04-22  David Hyatt  <hyatt@apple.com>
35874
35875        [New Multicolumn] Nested columns not working at all.
35876        https://bugs.webkit.org/show_bug.cgi?id=131805
35877
35878        Reviewed by Dean Jackson.
35879
35880        Add support for nested pagination contexts, allowing for an arbitrary level
35881        of nesting of multicolumn layouts. There were a number of things that had to
35882        be patched in order for this to work.
35883
35884        * rendering/RenderBlock.cpp:
35885        (WebCore::RenderBlock::regionAtBlockOffset):
35886        Make sure RenderMultiColumnFlowThreads just return null for regions at any
35887        block offset. Individual region sets will be created as you cross ancestor
35888        regions eventually, so this is just getting in the way.
35889
35890        * rendering/RenderLayer.cpp:
35891        (WebCore::RenderLayer::enclosingPaginationLayerInSubtree):
35892        Add a new helper method for obtaining an enclosingPaginationLayer when
35893        constrained by some root. This function ensures you don't accidentally
35894        cross your subtree root when looking for enclosing pagination layers.
35895
35896        (WebCore::RenderLayer::collectFragments):
35897        Patch collectFragments to know how to recur to collect ancestor fragments
35898        in order to apply nested splitting as you cross pagination boundaries.
35899
35900        (WebCore::RenderLayer::updatePaintingInfoForFragments):
35901        (WebCore::RenderLayer::calculateClipRects):
35902        * rendering/RenderLayer.h:
35903        (WebCore::LayerFragment::LayerFragment):
35904        (WebCore::LayerFragment::setRects):
35905        (WebCore::LayerFragment::moveBy):
35906        (WebCore::LayerFragment::intersect):
35907        Improve the LayerFragment so that it caches transformed bounding boxes as
35908        well. This is needed to fix intersectsDamageRect so that it doesn't grab
35909        the wrong bounding box when checking inline layers that are paginated.
35910
35911        * rendering/RenderMultiColumnFlowThread.cpp:
35912        (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantInserted):
35913        Ignore inserted flow threads inside an ancestor flow thread, since we only
35914        care about what the sets do.
35915        
35916        * rendering/RenderObject.cpp:
35917        (WebCore::RenderObject::insertedIntoTree):
35918        Make sure that nested flow thread layers return themselves when a child
35919        is inserted directly under them.
35920
359212014-04-22  Myles C. Maxfield  <mmaxfield@apple.com>
35922
35923        [OS X] Make checking if a font is the system font more robust
35924        https://bugs.webkit.org/show_bug.cgi?id=132030
35925
35926        Reviewed by Dean Jackson.
35927
35928        Instead of inspecting a font's name to determine if it is a system font,
35929        on OS X we can ask the system directly.
35930
35931        This patch also moves a platform-specific check into platform-specific
35932        code, so that other platforms don't check for OS X-specific behavior.
35933
35934        Covered by existing tests.
35935
35936        * platform/graphics/Font.cpp:
35937        (WebCore::Font::hasValidAverageCharWidth):
35938        * platform/graphics/Font.h:
35939        * platform/graphics/mac/FontMac.mm:
35940        (WebCore::Font::primaryFontDataIsSystemFont):
35941
359422014-04-23  Philippe Normand  <pnormand@igalia.com>
35943
35944        [GTK] Focus management API was moved from HTMLDocument to Document in r166668
35945        https://bugs.webkit.org/show_bug.cgi?id=132060
35946
35947        Reviewed by Carlos Garcia Campos.
35948
35949        Deprecate the removed methods in WebKitDOMHTMLDocument to keep API compatibility.
35950
35951        * bindings/gobject/WebKitDOMDeprecated.cpp:
35952        (webkit_dom_html_document_get_active_element):
35953        (webkit_dom_html_document_has_focus):
35954        * bindings/gobject/WebKitDOMDeprecated.h:
35955        * bindings/gobject/WebKitDOMDeprecated.symbols:
35956        * bindings/gobject/webkitdom.symbols:
35957
359582014-04-22  Andreas Kling  <akling@apple.com>
35959
35960        [iOS WebKit1] MemoryPressureHandler::respondToMemoryPressure called on wrong thread.
35961        <https://webkit.org/b/132041>
35962        <rdar://problem/16687238>
35963
35964        Always dispatch the memory pressure relief code on the main queue.
35965        This is really only needed for iOS/WK1, but we might as well share the code.
35966
35967        Reviewed by Michael Saboff.
35968
35969        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
35970        (WebCore::MemoryPressureHandler::install):
35971
359722014-04-23  Philippe Normand  <pnormand@igalia.com>
35973
35974        [GTK] ShadowRoot API was removed in r164131
35975        https://bugs.webkit.org/show_bug.cgi?id=132059
35976
35977        Reviewed by Gustavo Noronha Silva.
35978
35979        Add ShadowRoot removed API to WebKitDOMDeprecated to keep API/ABI compatibility.
35980
35981        * bindings/gobject/WebKitDOMDeprecated.cpp:
35982        (webkit_dom_shadow_root_class_init):
35983        (webkit_dom_shadow_root_init):
35984        (webkit_dom_shadow_root_element_from_point):
35985        (webkit_dom_shadow_root_get_active_element):
35986        (webkit_dom_shadow_root_get_apply_author_styles):
35987        (webkit_dom_shadow_root_get_element_by_id):
35988        (webkit_dom_shadow_root_get_elements_by_class_name):
35989        (webkit_dom_shadow_root_get_elements_by_tag_name):
35990        (webkit_dom_shadow_root_get_elements_by_tag_name_ns):
35991        (webkit_dom_shadow_root_get_inner_html):
35992        (webkit_dom_shadow_root_get_reset_style_inheritance):
35993        (webkit_dom_shadow_root_get_selection):
35994        (webkit_dom_shadow_root_set_apply_author_styles):
35995        (webkit_dom_shadow_root_set_inner_html):
35996        (webkit_dom_shadow_root_set_reset_style_inheritance):
35997        * bindings/gobject/WebKitDOMDeprecated.h:
35998        * bindings/gobject/WebKitDOMDeprecated.symbols:
35999
360002014-04-23  Morten Stenshorne  <mstensho@opera.com>
36001
36002        [New Multicolumn] fast/multicol/overflow-content.html displays red
36003        https://bugs.webkit.org/show_bug.cgi?id=131809
36004
36005        Reviewed by David Hyatt.
36006
36007        Insert a break at end of content on our own in the multicol code, to make sure
36008        that overflow is accounted for, and also to make sure that we account for all
36009        content in non-final sets (i.e. those preceding spanners).
36010
36011        In other words, this will additionally fix balancing issues in sets preceding
36012        a spanner. Added a test for that.
36013
36014        Tests: fast/multicol/break-in-columns-before-spanner.html
36015               fast/multicol/newmulticol/compare-with-old-impl/overflow-content.html
36016
36017        * rendering/RenderFlowThread.cpp:
36018        (WebCore::RenderFlowThread::regionInRange): Deleted.
36019        * rendering/RenderFlowThread.h:
36020        * rendering/RenderMultiColumnSet.cpp:
36021        (WebCore::RenderMultiColumnSet::distributeImplicitBreaks):
36022        * rendering/RenderNamedFlowThread.cpp:
36023        (WebCore::RenderNamedFlowThread::applyBreakAfterContent):
36024        * rendering/RenderNamedFlowThread.h:
36025
360262014-04-23  Morten Stenshorne  <mstensho@opera.com>
36027
36028        Overflow propagation broken in BTT and RTL writing-modes
36029        https://bugs.webkit.org/show_bug.cgi?id=113781
36030
36031        Reviewed by David Hyatt.
36032
36033        Overflow rectangles are not quite physical, not quite logical. This
36034        means that we cannot use clientBoxRect() directly to represent a
36035        rectangle that expresses exactly no overflow. This rectangle is the
36036        padding box (relative to the border box) in vertical-lr and
36037        horizontal-tb, but the block-direction borders need to be flipped in
36038        vertical-rl and horizontal-bt.
36039
36040        Tests: fast/css/overflow-btt-border-after.html
36041               fast/css/overflow-rtl-border-after.html
36042
36043        * WebCore.exp.in:
36044        * rendering/RenderBlock.cpp:
36045        (WebCore::RenderBlock::computeOverflow):
36046        * rendering/RenderBox.cpp:
36047        (WebCore::RenderBox::addLayoutOverflow):
36048        (WebCore::RenderBox::addVisualOverflow):
36049        (WebCore::RenderBox::layoutOverflowRectForPropagation):
36050        * rendering/RenderBox.h:
36051        (WebCore::RenderBox::layoutOverflowRect):
36052
360532014-04-23  Andrei Bucur  <abucur@adobe.com>
36054
36055        [CSS Regions] Improve the debugging infrastructure
36056        https://bugs.webkit.org/show_bug.cgi?id=132042
36057
36058        Reviewed by Mihnea Ovidenie.
36059
36060        This patch improves the debugging code for CSS Regions.
36061
36062        Tests: No function change. No new tests.
36063
36064        * rendering/RenderObject.cpp:
36065        (WebCore::RenderObject::showRegionsInformation): Print brackets around the region range when dumping
36066        the render tree to the console.
36067        * rendering/RootInlineBox.cpp:
36068        (WebCore::RootInlineBox::containingRegion): Convert the ASSERT to an ASSERT_WITH_SECURITY_IMPLICATION.
36069
360702014-04-22  Ryosuke Niwa  <rniwa@webkit.org>
36071
36072        Cursor doesn't change back to pointer when leaving the Safari window
36073        https://bugs.webkit.org/show_bug.cgi?id=132038
36074
36075        Reviewed by Alexey Proskuryakov.
36076
36077        r147739 incorrectly added an early exit in EventHandler::selectCursor when hit test result didn't have
36078        any node associated with it. Since we will hit this code when the cursor is outside of the WebView,
36079        we still need to take the CURSOR_AUTO path as did the code before r147739.
36080
36081        No new test is added since this behavior can't be tested in DRT or WTR.
36082
36083        * page/EventHandler.cpp:
36084        (WebCore::EventHandler::selectCursor):
36085
360862014-04-22  Zalan Bujtas  <zalan@apple.com>
36087
36088        Do not paint border image when the border rect is empty.
36089        https://bugs.webkit.org/show_bug.cgi?id=131988
36090
36091        Reviewed by Darin Adler.
36092
36093        http://trac.webkit.org/changeset/167351 introduced an early return when border
36094        rect is empty. This patch ensures that border image is not painted either in that case.
36095
36096        Modified padding-margin-negative-border.html to cover border-image case.
36097
36098        * rendering/RenderBoxModelObject.cpp:
36099        (WebCore::RenderBoxModelObject::paintBorder):
36100
361012014-04-22  Tim Horton  <timothy_horton@apple.com>
36102
36103        ASSERTION FAILED: scrollerImp == scrollbarPainterForScrollbar(_scrollbar) on two API tests
36104        https://bugs.webkit.org/show_bug.cgi?id=132034
36105        <rdar://problem/16624332>
36106
36107        Reviewed by Simon Fraser.
36108
36109        * platform/mac/ScrollAnimatorMac.mm:
36110        (-[WebScrollbarPainterDelegate shouldUseLayerPerPartForScrollerImp:]):
36111        scrollerImpWithStyle:controlSize:horizontal:replacingScrollerImp: moves the delegate
36112        from the old scrollerImp to the new one, and also happens to call shouldUseLayerPerPartForScrollerImp.
36113        Since scrollerImpWithStyle: has not returned yet, the scrollbarPainterForScrollbar still returns the old scrollerImp,
36114        so this assertion fires. It's safe to remove this because supportsUpdateOnSecondaryThread doesn't make use of the imp.
36115
361162014-04-22  Ryosuke Niwa  <rniwa@webkit.org>
36117
36118        REGRESSION (r157328): popover to check into flight ba.com dismisses instantly when focusing form
36119        https://bugs.webkit.org/show_bug.cgi?id=131949
36120
36121        Reviewed by Darin Adler.
36122
36123        The regression was caused by two bugs:
36124        1. The event didn't stop propagating itself even when it should.
36125           If the related target is same as the event origin, the event propagation should stop when the event reaches
36126           the root of the related target's tree scope. Otherwise, it should stop when it reaches the related target.
36127
36128        2. Mouse event's related target exposed nodes inside a user-agent shadow DOM when the related target appeared
36129           inside the origin.
36130
36131        Fixed the bugs by re-introducing path shrinkage algorithm removed in r157328 into EventPath::setRelatedTarget
36132        and adding an algorithm to determine the least common ancestor of the related target and the current target
36133        in moveToParentOrShadowHost. The latter algorithm doesn't match the shadow DOM specification:
36134        http://www.w3.org/TR/2013/WD-shadow-dom-20130514/
36135        but it's good enough in terms of the Web exposed behavior as we don't support author defined insertion points.
36136
36137        Test: fast/events/shadow-event-path.html
36138
36139        * dom/EventDispatcher.cpp:
36140        (WebCore::EventRelatedNodeResolver::moveToParentOrShadowHost):
36141        (WebCore::EventRelatedNodeResolver::findHostOfTreeScopeInTargetTreeScope): Added.
36142        (WebCore::EventDispatcher::dispatchEvent):
36143        (WebCore::EventPath::setRelatedTarget):
36144
361452014-04-22  Ryosuke Niwa  <rniwa@webkit.org>
36146
36147        Rollout r156635 since the old behavior was intentional.
36148
36149        * page/EventHandler.cpp:
36150        (WebCore::EventHandler::selectCursor):
36151
361522014-04-22  Commit Queue  <commit-queue@webkit.org>
36153
36154        Unreviewed, rolling out r167674.
36155        https://bugs.webkit.org/show_bug.cgi?id=132025
36156
36157        Going a different way with this (Requested by bradee-oh on
36158        #webkit).
36159
36160        Reverted changeset:
36161
36162        "Change Image Controls replacement to use selection and paste"
36163        https://bugs.webkit.org/show_bug.cgi?id=131992
36164        http://trac.webkit.org/changeset/167674
36165
361662014-04-22  Brent Fulgham  <bfulgham@apple.com>
36167
36168        [Win] Support Python 2.7 in Cygwin
36169        https://bugs.webkit.org/show_bug.cgi?id=132023
36170
36171        Reviewed by Michael Saboff.
36172
36173        * DerivedSources.make: Use proper path to Cygwin on
36174        all platforms.
36175
361762014-04-22  Andreas Kling  <akling@apple.com>
36177
36178        REGRESSION (r151839): Subframe keeps getting mousemove events with the same coordinates after hiding a hovered element.
36179        <https://webkit.org/b/131974>
36180        <rdar://problem/15907469>
36181
36182        When the currently hovered element disappears as a result of style recalc,
36183        we send a fake mousemove event to the page, to see if anything newly added
36184        should become hovered.
36185
36186        The faking mechanism lives in EventHandler and simply synthesizes a new
36187        mousemove event using the last seen mouse location.
36188
36189        The problem here is that we were sending this fake mousemove event to the
36190        subframe where the hovered element lived. Since subframes aren't kept up
36191        to date on recent mouse locations, this could cause some strange behavior
36192        where a subframe would dispatch mousemove events with stale coordinates.
36193
36194        The solution is to always dispatch fake mousemove events from the main
36195        frame's event handler. This is how real event delivery happens, and hit
36196        testing will then find the appropriate subframe, if any.
36197
36198        Reviewed by Benjamin Poulain.
36199
36200        Test: fast/events/ghostly-mousemoves-in-subframe.html
36201
36202        * dom/Document.cpp:
36203        (WebCore::Document::recalcStyle):
36204
362052014-04-22  Myles C. Maxfield  <mmaxfield@apple.com>
36206
36207        [OS X] Glyph spacing for system fonts may be incorrect
36208        https://bugs.webkit.org/show_bug.cgi?id=131967
36209
36210        Unreviewed iOS build fix after r167679.
36211
36212        * platform/graphics/mac/SimpleFontDataMac.mm:
36213
362142014-04-22  Myles C. Maxfield  <mmaxfield@apple.com>
36215
36216        [OS X] Glyph spacing for system fonts may be incorrect
36217        https://bugs.webkit.org/show_bug.cgi?id=131967
36218
36219        Unreviewed build fix after r167679.
36220
36221        * platform/graphics/mac/SimpleFontDataMac.mm:
36222        (WebCore::hasCustomTracking):
36223
362242014-04-21  Myles C. Maxfield  <mmaxfield@apple.com>
36225
36226        [OS X] Glyph spacing for system fonts may be incorrect
36227        https://bugs.webkit.org/show_bug.cgi?id=131967
36228
36229        Reviewed by Simon Fraser.
36230
36231        Covered by existing tests.
36232
36233        * platform/graphics/mac/SimpleFontDataMac.mm:
36234        (WebCore::SimpleFontData::platformWidthForGlyph): Update to use CTFontGetAdvancesForGlyphs() for system fonts
36235        (WebCore::hasCustomTracking):
36236
362372014-04-22  David Hyatt  <hyatt@apple.com>
36238
36239        [New Multicolumn] widows/orphans cause assertion failures.
36240        https://bugs.webkit.org/show_bug.cgi?id=131233
36241
36242        Reviewed by Dean Jackson.
36243
36244        * rendering/RenderMultiColumnSet.cpp:
36245        (WebCore::RenderMultiColumnSet::recordSpaceShortage):
36246        Fix an obvious bug where the space shortage is recorded twice (and the
36247        if statement that kept it from being negative is accidentally ignored).
36248
362492014-04-22  David Hyatt  <hyatt@apple.com>
36250
36251        [New Multicolumn] Make sure columnTranslationForOffset has the same column-span-aware
36252        translation that fragment collection does.
36253        https://bugs.webkit.org/show_bug.cgi?id=131738
36254
36255        Reviewed by Anders Carlsson.
36256
36257        * rendering/RenderMultiColumnSet.cpp:
36258        (WebCore::RenderMultiColumnSet::collectLayerFragments):
36259        Remove a FIXME that is no longer needed, since the translation offset of the 
36260        column set did get patched.
36261
36262        (WebCore::RenderMultiColumnSet::columnTranslationForOffset):
36263        Add the exact same fix to columnTranslationForOffset that was applied to collectLayerFragments.
36264
362652014-04-22  Mark Lam  <mark.lam@apple.com>
36266
36267        WebCore::HTMLMediaElement::ensureMediaControlsInjectedScript() needs to acquire the JSLock before calling into JS.
36268        <https://webkit.org/b/132021>
36269
36270        Reviewed by Mark Hahnenberg.
36271
36272        Covered by existing layout test.
36273
36274        * html/HTMLMediaElement.cpp:
36275        (WebCore::HTMLMediaElement::parseAttribute):
36276
362772014-04-22  Manuel Rego Casasnovas  <rego@igalia.com>
36278
36279        REGRESSION (r167652): Broke fast/regions/cssom/region-range-for-box-crash.html in debug mode
36280        https://bugs.webkit.org/show_bug.cgi?id=131982
36281
36282        Reviewed by David Hyatt.
36283
36284        The problem was creating the Range from the arguments received at RenderView::setSelection(). Specifically
36285        in this test endPos is 1 when the element has not children which creates an invalid Range.
36286
36287        * rendering/RenderView.cpp:
36288        (WebCore::RenderView::splitSelectionBetweenSubtrees): Pass 0 as startPos and endPos to Range::create() as we are
36289        not interested in the positions at this point.
36290
362912014-04-22  Brady Eidson  <beidson@apple.com>
36292
36293        Change Image Controls replacement to use selection and paste
36294        <rdar://problem/16302722> and https://bugs.webkit.org/show_bug.cgi?id=131992
36295
36296        Reviewed by Tim Horton.
36297
36298        * WebCore.exp.in: Remove deleted symbol.
36299
36300        * html/shadow/mac/ImageControlsButtonElementMac.cpp:
36301        (WebCore::ImageControlsButtonElementMac::defaultEventHandler):
36302
36303        * page/ContextMenuController.cpp:
36304        (WebCore::ContextMenuController::showImageControlsMenu): Select the image element
36305          before showing the menu.
36306        (WebCore::ContextMenuController::replaceControlledImage): Deleted.
36307        * page/ContextMenuController.h:
36308
363092014-04-22  David Hyatt  <hyatt@apple.com>
36310
36311        REGRESSION: Hitting asserts in new flow thread selection code.
36312        https://bugs.webkit.org/show_bug.cgi?id=132019
36313
36314        Reviewed by Anders Carlsson.
36315
36316        Null checking flowThreadController is not enough. The list of threads
36317        can be null even when the flowThreadController is not. That's why you
36318        use hasRenderNamedFlowThreads. I patched the two bad places in the code
36319        to use hasRenderNamedFlowThreads to stop the crashes.
36320        
36321        * rendering/RenderView.cpp:
36322        (WebCore::RenderView::selectionBounds):
36323        (WebCore::RenderView::repaintSelection):
36324
363252014-04-22  Brent Fulgham  <bfulgham@apple.com>
36326
36327        Check (rather than assume) element is a RenderTableSection before using it
36328        https://bugs.webkit.org/show_bug.cgi?id=121858
36329
36330        Reviewed by David Kilzer.
36331
36332        Test: fast/table/table-insert-object-before-td-crash.html
36333
36334        * rendering/RenderTable.cpp:
36335        (WebCore::RenderTable::addChild): Check that lastBox is a table section before
36336        using the node as if it was one.
36337
363382014-04-22  Alex Christensen  <achristensen@webkit.org>
36339
36340        Begin implementation of video using Media Foundation.
36341        https://bugs.webkit.org/show_bug.cgi?id=131830
36342
36343        Reviewed by Brent Fulgham.
36344
36345        * WebCore.vcxproj/WebCore.vcxproj:
36346        * WebCore.vcxproj/WebCore.vcxproj.filters:
36347        Added MediaPlayerPrivateMediaFoundation files.
36348        * platform/graphics/MediaPlayer.cpp:
36349        Include MediaPlayerPrivateMediaFoundation inside new USE(MEDIA_FOUNDATION) flag.
36350        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.cpp: Added.
36351        * platform/graphics/win/MediaPlayerPrivateMediaFoundation.h: Added.
36352
363532014-04-22  Commit Queue  <commit-queue@webkit.org>
36354
36355        Unreviewed, rolling out r167658.
36356        https://bugs.webkit.org/show_bug.cgi?id=131993
36357
36358        Caused many crashes on media tests (Requested by ap on
36359        #webkit).
36360
36361        Reverted changeset:
36362
36363        "[Mac] don't ask for AVAssetTrack properties before they are
36364        available"
36365        https://bugs.webkit.org/show_bug.cgi?id=131902
36366        http://trac.webkit.org/changeset/167658
36367
363682014-04-22  David Hyatt  <hyatt@apple.com>
36369
36370        [New Multicolumn] fast/multicol/multicol-with-child-renderLayer-for-input.html puts the textfield in the wrong place
36371        https://bugs.webkit.org/show_bug.cgi?id=131808
36372
36373        Reviewed by Brady Eidson.
36374    
36375        Make sure FrameView is patched to pass in the update pagination flag when subtree layout
36376        is done on textfields. It had code for the old multicolumn system but did not have a check
36377        for the new multicolumn system.
36378
36379        Added fast/multicol/newmulticol/compare-with-old-impl/multicol-with-child-renderLayer-for-input.html
36380
36381        * page/FrameView.cpp:
36382        (WebCore::updateLayerPositionFlags):
36383
363842014-04-22  Zalan Bujtas  <zalan@apple.com>
36385
36386        border-style: double rendered as solid when combined with border-radius
36387        https://bugs.webkit.org/show_bug.cgi?id=131927
36388
36389        Reviewed by Simon Fraser.
36390
36391        BorderEdge::getDoubleBorderStripeWidths() should return the calculated inner, outer border widths. 
36392
36393        Test: fast/borders/hidpi-double-border-with-border-radius-always-produce-solid-line.html
36394
36395        * rendering/BorderEdge.cpp:
36396        (WebCore::BorderEdge::getDoubleBorderStripeWidths):
36397        * rendering/BorderEdge.h:
36398
363992014-04-22  Eric Carlson  <eric.carlson@apple.com>
36400
36401        [Mac] don't ask for AVAssetTrack properties before they are available
36402        https://bugs.webkit.org/show_bug.cgi?id=131902
36403        <rdar://problem/16505076>
36404
36405        Reviewed by Jer Noble.
36406
36407        No new tests, the behavior this changes can not be tested with a layout test.
36408
36409        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
36410        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
36411        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize
36412            m_cachedTotalBytes.
36413        (WebCore::MediaPlayerPrivateAVFoundationObjC::beginLoadingMetadata): Don't report that
36414            metadata has been loaded until the track properties we need have been loaded too.
36415        (WebCore::MediaPlayerPrivateAVFoundationObjC::totalBytes): Cache totalBytes instead
36416            of recalculating it every time.
36417        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksDidChange): Invalidate cached
36418            total bytes.
36419        (WebCore::assetTrackMetadataKeyNames): Array of AVAssetTrack properties we use.
36420
364212014-04-22  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
36422
36423        Buildfix after r167650 broke non-Cocoa builds
36424        https://bugs.webkit.org/show_bug.cgi?id=131980
36425
36426        Reviewed by Mario Sanchez Prada.
36427
36428        * page/EventHandler.cpp:
36429        (WebCore::EventHandler::handleWheelEvent):
36430
364312014-04-22  Manuel Rego Casasnovas  <rego@igalia.com>
36432
36433        [CSS Regions] Selection highlight doesn't match DOM selection
36434        https://bugs.webkit.org/show_bug.cgi?id=131511
36435
36436        Reviewed by David Hyatt.
36437
36438        This patch implements a subtrees approach to fix selection interaction in CSS Regions.
36439
36440        The idea is to divide the Render tree in subtrees. One subtree will be the RenderView (which is always present),
36441        then for each RenderNamedFlowThread (which are children of RenderView) we will have an extra subtree.
36442
36443        For each subtree it determines the start and end positions according to the DOM tree. So, every subtree will
36444        always have a start and end position, and the selection algorithm will be able to reach the end from the start
36445        without problems (this allows us to remove the changes introduced in r155058).
36446
36447        Then selection related methods in RenderView are adapted to ensure that they are called for each subtree. Making
36448        the selection highlight to match DOM selection as expected.
36449
36450        Test: fast/regions/selection/selecting-text-including-region.html
36451
36452        * CMakeLists.txt: Add new class SelectionSubtreeRoot to build file.
36453        * WebCore.vcxproj/WebCore.vcxproj: Ditto.
36454        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
36455        * WebCore.xcodeproj/project.pbxproj: Ditto.
36456        * rendering/RenderNamedFlowThread.h: Inherit from SelectionSubtreeRoot.
36457        * rendering/RenderObject.cpp:
36458        (WebCore::RenderObject::selectionRoot): New method to return the RenderNamedFlowThread if any or the RenderView
36459        otherwise.
36460        (WebCore::RenderObject::selectionStartEnd): If it's inside a RenderNamedFlowThread use specific method instead
36461        of the RenderView's one.
36462        * rendering/RenderObject.h: Add new method signature.
36463        * rendering/RenderView.cpp:
36464        (WebCore::RenderView::selectionBounds): Adapt method to subtrees approach.
36465        (WebCore::RenderView::subtreeSelectionBounds): Modify previous method in order to use SelectionSubtreeRoot
36466        objects.
36467        (WebCore::RenderView::repaintSelection): Adapt method to subtrees approach.
36468        (WebCore::RenderView::repaintSubtreeSelection): Modify previous method in order to use SelectionSubtreeRoot
36469        objects.
36470        (getNextOrPrevRenderObjectBasedOnDirection): Deleted method from r155058 as it is not needed anymore. Each
36471        subtree will have start and end positions, so the selection algorithm will always find the end.
36472        (WebCore::RenderView::setSelection): Adapt method to subtrees approach.
36473        (WebCore::RenderView::splitSelectionBetweenSubtrees): Determine start and end positions for each subtree and
36474        call setSubtreeSelection().
36475        (WebCore::RenderView::setSubtreeSelection): Modify previous method in order to use SelectionSubtreeRoot objects.
36476        * rendering/RenderView.h: Inherit from SelectionSubtreeRoot. Add signature for new helper methods receiving
36477        SelectionSubtreeRoot objects.
36478        * rendering/SelectionSubtreeRoot.cpp: Added.
36479        (WebCore::SelectionSubtreeRoot::SelectionSubtreeRoot):
36480        (WebCore::SelectionSubtreeRoot::selectionStartEndPositions):
36481        * rendering/SelectionSubtreeRoot.h: Added. New class to identify root elements for the subtrees. With some basic
36482        attributes and methods to store the start and end positions and offsets.
36483        (WebCore::SelectionSubtreeRoot::selectionStart):
36484        (WebCore::SelectionSubtreeRoot::selectionStartPos):
36485        (WebCore::SelectionSubtreeRoot::selectionEnd):
36486        (WebCore::SelectionSubtreeRoot::selectionEndPos):
36487        (WebCore::SelectionSubtreeRoot::setSelectionStart):
36488        (WebCore::SelectionSubtreeRoot::setSelectionStartPos):
36489        (WebCore::SelectionSubtreeRoot::setSelectionEnd):
36490        (WebCore::SelectionSubtreeRoot::setSelectionEndPos):
36491
364922014-04-21  Brent Fulgham  <bfulgham@apple.com>
36493
36494        [Mac] Follow-up: After a horizontal overflow scroll with a mechanical wheel mouse, vertical scrolling no longer works
36495        https://bugs.webkit.org/show_bug.cgi?id=131960
36496        <rdar://problem/16142100>
36497
36498        Unreviewed build fix.
36499
36500        * page/EventHandler.cpp:
36501        (WebCore::EventHandler::handleWheelEvent): The test to clear the
36502        last scrolled node was too broad. It should only follow this path
36503        if both the phase and momentum phase are 'None'.
36504
365052014-04-21  Brent Fulgham  <bfulgham@apple.com>
36506
36507        [Mac] After a horizontal overflow scroll with a mechanical wheel mouse, vertical scrolling no longer works
36508        https://bugs.webkit.org/show_bug.cgi?id=131960
36509        <rdar://problem/16142100>
36510
36511        Reviewed by Darin Adler.
36512
36513        Test: platform/mac/fast/scrolling/scroll-div-no-latching.html
36514
36515        * page/EventHandler.cpp:
36516        (WebCore::EventHandler::handleWheelEvent): When not latching, always clear m_latchedWheelEventElement and m_previousWheelScrolledElement.
36517
365182014-04-21  Joseph Pecoraro  <pecoraro@apple.com>
36519
36520        WebProfilerAgent::disable is calling the wrong superclass method
36521        https://bugs.webkit.org/show_bug.cgi?id=131968
36522
36523        Reviewed by Simon Fraser.
36524
36525        * inspector/WebProfilerAgent.cpp:
36526        (WebCore::WebProfilerAgent::disable):
36527
365282014-04-21  Enrica Casucci  <enrica@apple.com>
36529
36530        Followup from http://trac.webkit.org/changeset/167624
36531
36532        Reviewed by Darin Adler.
36533
36534        Fixing incorrect use of ? : syntax.
36535
36536        * editing/VisibleUnits.cpp:
36537        (WebCore::characterBeforePosition):
36538
365392014-04-21  Ryuan Choi  <ryuan.choi@samsung.com>
36540
36541        Move CoordinatedGraphics related codes out of CMakeLists.txt
36542        https://bugs.webkit.org/show_bug.cgi?id=131931
36543
36544        Reviewed by Gyuyoung Kim.
36545
36546        Move CoordinatedGraphics related files to PlatformEfl.cmake because they are not common files.
36547
36548        * CMakeLists.txt: 
36549        * PlatformEfl.cmake:
36550
365512014-04-21  Jer Noble  <jer.noble@apple.com>
36552
36553        [MSE][Mac] AVSampleBufferDisplayLayer and AudioRenderer is overretained.
36554        https://bugs.webkit.org/show_bug.cgi?id=131963
36555
36556        Reviewed by Jon Honeycutt.
36557
36558        Adopt the results of -[[class alloc] init] rather than retaining them.
36559
36560        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
36561        (WebCore::SourceBufferPrivateAVFObjC::hasVideo):
36562        (WebCore::SourceBufferPrivateAVFObjC::trackDidChangeEnabled):
36563
365642014-04-21  Zalan Bujtas  <zalan@apple.com>
36565
36566        REGRESSION (r166784): Gradient at background of iCloud login page doesn’t go all the way to the bottom
36567        https://bugs.webkit.org/show_bug.cgi?id=131924
36568
36569        Computing tile dimension for contain/cover requires higher precision than what LayoutUnit has. Switching to floats.
36570
36571        Reviewed by Simon Fraser.
36572
36573        Test: fast/backgrounds/hidpi-background-image-contain-cover-scale-needs-more-precision.html
36574
36575        * rendering/RenderBoxModelObject.cpp:
36576        (WebCore::RenderBoxModelObject::calculateFillTileSize):
36577
365782014-04-21  Dean Jackson  <dino@apple.com>
36579
36580        Build fix for Mountain Lion.
36581
36582        * platform/mac/SerializedPlatformRepresentationMac.mm:
36583        (WebCore::SerializedPlatformRepresentationMac::deserialize):
36584
365852014-04-21  Dan Bernstein  <mitz@apple.com>
36586
36587        WebCore part of <rdar://problem/16631323> Page::setDefersLoading doesn’t do anything when using the Network process
36588        https://bugs.webkit.org/show_bug.cgi?id=131939
36589
36590        Reviewed by David Kilzer.
36591
36592        * WebCore.exp.in: Exported WebCore::ResourceHandle::setDefersLoading.
36593
36594        * loader/ResourceLoadScheduler.cpp:
36595        (WebCore::ResourceLoadScheduler::setDefersLoading): Added a no-op implementation.
36596        * loader/ResourceLoadScheduler.h: Declared new virtual member function setDefersLoading.
36597
36598        * loader/ResourceLoader.cpp:
36599        (WebCore::ResourceLoader::setDefersLoading): Added a call to the above function.
36600
366012014-04-21  Brent Fulgham  <bfulgham@apple.com>
36602
36603        [Mac] Difficulty gesture scrolling vertically with trackpad after scrolling horizontally 
36604        https://bugs.webkit.org/show_bug.cgi?id=131959
36605        <rdar://problem/16654523>
36606
36607        Reviewed by Simon Fraser.
36608
36609        * page/mac/EventHandlerMac.mm:
36610        (WebCore::deltaIsPredominantlyVertical): Added.
36611        (WebCore::scrolledToEdgeInDominantDirection): Only consider current mouse wheel event. We don't care about
36612        overall history when deciding if we are bumping against the edge of a scrollable region. Short-circuit if
36613        the element style indicates that overflow is hidden, since this means there is no scroll possible in that
36614        direction.
36615        (WebCore::EventHandler::platformPrepareForWheelEvents): Update for new signature.
36616
366172014-04-21  Eric Carlson  <eric.carlson@apple.com>
36618
36619        [Mac] implement WebKitDataCue
36620        https://bugs.webkit.org/show_bug.cgi?id=131799
36621
36622        Reviewed by Dean Jackson.
36623
36624        Tests: http/tests/media/track-in-band-hls-metadata.html
36625               media/track/track-datacue-value.html
36626
36627        * Configurations/FeatureDefines.xcconfig: Define ENABLE_DATACUE_VALUE.
36628        * DerivedSources.make: Add ENABLE_DATACUE_VALUE to HTML_FLAGS when appropriate.
36629
36630        * CMakeLists.txt: Add JSDataCueCustom.cpp.
36631        * bindings/js/JSBindingsAllInOne.cpp:
36632        * WebCore.xcodeproj/project.pbxproj: Add new files.
36633
36634        * bindings/js/JSDataCueCustom.cpp: Added.
36635        (WebCore::JSDataCue::value): 
36636        (WebCore::JSDataCue::setValue):
36637        (WebCore::JSDataCueConstructor::constructJSDataCue): Custom constructor.
36638
36639        * html/HTMLMediaElement.cpp:
36640        (WebCore::HTMLMediaElement::updateActiveTextTrackCues): Drive-by fixes: don't schedule timeupdate
36641            events when paused, don't call sort on an Vector that can't be sorted.
36642
36643        * html/track/DataCue.cpp:
36644        (WebCore::DataCue::DataCue): Initialize m_type.
36645        (WebCore::DataCue::~DataCue): Unprotect the JSValue if necessary.
36646        (WebCore::DataCue::data): Ask the platform value for data if non-null.
36647        (WebCore::DataCue::setData): Clear m_platformValue and m_value.
36648        (WebCore::DataCue::isEqual): New.
36649        (WebCore::DataCue::value): Return a JSValue from the platform value, or the value passed
36650            to the constructor/set by script.
36651        (WebCore::DataCue::setValue): Set m_value.
36652        * html/track/DataCue.h:
36653        * html/track/DataCue.idl:
36654
36655        * html/track/InbandDataTextTrack.cpp:
36656        (WebCore::InbandDataTextTrack::addDataCue): Don't add the same cue more than once.
36657        (WebCore::InbandDataTextTrack::updateDataCue): Update a cue's duration.
36658        (WebCore::InbandDataTextTrack::removeDataCue): Remove an incomplete cue.
36659        (WebCore::InbandDataTextTrack::removeCue): Remove a cue from the incomplete cue map if necessary.
36660        * html/track/InbandDataTextTrack.h:
36661
36662        * html/track/InbandGenericTextTrack.cpp:
36663        (WebCore::InbandGenericTextTrack::addGenericCue): CueMatchRules is now in TextTrackCue instead
36664            of VTTCue.
36665        * html/track/InbandTextTrack.h:
36666
36667        * html/track/InbandWebVTTTextTrack.cpp:
36668        (WebCore::InbandWebVTTTextTrack::newCuesParsed): Ditto.
36669
36670        * html/track/TextTrack.cpp:
36671        (WebCore::TextTrack::hasCue): Ditto.
36672        * html/track/TextTrack.h:
36673
36674        * html/track/TextTrackCue.cpp:
36675        (WebCore::TextTrackCue::isEqual): New, test base class equality.
36676        * html/track/TextTrackCue.h:
36677
36678        * html/track/TextTrackCueGeneric.cpp:
36679        (WebCore::TextTrackCueGeneric::isEqual): Call TextTrackCue::isEqual first.
36680        * html/track/TextTrackCueGeneric.h:
36681
36682        * html/track/VTTCue.cpp:
36683        (WebCore::VTTCue::isEqual): Call TextTrackCue::isEqual first.
36684        * html/track/VTTCue.h:
36685
36686        * platform/SerializedPlatformRepresentation.h: Added.
36687        (WebCore::SerializedPlatformRepresentation::~SerializedPlatformRepresentation):
36688        (WebCore::SerializedPlatformRepresentation::SerializedPlatformRepresentation):
36689
36690        * platform/graphics/InbandTextTrackPrivateClient.h: Add methods for DataCue with SerializedPlatformRepresentation.
36691
36692        * platform/graphics/avfoundation/InbandMetadataTextTrackPrivateAVF.cpp: Added.
36693        (WebCore::InbandMetadataTextTrackPrivateAVF::create):
36694        (WebCore::InbandMetadataTextTrackPrivateAVF::InbandMetadataTextTrackPrivateAVF):
36695        (WebCore::InbandMetadataTextTrackPrivateAVF::~InbandMetadataTextTrackPrivateAVF):
36696        (WebCore::InbandMetadataTextTrackPrivateAVF::addDataCue):
36697        (WebCore::InbandMetadataTextTrackPrivateAVF::updatePendingCueEndTimes):
36698        (WebCore::InbandMetadataTextTrackPrivateAVF::flushPartialCues):
36699        * platform/graphics/avfoundation/InbandMetadataTextTrackPrivateAVF.h: Added.
36700
36701        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
36702        (WebCore::MediaPlayerPrivateAVFoundation::seekWithTolerance): currentTrack -> currentTextTrack.
36703        (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted): Ditto.
36704        (WebCore::MediaPlayerPrivateAVFoundation::configureInbandTracks): Ditto.
36705        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
36706        (WebCore::MediaPlayerPrivateAVFoundation::setCurrentTextTrack):
36707        (WebCore::MediaPlayerPrivateAVFoundation::setCurrentTrack): Deleted.
36708
36709        Renamed currentTrack and setCurrentTrack to currentTextTrack and setCurrentTextTrack.
36710        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
36711        (WebCore::AVFWrapper::currentTextTrack):
36712        (WebCore::MediaPlayerPrivateAVFoundationCF::setCurrentTextTrack):
36713        (WebCore::MediaPlayerPrivateAVFoundationCF::currentTextTrack):
36714        (WebCore::AVFWrapper::setCurrentTextTrack):
36715        (WebCore::AVFWrapper::AVFWrapper):
36716        (WebCore::AVFWrapper::processCue):
36717        (WebCore::AVFWrapper::currentTrack): Deleted.
36718        (WebCore::MediaPlayerPrivateAVFoundationCF::setCurrentTrack): Deleted.
36719        (WebCore::MediaPlayerPrivateAVFoundationCF::currentTrack): Deleted.
36720        (WebCore::AVFWrapper::setCurrentTrack): Deleted.
36721        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
36722
36723        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
36724        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
36725        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
36726        (WebCore::MediaPlayerPrivateAVFoundationObjC::seekToTime): currentTrack -> currentTextTrack
36727        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): currentTrack -> currentTextTrack.
36728        (WebCore::MediaPlayerPrivateAVFoundationObjC::processMetadataTrack): New.
36729        (WebCore::MediaPlayerPrivateAVFoundationObjC::processCue): m_currentTrack -> m_currentTextTrack.
36730        (WebCore::MediaPlayerPrivateAVFoundationObjC::flushCues): Ditto.
36731        (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTextTrack): Renamed from setCurrentTextTrack.
36732        (WebCore::metadataType): Map an AVFoundation metadata key space to a metadata cue type.
36733        (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive): Process new metadata.
36734        (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]):
36735        (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTrack): Deleted.
36736
36737        Create a JSValue representation from an AVMetadataItem.
36738        * platform/mac/SerializedPlatformRepresentationMac.h: Added.
36739        (WebCore::SerializedPlatformRepresentationMac::platformType):
36740        (WebCore::SerializedPlatformRepresentationMac::nativeValue):
36741        * platform/mac/SerializedPlatformRepresentationMac.mm: Added.
36742        (WebCore::SerializedPlatformRepresentationMac::SerializedPlatformRepresentationMac):
36743        (WebCore::SerializedPlatformRepresentationMac::~SerializedPlatformRepresentationMac):
36744        (WebCore::SerializedPlatformRepresentationMac::create):
36745        (WebCore::SerializedPlatformRepresentationMac::data):
36746        (WebCore::SerializedPlatformRepresentationMac::deserialize):
36747        (WebCore::SerializedPlatformRepresentationMac::isEqual):
36748        (WebCore::toSerializedPlatformRepresentationMac):
36749        (WebCore::jsValueWithValueInContext):
36750        (WebCore::jsValueWithDataInContext):
36751        (WebCore::jsValueWithArrayInContext):
36752        (WebCore::jsValueWithDictionaryInContext):
36753        (WebCore::jsValueWithAVMetadataItemInContext):
36754
367552014-04-21  Benjamin Poulain  <benjamin@webkit.org>
36756
36757        Add Element.matches, the standard name for webkitMatchesSelector
36758        https://bugs.webkit.org/show_bug.cgi?id=131922
36759
36760        Reviewed by Andreas Kling.
36761
36762        This patch just renames webkitMatchesSelector() to matches().
36763
36764        * bindings/scripts/CodeGeneratorObjC.pm:
36765        (GenerateImplementation):
36766        The Objective-C binding generator only supported ImplementedAs for getters and setters.
36767        This adds support for the option so that Element.matches can be generated for Obj-C.
36768
36769        * dom/Element.cpp:
36770        (WebCore::Element::matches):
36771        (WebCore::Element::webkitMatchesSelector): Deleted.
36772        * dom/Element.h:
36773        * dom/Element.idl:
36774        * inspector/InspectorCSSAgent.cpp:
36775        (WebCore::InspectorCSSAgent::buildArrayForMatchedRuleList):
36776
367772014-04-21  Beth Dakin  <bdakin@apple.com>
36778
36779        topContentInset does not play well with fullscreen elements
36780        https://bugs.webkit.org/show_bug.cgi?id=131955
36781        -and corresponding-
36782        <rdar://problem/16651925>
36783
36784        Reviewed by Sam Weinig.
36785
36786        Calling setNeedsLayout() is not sufficient when the topContentInset has changed 
36787        dynamically. We need to perform the layout right away and update the scrollbars. 
36788        This works completely when the inset changes due to entering/exiting fullscreen, 
36789        but I left a FIXME behind because it is possible to change the inset dynamically 
36790        just through the WK2 API and end up in a situation where everything looks right 
36791        except for the scrollbars. 
36792        * page/FrameView.cpp:
36793        (WebCore::FrameView::topContentInsetDidChange):
36794        * page/FrameView.h:
36795        * page/Page.cpp:
36796        (WebCore::Page::setTopContentInset):
36797
367982014-04-18  Jon Honeycutt  <jhoneycutt@apple.com>
36799
36800        Empty RenderInline objects should not be line break objects.
36801
36802        https://bugs.webkit.org/show_bug.cgi?id=131861
36803        <rdar://problem/15663617>
36804
36805        Reviewed by David Hyatt.
36806
36807        * rendering/line/BreakingContextInlineHeaders.h:
36808        (WebCore::BreakingContext::canBreakAtThisPosition):
36809        Don't break at this position if this is an empty RenderInline.
36810
368112014-04-21  Enrica Casucci  <enrica@apple.com>
36812
36813        [iOS WebKit2] support replacements for misspelled words.
36814        https://bugs.webkit.org/show_bug.cgi?id=131827
36815        <rdar://problem/16319657>
36816
36817        Reviewed by Darin Adler.
36818
36819        Adds utility function to return the character before the current selection
36820        and converts the nbsp to the space character.
36821
36822        * WebCore.exp.in:
36823        * editing/VisibleUnits.cpp:
36824        (WebCore::characterBeforePosition):
36825        * editing/VisibleUnits.h:
36826
368272014-04-21  Eric Carlson  <eric.carlson@apple.com>
36828
36829        [iOS] enable plug-in replacement
36830        https://bugs.webkit.org/show_bug.cgi?id=131947
36831
36832        Reviewed by Jer Noble.
36833
36834        * bindings/generic/RuntimeEnabledFeatures.cpp:
36835        (WebCore::RuntimeEnabledFeatures::RuntimeEnabledFeatures): initialize m_isPluginReplacementEnabled
36836            to true on iOS.
36837
368382014-04-21  Rik Cabanier  <cabanier@adobe.com>
36839
36840        [CSS Blending] Remove support for non-separable blend modes from mix-blend-mode
36841        https://bugs.webkit.org/show_bug.cgi?id=131824
36842
36843        Reviewed by Dean Jackson.
36844
36845        Removed support for non-separable blend modes from the CSS parser.
36846
36847        Covered by existing tests
36848
36849        * css/CSSParser.cpp:
36850        (WebCore::isValidKeywordPropertyAndValue):
36851        * platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
36852        (PlatformCAFilters::setBlendingFiltersOnLayer):
36853
368542014-04-21  David Hyatt  <hyatt@apple.com>
36855
36856        [New Multicolumn] Column set drawing under horizontal scrollbar.
36857        https://bugs.webkit.org/show_bug.cgi?id=131812.
36858
36859        Reviewed by Sam Weinig.
36860
36861        Added fast/multicol/newmulticol/compare-with-old-impl/LeftToRight-tb.html.
36862
36863        * rendering/RenderBlockFlow.cpp:
36864        (WebCore::RenderBlockFlow::layoutBlock):
36865        (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
36866        * rendering/RenderBlockFlow.h:
36867        Pass in relayoutChildren as a reference boolean to checkForPaginationLogicalHeightChange.
36868        The new columns need to be able to set it to true if the amount of available column
36869        height ever changes, so that the RenderFlowThread and the sets get a layout call.
36870
36871        * rendering/style/RenderStyle.cpp:
36872        (WebCore::RenderStyle::setColumnStylesFromPaginationMode):
36873        Make sure that the pagination mode is set up with an auto column-fill specified. You
36874        don't ever want to balance when you set a pagination mode on the RenderView.
36875
368762014-04-21  Tim Horton  <timothy_horton@apple.com>
36877
36878        [iOS WebKit2] Implement CSS viewport units
36879        https://bugs.webkit.org/show_bug.cgi?id=131863
36880        <rdar://problem/16279088>
36881
36882        Reviewed by Darin Adler.
36883
36884        * WebCore.exp.in:
36885        * page/FrameView.cpp:
36886        (WebCore::FrameView::setViewportSize):
36887        * page/FrameView.h:
36888        (WebCore::FrameView::viewportSize):
36889        Add setViewportSize() and viewportSize().
36890        If the viewport size changes, we have to do style recalc.
36891        If we have an overridden viewport size, use it.
36892
36893        * rendering/RenderView.cpp:
36894        (WebCore::RenderView::viewportSize):
36895        * rendering/RenderView.h:
36896        Get the size from FrameView.
36897
368982014-04-21  Joseph Pecoraro  <pecoraro@apple.com>
36899
36900        Remove unused WebKitSystemInterface functions
36901        https://bugs.webkit.org/show_bug.cgi?id=131938
36902
36903        Reviewed by Alexey Proskuryakov.
36904
36905        * WebCore.exp.in:
36906        * platform/ios/WebCoreSystemInterfaceIOS.mm:
36907        * platform/mac/WebCoreSystemInterface.h:
36908        * platform/mac/WebCoreSystemInterface.mm:
36909
369102014-04-21  Andreas Kling  <akling@apple.com>
36911
36912        Move the JSString cache from DOMWrapperWorld to VM.
36913        <https://webkit.org/b/131940>
36914
36915        Since there's no need for JSStrings to be world-specific, this patch
36916        moves the string cache to JSC::VM. This makes jsStringWithCache()
36917        a lot faster since it no longer has to jump through twenty-eleven
36918        hoops to find the DOMWrapperWorld.
36919
36920        Reviewed by Geoff Garen.
36921
36922        * bindings/js/DOMWrapperWorld.cpp:
36923        (WebCore::DOMWrapperWorld::clearWrappers):
36924        * bindings/js/DOMWrapperWorld.h:
36925        * bindings/js/JSDOMBinding.cpp:
36926        (WebCore::jsStringWithCache):
36927
369282014-04-21  David Hyatt  <hyatt@apple.com>
36929
36930        [New Multicolumn] Column balancing is slow on float-multicol.html
36931        https://bugs.webkit.org/show_bug.cgi?id=131801
36932
36933        Reviewed by Enrica Casucci.
36934
36935        Added fast/multicol/tall-float.html
36936
36937        * rendering/RenderBlock.cpp:
36938        (WebCore::RenderBlock::expandsToEncloseOverhangingFloats):
36939        Make RenderFlowThreads expand to encompass floats. Also from Morten's patch for
36940        Blink (#361551).
36941
36942        * rendering/RenderBlockFlow.cpp:
36943        (WebCore::RenderBlockFlow::computeOverflow):
36944        Fix a bug where the new multi-column code was adding in overflow for floats
36945        when it should not. This was resulting in the creation of scrollbars when none
36946        should exist. This is my own addition.
36947
36948        (WebCore::RenderBlockFlow::addOverhangingFloats):
36949        Make RenderFlowThreads and RenderRegions ignore overhanging float additions. This
36950        comes from Morten's patch for Blink (#361551).
36951
369522014-04-21  Darin Adler  <darin@apple.com>
36953
36954        REGRESSION (r160908): Safari doesn't draw rotated images properly first time
36955        https://bugs.webkit.org/show_bug.cgi?id=131930
36956
36957        Reviewed by Anders Carlsson.
36958
36959        With render tree creation sufficiently lazy, we had to put some explicit
36960        calls to updateStyleIfNeeded into the ImageDocument class.
36961
36962        * dom/DOMImplementation.cpp:
36963        (WebCore::DOMImplementation::createDocument): Pass a Frame&.
36964
36965        * html/ImageDocument.cpp:
36966        (WebCore::ImageDocument::imageSize): Added this helper function. This updates
36967        style so we can use the renderer to compute an image size taking things like
36968        orientation into account, and also passes in the zoom factor.
36969        (WebCore::ImageDocument::updateDuringParsing): Moved the body of the
36970        ImageDocumentParser::appendBytes function into this function. Since it's a
36971        member of ImageDocument, it has better access to appropriate private members,
36972        and we don't have to expose as many functions to the public. Also changed to
36973        not use the frame so much. Also merged in the code that creates the document
36974        instead of having it be a side effect in the cachedImage helper function; all
36975        the other call sites were checking for null before calling cachedImage.
36976        (WebCore::ImageDocument::finishedParsing): Moved the body of the
36977        ImageDocumentParser::finish function here. Added a call to updateStyleIfNeeded
36978        before using the renderer to get the image size.
36979        (WebCore::ImageDocumentParser::document): Made this return a reference. It's
36980        just a convenience function used in the two functions below.
36981        (WebCore::ImageDocumentParser::appendBytes): Just call updateDuringParsing.
36982        (WebCore::ImageDocumentParser::finish): Just call finishedParsing.
36983        (WebCore::ImageDocument::ImageDocument): Take a reference for the argument,
36984        use nullptr, and also initialize m_shouldShrinkImage directly instead of using
36985        a shouldShrinkToFit() helper function to do it.
36986        (WebCore::ImageDocument::createDocumentStructure): Removed unneeded check of
36987        null for the frame, since the caller does it. Removed some unneeded
36988        IGNORE_EXCEPTON and a stray semicolon. Use m_shouldShrinkImage instead of
36989        calling shouldShrinkToFit since at this early point they will be identical.
36990        (WebCore::ImageDocument::scale): Make non-const so we can call the new
36991        imageSize helper. Use Document::view instead of Frame::view. Improved the
36992        conversion to floating point so it doesn't involve a static_cast and an extra
36993        conversion from int to LayoutUnit.
36994        (WebCore::ImageDocument::resizeImageToFit): Ditto.
36995        (WebCore::ImageDocument::imageClicked): Ditto.
36996        (WebCore::ImageDocument::imageUpdated): Ditto. Also use m_shouldShrinkImage
36997        ibnstead of shouldShrinkToFit.
36998        (WebCore::ImageDocument::restoreImageSize): Ditto.
36999        (WebCore::ImageDocument::imageFitsInWindow): Ditto.
37000        (WebCore::ImageDocument::windowSizeChanged): Ditto.
37001        (WebCore::ImageDocument::cachedImage): Deleted. Moved logic into updateDuringParsing.
37002        (WebCore::ImageDocument::shouldShrinkToFit): Deleted. Moved logic into constructor.
37003        (WebCore::ImageEventListener::handleEvent): Updated for changes above.
37004        (WebCore::ImageEventListener::operator==): Simplified. No reason this has to check
37005        whether both listeners are in the same document.
37006        (WebCore::ImageDocumentElement::didMoveToNewDocument): Use nullptr.
37007
37008        * html/ImageDocument.h: Deleted some unused things, updated for changes above,
37009        and made some memer functions private.
37010
37011        * loader/FrameLoaderClient.h: Deleted the allowScriptFromSource, allowPlugins,
37012        allowImage, and allowDisplayingInsecureContent functions. These were only used in
37013        Chromium and are now unneeded complexity. We could bring them back if anyone wants them.
37014
37015        * loader/MixedContentChecker.cpp:
37016        (WebCore::MixedContentChecker::canDisplayInsecureContent): Removed call to
37017        allowDisplayingInsecureContent, just use the setting directly.
37018        (WebCore::MixedContentChecker::canRunInsecureContent): Removed call to
37019        allowRunningInsecureContent, just use the setting directly.
37020
37021        * loader/SubframeLoader.cpp:
37022        (WebCore::SubframeLoader::allowPlugins): Removed call to allowPlugins, just
37023        use the arePluginsEnabled setting directly.
37024
37025        * loader/cache/CachedResourceLoader.cpp:
37026        (WebCore::CachedResourceLoader::canRequest): Removed call to allowScriptFromSource, just
37027        use the isScriptEnabled setting directly.
37028        (WebCore::CachedResourceLoader::clientDefersImage): Removed call to allowImage.
37029
370302014-04-21  David Hyatt  <hyatt@apple.com>
37031
37032        [New Multicolumn] Pagination mode messed up with non-inline axis and reversed direction.
37033        https://bugs.webkit.org/show_bug.cgi?id=131811
37034
37035        Reviewed by Dean Jackson.
37036
37037        Added fast/multicol/newmulticol/compare-with-old-impl/BottomToTop-tb.html
37038        
37039        With block axis pagination mode, it is possible to set a column height that is not the same
37040        as the available fill height for a block. The new multi-column code had the assumption that
37041        the column height was the same as the amount of fill room you had available. This is not
37042        the case.
37043        
37044        To correct the issue, I added a member variable to RenderMultiColumnSet that stores the
37045        available column height as a separate variable from the computed column height. This allows
37046        the pagination API to specify a different column height that is not the same as the view's
37047        content height.
37048
37049        Even though it isn't involved in the solution, I also patched pageOrViewLogicalHeight on
37050        RenderView to work with the new column code as well.
37051
37052        To address the layout test failures (that caused the previous rollout), I made sure to
37053        initialize m_availableHeight to 0 when m_computedColumnHeight also gets reset to 0.
37054        
37055        The assertion is not something I could reproduce on any machine, but I can see the problem.
37056        I patched Page's pageCount method to not have column code directly in Page.cpp, 
37057        and to make a new pageCount() method on RenderView that Page calls
37058        into. This method is now patched to handle the new column code as well as the old. I have
37059        no real way of testing this method though, since I can't reproduce the assertion that the
37060        bots were experiencing.
37061
37062        * page/Page.cpp:
37063        (WebCore::Page::pageCount):
37064        * rendering/RenderMultiColumnSet.cpp:
37065        (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
37066        (WebCore::RenderMultiColumnSet::setAndConstrainColumnHeight):
37067        (WebCore::RenderMultiColumnSet::prepareForLayout):
37068        (WebCore::RenderMultiColumnSet::computeLogicalHeight):
37069        * rendering/RenderMultiColumnSet.h:
37070        * rendering/RenderView.cpp:
37071        (WebCore::RenderView::pageOrViewLogicalHeight):
37072        (WebCore::RenderView::pageCount):
37073        * rendering/RenderView.h:
37074
370752014-04-18  Dean Jackson  <dino@apple.com>
37076
37077        [Media] Clean up localized strings in controls
37078        https://bugs.webkit.org/show_bug.cgi?id=131857
37079        <rdar://problem/16663005>
37080
37081        Reviewed by Eric Carlson.
37082
37083        There is no need for separate localization files
37084        on OS X and iOS. Move the small number of iOS-specific
37085        localizations into a shared file.
37086
37087        We also don't need a function to return a static table.
37088        Ultimately I think we want a top-level WebKit object that
37089        hold the table, but for now use a global variable
37090        called UIStringTable. Since we're in an isolated world, we
37091        won't clash with anything.
37092
37093        I noticed a few cases were we grab a localized string and
37094        then instantly run a replacement on it. This should be
37095        supported directly in the UIString() accessor.
37096
37097        * English.lproj/mediaControlsLocalizedStrings.js: Add iOS strings. Just
37098        use a static table.
37099        (mediaControlsLocalizedStrings): Deleted.
37100        * English.lproj/mediaControlsLocalizedStringsiOS.js: Removed.
37101        * Modules/mediacontrols/mediaControlsApple.js:
37102        (Controller.prototype.extend): Fix braces.
37103        (Controller.prototype.UIString): Use the string table, and allow replacement.
37104        (Controller.prototype.createControls): Use new UIString replacement.
37105        * Modules/mediacontrols/mediaControlsiOS.js:
37106        (ControllerIOS.prototype.updateWirelessPlaybackStatus): Use new UIString.
37107        (ControllerIOS.prototype.UIString): Deleted. Use the parent class version.
37108        * WebCore.xcodeproj/project.pbxproj: Remove file from Resources.
37109        * rendering/RenderThemeIOS.mm:
37110        (WebCore::RenderThemeIOS::mediaControlsScript): No need to include the iOS
37111        specific localization file.
37112
371132014-04-21  Brent Fulgham  <bfulgham@apple.com>
37114
37115        [Win] Unreviewed build fix.
37116
37117        * inspector/TimelineRecordFactory.cpp: Add missing include.
37118
371192014-04-21  Zan Dobersek  <zdobersek@igalia.com>
37120
37121        Move cross-port Source/WebCore/page/ code to std::unique_ptr
37122        https://bugs.webkit.org/show_bug.cgi?id=130534
37123
37124        Reviewed by Darin Adler.
37125
37126        Replace uses of OwnPtr and PassOwnPtr in cross-port code under Source/WebCore/page/ with
37127        std::unique_ptr. Unnecessary OwnPtr.h and PassOwnPtr.h header inclusions are removed as well.
37128
37129        * dom/Document.cpp:
37130        (WebCore::Document::initSecurityContext):
37131        * dom/SecurityContext.cpp:
37132        (WebCore::SecurityContext::setContentSecurityPolicy):
37133        * dom/SecurityContext.h:
37134        * page/CaptionUserPreferences.h:
37135        * page/ContentSecurityPolicy.cpp:
37136        (WebCore::CSPDirectiveList::create):
37137        (WebCore::CSPDirectiveList::checkEvalAndReportViolation):
37138        (WebCore::CSPDirectiveList::checkInlineAndReportViolation):
37139        (WebCore::CSPDirectiveList::checkSourceAndReportViolation):
37140        (WebCore::CSPDirectiveList::setCSPDirective):
37141        (WebCore::ContentSecurityPolicy::didReceiveHeader):
37142        * page/ContentSecurityPolicy.h:
37143        * page/DOMSecurityPolicy.h:
37144        * page/DOMWindow.cpp:
37145        (WebCore::PostMessageTimer::fired):
37146        (WebCore::DOMWindow::postMessageTimerFired):
37147        * page/DOMWindow.h:
37148        * page/EventHandler.cpp:
37149        (WebCore::EventHandler::EventHandler):
37150        * page/EventHandler.h:
37151        * page/Frame.cpp:
37152        (WebCore::Frame::Frame):
37153        (WebCore::createRegExpForLabels):
37154        (WebCore::Frame::searchForLabelsAboveCell):
37155        (WebCore::Frame::searchForLabelsBeforeElement):
37156        (WebCore::matchLabelsAgainstString):
37157        (WebCore::Frame::setTiledBackingStoreEnabled):
37158        * page/Frame.h:
37159        * page/FrameView.cpp:
37160        (WebCore::FrameView::addEmbeddedObjectToUpdate):
37161        (WebCore::FrameView::addSlowRepaintObject):
37162        (WebCore::FrameView::addViewportConstrainedObject):
37163        (WebCore::FrameView::addScrollableArea):
37164        * page/FrameView.h:
37165        * page/Page.cpp:
37166        (WebCore::Page::Page):
37167        * page/Page.h:
37168        * page/PageConsole.h:
37169        * page/PageThrottler.h:
37170        * page/SecurityPolicy.cpp:
37171        (WebCore::SecurityPolicy::addOriginAccessWhitelistEntry):
37172        * page/animation/AnimationController.h:
37173        * page/animation/CSSPropertyAnimation.cpp:
37174        (WebCore::PropertyWrapperVisitedAffectedColor::PropertyWrapperVisitedAffectedColor):
37175        (WebCore::CSSPropertyAnimationWrapperMap::instance):
37176        (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
37177        * page/mac/PageMac.cpp:
37178        (WebCore::Page::addSchedulePair):
37179        * workers/WorkerGlobalScope.cpp:
37180        (WebCore::WorkerGlobalScope::applyContentSecurityPolicyFromString):
37181
371822014-04-21  Darin Adler  <darin@apple.com>
37183
37184        Add HashSet::takeAny
37185        https://bugs.webkit.org/show_bug.cgi?id=131928
37186
37187        Reviewed by Benjamin Poulain.
37188
37189        * dom/Document.cpp:
37190        (WebCore::Document::takeAnyMediaCanStartListener): Use HashSet::takeAny.
37191        * dom/ScriptExecutionContext.cpp:
37192        (WebCore::takeAny): Deleted.
37193        (WebCore::ScriptExecutionContext::~ScriptExecutionContext): Use HashSet::takeAny.
37194
371952014-04-21  Zan Dobersek  <zdobersek@igalia.com>
37196
37197        iOS and non-iOS RemoteCommandListener::create() functions should use std::make_unique<>()
37198        https://bugs.webkit.org/show_bug.cgi?id=131916
37199
37200        Reviewed by Darin Adler.
37201
37202        A follow-up to r167197. Make RemoteCommandListener ctor public and use std::make_unique<>()
37203        in both versions of RemoteCommandListener::create() functions (iOS and non-iOS).
37204
37205        * platform/RemoteCommandListener.cpp:
37206        (WebCore::RemoteCommandListener::create):
37207        * platform/RemoteCommandListener.h:
37208        (WebCore::RemoteCommandListener::RemoteCommandListener):
37209        * platform/ios/RemoteCommandListenerIOS.mm:
37210        (WebCore::RemoteCommandListener::create):
37211
372122014-04-21  Andreas Kling  <akling@apple.com>
37213
37214        Micro-optimize the way we hand NodeLists to JSC.
37215        <https://webkit.org/b/131932>
37216
37217        Use HashMap::fastAdd() when returning cached node lists and collections.
37218        10.9% progression on Bindings/get-elements-by-tag-name.html
37219
37220        Reviewed by Antti Koivisto.
37221
37222        * dom/NodeRareData.h:
37223        (WebCore::NodeListsNodeData::addCacheWithAtomicName):
37224        (WebCore::NodeListsNodeData::addCacheWithName):
37225        (WebCore::NodeListsNodeData::addCacheWithQualifiedName):
37226        (WebCore::NodeListsNodeData::addCachedCollection):
37227
372282014-04-21  Commit Queue  <commit-queue@webkit.org>
37229
37230        Unreviewed, rolling out r167584.
37231        https://bugs.webkit.org/show_bug.cgi?id=131929
37232
37233        Broke Objective-C bindings test (Requested by ap on #webkit).
37234
37235        Reverted changeset:
37236
37237        "Add Element.matches, the standard name for
37238        webkitMatchesSelector"
37239        https://bugs.webkit.org/show_bug.cgi?id=131922
37240        http://trac.webkit.org/changeset/167584
37241
372422014-04-20  Benjamin Poulain  <benjamin@webkit.org>
37243
37244        Compile the :root pseudo class and fix a related issue with :nth-child()
37245        https://bugs.webkit.org/show_bug.cgi?id=131926
37246
37247        Reviewed by Andreas Kling.
37248
37249        Add the :root pseudo class. This is another trivial selector, we just need to compare
37250        the element pointer with the documentElement.
37251
37252        I discovered some issues with :nth-child(n) through the layout tests for ":root".
37253        When the pseudo class nth-child could match anything, no code was generated. That decision
37254        was taken when generating the fragments.
37255
37256        The specification of :nth-child() has two tests: the parent test and the counter test.
37257        Since some fragments would not generate any code for :nth-child(n), they would succeed on the root,
37258        which is incorrect since the root should fail the parent test.
37259
37260        This was fixed by moving the filtering of non-counting :nth-child() after we generate the parent
37261        check.
37262        We still don't generate any counter test unless required.
37263
37264        Test: fast/selectors/nth-child-on-root.html
37265
37266        * cssjit/SelectorCompiler.cpp:
37267        (WebCore::SelectorCompiler::addPseudoClassType):
37268        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
37269        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
37270        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsRoot):
37271        * dom/Document.h:
37272        (WebCore::Document::documentElementMemoryOffset):
37273
372742014-04-20  Benjamin Poulain  <benjamin@webkit.org>
37275
37276        Add Element.matches, the standard name for webkitMatchesSelector
37277        https://bugs.webkit.org/show_bug.cgi?id=131922
37278
37279        Reviewed by Andreas Kling.
37280
37281        This patch just renames webkitMatchesSelector() to matches().
37282
37283        * bindings/scripts/CodeGeneratorObjC.pm:
37284        (GenerateImplementation):
37285        The Objective-C binding generator only supported ImplementedAs for getters and setters.
37286        This adds support for the option so that Element.matches can be generated for Obj-C.
37287
37288        * dom/Element.cpp:
37289        (WebCore::Element::matches):
37290        (WebCore::Element::webkitMatchesSelector): Deleted.
37291        * dom/Element.h:
37292        * dom/Element.idl:
37293        * inspector/InspectorCSSAgent.cpp:
37294        (WebCore::InspectorCSSAgent::buildArrayForMatchedRuleList):
37295
372962014-04-20  Zalan Bujtas  <zalan@apple.com>
37297
37298        Subpixel rendering: RenderLayer's size is set using enclosingRect() which can result in cruft.
37299        https://bugs.webkit.org/show_bug.cgi?id=131468
37300
37301        Reviewed by Darin Adler.
37302
37303        Layers marked opaque may not paint edge pixels, when RenderLayer bounds are non-integral and
37304        get device pixel snapped.
37305        For details see this: https://trac.webkit.org/r159463
37306
37307        Test: compositing/hidpi-non-simple-compositing-layer-with-fractional-size-and-background.html
37308
37309        * rendering/RenderLayerBacking.cpp:
37310        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
37311
373122014-04-19  Darin Adler  <darin@apple.com>
37313
37314        Simple layout can get confused by coordinate overflow
37315        https://bugs.webkit.org/show_bug.cgi?id=131890
37316        rdar://problem/15558510
37317
37318        Reviewed by Andreas Kling.
37319
37320        Test: fast/css/simple-layout-overflow.html
37321
37322        * rendering/SimpleLineLayoutResolver.h:
37323        (WebCore::SimpleLineLayout::RunResolver::rangeForRect):
37324        If lastLine is smaller than firstLine, just ignore it.
37325
373262014-04-20  Darin Adler  <darin@apple.com>
37327
37328        ScriptExecutionContext::stopActiveDOMObjects iterates a hash map that can change during iteration (for multiple reasons, including GC)
37329        https://bugs.webkit.org/show_bug.cgi?id=52719
37330
37331        Reviewed by Alexey Proskuryakov.
37332
37333        At least two specific ways this can happen:
37334
37335        1) XMLHttpRequest::stop can trigger a JavaScript garbage collection.
37336        2) NotificationCenter::stop can delete the last references to notifications;
37337           those notifications are also active DOM objects.
37338
37339        Besides fixing the iteration in that function, did some other fixes for the
37340        ScriptExecutionContext class, including some coding style changes. Many uses
37341        of nullptr instead of 0, without listing each function separately below.
37342
37343        * Modules/webdatabase/DatabaseContext.cpp:
37344        (WebCore::DatabaseContext::contextDestroyed): Call through to the base class
37345        version of contextDestroyed rather than repeating what it does (with a large
37346        comment that doesn't acknowledge the base class alread does it).
37347        * Modules/webdatabase/DatabaseContext.h: Removed some unneeded includes.
37348        Wrote out "private" explicitly for deriving from ActiveDOMObject. Made the
37349        ActiveDOMObject function overrides private, and marked them override and final.
37350
37351        * dom/ActiveDOMObject.h: Updated comments. Replaced suspendIfNeededCalled with
37352        assertSuspendIfNeededWasCalled, which has an empty inline version in the header.
37353        Renamed m_suspendIfNeededCalled to m_suspendIfNeededWasCalled.
37354
37355        * dom/ActiveDOMObject.cpp:
37356        (WebCore::ActiveDOMObject::ActiveDOMObject): Pass a reference instead of a pointer.
37357        (WebCore::ActiveDOMObject::~ActiveDOMObject): Ditto.
37358        (WebCore::ActiveDOMObject::suspendIfNeeded): Ditto.
37359
37360        * dom/ContextDestructionObserver.cpp:
37361        (WebCore::ContextDestructionObserver::observeContext): Pass a reference instead of a pointer.
37362
37363        * dom/MessagePort.cpp:
37364        (WebCore::MessagePort::MessagePort): Pass a reference instead of a pointer.
37365        (WebCore::MessagePort::~MessagePort): Ditto.
37366        (WebCore::MessagePort::disentangle): Ditto.
37367
37368        * dom/ScriptExecutionContext.cpp:
37369        (WebCore::ScriptExecutionContext::ScriptExecutionContext): Updated flags used
37370        for assertions so they are conditional and updated their names.
37371        (WebCore::takeAny): Added. Helper function that we can consider for HashSet in
37372        the future; makes loop below easier to read.
37373        (WebCore::checkConsistency): Added. Assertions that were done multiple places below,
37374        and should not be written over and over again.
37375        (WebCore::ScriptExecutionContext::~ScriptExecutionContext): Changed to use C++11
37376        for loops and the takeAny function above.
37377        (WebCore::ScriptExecutionContext::dispatchMessagePortEvents): Ditto.
37378        (WebCore::ScriptExecutionContext::createdMessagePort): Changed to take a reference
37379        for clarity and so it doesn't have to do an assert the pointer is non-null.
37380        (WebCore::ScriptExecutionContext::destroyedMessagePort): Ditto.
37381        (WebCore::ScriptExecutionContext::canSuspendActiveDOMObjects): Changed to use
37382        C++11 for loop and reworded comment and redid assertions.
37383        (WebCore::ScriptExecutionContext::suspendActiveDOMObjects): Ditto.
37384        (WebCore::ScriptExecutionContext::resumeActiveDOMObjects): Ditto.
37385        (WebCore::ScriptExecutionContext::stopActiveDOMObjects): Changed to support
37386        removal of an active DOM object during the stop function. Included new comments
37387        to clarify what the rules are.
37388        (WebCore::ScriptExecutionContext::suspendActiveDOMObjectIfNeeded): Changed to take
37389        a reference for clarity and so it doesn't have to assert a pointer is non-null.
37390        (WebCore::ScriptExecutionContext::didCreateActiveDOMObject): Ditto. Also changed to
37391        use RELEASE_ASSERT instead of CRASH.
37392        (WebCore::ScriptExecutionContext::willDestroyActiveDOMObject): Ditto.
37393        (WebCore::ScriptExecutionContext::didCreateDestructionObserver): Ditto.
37394        (WebCore::ScriptExecutionContext::willDestroyDestructionObserver): Ditto.
37395        (WebCore::ScriptExecutionContext::closeMessagePorts): Moved the body of this
37396        function into its one call site, ScriptExecutionContext::stopActiveDOMObjects,
37397        since it's simple enough when written as a C++11 for loop.
37398        (WebCore::ScriptExecutionContext::hasPendingActivity): Added. This function was
37399        already exported for workers, and implementing it outside this class required
37400        exposing the private HashSet members; more sensible to implement it here and
37401        simply make it public in WorkerGlobalScope.
37402
37403        * dom/ScriptExecutionContext.h: Removed unnecessary includes and forward declarations.
37404        Removed a long-ago-fixed FIXME. Changed various functions to take references instead of
37405        pointers. Added a protected hasPendingActivity function, deleted the closeMessagePorts
37406        function, deleted the ActiveDOMObjectsSet typedef, made the assertion flags be
37407        !ASSERT_DISABLED only, and deleted the messagePorts and activeDOMObjects functions.
37408
37409        * workers/WorkerGlobalScope.cpp:
37410        (WebCore::WorkerGlobalScope::hasPendingActivity): Deleted. This is now implemented
37411        in the base class.
37412
37413        * workers/WorkerGlobalScope.h: Make hasPendingActivity function from the base class
37414        public instead of declaring it in this class.
37415
374162014-04-20  Brent Fulgham  <bfulgham@apple.com>
37417
37418        [Mac] Unable to select 'Off' or 'Auto' from track menu when tracks consist of unsupported track types
37419        https://bugs.webkit.org/show_bug.cgi?id=131908
37420        <rdar://problem/15999882>
37421
37422        Reviewed by Eric Carlson.
37423
37424        * html/HTMLMediaElement.cpp:
37425        (WebCore::HTMLMediaElement::setSelectedTextTrack): When the user selects 'Off', make sure the currently 'showing'
37426        track is switched to 'disabled'.
37427
374282014-04-20  Andreas Kling  <akling@apple.com>
37429
37430        Speed up jsStringWithCache() through WeakGCMap inlining.
37431        <https://webkit.org/b/131923>
37432
37433        Inline the common path of WeakGCMap::add() in jsStringWithCache().
37434        26% progression on Bindings/id-getter.html
37435
37436        Reviewed by Darin Adler.
37437
37438        * WebCore.exp.in:
37439        * bindings/js/JSDOMBinding.h:
37440        * bindings/js/JSDOMBinding.cpp:
37441        (WebCore::jsStringWithCache):
37442
37443            Move jsStringWithCache() out of line since we're now blowing up
37444            its size quite a bit.
37445
374462014-04-20  Benjamin Poulain  <benjamin@webkit.org>
37447
37448        Fix the build after r167574
37449
37450        * cssjit/SelectorCompiler.cpp:
37451        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
37452
374532014-04-20  Benjamin Poulain  <benjamin@webkit.org>
37454
37455        Compile the pseudo class :target
37456        https://bugs.webkit.org/show_bug.cgi?id=131904
37457
37458        Reviewed by Andreas Kling.
37459
37460        The pseudo class :target is trivial, it just compare the current element with
37461        Document::cssTarget().
37462
37463        * cssjit/SelectorCompiler.cpp:
37464        (WebCore::SelectorCompiler::addPseudoType):
37465        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
37466        (WebCore::SelectorCompiler::getDocument):
37467        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueExactMatching):
37468        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsTarget):
37469        * dom/Document.h:
37470        (WebCore::Document::cssTargetMemoryOffset):
37471
374722014-04-20  Benjamin Poulain  <benjamin@webkit.org>
37473
37474        Rename the CSSSelector PseudoType to PseudoClassType
37475        https://bugs.webkit.org/show_bug.cgi?id=131907
37476
37477        Reviewed by Andreas Kling.
37478
37479        Pseudo Elements and Page Pseudo Classes have been moved out of PseudoType in previous patches.
37480        The remaining values in the PseudoType enumeration are the pseudo classes.
37481
37482        This patch is the final clean up, PseudoType is renamed to PseudoClassType.
37483
37484        * css/CSSGrammar.y.in:
37485        * css/CSSParserValues.cpp:
37486        (WebCore::CSSParserSelector::parsePseudoClassAndCompatibilityElementSelector):
37487        * css/CSSParserValues.h:
37488        (WebCore::CSSParserSelector::pseudoClassType):
37489        (WebCore::CSSParserSelector::pseudoType): Deleted.
37490        * css/CSSSelector.cpp:
37491        (WebCore::CSSSelector::specificityForOneSelector):
37492        (WebCore::appendPseudoClassFunctionTail):
37493        (WebCore::CSSSelector::selectorText):
37494        * css/CSSSelector.h:
37495        (WebCore::CSSSelector::pseudoClassType):
37496        (WebCore::CSSSelector::pseudoElementType):
37497        (WebCore::CSSSelector::pagePseudoClassType):
37498        (WebCore::pseudoClassIsRelativeToSiblings):
37499        (WebCore::CSSSelector::isSiblingSelector):
37500        (WebCore::CSSSelector::CSSSelector):
37501        (WebCore::CSSSelector::pseudoType): Deleted.
37502        * css/RuleSet.cpp:
37503        (WebCore::RuleSet::findBestRuleSetAndAdd):
37504        * css/SelectorChecker.cpp:
37505        (WebCore::SelectorChecker::checkOne):
37506        (WebCore::SelectorChecker::checkScrollbarPseudoClass):
37507        (WebCore::SelectorChecker::determineLinkMatchType):
37508        (WebCore::SelectorChecker::matchesFocusPseudoClass):
37509        * css/SelectorChecker.h:
37510        (WebCore::SelectorChecker::isCommonPseudoClassSelector):
37511        * css/SelectorCheckerFastPath.cpp:
37512        (WebCore::SelectorCheckerFastPath::commonPseudoClassSelectorMatches):
37513        * css/SelectorPseudoClassAndCompatibilityElementMap.in:
37514        * css/SelectorPseudoTypeMap.h:
37515        * css/StyleResolver.cpp:
37516        (WebCore::StyleResolver::styleForElement):
37517        * css/makeSelectorPseudoClassAndCompatibilityElementMap.py:
37518        (enumerablePseudoType):
37519        * cssjit/SelectorCompiler.cpp:
37520        (WebCore::SelectorCompiler::addPseudoClassType):
37521        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
37522        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
37523        (WebCore::SelectorCompiler::addPseudoType): Deleted.
37524        * inspector/InspectorCSSAgent.cpp:
37525        (WebCore::computePseudoClassMask):
37526        (WebCore::InspectorCSSAgent::forcePseudoState):
37527        * inspector/InspectorCSSAgent.h:
37528        * inspector/InspectorInstrumentation.cpp:
37529        (WebCore::InspectorInstrumentation::forcePseudoStateImpl):
37530        * inspector/InspectorInstrumentation.h:
37531        (WebCore::InspectorInstrumentation::forcePseudoState):
37532
375332014-04-19  Alexey Proskuryakov  <ap@apple.com>
37534
37535        Crashes in HTMLFormElement::submit.
37536        https://bugs.webkit.org/show_bug.cgi?id=131910
37537        <rdar://problem/15661790>
37538
37539        Based on a patch by Kent Tamura.
37540
37541        Reviewed by Anders Carlsson.
37542
37543        Tests: fast/forms/form-submission-crash-2.html
37544               fast/forms/form-submission-crash.html
37545
37546        Code that executes arbitrary JS needs to protect objects that it uses afterwards.
37547
37548        * html/HTMLFormElement.cpp:
37549        (WebCore::HTMLFormElement::prepareForSubmission):
37550        (WebCore::HTMLFormElement::submit):
37551        * loader/FrameLoader.cpp:
37552        (WebCore::FrameLoader::submitForm):
37553
375542014-04-20  Antti Koivisto  <antti@apple.com>
37555
37556        Text bounding box computation for simple line layout is wrong
37557        https://bugs.webkit.org/show_bug.cgi?id=131912
37558
37559        Reviewed by Andreas Kling.
37560
37561        Top-left is currently the first line top-left which is not always correct.
37562
37563        * WebCore.exp.in:
37564        * rendering/RenderText.cpp:
37565        (WebCore::RenderText::firstRunLocation):
37566        (WebCore::RenderText::firstRunOrigin): Deleted.
37567        (WebCore::RenderText::firstRunX): Deleted.
37568        (WebCore::RenderText::firstRunY): Deleted.
37569        
37570            Keep just one accessor and rename it.
37571            Encapsulate the line box and simple line versions.
37572
37573        * rendering/RenderText.h:
37574        * rendering/RenderTextLineBoxes.cpp:
37575        (WebCore::RenderTextLineBoxes::firstRunLocation):
37576
37577            Line box version.
37578
37579        * rendering/RenderTextLineBoxes.h:
37580        * rendering/RenderTreeAsText.cpp:
37581        
37582            Simplify RenderText dumping.
37583
37584        (WebCore::RenderTreeAsText::writeRenderObject):
37585        * rendering/SimpleLineLayoutFunctions.cpp:
37586        (WebCore::SimpleLineLayout::computeTextBoundingBox):
37587        
37588            Return the correct x position.
37589
37590        (WebCore::SimpleLineLayout::computeTextFirstRunLocation):
37591        
37592            Simple line version.
37593
37594        * rendering/SimpleLineLayoutFunctions.h:
37595        * rendering/svg/SVGRenderTreeAsText.cpp:
37596        (WebCore::writeSVGInlineText):
37597
375982014-04-19  Zalan Bujtas  <zalan@apple.com>
37599
37600        Subpixel rendering: RenderLayer's clipping should snap to device pixel boundaries.
37601        https://bugs.webkit.org/show_bug.cgi?id=131466
37602
37603        Reviewed by Simon Fraser.
37604
37605        Fractional pixel clipping can produce cruft on RenderLayers. Since RenderLayer
37606        sizing and painting are snapped, painting clip rect needs to be snapped the same way.
37607
37608        Test: fast/clip/clip-when-rect-has-fractional-pixel-value.html
37609
37610        * rendering/RenderLayer.cpp:
37611        (WebCore::RenderLayer::clipToRect):
37612
376132014-04-19  Brent Fulgham  <bfulgham@apple.com>
37614
37615        Latched scrolling may interact badly with custom programmatic scrolling
37616        https://bugs.webkit.org/show_bug.cgi?id=131869
37617        <rdar://problem/16249557>
37618
37619        Reviewed by Darin Adler.
37620
37621        * dom/Element.cpp:
37622        (WebCore::Element::setScrollLeft): Mark scrollable area as having
37623        been scrolled programmatically.
37624        (WebCore::Element::setScrollTop): Ditto.
37625        * page/EventHandler.cpp:
37626        (WebCore::EventHandler::handleWheelEvent): Check for programmatic scroll, and
37627        clear latched state if the handler manually scrolled. Clear programmatic
37628        scroll state at the end of event handling.
37629        (WebCore::EventHandler::clearLatchedState): Refactored code.
37630        * page/EventHandler.h:
37631        * page/mac/EventHandlerMac.mm:
37632        (WebCore::EventHandler::platformPrepareForWheelEvents): Check
37633        if scrollable area was scrolled programmatically. If it was, do
37634        not honor latching behavior.
37635        * platform/ScrollableArea.cpp:
37636        (WebCore::ScrollableArea::ScrollableArea): Initialize new member.
37637        * platform/ScrollableArea.h:
37638        (WebCore::ScrollableArea::isScrolledProgrammatically): Added.
37639        (WebCore::ScrollableArea::setScrolledProgrammatically): Added.
37640
376412014-04-19  Chris Fleizach  <cfleizach@apple.com>
37642
37643        AX: grid rows are not recognized do to lack of explicit role="row", role="gridcell"
37644        https://bugs.webkit.org/show_bug.cgi?id=131819
37645
37646        Reviewed by Darin Adler.
37647
37648        Test: accessibility/table-with-missing-aria-role-rows.html
37649
37650        If a table is using role="grid", and it has <tr> elements that do not have
37651        role="row", we should still treat them as row elements.
37652
37653        * accessibility/AccessibilityARIAGrid.cpp:
37654        (WebCore::AccessibilityARIAGrid::addTableCellChild):
37655
376562014-04-19  Chris Fleizach  <cfleizach@apple.com>
37657
37658        AX: Malformed tables exposing incorrect col and colSpans
37659        https://bugs.webkit.org/show_bug.cgi?id=131796
37660
37661        Reviewed by Darin Adler.
37662
37663        Test: accessibility/table-incorrect-colspan-cell.html
37664
37665        When a developer has specified malformed colspans, accessibility is reporting those values instead of the effective column information.
37666
37667        * accessibility/AccessibilityTableCell.cpp:
37668        (WebCore::AccessibilityTableCell::columnIndexRange):
37669
376702014-04-19  Benjamin Poulain  <bpoulain@apple.com>
37671
37672        Make the CSS JIT compile for ARM64
37673        https://bugs.webkit.org/show_bug.cgi?id=131834
37674
37675        Reviewed by Gavin Barraclough.
37676
37677        Add the CPU specific code required to compile SelectorCompiler on ARM64.
37678        The code is absolutely non-functional, it would crash immediately, but it compiles.
37679
37680        * cssjit/FunctionCall.h:
37681        (WebCore::FunctionCall::FunctionCall):
37682        (WebCore::FunctionCall::callAndBranchOnCondition):
37683        * cssjit/RegisterAllocator.h:
37684        What am I supposed to do with all those registers? There are so many of them :)
37685        The array calleeSavedRegisters is defined for compatibility but it cannot be reached at the moment.
37686
37687        (WebCore::RegisterAllocator::isValidRegister):
37688        * cssjit/SelectorCompiler.cpp:
37689        (WebCore::SelectorCompiler::SelectorCodeGenerator::modulo):
37690        Implement modulo by doing dividend - (divisor * int(dividend/divisor)).
37691
37692        * cssjit/StackAllocator.h:
37693        StackAllocator will need a small redesign to handle the 16 bytes alligned stack of
37694        ARM64.
37695        The code has been modified to build but it is pretty useless.
37696
37697        (WebCore::StackAllocator::allocateUninitialized):
37698        (WebCore::StackAllocator::push):
37699        (WebCore::StackAllocator::pop):
37700        (WebCore::StackAllocator::popAndDiscard):
37701        (WebCore::StackAllocator::popAndDiscardUpTo):
37702        (WebCore::StackAllocator::alignStackPreFunctionCall):
37703        (WebCore::StackAllocator::unalignStackPostFunctionCall):
37704
377052014-04-19  Simon Fraser  <simon.fraser@apple.com>
37706
37707        [UI-side compositing] Implement blend modes
37708        https://bugs.webkit.org/show_bug.cgi?id=131891
37709        <rdar://problem/16490085>
37710
37711        Reviewed by Tim Horton.
37712
37713        Implement blend modes with UI-side compositing.
37714        
37715        PlatformCALayer::setBlendMode() becomes pure virtual, and overridden in
37716        PlatformCALayerMac and PlatformCALayerRemote.
37717        PlatformCAFilters::setBlendingFiltersOnLayer() now takes a raw platform
37718        layer, so it can be called from the UI process on a CALayer*.
37719        
37720        Fix an issue with GraphicsLayerCA::LayerChange flags. 1 << 31 shifts
37721        a signed integer, so it ended up setting all the high bits in m_uncommittedChanges,
37722        causing us to push blend modes to the UI process for every layer. Fix by shifting
37723        an unsigned long long (1LLU << 31). This should also fix a build warning on Windows.
37724
37725        * WebCore.exp.in:
37726        * platform/graphics/ca/GraphicsLayerCA.h:
37727        * platform/graphics/ca/PlatformCAFilters.h:
37728        * platform/graphics/ca/PlatformCALayer.h:
37729        * platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
37730        (PlatformCAFilters::setBlendingFiltersOnLayer):
37731        * platform/graphics/ca/mac/PlatformCALayerMac.h:
37732        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
37733        (PlatformCALayerMac::setFilters):
37734        (PlatformCALayerMac::setBlendMode):
37735        (PlatformCALayer::setBlendMode): Deleted.
37736
377372014-04-19  Joseph Pecoraro  <pecoraro@apple.com>
37738
37739        Fix AVPlayerController leak on pages with video
37740        https://bugs.webkit.org/show_bug.cgi?id=131878
37741
37742        Reviewed by Eric Carlson.
37743
37744        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
37745        (-[WebAVPlayerController init]):
37746        Assigning to the retain property will increment the count,
37747        so balance the alloc with an autorelease.
37748
377492014-04-19  Andreas Kling  <akling@apple.com>
37750
37751        Slap ALWAYS_INLINE on Element attribute lookup things.
37752        <https://webkit.org/b/131892>
37753
37754        Most of the "inline" helpers for setting/getting attributes were not
37755        actually getting inlined by the compiler, so let's make that happen.
37756
37757        Reviewed by Geoffrey Garen.
37758
37759        * dom/Element.cpp:
37760        (WebCore::Element::synchronizeAttribute):
37761        * dom/ElementData.h:
37762        (WebCore::ElementData::findAttributeByName):
37763        (WebCore::ElementData::findAttributeIndexByName):
37764
377652014-04-19  Darin Adler  <darin@apple.com>
37766
37767        Telephone number detection should respect its setting consistently
37768        https://bugs.webkit.org/show_bug.cgi?id=131893
37769        rdar://problem/16597639
37770
37771        Reviewed by Tim Horton.
37772
37773        * editing/Editor.cpp:
37774        (WebCore::Editor::respondToChangedSelection): Only start the timer
37775        if shouldDetectTelephoneNumbers returns true.
37776        (WebCore::Editor::shouldDetectTelephoneNumbers): Added. Calls both
37777        isTelephoneNumberParsingEnabled and TelephoneNumberDetector::isSupported.
37778        (WebCore::Editor::scanSelectionForTelephoneNumbers): Use
37779        shouldDetectTelephoneNumbers.
37780        (WebCore::Editor::clearDataDetectedTelephoneNumbers): Use document()
37781        instead of m_frame.document().
37782
37783        * editing/Editor.h: Added declaration of shouldDetectTelephoneNumbers.
37784
377852014-04-19  Andrei Bucur  <abucur@adobe.com>
37786
37787        [CSS Regions] Harden the layout in case there are no regions
37788        https://bugs.webkit.org/show_bug.cgi?id=131517
37789
37790        Reviewed by Mihnea Ovidenie.
37791
37792        The patch fixes the cases when the content of a flow thread is not
37793        properly invalidated when all the regions of its chain are removed.
37794
37795        Test: fast/regions/simplified-layout-no-regions.html
37796
37797        * rendering/RenderFlowThread.cpp:
37798        (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
37799        * rendering/RenderRegion.cpp:
37800        (WebCore::RenderRegion::ensureOverflowForBox):
37801
378022014-04-19  Zalan Bujtas  <zalan@apple.com>
37803
37804        https://bugs.webkit.org/show_bug.cgi?id=131594
37805        Subpixel rendering: WK1: Wrong repaint rect is calculated when layer has non-compositing transform.
37806
37807        Reviewed by Simon Fraser.
37808
37809        We need to snap the repaint rect for transformed object the same way when we paint them.
37810
37811        Test: fast/repaint/hidpi-wrong-repaint-rect-when-parent-has-noncompositing-transform.html
37812
37813        * rendering/RenderBox.cpp:
37814        (WebCore::RenderBox::computeRectForRepaint):
37815
378162014-04-18  Simon Fraser  <simon.fraser@apple.com>
37817
37818        Use 'override' in GraphicsLayerCA
37819        https://bugs.webkit.org/show_bug.cgi?id=131882
37820
37821        Reviewed by Tim Horton.
37822
37823        Add 'override' to all overridden functions. Found a few that need
37824        not have been virtual. Removed "allowTiledLayer" stuff that was
37825        never called.
37826
37827        * WebCore.exp.in:
37828        * platform/graphics/ca/GraphicsLayerCA.cpp:
37829        (WebCore::GraphicsLayerCA::GraphicsLayerCA):
37830        (WebCore::GraphicsLayerCA::requiresTiledLayer):
37831        (WebCore::GraphicsLayerCA::setAllowTiledLayer): Deleted.
37832        * platform/graphics/ca/GraphicsLayerCA.h:
37833        (WebCore::GraphicsLayerCA::platformCALayer):
37834        (WebCore::GraphicsLayerCA::hasContentsLayer): Deleted.
37835        (WebCore::GraphicsLayerCA::allowTiledLayer): Deleted.
37836        (WebCore::GraphicsLayerCA::isGraphicsLayerCA): Deleted.
37837        (WebCore::GraphicsLayerCA::platformCALayerLayoutSublayersOfLayer): Deleted.
37838        (WebCore::GraphicsLayerCA::platformCALayerRespondsToLayoutChanges): Deleted.
37839        (WebCore::GraphicsLayerCA::platformCALayerContentsOrientation): Deleted.
37840        (WebCore::GraphicsLayerCA::platformCALayerShowDebugBorders): Deleted.
37841        (WebCore::GraphicsLayerCA::platformCALayerIncrementRepaintCount): Deleted.
37842        (WebCore::GraphicsLayerCA::platformCALayerContentsOpaque): Deleted.
37843        (WebCore::GraphicsLayerCA::platformCALayerDrawsContent): Deleted.
37844        (WebCore::GraphicsLayerCA::platformCALayerLayerDidDisplay): Deleted.
37845
378462014-04-18  Timothy Hatcher  <timothy@apple.com>
37847
37848        Web Inspector: Move InspectorProfilerAgent to JavaScriptCore
37849        https://bugs.webkit.org/show_bug.cgi?id=131673
37850
37851        Passes existing profiler and inspector tests.
37852
37853        Reviewed by Joseph Pecoraro.
37854
37855        * CMakeLists.txt:
37856        * DerivedSources.make:
37857        * ForwardingHeaders/inspector/agents/InspectorProfilerAgent.h: Added.
37858        * WebCore.exp.in:
37859        * WebCore.vcxproj/WebCore.vcxproj:
37860        * WebCore.vcxproj/WebCore.vcxproj.filters:
37861        * WebCore.xcodeproj/project.pbxproj:
37862        * bindings/js/ScriptProfile.cpp: Removed.
37863        * bindings/js/ScriptProfile.h:
37864        * bindings/js/ScriptProfiler.cpp: Removed.
37865        * bindings/js/ScriptProfiler.h: Removed.
37866        * inspector/InspectorAllInOne.cpp:
37867        * inspector/InspectorConsoleInstrumentation.h:
37868        (WebCore::InspectorInstrumentation::profilerEnabled):
37869        (WebCore::InspectorInstrumentation::startProfiling):
37870        (WebCore::InspectorInstrumentation::stopProfiling):
37871        * inspector/InspectorController.cpp:
37872        (WebCore::InspectorController::InspectorController):
37873        * inspector/InspectorController.h:
37874        * inspector/InspectorInstrumentation.cpp:
37875        (WebCore::InspectorInstrumentation::didCommitLoadImpl):
37876        (WebCore::InspectorInstrumentation::startProfilingImpl):
37877        (WebCore::InspectorInstrumentation::stopProfilingImpl):
37878        (WebCore::InspectorInstrumentation::consoleTimeStampImpl): Deleted.
37879        * inspector/InspectorInstrumentation.h:
37880        * inspector/InspectorProfilerAgent.cpp: Removed.
37881        * inspector/InspectorProfilerAgent.h: Removed.
37882        * inspector/InspectorTimelineAgent.cpp:
37883        (WebCore::startProfiling):
37884        (WebCore::stopProfiling):
37885        (WebCore::InspectorTimelineAgent::willCallFunction):
37886        (WebCore::InspectorTimelineAgent::didCallFunction):
37887        (WebCore::InspectorTimelineAgent::willEvaluateScript):
37888        (WebCore::InspectorTimelineAgent::didEvaluateScript):
37889        (WebCore::InspectorTimelineAgent::didDispatchXHRLoadEvent): Deleted.
37890        * inspector/InstrumentingAgents.h:
37891        (WebCore::InstrumentingAgents::inspectorProfilerAgent):
37892        (WebCore::InstrumentingAgents::setInspectorProfilerAgent):
37893        * inspector/PageDebuggerAgent.cpp:
37894        (WebCore::PageDebuggerAgent::sourceMapURLForScript): Deleted.
37895        * inspector/PageDebuggerAgent.h:
37896        * inspector/PageProfilerAgent.cpp: Added.
37897        (WebCore::PageProfilerAgent::PageProfilerAgent):
37898        (WebCore::PageProfilerAgent::profilingGlobalExecState):
37899        * inspector/PageProfilerAgent.h: Added.
37900        (WebCore::PageProfilerAgent::~PageProfilerAgent):
37901        * inspector/ScriptProfile.idl:
37902        * inspector/TimelineRecordFactory.cpp:
37903        (WebCore::TimelineRecordFactory::appendProfile):
37904        * inspector/TimelineRecordFactory.h:
37905        * inspector/WebConsoleAgent.cpp:
37906        * inspector/WebProfilerAgent.cpp: Added.
37907        (WebCore::WebProfilerAgent::WebProfilerAgent):
37908        (WebCore::WebProfilerAgent::enable):
37909        (WebCore::WebProfilerAgent::disable):
37910        * inspector/WebProfilerAgent.h: Added.
37911        (WebCore::WebProfilerAgent::~WebProfilerAgent):
37912        * inspector/WorkerInspectorController.cpp:
37913        (WebCore::WorkerInspectorController::WorkerInspectorController):
37914        * inspector/WorkerProfilerAgent.cpp: Added.
37915        (WebCore::WorkerProfilerAgent::WorkerProfilerAgent):
37916        (WebCore::WorkerProfilerAgent::profilingGlobalExecState):
37917        * inspector/WorkerProfilerAgent.h: Added.
37918        (WebCore::WorkerProfilerAgent::~WorkerProfilerAgent):
37919        * loader/appcache/ApplicationCacheGroup.cpp:
37920        * page/PageConsole.cpp:
37921        (WebCore::PageConsole::profile):
37922        (WebCore::PageConsole::profileEnd):
37923        (WebCore::PageConsole::time): Deleted.
37924        (WebCore::PageConsole::timeEnd): Deleted.
37925        (WebCore::PageConsole::timeStamp): Deleted.
37926        * page/PageConsole.h:
37927        * testing/Internals.cpp:
37928        * testing/Internals.h:
37929        * xml/XMLHttpRequest.cpp:
37930
379312014-04-18  Simon Fraser  <simon.fraser@apple.com>
37932
37933        Contents of directly composited image layers are sometimes missing
37934        https://bugs.webkit.org/show_bug.cgi?id=131880
37935
37936        Reviewed by Tim Horton.
37937        
37938        RenderLayerBacking::updateGraphicsLayerGeometry() tested whether a
37939        GraphicsLayer had a contents layer to determine whether to call code
37940        that updates the contents rect. However, on Mac, we don't make a contents
37941        layer until later at layer flush time. That would result in an empty
37942        contentsRect being set.
37943        
37944        Fix by renaming GraphicsLayer::hasContentsLayer() to usesContentsLayer(),
37945        and on Mac consulting the m_contentsLayerPurpose flag, which is set
37946        at the appropriate time.
37947
37948        Test: compositing/images/update-content-rect.html
37949
37950        * platform/ScrollView.cpp:
37951        (WebCore::positionScrollbarLayer):
37952        * platform/graphics/GraphicsLayer.cpp:
37953        (WebCore::GraphicsLayer::getDebugBorderInfo):
37954        * platform/graphics/GraphicsLayer.h:
37955        (WebCore::GraphicsLayer::usesContentsLayer):
37956        (WebCore::GraphicsLayer::hasContentsLayer): Deleted.
37957        * platform/graphics/ca/GraphicsLayerCA.h:
37958        (WebCore::GraphicsLayerCA::hasContentsLayer): Deleted.
37959        * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
37960        (WebCore::GraphicsLayerTextureMapper::usesContentsLayer):
37961        (WebCore::GraphicsLayerTextureMapper::hasContentsLayer): Deleted.
37962        * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
37963        * rendering/RenderLayerBacking.cpp:
37964        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
37965        (WebCore::RenderLayerBacking::positionOverflowControlsLayers):
37966        (WebCore::RenderLayerBacking::compositingLayerType):
37967
379682014-04-18  Commit Queue  <commit-queue@webkit.org>
37969
37970        Unreviewed, rolling out r167527.
37971        https://bugs.webkit.org/show_bug.cgi?id=131883
37972
37973        Broke 32-bit build (Requested by ap on #webkit).
37974
37975        Reverted changeset:
37976
37977        "[Mac] implement WebKitDataCue"
37978        https://bugs.webkit.org/show_bug.cgi?id=131799
37979        http://trac.webkit.org/changeset/167527
37980
379812014-04-18  Eric Carlson  <eric.carlson@apple.com>
37982
37983        [Mac] implement WebKitDataCue
37984        https://bugs.webkit.org/show_bug.cgi?id=131799
37985
37986        Reviewed by Dean Jackson.
37987
37988        Tests: http/tests/media/track-in-band-hls-metadata.html
37989               media/track/track-datacue-value.html
37990
37991        * Configurations/FeatureDefines.xcconfig: Define ENABLE_DATACUE_VALUE.
37992        * DerivedSources.make: Add ENABLE_DATACUE_VALUE to HTML_FLAGS when appropriate.
37993
37994        * CMakeLists.txt: Add JSDataCueCustom.cpp.
37995        * bindings/js/JSBindingsAllInOne.cpp:
37996        * WebCore.xcodeproj/project.pbxproj: Add new files.
37997
37998        * bindings/js/JSDataCueCustom.cpp: Added.
37999        (WebCore::JSDataCue::value): 
38000        (WebCore::JSDataCue::setValue):
38001        (WebCore::JSDataCueConstructor::constructJSDataCue): Custom constructor.
38002
38003        * html/HTMLMediaElement.cpp:
38004        (WebCore::HTMLMediaElement::updateActiveTextTrackCues): Drive-by fixes: don't schedule timeupdate
38005            events when paused, don't call sort on an Vector that can't be sorted.
38006
38007        * html/track/DataCue.cpp:
38008        (WebCore::DataCue::DataCue): Initialize m_type.
38009        (WebCore::DataCue::~DataCue): Unprotect the JSValue if necessary.
38010        (WebCore::DataCue::data): Ask the platform value for data if non-null.
38011        (WebCore::DataCue::setData): Clear m_platformValue and m_value.
38012        (WebCore::DataCue::isEqual): New.
38013        (WebCore::DataCue::value): Return a JSValue from the platform value, or the value passed
38014            to the constructor/set by script.
38015        (WebCore::DataCue::setValue): Set m_value.
38016        * html/track/DataCue.h:
38017        * html/track/DataCue.idl:
38018
38019        * html/track/InbandDataTextTrack.cpp:
38020        (WebCore::InbandDataTextTrack::addDataCue): Don't add the same cue more than once.
38021        (WebCore::InbandDataTextTrack::updateDataCue): Update a cue's duration.
38022        (WebCore::InbandDataTextTrack::removeDataCue): Remove an incomplete cue.
38023        (WebCore::InbandDataTextTrack::removeCue): Remove a cue from the incomplete cue map if necessary.
38024        * html/track/InbandDataTextTrack.h:
38025
38026        * html/track/InbandGenericTextTrack.cpp:
38027        (WebCore::InbandGenericTextTrack::addGenericCue): CueMatchRules is now in TextTrackCue instead
38028            of VTTCue.
38029        * html/track/InbandTextTrack.h:
38030
38031        * html/track/InbandWebVTTTextTrack.cpp:
38032        (WebCore::InbandWebVTTTextTrack::newCuesParsed): Ditto.
38033
38034        * html/track/TextTrack.cpp:
38035        (WebCore::TextTrack::hasCue): Ditto.
38036        * html/track/TextTrack.h:
38037
38038        * html/track/TextTrackCue.cpp:
38039        (WebCore::TextTrackCue::isEqual): New, test base class equality.
38040        * html/track/TextTrackCue.h:
38041
38042        * html/track/TextTrackCueGeneric.cpp:
38043        (WebCore::TextTrackCueGeneric::isEqual): Call TextTrackCue::isEqual first.
38044        * html/track/TextTrackCueGeneric.h:
38045
38046        * html/track/VTTCue.cpp:
38047        (WebCore::VTTCue::isEqual): Call TextTrackCue::isEqual first.
38048        * html/track/VTTCue.h:
38049
38050        * platform/SerializedPlatformRepresentation.h: Added.
38051        (WebCore::SerializedPlatformRepresentation::~SerializedPlatformRepresentation):
38052        (WebCore::SerializedPlatformRepresentation::SerializedPlatformRepresentation):
38053
38054        * platform/graphics/InbandTextTrackPrivateClient.h: Add methods for DataCue with SerializedPlatformRepresentation.
38055
38056        * platform/graphics/avfoundation/InbandMetadataTextTrackPrivateAVF.cpp: Added.
38057        (WebCore::InbandMetadataTextTrackPrivateAVF::create):
38058        (WebCore::InbandMetadataTextTrackPrivateAVF::InbandMetadataTextTrackPrivateAVF):
38059        (WebCore::InbandMetadataTextTrackPrivateAVF::~InbandMetadataTextTrackPrivateAVF):
38060        (WebCore::InbandMetadataTextTrackPrivateAVF::addDataCue):
38061        (WebCore::InbandMetadataTextTrackPrivateAVF::updatePendingCueEndTimes):
38062        (WebCore::InbandMetadataTextTrackPrivateAVF::flushPartialCues):
38063        * platform/graphics/avfoundation/InbandMetadataTextTrackPrivateAVF.h: Added.
38064
38065        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
38066        (WebCore::MediaPlayerPrivateAVFoundation::seekWithTolerance): currentTrack -> currentTextTrack.
38067        (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted): Ditto.
38068        (WebCore::MediaPlayerPrivateAVFoundation::configureInbandTracks): Ditto.
38069        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
38070        (WebCore::MediaPlayerPrivateAVFoundation::setCurrentTextTrack):
38071        (WebCore::MediaPlayerPrivateAVFoundation::setCurrentTrack): Deleted.
38072
38073        Renamed currentTrack and setCurrentTrack to currentTextTrack and setCurrentTextTrack.
38074        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
38075        (WebCore::AVFWrapper::currentTextTrack):
38076        (WebCore::MediaPlayerPrivateAVFoundationCF::setCurrentTextTrack):
38077        (WebCore::MediaPlayerPrivateAVFoundationCF::currentTextTrack):
38078        (WebCore::AVFWrapper::setCurrentTextTrack):
38079        (WebCore::AVFWrapper::AVFWrapper):
38080        (WebCore::AVFWrapper::processCue):
38081        (WebCore::AVFWrapper::currentTrack): Deleted.
38082        (WebCore::MediaPlayerPrivateAVFoundationCF::setCurrentTrack): Deleted.
38083        (WebCore::MediaPlayerPrivateAVFoundationCF::currentTrack): Deleted.
38084        (WebCore::AVFWrapper::setCurrentTrack): Deleted.
38085        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
38086
38087        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
38088        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
38089        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
38090        (WebCore::MediaPlayerPrivateAVFoundationObjC::seekToTime): currentTrack -> currentTextTrack
38091        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): currentTrack -> currentTextTrack.
38092        (WebCore::MediaPlayerPrivateAVFoundationObjC::processMetadataTrack): New.
38093        (WebCore::MediaPlayerPrivateAVFoundationObjC::processCue): m_currentTrack -> m_currentTextTrack.
38094        (WebCore::MediaPlayerPrivateAVFoundationObjC::flushCues): Ditto.
38095        (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTextTrack): Renamed from setCurrentTextTrack.
38096        (WebCore::metadataType): Map an AVFoundation metadata key space to a metadata cue type.
38097        (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive): Process new metadata.
38098        (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]):
38099        (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTrack): Deleted.
38100
38101        Create a JSValue representation from an AVMetadataItem.
38102        * platform/mac/SerializedPlatformRepresentationMac.h: Added.
38103        (WebCore::SerializedPlatformRepresentationMac::platformType):
38104        (WebCore::SerializedPlatformRepresentationMac::nativeValue):
38105        * platform/mac/SerializedPlatformRepresentationMac.mm: Added.
38106        (WebCore::SerializedPlatformRepresentationMac::SerializedPlatformRepresentationMac):
38107        (WebCore::SerializedPlatformRepresentationMac::~SerializedPlatformRepresentationMac):
38108        (WebCore::SerializedPlatformRepresentationMac::create):
38109        (WebCore::SerializedPlatformRepresentationMac::data):
38110        (WebCore::SerializedPlatformRepresentationMac::deserialize):
38111        (WebCore::SerializedPlatformRepresentationMac::isEqual):
38112        (WebCore::toSerializedPlatformRepresentationMac):
38113        (WebCore::jsValueWithValueInContext):
38114        (WebCore::jsValueWithDataInContext):
38115        (WebCore::jsValueWithArrayInContext):
38116        (WebCore::jsValueWithDictionaryInContext):
38117        (WebCore::jsValueWithAVMetadataItemInContext):
38118
381192014-04-18  Jon Honeycutt  <jhoneycutt@apple.com>
38120
38121        Harden RenderInline::inlineElementContinuation()
38122
38123        <https://bugs.webkit.org/show_bug.cgi?id=131858>
38124
38125        Reviewed by Sam Weinig.
38126
38127        No new tests, as there are no known cases of this happening.
38128
38129        * rendering/RenderInline.cpp:
38130        (WebCore::RenderInline::inlineElementContinuation):
38131        Return nullptr if the continuation is neither a RenderInline nor a
38132        RenderBlock.
38133
381342014-04-18  Stephanie Lewis  <slewis@apple.com>
38135
38136        We shouldn’t create page throttlers for other pages than WebKit2 pages.
38137        Part of <rdar://problem/16473045> Visibility state counters are often incorrect
38138        https://bugs.webkit.org/show_bug.cgi?id=131696
38139
38140        Reviewed by Gavin Barraclough.
38141
38142        No new test since not web exposed.
38143
38144        Page throttlers were being created for SVG images and other page instances that
38145        were not accurately tracking the states that enable and disable page throttling.
38146        Make the throttler an unique ptr and only initialize it for WebKit2.
38147
38148        This also fixes an inefficiency where we would throttle a new page on creation because 
38149        we assumed it was visible even if that was not the case.
38150
38151        * WebCore.exp.in:
38152        * html/HTMLMediaElement.cpp:
38153        (WebCore::HTMLMediaElement::parseAttribute): Check page throttler exists.
38154        * loader/FrameLoader.cpp:
38155        (WebCore::FrameLoader::started): ditto
38156        * page/Page.cpp:
38157        (WebCore::Page::Page): Don’t automatically create page throttler.
38158        (WebCore::Page::createPageThrottler): Create page throttler.
38159        (WebCore::Page::setViewState): Check page throttler exists.
38160        * page/Page.h:
38161        (WebCore::Page::pageThrottler): Make the page throttler a unique ptr.
38162        * page/PageThrottler.h:
38163        * page/Settings.cpp: 
38164        (WebCore::Settings::setHiddenPageDOMTimerThrottlingEnabled): Check page throttler exists.
38165
381662014-04-18  Stephanie Lewis  <slewis@apple.com>
38167
38168        Move DOM throttling out of the page throttler
38169        <rdar://problem/16473004>
38170        https://bugs.webkit.org/show_bug.cgi?id=131697
38171
38172        Reviewed by Gavin Barraclough.
38173
38174        No new tests since it's not web exposed.
38175
38176        DOM timer throttling is currently part of the page throttler which uses per process 
38177        state and per page state to determine when to throttle.  This led us to being overly 
38178        conservative when turning DOM throttling off.  It should only respond to view state changes.
38179
38180        Additionally since creating extra page throttlers SVG images caused bugs 
38181        in tracking state we'll reserve the page throttler for WebKit2 views.  To avoid regressing 
38182        WebKit1 we should move DOM timer throttling back to the page.
38183
38184        * page/Page.cpp:
38185        (WebCore::Page::Page): set DOM timer throttling.
38186        (WebCore::Page::setIsVisuallyIdleInternal): ditto.
38187        (WebCore::Page::hiddenPageDOMTimerThrottlingStateChanged): ditto.
38188        (WebCore::Page::setIsVisible): Update view state masks for WebKit1 to include IsVisibleOrOccluded and IsVisuallyIdle
38189        * page/Page.h:
38190        * page/PageThrottler.cpp:
38191        (WebCore::PageThrottler::PageThrottler): remove DOM timer throttling.
38192        (WebCore::PageThrottler::started): ditto.
38193        (WebCore::PageThrottler::stopped): ditto.
38194        (WebCore::PageThrottler::hiddenPageDOMTimerThrottlingStateChanged): Deleted.
38195        * page/PageThrottler.h:
38196        * page/Settings.cpp:
38197        (WebCore::Settings::setHiddenPageDOMTimerThrottlingEnabled):
38198
381992014-04-18  Dean Jackson  <dino@apple.com>
38200
38201        [WebGL] Limit maximum texture sizes on older Intel hardware
38202        https://bugs.webkit.org/show_bug.cgi?id=131867
38203
38204        Reviewed by Geoffrey Garen.
38205
38206        Both Chrome and Firefox limit the MAX_TEXTURE_SIZE on
38207        older Intel hardware to be at most 4096. This does the
38208        same for WebKit.
38209
38210        * platform/graphics/Extensions3D.h: Add requiresRestrictedMaximumTextureSize() accessor.
38211        * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
38212        (WebCore::Extensions3DOpenGLCommon::Extensions3DOpenGLCommon): Record the value of GL_RENDERER
38213        and test for "Intel HD Graphics 3000", which is the problematic hardware.
38214        * platform/graphics/opengl/Extensions3DOpenGLCommon.h:
38215        (WebCore::Extensions3DOpenGLCommon::requiresRestrictedMaximumTextureSize): Getter.
38216        * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
38217        (WebCore::GraphicsContext3D::getIntegerv): If you're asking for MAX_TEXTURE_SIZE or
38218        MAX_CUBE_MAP_TEXTURE_SIZE, and you're on problematic hardware, return a clamped value
38219        (4096 and 1024 respectively).
38220
382212014-04-18  Hans Muller  <hmuller@adobe.com>
38222
38223        [CSS Shapes] Add parsing support for gradients
38224        https://bugs.webkit.org/show_bug.cgi?id=131444
38225
38226        Reviewed by Bem Jones-Bey.
38227
38228        Added support for shape-outside gradient values.
38229
38230        Test: fast/shapes/shape-outside-floats/shape-outside-linear-gradient.html
38231
38232        * css/DeprecatedStyleBuilder.cpp:
38233        (WebCore::ApplyPropertyShape::applyValue): Accept generated images as shape-outside values.
38234        * rendering/shapes/ShapeOutsideInfo.cpp:
38235        (WebCore::checkShapeImageOrigin): Generated images get a pass, others do not.
38236        (WebCore::getShapeImageAndRect): Use StyleImage::image() to get a generated image.
38237        (WebCore::ShapeOutsideInfo::isEnabledFor):
38238        * rendering/style/ShapeValue.h:
38239        (WebCore::ShapeValue::isImageValid): Generated images are always considered valid.
38240
382412014-04-18  Brady Eidson  <beidson@apple.com>
38242
38243        REGRESSION (r155700): Pasting an image into content-editable regions is broken.
38244        <rdar://problem/16654156> and https://bugs.webkit.org/show_bug.cgi?id=131844
38245
38246        Reviewed by Enrica Casucci.
38247
38248        * editing/mac/EditorMac.mm:
38249        (WebCore::Editor::createFragmentForImageResourceAndAddResource): Add the ArchiveResource before
38250          creating the element that uses it.
38251
382522014-04-18  Simon Fraser  <simon.fraser@apple.com>
38253
38254        [iOS WK2] Make window.scroll() and window.scrollBy() work
38255        https://bugs.webkit.org/show_bug.cgi?id=131848
38256        <rdar://problem/16638319>
38257
38258        Reviewed by Beth Dakin.
38259
38260        The scrolling-related functions in DOMWindow were #ifdeffed for iOS
38261        to use the hacky WK1-specific "actual scroll" functions, which do nothing
38262        in WK2.
38263        
38264        Fix by adding a scroll position wrapper (contentsScrollPosition) which does
38265        the right thing on WK1 and WK2, and change almost all the places that used "actualScrollPosition"
38266        to us it (with the exception of contentsScrollOffset() in MouseRelatedEvent.cpp, which has
38267        confusing scaling behavior).
38268
38269        * dom/MouseRelatedEvent.cpp:
38270        (WebCore::MouseRelatedEvent::MouseRelatedEvent):
38271        * dom/TreeScope.cpp:
38272        (WebCore::nodeFromPoint): Remove #ifdefs. 
38273        * html/HTMLBodyElement.cpp:
38274        (WebCore::HTMLBodyElement::scrollLeft):
38275        (WebCore::HTMLBodyElement::scrollTop):
38276        * page/DOMWindow.cpp:
38277        (WebCore::DOMWindow::scrollX):
38278        (WebCore::DOMWindow::scrollY):
38279        (WebCore::DOMWindow::scrollBy):
38280        (WebCore::DOMWindow::scrollTo):
38281        * platform/ScrollView.cpp:
38282        (WebCore::ScrollView::contentsScrollPosition):
38283        (WebCore::ScrollView::setContentsScrollPosition):
38284        * platform/ScrollView.h:
38285
382862014-04-18  Simon Fraser  <simon.fraser@apple.com>
38287
38288        Worse animation performance on pages with 3D transforms
38289        https://bugs.webkit.org/show_bug.cgi?id=131838
38290        <rdar://problem/16428630&15705876>
38291
38292        Reviewed by Dean Jackson.
38293        
38294        r155977 added logic to adjust the contentsScale of compositing layers
38295        based on a root-relative transform. However, this resulted in
38296        the contentsScale continually changing on layers whose transforms
38297        are changed dynamically, which caused lots of expensive painting.
38298        
38299        Fix by bucketing the part of the scale computed from the root-relative transform
38300        into buckets of 0.25 via rounding.
38301
38302        Test: compositing/contents-scale/rounded-contents-scale.html
38303
38304        * platform/graphics/ca/GraphicsLayerCA.cpp:
38305        (WebCore::clampedContentsScaleForScale):
38306        (WebCore::GraphicsLayerCA::updateContentsOpaque):
38307        (WebCore::GraphicsLayerCA::updateContentsScale):
38308        (WebCore::GraphicsLayerCA::updateContentsVisibility): Deleted.
38309        (WebCore::GraphicsLayerCA::animatedLayerClones): Deleted.
38310
383112014-04-18  Simon Fraser  <simon.fraser@apple.com>
38312
38313        Remove some includes from image-related headers, and Document.h
38314        https://bugs.webkit.org/show_bug.cgi?id=131797
38315
38316        Reviewed by Martin Robinson.
38317
38318        Remove some #includes from Document.h, DragImage.h, GradientImage.h,
38319        Image.h, and ImageBuffer.h and deal with the fallout.
38320
38321        * dom/ContainerNode.h:
38322        * dom/Document.cpp:
38323        (WebCore::Document::setInputCursor):
38324        * dom/Document.h:
38325        (WebCore::Document::inputCursor):
38326        * dom/MutationObserverRegistration.cpp:
38327        * html/canvas/WebGLRenderingContext.cpp:
38328        * page/FrameSnapshotting.cpp:
38329        * page/Page.cpp:
38330        * platform/DragImage.h:
38331        * platform/graphics/BitmapImage.cpp:
38332        * platform/graphics/GradientImage.cpp:
38333        (WebCore::GradientImage::GradientImage):
38334        (WebCore::GradientImage::~GradientImage):
38335        * platform/graphics/GradientImage.h:
38336        * platform/graphics/Image.h:
38337        * platform/graphics/ImageBuffer.cpp:
38338        * platform/graphics/ImageBuffer.h:
38339        (WebCore::ImageBuffer::create):
38340        (WebCore::ImageBuffer::internalSize):
38341        (WebCore::ImageBuffer::logicalSize):
38342        (WebCore::ImageBuffer::baseTransform):
38343        (WebCore::ImageBuffer::spaceSize):
38344        (WebCore::ImageBuffer::setSpaceSize):
38345        * rendering/RenderThemeMac.mm:
38346        * rendering/shapes/Shape.cpp:
38347        * rendering/svg/RenderSVGContainer.cpp:
38348        * svg/SVGURIReference.h:
38349
383502014-04-18  Gabor Rapcsanyi  <rgabor@webkit.org>
38351
38352        Unreviewed. ARM64 buildfix after r167473.
38353
38354        * platform/audio/DenormalDisabler.h: Put back the MathExtras.h include.
38355
383562014-04-18  Radu Stavila  <stavila@adobe.com>
38357
38358        [CSSRegions] Incorrect background paint on positioned element hover
38359        https://bugs.webkit.org/show_bug.cgi?id=131617
38360
38361        Reviewed by Andrei Bucur.
38362
38363        When computing the repaint rect for absolute elements flowed into regions, the Y location of the
38364        region within the flow thread must no longer be added to the repaint rect's location because absolute
38365        positioned elements get pushed down through the regions by their absolute top. So adding the region's
38366        position in the flow thread and then adding the element's absolute top would cause us to add
38367        something twice.
38368
38369        Tests: fast/regions/repaint/repaint-absolute-pushed-to-next-region.html
38370
38371        * rendering/RenderBox.cpp:
38372        (WebCore::RenderBox::computeRectForRepaint):
38373
383742014-04-18  Philippe Normand  <pnormand@igalia.com>
38375
38376        Remove NETWORK_INFO support
38377        https://bugs.webkit.org/show_bug.cgi?id=131841
38378
38379        Reviewed by Gyuyoung Kim.
38380
38381        * CMakeLists.txt:
38382        * Modules/networkinfo/NavigatorNetworkInfoConnection.cpp: Removed.
38383        * Modules/networkinfo/NavigatorNetworkInfoConnection.h: Removed.
38384        * Modules/networkinfo/NavigatorNetworkInfoConnection.idl: Removed.
38385        * Modules/networkinfo/NetworkInfo.cpp: Removed.
38386        * Modules/networkinfo/NetworkInfo.h: Removed.
38387        * Modules/networkinfo/NetworkInfoClient.h: Removed.
38388        * Modules/networkinfo/NetworkInfoConnection.cpp: Removed.
38389        * Modules/networkinfo/NetworkInfoConnection.h: Removed.
38390        * Modules/networkinfo/NetworkInfoConnection.idl: Removed.
38391        * Modules/networkinfo/NetworkInfoController.cpp: Removed.
38392        * Modules/networkinfo/NetworkInfoController.h: Removed.
38393        * PlatformEfl.cmake:
38394        * dom/EventTargetFactory.in:
38395        * platform/efl/NetworkInfoProviderEfl.cpp: Removed.
38396        * platform/efl/NetworkInfoProviderEfl.h: Removed.
38397        * testing/Internals.cpp:
38398        (WebCore::Internals::setNetworkInformation): Deleted.
38399        * testing/Internals.h:
38400        * testing/Internals.idl:
38401
384022014-04-17  Commit Queue  <commit-queue@webkit.org>
38403
38404        Unreviewed, rolling out r167478.
38405        https://bugs.webkit.org/show_bug.cgi?id=131840
38406
38407        Broke multicol tests (Requested by ap on #webkit).
38408
38409        Reverted changeset:
38410
38411        "[New Multicolumn] Pagination mode messed up with non-inline
38412        axis and reversed direction."
38413        https://bugs.webkit.org/show_bug.cgi?id=131811
38414        http://trac.webkit.org/changeset/167478
38415
384162014-04-17  Daniel Bates  <dabates@apple.com>
38417
38418        [iOS] Hook up screen.{availHeight, availWidth, height, width}
38419        https://bugs.webkit.org/show_bug.cgi?id=131821
38420        <rdar://problem/16413795>
38421
38422        Reviewed by Benjamin Poulain and Tim Horton.
38423
38424        Implement support for screen.{availHeight, availWidth, height, width} in WebKit2 for iOS.
38425
38426        Additionally substitute "screenSize" for "viewporScreenSize" to make the code more understandable.
38427
38428        * WebCore.exp.in: Export symbol for WebCore System Interface function
38429        _wkGetAvailableScreenSize.
38430        * dom/Document.cpp:
38431        (WebCore::Document::processViewport): Modified to call Chrome::screenSize(); formerly it
38432        called ChromeClient::viewportScreenSize().
38433        * page/Chrome.cpp:
38434        (WebCore::Chrome::screenSize): Added; turns around and calls ChromeClient::screenSize().
38435        (WebCore::Chrome::availableScreenSize): Added; turns around and calls ChromeClient::availableScreenSize().
38436        * page/Chrome.h:
38437        * page/ChromeClient.h:
38438        (WebCore::ChromeClient::screenSize): Renamed; formerly named viewportScreenSize.
38439        (WebCore::ChromeClient::availableScreenSize): Added; default implementation, which
38440        returns the size of Chrome::windowRect().
38441        * page/ViewportConfiguration.cpp:
38442        (WebCore::ViewportConfiguration::textDocumentParameters):
38443        * platform/HostWindow.h: Added declarations for availableScreenSize() and screenSize()
38444        so that a caller (e.g. WebCore::screenRect()) can query for such screen information using
38445        only the HostWindow interface. That is, a caller doesn't need to know about ChromeClient.
38446        * platform/ios/PlatformScreenIOS.mm:
38447        (WebCore::screenRect): Modified to query HostWindow::screenSize() when computing the
38448        screen rectangle in WebKit2 for iOS.
38449        (WebCore::screenAvailableRect): Modified to query HostWindow::availableScreenSize()
38450        when computing the available screen rectangle in WebKit2 for iOS.
38451        * platform/ios/WebCoreSystemInterfaceIOS.mm:
38452        * platform/mac/WebCoreSystemInterface.h:
38453
384542014-04-17  Darin Adler  <darin@apple.com>
38455
38456        origin spoofing possible (HTTP Origin, postMessage event.origin) due to inappropriate URL escape sequence decoding
38457        https://bugs.webkit.org/show_bug.cgi?id=131837
38458        rdar://problem/15211936
38459
38460        Reviewed by Anders Carlsson and Dave Hyatt.
38461
38462        Tests: fast/dom/DOMURL/parsing.html
38463               fast/dom/HTMLAnchorElement/anchor-element-href-parsing.html
38464
38465        * platform/URL.cpp:
38466        (WebCore::URL::host): Removed unnecessary call to decodeURLEscapeSequences, which caused
38467        problems and was not needed.
38468
384692014-04-17  David Hyatt  <hyatt@apple.com>
38470
38471        [New Multicolumn] Pagination mode messed up with non-inline axis and reversed direction.
38472        https://bugs.webkit.org/show_bug.cgi?id=131811
38473
38474        Reviewed by Dean Jackson.
38475
38476        Added fast/multicol/newmulticol/compare-with-old-impl/BottomToTop-tb.html
38477        
38478        With block axis pagination mode, it is possible to set a column height that is not the same
38479        as the available fill height for a block. The new multi-column code had the assumption that
38480        the column height was the same as the amount of fill room you had available. This is not
38481        the case.
38482        
38483        To correct the issue, I added a member variable to RenderMultiColumnSet that stores the
38484        available column height as a separate variable from the computed column height. This allows
38485        the pagination API to specify a different column height that is not the same as the view's
38486        content height.
38487
38488        Even though it isn't involved in the solution, I also patched pageOrViewLogicalHeight on
38489        RenderView to work with the new column code as well.
38490
38491        * rendering/RenderMultiColumnSet.cpp:
38492        (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
38493        (WebCore::RenderMultiColumnSet::setAndConstrainColumnHeight):
38494        (WebCore::RenderMultiColumnSet::computeLogicalHeight):
38495        * rendering/RenderMultiColumnSet.h:
38496        * rendering/RenderView.cpp:
38497        (WebCore::RenderView::pageOrViewLogicalHeight):
38498
384992014-04-17  Anders Carlsson  <andersca@apple.com>
38500
38501        Build fix.
38502
38503        * svg/animation/SMILTime.h:
38504
385052014-04-17  Bem Jones-Bey  <bjonesbe@adobe.com>
38506
38507        Unreviewed, rolling out r167384.
38508
38509        Sounds like this isn't the right fix, and causes generation to
38510        run far too often.
38511
38512        Reverted changeset:
38513
38514        "Fix CodeGenerator.pm to only write files if the generated
38515        content has changed"
38516        https://bugs.webkit.org/show_bug.cgi?id=131756
38517        http://trac.webkit.org/changeset/167384
38518
385192014-04-17  Ryuan Choi  <ryuan.choi@samsung.com>
38520
38521        Remove unnecessary MathExtras.h includes
38522        https://bugs.webkit.org/show_bug.cgi?id=131789
38523
38524        Reviewed by Anders Carlsson.
38525
38526        * platform/FileSystem.h:
38527        * platform/Scrollbar.h:
38528        * platform/animation/AnimationUtilities.h:
38529        * platform/audio/DenormalDisabler.h:
38530        * platform/graphics/Font.h:
38531        * platform/graphics/IntPoint.h: Included cmath instad of MathExtras.h.
38532        * platform/graphics/LayoutPoint.h:
38533        * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
38534        * rendering/svg/SVGMarkerData.h:
38535        * svg/animation/SMILTime.h:
38536
385372014-04-16  Huang Dongsung  <luxtella@company100.net>
38538
38539        Make RenderLayerBacking get the timingFunction of the correct animation.
38540        https://bugs.webkit.org/show_bug.cgi?id=100632
38541
38542        Reviewed by Simon Fraser.
38543
38544        When an element has multiple animations that have different timingFunctions,
38545        the progress of each animation should be calculated using its respective
38546        timingFunction. But at this point, the timingFunction of the first animation is
38547        only used in RenderLayerBacking::startAnimation(), regardless of how many
38548        animations the element has.
38549
38550        getAnimationFromStyleByName() was introduced in r89462 so that the
38551        timingFunction of the correct animation searched by its name would be
38552        used. This patch moves the function to KeyframeValue::timingFunction()
38553        so that RenderLayerBacking reuses this method.
38554
38555        Test: animations/keyframe-multiple-timing-functions-transform.html
38556
38557        * page/animation/KeyframeAnimation.cpp:
38558        (WebCore::KeyframeAnimation::fetchIntervalEndpointsForProperty):
38559        * rendering/RenderLayerBacking.cpp:
38560        (WebCore::RenderLayerBacking::startAnimation):
38561        * rendering/style/KeyframeList.cpp:
38562        (WebCore::KeyframeValue::timingFunction):
38563        (WebCore):
38564        * rendering/style/KeyframeList.h:
38565        (WebCore):
38566        (KeyframeValue):
38567
385682014-04-17  Andreas Kling  <akling@apple.com>
38569
38570        Rollout: Add a way to cache never-changing IDL attributes in the wrapper.
38571        <https://webkit.org/b/131759>
38572
38573        This behavior may be observable from the web, so we can't do it this way.
38574
38575        * bindings/scripts/CodeGeneratorJS.pm:
38576        (GenerateImplementation):
38577        * bindings/scripts/IDLAttributes.txt:
38578        * bindings/scripts/test/*:
38579        * dom/Element.idl:
38580        * dom/Node.idl:
38581
385822014-04-17  Andreas Kling  <akling@apple.com>
38583
38584        Cheesy Mountain Lion build fix.
38585
38586        * platform/MemoryPressureHandler.h:
38587        (WebCore::MemoryPressureHandler::ReliefLogger::logString):
38588
385892014-04-17  David Hyatt  <hyatt@apple.com>
38590
38591        [New Multicolumn] Column rules don't respect the specified stacking order.
38592        https://bugs.webkit.org/show_bug.cgi?id=131804
38593
38594        Reviewed by Beth Dakin.
38595
38596        Added fast/multicol/newmulticol/compare_with_old_impl/column-rules-stacking.html
38597
38598        * rendering/RenderBlockFlow.cpp:
38599        (WebCore::RenderBlockFlow::paintBoxDecorations):
38600        * rendering/RenderBlockFlow.h:
38601        Override paintBoxDecorations for block flows so that we can iterate over our column sets
38602        and paint their rules just after painting our background and border. We can't wait until
38603        the child column sets paint their backgrounds, since that is specified as being above negative
38604        z-index children. We have to pretend that the column sets don't exist as
38605        far as column rule painting is concerned.
38606
38607        * rendering/RenderMultiColumnSet.cpp:
38608        (WebCore::RenderMultiColumnSet::paintObject): Deleted.
38609        * rendering/RenderMultiColumnSet.h:
38610        Turn paintObject in RenderMultiColumnSet into an override that doesn't paint anything.
38611
386122014-04-17  Beth Dakin  <bdakin@apple.com>
38613
38614        Hit-testing is incorrect for plugins inside iframes when there is a 
38615        topContentInset
38616        https://bugs.webkit.org/show_bug.cgi?id=131826
38617        -and corresponding-
38618        <rdar://problem/16649996>
38619
38620        Reviewed by Tim Horton.
38621
38622        I missed one coordinate-conversion spot when getting hit-testing to work. Like 
38623        headerHeight() which also manipulates the location of the root layer, 
38624        topContentInset() has to be factored into all of these conversions.
38625        * page/FrameView.cpp:
38626        (WebCore::FrameView::convertFromRenderer):
38627
386282014-04-17  Andreas Kling  <akling@apple.com>
38629
38630        Stub out MemoryPressureHandler::ReliefLogger on older OS X'es.
38631
38632        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
38633        (WebCore::MemoryPressureHandler::ReliefLogger::platformLog):
38634        (WebCore::MemoryPressureHandler::ReliefLogger::platformMemoryUsage):
38635
386362014-04-17  Dirk Schulze  <krit@webkit.org>
38637
38638        Remove CANVAS_PATH where possible
38639        https://bugs.webkit.org/show_bug.cgi?id=131788
38640
38641        Reviewed by Dean Jackson.
38642
38643        Since Firefox and Chrome ship the same interoperable subset of Path2D soon, 
38644        it is time to remove CANVAS_PATH where possible.
38645
38646        * html/canvas/CanvasRenderingContext2D.cpp:
38647        (WebCore::CanvasRenderingContext2D::clip):
38648        (WebCore::CanvasRenderingContext2D::isPointInStroke):
38649        * html/canvas/CanvasRenderingContext2D.h:
38650        * html/canvas/CanvasRenderingContext2D.idl:
38651        * html/canvas/DOMPath.h:
38652        * html/canvas/DOMPath.idl:
38653
386542014-04-17  Brendan Long  <b.long@cablelabs.com>
38655
38656        [GStreamer] Store TrackPrivateBaseGStreamer's label and language as AtomicStrings
38657        https://bugs.webkit.org/show_bug.cgi?id=130404
38658
38659        Reviewed by Philippe Normand.
38660
38661        No new tests, this just makes things more efficient.
38662
38663        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
38664        (WebCore::TrackPrivateBaseGStreamer::getLanguageCode):
38665        (WebCore::TrackPrivateBaseGStreamer::getTag):
38666        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:
38667
386682014-04-17  Andreas Kling  <akling@apple.com>
38669
38670        Fix Cocoa build.
38671
38672        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
38673        (WebCore::MemoryPressureHandler::ReliefLogger::platformMemoryUsage):
38674
386752014-04-17  Rik Cabanier  <cabanier@adobe.com>
38676
38677        [CSS Blending] Remove the -webkit- prefix for mix-blend-mode and isolation CSS properties
38678        https://bugs.webkit.org/show_bug.cgi?id=131355
38679
38680        Reviewed by Dean Jackson.
38681
38682        Removed webkit prefix from mix-blend-mode and isolation. These properties
38683        never shipped and their spec is now in CR.
38684
38685        Covered by existing tests.
38686
38687        * css/CSSComputedStyleDeclaration.cpp:
38688        (WebCore::ComputedStyleExtractor::propertyValue):
38689        * css/CSSParser.cpp:
38690        (WebCore::isValidKeywordPropertyAndValue):
38691        (WebCore::isKeywordPropertyID):
38692        (WebCore::CSSParser::parseValue):
38693        * css/CSSPropertyNames.in:
38694        * css/DeprecatedStyleBuilder.cpp:
38695        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
38696
386972014-04-17  David Kilzer  <ddkilzer@apple.com>
38698
38699        Tidy up isIsolatedInline() and highestContainingIsolateWithinRoot()
38700        <http://webkit.org/b/131117>
38701
38702        Reviewed by Daniel Bates.
38703
38704        Based on review feedback for r166650.
38705
38706        * rendering/InlineIterator.h:
38707        (WebCore::isIsolatedInline):
38708        - Switch argument to a reference since it is never called with a
38709          nullptr.
38710        (WebCore::highestContainingIsolateWithinRoot):
38711        - Switch first argument to a reference since it's never a
38712          nullptr.
38713        - Use nullptr for pointer initialization.
38714        - Switch while() loop to for() loop. Pass reference to
38715          isIsolatedInline().
38716        (WebCore::numberOfIsolateAncestors):
38717        - Switch while() loop to for() loop. Pass reference to
38718          isIsolatedInline().
38719        * rendering/RenderBlockLineLayout.cpp:
38720        (WebCore::constructBidiRunsForSegment):
38721        - Rename startObj to startObject.
38722        - No longer need to pass the address of startObject here.
38723
387242014-04-17  Andreas Kling  <akling@apple.com>
38725
38726        Log number of bytes reclaimed at each step of memory pressure relief.
38727        <https://webkit.org/b/131751>
38728
38729        Reviewed by Antti Koivisto.
38730
38731        * platform/MemoryPressureHandler.h:
38732        * platform/MemoryPressureHandler.cpp:
38733        (WebCore::MemoryPressureHandler::ReliefLogger::platformLog):
38734        (WebCore::MemoryPressureHandler::ReliefLogger::platformMemoryUsage):
38735        (WebCore::MemoryPressureHandler::ReliefLogger::ReliefLogger):
38736        (WebCore::MemoryPressureHandler::ReliefLogger::~ReliefLogger):
38737        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
38738        (WebCore::MemoryPressureHandlerCocoa::ReliefLogger::platformMemoryUsage):
38739        (WebCore::MemoryPressureHandlerCocoa::ReliefLogger::platformLog):
38740
38741            Add a simple RAII helper to check memory usage before and after
38742            a block of code, and then dump the delta to system log.
38743
38744        (WebCore::MemoryPressureHandler::releaseMemory):
38745        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
38746        (WebCore::MemoryPressureHandler::platformReleaseMemory):
38747
38748            Use ReliefLogger to annotate the various attempts to reduce
38749            our memory footprint. This will help us understand the efficiency
38750            of our current strategy.
38751
387522014-04-17  David Hyatt  <hyatt@apple.com>
38753
38754        [New Multicolumn] columnNumberForOffset is not patched for new multicolumn code yet.
38755        https://bugs.webkit.org/show_bug.cgi?id=131740
38756
38757        Reviewed by Enrica Casucci.
38758        
38759        I took the opportunity to clean this code up while adding support for the new columns.
38760        columnNumberForOffset only applied for paginated RenderViews and was really about
38761        pages and not columns. It also only returns an actual page number if the columns are
38762        block progressed (e.g., right-to-left vertical Japanese books).
38763        
38764        Therefore I renamed columnNumberForOffset to pageNumberForBlockProgressionOffset and
38765        moved it to RenderView.
38766        
38767        I also renamed the member variable of SelectionRect to be pageNumber instead of
38768        columnNumber in order to make it more obvious that this isn't about columns per se
38769        (since the fact that we implemented RenderView's pagination mode using columns is an
38770        implementation detail).
38771
38772        * dom/Range.cpp:
38773        (WebCore::coalesceSelectionRects):
38774        (WebCore::Range::collectSelectionRects):
38775        * platform/ios/SelectionRect.h:
38776        (WebCore::SelectionRect::pageNumber):
38777        (WebCore::SelectionRect::columnNumber): Deleted.
38778        * rendering/RenderImage.cpp:
38779        (WebCore::RenderImage::collectSelectionRects):
38780        * rendering/RenderObject.cpp:
38781        (WebCore::RenderObject::collectSelectionRects):
38782        (WebCore::RenderObject::columnNumberForOffset): Deleted.
38783        * rendering/RenderObject.h:
38784        * rendering/RenderText.cpp:
38785        (WebCore::RenderText::collectSelectionRects):
38786        * rendering/RenderView.cpp:
38787        (WebCore::RenderView::pageNumberForBlockProgressionOffset):
38788        * rendering/RenderView.h:
38789
387902014-04-16  Brent Fulgham  <bfulgham@apple.com>
38791
38792        [Win] A few final cleanups to the DataObject classes.
38793        https://bugs.webkit.org/show_bug.cgi?id=131784
38794
38795        Reviewed by Anders Carlsson.
38796
38797        * platform/win/WCDataObject.cpp:
38798        (WebCore::WCDataObject::clearData): Use 'last()' method.
38799
388002014-04-15  Jer Noble  <jer.noble@apple.com>
38801
38802        Fullscreen media controls are unusable in pagination mode
38803        https://bugs.webkit.org/show_bug.cgi?id=131705
38804
38805        Reviewed by Darin Adler.
38806
38807        When pagination mode is enabled, the full screen media will (depending on the width of the
38808        pagination columns) overflow its column, and hit testing will be clipped to the column. In extreme
38809        cases, where the column width < 0.5 * media element width, the media controls will be entirely
38810        unclickable.
38811
38812        Rather than making the RenderFullScreen a child of the full screen element's parent's renderer,
38813        make it a child of the RenderView, putting it outside of the columns entirely. Always create and
38814        insert the fullscreenRenderer's placeholder, using it as the remembered insertion point for the
38815        fullscreen element's renderer when we exit full screen.
38816
38817        Drive-by fix: don't wrap the full screen element's renderer in webkitWillEnterFullScreenForElement();
38818        it will just be re-wrapped in createRendererIfNeeded().
38819
38820        * dom/Document.cpp:
38821        (WebCore::Document::webkitWillEnterFullScreenForElement): Don't wrap the full screen element's renderer.
38822        (WebCore::Document::setFullScreenRenderer): Call setPlaceholderStyle.
38823        * rendering/RenderFullScreen.cpp:
38824        (WebCore::RenderFullScreenPlaceholder::willBeDestroyed): Call clearPlaceholder.
38825        (WebCore::RenderFullScreen::wrapRenderer): Make fullscreenRenderer a child of the view().
38826        (WebCore::RenderFullScreen::unwrapRenderer): Return the children to the parent of the placeholder().
38827        (WebCore::RenderFullScreen::clearPlaceholder): Renamed from setPlaceholder().
38828        (WebCore::RenderFullScreen::ensurePlaceholder): Added. 
38829        (WebCore::RenderFullScreen::setPlaceholderStyle): Renamed from createPlaceholder().
38830        (WebCore::RenderFullScreen::setPlaceholder): Deleted.
38831        (WebCore::RenderFullScreen::createPlaceholder): Deleted.
38832        * rendering/RenderFullScreen.h:
38833
388342014-04-16  Jer Noble  <jer.noble@apple.com>
38835
38836        [MSE] Multiple initialization segments with same codecs in tracks fail validation.
38837        https://bugs.webkit.org/show_bug.cgi?id=131768
38838
38839        Additional initialization segments added to the same SourceBuffer with the same
38840        codec values will fail validation. Update the validation check to add the correct
38841        codec information for the initial segment, and check against the correct codecs during
38842        the validation step.
38843
38844        Additionally, after validation, if successful update the Audio, Video, and TextTracks
38845        for the SourceBuffer with the updated initialization segment information.
38846
38847        Reviewed by Eric Carlson.
38848
38849        Test: media/media-source/media-source-multiple-initialization-segments.html
38850
38851        * Modules/mediasource/SourceBuffer.cpp:
38852        (WebCore::SourceBuffer::appendBufferTimerFired): m_source may have been cleared
38853            as a result of the append, so check it before using.
38854        (WebCore::SourceBuffer::sourceBufferPrivateDidEndStream): Call streamEndedWithError
38855            instead of endOfStream as the latter is safe to call within an update.
38856        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment): Ditto.
38857            Update the track lists if validation succeeds.
38858        (WebCore::SourceBuffer::validateInitializationSegment): Switch the audio and video
38859            codec checks.
38860
38861        Add the ability for Audio, Video, and InbandTextTracks to replace their private tracks:
38862        * html/track/AudioTrack.cpp:
38863        (WebCore::AudioTrack::AudioTrack): Call updateKindFromPrivate().
38864        (WebCore::AudioTrack::setPrivate):
38865        (WebCore::AudioTrack::updateKindFromPrivate): Split out from constructor.
38866        * html/track/AudioTrack.h:
38867        * html/track/InbandTextTrack.cpp:
38868        (WebCore::InbandTextTrack::InbandTextTrack): Call updateKindFromPrivate().
38869        (WebCore::InbandTextTrack::setPrivate):
38870        (WebCore::InbandTextTrack::setMode): Split up into setModeInternal().
38871        (WebCore::InbandTextTrack::setModeInternal): Broke out from setMode().
38872        (WebCore::InbandTextTrack::updateKindFromPrivate): Split out from constructor.
38873        * html/track/InbandTextTrack.h:
38874        * html/track/TextTrack.h:
38875        (WebCore::TextTrack::isInband): Added, returns false.
38876        * html/track/VideoTrack.cpp:
38877        (WebCore::VideoTrack::VideoTrack): Call updateKindFromPrivate().
38878        (WebCore::VideoTrack::setPrivate):
38879        (WebCore::VideoTrack::updateKindFromPrivate):  Split out from constructor.
38880        * html/track/VideoTrack.h:
38881
388822014-04-17  David Hyatt  <hyatt@apple.com>
38883
38884        [New Multicolumn] Column sets below spanners don't repaint properly.
38885        https://bugs.webkit.org/show_bug.cgi?id=131778
38886
38887        Reviewed by Beth Dakin.
38888
38889        Added fast/repaint/spanner-with-margins.html.
38890
38891        * rendering/RenderBox.cpp:
38892        (WebCore::RenderBox::computeRectForRepaint):
38893        Turn off some code that was running for in-flow RenderFlowThreads that made no sense.
38894        I'm not convinced the code is right for other types of RenderFlowThreads either,
38895        but will leave that to the named flow thread experts. :)
38896
388972014-04-17  Koji Ishii  <kojishi@gmail.com>
38898
38899        Catch up ruby and its tag omission rule changes in HTML5 CR Feb 2014
38900        https://bugs.webkit.org/show_bug.cgi?id=131175
38901
38902        Reviewed by Darin Adler.
38903
38904        Tests: html5lib/resources/ruby.dat
38905               html5lib/resources/tests19.dat
38906
38907        This patch makes WebKit HTML parser to match to the tag omission rules of HTML5 CR Feb 2014:
38908        http://www.w3.org/TR/2014/CR-html5-20140204/syntax.html#syntax-tag-omission
38909        with the support for two new elements (rb, rtc) which were also defined in the spec:
38910        http://www.w3.org/TR/2014/CR-html5-20140204/text-level-semantics.html#the-rb-element
38911        http://www.w3.org/TR/2014/CR-html5-20140204/text-level-semantics.html#the-rtc-element
38912        to better support use cases presented by W3C I18N WG:
38913        http://www.w3.org/TR/ruby-use-cases/
38914
38915        * html/HTMLTagNames.in: rb and rtc added as HTMLElement interfaces.
38916        * html/parser/HTMLConstructionSite.cpp:
38917        (WebCore::hasImpliedEndTag): the spec says rb and rtc have implied end tags.
38918        * html/parser/HTMLTreeBuilder.cpp:
38919        (WebCore::HTMLTreeBuilder::processStartTagForInBody): rb and rtc added. rt excludes rtc from its implied end tags.
38920
389212014-04-17  Darin Adler  <darin@apple.com>
38922
38923        Try to fix EFL and GTK builds.
38924
38925        * workers/WorkerGlobalScope.idl: Touch file to make it rebuild, assuming that
38926        module dependencies aren't working right with CMake. Tweaked formatting quite a
38927        bit while I was in here.
38928
389292014-04-17  David Hyatt  <hyatt@apple.com>
38930
38931        [New Multicolumn] REGRESSION: Column set styles don't update when zooming etc.
38932        https://bugs.webkit.org/show_bug.cgi?id=131777
38933
38934        Reviewed by Enrica Casucci.
38935
38936        Added fast/multicol/zoom-test.html
38937
38938        * rendering/RenderBlockFlow.cpp:
38939        (WebCore::RenderBlockFlow::styleDidChange):
38940        Put back in the code that propagates new styles to the flow thread and column sets
38941        when styles change. This propagation was removed when the column span code landed.
38942        This patch puts it back in but qualifies the types of objects that get styles
38943        propagated to avoid accidentally propagating the wrong style to column spans.
38944
389452014-04-17  Darin Adler  <darin@apple.com>
38946
38947        Add separate flag for IndexedDatabase in workers since the current implementation is not threadsafe
38948        https://bugs.webkit.org/show_bug.cgi?id=131785
38949        rdar://problem/16003108
38950
38951        Reviewed by Brady Eidson.
38952
38953        * Configurations/FeatureDefines.xcconfig: Added INDEXED_DATABASE_IN_WORKERS.
38954
38955        * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.cpp: Use the new conditional
38956        instead of the old one.
38957        * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.h: Ditto.
38958        * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.idl: Ditto.
38959
389602014-04-17  Dan Bernstein  <mitz@apple.com>
38961
38962        WebCore part of <rdar://problem/16601336> [Cocoa] _userInitiated is always NO in WKNavigationAction passed to -webView:createWebViewWithConfiguration:forNavigationAction:windowFeatures:
38963        https://bugs.webkit.org/show_bug.cgi?id=131783
38964
38965        Reviewed by Tim Horton.
38966
38967        * loader/NavigationAction.cpp:
38968        (WebCore::NavigationAction::NavigationAction): Initialize m_processingUserGesture to
38969        ScriptController::processingUserGesture() at the time the NavigationAction is constructed.
38970        * loader/NavigationAction.h:
38971        Added boolean member variable m_processionUserGesture
38972        (WebCore::NavigationAction::processingUserGesture): Added this getter.
38973
389742014-04-17  Ion Rosca  <rosca@adobe.com>
38975
38976        [CSS Blending] Isolation descendant dependent flags are not updated correctly
38977        https://bugs.webkit.org/show_bug.cgi?id=130892
38978
38979        Reviewed by Dean Jackson.
38980
38981        The isolation descendant dependent flag (m_hasUnisolatedBlendingDescendants)
38982        will help us to determine if a layer should isolate blending descendants or not.
38983        The m_hasUnisolatedBlendingDescendants flag should be set for layers that have blending descendant layers
38984        not isolated by descendant stacking contexts.
38985        An element isolatesBlending() if it has this flag set and creates stacking context.
38986
38987        Tests: css3/compositing/blend-mode-isolation-flags-append-non-stacking-context-blending.html
38988               css3/compositing/blend-mode-isolation-flags-append-stacking-context-blending.html
38989               css3/compositing/blend-mode-isolation-flags-remove-non-stacking-context-blending.html
38990               css3/compositing/blend-mode-isolation-flags-remove-stacking-context-blending.html
38991               css3/compositing/blend-mode-isolation-flags-turn-off-blending-no-isolation.html
38992               css3/compositing/blend-mode-isolation-flags-turn-off-blending.html
38993               css3/compositing/blend-mode-isolation-flags-turn-off-stacking-context.html
38994               css3/compositing/blend-mode-isolation-flags-turn-on-blending.html
38995               css3/compositing/blend-mode-isolation-flags-turn-on-stacking-context.html
38996
38997        * rendering/RenderLayer.cpp:
38998        (WebCore::RenderLayer::RenderLayer):
38999        (WebCore::RenderLayer::updateBlendMode):
39000        (WebCore::RenderLayer::updateAncestorChainHasBlendingDescendants):
39001            When a layer has blending and it hasn't had it before, we set the isolation
39002        flag for all its ancestors up to the first layer creating stacking context.
39003        I removed the isComposited() check here. Isolation flags should be correct regardless
39004        of compositing state. Moreover, if this method is called from styleChanged(),
39005        the compositing state might not be accurate, it's going to be recalculated afterwards.  
39006        (WebCore::RenderLayer::dirtyAncestorChainHasBlendingDescendants):
39007            When a layer doesn't have blending, but it used to have it before, we mark
39008        the isolation flag as dirty for all its ancestors up to the first layer
39009        creating stacking context. The isolation flags will be recalculated by
39010        RenderLayer::updateDescendantDependentFlags.
39011        (WebCore::RenderLayer::updateDescendantDependentFlags):
39012            Evaluates if the layer has unisolated blending descendants by traversing
39013        the layer subtree.
39014        (WebCore::RenderLayer::addChild):
39015            When adding a subtree that has blending or has some unisolated descendants,
39016        we set the flag for all the ancestors, up to the stacking context layer.
39017        (WebCore::RenderLayer::removeChild):
39018            When removing a subtree that had blending or had some unisolated descendants,
39019        we dirty the flag so that it could be reevaluated.
39020        (WebCore::RenderLayer::calculateClipRects):
39021        (WebCore::RenderLayer::updateTransform):
39022        * rendering/RenderLayer.h:
39023            Rename m_hasBlendedElementInChildStackingContext => m_hasUnisolatedBlendingDescendants
39024        and m_hasBlendedElementInChildStackingContextStatusDirty => m_hasUnisolatedBlendingDescendantsStatusDirty,
39025        * rendering/RenderLayerCompositor.cpp:
39026        (WebCore::RenderLayerCompositor::computeCompositingRequirements):
39027            Add an assert to make sure that if m_hasUnisolatedCompositedBlendingDescendants is true,
39028        then m_hasUnisolatedBlendingDescendants is true as well.
39029
390302014-04-17  Tim Horton  <timothy_horton@apple.com>
39031
39032        Uninline blend(Color, Color) to get AnimationUtilities out of Color.h
39033        https://bugs.webkit.org/show_bug.cgi?id=131781
39034
39035        Reviewed by Simon Fraser.
39036
39037        * platform/graphics/Color.cpp:
39038        (WebCore::blend):
39039        Un-inline.
39040
39041        * platform/graphics/Color.h:
39042        No more AnimationUtilities.
39043
390442014-04-16  Benjamin Poulain  <bpoulain@apple.com>
39045
39046        Fix the build after r167412
39047
39048        * platform/ScrollView.cpp:
39049        (WebCore::ScrollView::updateScrollbars):
39050
390512014-04-16  Benjamin Poulain  <bpoulain@apple.com>
39052
39053        [iOS][WK2] Fix annoying scrolling bugs
39054        https://bugs.webkit.org/show_bug.cgi?id=131722
39055
39056        Reviewed by Simon Fraser.
39057
39058        * platform/ScrollView.cpp:
39059        (WebCore::ScrollView::updateScrollbars):
39060        Since ScrollingStateScrollingNode::setRequestedScrollPosition() was added, we see ScrollView::updateScrollbars()
39061        keep changing the scroll position to incorrect values.
39062
39063        On iOS, the scrollbars are handled by the native UI, the code just compute incorrect scroll position. On WebKit1,
39064        the code does not run because there is a platformWidget().
39065
39066        Just #ifdef the whole useless code.
39067
390682014-04-16  Alexandru Chiculita  <achicu@adobe.com>
39069
39070        Improve performance of the RenderLayerCompositor::OverlapMap
39071        https://bugs.webkit.org/show_bug.cgi?id=115063
39072
39073        Reviewed by Simon Fraser.
39074
39075        No new tests, no new functionality or behavior.
39076
39077        Do not use the OverlapMap in RenderLayerCompositor::computeCompositingRequirements if the layer already
39078        has a 3D transform. This way we can avoid a potential expensive lookups when we know for sure the layer
39079        is already supposed to be composited. 
39080
39081        Also, added a bounding box of the overlap map, so that it can catch cases when the new layer is not overlapping
39082        any of the previous layers. This is pretty common when having composited layers laid out in a vertical/horizontal list.
39083
39084
39085        * rendering/RenderLayerCompositor.cpp:
39086        (OverlapMapContainer):
39087        (WebCore::OverlapMapContainer::add):
39088        (WebCore::OverlapMapContainer::overlapsLayers):
39089        (WebCore::OverlapMapContainer::unite):
39090        (WebCore):
39091        (WebCore::RenderLayerCompositor::OverlapMap::add):
39092        (WebCore::RenderLayerCompositor::OverlapMap::overlapsLayers):
39093        (WebCore::RenderLayerCompositor::OverlapMap::pushCompositingContainer):
39094        (WebCore::RenderLayerCompositor::OverlapMap::popCompositingContainer):
39095        (RenderLayerCompositor::OverlapMap):
39096        (WebCore::RenderLayerCompositor::computeCompositingRequirements):
39097
390982014-04-16  Brian J. Burg  <burg@cs.washington.edu>
39099
39100        Web Replay: memoize fallback time values for document.lastModified
39101        https://bugs.webkit.org/show_bug.cgi?id=131318
39102
39103        Reviewed by Joseph Pecoraro.
39104
39105        If a document's Last-Modified header can't be found or used, then 
39106        document.lastModified is derived from the current system time or
39107        from filesystem data, which is obviously nondeterministic.
39108
39109        It's better to handle this inside Document::lastModified rather than using
39110        MemoizedDOMResult, because only the fallback case is nondeterministic.
39111
39112        Test: http/tests/inspector/replay/document-last-modified-fallback-value.html
39113
39114        The test is skipped for now, as it will be very flaky without the
39115        functionality introduced by bugs 130728 and 129391.
39116
39117        * dom/Document.cpp:
39118        (WebCore::Document::lastModified): Save or reuse memoized fallback value.
39119        * replay/WebInputs.json: Add input DocumentLastModifiedDate.
39120
391212014-04-16  David Hyatt  <hyatt@apple.com>
39122
39123        [New Multicolumn] Selection gets confused when the mouse is in the column gaps.
39124        https://bugs.webkit.org/show_bug.cgi?id=131739
39125
39126        Reviewed by Enrica Casucci.
39127
39128        * rendering/RenderBlock.cpp:
39129        (WebCore::RenderBlock::selectionGaps):
39130        Make sure not to paint selection gaps. This matches the old multi-column behavior. Even though
39131        selection gaps *nearly* work with the new multi-column code, I am disabling them so that we
39132        can turn them on without visual regressions.
39133        
39134        (WebCore::isChildHitTestCandidate):
39135        Don't allow in-flow RenderFlowThreads to be descended into from positionForPoint. We always want
39136        to look only at the spanners and at the sets.
39137
39138        * rendering/RenderMultiColumnFlowThread.cpp:
39139        (WebCore::RenderMultiColumnFlowThread::nodeAtPoint):
39140        * rendering/RenderMultiColumnFlowThread.h:
39141        Override nodeAtPoint to disallow the RenderMultiColumnFlowThread from being considered for hit
39142        testing when no DOM node is found. It's better to just let RenderBlock's positionForPoint run
39143        to drill back down into the appropriate column set.
39144
39145        * rendering/RenderMultiColumnSet.cpp:
39146        (WebCore::RenderMultiColumnSet::positionForPoint):
39147        Implement positionForPoint for RenderMultiColumnSets. This is a straight-up port of the
39148        old multi-column code's adjustPointToColumnContents function.
39149
39150        * rendering/RenderMultiColumnSet.h:
39151        Add override of positionForPoint.
39152
391532014-04-16  Dean Jackson  <dino@apple.com>
39154
39155        MediaDocument on iOS should be full page
39156        https://bugs.webkit.org/show_bug.cgi?id=131774
39157
39158        Reviewed by Jer Noble.
39159
39160        A MediaDocument on iOS has two problems. It can't rely
39161        on intrinsic size, since it doesn't load the content until
39162        a user gesture. Secondly, on a small screen you want the
39163        media to fill the page.
39164
39165        Add width/height 100% for iOS documents.
39166
39167        Test: platform/iphone-simulator/media/media-document-controls-size.html
39168
39169        * html/MediaDocument.cpp:
39170        (WebCore::MediaDocumentParser::createDocumentStructure):
39171
391722014-04-16  Roger Fong  <roger_fong@apple.com>
39173
39174        Add a way for layout tests to determine whether or not a plugin is snapshotted.
39175        https://bugs.webkit.org/show_bug.cgi?id=131650.
39176        <rdar://problem/16615528>
39177
39178        Reviewed by Dean Jackson.
39179
39180        * testing/Internals.cpp:
39181        (WebCore::Internals::isPluginSnapshotted):
39182        * testing/Internals.h:
39183        * testing/Internals.idl:
39184
391852014-04-16  Zoltan Horvath  <zoltan@webkit.org>
39186
39187        Vanish unnecessary includes from Shapes.{h|cpp}
39188        https://bugs.webkit.org/show_bug.cgi?id=131762
39189
39190        Reviewed by Andreas Kling.
39191
39192        No new tests, no behavior change.
39193
39194        * rendering/shapes/BoxShape.h:
39195        * rendering/shapes/Shape.cpp:
39196        * rendering/shapes/Shape.h:
39197        * rendering/shapes/ShapeOutsideInfo.h:
39198
391992014-04-16  Andreas Kling  <akling@apple.com>
39200
39201        Revert direct caching of tagName and nodeName from r167383.
39202
39203        Ryosuke tells me this is not entirely safe, will need to rethink.
39204
39205        * dom/Element.idl:
39206        * dom/Node.idl:
39207
392082014-04-16  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
39209
39210        Improve security mitigation added in webkit r94001.
39211        We missed the case where attachLine was called when we already had an inline box wrapper.
39212        https://bugs.webkit.org/show_bug.cgi?id=127285
39213
39214        Reviewed by Brent Fulgham.
39215
39216        Merged from Blink: https://src.chromium.org/viewvc/blink?revision=150697&view=revision
39217
39218        * rendering/RenderBox.cpp:
39219        (WebCore::RenderBox::positionLineBox):
39220        * rendering/RenderBox.h:
39221        (WebCore::RenderBox::setInlineBoxWrapper):
39222
392232014-04-16  Bem Jones-Bey  <bjonesbe@adobe.com>
39224
39225        Fix CodeGenerator.pm to only write files if the generated content has changed
39226        https://bugs.webkit.org/show_bug.cgi?id=131756
39227
39228        Reviewed by Sam Weinig.
39229
39230        To improve build speed, don't touch generated files unless the newly
39231        generated content is actually different.
39232
39233        * bindings/scripts/CodeGenerator.pm:
39234        (UpdateFile):
39235
392362014-04-16  Andreas Kling  <akling@apple.com>
39237
39238        Add a way to cache never-changing IDL attributes in the wrapper.
39239        <https://webkit.org/b/131759>
39240
39241        Some IDL attributes will always return the same value when queried
39242        on an object, so let's have a way to avoid calling into C++ code
39243        every time they are queried.
39244
39245        This patch adds a custom IDL thingy called "ReturnsCacheableValue"
39246        which causes the code generator to emit code to cache the returned
39247        value directly in the JS wrapper object.
39248
39249        Reviewed by Oliver Hunt.
39250
39251        * bindings/scripts/IDLAttributes.txt:
39252        * bindings/scripts/CodeGeneratorJS.pm:
39253        (GenerateImplementation):
39254
39255            Add ReturnsCacheableValue custom attribute.
39256
39257        * dom/Element.idl:
39258        * dom/Node.idl:
39259
39260            Annotate some attributes that return fully cacheable values.
39261
39262        * bindings/scripts/test/*:
39263
39264            Rebaseline.
39265
392662014-04-16  Noel Gordon  <noel.gordon@gmail.com>
39267
39268        Progressive JPEG outputScanlines() calls should handle failure
39269        https://bugs.webkit.org/show_bug.cgi?id=116701
39270
39271        Reviewed by Brent Fulgham.
39272
39273        outputScanlines() can fail and delete |this|. Copy the decoder pointer
39274        member and use that copy to detect and handle the failure case.
39275
39276        * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
39277        (WebCore::JPEGImageReader::decode):
39278
392792014-04-16  Robert Sipka  <sipka@inf.u-szeged.hu>
39280
39281        [curl] Add WEB_TIMING support
39282        https://bugs.webkit.org/show_bug.cgi?id=127555
39283
39284        Reviewed by Brent Fulgham.
39285
39286        Access timing information related to navigation.
39287
39288        * platform/network/curl/ResourceHandleManager.cpp:
39289        (WebCore::milisecondsSinceRequest):
39290        (WebCore::calculateWebTimingInformations):
39291        (WebCore::sockoptfunction):
39292        (WebCore::headerCallback):
39293        (WebCore::ResourceHandleManager::downloadTimerCallback):
39294        (WebCore::ResourceHandleManager::dispatchSynchronousJob):
39295        (WebCore::ResourceHandleManager::initializeHandle):
39296
392972014-04-16  Zoltan Horvath  <zoltan@webkit.org>
39298
39299        Cleanup header includes in ShapeOutsideInfo.h
39300        https://bugs.webkit.org/show_bug.cgi?id=131750
39301
39302        Reviewed by Antti Koivisto.
39303
39304        Make the build faster by removing unnecessary header includes.
39305
39306        No new tests, no behavior change.
39307
39308        * rendering/shapes/ShapeOutsideInfo.h:
39309
393102014-04-16  Simon Fraser  <simon.fraser@apple.com>
39311
39312        Fix the iOS build.
39313
39314        * platform/graphics/cg/BitmapImageCG.cpp:
39315        (WebCore::BitmapImage::draw):
39316
393172014-04-16  Alexey Proskuryakov  <ap@apple.com>
39318
39319        DataTransfer should cache its FileList
39320        https://bugs.webkit.org/show_bug.cgi?id=131694
39321
39322        Reviewed by Darin Adler.
39323
39324        Test: fast/events/data-transfer-files-attribute-identity.html
39325
39326        * bindings/js/SerializedScriptValue.cpp: (WebCore::CloneDeserializer::readTerminal):
39327        Switched to a new FileList constructor, CloneDeserializer doesn't really need to modify
39328        the FileList with append().
39329
39330        * dom/DataTransfer.h:
39331        * dom/DataTransfer.cpp:
39332        (WebCore::DataTransfer::types): Added a FIXME.
39333        (WebCore::DataTransfer::files): Changed to reuse a cached FileList. It's currently
39334        easy, because we don't support DataTransferItemList. Once we do, making any changes
39335        through it will also require updating the FileList in a way that doesn't replace
39336        File objects for unchanged files.
39337
39338        * fileapi/FileList.h:
39339        (WebCore::FileList::create):
39340        (WebCore::FileList::isEmpty):
39341        (WebCore::FileList::FileList):
39342        (WebCore::FileList::append):
39343        (WebCore::FileList::clear):
39344        Made non-const functions private, because neither DataTransfer nor FileInputType
39345        expect the list to be modified without their knowledge. Added a new Vector based
39346        constructor so that a FileList could be created without the use of append().
39347
39348        * html/FileInputType.cpp: (WebCore::FileInputType::createFileList): Simplified
39349        the code a little bit. FileInputType still needs to modify the list for clear(),
39350        but doesn't need to add to it dynamically - unlike with DataTransfer, it's expected
39351        to create a new FileList when it's modified.
39352
393532014-04-15  Brent Fulgham  <bfulgham@apple.com>
39354
39355        [Win] Eliminate use of deleteAllValues in Windows Files
39356        https://bugs.webkit.org/show_bug.cgi?id=131631
39357
39358        Reviewed by Darin Adler.
39359
39360        Update to use std::unique_ptr for object lifetime. Get rid of
39361        deleteAllValues now that it is no loner needed. Use ranged for
39362        loops where possible.
39363
39364        * platform/win/WCDataObject.cpp:
39365        (WebCore::WCEnumFormatEtc::WCEnumFormatEtc):
39366        (WebCore::WCDataObject::~WCDataObject):
39367        (WebCore::WCDataObject::GetData):
39368        (WebCore::WCDataObject::QueryGetData):
39369        (WebCore::WCDataObject::SetData):
39370        (WebCore::WCDataObject::clearData):
39371        * platform/win/WCDataObject.h:
39372
393732014-04-16  Chris Fleizach  <cfleizach@apple.com>
39374
39375        AX: Accessing a table cell with an invalid column header crashes
39376        https://bugs.webkit.org/show_bug.cgi?id=131719
39377
39378        Reviewed by Darin Adler.
39379
39380        If no tableCell is available as a column/row header, then do not continue processing.
39381
39382        Test: accessibility/table-missing-column-header-crash.html
39383
39384        * accessibility/AccessibilityTableCell.cpp:
39385        (WebCore::AccessibilityTableCell::columnHeaders):
39386        (WebCore::AccessibilityTableCell::rowHeaders):
39387
393882014-04-16  Brendan Long  <b.long@cablelabs.com>
39389
39390        [GTK] Fix unused parameter warnings
39391        https://bugs.webkit.org/show_bug.cgi?id=131721
39392
39393        Reviewed by Darin Adler.
39394
39395        * bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
39396        (WebCore::toJS): Remove unused 'exec' parameter.
39397
393982014-04-16  Simon Fraser  <simon.fraser@apple.com>
39399
39400        Convert the boolean param of Image::startAnimation() to an enum
39401        https://bugs.webkit.org/show_bug.cgi?id=131742
39402
39403        Reviewed by Tim Horton.
39404
39405        Use an enum to make the code more readable.
39406
39407        * platform/graphics/BitmapImage.cpp:
39408        (WebCore::BitmapImage::startAnimation):
39409        * platform/graphics/BitmapImage.h:
39410        * platform/graphics/Image.cpp:
39411        (WebCore::Image::drawTiled):
39412        * platform/graphics/Image.h:
39413        (WebCore::Image::startAnimation):
39414        * svg/graphics/SVGImage.cpp:
39415        (WebCore::SVGImage::startAnimation):
39416        * svg/graphics/SVGImage.h:
39417
394182014-04-16  David Hyatt  <hyatt@apple.com>
39419
39420        Make sure to skip the RenderMultiColumnFlowThread when resolving percentage heights inside columns against
39421        containing blocks. The flow thread's auto height should not interfere if a fixed height is specified on
39422        an ancestor.
39423
39424        https://bugs.webkit.org/show_bug.cgi?id=131741
39425
39426        Reviewed by Simon Fraser.
39427
39428        Added fast/multicol/percent-height.html.
39429
39430        * rendering/RenderBox.cpp:
39431        (WebCore::RenderBox::skipContainingBlockForPercentHeightCalculation):
39432        Add an isInFlowRenderFlowThread check so that we skip those blocks and don't consider them at all
39433        when resolving percentage heights.
39434
394352014-04-16  Daewoong Jang  <daewoong.jang@navercorp.com>
39436
39437        [WinCairo][cURL] Build fix for WinCairo build with USE(CURL).
39438        https://bugs.webkit.org/show_bug.cgi?id=131614
39439
39440        Reviewed by Brent Fulgham.
39441
39442        Build fix, no new tests needed.
39443
39444        * platform/network/curl/CurlCacheEntry.cpp:
39445        (WebCore::CurlCacheEntry::loadResponseHeaders):
39446        * platform/network/curl/CurlCacheManager.cpp:
39447        (WebCore::CurlCacheManager::loadIndex):
39448        * platform/network/soup/ResourceError.h:
39449        * platform/network/soup/SocketStreamHandle.h:
39450
394512014-04-16  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
39452
39453        ASSERTION FAILED: x2 >= x1 in WebCore::RenderObject::drawLineForBoxSide
39454        https://bugs.webkit.org/show_bug.cgi?id=127835
39455
39456        In some cases when a negative margin and a positive padding are applied
39457        together to the right and/or left side of the box, the logical width of
39458        the borders can be set to a negative value, making the assertion fire.
39459        The fix checks if the width or height of the box is negative, and if so,
39460        it will not display the borders and shadows of the box.
39461
39462        Reviewed by Darin Adler.
39463
39464        Test: fast/css/padding-margin-negative-border.html
39465
39466        * rendering/RenderBoxModelObject.cpp:
39467        (WebCore::RenderBoxModelObject::paintBorder):
39468
394692014-04-16  Jer Noble  <jer.noble@apple.com>
39470
39471        [MSE] Seeks into buffered ranges will never complete.
39472        https://bugs.webkit.org/show_bug.cgi?id=131717
39473
39474        Reviewed by Eric Carlson.
39475
39476        Test: media/media-source/media-source-seek-complete.html
39477
39478        Run the SourceBuffer Monitoring step after initiating a seek.
39479
39480        * Modules/mediasource/SourceBuffer.cpp:
39481        (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime):
39482
394832014-04-15  Hyowon Kim  <hw1008.kim@samsung.com>
39484
39485        [EFL] Fix problems with the pixel dump.
39486        https://bugs.webkit.org/show_bug.cgi?id=131265
39487
39488        Reviewed by Gyuyoung Kim.
39489
39490        Painting and compositing paths of WebKit-EFL were totally modified from r166768.
39491        However pixel dump codes still call deprecated functions like ewk_view_paint(),
39492        which causes that nothing is drawn.
39493
39494        This patch adds new member functions to AcceleratedCompositingContext to support pixel dump.
39495        One of new functions is AcceleratedCompositingContext::extractImageData(),
39496        which replaces deprecated function calls. Besides the extractImageData() is invoked by
39497        ewk_view_screenshot_contents_get() in order to take the visible content displayed on the EFL webview.
39498
39499        * platform/graphics/cairo/CairoUtilities.cpp:
39500        (WebCore::flipImageSurfaceVertically): Flip pixel data of given cairo_surface_t vertically up/down.
39501        Whereas Cairo uses the top-left corner as being 0,0 of the coordinate system,
39502        OpenGL uses the bottom-left corner being 0,0.
39503        So we need to vertically flip resultant images taken by glReadPixels().
39504        * platform/graphics/cairo/CairoUtilities.h:
39505
395062014-04-15  Hyowon Kim  <hw1008.kim@samsung.com>
39507
39508        Make page overlay functionality working on coordinated graphics.
39509        https://bugs.webkit.org/show_bug.cgi?id=131425
39510
39511        Reviewed by Darin Adler.
39512
39513        Page overlay functionality did not work on coordinated graphics since r166975.
39514        This patch removes deprecated code related to the PageOverlay GraphicsLayer management.
39515        and makes CoordinatedLayerTreeHost use PageOverlayController.
39516
39517        * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
39518        (WebCore::CompositingCoordinator::setRootCompositingLayer):
39519        (WebCore::CompositingCoordinator::flushPendingLayerChanges):
39520        * platform/graphics/texmap/coordinated/CompositingCoordinator.h:
39521
395222014-04-10  Roger Fong  <roger_fong@apple.com>
39523
39524        Snapshotted plugins may need to be restarted if style properties are changed after initial load of plugin.
39525        https://bugs.webkit.org/show_bug.cgi?id=131553.
39526        <rdar://problem/15443375>
39527
39528        Reviewed by Timothy Horton.
39529
39530        Test: plugins/snapshotting/set-plugin-size-to-tiny.html
39531
39532        When updating embedded objects during our post layout checks, check for certain style changes
39533        that may result in the plugin needing to be restarted.
39534
39535        * html/HTMLPlugInImageElement.h: 
39536        Add m_plugInDimensionsSpecified field to keep track of whether or not dimensions on the plugin’s renderer have been specified.
39537        * html/HTMLPlugInImageElement.cpp:
39538        (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
39539        Initialize m_plugInDimensionsSpecified.
39540        (WebCore::isSmallerThanTinySizingThreshold):
39541        Refactoring, move check for whether or not plugin is smaller than the tiny plugin size threshold to this method.
39542        (WebCore::HTMLPlugInImageElement::isTopLevelFullPage): 
39543        Refactoring, move check for whether or not plugin is top level full page to this method.
39544        (WebCore::HTMLPlugInImageElement::checkSnapshotStatus): 
39545        Use refactored checks here as well to determine whether or not we need to restart the snapshotted plugin.
39546        (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Use refactored checks.
39547        If plugin dimensions were specified, set m_plugInDimensionsSpecified to true.
39548
395492014-04-15  Andreas Kling  <akling@apple.com>
39550
39551        [iOS WebKit2] Listen for system memory pressure notifications.
39552        <https://webkit.org/b/131653>
39553        <rdar://problem/16208123>
39554
39555        Reviewed by Antti Koivisto.
39556
39557        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
39558        (WebCore::MemoryPressureHandler::install):
39559
39560            Use the right invocation to summon the memory pressure handler.
39561
39562        (WebCore::MemoryPressureHandler::install):
39563        (WebCore::MemoryPressureHandler::uninstall):
39564        (WebCore::MemoryPressureHandler::holdOff):
39565        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
39566
39567            Make stubbed out functions !PLATFORM(COCOA)
39568
395692014-04-14  Morten Stenshorne  <mstensho@opera.com>
39570
39571        [New Multicolumn] Add support for column-span:all
39572        https://bugs.webkit.org/show_bug.cgi?id=129330
39573
39574        Reviewed by Dave Hyatt.
39575
39576        Column spanners are implemented as siblings of RenderMultiColumnSet
39577        objects (i.e. the regions for the column rows). This means that they
39578        are pulled out from the flow thread tree where they would otherwise
39579        live. This causes some complexity, most of which is contained within
39580        the multicol code.
39581
39582        A placeholder is put in the flow thread tree where the spanner's
39583        renderer would otherwise live. This is needed in order make sure that
39584        we interrupt line layout before after the spanner. We also need this
39585        to be able to switch from one multicol set to the next.
39586
39587        Some extra logic is required when dynamically inserting and removing
39588        flow thread descendants now, because we need to figure out if the
39589        renderer added should trigger creation of new multi column sets. If
39590        a spanner is inserted in the middle of a multi column set, we need to
39591        detect this, split the set and put the spanner in the middle.
39592
39593        Wrote a bunch of tests. A few of the tests were copied from existing
39594        (old-impl) tests and put in a separate directory. That directory can
39595        be wiped when we turn on the new multicol implementation by default.
39596
39597        Tests: fast/multicol/newmulticol/adjacent-spanners.html
39598               fast/multicol/newmulticol/block-becomes-spanner.html
39599               fast/multicol/newmulticol/change-spanner-display.html
39600               fast/multicol/newmulticol/change-spanner-parent-display.html
39601               fast/multicol/newmulticol/compare-with-old-impl/anonymous-block-split-crash.html
39602               fast/multicol/newmulticol/compare-with-old-impl/before-child-anonymous-column-block.html
39603               fast/multicol/newmulticol/compare-with-old-impl/clone-before-after-content-crash.html
39604               fast/multicol/newmulticol/compare-with-old-impl/clone-block-children-inline-mismatch-crash.html
39605               fast/multicol/newmulticol/compare-with-old-impl/clone-flexbox.html
39606               fast/multicol/newmulticol/compare-with-old-impl/clone-summary.html
39607               fast/multicol/newmulticol/compare-with-old-impl/column-span-inside-multicol-webkit-box.html
39608               fast/multicol/newmulticol/compare-with-old-impl/continuation-crash.html
39609               fast/multicol/newmulticol/compare-with-old-impl/double-merge-anonymous-block-crash.html
39610               fast/multicol/newmulticol/compare-with-old-impl/empty-anonymous-block-split-crash.html
39611               fast/multicol/newmulticol/compare-with-old-impl/float-not-removed-crash.html
39612               fast/multicol/newmulticol/compare-with-old-impl/list-multi-column-crash.html
39613               fast/multicol/newmulticol/compare-with-old-impl/positioned-child-not-removed-crash.html
39614               fast/multicol/newmulticol/compare-with-old-impl/positioned-objects-not-removed-crash.html
39615               fast/multicol/newmulticol/compare-with-old-impl/recursive-split-flow-crash.html
39616               fast/multicol/newmulticol/compare-with-old-impl/removal-of-multicol-span-crash.html
39617               fast/multicol/newmulticol/compare-with-old-impl/remove-child-split-flow-crash.html
39618               fast/multicol/newmulticol/compare-with-old-impl/runin-continuation-crash.html
39619               fast/multicol/newmulticol/compare-with-old-impl/span-as-immediate-child-complex-splitting.html
39620               fast/multicol/newmulticol/compare-with-old-impl/span-as-nested-inline-block-child.html
39621               fast/multicol/newmulticol/compare-with-old-impl/split-flow-anonymous-wrapper-crash.html
39622               fast/multicol/newmulticol/compare-with-old-impl/split-inline-wrong-post-block-crash.html
39623               fast/multicol/newmulticol/compare-with-old-impl/table-multi-column-crash.html
39624               fast/multicol/newmulticol/compare-with-old-impl/textbox-not-removed-crash.html
39625               fast/multicol/newmulticol/compare-with-old-impl/update-after-content-before-child-crash.html
39626               fast/multicol/newmulticol/insert-row-content1.html
39627               fast/multicol/newmulticol/insert-row-content2.html
39628               fast/multicol/newmulticol/insert-row-content3.html
39629               fast/multicol/newmulticol/insert-row-content4.html
39630               fast/multicol/newmulticol/insert-row-content5.html
39631               fast/multicol/newmulticol/insert-row-content6.html
39632               fast/multicol/newmulticol/insert-row-content7.html
39633               fast/multicol/newmulticol/insert-row-content8.html
39634               fast/multicol/newmulticol/insert-row-content9.html
39635               fast/multicol/newmulticol/insert-spanner-child1.html
39636               fast/multicol/newmulticol/insert-spanner-child2.html
39637               fast/multicol/newmulticol/insert-spanner-child3.html
39638               fast/multicol/newmulticol/insert-spanner1.html
39639               fast/multicol/newmulticol/insert-spanner2.html
39640               fast/multicol/newmulticol/insert-spanner3.html
39641               fast/multicol/newmulticol/insert-spanner4.html
39642               fast/multicol/newmulticol/insert-spanner5.html
39643               fast/multicol/newmulticol/insert-spanner6.html
39644               fast/multicol/newmulticol/insert-spanner7.html
39645               fast/multicol/newmulticol/insert-spanner8.html
39646               fast/multicol/newmulticol/multicol-with-spanner-becomes-regular-block.html
39647               fast/multicol/newmulticol/remove-row-content1.html
39648               fast/multicol/newmulticol/remove-row-content2.html
39649               fast/multicol/newmulticol/remove-row-content3.html
39650               fast/multicol/newmulticol/remove-row-content4.html
39651               fast/multicol/newmulticol/remove-row-content5.html
39652               fast/multicol/newmulticol/remove-row-content6.html
39653               fast/multicol/newmulticol/remove-row-content7.html
39654               fast/multicol/newmulticol/remove-row-content8.html
39655               fast/multicol/newmulticol/remove-row-content9.html
39656               fast/multicol/newmulticol/remove-spanner1.html
39657               fast/multicol/newmulticol/remove-spanner2.html
39658               fast/multicol/newmulticol/remove-spanner3.html
39659               fast/multicol/newmulticol/remove-spanner4.html
39660               fast/multicol/newmulticol/remove-spanner5.html
39661               fast/multicol/newmulticol/remove-spanner6.html
39662               fast/multicol/newmulticol/sole-spanner.html
39663               fast/multicol/newmulticol/span-between-text.html
39664               fast/multicol/newmulticol/spanner-becomes-regular-block.html
39665               fast/multicol/newmulticol/spanner-first.html
39666               fast/multicol/newmulticol/spanner-img.html
39667               fast/multicol/newmulticol/spanner-inline-block.html
39668               fast/multicol/newmulticol/spanner-last.html
39669               fast/multicol/newmulticol/spanner-nested-dynamic.html
39670               fast/multicol/newmulticol/spanner-nested.html
39671               fast/multicol/newmulticol/spanner-pseudo-after1.html
39672               fast/multicol/newmulticol/spanner-pseudo-after2.html
39673               fast/multicol/newmulticol/spanner-pseudo-after3.html
39674               fast/multicol/newmulticol/spanner-pseudo-after4.html
39675               fast/multicol/newmulticol/spanner-pseudo-before-after1.html
39676               fast/multicol/newmulticol/spanner-pseudo-before-after2.html
39677               fast/multicol/newmulticol/spanner-pseudo-before-after3.html
39678               fast/multicol/newmulticol/spanner-pseudo-before-after4.html
39679               fast/multicol/newmulticol/spanner-pseudo-before1.html
39680               fast/multicol/newmulticol/spanner-pseudo-before2.html
39681               fast/multicol/newmulticol/spanner-pseudo-before3.html
39682               fast/multicol/newmulticol/spanner-pseudo-before4.html
39683               fast/multicol/newmulticol/spanner-table.html
39684               fast/multicol/newmulticol/spanner-with-margin.html
39685               fast/multicol/newmulticol/spanner1.html
39686               fast/multicol/newmulticol/spanner2.html
39687               fast/multicol/newmulticol/spanner3.html
39688               fast/multicol/newmulticol/spanner4.html
39689               fast/multicol/newmulticol/spanner5.html
39690               fast/multicol/newmulticol/spanner6.html
39691               fast/multicol/newmulticol/spanner7.html
39692               fast/multicol/newmulticol/spanner8.html
39693               fast/multicol/newmulticol/spanner9.html
39694               fast/multicol/newmulticol/trailing-margin-with-spanner.html
39695               fast/multicol/newmulticol/trailing-margin-with-spanner2.html
39696
39697        * CMakeLists.txt:
39698        * WebCore.vcxproj/WebCore.vcxproj:
39699        * WebCore.vcxproj/WebCore.vcxproj.filters:
39700        * rendering/RenderBlock.cpp:
39701        (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
39702        Disable the old anonymous multicol container and spanner anonymous
39703        block generation machinery when the new multicol implementation is
39704        enabled.
39705        * rendering/RenderBlockFlow.cpp:
39706        (WebCore::RenderBlockFlow::createMultiColumnFlowThread):
39707        (WebCore::RenderBlockFlow::destroyMultiColumnFlowThread):
39708        (WebCore::RenderBlockFlow::layoutBlockChild): Need to notify the
39709        flow thread when a descendant's final position is known. Spanner
39710        placeholders need to know where to terminate the column set that
39711        it follows.
39712        (WebCore::RenderBlockFlow::styleDidChange): Remove old code that
39713        isn't needed anymore. The renderers in question (flow thread and
39714        column sets) set display:block on themselves already. This code
39715        caused problems for spanners, which got all their style wiped.
39716        (WebCore::RenderBlockFlow::setMultiColumnFlowThread): If setting
39717        the flow thread to nullptr, there's no need to create the "rare
39718        data" structure.
39719        (WebCore::RenderBlockFlow::relayoutForPagination):
39720        (WebCore::RenderBlockFlow::layoutSpecialExcludedChild):
39721        (WebCore::RenderBlockFlow::addChild): beforeChild is retrieved via
39722        the DOM. If it is a spanner, we need to locate the placeholder
39723        here, because that's the correct location to insert siblings,
39724        DOM-wise.
39725        (WebCore::RenderBlockFlow::removeChild): The multicol flow thread
39726        needs to know when children disappear.
39727        (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
39728        Don't modify the height back and forth when calculating the
39729        multicol container's final height, as that messes up balancing.
39730        (WebCore::RenderBlockFlow::insertedIntoTree): Deleted.
39731        (WebCore::RenderBlockFlow::willBeDestroyed): Deleted.
39732        (WebCore::RenderBlockFlow::styleWillChange): Deleted.
39733        (WebCore::RenderBlockFlow::lineAtIndex): Deleted.
39734        * rendering/RenderBlockFlow.h:
39735        * rendering/RenderElement.cpp:
39736        (WebCore::RenderElement::insertedIntoTree): Set up an element's
39737        layer before notifying the flow thread. The multicol flow thread
39738        may decide to move the element (if it's a spanner), which may
39739        involve re-insertion of layers.  Calling
39740        RenderObject::insertedIntoTree() last instead of first also better
39741        matches the order we used to have prior to the introduction of
39742        RenderElement, FWIW.
39743        * rendering/RenderFlowThread.cpp:
39744        (WebCore::RenderFlowThread::layout):
39745        (WebCore::RenderFlowThread::removeRegionFromThread): Deleted.
39746        (WebCore::RenderFlowThread::invalidateRegions): Deleted.
39747        * rendering/RenderFlowThread.h:
39748        * rendering/RenderMultiColumnFlowThread.cpp:
39749        (WebCore::RenderMultiColumnFlowThread::RenderMultiColumnFlowThread):
39750        (WebCore::RenderMultiColumnFlowThread::removeFlowChildInfo): When
39751        a flow thread descendant is inserted, the multicol flow thread
39752        needs to be notified.
39753        (WebCore::RenderMultiColumnFlowThread::firstMultiColumnSet):
39754        (WebCore::RenderMultiColumnFlowThread::lastMultiColumnSet):
39755        (WebCore::RenderMultiColumnFlowThread::firstColumnSetOrSpanner):
39756        (WebCore::RenderMultiColumnFlowThread::nextColumnSetOrSpannerSiblingOf):
39757        (WebCore::RenderMultiColumnFlowThread::previousColumnSetOrSpannerSiblingOf):
39758        (WebCore::RenderMultiColumnFlowThread::layout):
39759        (WebCore::RenderMultiColumnFlowThread::findSetRendering):
39760        (WebCore::RenderMultiColumnFlowThread::populate):
39761        (WebCore::RenderMultiColumnFlowThread::evacuateAndDestroy):
39762        (WebCore::RenderMultiColumnFlowThread::addRegionToThread):
39763        (WebCore::RenderMultiColumnFlowThread::willBeRemovedFromTree):
39764        Need to detach column sets here, since they have pointers to their
39765        flow thread.
39766        (WebCore::RenderMultiColumnFlowThread::resolveMovedChild):
39767        (WebCore::isValidColumnSpanner):
39768        (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantInserted):
39769        (WebCore::RenderMultiColumnFlowThread::flowThreadRelativeWillBeRemoved):
39770        (WebCore::RenderMultiColumnFlowThread::flowThreadDescendantBoxLaidOut):
39771        (WebCore::RenderMultiColumnFlowThread::autoGenerateRegionsToBlockOffset):
39772        Nothing to be done here for the time being. Column sets are now
39773        created during box creation. We are going to need to add some code
39774        here again once multicol properly supports nested fragmentation
39775        contexts (and you get adjacent column rows because of that).
39776        (WebCore::RenderMultiColumnFlowThread::regionAtBlockOffset):
39777        During layout, don't trust the region interval tree, as that one
39778        depends on the resulting layout.
39779        (WebCore::RenderMultiColumnFlowThread::setRegionRangeForBox): With
39780        a convenience method to get the last column set, and column sets
39781        now being created during normal box creation, this young method
39782        needs an overhaul.
39783        (WebCore::RenderMultiColumnFlowThread::setRegionRangeForBox):
39784        (WebCore::RenderMultiColumnFlowThread::isPageLogicalHeightKnown):
39785        * rendering/RenderMultiColumnFlowThread.h:
39786        * rendering/RenderMultiColumnSet.cpp:
39787        (WebCore::RenderMultiColumnSet::nextSiblingMultiColumnSet):
39788        (WebCore::RenderMultiColumnSet::previousSiblingMultiColumnSet):
39789        (WebCore::RenderMultiColumnSet::firstRendererInFlowThread):
39790        (WebCore::RenderMultiColumnSet::lastRendererInFlowThread):
39791        (WebCore::precedesRenderer):
39792        (WebCore::RenderMultiColumnSet::containsRendererInFlowThread):
39793        (WebCore::RenderMultiColumnSet::setLogicalTopInFlowThread):
39794        (WebCore::RenderMultiColumnSet::setLogicalBottomInFlowThread):
39795        (WebCore::RenderMultiColumnSet::pageLogicalTopForOffset):
39796        (WebCore::RenderMultiColumnSet::distributeImplicitBreaks):
39797        (WebCore::RenderMultiColumnSet::calculateBalancedHeight):
39798        (WebCore::RenderMultiColumnSet::addForcedBreak):
39799        (WebCore::RenderMultiColumnSet::recalculateColumnHeight):
39800        Previously only needed if columns were to be balanced, now it's
39801        also needed when not balancing.
39802        (WebCore::RenderMultiColumnSet::recordSpaceShortage): Some layout
39803        elements actually have 0 height. Skip them, since they're not
39804        taking us anywhere.
39805        (WebCore::RenderMultiColumnSet::updateLogicalWidth):
39806        (WebCore::RenderMultiColumnSet::requiresBalancing): Column sets
39807        now have individual balancing needs. If they precede a spanner,
39808        they must always be balanced. For the last column set, see if
39809        height is unspecified or column-fill is 'balance' (like before).
39810        (WebCore::RenderMultiColumnSet::prepareForLayout):
39811        (WebCore::RenderMultiColumnSet::beginFlow):
39812        (WebCore::RenderMultiColumnSet::endFlow):
39813        (WebCore::RenderMultiColumnSet::layout):
39814        (WebCore::RenderMultiColumnSet::calculateMaxColumnHeight):
39815        (WebCore::RenderMultiColumnSet::columnRectAt):
39816        (WebCore::RenderMultiColumnSet::flowThreadPortionOverflowRect):
39817        (WebCore::RenderMultiColumnSet::paintColumnRules):
39818        (WebCore::RenderMultiColumnSet::initialBlockOffsetForPainting):
39819        (WebCore::RenderMultiColumnSet::collectLayerFragments):
39820        (WebCore::RenderMultiColumnSet::columnTranslationForOffset):
39821        (WebCore::RenderMultiColumnSet::setAndConstrainColumnHeight): Deleted.
39822        (WebCore::RenderMultiColumnSet::findRunWithTallestColumns): Deleted.
39823        (WebCore::RenderMultiColumnSet::clearForcedBreaks): Deleted.
39824        (WebCore::RenderMultiColumnSet::repaintFlowThreadContent): Deleted.
39825        * rendering/RenderMultiColumnSet.h:
39826        * rendering/RenderMultiColumnSpannerPlaceholder.cpp: Added.
39827        (WebCore::RenderMultiColumnSpannerPlaceholder::createAnonymous):
39828        (WebCore::RenderMultiColumnSpannerPlaceholder::RenderMultiColumnSpannerPlaceholder):
39829        (WebCore::RenderMultiColumnSpannerPlaceholder::renderName):
39830        * rendering/RenderMultiColumnSpannerPlaceholder.h: Added.
39831        * rendering/RenderObject.cpp:
39832        (WebCore::RenderObject::insertedIntoTree): Need to notify the
39833        multicol flow thread when descendants are inserted. That may
39834        trigger insertion of column sets, or, in the case of spanners,
39835        they need to be moved out from the flow thread.
39836        * rendering/RenderObject.h:
39837        (WebCore::RenderObject::isRenderMultiColumnSpannerPlaceholder):
39838        (WebCore::RenderObject::isAnonymousBlock): Exclude column sets
39839        here, so that they don't get involved in anonymous block merging
39840        and other kinds of fun.
39841        * rendering/RenderRegion.h:
39842        * rendering/RenderRegionSet.h:
39843
398442014-04-15  Simon Fraser  <simon.fraser@apple.com>
39845
39846        LayerTreeAsTextBehavior should be in the WebCore namespace
39847        https://bugs.webkit.org/show_bug.cgi?id=131683
39848
39849        Reviewed by Andrei Bucur.
39850
39851        Move LayerTreeAsTextBehavior and the bit flags into the WebCore namespace.
39852
39853        * platform/graphics/GraphicsLayer.cpp:
39854        (showGraphicsLayerTree):
39855        * platform/graphics/GraphicsLayer.h:
39856
398572014-04-15  Benjamin Poulain  <bpoulain@apple.com>
39858
39859        ViewportConfiguration handles userZoom incorrectly
39860        https://bugs.webkit.org/show_bug.cgi?id=131657
39861
39862        Reviewed by Darin Adler.
39863
39864        * page/ViewportConfiguration.cpp:
39865        (WebCore::viewportArgumentUserZoomIsSet):
39866        (WebCore::ViewportConfiguration::updateConfiguration):
39867        The other viewport values must be strictly positive, userZoom is always either zero, one or minus one.
39868        As a result, the value zero was never set.
39869
398702014-04-15  Simon Fraser  <simon.fraser@apple.com>
39871
39872        [iOS WK2] Pages often blank on first load if page loaded by typing the URL
39873        https://bugs.webkit.org/show_bug.cgi?id=131665
39874
39875        Reviewed by Tim Horton.
39876
39877        The document overlay-related code in RemoteLayerTreeDrawingArea::setRootCompositingLayer()
39878        was triggering a compositing layer flush when called with a null rootLayer, which happens
39879        for pages going into the page cache. This would trigger a layer flush that would clobber
39880        the root layer for the visible page, resulting in missing content.
39881        
39882        Also, rebuildCompositingLayerTree() is called recursively and the m_documentOverlayRootLayer
39883        was being added to (and then removed from) every single compositing layers.
39884        
39885        Fix both these by changing to a pull model, where RenderLayerCompositor requests
39886        the overlay layer via ChromeClient, and gets it at the end of every flush,
39887        adding to the children of the root layer.
39888
39889        * WebCore.exp.in:
39890        * page/ChromeClient.h:
39891        (WebCore::ChromeClient::documentOverlayLayerForFrame):
39892        * rendering/RenderLayerCompositor.cpp:
39893        (WebCore::RenderLayerCompositor::RenderLayerCompositor):
39894        (WebCore::RenderLayerCompositor::flushPendingLayerChanges): Put visibleRect
39895        into a variable for ease of debugging.
39896        (WebCore::RenderLayerCompositor::updateCompositingLayers): Asser
39897        that we're not in the page cache (this would have caught the bug).
39898        (WebCore::RenderLayerCompositor::appendOverlayLayers):
39899        (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
39900        (WebCore::RenderLayerCompositor::setDocumentOverlayRootLayer): Deleted.
39901        * rendering/RenderLayerCompositor.h:
39902
399032014-04-15  Commit Queue  <commit-queue@webkit.org>
39904
39905        Unreviewed, rolling out r167199 and r167251.
39906        https://bugs.webkit.org/show_bug.cgi?id=131678
39907
39908        Caused a DYEBench regression and does not seem to improve perf
39909        on relevant websites (Requested by rniwa on #webkit).
39910
39911        Reverted changesets:
39912
39913        "Rewrite Function.bind as a builtin"
39914        https://bugs.webkit.org/show_bug.cgi?id=131083
39915        http://trac.webkit.org/changeset/167199
39916
39917        "Update test result"
39918        http://trac.webkit.org/changeset/167251
39919
399202014-04-15  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
39921
39922        Remove unnecessary null checking in NavigatorContentUtils
39923        https://bugs.webkit.org/show_bug.cgi?id=131652
39924
39925        Reviewed by Darin Adler.
39926
39927        Some functions have checked if document is null. However, document is always not
39928        null when frame is existed.
39929
39930        No new tests, no behavior changes.
39931
39932        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
39933        (WebCore::NavigatorContentUtils::registerProtocolHandler):
39934        (WebCore::NavigatorContentUtils::isProtocolHandlerRegistered):
39935        (WebCore::NavigatorContentUtils::unregisterProtocolHandler):
39936
399372014-04-15  Commit Queue  <commit-queue@webkit.org>
39938
39939        Unreviewed, rolling out r167298.
39940        https://bugs.webkit.org/show_bug.cgi?id=131670
39941
39942        Broke CSS filters (17 test crashes) (Requested by ap on
39943        #webkit).
39944
39945        Reverted changeset:
39946
39947        "[iOS WK2] Pages often blank on first load if page loaded by
39948        typing the URL"
39949        https://bugs.webkit.org/show_bug.cgi?id=131665
39950        http://trac.webkit.org/changeset/167298
39951
399522014-04-14  Pratik Solanki  <psolanki@apple.com>
39953
39954        Unreviewed. Attempt to fix Windows build after r167277.
39955
39956        * page/FrameView.cpp:
39957        (WebCore::FrameView::willPaintContents):
39958
399592014-04-14  Commit Queue  <commit-queue@webkit.org>
39960
39961        Unreviewed, rolling out r167261.
39962        https://bugs.webkit.org/show_bug.cgi?id=131667
39963
39964        broke many navigation tests (Requested by ap on #webkit).
39965
39966        Reverted changeset:
39967
39968        "Web Replay: memoize fallback time values for
39969        document.lastModified"
39970        https://bugs.webkit.org/show_bug.cgi?id=131318
39971        http://trac.webkit.org/changeset/167261
39972
399732014-04-14  Simon Fraser  <simon.fraser@apple.com>
39974
39975        [iOS WK2] Pages often blank on first load if page loaded by typing the URL
39976        https://bugs.webkit.org/show_bug.cgi?id=131665
39977
39978        Reviewed by Tim Horton.
39979
39980        The document overlay-related code in RemoteLayerTreeDrawingArea::setRootCompositingLayer()
39981        was triggering a compositing layer flush when called with a null rootLayer, which happens
39982        for pages going into the page cache. This would trigger a layer flush that would clobber
39983        the root layer for the visible page, resulting in missing content.
39984        
39985        Also, rebuildCompositingLayerTree() is called recursively and the m_documentOverlayRootLayer
39986        was being added to (and then removed from) every single compositing layers.
39987        
39988        Fix both these by changing to a pull model, where RenderLayerCompositor requests
39989        the overlay layer via ChromeClient, and gets it at the end of every flush,
39990        adding to the children of the root layer.
39991
39992        * WebCore.exp.in:
39993        * page/ChromeClient.h:
39994        (WebCore::ChromeClient::documentOverlayLayerForFrame):
39995        * rendering/RenderLayerCompositor.cpp:
39996        (WebCore::RenderLayerCompositor::RenderLayerCompositor):
39997        (WebCore::RenderLayerCompositor::flushPendingLayerChanges): Put visibleRect
39998        into a variable for ease of debugging.
39999        (WebCore::RenderLayerCompositor::updateCompositingLayers): Asser
40000        that we're not in the page cache (this would have caught the bug).
40001        (WebCore::RenderLayerCompositor::appendOverlayLayers):
40002        (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
40003        (WebCore::RenderLayerCompositor::setDocumentOverlayRootLayer): Deleted.
40004        * rendering/RenderLayerCompositor.h:
40005
400062014-04-14  Jon Honeycutt  <jhoneycutt@apple.com>
40007
40008        Assertion failure under FEImage::determineAbsolutePaintRect()
40009
40010        <https://bugs.webkit.org/show_bug.cgi?id=131660>
40011        <rdar://problem/15669294>
40012
40013        This patch merges Chromium r149536 (see
40014        <https://chromiumcodereview.appspot.com/14701012>), which moves
40015        m_absoluteTransform out of SVGFilter and into the base Filter class, so
40016        that it isn't necessary to cast a Filter to SVGFilter to get the
40017        absolute transform.
40018
40019        Reviewed by Geoffrey Garen.
40020
40021        Test: svg/filters/feImage-filter-assertion.html
40022
40023        * platform/graphics/filters/Filter.h:
40024        (WebCore::Filter::Filter):
40025        Changed to take the absolute transform.
40026        (WebCore::Filter::absoluteTransform):
40027        Moved from SVGFilter.
40028        (WebCore::Filter::mapAbsolutePointToLocalPoint):
40029        Ditto.
40030
40031        * rendering/FilterEffectRenderer.cpp:
40032        (WebCore::FilterEffectRenderer::FilterEffectRenderer):
40033        Pass a default AffineTransform() to the Filter base class.
40034
40035        * svg/graphics/filters/SVGFEImage.cpp:
40036        (WebCore::FEImage::determineAbsolutePaintRect):
40037        Use the Filter without casting it to SVGFilter.
40038        (WebCore::FEImage::platformApplySoftware):
40039        Ditto.
40040
40041        * svg/graphics/filters/SVGFilter.cpp:
40042        (WebCore::SVGFilter::SVGFilter):
40043        Pass the transform to the base class, and remove initialization of a
40044        removed member var.
40045
40046        * svg/graphics/filters/SVGFilter.h:
40047        Member var moved to Filter.h.
40048
400492014-04-14  Darin Adler  <darin@apple.com>
40050
40051        REGRESSION (r158617): Find on Page can get stuck in a loop when the search string occurs in an <input> in a <fieldset>
40052        https://bugs.webkit.org/show_bug.cgi?id=126322
40053
40054        Reviewed by Ryosuke Niwa.
40055
40056        One additional tweak to the fix for the bug above.
40057        Fixes crash in editing/editability/ignored-content.html test.
40058
40059        * html/HTMLObjectElement.cpp:
40060        (WebCore::HTMLObjectElement::canContainRangeEndPoint): Call through to
40061        HTMLElement::canContainRangeEndPoint, bypassing HTMLPlugInElement override
40062        that always returns false. Without this change, this function was always
40063        returning false.
40064
400652014-04-14  Simon Fraser  <simon.fraser@apple.com>
40066
40067        Crash in TileController::tileRevalidationTimerFired
40068        https://bugs.webkit.org/show_bug.cgi?id=131656
40069        <rdar://problem/16583166>
40070
40071        Reviewed by Sam Weinig.
40072
40073        It's possible for the TileController revalidation timer to fire after
40074        the GraphicsLayer has been destroyed, so the PlatformCALayer no longer
40075        has an owningGraphicsLayer.
40076        
40077        Bail from the timer callback if owningGraphicsLayer() is null.
40078        
40079        Also some drive-by 0 -> nullptr changes.
40080
40081        * platform/graphics/ca/GraphicsLayerCA.cpp:
40082        (WebCore::GraphicsLayerCA::willBeDestroyed):
40083        * platform/graphics/ca/PlatformCALayer.cpp:
40084        (WebCore::PlatformCALayer::~PlatformCALayer):
40085        * platform/graphics/ca/mac/TileController.mm:
40086        (WebCore::TileController::tileRevalidationTimerFired):
40087
400882014-04-14  Bem Jones-Bey  <bjonesbe@adobe.com>
40089
40090        [CSS Shapes] Remove some leftover shape-inside code
40091        https://bugs.webkit.org/show_bug.cgi?id=131641
40092
40093        Reviewed by Dean Jackson.
40094
40095        I discovered that some code had been leftover from the shape-inside
40096        removal. This removes that leftover code.
40097
40098        No new tests, no behavior change.
40099
40100        * platform/text/BidiResolver.h:
40101        * rendering/BidiRun.cpp:
40102        (WebCore::BidiRun::BidiRun):
40103        * rendering/RenderBlockFlow.h:
40104        * rendering/RenderBlockLineLayout.cpp:
40105        (WebCore::RenderBlockFlow::createLineBoxes):
40106        (WebCore::RenderBlockFlow::constructLine):
40107        (WebCore::computeExpansionForJustifiedText):
40108        (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForSegment):
40109
401102014-04-14  Jer Noble  <jer.noble@apple.com>
40111
40112        [MSE][Mac] video.currentTime is sometimes negative.
40113        https://bugs.webkit.org/show_bug.cgi?id=131644
40114
40115        Reviewed by Eric Carlson.
40116
40117        AVSampleBufferRenderSynchronizer will occasionally return slightly negative values
40118        when beginning playback. Clamp the return value to 0.
40119
40120        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
40121        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::currentTimeDouble):
40122
401232014-04-14  Bem Jones-Bey  <bjonesbe@adobe.com>
40124
40125        [CSSExclusions] Remove FIXME referencing closed bug
40126        https://bugs.webkit.org/show_bug.cgi?id=131645
40127
40128        Reviewed by Dean Jackson.
40129
40130        This is silly, but the comment is really confusing as it's entirely
40131        wrong now.
40132
40133        No new tests, no behavior change.
40134
40135        * rendering/style/RenderStyle.cpp:
40136        (WebCore::RenderStyle::changeRequiresRepaint):
40137
401382014-04-14  Andreas Kling  <akling@apple.com>
40139
40140        Build fixage.
40141
40142        * page/FrameView.cpp:
40143
401442014-04-14  Jon Honeycutt  <jhoneycutt@apple.com>
40145
40146        Assertion failure !node || node->isElementNode() in
40147        WebCore::RenderBlock::inlineElementContinuation
40148  
40149        https://bugs.webkit.org/show_bug.cgi?id=108829
40150        <rdar://problem/13666405>
40151  
40152        I can't reproduce this assertion failure, but there seems to be an
40153        invalid assumption in RenderBlock::inlineElementContinuation() that
40154        anything with the "isInline()" bit set is a RenderInline.
40155        
40156        No new test because the test case in the bug does not repro for me.
40157
40158        Reviewed by Brent Fulgham.
40159
40160        * rendering/RenderBlock.cpp:
40161        (WebCore::RenderBlock::inlineElementContinuation):
40162        Dave Hyatt says that this function should only return RenderInline
40163        objects (not non-RenderInline inline objects), so update the checks
40164        from isInline() to isRenderInline() before casting with
40165        toRenderInline().
40166
40167        * rendering/RenderInline.cpp:
40168        (WebCore::RenderInline::inlineElementContinuation):
40169        Ditto.
40170
401712014-04-14  Andreas Kling  <akling@apple.com>
40172
40173        Do more things under memory pressure on non-iOS platforms.
40174        <https://webkit.org/b/131625>
40175
40176        Reviewed by Antti Koivisto.
40177
40178        Rename hasReceivedMemoryPressure() to isUnderMemoryPressure() and
40179        make it use std::atomic<bool> instead of OSAtomic primitives.
40180
40181        Unmask most of the PLATFORM(IOS) blocks so all platforms can take
40182        advantage of optimizations done while under pressure. Note that
40183        isUnderMemoryPressure() will still always return false on platforms
40184        other than iOS/WK1, but this will change soon.
40185
40186        * history/PageCache.cpp:
40187        (WebCore::PageCache::canCache):
40188        * loader/FrameLoader.cpp:
40189        (WebCore::FrameLoader::commitProvisionalLoad):
40190        * page/FrameView.cpp:
40191        (WebCore::FrameView::willPaintContents):
40192        (WebCore::FrameView::didPaintContents):
40193        * platform/MemoryPressureHandler.cpp:
40194        (WebCore::MemoryPressureHandler::MemoryPressureHandler):
40195        * platform/MemoryPressureHandler.h:
40196        (WebCore::MemoryPressureHandler::isUnderMemoryPressure):
40197        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
40198        (WebCore::MemoryPressureHandler::setReceivedMemoryPressure):
40199        (WebCore::MemoryPressureHandler::clearMemoryPressure):
40200        (WebCore::MemoryPressureHandler::respondToMemoryPressureIfNeeded):
40201        (WebCore::MemoryPressureHandler::hasReceivedMemoryPressure): Deleted.
40202        * platform/graphics/FontCache.cpp:
40203        (WebCore::FontCache::purgeInactiveFontDataIfNeeded):
40204        * platform/ios/LegacyTileCache.mm:
40205        (WebCore::LegacyTileCache::createTilesInActiveGrid):
40206        * platform/ios/LegacyTileGrid.mm:
40207        (WebCore::LegacyTileGrid::shouldUseMinimalTileCoverage):
40208        * platform/ios/LegacyTileLayerPool.mm:
40209        (WebCore::LegacyTileLayerPool::addLayer):
40210        * platform/ios/TileControllerMemoryHandlerIOS.cpp:
40211        (WebCore::TileControllerMemoryHandler::tileControllerGainedUnparentedTiles):
40212
402132014-04-14  Beth Dakin  <bdakin@apple.com>
40214
40215        RenderLayerCompositor's m_layerForOverhangAreas should be offset by the 
40216        topContentInset
40217        https://bugs.webkit.org/show_bug.cgi?id=131632
40218        -and corresponding-
40219        <rdar://problem/16609602>
40220
40221        Reviewed by Tim Horton.
40222
40223        Offset m_layerForOverhangAreas by the topContentInset. 
40224        * rendering/RenderLayerCompositor.cpp:
40225        (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
40226
402272014-04-14  Alexey Proskuryakov  <ap@apple.com>
40228
40229        Eliminate CachedFrame::m_mousePressNode
40230        https://bugs.webkit.org/show_bug.cgi?id=131626
40231
40232        Reviewed by Brady Eidson.
40233
40234        I couldn't find any observable effect of this change.
40235
40236        * history/CachedFrame.cpp:
40237        (WebCore::CachedFrameBase::CachedFrameBase):
40238        (WebCore::CachedFrameBase::restore):
40239        (WebCore::CachedFrame::clear):
40240        * history/CachedFrame.h:
40241        (WebCore::CachedFrame::documentLoader):
40242        (WebCore::CachedFrame::mousePressNode): Deleted.
40243        Eliminated m_mousePressNode, accessor, and code that reached out to EventHandler.
40244
40245        * page/EventHandler.cpp:
40246        (WebCore::EventHandler::mousePressNode): Deleted.
40247        (WebCore::EventHandler::setMousePressNode): Deleted.
40248        * page/EventHandler.h:
40249        (WebCore::EventHandler::setMousePressed): Deleted. This function was already unused.
40250
402512014-04-14  Simon Fraser  <simon.fraser@apple.com>
40252
40253        Run filter animations in the UI process with UI-side compositing
40254        https://bugs.webkit.org/show_bug.cgi?id=131199
40255        <rdar://problem/16479487>
40256
40257        Reviewed by Sam Weinig.
40258
40259        Add FilterOperation::clone() which is used during decoding.
40260        Export some things.
40261
40262        * WebCore.exp.in:
40263        * platform/graphics/filters/FilterOperation.h:
40264
402652014-04-14  Jer Noble  <jer.noble@apple.com>
40266
40267        Use after free in WebCore::CachedResourceHandleBase::~CachedResourceHandleBase / WebCore::removeDetachedChildrenInContainer
40268        https://bugs.webkit.org/show_bug.cgi?id=131169
40269
40270        Reviewed by Eric Carlson.
40271
40272        Invalidate the WebCoreAVFResourceLoader owned by MediaPlayerPrivateAVFoundationObjC
40273        in its destructor, to prevent a private function being called in response to the
40274        WebCoreAVFResourceLoader being stopped.
40275
40276        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
40277        (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC):
40278        * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.h:
40279        * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.mm:
40280        (WebCore::WebCoreAVFResourceLoader::invalidate):
40281
402822014-04-14  Simon Fraser  <simon.fraser@apple.com>
40283
40284        [WK2 iOS] Scrolling to anchor links is broken
40285        https://bugs.webkit.org/show_bug.cgi?id=131618
40286        <rdar://problem/16599144>
40287
40288        Reviewed by Tim Horton.
40289
40290        Have ScrollingTreeScrollingNode pass RequestedScrollPosition updates
40291        to the scrolling tree, so that the scrolling tree can have custom behavior
40292        for them if necessary.
40293
40294        * page/scrolling/ScrollingTree.h:
40295        (WebCore::ScrollingTree::scrollingTreeNodeRequestsScroll):
40296        * page/scrolling/ScrollingTreeScrollingNode.cpp:
40297        (WebCore::ScrollingTreeScrollingNode::updateAfterChildren):
40298        * page/scrolling/ScrollingTreeScrollingNode.h:
40299
403002014-04-14  Brian J. Burg  <burg@cs.washington.edu>
40301
40302        Web Replay: memoize fallback time values for document.lastModified
40303        https://bugs.webkit.org/show_bug.cgi?id=131318
40304
40305        Reviewed by Joseph Pecoraro.
40306
40307        If a document's Last-Modified header can't be found or used, then 
40308        document.lastModified is derived from the current system time or
40309        from filesystem data, which is obviously nondeterministic.
40310
40311        It's better to handle this inside Document::lastModified rather than using
40312        MemoizedDOMResult, because only the fallback case is nondeterministic.
40313
40314        Test: http/tests/inspector/replay/document-last-modified-fallback-value.html
40315
40316        * dom/Document.cpp:
40317        (WebCore::Document::lastModified): Save or reuse memoized fallback value.
40318        * replay/WebInputs.json: Add input DocumentLastModifiedDate.
40319
403202014-04-12  Antti Koivisto  <antti@apple.com>
40321
40322        Keep secondary tile grid for zoomed-out scale
40323        https://bugs.webkit.org/show_bug.cgi?id=131586
40324
40325        Reviewed by Darin Adler.
40326
40327        * platform/graphics/ca/GraphicsLayerCA.cpp:
40328        (WebCore::GraphicsLayerCA::updateContentsScale):
40329        
40330            Don't repaint tiled backing with setNeedsDisplay, it invalidates itself correctly in setContentsScale.
40331            Update custom child layers when tiled backing scale changes.
40332
40333        * platform/graphics/ca/mac/TileController.h:
40334        * platform/graphics/ca/mac/TileController.mm:
40335        (WebCore::TileController::TileController):
40336        (WebCore::TileController::setNeedsDisplay):
40337        
40338            Drop the whole zoomed-out grid on full repaint.
40339
40340        (WebCore::TileController::setNeedsDisplayInRect):
40341            
40342            Drop changed zoomed-out tiles. A more sophisticated strategy is possible.
40343
40344        (WebCore::TileController::setContentsScale):
40345        
40346            Swap the zoomed-out grid in and out as needed.
40347            Repaint the active grid after scale change so the client does not have to.
40348
40349        (WebCore::TileController::contentsScale):
40350        
40351            Get the content scale from the tile grid so it is not kept in two places.
40352
40353        (WebCore::TileController::zoomedOutContentsScale):
40354        (WebCore::TileController::setZoomedOutContentsScale):
40355        
40356            Drop the zoomed-out grid if it no longer matches the zoomed-out scale.
40357
40358        (WebCore::TileController::tileRevalidationTimerFired):
40359        (WebCore::TileController::retainedTileBackingStoreMemory):
40360        (WebCore::TileController::containerLayers):
40361        
40362            Return both zoomed-out tiles and the active tiles. Active tiles are on top.
40363
40364        (WebCore::TileController::numberOfUnparentedTiles):
40365        (WebCore::TileController::removeUnparentedTilesNow):
40366        * platform/graphics/ca/mac/TileGrid.h:
40367        * platform/graphics/ca/mac/TileGrid.mm:
40368        (WebCore::TileGrid::dropTilesInRect):
40369        
40370            Add a function for dropping tiles.
40371
40372        (WebCore::TileGrid::revalidateTiles):
40373
403742014-04-14  Oliver Hunt  <oliver@apple.com>
40375
40376        Update test result
40377
40378        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
40379        (WebCore::JSTestNondeterministicConstructor::finishCreation):
40380
403812014-04-14  Dirk Schulze  <krit@webkit.org>
40382
40383        Optimize Canvas fill and drawImage with SourceIn, DestinationIn, SourceOut, and DestinationAtop using transparencyLayer.
40384        https://bugs.webkit.org/show_bug.cgi?id=79659
40385
40386        Reviewed by Darin Adler.
40387
40388        Optimize fill() and fillRect() operations in Canvas on composited contexts by
40389        10 to 20 times on CG.
40390
40391        Replacing the ImageBuffer code by transparency layers allows the
40392        graphics library to optimize the drawing.
40393
40394        Doing the same for drawImage() would give performance regressions.
40395
40396        An inline function will create a transparency layer for CG. Cairo graphics
40397        does not composite correctly when a transparency layer gets created. 
40398        The inline function is just a NOOP for Cairo.
40399
40400        This fixes bug 131303 as well.
40401
40402        Added performance tests with r167124 already.
40403
40404        * html/canvas/CanvasRenderingContext2D.cpp:
40405        (WebCore::CanvasRenderingContext2D::fillInternal):
40406        (WebCore::CanvasRenderingContext2D::strokeInternal):
40407        (WebCore::CanvasRenderingContext2D::beginCompositeLayer):
40408        (WebCore::CanvasRenderingContext2D::endCompositeLayer):
40409        (WebCore::CanvasRenderingContext2D::fillRect):
40410        (WebCore::CanvasRenderingContext2D::strokeRect):
40411        (WebCore::CanvasRenderingContext2D::drawTextInternal):
40412        (WebCore::CanvasRenderingContext2D::fullCanvasCompositedFill): Deleted.
40413        * html/canvas/CanvasRenderingContext2D.h:
40414
404152014-04-14  Tim Horton  <timothy_horton@apple.com>
40416
40417        Lots of compositing test failures after r167152
40418        https://bugs.webkit.org/show_bug.cgi?id=131574
40419
40420        Reviewed by Darin Adler.
40421
40422        * platform/graphics/GraphicsLayer.cpp:
40423        (WebCore::dumpChildren):
40424        (WebCore::GraphicsLayer::dumpProperties):
40425        Make child-dumping recursive so that we can easily skip layers up to any depth.
40426
404272014-04-14  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
40428
40429        Fix incorrect indentations in CodeGeneratorJS.pm introduced in r165521
40430        https://bugs.webkit.org/show_bug.cgi?id=131613
40431
40432        Reviewed by Csaba Osztrogonác.
40433
40434        * bindings/scripts/CodeGeneratorJS.pm:
40435        (GenerateImplementation):
40436        Fixed 5-space indentation.
40437        * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
40438        Updated the tests accordingly.
40439
404402014-04-14  Manuel Rego Casasnovas  <rego@igalia.com>
40441
40442        [JSC] CSSStyleDeclaration report incorrect descriptor
40443        https://bugs.webkit.org/show_bug.cgi?id=89697
40444
40445        Reviewed by Benjamin Poulain.
40446
40447        Change descriptor of CSSStyleDeclaration properties in order to have
40448        writable and enumerable attributes set to true. Configurable is kept to
40449        false since the property is not deleteable.
40450
40451        Test: fast/dom/CSSStyleDeclaration/cssstyledeclaration-properties-descriptor.html
40452
40453        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
40454        (WebCore::JSCSSStyleDeclaration::getOwnPropertySlotDelegate): Only set
40455        DontDelete attribute when creating the descriptor for
40456        CSSStyleDeclaration properties.
40457
404582014-04-14  Benjamin Poulain  <benjamin@webkit.org>
40459
40460        [JSC] Improve the call site of string comparison in some hot path
40461        https://bugs.webkit.org/show_bug.cgi?id=131605
40462
40463        Reviewed by Darin Adler.
40464
40465        * dom/NodeRareData.h:
40466        (WebCore::NodeListsNodeData::NodeListCacheMapEntryHash::equal):
40467        We should use the right comparison operation depending on the Hash Traits.
40468
404692014-04-14  Andreas Kling  <akling@apple.com>
40470
40471        Merge MemoryPressureHandler{Mac,IOS}.mm
40472        <https://webkit.org/b/131603>
40473
40474        Join the iOS and Mac platform implementations of MemoryPressureHandler
40475        under the shared Cocoa banner. Each platform still has its own quirky
40476        behavior, but this puts them in the same file so we can start sharing.
40477
40478        Reviewed by Darin Adler.
40479
40480        * WebCore.xcodeproj/project.pbxproj:
40481        * platform/cocoa/MemoryPressureHandlerCocoa.mm: Renamed from Source/WebCore/platform/mac/MemoryPressureHandlerMac.mm.
40482        (WebCore::MemoryPressureHandler::platformReleaseMemory):
40483        (WebCore::MemoryPressureHandler::install):
40484        (WebCore::MemoryPressureHandler::uninstall):
40485        (WebCore::MemoryPressureHandler::holdOff):
40486        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
40487        (WebCore::respondToMemoryPressureCallback):
40488        (WebCore::MemoryPressureHandler::installMemoryReleaseBlock):
40489        (WebCore::MemoryPressureHandler::setReceivedMemoryPressure):
40490        (WebCore::MemoryPressureHandler::hasReceivedMemoryPressure):
40491        (WebCore::MemoryPressureHandler::clearMemoryPressure):
40492        (WebCore::MemoryPressureHandler::shouldWaitForMemoryClearMessage):
40493        (WebCore::MemoryPressureHandler::respondToMemoryPressureIfNeeded):
40494        * platform/ios/MemoryPressureHandlerIOS.mm: Removed.
40495
404962014-04-14  Benjamin Poulain  <benjamin@webkit.org>
40497
40498        CSS JIT: compile the :nth-child() pseudo class
40499        https://bugs.webkit.org/show_bug.cgi?id=131602
40500
40501        Reviewed by Andreas Kling.
40502
40503        Tests: fast/selectors/nth-child-bounds.html
40504               fast/selectors/nth-child-with-backtracking.html
40505
40506        Compile the :nth-child() pseudo class function + some related clean up.
40507
40508        * css/CSSSelector.cpp:
40509        (WebCore::CSSSelector::nthA):
40510        (WebCore::CSSSelector::nthB):
40511        Expose the parsed value of an+b filters. Those values are used to compile
40512        the selector.
40513
40514        (WebCore::CSSSelector::RareData::parseNth):
40515        While working on the patch, I discovered some severe issues with the parsing of large
40516        values of a and/or b. The problem comes from the way the CSS parser handle the values:
40517        the values are parsed as a double then converted to an AtomicString for CSSSelector.
40518
40519        There are many problems related to large values but we never got bug reports because
40520        they are very uncommon. Fixing those problem would require changing the parser.
40521
40522        Here, CSSSelector::RareData::parseNth() is hardened a little bit to avoid absurd values
40523        of a and b.
40524
40525        * css/CSSSelector.h:
40526        * cssjit/RegisterAllocator.h:
40527        It looks like I forgot RDX in the list of register. Add it now since it is required
40528        for SelectorCodeGenerator::modulo().
40529
40530        * cssjit/SelectorCompiler.cpp:
40531        (WebCore::SelectorCompiler::addPseudoType):
40532        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
40533        (WebCore::SelectorCompiler::SelectorCodeGenerator::modulo):
40534        (WebCore::SelectorCompiler::SelectorCodeGenerator::moduloIsZero):
40535        There is no modulo() operation exposed on the macro assemblers. This is a basic
40536        implementation on top of idiv for x86_64.
40537
40538        Since idiv works exclusively with RAX and RDX, most of the code is about getting
40539        those registers efficiently.
40540
40541        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
40542        (WebCore::SelectorCompiler::setElementChildIndex):
40543        (WebCore::SelectorCompiler::setElementChildIndexAndUpdateStyle):
40544        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsNthChild):
40545        This is pretty much a straightforward implementation of :nth-child().
40546        The first part counts the number of previous elements.
40547        The second part updates the tree if this is style resolution.
40548        The last part compares the number of previous siblings to an+b to find if the filter matches.
40549
40550        The only part that diverges from SelectorChecker is how childIndex is used. Instead of testing it
40551        at every iteration, only the first iteration handle the cache.
40552
40553        * dom/ElementRareData.h:
40554        (WebCore::ElementRareData::childIndexMemoryOffset):
40555        * dom/Node.h:
40556        (WebCore::Node::rareDataMemoryOffset):
40557        (WebCore::Node::flagHasRareData):
40558        * rendering/style/RenderStyle.h:
40559
405602014-04-14  Tim Horton  <timothy_horton@apple.com>
40561
40562        Support setting a background color on page overlays
40563        https://bugs.webkit.org/show_bug.cgi?id=131600
40564
40565        Reviewed by Darin Adler.
40566
40567        * rendering/RenderLayerCompositor.cpp:
40568        (WebCore::RenderLayerCompositor::setDocumentOverlayRootLayer):
40569        Mark the compositing tree as needing a rebuild when we get a new document-relative
40570        overlay layer; otherwise we were depending on something else coming along and
40571        requiring a rebuild, which didn't always happen.
40572
405732014-04-14  Mihnea Ovidenie  <mihnea@adobe.com>
40574
40575        [CSS Regions] Hit testing doesn't work in video
40576        https://bugs.webkit.org/show_bug.cgi?id=131485
40577
40578        Reviewed by Andrei Bucur.
40579
40580        When hit testing flow thread layer through the region layer,
40581        we have to pass the depth sorting information and take that
40582        into account for the situation in which an ancestor of the region
40583        has preserve-3d transform style.
40584
40585        Test: fast/regions/hit-test-region-preserve3d-container.html
40586
40587        * rendering/RenderLayer.cpp:
40588        (WebCore::RenderLayer::hitTestLayer):
40589        (WebCore::RenderLayer::hitTestFlowThreadIfRegionForFragments):
40590        * rendering/RenderLayer.h:
40591
405922014-04-13  Darin Adler  <darin@apple.com>
40593
40594        userVisibleString should not try to "encode" host names
40595        https://bugs.webkit.org/show_bug.cgi?id=131587
40596        rdar://problem/14686849
40597
40598        Reviewed by Alexey Proskuryakov.
40599
40600        * WebCore.exp.in: Updated for WebCoreNSURLExtras argument type changes.
40601
40602        * platform/mac/WebCoreNSURLExtras.h: Removed unneeded code to make this
40603        Objective-C++ header compile in plain C++ files, which we never need to do.
40604        Added missing argument name, baseURL, and changed mysterious CFIndex arguments
40605        to the correct type, CFURLComponentType.
40606
40607        * platform/mac/WebCoreNSURLExtras.mm:
40608        (WebCore::isLookalikeCharacter): Removed the inline keyword from this, and added
40609        more lookalike characters from the Mozilla list referenced here.
40610        (WebCore::URLByTruncatingOneCharacterBeforeComponent): Updated argument type.
40611        (WebCore::dataForURLComponentType): Ditto.
40612        (WebCore::userVisibleString): Only call mapHostNames if host name decoding is
40613        needed; no encoding here.
40614
406152014-04-13  Darin Adler  <darin@apple.com>
40616
40617        REGRESSION (r158617): Find on Page can get stuck in a loop when the search string occurs in an <input> in a <fieldset>
40618        https://bugs.webkit.org/show_bug.cgi?id=126322
40619
40620        Reviewed by Ryosuke Niwa.
40621
40622        * dom/Element.cpp:
40623        (WebCore::Element::canContainRangeEndPoint): Now returns false when the role of the element
40624        is "img". This is the same rule that's hard-coded in isRenderReplacedElement for the same
40625        reason. Need more test coverage to make sure this role feature works consistently.
40626
40627        * dom/Element.h: Made canContainRangeEndPoint no longer inline since it's not just a
40628        return statement any more.
40629
40630        * dom/Position.cpp:
40631        (WebCore::Position::isCandidate): Took out code that calls isRendererReplacedElement
40632        that was added in r158617; not needed now that we updated canContainRangeEndPoint.
40633
40634        * dom/Range.cpp:
40635        (WebCore::Range::firstNode): Removed code here that called isRendererReplacedElement.
40636        This was the wrong level to be adding editing logic, and there's a FIXME here to that
40637        effect, which we are now deleting. This was the change that broke Find.
40638
40639        * editing/TextIterator.cpp: Added a comment about the redundancy between the
40640        isRendererReplacedElement and editingIgnoresContent functions.
40641
40642        * html/HTMLHRElement.cpp:
40643        (WebCore::HTMLHRElement::canContainRangeEndPoint): Call through to base class instead
40644        of just returning true when we have child nodes. Lets Element::canContainRangeEndPoint
40645        do its thing.
40646        * html/HTMLHRElement.h: Ditto.
40647
40648        * html/HTMLObjectElement.cpp:
40649        (WebCore::HTMLObjectElement::canContainRangeEndPoint): Call through to base class instead
40650        of just returning true when we have fallback content. Lets Element::canContainRangeEndPoint
40651        do its thing.
40652        * html/HTMLObjectElement.h: Ditto.
40653
40654        * testing/Internals.cpp:
40655        (WebCore::Internals::countMatchesForText): Set the limit to 1000 instead of infinite.
40656
406572014-04-12  Darin Adler  <darin@apple.com>
40658
40659        Use unique_ptr for FillLayer::m_next
40660        https://bugs.webkit.org/show_bug.cgi?id=75222
40661
40662        Reviewed by Dan Bernstein.
40663
40664        * css/DeprecatedStyleBuilder.cpp:
40665        (WebCore::ApplyPropertyFillLayer::applyInheritValue):
40666        Renamed currChild to just child and prevChild to previousChild.
40667        Changed code to pass ownership of the new FillLayer immediately.
40668        Changed some loops to be for loops.
40669        (WebCore::ApplyPropertyFillLayer::applyInitialValue): Ditto.
40670        (WebCore::ApplyPropertyFillLayer::applyValue): Ditto.
40671
40672        * rendering/RenderBox.cpp:
40673        (WebCore::RenderBox::backgroundHasOpaqueTopLayer): Use reference
40674        instead of pointer.
40675        (WebCore::RenderBox::paintFillLayers): Ditto.
40676        * rendering/RenderBoxModelObject.cpp:
40677        (WebCore::RenderBoxModelObject::paintFillLayerExtended): Ditto.
40678
40679        * rendering/style/FillLayer.cpp:
40680        (WebCore::FillLayer::FillLayer): Removed m_next initializer since it is now an
40681        OwnPtr and initializes automatically. In a couple other places, changed m_next
40682        initializer to use make_unique.
40683        (WebCore::FillLayer::~FillLayer): Wrote loop for deletion of m_next.
40684        (WebCore::FillLayer::operator=): Removed unneeded explicit deletion of m_next.
40685        (WebCore::FillLayer::cullEmptyLayers): Ditto.
40686        (WebCore::clipMax): Marked inline.
40687        (WebCore::FillLayer::computeClipMax): Rewrote to use a loop instead of recursion.
40688        (WebCore::FillLayer::containsImage): Ditto.
40689        (WebCore::FillLayer::imagesAreLoaded): Ditto.
40690        (WebCore::FillLayer::hasOpaqueImage): Rewrote to use && instead of multiple if.
40691        (WebCore::FillLayer::hasImage): Rewrote to use a loop instead of recursion.
40692        (WebCore::FillLayer::hasFixedImage): Ditto.
40693
40694        * rendering/style/FillLayer.h: Changed m_next to be a unique_ptr.
40695
406962014-04-13  Andy Estes  <aestes@apple.com>
40697
40698        [QuickLook] Move file system-related code into WebKit
40699        https://bugs.webkit.org/show_bug.cgi?id=131597
40700
40701        Reviewed by Dan Bernstein.
40702
40703        QuickLookHandle should not be responsible for saving a copy of the
40704        original document to disk as it might be running in a process that
40705        either can't write to disk or can only write into a sandboxed
40706        container. To account for this, we need to separate the concern of
40707        quick look conversion from that of original document saving so that
40708        each activity can run in the appropriate process.
40709
40710        Created a new interface between WebCore and WebKit by adding a client
40711        (QuickLookHandleClient) to QuickLookHandle which is notified of incoming
40712        bytes. A new function on FrameLoaderClient tells WebKit when a new
40713        QuickLookHandle is created, giving WebKit the opportunity to register a
40714        handle client. Moved the existing file system-related code as well as
40715        code only needed by WebKit1 in QuickLookHandle into a new WebKit1
40716        QuickLookHandleClient subclass.
40717
40718        * WebCore.exp.in:
40719        * WebCore.xcodeproj/project.pbxproj: Made QuickLookHandleClient.h Private.
40720        * loader/FrameLoaderClient.h:
40721        (WebCore::FrameLoaderClient::didCreateQuickLookHandle): Added.
40722        * loader/ResourceLoader.cpp:
40723        (WebCore::ResourceLoader::didCreateQuickLookHandle): Called FrameLoaderClient::didCreateQuickLookHandle().
40724        * loader/ResourceLoader.h:
40725        * platform/network/ResourceHandle.h: Made m_quickLook a unique_ptr.
40726        (WebCore::ResourceHandle::setQuickLookHandle): Changed to take a unique_ptr.
40727        * platform/network/ResourceHandleClient.h:
40728        (WebCore::ResourceHandleClient::didCreateQuickLookHandle): Added.
40729        * platform/network/ios/QuickLook.h: Added m_client, gave m_converter a stronger type, and made m_nsResponse a RetainPtr.
40730        (WebCore::QuickLookHandle::setClient): Added.
40731        (WebCore::QuickLookHandle::firstRequestURL): Added.
40732        (WebCore::QuickLookHandle::converter): Added.
40733        * platform/network/ios/QuickLook.mm:
40734        (WebCore::registerQLPreviewConverterIfNeeded):
40735        (WebCore::createTemporaryFileForQuickLook): Made non-static.
40736        (WebCore::emptyClient): Returned a shared empty QuickLookHandleClient.
40737        (WebCore::QuickLookHandle::QuickLookHandle): Removed file system and WebKit1-only code.
40738        (WebCore::QuickLookHandle::create): Changed to return a unique_ptr.
40739        (WebCore::QuickLookHandle::nsResponse):
40740        (WebCore::QuickLookHandle::didReceiveDataArray): Removed file system code and called QuickLookHandleClient::didReceiveDataArray() instead.
40741        (WebCore::QuickLookHandle::didReceiveData): Removed file system code and called QuickLookHandleClient::didReceiveData() instead.
40742        (WebCore::QuickLookHandle::didFinishLoading): Removed file system code and called QuickLookHandleClient::didFinishLoading() instead.
40743        (WebCore::QuickLookHandle::didFail): Removed file system and WebKit1-only code, calling QuickLookHandleClient::didFail() instead.
40744        (WebCore::QuickLookHandle::~QuickLookHandle): Removed file system and WebKit1-only code. Cleared our reference to m_client.
40745        (WebCore::QuickLookHandle::previewFileName): Retrieved from m_converter.
40746        (WebCore::QuickLookHandle::previewRequestURL): Ditto.
40747        * platform/network/ios/QuickLookHandleClient.h: Added.
40748        (WebCore::QuickLookHandleClient::~QuickLookHandleClient):
40749        (WebCore::QuickLookHandleClient::didReceiveDataArray):
40750        (WebCore::QuickLookHandleClient::didReceiveData):
40751        (WebCore::QuickLookHandleClient::didFinishLoading):
40752        (WebCore::QuickLookHandleClient::didFail):
40753
407542014-04-10  Pratik Solanki  <psolanki@apple.com>
40755
40756        Move early return out of dispatch_async() block so we can return from willSendRequest quickly
40757        https://bugs.webkit.org/show_bug.cgi?id=131478
40758        <rdar://problem/16575535>
40759
40760        Reviewed by Alexey Proskuryakov.
40761
40762        Do a quick check to see if we need to synthesize the redirect response on the dispatch queue
40763        and return from willSendRequest callback quickly instead of always doing an effectively synchronous
40764        call to the main thread. We can't call synthesizeRedirectResponseIfNecessary on the dispatch
40765        queue since that accesses the ResourceRequest.
40766
40767        No new tests because no change in functionality.
40768
40769        * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h:
40770        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
40771        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::setupRequest): Save the
40772        request scheme to use later for early return from willSendRequest.
40773        (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willSendRequest):
40774
407752014-04-08  Oliver Hunt  <oliver@apple.com>
40776
40777        Rewrite Function.bind as a builtin
40778        https://bugs.webkit.org/show_bug.cgi?id=131083
40779
40780        Reviewed by Geoffrey Garen.
40781
40782        Switch WebCore to use the helper functions when defining the
40783        prototype properties on DOM constructors, and update bindings
40784        tests accordingly.
40785
40786        * bindings/js/JSImageConstructor.cpp:
40787        (WebCore::JSImageConstructor::finishCreation):
40788        * bindings/scripts/CodeGeneratorJS.pm:
40789        (GenerateConstructorHelperMethods):
40790        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
40791        (WebCore::JSTestActiveDOMObjectConstructor::finishCreation):
40792        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
40793        (WebCore::JSTestCustomNamedGetterConstructor::finishCreation):
40794        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
40795        (WebCore::JSTestEventConstructorConstructor::finishCreation):
40796        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
40797        (WebCore::JSTestEventTargetConstructor::finishCreation):
40798        * bindings/scripts/test/JS/JSTestException.cpp:
40799        (WebCore::JSTestExceptionConstructor::finishCreation):
40800        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
40801        (WebCore::JSTestGenerateIsReachableConstructor::finishCreation):
40802        * bindings/scripts/test/JS/JSTestInterface.cpp:
40803        (WebCore::JSTestInterfaceConstructor::finishCreation):
40804        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
40805        (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation):
40806        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
40807        (WebCore::JSTestNamedConstructorConstructor::finishCreation):
40808        (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation):
40809        * bindings/scripts/test/JS/JSTestNode.cpp:
40810        (WebCore::JSTestNodeConstructor::finishCreation):
40811        * bindings/scripts/test/JS/JSTestObj.cpp:
40812        (WebCore::JSTestObjConstructor::finishCreation):
40813        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
40814        (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
40815        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
40816        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation):
40817        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
40818        (WebCore::JSTestTypedefsConstructor::finishCreation):
40819        * bindings/scripts/test/JS/JSattribute.cpp:
40820        (WebCore::JSattributeConstructor::finishCreation):
40821        * bindings/scripts/test/JS/JSreadonly.cpp:
40822        (WebCore::JSreadonlyConstructor::finishCreation):
40823
408242014-04-13  Simon Fraser  <simon.fraser@apple.com>
40825
40826        [iOS WK2] Hook up scrolling tree nodes when coming out of the page cache
40827        https://bugs.webkit.org/show_bug.cgi?id=131577
40828
40829        Reviewed by Tim Horton.
40830
40831        The call to scrollingCoordinator->frameViewRootLayerDidChange() was inside
40832        a #if !PLATFORM(IOS) block, but now that we use the ScrollingCoordinator
40833        for WK2 we want to call this.
40834
40835        * loader/HistoryController.cpp:
40836        (WebCore::HistoryController::restoreScrollPositionAndViewState):
40837
408382014-04-13  Zan Dobersek  <zdobersek@igalia.com>
40839
40840        Unreviewed build fix after r167196.
40841
40842        * platform/RemoteCommandListener.cpp:
40843        (WebCore::RemoteCommandListener::create): Fall back to using the new operator
40844        for allocating RemoteCommandListener object. Using std::make_unique() requires
40845        for the operator to be public, which doesn't work well with the static create()
40846        method.
40847
408482014-04-13  Zan Dobersek  <zdobersek@igalia.com>
40849
40850        Remove unnecessary uses of std::move() in return statements
40851        https://bugs.webkit.org/show_bug.cgi?id=131457
40852
40853        Reviewed by Darin Adler.
40854
40855        Don't use std::move() in return statements unless necessary as it inhibits
40856        named return value optimizations as performed by compilers.
40857
40858        * Modules/battery/BatteryManager.cpp:
40859        (WebCore::BatteryManager::create):
40860        * html/FormController.cpp:
40861        (WebCore::FormController::createSavedFormStateMap):
40862        * html/canvas/WebGLRenderingContext.cpp:
40863        (WebCore::WebGLRenderingContext::create):
40864        * platform/RemoteCommandListener.cpp:
40865        (WebCore::RemoteCommandListener::create):
40866        * platform/graphics/ca/GraphicsLayerCA.cpp:
40867        (WebCore::GraphicsLayer::create):
40868        * platform/ios/RemoteCommandListenerIOS.mm:
40869        (WebCore::RemoteCommandListener::create):
40870        * rendering/RenderGrid.cpp:
40871        (WebCore::RenderGrid::GridIterator::nextEmptyGridArea):
40872        * rendering/RenderLayer.cpp:
40873        (WebCore::RenderLayer::setupFilters):
40874        * rendering/style/CounterDirectives.cpp:
40875        (WebCore::clone):
40876
408772014-04-13  Commit Queue  <commit-queue@webkit.org>
40878
40879        Unreviewed, rolling out r167168 and r167194.
40880        https://bugs.webkit.org/show_bug.cgi?id=131589
40881
40882        Caused massive ASSERTION failures on the GTK Debug bot
40883        (Requested by philn on #webkit).
40884
40885        Reverted changesets:
40886
40887        "[GTK] Add HighDPI support for non-accelerated compositing
40888        contents"
40889        https://bugs.webkit.org/show_bug.cgi?id=131562
40890        http://trac.webkit.org/changeset/167168
40891
40892        "Unreviewed. Fix GTK+ build with recent cairo and GTK+ after
40893        r167168."
40894        http://trac.webkit.org/changeset/167194
40895
408962014-04-13  Youenn Fablet  <youenn.fablet@crf.canon.fr>
40897
40898        [GStreamer] No CORS support for media elements
40899        https://bugs.webkit.org/show_bug.cgi?id=99037
40900
40901        Reviewed by Philippe Normand.
40902
40903        Added CORS access control check to media sources when crossorigin attribute is set.
40904
40905        Added getter to CORS access control check status (used to compute whether the stream is tainted or not).
40906        Related test is http/tests/security/video-cross-origin-readback.html.
40907
40908        Disabled access to cross-origin streams that fail CORS check when crossorigin attribute is set.
40909        Related test is http/tests/security/video-cross-origin-accessfailure.html.
40910
40911        Tests: http/tests/security/video-cross-origin-accessfailure.html
40912               http/tests/security/video-cross-origin-accesssameorigin.html
40913
40914        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
40915        (WebCore::MediaPlayerPrivateGStreamer::didPassCORSAccessCheck): Return whether media is cross-origin (tainted) or not by querying the gstreamer source layer.
40916        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h: Added MediaPlayerPrivateGStreamer::didPassCORSAccessCheck declaration.
40917        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
40918        (webKitWebSrcStart): Passed CORS mode parameter to the streaming client. In case of CORS check failure, stop the resource loading.
40919        (webKitSrcPassedCORSAccessCheck): Return whether CORS access control check was done and successful.
40920        (StreamingClient::handleResponseReceived): Take a parameter to assign the CORS access control check result.
40921        (CachedResourceStreamingClient::CachedResourceStreamingClient): Updated setting of the ResourceLoaderOptions according CORS mode.
40922        (CachedResourceStreamingClient::responseReceived): Check CORS and pass result to handleResponseReceived.
40923        (ResourceHandleStreamingClient::didReceiveResponse): No CORS check.
40924        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.h: Added webKitSrcPassedCORSAccessCheck declaration.
40925
409262014-04-12  Darin Adler  <darin@apple.com>
40927
40928        REGRESSION (r166860): ASSERTION FAILED: !isCalculated() on fast/css/image-set-value-not-removed-crash.html
40929        https://bugs.webkit.org/show_bug.cgi?id=131480
40930
40931        Reviewed by Andreas Kling.
40932
40933        Fixes intermittent assertion failure in fast/css/image-set-value-not-removed-crash.html.
40934
40935        * css/CSSComputedStyleDeclaration.cpp:
40936        (WebCore::valueForImageSliceSide): Added. Helper used below in valueForNinePieceImageSlice.
40937        Handles calculated values by returning 0; incorrect but predictable.
40938        (WebCore::valueForNinePieceImageSlice): Updated to call valueForImageSliceSide.
40939        (WebCore::positionOffsetValue): Use nullptr.
40940        (WebCore::ComputedStyleExtractor::propertyValue): Updated to call positionOffsetValue
40941        by its new name. Removed "get" from the name.
40942        (WebCore::positionOffsetValue): Renamed from getPositionOffsetValue.
40943
40944        * platform/Length.h: Made isCalculated public.
40945
409462014-04-12  Andy Estes  <aestes@apple.com>
40947
40948        Fix the iOS build after r167183.
40949
40950        * platform/network/ResourceHandle.h:
40951        * platform/network/cf/ResourceHandleCFNet.cpp:
40952        (WebCore::ResourceHandle::schedule):
40953        (WebCore::ResourceHandle::unschedule):
40954
409552014-04-12  Andy Estes  <aestes@apple.com>
40956
40957        [iOS] Move QuickLookHandle from ResourceLoader to WebResourceLoader
40958        https://bugs.webkit.org/show_bug.cgi?id=131580
40959
40960        Reviewed by Darin Adler.
40961
40962        There's no need to bloat WebKit1's ResourceLoader with a pointer that
40963        only WebKit2's WebResourceLoader cares about.
40964
40965        * loader/ResourceLoader.h:
40966        (WebCore::ResourceLoader::quickLookHandle): Deleted.
40967        (WebCore::ResourceLoader::setQuickLookHandle): Deleted.
40968
409692014-04-12  Chris Fleizach  <cfleizach@apple.com>
40970
40971        AX: Cleanup AccessibilityObject::getAttribute
40972        https://bugs.webkit.org/show_bug.cgi?id=131555
40973
40974        Reviewed by Darin Adler.
40975
40976        No new functionality.
40977
40978        * accessibility/AccessibilityObject.cpp:
40979        (WebCore::AccessibilityObject::getAttribute):
40980
409812014-04-12  Youenn Fablet  <youenn.fablet@crf.canon.fr>
40982
40983        [SOUP] Libsoup internal credential setting should be controlled by loader decision
40984        https://bugs.webkit.org/show_bug.cgi?id=130963
40985
40986        Reviewed by Darin Adler.
40987
40988        Disabled libsoup internal authentication manager for messages for which no credential is available and no stored credentials should be used.
40989        Updated synchronous loader to return whether using credentials or not according StoredCredential loader option parameter.
40990        Unskipped test http/tests/xmlhttprequest/cross-origin-no-authorization.html covers the patch.
40991
40992        * platform/network/ResourceHandleInternal.h:
40993        (WebCore::ResourceHandleInternal::ResourceHandleInternal): Added m_useAuthenticationManager boolean to control whether disable authentication manager or not.
40994        * platform/network/soup/ResourceHandleSoup.cpp:
40995        (WebCore::WebCoreSynchronousLoader::WebCoreSynchronousLoader): Added m_storedCredentials member.
40996        (WebCore::WebCoreSynchronousLoader::shouldUseCredentialStorage): Return true if stored credentials are allowed.
40997        (WebCore::applyAuthenticationToRequest): Set m_useAuthenticationManager value to disable authentication manager if cannot use stored credentials and ResourceHandleInternal has no username and password.
40998        (WebCore::createSoupMessageForHandleAndRequest): Disable authentication mananger according m_useAuthenticationManager value.
40999        (WebCore::ResourceHandle::platformLoadResourceSynchronously): Added StoredCredentials loader option to the sync loader constructor.
41000
410012014-04-11  Darin Adler  <darin@apple.com>
41002
41003        Some small loader refinements and refactoring
41004        https://bugs.webkit.org/show_bug.cgi?id=131541
41005
41006        Reviewed by Alexey Proskuryakov.
41007
41008        Cut down on use of ResourceLoader::handle, which always returns null when
41009        using a network process. Also streamlined conditionals and did some other
41010        small refactoring.
41011
41012        * loader/DocumentLoader.h: Use references rather than pointers for SchedulePair.
41013
41014        * loader/ResourceLoader.cpp:
41015        (WebCore::ResourceLoader::didChangePriority): Use m_handle instead of handle(),
41016        since we'd like to delete handle() entirely soon.
41017        (WebCore::ResourceLoader::didReceiveAuthenticationChallenge): Ditto.
41018        (WebCore::ResourceLoader::schedule): Added.
41019        (WebCore::ResourceLoader::unschedule): Ditto.
41020        * loader/ResourceLoader.h: Rearranged header to eliminate nested conditionals.
41021        Added schedule and unschedule functions for Mac.
41022
41023        * loader/mac/DocumentLoaderMac.cpp:
41024        (WebCore::scheduleAll): Changed to take a reference and call ResourceLoader::schedule.
41025        (WebCore::unscheduleAll): Ditto.
41026        (WebCore::DocumentLoader::schedule): Ditto.
41027        (WebCore::DocumentLoader::unschedule): Ditto.
41028
41029        * page/mac/PageMac.cpp:
41030        (WebCore::Page::addSchedulePair): Pass a reference rather than a pointer to schedule.
41031        (WebCore::Page::removeSchedulePair): Ditto.
41032
41033        * platform/network/ResourceHandle.h: Did a bit of reformatting and reorganizing of
41034        conditionals.
41035
41036        * platform/network/ResourceHandleInternal.h: Removed a tiny bit of unneeded declaration.
41037
41038        * platform/network/mac/ResourceHandleMac.mm:
41039        (WebCore::ResourceHandle::schedule): Updated to take a reference rather than a pointer.
41040        (WebCore::ResourceHandle::unschedule): Ditto.
41041
410422014-04-11  Andreas Kling  <akling@apple.com>
41043
41044        Make NodeList.length inline-cacheable by JSC.
41045        <https://webkit.org/b/131579>
41046
41047        For objects with custom index or name getters, we have to make sure
41048        that builtin properties take precedence. We do this by scanning the
41049        ancestor chain for a suitable property slot before moving on to
41050        named items.
41051
41052        With this patch, we now mark such builtins as cacheable. This is
41053        safe since the whole point of doing this before processing named
41054        items is to ensure the same slot is returned consistently.
41055
41056        Reviewed by Benjamin Poulain.
41057
41058        * bindings/scripts/CodeGeneratorJS.pm:
41059        (GenerateGetOwnPropertySlotBody):
41060
410612014-04-11  Tim Horton  <timothy_horton@apple.com>
41062
41063        Lots of compositing test failures after r167152
41064        https://bugs.webkit.org/show_bug.cgi?id=131574
41065
41066        Reviewed by Simon Fraser.
41067
41068        * platform/graphics/GraphicsLayer.cpp:
41069        (WebCore::GraphicsLayer::dumpProperties):
41070        We were asking the parent's client whether the child should be dumped,
41071        but really the child's client is the one who should decide.
41072
410732014-04-11  Benjamin Poulain  <bpoulain@apple.com>
41074
41075        ViewportConfiguration::layoutWidth() compute the width incorrectly when initial-scale+width do not fit in view
41076        https://bugs.webkit.org/show_bug.cgi?id=131575
41077
41078        Reviewed by Enrica Casucci.
41079
41080        I made a mistake when writing the new viewport code: ViewportConfiguration::layoutWidth() uses m_contentSize in one place.
41081        That make no sense, contentSize depends on the layout width.
41082
41083        * page/ViewportConfiguration.cpp:
41084        (WebCore::ViewportConfiguration::layoutWidth):
41085
410862014-04-11  Andreas Kling  <akling@apple.com>
41087
41088        Remove "numeric index getter" stuff from bindings code generator.
41089        <https://webkit.org/b/131565>
41090
41091        This was used for an earlier generation of typed arrays. Now that JSC
41092        has native typed array support, we're not using this functionality and
41093        can just remove it.
41094
41095        Reviewed by Geoffrey Garen.
41096
41097        * bindings/scripts/CodeGeneratorJS.pm:
41098        (GenerateGetOwnPropertySlotBody):
41099        (HasComplexGetOwnProperty):
41100        (InterfaceRequiresAttributesOnInstance):
41101        (InstanceOverridesGetOwnPropertySlot):
41102        (GenerateHeader):
41103        (GenerateImplementation):
41104
411052014-04-11  Brian J. Burg  <burg@cs.washington.edu>
41106
41107        Web Replay: consolidate decoding macros used in SerializationMethods
41108        https://bugs.webkit.org/show_bug.cgi?id=131564
41109
41110        Reviewed by Timothy Hatcher.
41111
41112        We can use EncodingTraits<T>::DecodedType to create a local variable
41113        with the appropriate decoded type, rather than special casing.
41114
41115        * replay/SerializationMethods.cpp:
41116        (JSC::EncodingTraits<NondeterministicInputBase>::decodeValue):
41117        (JSC::EncodingTraits<KeypressCommand>::decodeValue):
41118        (JSC::EncodingTraits<PlatformKeyboardEvent>::decodeValue):
41119        (JSC::EncodingTraits<PlatformMouseEvent>::decodeValue):
41120        (JSC::EncodingTraits<PlatformWheelEvent>::decodeValue):
41121        (JSC::EncodingTraits<PluginData>::decodeValue):
41122
411232014-04-11  Beth Dakin  <bdakin@apple.com>
41124
41125        Need WK2 API to disable rubber-banding
41126        https://bugs.webkit.org/show_bug.cgi?id=131567
41127
41128        Reviewed by Simon Fraser.
41129
41130        Page will now store a vertical and horizontal ScrollElasticity in case the API has 
41131        been called before the FrameView even exists.
41132
41133        New Page functions.
41134        * WebCore.exp.in:
41135
41136        Use Page’s cached ScrollElasticity.
41137        * page/FrameView.cpp:
41138        (WebCore::FrameView::FrameView):
41139
41140        If there is already a FrameView, then assign it the new ScrollElasticity.
41141        * page/Page.cpp:
41142        (WebCore::Page::Page):
41143        (WebCore::Page::setVerticalScrollElasticity):
41144        (WebCore::Page::setHorizontalScrollElasticity):
41145        * page/Page.h:
41146        (WebCore::Page::verticalScrollElasticity):
41147        (WebCore::Page::horizontalScrollElasticity):
41148
411492014-04-11  Martin Robinson  <mrobinson@igalia.com>
41150
41151        REGRESSION(167145): Many media tests fail
41152        https://bugs.webkit.org/show_bug.cgi?id=131569
41153
41154        Reviewed by Brent Fulgham.
41155
41156        * PlatformGTK.cmake: Add the localized strings file to the list of user agent scripts.
41157        * platform/gtk/RenderThemeGtk.cpp:
41158        (WebCore::RenderThemeGtk::mediaControlsScript): Include the localized strings file in the script body.
41159
411602014-04-11  Tim Horton  <timothy_horton@apple.com>
41161
41162        [iOS WebKit2] Find-in-page indicator
41163        https://bugs.webkit.org/show_bug.cgi?id=131510
41164        <rdar://problem/16547777>
41165
41166        Reviewed by Simon Fraser and Enrica Casucci.
41167
41168        * editing/Editor.cpp:
41169        (WebCore::Editor::findString):
41170        * editing/FindOptions.h:
41171        Add a find option which prevents WebCore from revealing the selection
41172        after selecting a successful find match.
41173
411742014-04-11  Owen Taylor  <otaylor@redhat.com>
41175
41176        [GTK] Add HighDPI support for non-accelerated compositing contents
41177        https://bugs.webkit.org/show_bug.cgi?id=131562
41178
41179        Reviewed by Martin Robinson.
41180
41181        No new tests. This will be tested once we have the proper dependencies in the WebKit testing
41182        JHBuild.
41183
41184        * platform/cairo/WidgetBackingStore.h:
41185        (WebCore::WidgetBackingStore::WidgetBackingStore): Accept a device scale argument.
41186        * platform/cairo/WidgetBackingStoreCairo.cpp: Use the device scale argument to make the surface the proper size and set the surface device scale.
41187        * platform/cairo/WidgetBackingStoreCairo.h: Accept a device scale argument.
41188        * platform/graphics/cairo/CairoUtilities.cpp: Add a new helper to set the device scale if Cairo built against is new enough.
41189        * platform/graphics/cairo/CairoUtilities.h:
41190        * platform/gtk/GtkVersioning.h: Add the HAVE_GTK_SCALE_FACTOR macro.
41191        * platform/gtk/WidgetBackingStoreGtkX11.cpp: Use the device scale argument to make the surface the proper size and set the surface device scale.
41192        * platform/gtk/WidgetBackingStoreGtkX11.h: Accept a device scale argument.
41193
411942014-04-11  Jon Honeycutt  <jhoneycutt@apple.com>
41195
41196        Assertion failure changing select element size during focus event
41197        dispatch
41198        <https://bugs.webkit.org/show_bug.cgi?id=131566>
41199        <rdar://problem/16400735>
41200
41201        Reviewed by Andy Estes.
41202
41203        Test: fast/forms/select-change-size-during-focus.html
41204
41205        * html/HTMLSelectElement.cpp:
41206        (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
41207        Adopt the fix from Chromium r171216; check that the renderer is still
41208        of the expected type, and return early if it is not.
41209
412102014-04-11  Bem Jones-Bey  <bjonesbe@adobe.com>
41211
41212        Clear sibling floats while splitting inline flow
41213        https://bugs.webkit.org/show_bug.cgi?id=130905
41214
41215        Reviewed by David Hyatt.
41216
41217        This is a port of a Blink patch by kenrb@chromium.org.
41218        (https://src.chromium.org/viewvc/blink?revision=169658&view=revision)
41219
41220        During RenderInline::splitFlow(), floats are cleared on an anonymous
41221        containingBlock() for the inline being split. This is a problem if
41222        siblings of the block contain references to the same floats, since the
41223        float removal code in markSiblingsWithFloatsForLayout() will not later
41224        find them.
41225
41226        This change also affects RenderBlock::splitFlow() and
41227        RenderBoxModelObject::moveChildrenTo, since those are called in
41228        similar situations as RenderInline::splitFlow().
41229
41230        Test: fast/block/float/split-inline-sibling-of-float-crash.html
41231
41232        * rendering/RenderBlockFlow.cpp:
41233        (WebCore::RenderBlockFlow::removeFloatingObjects): Add call to
41234            markSiblingsWithFloatsForLayout() before removing floats.
41235
412362014-04-11  Gavin Barraclough  <baraclough@apple.com>
41237
41238        Rollout - Rewrite Function.bind as a builtin
41239        https://bugs.webkit.org/show_bug.cgi?id=131083
41240
41241        Unreviewed.
41242
41243        Rolling out r167020 while investigating a performance regression.
41244
41245        * bindings/js/JSImageConstructor.cpp:
41246        (WebCore::JSImageConstructor::finishCreation):
41247        * bindings/scripts/CodeGeneratorJS.pm:
41248        (GenerateConstructorHelperMethods):
41249        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
41250        (WebCore::JSTestActiveDOMObjectConstructor::finishCreation):
41251        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
41252        (WebCore::JSTestCustomNamedGetterConstructor::finishCreation):
41253        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
41254        (WebCore::JSTestEventConstructorConstructor::finishCreation):
41255        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
41256        (WebCore::JSTestEventTargetConstructor::finishCreation):
41257        * bindings/scripts/test/JS/JSTestException.cpp:
41258        (WebCore::JSTestExceptionConstructor::finishCreation):
41259        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
41260        (WebCore::JSTestGenerateIsReachableConstructor::finishCreation):
41261        * bindings/scripts/test/JS/JSTestInterface.cpp:
41262        (WebCore::JSTestInterfaceConstructor::finishCreation):
41263        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
41264        (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation):
41265        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
41266        (WebCore::JSTestNamedConstructorConstructor::finishCreation):
41267        (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation):
41268        * bindings/scripts/test/JS/JSTestNode.cpp:
41269        (WebCore::JSTestNodeConstructor::finishCreation):
41270        * bindings/scripts/test/JS/JSTestObj.cpp:
41271        (WebCore::JSTestObjConstructor::finishCreation):
41272        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
41273        (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
41274        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
41275        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation):
41276        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
41277        (WebCore::JSTestTypedefsConstructor::finishCreation):
41278        * bindings/scripts/test/JS/JSattribute.cpp:
41279        (WebCore::JSattributeConstructor::finishCreation):
41280        * bindings/scripts/test/JS/JSreadonly.cpp:
41281        (WebCore::JSreadonlyConstructor::finishCreation):
41282
412832014-04-11  Myles C. Maxfield  <mmaxfield@apple.com>
41284
41285        Build Fix after r167151.
41286
41287        Unreviewed.
41288
41289        * editing/AlternativeTextController.cpp:
41290        (WebCore::AlternativeTextController::applyAlternativeTextToRange):
41291
412922014-04-10  Jer Noble  <jer.noble@apple.com>
41293
41294        [EME][Mac] Using KeySession.update([renew]) should trigger KeyMessage event instead of NeedKey event
41295        https://bugs.webkit.org/show_bug.cgi?id=131527
41296
41297        Reviewed by Eric Carlson.
41298
41299        Rather than triggering a needKey() event, necessatating the creation
41300        of an entirely new MediaKeySession, cause a new key request to be
41301        created by sending the same initData back into the AVSampleDataParser.
41302
41303        Also, do some drive-by clean up suggested by Darin in the review for
41304        r166509.
41305
41306        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
41307        (WebCore::isEqual): Support an alloc-free equality check between
41308            Uint8Array and static strings.
41309        (WebCore::CDMSessionMediaSourceAVFObjC::update):
41310
413112014-04-11  David Kilzer  <ddkilzer@apple.com>
41312
41313        Build fix (r167151): Do not dereference Node::document() before passing to Range::create()
41314        <https://webkit.org/b/131475>
41315
41316        Fixes the following build failure:
41317
41318            WebCore/editing/AlternativeTextController.cpp:275:71: error: indirection requires pointer operand ('WebCore::Document' invalid)
41319                int paragraphStartIndex = TextIterator::rangeLength(Range::create(*rootNode.document(), &rootNode, 0, paragraphRangeContainingCorrection.get()->startContainer(), paragraphRangeContainingCorrection.get()->startOffset()).get());
41320                                                                                  ^~~~~~~~~~~~~~~~~~~~
41321
41322        * editing/AlternativeTextController.cpp:
41323        (WebCore::AlternativeTextController::applyAlternativeTextToRange):
41324        Remove unneeded '*' operator since Node::document() returns a
41325        Document& and Range::create() accepts a Document& for its first
41326        argument.
41327
413282014-04-11  Brian J. Burg  <burg@cs.washington.edu>
41329
41330        Web Replay: memoize nondeterministic attributes of the Navigator interface
41331        https://bugs.webkit.org/show_bug.cgi?id=131340
41332
41333        Reviewed by Timothy Hatcher.
41334
41335        Most attributes of window.navigator do not change very often, but they
41336        could be easily changed by the user or embedder. So, memoize attribute values.
41337
41338        This change does not include navigator.mimeTypes and navigator.plugins,
41339        which will be handled at a different level. <https://webkit.org/b/131341>
41340
41341        Test: ManualTests/inspector/replay-window-navigator-basic.html
41342
41343        * page/Navigator.idl: Add Nondeterministic attribute.
41344
413452014-04-10  Jer Noble  <jer.noble@apple.com>
41346
41347        [iOS][WK2] Videos should animate into and out of fullscreen.
41348        https://bugs.webkit.org/show_bug.cgi?id=131497
41349
41350        Reviewed by Simon Fraser.
41351
41352        Use AVPlayerViewController's new enterFullScreenWithCompletionHandler: and exitFullScreenWithCompletionHandler:
41353        methods to animate into and out of full screen. To do so, use the provided initialFrame and finalFrame screen
41354        rects to correctly place the AVPlayerViewController's view before entering or exiting fullscreen.
41355
41356        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
41357        (-[WebVideoFullscreenController enterFullscreen:]): Pass the media element's screen rect.
41358        (-[WebVideoFullscreenController exitFullscreen]): Ditto.
41359        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
41360        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
41361        (-[WebAVPlayerController playerViewController:shouldExitFullScreenWithReason:]): Renamed from shouldDismissWithReason.
41362        (WebVideoFullscreenInterfaceAVKit::enterFullscreen): Use the new AVKit APIs.
41363        (WebVideoFullscreenInterfaceAVKit::exitFullscreen): Ditto.
41364        * WebCore.exp.in: Modify the exported symbols for enter and exitFullscreen.
41365
413662014-04-11  Tim Horton  <timothy_horton@apple.com>
41367
41368        Support document-relative and custom-frame page overlays
41369        https://bugs.webkit.org/show_bug.cgi?id=131560
41370        <rdar://problem/16595556>
41371
41372        Reviewed by Simon Fraser.
41373
41374        * WebCore.exp.in:
41375        * rendering/RenderLayerCompositor.cpp:
41376        (WebCore::RenderLayerCompositor::RenderLayerCompositor):
41377        (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
41378        (WebCore::RenderLayerCompositor::setDocumentOverlayRootLayer):
41379        * rendering/RenderLayerCompositor.h:
41380        Add the concept of a document overlay layer, which is plugged in as the
41381        last child of the root content layer. Expose it to WebKit2.
41382
413832014-04-09  Myles C. Maxfield  <mmaxfield@apple.com>
41384
41385        Autocorrection causes ASSERT when replacing alternative string
41386        https://bugs.webkit.org/show_bug.cgi?id=131475
41387
41388        Reviewed by Ryosuke Niwa.
41389
41390        In AlternativeTextController::applyAlternativeTextToRange(), we attempt to create
41391        a Range that crosses from outside of a shadow root to inside of one. Instead,
41392        we should keep the Range entirely within the shadow root.
41393
41394        Test: ManualTests/autocorrection/autocorrection-accept-crash.html
41395
41396        * editing/AlternativeTextController.cpp:
41397        (WebCore::AlternativeTextController::applyAlternativeTextToRange):
41398
413992014-04-11  Hans Muller  <hmuller@adobe.com>
41400
41401        [CSS Shapes] shape-outside from image doesn't load properly
41402        https://bugs.webkit.org/show_bug.cgi?id=131491
41403
41404        Reviewed by Bem Jones-Bey.
41405
41406        Make RenderImage::imageChanged() call super if there's a shape-outside
41407        image because the shape-outside imageChanged() logic is in RenderBox.
41408
41409        Test: http/tests/css/shape-image-file.html
41410
41411        * rendering/RenderElement.h:
41412        (WebCore::RenderElement::hasShapeOutside):
41413        * rendering/RenderImage.cpp:
41414        (WebCore::RenderImage::imageChanged):
41415
414162014-04-11  Brady Eidson  <beidson@apple.com>
41417
41418        Aggregate multiple "respondToChangedSelection" calls to one scan for telephone numbers
41419        https://bugs.webkit.org/show_bug.cgi?id=131559
41420
41421        Reviewed by Gavin Barraclough.
41422
41423        No new tests (Perf-only change to an untested feature)
41424
41425        * editing/Editor.cpp:
41426        (WebCore::Editor::Editor):
41427        (WebCore::Editor::respondToChangedSelection): Start a one shot timer for scanSelectionForTelephoneNumbers
41428          instead of scanning synchronously.
41429        (WebCore::Editor::scanSelectionForTelephoneNumbers):
41430        * editing/Editor.h:
41431
414322014-04-11  Antti Koivisto  <antti@apple.com>
41433
41434        Try to fix windows build.
41435        
41436        * platform/graphics/ca/GraphicsLayerCA.h:
41437
414382014-04-11  Brent Fulgham  <bfulgham@apple.com>
41439
41440        Unreviewed follow-up for r167145
41441
41442        * English.lproj/mediaControlsLocalizedStringsiOS.js:
41443        (mediaControlsLocalizedStringsiOS): Use smart-quote in
41444        message string.
41445
414462014-04-11  Brent Fulgham  <bfulgham@apple.com>
41447
41448        Regression: media controls and status messages are no longer localized.
41449        https://bugs.webkit.org/show_bug.cgi?id=120956
41450
41451        Reviewed by Jer Noble.
41452
41453        * English.lproj/mediaControlsLocalizedStrings.js: Added.
41454        (mediaControlsLocalizedStrings): Moved from mediaControlsApple.js.
41455        * English.lproj/mediaControlsLocalizedStringsiOS.js: Added.
41456        (mediaControlsLocalizedStringsiOS): Moved from mediaControlsiOS.js.
41457        * Modules/mediacontrols/mediaControlsApple.js:
41458        (Controller.prototype.UIString): Get strings from external file.
41459        * Modules/mediacontrols/mediaControlsiOS.js:
41460        (ControllerIOS.prototype.UIString): Ditto.
41461        * WebCore.vcxproj/copyWebCoreResourceFiles.cmd: Copy to Windows bundle.
41462        * WebCore.xcodeproj/project.pbxproj: Copy new files to bundle.
41463        * rendering/RenderThemeIOS.mm:
41464        (WebCore::RenderThemeIOS::mediaControlsScript): Load the locale-specific
41465        string resource when loading the media controls.
41466        * rendering/RenderThemeMac.mm:
41467        (WebCore::RenderThemeMac::mediaControlsScript): Ditto.
41468        * rendering/RenderThemeWin.cpp:
41469        (WebCore::RenderThemeWin::mediaControlsScript): Ditto.
41470
414712014-04-11  Brent Fulgham  <bfulgham@apple.com>
41472
41473        [Win] Build fix after r167138
41474
41475        * platform/graphics/ca/GraphicsLayerCA.h: The TileController is
41476        only available on Mac/Cocoa builds.
41477
414782014-04-11  Mark Lam  <mark.lam@apple.com>
41479
41480        JSMainThreadExecState::call() should clear exceptions before returning.
41481        <https://webkit.org/b/131530>
41482
41483        Reviewed by Geoffrey Garen.
41484
41485        Test: fast/dom/regress-131530.html
41486
41487        Previously, JSMainThreadExecState::call() did not clear any pending
41488        exceptions in the VM before returning.  On returning, the
41489        JSMainThreadExecState destructor may re-enter the VM to notify
41490        MutationObservers.  This may result in a crash because the VM expects
41491        exceptions to be cleared at entry.
41492
41493        We now change JSMainThreadExecState::call() to return the exception
41494        (if present) via an argument, and clear it from the VM before returning.
41495
41496        As part of this change, I updated various parts of the code base to use the
41497        new API as needed.
41498
41499        * bindings/js/JSCallbackData.cpp:
41500        (WebCore::JSCallbackData::invokeCallback):
41501        * bindings/js/JSCustomXPathNSResolver.cpp:
41502        (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
41503        * bindings/js/JSDOMGlobalObjectTask.cpp:
41504        - Assert that there's no unhandled exception after the Microtask returns.
41505          See comment for WebCore::JSMainThreadExecState::runTask below for more
41506          details.
41507
41508        * bindings/js/JSErrorHandler.cpp:
41509        (WebCore::JSErrorHandler::handleEvent):
41510        * bindings/js/JSEventListener.cpp:
41511        (WebCore::JSEventListener::handleEvent):
41512        * bindings/js/JSHTMLDocumentCustom.cpp:
41513        (WebCore::JSHTMLDocument::open):
41514        - Document.open() cannot be the first function on the JS stack.  Hence,
41515          there is no need to use JSMainThreadExecState to call into the VM, as
41516          this is only needed to catch the event of returning from the first
41517          function for the purpose of notifying MutationObservers.  Change to
41518          call JSC::call() directly.
41519
41520        * bindings/js/JSMainThreadExecState.cpp:
41521        (WebCore::functionCallHandlerFromAnyThread):
41522        * bindings/js/JSMainThreadExecState.h:
41523        (WebCore::JSMainThreadExecState::call):
41524        (WebCore::JSMainThreadExecState::evaluate):
41525        - Remove the explicitly acquisition of the JSLock here because we now
41526          acquire the JSLock as part of the JSMainThreadExecState instance.
41527        (WebCore::JSMainThreadExecState::runTask):
41528        - Added an assert to verify that the task does not return with an
41529          unhandled exception.  Currently, the only Microtask in use is for the
41530          Promise implementation, which will eat the exception before returning.
41531          This assertion is added here to verify that this contract does not
41532          inadvertantly change in the future.
41533        (WebCore::JSMainThreadExecState::JSMainThreadExecState):
41534        - Now acquires the JSLock as well since by definition, we're only
41535          instantiating the JSMainThreadExecState because we're about to enter
41536          the VM.
41537
41538        * bindings/js/JSMutationCallback.cpp:
41539        (WebCore::JSMutationCallback::call):
41540        * bindings/js/JSNodeFilterCondition.cpp:
41541        (WebCore::JSNodeFilterCondition::acceptNode):
41542        - acceptNode() is only used in the TreeWalker and NodeIterator APIs which
41543          cannot be the first function on the JS stack.  Hence, we should call
41544          JSC::call() directly instead of going through JSMainThreadExecState.
41545
41546        * bindings/js/ScheduledAction.cpp:
41547        (WebCore::ScheduledAction::executeFunctionInContext):
41548        * bindings/objc/WebScriptObject.mm:
41549        (WebCore::addExceptionToConsole):
41550        (-[WebScriptObject callWebScriptMethod:withArguments:]):
41551
415522014-04-11  Brian J. Burg  <burg@cs.washington.edu>
41553
41554        Web Replay: CodeGeneratorJS should guard includes of replay-related headers
41555        https://bugs.webkit.org/show_bug.cgi?id=131407
41556
41557        Reviewed by Timothy Hatcher.
41558
41559        This patch adds guards to headers that are only required by generated replay code
41560        that is itself guarded. Other ports probably haven't added the headers to their
41561        build files, so we don't want to emit the unused header includes.
41562
41563        This patch also converts generated uses of DEFINE_STATIC_LOCAL to NeverDestroyed<T>.
41564        Finally, a new bindings test was added to document changes to generated replay code.
41565
41566        Test: Source/WebCore/bindings/scripts/test/TestNondeterministic.idl
41567
41568        * bindings/scripts/CodeGeneratorJS.pm:
41569        (GenerateImplementation):
41570        (GenerateImplementationFunctionCall):
41571
41572        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.cpp: Added.
41573        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.h: Added.
41574        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministic.symbols: Added.
41575        * bindings/scripts/test/GObject/WebKitDOMTestNondeterministicPrivate.h: Added.
41576        * bindings/scripts/test/JS/JSTestNondeterministic.cpp: Added.
41577        * bindings/scripts/test/JS/JSTestNondeterministic.h: Added.
41578        * bindings/scripts/test/ObjC/DOMTestNondeterministic.h: Added.
41579        * bindings/scripts/test/ObjC/DOMTestNondeterministic.mm: Added.
41580        * bindings/scripts/test/ObjC/DOMTestNondeterministicInternal.h: Added.
41581        * bindings/scripts/test/TestNondeterministic.idl: Added.
41582
415832014-04-11  Antti Koivisto  <antti@apple.com>
41584
41585        Pipe initial scale factor to TileController
41586        https://bugs.webkit.org/show_bug.cgi?id=131521
41587
41588        Reviewed by Tim Horton.
41589
41590        * WebCore.exp.in:
41591        * page/Page.cpp:
41592        (WebCore::Page::Page):
41593        (WebCore::Page::setZoomedOutPageScaleFactor):
41594        * page/Page.h:
41595        (WebCore::Page::zoomedOutPageScaleFactor):
41596        * platform/graphics/GraphicsLayerClient.h:
41597        (WebCore::GraphicsLayerClient::zoomedOutPageScaleFactor):
41598        * platform/graphics/TiledBacking.h:
41599        * platform/graphics/ca/GraphicsLayerCA.cpp:
41600        (WebCore::GraphicsLayerCA::updateContentsScale):
41601        * platform/graphics/ca/GraphicsLayerCA.h:
41602        * platform/graphics/ca/mac/TileController.h:
41603        * platform/graphics/ca/mac/TileController.mm:
41604        (WebCore::TileController::TileController):
41605        (WebCore::TileController::setContentsScale):
41606        (WebCore::TileController::setZoomedOutContentsScale):
41607        * rendering/RenderLayerBacking.cpp:
41608        (WebCore::RenderLayerBacking::zoomedOutPageScaleFactor):
41609        * rendering/RenderLayerBacking.h:
41610        * rendering/RenderLayerCompositor.cpp:
41611        (WebCore::RenderLayerCompositor::zoomedOutPageScaleFactor):
41612        * rendering/RenderLayerCompositor.h:
41613
416142014-04-10  Chris Fleizach  <cfleizach@apple.com>
41615
41616        Heap-use-after-free in WebCore::SpeechSynthesisUtterance::startTime
41617        https://bugs.webkit.org/show_bug.cgi?id=131482
41618
41619        Reviewed by David Kilzer.
41620
41621        Hold onto the utterance until it has time to fire, in case other references have been removed.
41622
41623        Merged from Blink r171077 by <dmazzoni@chromium.org>
41624
41625        Test: platform/mac/fast/speechsynthesis/speech-synthesis-gc-utterance-crash.html
41626
41627        * Modules/speech/SpeechSynthesis.cpp:
41628        (WebCore::SpeechSynthesis::handleSpeakingCompleted):
41629
416302014-04-11  Zan Dobersek  <zdobersek@igalia.com>
41631
41632        Avoid Vector copies in RenderGrid::placeItemsOnGrid()
41633        https://bugs.webkit.org/show_bug.cgi?id=131452
41634
41635        Reviewed by Sergio Villar Senin.
41636
41637        * rendering/RenderGrid.cpp:
41638        (WebCore::RenderGrid::placeSpecifiedMajorAxisItemsOnGrid): Take in a const reference to the
41639        Vector object. Make the for-loop that iterates through it range-based.
41640        (WebCore::RenderGrid::placeAutoMajorAxisItemsOnGrid): Ditto.
41641        * rendering/RenderGrid.h:
41642
416432014-04-11  Joseph Pecoraro  <pecoraro@apple.com>
41644
41645        Web Inspector: Remove shared PageScriptDebugServer, create per-Page
41646        https://bugs.webkit.org/show_bug.cgi?id=131523
41647
41648        Reviewed by Timothy Hatcher.
41649
41650        Having a shared PageScriptDebugServer was causing issues when we called
41651        JSC::Debugger::clearBreakpoints() closing one inspector while another
41652        is open for another WebCore::Page in the same process. Having the same
41653        JSC::Debugger underlying multiple InspectorDebuggerAgent instances
41654        means that when clearBreakpoints is called, the real JSC breakpoints
41655        underlying other InspectorDebuggerAgent's get removed. When those
41656        InspectorDebuggerAgents attempt to remove their breakpoints they
41657        encounter unexpected issues.
41658
41659        This entirely rebuilds PageScriptDebugServer to be per-Page instead
41660        of shared across all pages. So take this opportunity to move the
41661        file from WebCore/bindings/js to WebCore/inspector.
41662
41663        * CMakeLists.txt:
41664        * WebCore.vcxproj/WebCore.vcxproj:
41665        * WebCore.vcxproj/WebCore.vcxproj.filters:
41666        * WebCore.xcodeproj/project.pbxproj:
41667        * bindings/js/JSBindingsAllInOne.cpp:
41668        * bindings/js/PageScriptDebugServer.h: Removed.
41669        * inspector/InspectorAllInOne.cpp:
41670        Move PageScriptDebugServer.
41671
41672        * inspector/InspectorController.h:
41673        * inspector/InspectorController.cpp:
41674        (WebCore::InspectorController::InspectorController):
41675        Set the ScriptDebugServer directly on some other agents that
41676        were previously using the global debug server.
41677
41678        * inspector/InspectorProfilerAgent.h:
41679        (WebCore::InspectorProfilerAgent::scriptDebugServer):
41680        * inspector/InspectorProfilerAgent.cpp:
41681        (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
41682        (WebCore::InspectorProfilerAgent::setScriptDebugServer):
41683        (WebCore::InspectorProfilerAgent::start):
41684        (WebCore::InspectorProfilerAgent::willDestroyFrontendAndBackend): Deleted.
41685        * inspector/InspectorTimelineAgent.h:
41686        * inspector/InspectorTimelineAgent.cpp:
41687        (WebCore::InspectorTimelineAgent::start):
41688        (WebCore::InspectorTimelineAgent::stop):
41689        (WebCore::InspectorTimelineAgent::setPageScriptDebugServer):
41690        (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
41691        Refactor these two agents to take in a script debug server.
41692        The server is expected to be set during initialization and
41693        to always be valid (like debug server on RuntimeAgent).
41694
41695        * inspector/PageDebuggerAgent.h:
41696        * inspector/PageDebuggerAgent.cpp:
41697        (WebCore::PageDebuggerAgent::PageDebuggerAgent):
41698        (WebCore::PageDebuggerAgent::startListeningScriptDebugServer):
41699        (WebCore::PageDebuggerAgent::stopListeningScriptDebugServer):
41700        (WebCore::PageDebuggerAgent::scriptDebugServer):
41701        Have PageDebuggerAgent hold the PageScriptDebugServer.
41702        Update for the simplified interfaces.
41703
41704        * inspector/PageScriptDebugServer.h: Added.
41705        * inspector/PageScriptDebugServer.cpp: Renamed from Source/WebCore/bindings/js/PageScriptDebugServer.cpp.
41706        (WebCore::PageScriptDebugServer::PageScriptDebugServer):
41707        (WebCore::PageScriptDebugServer::addListener):
41708        (WebCore::PageScriptDebugServer::removeListener):
41709        (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
41710        (WebCore::PageScriptDebugServer::didPause):
41711        (WebCore::PageScriptDebugServer::didContinue):
41712        (WebCore::PageScriptDebugServer::runEventLoopWhilePaused):
41713        (WebCore::PageScriptDebugServer::runEventLoopWhilePausedInternal):
41714        (WebCore::PageScriptDebugServer::isContentScript):
41715        (WebCore::PageScriptDebugServer::reportException):
41716        (WebCore::PageScriptDebugServer::setJavaScriptPaused):
41717        Model after JSGlobalObjectScriptDebugServer, the PageScriptDebugServer
41718        holds a reference to a Page.
41719
417202014-04-11  Bear Travis  <betravis@adobe.com>
41721
41722        [CSS Shapes] inset args and radial args should serialize to the simplest form
41723        https://bugs.webkit.org/show_bug.cgi?id=129825
41724
41725        Reviewed by Dirk Schulze.
41726
41727        Modify inset serialization to omit components where possible. The insets simplify
41728        according to the margin shorthand, while the corner radii simplify according to
41729        the border-radius shorthand.
41730
41731        Modifying existing parsing tests.
41732
41733        * css/CSSBasicShapes.cpp:
41734        (WebCore::buildInsetRadii): Add the necessary radii, omitting components where possible.
41735        (WebCore::buildInsetString): Omit components where possible.
41736
417372014-04-11  Praveen R Jadhav  <praveen.j@samsung.com>
41738
41739        "playbackTime" parameter is not present in AudioProcessingEvent Interface as per W3C spec
41740        https://bugs.webkit.org/show_bug.cgi?id=105518
41741
41742        Reviewed by Jer Noble.
41743
41744        Attribute "playbackTime" in AudioProcessingEvent implemented to pass playback time of
41745        audiobuffer associated with ScriptProcessorNode of the context.
41746 
41747        Reference: https://codereview.chromium.org/210973002
41748
41749        Spec: http://www.w3.org/TR/webaudio/#AudioProcessingEvent
41750
41751        Test: webaudio/audioprocessingevent.html
41752
41753        * Modules/webaudio/AudioProcessingEvent.cpp:
41754        (WebCore::AudioProcessingEvent::create):
41755        (WebCore::AudioProcessingEvent::AudioProcessingEvent):
41756        * Modules/webaudio/AudioProcessingEvent.h:
41757        (WebCore::AudioProcessingEvent::playbackTime):
41758        * Modules/webaudio/AudioProcessingEvent.idl:
41759        * Modules/webaudio/ScriptProcessorNode.cpp:
41760        (WebCore::ScriptProcessorNode::fireProcessEvent):
41761
417622014-04-11  Zalan Bujtas  <zalan@apple.com>
41763
41764        Subpixel rendering: WK1: Trail of cruft in redraw during animations.
41765        https://bugs.webkit.org/show_bug.cgi?id=131525
41766
41767        Reviewed by Simon Fraser.
41768
41769        Use enclosing rect instead of snapping to make sure the repaint rect always
41770        covers the dirty area when painting is requested in a non-compositing RenderView.
41771        This only applies to WK1 as WK2 has compositing RenderView and the repainting 
41772        is managed by RenderLayerBacking.
41773
41774        This is a temporary solution until after ScrollView/FrameView/RenderView
41775        is transitioned to device pixels. (tracked here: webkit.org/b/131526).
41776
41777        Test: fast/repaint/hidpi-block-width-change-leaves-cruft.html
41778
41779        * rendering/RenderView.cpp:
41780        (WebCore::RenderView::repaintViewRectangle):
41781
417822014-04-10  Dean Jackson  <dino@apple.com>
41783
41784        WebGL: need error checking after texture uploads
41785        https://bugs.webkit.org/show_bug.cgi?id=62902
41786        rdar://problem/9640309
41787
41788        Reviewed by Brent Fulgham.
41789
41790        A followup to Darin's r167109. We need to also check for errors
41791        in the texImage2D case.
41792
41793        This is difficult to reproducibly test because it would require
41794        attempting to exhaust GPU memory.
41795
41796        * html/canvas/WebGLRenderingContext.cpp:
41797        (WebCore::WebGLRenderingContext::compressedTexImage2D): Check for errors by calling
41798        moveErrorsToSyntheticErrorList twice, once before and once after. If an error
41799        occurred, explicitly mark the texture as invalid.
41800        (WebCore::WebGLRenderingContext::texImage2DBase): Ditto.
41801        * html/canvas/WebGLTexture.cpp:
41802        (WebCore::WebGLTexture::markInvalid): If the LevelInfo exists for this
41803        mipmap level, then set the valid flag to false. There is a chance that
41804        a previous call to texImage2D succeeded for this level, but it's probably
41805        better to assume that is now invalid.
41806        * html/canvas/WebGLTexture.h: New markInvalid method.
41807
418082014-04-10  Darin Adler  <darin@apple.com>
41809
41810        WebGL: need error checking after texture and buffer uploads in some cases
41811        https://bugs.webkit.org/show_bug.cgi?id=62902
41812        rdar://problem/9640309
41813
41814        Reviewed by Dean Jackson.
41815
41816        Not clear how to write a test for this.
41817
41818        * html/canvas/WebGLBuffer.cpp:
41819        (WebCore::WebGLBuffer::disassociateBufferData): Added.
41820        * html/canvas/WebGLBuffer.h: Added disassociateBufferData.
41821
41822        * html/canvas/WebGLRenderingContext.cpp:
41823        (WebCore::WebGLRenderingContext::bufferData): Check for errors by calling
41824        moveErrorsToSyntheticErrorList twice, once before and once after. If an error
41825        occurred, call the WebGLBuffer so it doesn't think it has data.
41826        (WebCore::WebGLRenderingContext::bufferSubData): Ditto.
41827
41828        * platform/graphics/GraphicsContext3D.h: Added moveErrorsToSyntheticErrorList.
41829
41830        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
41831        (WebCore::GraphicsContext3D::moveErrorsToSyntheticErrorList): Added. Calls
41832        glError and moves any errors to the synthetic error list.
41833        (WebCore::GraphicsContext3D::getError): Added call to moveErrorsToSyntheticErrorList
41834        to preserve error ordering.
41835        (WebCore::GraphicsContext3D::synthesizeGLError): Ditto.
41836
418372014-04-10  Enrica Casucci  <enrica@apple.com>
41838
41839        iOS build fix to deal with CoreText changes.
41840        
41841        Reviewed by Benjamin Poulain.
41842        
41843        This is a temporary fix until CT fixes the issue.
41844
41845        * rendering/RenderThemeIOS.mm:
41846
418472014-04-10  Commit Queue  <commit-queue@webkit.org>
41848
41849        Unreviewed, rolling out r167073.
41850        https://bugs.webkit.org/show_bug.cgi?id=131516
41851
41852        This patch caused crashes in video tests. (Requested by
41853        mrobinson on #webkit).
41854
41855        Reverted changeset:
41856
41857        "[GStreamer] No CORS support for media elements"
41858        https://bugs.webkit.org/show_bug.cgi?id=99037
41859        http://trac.webkit.org/changeset/167073
41860
418612014-04-10  Beth Dakin  <bdakin@apple.com>
41862
41863        Radio buttons are using the wrong sizes and margins
41864        https://bugs.webkit.org/show_bug.cgi?id=131503
41865
41866        Reviewed by Jer Noble.
41867
41868        This is a regression that I caused recently when I combined radio button and 
41869        checkbox code. 
41870        * platform/mac/ThemeMac.mm:
41871        (WebCore::paintToggleButton):
41872
418732014-04-08  Jon Honeycutt  <jhoneycutt@apple.com>
41874
41875        Assertion failure in WebCore::FlexBoxIterator::next()
41876        <https://bugs.webkit.org/show_bug.cgi?id=117176>
41877        <rdar://problem/14054549>
41878
41879        Code added in r115687 began removing anonymous wrappers when children
41880        become inline. However, there are some objects, like
41881        RenderDeprecatedFlexBox, whose children should always be blocks.
41882
41883        Reviewed by Tim Horton.
41884
41885        * rendering/RenderBlock.h:
41886        (WebCore::RenderBlock::canCollapseAnonymousBlockChild):
41887        Made public.
41888
41889        * rendering/RenderObject.cpp:
41890        (WebCore::RenderObject::removeAnonymousWrappersForInlinesIfNecessary):
41891        Return early if we can't collapse anonymous block children.
41892
418932014-04-07  Jon Honeycutt  <jhoneycutt@apple.com>
41894
41895        Assertion failure, !node || node->isElementNode(), in
41896        WebCore::RenderBlock::clone()
41897        <https://bugs.webkit.org/show_bug.cgi?id=110489>
41898        <rdar://problem/13666425>
41899
41900        Reviewed by Antti Koivisto.
41901
41902        We're ending up in RenderBlock::splitBlocks() with |this| ==
41903        |fromBlock|.  We then try to climb the ancestor block chain from
41904        this->parent() to |fromBlock|, but this->parent() is already above
41905        |fromBlock|, so we end up climbing up to the RenderView and trying to
41906        clone it, causing the assertion failure.
41907
41908        Adopt Chromium's mitigation for this from
41909        <https://codereview.chromium.org/13852041>. This is not intended as a
41910        fix for the underlying issue.
41911
41912        Also, fix another issue that occurs with this fuzzed test case that's
41913        not handled by the Chromium fix.
41914
41915        * rendering/RenderBlock.cpp:
41916        (WebCore::RenderBlock::splitBlocks):
41917        Ensure while we're in the loop that |curr| is a descendant of
41918        |fromBlock|. From the Chromium patch:
41919
41920            We need to check in every iteration of the loop because
41921            moveChildrenTo could have moved |curr|. This is a mitigation and
41922            not really a fix against a class of tree craziness.
41923
41924        Finally, before moving children from |fromBlock| to |toBlock|, ensure
41925        that the children are children of |fromBlock|. If we never entered the
41926        loop, they will be siblings of |fromBlock|, not children.
41927
419282014-04-10  Enrica Casucci  <enrica@apple.com>
41929
41930        Build fix after http://trac.webkit.org/changeset/167085.
41931
41932        Reviewed by Timothy Hatcher.
41933
41934        * plugins/PluginData.h:
41935
419362014-04-10  Zalan Bujtas  <zalan@apple.com>
41937
41938        Web Inspector: Breakpoint in gutter has clipped / broken border image.
41939        https://bugs.webkit.org/show_bug.cgi?id=131500
41940
41941        Reviewed by Joseph Pecoraro.
41942
41943        Typo in r166925.
41944
41945        Test: fast/borders/border-image-slice-missing-right.html
41946
41947        * rendering/RenderBoxModelObject.cpp:
41948        (WebCore::RenderBoxModelObject::paintNinePieceImage):
41949
419502014-04-10  James Craig  <jcraig@apple.com>
41951
41952        Web Inspector: AXI: expose aria-busy state of current and ancestor nodes
41953        https://bugs.webkit.org/show_bug.cgi?id=130826
41954
41955        Reviewed by Timothy Hatcher.
41956
41957        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
41958
41959        Expose if node is contained by any "busy" ancestor nodes, too.
41960
41961        * inspector/InspectorDOMAgent.cpp:
41962        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
41963
419642014-04-10  Joseph Pecoraro  <pecoraro@apple.com>
41965
41966        Web Inspector: Remove unused ruler in overlay code
41967        https://bugs.webkit.org/show_bug.cgi?id=131507
41968
41969        Reviewed by Timothy Hatcher.
41970
41971        * inspector/InspectorDOMAgent.cpp:
41972        (WebCore::InspectorDOMAgent::highlightConfigFromInspectorObject):
41973        * inspector/InspectorOverlay.cpp:
41974        (WebCore::buildObjectForHighlight):
41975        * inspector/InspectorOverlay.h:
41976        (WebCore::Highlight::Highlight):
41977        (WebCore::Highlight::setDataFromConfig):
41978        * inspector/InspectorOverlayPage.js:
41979        (_drawFragmentHighlight):
41980        (_drawRegionNumber): Deleted.
41981        (quadToPath): Deleted.
41982        (drawOutlinedQuad): Deleted.
41983        (pathCommand): Deleted.
41984        (drawPath): Deleted.
41985        (drawOutlinedQuadWithClip): Deleted.
41986        (quadEquals): Deleted.
41987        (drawGutter): Deleted.
41988        (drawNodeHighlight): Deleted.
41989        (drawQuadHighlight): Deleted.
41990        (setPlatform): Deleted.
41991        (dispatch): Deleted.
41992        (log): Deleted.
41993
419942014-04-10  Brian J. Burg  <burg@cs.washington.edu>
41995
41996        Web Replay: memoize plugin data for navigator.mimeTypes and navigator.plugins
41997        https://bugs.webkit.org/show_bug.cgi?id=131341
41998
41999        Reviewed by Timothy Hatcher.
42000
42001        Information about plugins and mime types is nondeterministic and can change
42002        at any time, whether by system events, browser settings changes, or
42003        triggered by script. To avoid interposing on all those code paths, just
42004        memoize the plugin data used by DOMPluginArray and DOMMimeTypeArray.
42005
42006        This is less efficient than controlling mutations to the underlying PluginData
42007        of a Page, but that can be done later if better plugin support is desired.
42008        The point of this change is to make analytics trackers deterministic across
42009        enabling/disabling of plugins.
42010
42011        Test: LayoutTests/inspector/window-navigator-plugins-memoized.hml
42012
42013        * plugins/DOMMimeTypeArray.cpp:
42014        (WebCore::DOMMimeTypeArray::getPluginData):
42015        * plugins/DOMPluginArray.cpp:
42016        (WebCore::DOMPluginArray::pluginData): Save or restore memoized plugin
42017        data during capture and replay, respectively.
42018
42019        * plugins/PluginData.h:
42020        (WebCore::PluginData::PluginData): Add a constructor that uses the
42021        provided plugin data rather than fetching live plugin data. This is
42022        marked protected so it's only used by a subclass specifically for
42023        deserialization.
42024
42025        * replay/SerializationMethods.cpp: Add encoder specializations.
42026        (JSC::EncodingTraits<MimeClassInfo>::encodeValue):
42027        (JSC::EncodingTraits<MimeClassInfo>::decodeValue):
42028        (JSC::EncodingTraits<PluginInfo>::encodeValue):
42029        (JSC::EncodingTraits<PluginInfo>::decodeValue):
42030        (JSC::EncodingTraits<PluginData>::encodeValue):
42031        (JSC::DeserializedPluginData::DeserializedPluginData): Add a custom
42032        subclass of PluginData that can be initialized from deserialized data.
42033        (JSC::EncodingTraits<PluginData>::decodeValue):
42034        * replay/SerializationMethods.h:
42035        * replay/WebInputs.json: Add new input FetchPluginData.
42036
420372014-04-10  Myles C. Maxfield  <mmaxfield@apple.com>
42038
42039        Remove "System Font" from character width calculations
42040        https://bugs.webkit.org/show_bug.cgi?id=131411
42041
42042        Reviewed by Tim Horton.
42043
42044        Covered by existing tests
42045
42046        * platform/graphics/Font.cpp:
42047        (WebCore::Font::hasValidAverageCharWidth):
42048
420492014-04-10  Bem Jones-Bey  <bjonesbe@adobe.com>
42050
42051        Invalid cast in WebCore::RenderLayer::setupClipPath
42052        https://bugs.webkit.org/show_bug.cgi?id=131368
42053
42054        Reviewed by Dirk Schulze.
42055
42056        Only attempt to clip to a box shape if the renderer being clipped is
42057        actually a box.
42058
42059        Test: css3/masking/clip-path-box-shape-on-inline-crash.html
42060
42061        * rendering/RenderLayer.cpp:
42062        (WebCore::RenderLayer::setupClipPath): Add isBox() check.
42063
420642014-04-10  Owen Taylor  <otaylor@redhat.com>
42065
42066        [GTK] Remove a comment that was incorrectly cut-and-pasted from WidgetBackingStoreCairo
42067        https://bugs.webkit.org/show_bug.cgi?id=131499
42068
42069        Reviewed by Martin Robinson.
42070
42071        * platform/gtk/WidgetBackingStoreGtkX11.cpp: Remove a comment that was incorrectly copy and pasted
42072        from the Cairo implementation.
42073
420742014-04-09  Alexey Proskuryakov  <ap@apple.com>
42075
42076        Eliminate DragSession structure
42077        https://bugs.webkit.org/show_bug.cgi?id=131465
42078
42079        Reviewed by Benjamin Poulain.
42080
42081        DragSession is really just a transient response to NSDragDestination delegate methods.
42082        The "session" name was quite misleading, and thankfully, we don't need a class for this
42083        bag of data at all.
42084
42085        * WebCore.xcodeproj/project.pbxproj:
42086        * page/DragController.cpp:
42087        (WebCore::DragController::DragController):
42088        (WebCore::DragController::dragEntered):
42089        (WebCore::DragController::dragUpdated):
42090        (WebCore::DragController::dragEnteredOrUpdated):
42091        (WebCore::DragController::tryDocumentDrag):
42092        * page/DragController.h:
42093        (WebCore::DragController::mouseIsOverFileInput):
42094        (WebCore::DragController::numberOfItemsToBeAccepted):
42095        * page/DragSession.h: Removed.
42096
420972014-04-10  Youenn Fablet  <youenn.fablet@crf.canon.fr>
42098
42099        [GStreamer] No CORS support for media elements
42100        https://bugs.webkit.org/show_bug.cgi?id=99037
42101
42102        Reviewed by Philippe Normand.
42103
42104        Added CORS access control check to media sources when crossorigin attribute is set.
42105
42106        Added getter to CORS access control check status (used to compute whether the stream is tainted or not).
42107        Related test is http/tests/security/video-cross-origin-readback.html.
42108
42109        Disabled access to cross-origin streams that fail CORS check when crossorigin attribute is set.
42110        Related test is http/tests/security/video-cross-origin-accessfailure.html.
42111
42112        Tests: http/tests/security/video-cross-origin-accessfailure.html
42113               http/tests/security/video-cross-origin-accesssameorigin.html
42114
42115        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
42116        (WebCore::MediaPlayerPrivateGStreamer::didPassCORSAccessCheck): Return whether media is cross-origin (tainted) or not by querying the gstreamer source layer.
42117        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h: Added MediaPlayerPrivateGStreamer::didPassCORSAccessCheck declaration.
42118        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
42119        (webKitWebSrcStart): Passed CORS mode parameter to the streaming client. In case of CORS check failure, stop the resource loading.
42120        (webKitSrcPassedCORSAccessCheck): Return whether CORS access control check was done and successful.
42121        (StreamingClient::handleResponseReceived): Take a parameter to assign the CORS access control check result.
42122        (CachedResourceStreamingClient::CachedResourceStreamingClient): Updated setting of the ResourceLoaderOptions according CORS mode.
42123        (CachedResourceStreamingClient::responseReceived): Check CORS and pass result to handleResponseReceived.
42124        (ResourceHandleStreamingClient::didReceiveResponse): No CORS check.
42125        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.h: Added webKitSrcPassedCORSAccessCheck declaration.
42126
421272014-04-10  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
42128
42129        Move UseJSC.cmake back to CMakeLists.txt
42130        https://bugs.webkit.org/show_bug.cgi?id=130834
42131
42132        Reviewed by Csaba Osztrogonác.
42133
42134        No new tests required.
42135
42136        * CMakeLists.txt:
42137        * UseJSC.cmake: Removed.
42138
421392014-04-09  Commit Queue  <commit-queue@webkit.org>
42140
42141        Unreviewed, rolling out r167046.
42142        https://bugs.webkit.org/show_bug.cgi?id=131479
42143
42144        Caused 300+ failures on Mavericks WK1 tester (Requested by ap
42145        on #webkit).
42146
42147        Reverted changeset:
42148
42149        "Remove "System Font" from whitelisted DRT fonts and char
42150        width calculations"
42151        https://bugs.webkit.org/show_bug.cgi?id=131411
42152        http://trac.webkit.org/changeset/167046
42153
421542014-04-09  Jeremy Jones  <jeremyj@apple.com>
42155
42156        Fix build failure.
42157        https://bugs.webkit.org/show_bug.cgi?id=131473
42158
42159        Reviewed by Dan Bernstein.
42160
42161        Fix build failure.
42162
42163        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
42164        (mediaSelectionOptions):
42165
421662014-04-09  Enrica Casucci  <enrica@apple.com>
42167
42168        Unreviewed build fix after http://trac.webkit.org/changeset/167045
42169
42170        The file contained an invalid character.
42171
42172        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
42173        (WebVideoFullscreenInterfaceAVKit::enterFullscreen):
42174
421752014-04-09  Dean Jackson  <dino@apple.com>
42176
42177        [iOS] Media controls should resize as the user zooms
42178        https://bugs.webkit.org/show_bug.cgi?id=131322
42179
42180        Reviewed by Eric Carlson.
42181
42182        On iOS the media controls should remain the same size
42183        independent of user zoom. Have the HTMLMediaElement optionally
42184        register for updates in the page scale to apply an inverse
42185        scale.
42186
42187        * Modules/mediacontrols/MediaControlsHost.cpp: New exposed property that calls
42188        back into HTMLMediaElement::mediaControlsDependOnPageScaleFactor.
42189        (WebCore::MediaControlsHost::controlsDependOnPageScaleFactor):
42190        (WebCore::MediaControlsHost::setControlsDependOnPageScaleFactor):
42191        * Modules/mediacontrols/MediaControlsHost.h: Keep a reference to the actual
42192        controls from the JavaScript side so we can talk to it later.
42193        (WebCore::MediaControlsHost::controllerJSValue):
42194        (WebCore::MediaControlsHost::setControllerJSValue):
42195        * Modules/mediacontrols/MediaControlsHost.idl: Expose controlsDependOnPageScaleFactor.
42196
42197        * Modules/mediacontrols/mediaControlsiOS.css:
42198        (audio::-webkit-media-controls-panel): Specify the transform origin so that
42199        scaling will keep the controls pinned to the bottom left corner.
42200        (audio::-webkit-media-controls-start-playback-button): Update to the correct size
42201        and provide new artwork.
42202        (audio::-webkit-media-controls-start-playback-button.failed): New artwork.
42203        * Modules/mediacontrols/mediaControlsiOS.js:
42204        (ControllerIOS): Tell the host that these controls care about the page scale.
42205        (ControllerIOS.prototype.get pageScaleFactor): New getter.
42206        (ControllerIOS.prototype.set pageScaleFactor): When set, update the play button and the panel.
42207
42208        * html/HTMLMediaElement.cpp:
42209        (WebCore::HTMLMediaElement::ensureMediaControlsInjectedScript): Small naming cleanup.
42210        (setPageScaleFactorProperty): Static helper to set a JS property value.
42211        (WebCore::HTMLMediaElement::didAddUserAgentShadowRoot): Keep a reference to the controls object,
42212        and make sure to set the page scale factor on the controls.
42213        (WebCore::HTMLMediaElement::pageScaleFactorChanged): Implement the callback, telling
42214        the controls object that it needs to relayout.
42215
422162014-04-09  Antti Koivisto  <antti@apple.com>
42217
42218        Try to fix iOS build.
42219
42220        * platform/graphics/ca/mac/TileController.mm:
42221
422222014-04-09  Andy Estes  <aestes@apple.com>
42223
42224        REGRESSION (r165908): ~QuickLookHandle() tries to dereference a null ResourceHandle
42225        https://bugs.webkit.org/show_bug.cgi?id=131467
42226
42227        Reviewed by Tim Horton.
42228
42229        QuickLookHandle stored a ResourceHandle pointer in order to later
42230        retrive the URL of its firstRequest(), but after r165908 we no longer
42231        always have a ResourceHandle. Since firstRequest()'s URL is the only
42232        thing we need from ResourceHandle, store it directly rather than a
42233        ResourceHandle pointer. In the case where we create a QuickLookHandle
42234        from a ResourceLoader rather than a ResourceHandle, pass the loader's
42235        originalRequest(), which represents the same request as firstRequest()
42236        (i.e. the request after willSendRequest() but before redirects).
42237
42238        * platform/network/ios/QuickLook.h:
42239        * platform/network/ios/QuickLook.mm:
42240        (WebCore::QuickLookHandle::QuickLookHandle):
42241        (WebCore::QuickLookHandle::create):
42242        (WebCore::QuickLookHandle::didFail):
42243        (WebCore::QuickLookHandle::~QuickLookHandle):
42244
422452014-04-09  James Craig  <jcraig@apple.com>
42246
42247        AX: Bug in AccessibilityNodeObject::helpText
42248        https://bugs.webkit.org/show_bug.cgi?id=130386
42249
42250        Reviewed by Chris Fleizach.
42251
42252        Test: accessibility/help-text.html
42253
42254        Ancestor loop was always checking attribute of original node rather than current node.
42255
42256        * accessibility/AccessibilityNodeObject.cpp:
42257        (WebCore::AccessibilityNodeObject::helpText):
42258
422592014-04-09  Chris Fleizach  <cfleizach@apple.com>
42260
42261        Regression: AX: list heuristics sometimes determined as presentational even when explicit roles applied
42262        https://bugs.webkit.org/show_bug.cgi?id=131041
42263
42264        Reviewed by Mario Sanchez Prada.
42265
42266        When display:table is used on a list item, it inserts RenderObjects that can be ignored as the children
42267        of the list. This allows normal list heuristics to be applied.
42268
42269        * accessibility/AccessibilityTableCell.cpp:
42270        (WebCore::AccessibilityTableCell::computeAccessibilityIsIgnored):
42271
422722014-04-09  Antti Koivisto  <antti@apple.com>
42273
42274        TileGrid should be PlatformCALayerClient instead of TileController
42275        https://bugs.webkit.org/show_bug.cgi?id=131456
42276        
42277        Switch one more place to use removeTiles.
42278
42279        * platform/graphics/ca/mac/TileGrid.mm:
42280        (WebCore::TileGrid::revalidateTiles):
42281
422822014-04-09  Myles C. Maxfield  <mmaxfield@apple.com>
42283
42284        Remove "System Font" from whitelisted DRT fonts and char width calculations
42285        https://bugs.webkit.org/show_bug.cgi?id=131411
42286
42287        Reviewed by Tim Horton.
42288
42289        Covered by existing tests.
42290
42291        * platform/graphics/Font.cpp:
42292        (WebCore::Font::hasValidAverageCharWidth):
42293
422942014-04-09  Jeremy Jones  <jeremyj@apple.com>
42295
42296        Fullscreen does two view controller changes at once
42297        https://bugs.webkit.org/show_bug.cgi?id=131432
42298
42299        Reviewed by Eric Carlson.
42300
42301        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
42302        (WebVideoFullscreenInterfaceAVKit::enterFullscreen):
42303        delay -presentViewController on the main run loop to allow
42304        previous view controller change to complete.
42305
423062014-04-09  Jeremy Jones  <jeremyj@apple.com>
42307
42308        Enable fullscreen captions selection
42309        https://bugs.webkit.org/show_bug.cgi?id=131069
42310
42311        Reviewed by Eric Carlson.
42312
42313        Enable media selection options from fullscreen. i.e. captions.
42314
42315        * WebCore.exp.in:
42316        Add exports for 
42317        setAudioMediaSelectionOptions
42318        setLegibleMediaSelectionOptions
42319        selectAudioMediaOption
42320        selectLegibleMediaOption
42321
42322        * platform/ios/WebVideoFullscreenInterface.h:
42323        Add setAudioMediaSelectionOptions/setLegibleMediaSelectionOptions
42324
42325        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
42326        Add setAudioMediaSelectionOptions/setLegibleMediaSelectionOptions
42327
42328        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
42329        Add setAudioMediaSelectionOptions/setLegibleMediaSelectionOptions
42330
42331        (-[WebAVPlayerController dealloc]):
42332        (-[WebAVPlayerController hasMediaSelectionOptions]):
42333        (+[WebAVPlayerController keyPathsForValuesAffectingHasMediaSelectionOptions]):
42334        (-[WebAVPlayerController hasAudioMediaSelectionOptions]):
42335        (+[WebAVPlayerController keyPathsForValuesAffectingHasAudioMediaSelectionOptions]):
42336        (-[WebAVPlayerController hasLegibleMediaSelectionOptions]):
42337        (+[WebAVPlayerController keyPathsForValuesAffectingHasLegibleMediaSelectionOptions]):
42338        (-[WebAVPlayerController currentAudioMediaSelectionOption]):
42339        (-[WebAVPlayerController setCurrentAudioMediaSelectionOption:]):
42340        (-[WebAVPlayerController currentLegibleMediaSelectionOption]):
42341        (-[WebAVPlayerController setCurrentLegibleMediaSelectionOption:]):
42342        (WebVideoFullscreenInterfaceAVKit::setAudioMediaSelectionOptions):
42343        (WebVideoFullscreenInterfaceAVKit::setLegibleMediaSelectionOptions):
42344        * platform/ios/WebVideoFullscreenModel.h:
42345        Add selectAudioMediaOption/selectLegibleMediaOption
42346
42347        * platform/ios/WebVideoFullscreenModelMediaElement.h:
42348        Add selectAudioMediaOption/selectLegibleMediaOption
42349
42350        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
42351        Add selectAudioMediaOption/selectLegibleMediaOption
42352
42353        (WebVideoFullscreenModelMediaElement::setMediaElement):
42354        Send initial media selection options.
42355
42356        (WebVideoFullscreenModelMediaElement::selectAudioMediaOption):
42357        Will be implemented when audio track slection is implemented.
42358
42359        (WebVideoFullscreenModelMediaElement::selectLegibleMediaOption):
42360        Select corresponding text track on HTMLMediaElement.
42361
423622014-04-09  Antti Koivisto  <antti@apple.com>
42363
42364        TileGrid should be PlatformCALayerClient instead of TileController
42365        https://bugs.webkit.org/show_bug.cgi?id=131456
42366
42367        Reviewed by Tim Horton.
42368
42369        The client interface is for the tiles in the grid.
42370
42371        * platform/graphics/ca/mac/TileController.h:
42372        * platform/graphics/ca/mac/TileController.mm:
42373        (WebCore::TileController::setContentsScale):
42374        (WebCore::TileController::createTileLayer):
42375        (WebCore::TileController::platformCALayerPaintContents): Deleted.
42376        (WebCore::TileController::platformCALayerDeviceScaleFactor): Deleted.
42377        (WebCore::TileController::platformCALayerShowDebugBorders): Deleted.
42378        (WebCore::TileController::platformCALayerShowRepaintCounter): Deleted.
42379        (WebCore::TileController::platformCALayerIncrementRepaintCount): Deleted.
42380        * platform/graphics/ca/mac/TileGrid.h:
42381        
42382            Move repaint counter to TileGrid too.
42383
42384        * platform/graphics/ca/mac/TileGrid.mm:
42385        (WebCore::TileGrid::removeTiles):
42386        (WebCore::TileGrid::removeAllSecondaryTiles):
42387        (WebCore::TileGrid::removeTilesInCohort):
42388        
42389           Cleaned up tile removal.
42390
42391        (WebCore::TileGrid::revalidateTiles):
42392        (WebCore::TileGrid::ensureTilesForRect):
42393        (WebCore::TileGrid::platformCALayerPaintContents):
42394        (WebCore::TileGrid::platformCALayerDeviceScaleFactor):
42395        (WebCore::TileGrid::platformCALayerShowDebugBorders):
42396        (WebCore::TileGrid::platformCALayerShowRepaintCounter):
42397        (WebCore::TileGrid::platformCALayerContentsOpaque):
42398        (WebCore::TileGrid::platformCALayerIncrementRepaintCount):
42399        (WebCore::queueTileForRemoval): Deleted.
42400
424012014-04-09  Alexey Proskuryakov  <ap@apple.com>
42402
42403        Rename some dragging functions
42404        https://bugs.webkit.org/show_bug.cgi?id=131460
42405
42406        Reviewed by Tim Horton.
42407
42408        Renamed performDrag to performDragOperation. This function is responsible for
42409        accepting a drop, not for the whole drag.
42410
42411        The new name is not perfect either, but I think that it's better, and at least
42412        it matches AppKit, like the other dragging destination functions already do.
42413
42414        * WebCore.exp.in:
42415        * page/DragController.cpp:
42416        (WebCore::DragController::performDragOperation):
42417        (WebCore::DragController::performDrag): Deleted.
42418        * page/DragController.h:
42419
424202014-04-08  Samuel White  <samuel_white@apple.com>
42421
42422        AX: Initial text selection point should respect element focus.
42423        https://bugs.webkit.org/show_bug.cgi?id=131402
42424
42425        Reviewed by Chris Fleizach.
42426
42427        Support the case where we want to set the initial selection and there's already a focused element.
42428
42429        No new tests, updated existing selection-initial to test this functionality.
42430
42431        * page/EventHandler.cpp:
42432        (WebCore::setKeyboardSelection):
42433        (WebCore::handleKeyboardSelectionMovement):
42434
424352014-04-09  Ryosuke Niwa  <rniwa@webkit.org>
42436
42437        HTMLCollection::updateNamedElementCach iterates over items twice
42438        https://bugs.webkit.org/show_bug.cgi?id=131448
42439
42440        Reviewed by Andreas Kling.
42441
42442        Compute the length first and go through the cache interface to traverse through items.
42443
42444        * html/HTMLCollection.cpp:
42445        (WebCore::HTMLCollection::updateNamedElementCache):
42446
424472014-04-09  Brendan Long  <b.long@cablelabs.com>
42448
42449        [GStreamer] Expose MPEG-TS metadata
42450        https://bugs.webkit.org/show_bug.cgi?id=122001
42451
42452        Reviewed by Eric Carlson.
42453
42454        Test: media/track/in-band/track-in-band-mpegts-metadata.html
42455
42456        * CMakeLists.txt: Add InbandDataTextTrack.
42457        * PlatformGTK.cmake: Look for gstreamer-mpegts and use it if available.
42458        * WebCore.vcxproj/WebCore.vcxproj: Add InbandDataTextTrack.
42459        * WebCore.vcxproj/WebCore.vcxproj.filters: Same.
42460        * WebCore.xcodeproj/project.pbxproj: Same.
42461        * html/track/DataCue.cpp:
42462        (WebCore::DataCue::DataCue): Add a constructor using raw data.
42463        * html/track/DataCue.h:
42464        (WebCore::DataCue::create): Same.
42465        * html/track/InbandDataTextTrack.cpp: Added, InbandTextTrack which implements addDataCue().
42466        * html/track/InbandDataTextTrack.h:
42467        * html/track/InbandGenericTextTrack.h: Move unimplemented methods to InbandTextTrack.
42468        * html/track/InbandWebVTTTextTrack.h: Same.
42469        * html/track/InbandTextTrack.h: Same, and add inBandMetadataTrackDispatchType.
42470        * html/track/InbandTextTrack.cpp:
42471        (WebCore::InbandTextTrack::create): Add constructor for InbandDataTextTrack.
42472        (WebCore::InbandTextTrack::inBandMetadataTrackDispatchType): Added.
42473        * html/track/TextTrack.h:
42474        (WebCore::TextTrack::inBandMetadataTrackDispatchType): Added (empty).
42475        * html/track/TextTrack.idl: Add inBandMetadataTrackDispatchType.
42476        * platform/graphics/InbandTextTrackPrivate.h: Add inBandMetadataTrackDispatchType and Data format.
42477        (WebCore::InbandTextTrackPrivate::inBandMetadataTrackDispatchType):
42478        * platform/graphics/InbandTextTrackPrivateClient.h: Add addDataCue() method.
42479        * platform/graphics/gstreamer/InbandMetadataTextTrackPrivateGStreamer.h:
42480        (WebCore::InbandMetadataTextTrackPrivateGStreamer::create): Allow specifying the cue format and id.
42481         (WebCore::InbandMetadataTextTrackPrivateGStreamer::InbandMetadataTextTrackPrivateGStreamer): Same.
42482        (WebCore::InbandMetadataTextTrackPrivateGStreamer::setInBandMetadataTrackDispatchType): Added.
42483        (WebCore::InbandMetadataTextTrackPrivateGStreamer::addDataCue): Added.
42484        (WebCore::InbandMetadataTextTrackPrivateGStreamer::addGenericCue): Added.
42485        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
42486        (WebCore::MediaPlayerPrivateGStreamer::handleMessage): Check for MPEG-TS sections.
42487        (WebCore::MediaPlayerPrivateGStreamer::processMpegTsSection): Add MPEG-TS section metadata, and get inBandMetadataTrackDispatchType from the PMT.
42488        (WebCore::MediaPlayerPrivateGStreamer::processTableOfContents): Explicitly use Generic CueFormat.
42489        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
42490
424912014-04-08  Chris Fleizach  <cfleizach@apple.com>
42492
42493        AX: Make AXPress much more reliable on the Web
42494        https://bugs.webkit.org/show_bug.cgi?id=131426
42495
42496        Reviewed by Mario Sanchez Prada.
42497
42498        AXPress fails when an event handler is on a node higher in the parent chain than the focused node.
42499
42500        We need to make AXPress more reliable by 
42501            1) Using the element that is focused as the target of the event
42502            2) Search for the inner most control object when dispatching the event
42503
42504        Updated existing accessibility/press-works-on-control-types.html
42505
42506        * accessibility/AccessibilityMenuList.cpp:
42507        (WebCore::AccessibilityMenuList::press):
42508        * accessibility/AccessibilityMenuList.h:
42509        * accessibility/AccessibilityMenuListPopup.cpp:
42510        (WebCore::AccessibilityMenuListPopup::press):
42511        * accessibility/AccessibilityMenuListPopup.h:
42512        * accessibility/AccessibilityObject.cpp:
42513        (WebCore::AccessibilityObject::press):
42514        * accessibility/AccessibilityObject.h:
42515        (WebCore::AccessibilityObject::performDefaultAction):
42516        * accessibility/AccessibilitySearchFieldButtons.cpp:
42517        (WebCore::AccessibilitySearchFieldCancelButton::press):
42518        * accessibility/AccessibilitySearchFieldButtons.h:
42519        * accessibility/AccessibilitySpinButton.cpp:
42520        (WebCore::AccessibilitySpinButtonPart::press):
42521        * accessibility/AccessibilitySpinButton.h:
42522
425232014-04-09  Brady Eidson  <beidson@apple.com>
42524
42525        ContentFilterMac is broken when NE_FILTER_SOURCE is enabled.
42526        <rdar://problem/15978793> and https://bugs.webkit.org/show_bug.cgi?id=131445
42527
42528        Reviewed by Andy Estes.
42529
42530        No new tests (Not a tested feature).
42531
42532        * platform/mac/ContentFilterMac.mm:
42533        (WebCore::ContentFilter::needsMoreData): Only consider m_neFilterSourceStatus if m_neFilterSource exists.
42534        (WebCore::ContentFilter::didBlockData): Ditto.
42535
425362014-04-08  Oliver Hunt  <oliver@apple.com>
42537
42538        Rewrite Function.bind as a builtin
42539        https://bugs.webkit.org/show_bug.cgi?id=131083
42540
42541        Reviewed by Geoffrey Garen.
42542
42543        Switch WebCore to use the helper functions when defining the
42544        prototype properties on DOM constructors, and update bindings
42545        tests accordingly.
42546
42547        * bindings/js/JSImageConstructor.cpp:
42548        (WebCore::JSImageConstructor::finishCreation):
42549        * bindings/scripts/CodeGeneratorJS.pm:
42550        (GenerateConstructorHelperMethods):
42551        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
42552        (WebCore::JSTestActiveDOMObjectConstructor::finishCreation):
42553        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
42554        (WebCore::JSTestCustomNamedGetterConstructor::finishCreation):
42555        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
42556        (WebCore::JSTestEventConstructorConstructor::finishCreation):
42557        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
42558        (WebCore::JSTestEventTargetConstructor::finishCreation):
42559        * bindings/scripts/test/JS/JSTestException.cpp:
42560        (WebCore::JSTestExceptionConstructor::finishCreation):
42561        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
42562        (WebCore::JSTestGenerateIsReachableConstructor::finishCreation):
42563        * bindings/scripts/test/JS/JSTestInterface.cpp:
42564        (WebCore::JSTestInterfaceConstructor::finishCreation):
42565        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
42566        (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation):
42567        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
42568        (WebCore::JSTestNamedConstructorConstructor::finishCreation):
42569        (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation):
42570        * bindings/scripts/test/JS/JSTestNode.cpp:
42571        (WebCore::JSTestNodeConstructor::finishCreation):
42572        * bindings/scripts/test/JS/JSTestObj.cpp:
42573        (WebCore::JSTestObjConstructor::finishCreation):
42574        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
42575        (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
42576        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
42577        (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation):
42578        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
42579        (WebCore::JSTestTypedefsConstructor::finishCreation):
42580        * bindings/scripts/test/JS/JSattribute.cpp:
42581        (WebCore::JSattributeConstructor::finishCreation):
42582        * bindings/scripts/test/JS/JSreadonly.cpp:
42583        (WebCore::JSreadonlyConstructor::finishCreation):
42584
425852014-04-09  Enrica Casucci  <enrica@apple.com>
42586
42587        Unreviewed iOS build fix. Replacing deprecated enum with AVPlayerViewControllerExitFullScreenReason.
42588
42589        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
42590        (-[WebAVPlayerController playerViewController:shouldDismissWithReason:]):
42591
425922014-04-09  Radu Stavila  <stavila@adobe.com>
42593
42594        [CSS Regions] Monolithic elements should not affect the layout of the content outside its region
42595        https://bugs.webkit.org/show_bug.cgi?id=130499
42596
42597        Reviewed by David Hyatt.
42598
42599        When performing layout on an element flowed into regions, its logical height must not be incremented 
42600        past the region's logical bottom for monolithic elements in regions different than the last region their containing
42601        block is fragmented into. This ensures that the following elements are correctly laid out 
42602        from the top of the next region.
42603        This change must also be applied to floats in order to prevent text from avoiding part
42604        of a float that did not actually made it into the current region, but instead overflowed
42605        the previous one.
42606
42607        Tests: fast/regions/fragmentation-after-float-overflow-single-region.html
42608               fast/regions/fragmentation-after-monolithic-overflow-self-collapsed.html
42609               fast/regions/fragmentation-after-monolithic-overflow-single-region.html
42610               fast/regions/fragmentation-after-monolithic-overflow.html
42611
42612        * rendering/FloatingObjects.cpp:
42613        (WebCore::FloatingObjects::computePlacedFloatsTree):
42614        * rendering/RenderBlockFlow.cpp:
42615        (WebCore::RenderBlockFlow::layoutBlockChild):
42616        (WebCore::RenderBlockFlow::adjustBlockChildForPagination):
42617        (WebCore::RenderBlockFlow::lowestFloatLogicalBottom):
42618        (WebCore::RenderBlockFlow::getClearDelta):
42619        (WebCore::RenderBlockFlow::applyAfterBreak): Deleted.
42620        (WebCore::RenderBlockFlow::nextFloatLogicalBottomBelow): Deleted.
42621        (WebCore::RenderBlockFlow::nextFloatLogicalBottomBelowForBlock): Deleted.
42622        (WebCore::RenderBlockFlow::flipFloatForWritingModeForChild): Deleted.
42623        * rendering/RenderBlockFlow.h:
42624        * rendering/RenderFlowThread.cpp:
42625        (WebCore::RenderFlowThread::isBoxInDifferentRegionsAsFloat):
42626        * rendering/RenderFlowThread.h:
42627
426282014-04-09  Anders Carlsson  <andersca@apple.com>
42629
42630        Use std::array in AffineTransform, and get rid of setMatrix
42631        https://bugs.webkit.org/show_bug.cgi?id=131416
42632
42633        Reviewed by Sam Weinig.
42634
42635        * platform/graphics/transforms/AffineTransform.cpp:
42636        (WebCore::AffineTransform::AffineTransform):
42637        (WebCore::AffineTransform::multiply):
42638        * platform/graphics/transforms/AffineTransform.h:
42639        (WebCore::AffineTransform::setMatrix): Deleted.
42640
426412014-04-09  Carlos Garcia Campos  <cgarcia@igalia.com>
42642
42643        [GTK] Plugin process crashes when loading totem plugin
42644        https://bugs.webkit.org/show_bug.cgi?id=131357
42645
42646        Reviewed by Martin Robinson.
42647
42648        Remove netscape plugin implementation from WebCore that was only
42649        used by WebKit1. This removes the conflict between the WebCore NPN
42650        symbols and the ones used by the plugins.
42651
42652        * CMakeLists.txt:
42653        * PlatformEfl.cmake:
42654        * PlatformGTK.cmake:
42655        * PlatformWin.cmake:
42656        * plugins/PluginViewNone.cpp:
42657        * plugins/gtk/PluginPackageGtk.cpp: Removed.
42658        * plugins/gtk/PluginViewGtk.cpp: Removed.
42659        * plugins/gtk/gtk2xtbin.c: Removed.
42660        * plugins/gtk/gtk2xtbin.h: Removed.
42661        * plugins/gtk/xembed.h: Removed.
42662
426632014-04-09  Jeremy Jones  <jeremyj@apple.com>
42664
42665        fullscreen controls first show a play button instead of a pause button
42666        https://bugs.webkit.org/show_bug.cgi?id=131430
42667
42668        Reviewed by Jer Noble.
42669
42670        isPlaying() is false while buffering, paused() isn't; use paused() for
42671        the play button.
42672
42673        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
42674        (WebVideoFullscreenModelMediaElement::setMediaElement):
42675        (WebVideoFullscreenModelMediaElement::handleEvent):
42676        Use HTMLMediaElement::paused() instead of HTMLMediaElement::isPlaying()
42677
426782014-04-09  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
42679
42680        Remove duplicated files and unnecessary conditions from UseJSC.cmake
42681        https://bugs.webkit.org/show_bug.cgi?id=131438
42682
42683        Reviewed by Csaba Osztrogonác.
42684
42685        No new tests required.
42686
42687        * UseJSC.cmake:
42688
426892014-04-09  Mario Sanchez Prada  <mario.prada@samsung.com>
42690
42691        [GTK] Layout tests accessibility/children-changed-sends-notification.html and accessibility/notification-listeners.html fails
42692        https://bugs.webkit.org/show_bug.cgi?id=131380
42693
42694        Reviewed by Chris Fleizach.
42695
42696        Don't emit signals for added objects that we know won't be exposed
42697        to the accessibility hierarchy (e.g. static text).
42698
42699        * accessibility/atk/AXObjectCacheAtk.cpp:
42700        (WebCore::AXObjectCache::attachWrapper): Add extra check and early return.
42701
427022014-04-09  Mario Sanchez Prada  <mario.prada@samsung.com>
42703
42704        [AX][GTK] No new lines in some AX tests output
42705        https://bugs.webkit.org/show_bug.cgi?id=131294
42706
42707        Reviewed by Martin Robinson.
42708
42709        Do not implement Hypetext or AtkText for the WebArea. Those
42710        interfaces will be implemented by the containers (automatically
42711        generated or not) for the different parts of the DOM and the
42712        render subtree under this element anyway.
42713
42714        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
42715        (getInterfaceMaskFromObject): Make sure we don't apply
42716        WAIHypertext nor WAIText to objects with role WebAreaRole.
42717
427182014-04-08  Conrad Shultz  <conrad_shultz@apple.com>
42719
42720        nil should only be used for objects
42721        https://bugs.webkit.org/show_bug.cgi?id=131431
42722
42723        Reviewed by Chris Fleizach.
42724
42725        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
42726        (-[WebAccessibilityObjectWrapper accessibilityIsAttributeSettable:]):
42727        nil -> NO.
42728
42729        * platform/mac/WebVideoFullscreenController.mm:
42730        (-[WebVideoFullscreenController setMediaElement:]):
42731        nil -> 0; change a NULL to nullptr while we're here.
42732
427332014-04-08  Mihnea Ovidenie  <mihnea@adobe.com>
42734
42735        [CSSRegions] Crash when video in region exits fullscreen
42736        https://bugs.webkit.org/show_bug.cgi?id=131366
42737
42738        Reviewed by Andrei Bucur.
42739
42740        After fix for https://bugs.webkit.org/show_bug.cgi?id=130392, we compute the region ranges
42741        information for inline elements collected in named flows with associated region chains.
42742        The algorithm for this computation, implemented in RenderFlowThread::getRegionRangeForBox,
42743        walks up the render tree trying to find the top-most unsplittable box under the named flow
42744        in the case where the region ranges information is not available.
42745
42746        As this traversal works properly only when the starting box is not detached from the render tree,
42747        i changed the named flow information clearing in RenderBlock::collapseAnonymousBoxChild
42748        to occur before the child to be collapsed is removed from the render tree.
42749
42750        Test: fast/regions/full-screen-video-in-region-crash.html
42751
42752        * rendering/RenderBlock.cpp:
42753        (WebCore::RenderBlock::collapseAnonymousBoxChild):
42754        * rendering/RenderFlowThread.cpp:
42755        (WebCore::RenderFlowThread::getRegionRangeForBox):
42756
427572014-04-08  Chris Fleizach  <cfleizach@apple.com>
42758
42759        Unreviewed build fix for iOS (redux).
42760
42761        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
42762        (-[WebAccessibilityObjectWrapper accessibilityARIAIsBusy]):
42763        (-[WebAccessibilityObjectWrapper accessibilityARIALiveRegionIsAtomic]):
42764
427652014-04-08  Chris Fleizach  <cfleizach@apple.com>
42766 
42767        Unreviewed build fix for iOS.
42768
42769        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
42770        (-[WebAccessibilityObjectWrapper accessibilityElementCount]):
42771
427722014-04-08  Antti Koivisto  <antti@apple.com>
42773
42774        Factor tile coverage map into a class
42775        https://bugs.webkit.org/show_bug.cgi?id=131417
42776
42777        Reviewed by Tim Horton.
42778
42779        * WebCore.xcodeproj/project.pbxproj:
42780        * platform/graphics/ca/PlatformCALayerClient.h:
42781        (WebCore::PlatformCALayerClient::platformCALayerLayoutSublayersOfLayer):
42782        (WebCore::PlatformCALayerClient::platformCALayerRespondsToLayoutChanges):
42783        (WebCore::PlatformCALayerClient::platformCALayerAnimationStarted):
42784        (WebCore::PlatformCALayerClient::platformCALayerContentsOrientation):
42785        (WebCore::PlatformCALayerClient::platformCALayerShowDebugBorders):
42786        (WebCore::PlatformCALayerClient::platformCALayerShowRepaintCounter):
42787        (WebCore::PlatformCALayerClient::platformCALayerIncrementRepaintCount):
42788        (WebCore::PlatformCALayerClient::platformCALayerLayerDidDisplay):
42789        
42790            Added default implementation to some of these to make clients less messy.
42791
42792        * platform/graphics/ca/mac/TileController.h:
42793        * platform/graphics/ca/mac/TileController.mm:
42794        (WebCore::TileController::~TileController):
42795        (WebCore::TileController::platformCALayerPaintContents):
42796        (WebCore::TileController::setTiledScrollingIndicatorPosition):
42797        (WebCore::TileController::updateTileCoverageMap):
42798        (WebCore::TileController::tiledScrollingIndicatorLayer):
42799        * platform/graphics/ca/mac/TileCoverageMap.h: Added.
42800        (WebCore::TileCoverageMap::setPosition):
42801        (WebCore::TileCoverageMap::layer):
42802        * platform/graphics/ca/mac/TileCoverageMap.mm: Added.
42803        
42804            The new class.
42805
42806        (WebCore::TileCoverageMap::TileCoverageMap):
42807        (WebCore::TileCoverageMap::~TileCoverageMap):
42808        (WebCore::TileCoverageMap::update):
42809        (WebCore::TileCoverageMap::platformCALayerPaintContents):
42810        (WebCore::TileCoverageMap::platformCALayerDeviceScaleFactor):
42811        * platform/graphics/ca/mac/TileGrid.h:
42812        * platform/graphics/ca/mac/TileGrid.mm:
42813        (WebCore::TileGrid::drawTileMapContents):
42814
428152014-04-08  Zalan Bujtas  <zalan@apple.com>
42816
42817        Subpixel rendering: Clip outer rounded border rect on device pixel boundaries.
42818        https://bugs.webkit.org/show_bug.cgi?id=131404
42819
42820        Reviewed by Simon Fraser.
42821
42822        Use device pixel snapped rectangle to clip out rounded rects, when not all sides are solid/double.
42823        Snapping it to device pixel boundaries ensures that when we call drawRect(devicePixelSnappedRect) later,
42824        it leaves no cruft behind.
42825
42826        Test: fast/borders/hidpi-rounded-border-on-subpixel-position.html
42827
42828        * rendering/RenderBoxModelObject.cpp:
42829        (WebCore::RenderBoxModelObject::paintBorder):
42830
428312014-04-08  Jon Lee  <jonlee@apple.com>
42832
42833        Turn MSE on by default
42834        https://bugs.webkit.org/show_bug.cgi?id=131313
42835        <rdar://problem/16525223>
42836
42837        Reviewed by Jer Noble.
42838
42839        * Configurations/FeatureDefines.xcconfig:
42840        * page/Settings.in: Add MEDIA_SOURCE conditional.
42841
428422014-04-08  Anders Carlsson  <andersca@apple.com>
42843
42844        Remove an unused parameter from loadResource.
42845
42846        Reviewed by Darin Adler.
42847
42848        Since the CachedResourceRequest has the charset in it, we don't need to pass it separately to loadRequest.
42849
42850        * loader/cache/CachedResourceLoader.cpp:
42851        (WebCore::CachedResourceLoader::requestResource):
42852        (WebCore::CachedResourceLoader::loadResource):
42853        * loader/cache/CachedResourceLoader.h:
42854
428552014-04-08  Ryuan Choi  <ryuan.choi@samsung.com>
42856
42857        Unreviewed EFL build fix attempt since r166956
42858
42859        * page/efl/DragControllerEfl.cpp: Rename Clipboard to DataTransfer.
42860        (WebCore::DragController::declareAndWriteDragImage):
42861
428622014-04-08  Simon Fraser  <simon.fraser@apple.com>
42863
42864        REGRESSION (r155998): Elements render at very low resolution with some 3d transforms
42865        https://bugs.webkit.org/show_bug.cgi?id=131412
42866        <rdar://problem/16525044>
42867
42868        Reviewed by Tim Horton.
42869        
42870        In r155998 we started to compute a root-relative transform in order to choose
42871        a good contentsScale to avoid blurring on scaling.
42872        
42873        However, the code failed to update this transform when passing over
42874        GraphicsLayerCAs with no uncommitted changes, which caused us to choose
42875        an incorrect contentsScale sometimes, resulting in blurriness.
42876        
42877        Fix by updating the root-relative transform on layers with no uncommitted
42878        changes.
42879
42880        Test: compositing/contents-scale/incremental-change.html
42881
42882        * platform/graphics/ca/GraphicsLayerCA.cpp:
42883        (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
42884
428852014-04-08  Anders Carlsson  <andersca@apple.com>
42886
42887        Don't call CGPathAddPath with invalid CGAffineTransform objects
42888        https://bugs.webkit.org/show_bug.cgi?id=131413
42889        <rdar://problem/16399645>
42890
42891        Reviewed by Darin Adler.
42892
42893        Covered by existing tests.
42894
42895        * platform/graphics/cg/PathCG.cpp:
42896        (WebCore::Path::addPath):
42897        Don't try to add the path if the affine transform isn't invertible.
42898
42899        * platform/graphics/transforms/AffineTransform.cpp:
42900        (WebCore::AffineTransform::isInvertible):
42901        Handle infinite and NaN determinants.
42902
42903        (WebCore::AffineTransform::inverse):
42904        Handle infinite and NaN determinants.
42905
429062014-04-08  Brian J. Burg  <burg@cs.washington.edu>
42907
42908        Web Replay: memoize nondeterministic attributes of the Screen interface
42909        https://bugs.webkit.org/show_bug.cgi?id=131339
42910
42911        Reviewed by Timothy Hatcher.
42912
42913        The values from the screen interface are nondeterministic. Since we can't
42914        change the physical screen dimensions, instead memoize values of attributes.
42915
42916        Test: ManualTests/inspector/replay-window-screen.html
42917
42918        * page/Screen.idl: Add Nondeterministic attribute.
42919
429202014-04-08  Beth Dakin  <bdakin@apple.com>
42921
42922        https://bugs.webkit.org/show_bug.cgi?id=131408
42923        Scrollbars layers don't dynamically update when device scale factor changes
42924        -and corresponding-
42925        <rdar://problem/16503875>
42926
42927        Reviewed by Tim Horton.
42928
42929        The scrollbar layers are not children of the RenderView's layer, so they were 
42930        completely skipped over by this function before. We need to start this higher up 
42931        the tree in the rootGraphicsLayer(), which will typically return the 
42932        m_overflowControlsHostLayer.
42933        * rendering/RenderLayerCompositor.cpp:
42934        (WebCore::RenderLayerCompositor::deviceOrPageScaleFactorChanged):
42935
429362014-04-08  Ryosuke Niwa  <rniwa@webkit.org>
42937
42938        HTMLConverter::aggregatedAttributesForAncestors should cache intermediate results
42939        https://bugs.webkit.org/show_bug.cgi?id=131400
42940
42941        Reviewed by Sam Weinig.
42942
42943        Instead of accumulating attributes from a character node to the highest ancestor,
42944        recursively call aggregatedAttributesForElementAndItsAncestors so that aggregated
42945        attributes are cached on each ancestor to eliminate the old O(n^2) behavior.
42946
42947        * editing/cocoa/HTMLConverter.mm:
42948        (HTMLConverter::aggregatedAttributesForAncestors):
42949        (HTMLConverter::aggregatedAttributesForElementAndItsAncestors): Extracted from aggregatedAttributesForAncestors.
42950
429512014-04-08  Jinwoo Song  <jinwoo7.song@samsung.com>
42952
42953        Unreviewed CMake build fix after r166965.
42954
42955        * UseJSC.cmake: Rename JSClipboardCustom.cpp to JSDataTransferCustom.cpp.
42956
429572014-04-08  Enrica Casucci  <enrica@apple.com>
42958
42959        Unreviewed iOS build fix.
42960
42961        Return false instead of nil in a function that returns BOOL.
42962
42963        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
42964        (-[WebAccessibilityObjectWrapper accessibilityCanFuzzyHitTest]):
42965
429662014-04-08  Brady Eidson  <beidson@apple.com>
42967
42968        Non-empty ranges misdetected as empty ranges, avoiding telephone number detection.
42969        <rdar://problem/16553441> and https://bugs.webkit.org/show_bug.cgi?id=131397 
42970
42971        Reviewed by Tim Horton.
42972
42973        No new tests (Only affects a currently untested Mac-only WK2 feature)
42974
42975        * editing/Editor.cpp:
42976        (WebCore::Editor::scanSelectionForTelephoneNumbers): Fix detection of empty ranges so we don’t
42977          early return erroneously.
42978
429792014-04-08  Adenilson Cavalcanti  <cavalcantii@gmail.com>
42980
42981        [SVG] Fix CSS transform handling when zoomed
42982        https://bugs.webkit.org/show_bug.cgi?id=125836
42983
42984        Reviewed by Tim Horton.
42985
42986        Tests: svg/zoom/page/zoom-css-transforms-expected.svg
42987               svg/zoom/page/zoom-css-transforms.svg
42988
42989        Adjusts CSS transforms when used in SVG to account for unexpected
42990        translation scale. Backport from Chromium #174910.
42991
42992        * svg/SVGGraphicsElement.cpp:
42993        (WebCore::SVGGraphicsElement::animatedLocalTransform):
42994
429952014-04-08  Hans Muller  <hmuller@adobe.com>
42996
42997        [CSS Shapes] large corner radius combined with 0 radius does not wrap properly
42998        https://bugs.webkit.org/show_bug.cgi?id=129739
42999
43000        Reviewed by Bem Jones-Bey.
43001
43002        Corrected special case handling for shape-outside border-box values with border-radius
43003        values that greater than or equal to the box's height.
43004
43005        Tests: fast/shapes/shape-outside-floats/shape-outside-big-box-border-radius-001.html
43006               fast/shapes/shape-outside-floats/shape-outside-big-box-border-radius-002.html
43007
43008        * rendering/shapes/BoxShape.cpp:
43009        (WebCore::BoxShape::getExcludedIntervals):
43010
430112014-04-08  Alexey Proskuryakov  <ap@apple.com>
43012
43013        Rename Clipboard to DataTransfer
43014        https://bugs.webkit.org/show_bug.cgi?id=131371
43015
43016        Reviewed by Anders Carlsson.
43017
43018        This is the name used in HTML5, and it's much better than the confusing Clipboard one.
43019
43020        Renamed related enums too, and made DataTransferAccessPolicy an enum class.
43021
43022        * CMakeLists.txt:
43023        * Configurations/WebCore.xcconfig:
43024        * DerivedSources.cpp:
43025        * DerivedSources.make:
43026        * WebCore.exp.in:
43027        * WebCore.vcxproj/WebCore.vcxproj:
43028        * WebCore.vcxproj/WebCore.vcxproj.filters:
43029        * WebCore.xcodeproj/project.pbxproj:
43030        * bindings/js/JSBindingsAllInOne.cpp:
43031        * bindings/js/JSClipboardCustom.cpp: Removed.
43032        * bindings/js/JSDataTransferCustom.cpp: Copied from Source/WebCore/bindings/js/JSClipboardCustom.cpp.
43033        (WebCore::JSDataTransfer::types):
43034        (WebCore::JSClipboard::types): Deleted.
43035        * bindings/js/JSEventCustom.cpp:
43036        * dom/Clipboard.cpp: Removed.
43037        * dom/Clipboard.h: Removed.
43038        * dom/Clipboard.idl: Removed.
43039        * dom/ClipboardAccessPolicy.h: Removed.
43040        * dom/ClipboardEvent.cpp:
43041        (WebCore::ClipboardEvent::ClipboardEvent):
43042        * dom/ClipboardEvent.h:
43043        (WebCore::ClipboardEvent::create):
43044        (WebCore::ClipboardEvent::clipboard): Deleted.
43045        * dom/ClipboardMac.mm: Removed.
43046        * dom/DOMAllInOne.cpp:
43047        * dom/DataTransfer.cpp: Copied from Source/WebCore/dom/Clipboard.cpp.
43048        (WebCore::DataTransfer::DataTransfer):
43049        (WebCore::DataTransfer::createForCopyAndPaste):
43050        (WebCore::DataTransfer::~DataTransfer):
43051        (WebCore::DataTransfer::setAccessPolicy):
43052        (WebCore::DataTransfer::canReadTypes):
43053        (WebCore::DataTransfer::canReadData):
43054        (WebCore::DataTransfer::canWriteData):
43055        (WebCore::DataTransfer::clearData):
43056        (WebCore::DataTransfer::getData):
43057        (WebCore::DataTransfer::setData):
43058        (WebCore::DataTransfer::types):
43059        (WebCore::DataTransfer::files):
43060        (WebCore::DataTransfer::dropEffect):
43061        (WebCore::DataTransfer::setDropEffect):
43062        (WebCore::DataTransfer::effectAllowed):
43063        (WebCore::DataTransfer::setEffectAllowed):
43064        (WebCore::DataTransfer::setDragImage):
43065        (WebCore::DataTransfer::createForDragAndDrop):
43066        (WebCore::DataTransfer::canSetDragImage):
43067        (WebCore::DataTransfer::updateDragImage):
43068        (WebCore::DataTransfer::createDragImage):
43069        (WebCore::DragImageLoader::DragImageLoader):
43070        (WebCore::DragImageLoader::imageChanged):
43071        (WebCore::DataTransfer::sourceOperation):
43072        (WebCore::DataTransfer::destinationOperation):
43073        (WebCore::DataTransfer::setSourceOperation):
43074        (WebCore::DataTransfer::setDestinationOperation):
43075        (WebCore::Clipboard::Clipboard): Deleted.
43076        (WebCore::Clipboard::createForCopyAndPaste): Deleted.
43077        (WebCore::Clipboard::~Clipboard): Deleted.
43078        (WebCore::Clipboard::setAccessPolicy): Deleted.
43079        (WebCore::Clipboard::canReadTypes): Deleted.
43080        (WebCore::Clipboard::canReadData): Deleted.
43081        (WebCore::Clipboard::canWriteData): Deleted.
43082        (WebCore::Clipboard::clearData): Deleted.
43083        (WebCore::Clipboard::getData): Deleted.
43084        (WebCore::Clipboard::setData): Deleted.
43085        (WebCore::Clipboard::types): Deleted.
43086        (WebCore::Clipboard::files): Deleted.
43087        (WebCore::Clipboard::dropEffect): Deleted.
43088        (WebCore::Clipboard::setDropEffect): Deleted.
43089        (WebCore::Clipboard::effectAllowed): Deleted.
43090        (WebCore::Clipboard::setEffectAllowed): Deleted.
43091        (WebCore::Clipboard::setDragImage): Deleted.
43092        (WebCore::Clipboard::createForDragAndDrop): Deleted.
43093        (WebCore::Clipboard::canSetDragImage): Deleted.
43094        (WebCore::Clipboard::updateDragImage): Deleted.
43095        (WebCore::Clipboard::createDragImage): Deleted.
43096        (WebCore::Clipboard::sourceOperation): Deleted.
43097        (WebCore::Clipboard::destinationOperation): Deleted.
43098        (WebCore::Clipboard::setSourceOperation): Deleted.
43099        (WebCore::Clipboard::setDestinationOperation): Deleted.
43100        * dom/DataTransfer.h: Copied from Source/WebCore/dom/Clipboard.h.
43101        * dom/DataTransfer.idl: Copied from Source/WebCore/dom/Clipboard.idl.
43102        * dom/DataTransferAccessPolicy.h: Copied from Source/WebCore/dom/ClipboardAccessPolicy.h.
43103        * dom/DataTransferItemList.h:
43104        * dom/DataTransferMac.mm: Copied from Source/WebCore/dom/ClipboardMac.mm.
43105        (WebCore::DataTransfer::createDragImage):
43106        (WebCore::Clipboard::createDragImage): Deleted.
43107        * dom/Event.h:
43108        (WebCore::Event::clipboardData):
43109        (WebCore::Event::internalDataTransfer):
43110        (WebCore::Event::clipboard): Deleted.
43111        * dom/Event.idl:
43112        * dom/MouseEvent.cpp:
43113        (WebCore::MouseEvent::create):
43114        (WebCore::MouseEvent::MouseEvent):
43115        (WebCore::MouseEvent::initMouseEvent):
43116        * dom/MouseEvent.h:
43117        (WebCore::MouseEvent::dataTransfer):
43118        * dom/MouseEvent.idl:
43119        * dom/WheelEvent.cpp:
43120        * editing/Editor.cpp:
43121        (WebCore::Editor::canDHTMLCut):
43122        (WebCore::Editor::canDHTMLCopy):
43123        (WebCore::Editor::canDHTMLPaste):
43124        (WebCore::Editor::tryDHTMLCopy):
43125        (WebCore::Editor::tryDHTMLCut):
43126        (WebCore::Editor::tryDHTMLPaste):
43127        (WebCore::Editor::dispatchCPPEvent):
43128        (WebCore::Editor::performCutOrCopy):
43129        (WebCore::Editor::selectedTextForDataTransfer):
43130        (WebCore::Editor::selectedTextForClipboard): Deleted.
43131        * editing/Editor.h:
43132        * editing/ios/EditorIOS.mm:
43133        (WebCore::Editor::stringSelectionForPasteboardWithImageAltText):
43134        * editing/mac/EditorMac.mm:
43135        (WebCore::Editor::takeFindStringFromSelection):
43136        (WebCore::Editor::stringSelectionForPasteboardWithImageAltText):
43137        * loader/EmptyClients.h:
43138        * page/DragClient.h:
43139        * page/DragController.cpp:
43140        (WebCore::DragController::dragExited):
43141        (WebCore::DragController::performDrag):
43142        (WebCore::DragController::tryDHTMLDrag):
43143        (WebCore::DragController::startDrag):
43144        (WebCore::DragController::doImageDrag):
43145        (WebCore::DragController::doSystemDrag):
43146        * page/DragController.h:
43147        * page/DragState.h:
43148        * page/EventHandler.cpp:
43149        (WebCore::EventHandler::dispatchDragEvent):
43150        (WebCore::hasFileOfType):
43151        (WebCore::hasStringOfType):
43152        (WebCore::hasDropZoneType):
43153        (WebCore::findDropZone):
43154        (WebCore::EventHandler::updateDragAndDrop):
43155        (WebCore::EventHandler::cancelDragAndDrop):
43156        (WebCore::EventHandler::performDragAndDrop):
43157        (WebCore::EventHandler::freeDataTransfer):
43158        (WebCore::EventHandler::dragSourceEndedAt):
43159        (WebCore::EventHandler::dispatchDragSrcEvent):
43160        (WebCore::EventHandler::handleDrag):
43161        (WebCore::EventHandler::freeClipboard): Deleted.
43162        * page/EventHandler.h:
43163        * page/efl/EventHandlerEfl.cpp:
43164        (WebCore::EventHandler::createDraggingDataTransfer):
43165        (WebCore::EventHandler::createDraggingClipboard): Deleted.
43166        * page/gtk/DragControllerGtk.cpp:
43167        (WebCore::DragController::declareAndWriteDragImage):
43168        * page/gtk/EventHandlerGtk.cpp:
43169        (WebCore::EventHandler::createDraggingDataTransfer):
43170        (WebCore::EventHandler::createDraggingClipboard): Deleted.
43171        * page/mac/DragControllerMac.mm:
43172        (WebCore::DragController::declareAndWriteDragImage):
43173        * page/mac/EventHandlerMac.mm:
43174        (WebCore::EventHandler::createDraggingDataTransfer):
43175        (WebCore::EventHandler::createDraggingClipboard): Deleted.
43176        * page/win/DragControllerWin.cpp:
43177        (WebCore::DragController::declareAndWriteDragImage):
43178        * page/win/EventHandlerWin.cpp:
43179        (WebCore::EventHandler::createDraggingataTransfer):
43180        (WebCore::EventHandler::createDraggingClipboard): Deleted.
43181        * platform/Pasteboard.h:
43182        * platform/gtk/PasteboardGtk.cpp:
43183        (WebCore::Pasteboard::writeSelection):
43184        * platform/mac/PasteboardMac.mm:
43185        * platform/win/PasteboardWin.cpp:
43186        (WebCore::Pasteboard::writeRangeToDataObject):
43187        (WebCore::Pasteboard::writeSelection):
43188
431892014-04-08  Jer Noble  <jer.noble@apple.com>
43190
43191        Unreviewed iOS build fix. Pass 0 instead of nil to the options parameter of addObserver:forKeyPath:options:context.
43192
43193        * platform/graphics/ios/TextTrackRepresentationIOS.mm:
43194        (-[WebCoreTextTrackRepresentationIOSHelper setParent:]):
43195
431962014-04-08  Antti Koivisto  <antti@apple.com>
43197
43198        Remove exposedRect from TileController
43199        https://bugs.webkit.org/show_bug.cgi?id=131378
43200
43201        Reviewed by Simon Fraser.
43202
43203        Having two separate visible rectangles is confusing. We should compute one on higher level.
43204
43205        * page/FrameView.cpp:
43206        (WebCore::FrameView::setExposedRect):
43207        
43208            Push exposed rect to tile controller by doing a layer flush (like the changed visible rect is normally passed).
43209
43210        * platform/graphics/TiledBacking.h:
43211        * platform/graphics/ca/mac/TileController.h:
43212        * platform/graphics/ca/mac/TileController.mm:
43213        
43214            Remove exposedRect and just use visibleRect.
43215
43216        (WebCore::TileController::TileController):
43217        (WebCore::TileController::setTiledScrollingIndicatorPosition):
43218        
43219            Update the scrolling indicator position.
43220
43221        (WebCore::TileController::updateTileCoverageMap):
43222        (WebCore::TileController::setExposedRect): Deleted.
43223        * platform/graphics/ca/mac/TileGrid.h:
43224        * platform/graphics/ca/mac/TileGrid.mm:
43225        (WebCore::TileGrid::tilesWouldChangeForVisibleRect):
43226        (WebCore::TileGrid::revalidateTiles):
43227        (WebCore::TileGrid::scaledExposedRect): Deleted.
43228        * rendering/RenderLayerBacking.cpp:
43229        (WebCore::RenderLayerBacking::RenderLayerBacking):
43230        
43231            No need to push exposedRect anymore.
43232
43233        * rendering/RenderLayerCompositor.cpp:
43234        (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
43235        
43236            Integrate exposed rect to visible rect when flushing layers.
43237
432382014-04-08  Andreas Kling  <akling@apple.com>
43239
43240        [Mac] Always do a full GC when simulating memory pressure.
43241        <https://webkit.org/b/129790>
43242
43243        To get more consistent accounting on automated memory testers,
43244        add a synchronous GC as part of the simulated memory pressure event.
43245
43246        Reviewed by Geoffrey Garen.
43247
43248        * platform/mac/MemoryPressureHandlerMac.mm:
43249        (WebCore::MemoryPressureHandler::install):
43250
432512014-04-08  Jer Noble  <jer.noble@apple.com>
43252
43253        Unreviewed iOS build fix. Pass 0 instead of nil to setRate: when pausing.
43254
43255        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
43256        (WebCore::MediaPlayerPrivateAVFoundationObjC::platformPause):
43257
432582014-04-08  Mark Lam  <mark.lam@apple.com>
43259
43260        Refactor to make JSMainThreadExecState's constructor and destructor private.
43261        <https://webkit.org/b/131372>
43262
43263        Reviewed by Mark Hahnenberg.
43264
43265        This is in preparation for subsequent patches to ensure that we don't
43266        exit the VM with an exception still pending.
43267
43268        No new tests required.  This is only a refactor of existing behavior.
43269
43270        * bindings/js/JSDOMGlobalObjectTask.cpp:
43271        * bindings/js/JSMainThreadExecState.h:
43272        (WebCore::JSMainThreadExecState::runTask):
43273
432742014-04-07  Jer Noble  <jer.noble@apple.com>
43275
43276        [WK2][iOS] Consecutive videos in full screen display only black
43277        https://bugs.webkit.org/show_bug.cgi?id=131316
43278
43279        Reviewed by Eric Carlson.
43280
43281        Update the MediaPlayer's full screen attributes whenever the underlying engine changes,
43282        not just when the engine is initially created. Also, clear the videoLayer out of the
43283        fullscreen layer when destroying the videoLayer.
43284
43285        * html/HTMLMediaElement.cpp:
43286        (WebCore::HTMLMediaElement::parseAttribute):
43287        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
43288        (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoLayer):
43289
432902014-04-08  Morten Stenshorne  <mstensho@opera.com>
43291
43292        [New Multicolumn] Child top margin sometimes ignored for column balancing
43293        https://bugs.webkit.org/show_bug.cgi?id=122754
43294
43295        Reviewed by David Hyatt.
43296
43297        We need to set zero page logical height in LayoutState when column
43298        height is unknown (when the columns haven't yet been
43299        balanced). There's code that assumes that non-zero page height means
43300        that page height is known. Lying about this makes the pagination code
43301        believe that every top margin is adjacent to a column break, which
43302        makes it eat and ignore all top margins.
43303
43304        This should be cleaned up, but it's easier to wait until the old
43305        multicol code has been removed.
43306
43307        Tests: fast/multicol/break-in-scrollable.html
43308               fast/multicol/newmulticol/leading-and-trailing-margin.html
43309               fast/multicol/newmulticol/leading-margin.html
43310
43311        * rendering/LayoutState.cpp:
43312        (WebCore::LayoutState::LayoutState):
43313        * rendering/RenderBlockFlow.cpp:
43314        (WebCore::RenderBlockFlow::checkForPaginationLogicalHeightChange):
43315        * rendering/RenderFlowThread.h:
43316        * rendering/RenderMultiColumnFlowThread.cpp:
43317        (WebCore::RenderMultiColumnFlowThread::isPageLogicalHeightKnown):
43318        * rendering/RenderMultiColumnFlowThread.h:
43319
433202014-04-07  Dean Jackson  <dino@apple.com>
43321
43322        Allow elements to register for changes in page scale
43323        https://bugs.webkit.org/show_bug.cgi?id=131319
43324
43325        Reviewed by Eric Carlson.
43326
43327        Some parts of WebCore need to react to changes in the page
43328        scale factor, such as resizing when the user zooms. A followup
43329        patch will enable this for media controls - this simply lays
43330        the groundwork.
43331
43332        At the moment we only allow HTMLMediaElements to register, but if
43333        necessary this could be expanded in the future.
43334
43335        * dom/Document.cpp: New methods to keep a list of HTMLMediaElements that
43336        are interested in updates.
43337        (WebCore::Document::registerForPageScaleFactorChangedCallbacks):
43338        (WebCore::Document::unregisterForPageScaleFactorChangedCallbacks):
43339        (WebCore::Document::pageScaleFactorChanged):
43340        * dom/Document.h:
43341        * html/HTMLMediaElement.cpp:
43342        (WebCore::HTMLMediaElement::HTMLMediaElement):
43343        (WebCore::HTMLMediaElement::registerWithDocument): Add ourselves to the
43344        the document's pageScale callback.
43345        (WebCore::HTMLMediaElement::unregisterWithDocument): Remove ourselves from the
43346        the document's pageScale callback.
43347        (WebCore::HTMLMediaElement::setMediaControlsDependOnPageScaleFactor): Add/remove ourselves to/from
43348        the callback if necessary.
43349        (WebCore::HTMLMediaElement::pageScaleFactorChanged): The callback function. Empty for now.
43350        * html/HTMLMediaElement.h:
43351        (WebCore::HTMLMediaElement::mediaControlsDependOnPageScaleFactor): Accessor.
43352        * page/Page.cpp:
43353        (WebCore::Page::setPageScaleFactor): Tell all documents that the user has zoomed.
43354
433552014-04-08  peavo@outlook.com  <peavo@outlook.com>
43356
43357        [WinCairo] Compile error in TextureMapper.h
43358        https://bugs.webkit.org/show_bug.cgi?id=131360
43359
43360        Reviewed by Brent Fulgham.
43361
43362        The TextureMapper class has pure virtual methods, and cannot be instantiated.
43363
43364        * platform/graphics/texmap/TextureMapper.h:
43365        (WebCore::TextureMapper::platformCreateAccelerated):
43366
433672014-04-08  Zalan Bujtas  <zalan@apple.com>
43368
43369        Subpixel rendering: Slow paint path for inlines should snap to device pixels.
43370        https://bugs.webkit.org/show_bug.cgi?id=131259
43371
43372        Reviewed by Simon Fraser.
43373
43374        InlineTextBox::paint needs to round to the same device pixel position as SimpleLineLayout does.
43375
43376        Test: fast/inline/hidpi-slow-path-text-on-subpixel-position.html
43377
43378        * rendering/InlineTextBox.cpp:
43379        (WebCore::InlineTextBox::paint):
43380        * rendering/TextPainter.h: Cleanup. No reason to have them as references here.
43381
433822014-04-07  Brent Fulgham  <bfulgham@apple.com>
43383
43384        Keep 'webkitClosedCaptionsVisible' API in sync with captions display preferences
43385        https://bugs.webkit.org/show_bug.cgi?id=131344
43386
43387        Reviewed by Eric Carlson.
43388
43389        * html/HTMLMediaElement.cpp:
43390        (WebCore::HTMLMediaElement::configureTextTrackGroup) If we decide that captions should
43391        be active (due to user preferences) make sure the 'webkitClosedCaptionsVisible' state
43392        is turned on.
43393
433942014-04-08  Zalan Bujtas  <zalan@apple.com>
43395
43396        Subpixel rendering: Paint the filter effect result image on device pixel position.
43397        https://bugs.webkit.org/show_bug.cgi?id=131255
43398
43399        Reviewed by Simon Fraser.
43400
43401        This patch moves filter effect images from integral to device pixel position. However,
43402        result images are still integral based.
43403
43404        Test: css3/filters/hidpi-filter-is-on-subpixel-position.html
43405
43406        * rendering/FilterEffectRenderer.cpp:
43407        (WebCore::FilterEffectRendererHelper::applyFilterEffect):
43408
434092014-04-08  Zalan Bujtas  <zalan@apple.com>
43410
43411        Subpixel rendering: Make border images device pixel aware.
43412        https://bugs.webkit.org/show_bug.cgi?id=131209
43413
43414        Reviewed by Simon Fraser.
43415
43416        Snap border-image size and position to device pixels. It works both on generated and bitmap images.
43417
43418        Test: fast/borders/hidpi-border-image-gradient-on-subpixels.html
43419
43420        * rendering/RenderBoxModelObject.cpp:
43421        (WebCore::RenderBoxModelObject::paintNinePieceImage):
43422
434232014-04-08  Youenn Fablet  <youenn.fablet@crf.canon.fr>
43424
43425        [SOUP] Control cookie management according ResourceRequest.allowCookies()
43426        https://bugs.webkit.org/show_bug.cgi?id=131026
43427
43428        Reviewed by Sergio Villar Senin.
43429
43430        Added per soup-message disabling of cookie jar manager when related ResourceRequest does not allow cookies (e.g. some cross-origin requests).
43431
43432        Patch is covered by unskipped test http/tests/xmlhttprequest/cross-origin-cookie-storage.html.
43433
43434        * platform/network/soup/ResourceRequestSoup.cpp:
43435        (WebCore::ResourceRequest::updateSoupMessageMembers): Added disabling of cookie jar manager if cookies are not allowed.
43436
434372014-04-08  Sergio Villar Senin  <svillar@igalia.com>
43438
43439        [CSS Grid Layout] Handle min/max height in the grid element
43440        https://bugs.webkit.org/show_bug.cgi?id=131302
43441
43442        Reviewed by Darin Adler.
43443
43444        Removed a FIXME in the code as we're already handling min/max
43445        height in the code. Added a couple of test cases to improve the
43446        test coverage.
43447
43448        Merged from Blink r161876 by <jchaffraix@chromium.org>
43449
43450        Tests: fast/css-grid-layout/flex-content-sized-columns-resize.html
43451               fast/css-grid-layout/grid-element-min-max-height.html
43452
43453        * rendering/RenderGrid.cpp:
43454        (WebCore::RenderGrid::layoutGridItems):
43455
434562014-04-08  Mihnea Ovidenie  <mihnea@adobe.com>
43457
43458        [CSSRegions] Remove unused RenderBox::clearRenderBoxRegionInfo
43459        https://bugs.webkit.org/show_bug.cgi?id=131352
43460
43461        Reviewed by Andrei Bucur.
43462
43463        No new tests, code clean-up.
43464
43465        * rendering/RenderBox.cpp:
43466        (WebCore::RenderBox::clearRenderBoxRegionInfo): Deleted.
43467        * rendering/RenderBox.h:
43468
434692014-04-08  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
43470
43471        Buildfix after r166917
43472        https://bugs.webkit.org/show_bug.cgi?id=131351
43473
43474        Reviewed by Andrei Bucur.
43475
43476        * accessibility/AccessibilityNodeObject.cpp:
43477        (WebCore::accessibleNameForNode):
43478
434792014-04-08  Darin Adler  <darin@apple.com>
43480
43481        Fix assertions triggered by CSS calc changes in r166860
43482        https://bugs.webkit.org/show_bug.cgi?id=131346
43483
43484        Reviewed by Andrei Bucur.
43485
43486        * css/CSSComputedStyleDeclaration.cpp:
43487        (WebCore::getBorderRadiusCornerValues): Use isPercentNotCalculated() instead of
43488        type() == Percent; no behavior change.
43489        (WebCore::getBorderRadiusCornerValue): Ditto.
43490        (WebCore::lineHeightFromStyle): Use isPercentNotCalculated() before code
43491        that calls percent(), which won't work for a calculated length.
43492
43493        * css/DeprecatedStyleBuilder.cpp:
43494        (WebCore::ApplyPropertyBorderRadius::applyValue): Use isNegative and isZero rather
43495        than calling value() unconditionally. Should make calculated values work better.
43496
43497        * html/HTMLPlugInImageElement.cpp:
43498        (WebCore::is100Percent): Use isPercentNotCalculated() before code
43499        that calls percent(), which won't work for a calculated length.
43500
43501        * platform/Length.cpp:
43502        (WebCore::CalculationValueMap::deref): Use adoptRef here instead of calling deref
43503        immediately, so the deref will happen after calling remove. This makes the code
43504        work properly even if it's reentered inside the calculation value's destructor.
43505
43506        * platform/Length.h:
43507        (WebCore::Length::percent): Change assert to isPercentNotCalculated, since the
43508        value function this calls only works for non-calculated values anyway.
43509        (WebCore::Length::isPercentNotCalculated): Added.
43510        (WebCore::Length::isPercent): Changed to call isPercentNotCalculated.
43511        (WebCore::Length::isSpecified): Changed to call isPercent.
43512
43513        * platform/graphics/transforms/TranslateTransformOperation.h:
43514        (WebCore::TranslateTransformOperation::apply): Use isPercentNotCalculated()
43515        instead of type() == Percent; no behavior change.
43516
43517        * rendering/AutoTableLayout.cpp:
43518        (WebCore::AutoTableLayout::recalcColumn): Use isPercentNotCalculated()
43519        before code that calls value() or percent(), which won't work for a calculated length.
43520        (WebCore::AutoTableLayout::computeIntrinsicLogicalWidths): Ditto.
43521        (WebCore::AutoTableLayout::calcEffectiveLogicalWidth): Ditto.
43522        (WebCore::AutoTableLayout::layout): Ditto.
43523        * rendering/FixedTableLayout.cpp:
43524        (WebCore::FixedTableLayout::layout): Ditto.
43525        * rendering/RenderBoxModelObject.cpp:
43526        (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions): Ditto.
43527        * rendering/RenderTableSection.cpp:
43528        (WebCore::updateLogicalHeightForCell): Ditto.
43529        (WebCore::RenderTableSection::distributeExtraLogicalHeightToPercentRows): Ditto.
43530        (WebCore::RenderTableSection::distributeExtraLogicalHeightToRows): Ditto.
43531
43532        * rendering/style/RenderStyle.cpp:
43533        (WebCore::requireTransformOrigin): Use modern for loop. Also marked function static,
43534        since it's private to this file.
43535        (WebCore::RenderStyle::applyTransform): Use isPercentNotCalculated() instead of
43536        type() == Percent; no behavior change. Also use a modern for loop and auto& to avoid
43537        a really long type name.
43538
43539        * rendering/svg/RenderSVGRoot.cpp:
43540        (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation): Use isPercentNotCalculated()
43541        before code that calls percent(), which won't work for a calculated length.
43542
43543        * platform/Length.h:
43544        (WebCore::Length::percent):
43545        (WebCore::Length::isPercentNotCalculated):
43546        (WebCore::Length::isPercent):
43547        (WebCore::Length::isSpecified):
43548        * platform/graphics/transforms/TranslateTransformOperation.h:
43549        (WebCore::TranslateTransformOperation::apply):
43550        * rendering/AutoTableLayout.cpp:
43551        (WebCore::AutoTableLayout::recalcColumn):
43552        (WebCore::AutoTableLayout::computeIntrinsicLogicalWidths):
43553        (WebCore::AutoTableLayout::calcEffectiveLogicalWidth):
43554        (WebCore::AutoTableLayout::layout):
43555        * rendering/FixedTableLayout.cpp:
43556        (WebCore::FixedTableLayout::layout):
43557        * rendering/RenderBoxModelObject.cpp:
43558        (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
43559        * rendering/RenderTableSection.cpp:
43560        (WebCore::updateLogicalHeightForCell):
43561        (WebCore::RenderTableSection::distributeExtraLogicalHeightToPercentRows):
43562        (WebCore::RenderTableSection::distributeExtraLogicalHeightToRows):
43563        * rendering/style/RenderStyle.cpp:
43564        (WebCore::requireTransformOrigin):
43565        (WebCore::RenderStyle::applyTransform):
43566        * rendering/svg/RenderSVGRoot.cpp:
43567        (WebCore::RenderSVGRoot::computeIntrinsicRatioInformation):
43568
435692014-04-08  Xabier Rodriguez Calvar  <calvaris@igalia.com>
43570
43571        [GTK] Remove media controls dead code
43572        https://bugs.webkit.org/show_bug.cgi?id=131300
43573
43574        Reviewed by Eric Carlson.
43575
43576        MediaControlsGtk.cpp is no longer used so we can remove it from
43577        the repo.
43578
43579        No new tests needed.
43580
43581        * PlatformGTK.cmake: Remove html/shadow/MediaControlsGtk.cpp from
43582        compilation.
43583        * html/shadow/MediaControlsGtk.cpp: Removed.
43584
435852014-04-08  Mihnea Ovidenie  <mihnea@adobe.com>
43586
43587        [CSSRegions] Fixed positioned elements in named flows have fragmented content
43588        https://bugs.webkit.org/show_bug.cgi?id=130595
43589
43590        Reviewed by Darin Adler.
43591
43592        Fixed positioned elements that have the named flow as parent are positioned
43593        and sized relative to the viewport. Because of that, when the named flow
43594        has an associated region chain, the fixed positioned elements should not
43595        be fragmented.
43596
43597        By making a fixed positioned element with a named flow parent unsplittable
43598        for fragmentation, we prevent this wrong behavior.
43599
43600        Test: fast/regions/fixed-pos-content-fragmented.html
43601
43602        * rendering/RenderBox.cpp:
43603        (WebCore::RenderBox::isUnsplittableForPagination):
43604
436052014-04-07  Chris Fleizach  <cfleizach@apple.com>
43606
43607        Regression: AX: image labels no longer exposed to AX API in SVG test case
43608        https://bugs.webkit.org/show_bug.cgi?id=131208
43609
43610        Reviewed by Daniel Bates.
43611
43612        accessibleNameForNode should work on any Element, not just HTML elements.
43613
43614        Test: accessibility/svg-labelledby.html
43615
43616        * accessibility/AccessibilityNodeObject.cpp:
43617        (WebCore::accessibleNameForNode):
43618
436192014-04-08  Andres Gomez  <agomez@igalia.com>
43620
43621        [GTK] [EFL] Build fails with GCC < 4.8.x
43622        https://bugs.webkit.org/show_bug.cgi?id=130585
43623
43624        Reviewed by Martin Robinson.
43625
43626        The behavior in lower versions of GCC seem to be related to
43627        http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-active.html#2132.
43628
43629        Provided explicit casts for the failing ambiguous overloads.
43630
43631        * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
43632        (WebCore::AudioFileReader::createBus):
43633        * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
43634        (webKitMediaSrcChangeState):
43635        (webKitMediaVideoSrcNeedDataCb):
43636        (webKitMediaAudioSrcNeedDataCb):
43637        (webKitMediaVideoSrcEnoughDataCb):
43638        (webKitMediaAudioSrcEnoughDataCb):
43639        (webKitMediaVideoSrcSeekDataCb):
43640        (webKitMediaAudioSrcSeekDataCb):
43641        * platform/gtk/GtkDragAndDropHelper.cpp:
43642        (WebCore::GtkDragAndDropHelper::handleDragLeave):
43643        * platform/gtk/SharedTimerGtk.cpp:
43644        (WebCore::setSharedTimerFireInterval):
43645
436462014-04-08  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
43647
43648        Change NavigatorContentUtils client ownership from port side to NavigatorContentUtils
43649        https://bugs.webkit.org/show_bug.cgi?id=131299
43650
43651        Reviewed by Darin Adler.
43652
43653        EFL and GTK ports have managed own client of NavigatorContentUtils though it is only passed to
43654        NavigatorContentUtils. The NavigatorContentUtils has used the client to call port functions. So,
43655        there is no reason port implementation needs to manage the ownership. To manage the client is
43656        unnecessary work in current implementation.
43657
43658        No new tests, no behavior changes.
43659
43660        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
43661        (WebCore::NavigatorContentUtils::create):
43662        (WebCore::provideNavigatorContentUtilsTo):
43663        * Modules/navigatorcontentutils/NavigatorContentUtils.h:
43664        * Modules/navigatorcontentutils/NavigatorContentUtilsClient.h:
43665
436662014-04-07  Zoltan Horvath  <zoltan@webkit.org>
43667
43668        [CSS Shapes] Simplify the parsing of width arguments for Inset shapes
43669        https://bugs.webkit.org/show_bug.cgi?id=131305
43670
43671        Reviewed by Andreas Kling.
43672
43673        This code introduces some helper functions for setting the size arguments of inset shapes. This change
43674        also modifies the code to be the same as in Blink, so it helps us to keep the shapes code similar.
43675
43676        No new tests, no behavior change.
43677
43678        * css/CSSBasicShapes.h:
43679        (WebCore::CSSBasicShapeInset::updateShapeSize4Values):
43680        (WebCore::CSSBasicShapeInset::updateShapeSize1Value):
43681        (WebCore::CSSBasicShapeInset::updateShapeSize2Values):
43682        (WebCore::CSSBasicShapeInset::updateShapeSize3Values):
43683        * css/CSSParser.cpp:
43684        (WebCore::CSSParser::parseBasicShapeInset):
43685
436862014-04-07  Martin Robinson  <mrobinson@igalia.com>
43687
43688        fast/css3-text/css3-text-decoration/text-decoration-thickness.html fails on GTK
43689        https://bugs.webkit.org/show_bug.cgi?id=129957
43690
43691        Reviewed by Dean Jackson.
43692
43693        Causes existing tests to pass.
43694
43695        * platform/graphics/cairo/GraphicsContextCG.cpp: Use the now-shared computeLineBoundsAndAntialiasingModeForText.
43696        * platform/graphics/cairo/GraphicsContextCairo.cpp: Align the Cairo version of text underline drawing with the CG version.
43697        * platform/graphics/GraphicsContext.h: Add computeLineBoundsAndAntialiasingModeForText.
43698        * platform/graphics/GraphicsContext.cpp: Ditto.
43699
437002014-04-07  Beth Dakin  <bdakin@apple.com>
43701
43702        REGRESSION (r163194-r163227): Garbage tiles in overflow of RTL page with 
43703        background image
43704        https://bugs.webkit.org/show_bug.cgi?id=131323
43705        -and corresponding-
43706        <rdar://problem/16402013>
43707
43708        Reviewed by Tim Horton.
43709
43710        Returning the TiledBacking::bounds() for the 
43711        FrameView::extendedBackgroundRectForPainting() in convenient for ltr pages, but it 
43712        is simply incorrect in rtl. There is no easy way to map the rect into the right 
43713        coordinate space, so this patch re-works the code to use computations in 
43714        RenderView to get the right rect.
43715
43716        Call RenderView::unextendedBackgroundRect() and expand and move it based on the 
43717        TiledBacking’s margins.
43718        * page/FrameView.cpp:
43719        (WebCore::FrameView::extendedBackgroundRectForPainting):
43720
43721        The logic that used to be in backgroundRect() has been moved to 
43722        unextendedBackgroundRect(). 
43723        * rendering/RenderView.cpp:
43724        (WebCore::RenderView::unextendedBackgroundRect):
43725        (WebCore::RenderView::backgroundRect):
43726        * rendering/RenderView.h:
43727
437282014-04-07  Zoltan Horvath  <zoltan@webkit.org>
43729
43730        [CSS Shapes] inset complex calc() args vanish in serialized computed style
43731        https://bugs.webkit.org/show_bug.cgi?id=129838
43732
43733        Reviewed by Bem Jones-Bey.
43734
43735        We didn't pass the style parameter when setting the width members of CSSBasicShapeInset,
43736        which lead to a 'should never reach asserttion' in CSSPrimitiveValue::init. This patch
43737        adds the missing parameters to the call sites.
43738
43739        Extended existing parsing test script.
43740
43741        * css/BasicShapeFunctions.cpp:
43742        (WebCore::valueForBasicShape):
43743
437442014-04-07  Eric Carlson  <eric.carlson@apple.com>
43745
43746        [iOS] MediaDocument should allow autoplay
43747        https://bugs.webkit.org/show_bug.cgi?id=131301
43748
43749        Reviewed by Jer Noble.
43750
43751        * html/HTMLMediaElement.cpp:
43752        (WebCore::HTMLMediaElement::HTMLMediaElement): Don't add the RequireUserGestureForRateChange
43753            behavior restriction when in a MediaDocument.
43754
437552014-04-07  Hyowon Kim  <hw1008.kim@samsung.com>
43756
43757        Move to using std::unique_ptr for opengl, texmap, transforms and efl in WebCore/platform/graphics.
43758        https://bugs.webkit.org/show_bug.cgi?id=131276
43759
43760        Reviewed by Darin Adler.
43761
43762        Replace uses of OwnPtr and PassOwnPtr in code under WebCore/platform/graphics/
43763        opengl, texmap, transforms and efl with std::unique_ptr.
43764
43765        * html/canvas/WebGLRenderingContext.cpp:
43766        (WebCore::WebGLRenderingContext::initializeNewContext):
43767        * platform/graphics/GraphicsContext3D.h:
43768        * platform/graphics/GraphicsContext3DPrivate.cpp:
43769        (WebCore::GraphicsContext3DPrivate::create): Deleted.
43770        * platform/graphics/GraphicsContext3DPrivate.h:
43771        * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
43772        (WebCore::GraphicsContext3D::GraphicsContext3D):
43773        (WebCore::GraphicsContext3D::setContextLostCallback):
43774        (WebCore::GraphicsContext3D::setErrorMessageCallback):
43775        * platform/graphics/efl/EvasGLContext.h:
43776        * platform/graphics/efl/EvasGLSurface.h:
43777        * platform/graphics/efl/GraphicsContext3DEfl.cpp:
43778        (WebCore::GraphicsContext3D::setContextLostCallback):
43779        (WebCore::GraphicsContext3D::setErrorMessageCallback):
43780        * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
43781        (WebCore::GraphicsContext3DPrivate::create):
43782        (WebCore::GraphicsContext3DPrivate::setContextLostCallback):
43783        * platform/graphics/efl/GraphicsContext3DPrivate.h:
43784        * platform/graphics/mac/GraphicsContext3DMac.mm:
43785        (WebCore::GraphicsContext3D::GraphicsContext3D):
43786        (WebCore::GraphicsContext3D::setContextLostCallback):
43787        (WebCore::GraphicsContext3D::setErrorMessageCallback):
43788        * platform/graphics/opengl/Extensions3DOpenGLES.cpp:
43789        (WebCore::Extensions3DOpenGLES::setEXTContextLostCallback):
43790        * platform/graphics/opengl/Extensions3DOpenGLES.h:
43791        * platform/graphics/opengl/GLPlatformContext.cpp:
43792        (WebCore::createOffScreenContext):
43793        (WebCore::GLPlatformContext::createContext):
43794        * platform/graphics/opengl/GLPlatformContext.h:
43795        * platform/graphics/opengl/GLPlatformSurface.cpp:
43796        (WebCore::GLPlatformSurface::createOffScreenSurface):
43797        * platform/graphics/opengl/GLPlatformSurface.h:
43798        * platform/graphics/surfaces/efl/GraphicsSurfaceCommon.cpp:
43799        * platform/graphics/surfaces/egl/EGLSurface.cpp:
43800        (WebCore::EGLOffScreenSurface::createOffScreenSurface):
43801        * platform/graphics/surfaces/egl/EGLSurface.h:
43802        * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
43803        (WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
43804        * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
43805        * platform/graphics/texmap/TextureMapper.cpp:
43806        (WebCore::TextureMapper::create):
43807        (WebCore::TextureMapper::TextureMapper):
43808        * platform/graphics/texmap/TextureMapper.h:
43809        (WebCore::TextureMapper::platformCreateAccelerated):
43810        * platform/graphics/texmap/TextureMapperGL.cpp:
43811        (WebCore::TextureMapper::platformCreateAccelerated):
43812        * platform/graphics/texmap/TextureMapperGL.h:
43813        (WebCore::TextureMapperGL::create): Deleted.
43814        * platform/graphics/texmap/TextureMapperImageBuffer.h:
43815        (WebCore::TextureMapperImageBuffer::TextureMapperImageBuffer):
43816        (WebCore::TextureMapperImageBuffer::create): Deleted.
43817        * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
43818        (WebCore::CoordinatedGraphicsScene::purgeGLResources):
43819        * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
43820        * platform/graphics/transforms/TransformState.cpp:
43821        (WebCore::TransformState::operator=):
43822        (WebCore::TransformState::applyTransform):
43823        * platform/graphics/transforms/TransformState.h:
43824        * platform/graphics/win/GraphicsContext3DWin.cpp:
43825        (WebCore::GraphicsContext3D::GraphicsContext3D):
43826        (WebCore::GraphicsContext3D::setContextLostCallback):
43827        (WebCore::GraphicsContext3D::setErrorMessageCallback):
43828
438292014-04-07  Tim Horton  <timothy_horton@apple.com>
43830
43831        [iOS WebKit2] Make back-buffers purgeable when possible
43832        https://bugs.webkit.org/show_bug.cgi?id=131213
43833        <rdar://problem/15373906>
43834
43835        Reviewed by Simon Fraser.
43836
43837        * WebCore.exp.in:
43838        * platform/graphics/cg/IOSurfacePool.cpp:
43839        (WebCore::IOSurfacePool::takeSurface):
43840        (WebCore::IOSurfacePool::markOlderSurfacesPurgeable):
43841        (WebCore::IOSurfacePool::showPoolStatistics):
43842        * platform/graphics/cocoa/IOSurface.h:
43843        * platform/graphics/cocoa/IOSurface.mm:
43844        (IOSurface::isVolatile):
43845        (IOSurface::setIsVolatile):
43846        Rename purgeability functions to match the system
43847        and reduce confusion between purgeable memory
43848        and volatile vs. non-volatile memory.
43849
438502014-04-07  Benjamin Poulain  <benjamin@webkit.org>
43851
43852        Split CSS Selectors pseudo class and pseudo elements
43853        https://bugs.webkit.org/show_bug.cgi?id=131295
43854
43855        Reviewed by Andreas Kling.
43856
43857        Split pseudo class and pseudo element to make it clearer what pseudo types
43858        are possible for a given match type.
43859
43860        Pseudo Element types are separated and Pseudo Class are left in place. The Pseudo Class
43861        will have to be renamed too but that will be done separately to make this change smaller.
43862
43863        * css/CSSGrammar.y.in:
43864        * css/CSSParser.cpp:
43865        (WebCore::CSSParser::rewriteSpecifiersWithElementName):
43866        (WebCore::CSSParser::rewriteSpecifiers):
43867        Use a method isPseudoElementCueFunction() to abstract the #ifdef out of the parser.
43868
43869        * css/CSSParserValues.cpp:
43870        (WebCore::CSSParserSelector::parsePseudoElementSelector):
43871
43872        (WebCore::CSSParserSelector::parsePseudoElementCueFunctionSelector):
43873        Rename to specify this is for the pseudo element cue function, not the pseudo element cue.
43874
43875        (WebCore::CSSParserSelector::parsePseudoClassAndCompatibilityElementSelector):
43876        (WebCore::CSSParserSelector::parsePseudoCueFunctionSelector): Deleted.
43877        * css/CSSParserValues.h:
43878        (WebCore::CSSParserSelector::isPseudoElementCueFunction):
43879        * css/CSSSelector.cpp:
43880        (WebCore::CSSSelector::specificityForOneSelector):
43881        (WebCore::CSSSelector::pseudoId):
43882        (WebCore::CSSSelector::parsePseudoElementType):
43883        (WebCore::CSSSelector::operator==):
43884        * css/CSSSelector.h:
43885        (WebCore::CSSSelector::pseudoType):
43886        (WebCore::CSSSelector::setPseudoElementType):
43887        (WebCore::CSSSelector::pseudoElementType):
43888        (WebCore::CSSSelector::isUnknownPseudoElement):
43889        (WebCore::CSSSelector::isCustomPseudoElement):
43890        (WebCore::pseudoClassIsRelativeToSiblings):
43891        (WebCore::CSSSelector::isSiblingSelector):
43892        * css/RuleFeature.cpp:
43893        (WebCore::RuleFeatureSet::collectFeaturesFromSelector):
43894        * css/RuleSet.cpp:
43895        (WebCore::determinePropertyWhitelistType):
43896        (WebCore::RuleSet::findBestRuleSetAndAdd):
43897        * css/SelectorChecker.cpp:
43898        (WebCore::SelectorChecker::matchRecursively):
43899        (WebCore::SelectorChecker::checkOne):
43900        (WebCore::SelectorChecker::checkScrollbarPseudoClass):
43901        (WebCore::SelectorChecker::determineLinkMatchType):
43902        * css/SelectorPseudoClassAndCompatibilityElementMap.in:
43903        * css/SelectorPseudoElementTypeMap.in:
43904        * css/SelectorPseudoTypeMap.h:
43905        * css/makeSelectorPseudoClassAndCompatibilityElementMap.py:
43906        * css/makeSelectorPseudoElementsMap.py:
43907        (enumerablePseudoType):
43908        * page/DOMWindow.cpp:
43909        (WebCore::DOMWindow::getMatchedCSSRules):
43910
43911        * rendering/style/RenderStyleConstants.h:
43912        All the fullscreen pseudo types are pseudo class selectors. They should not have a pseudo ID.
43913
439142014-04-07  Brian J. Burg  <burg@cs.washington.edu>
43915
43916        Web Replay: detect possible replay divergence from unexpected DOM event dispatches
43917        https://bugs.webkit.org/show_bug.cgi?id=131193
43918
43919        Reviewed by Andreas Kling.
43920
43921        Add assertions to catch potential nondeterministic behavior.
43922
43923        The assertion added by this patch catches dispatched DOM events
43924        that are triggered by nondeterministic event loop cycles. If we
43925        did not capture an event loop input in the current event loop
43926        cycle nor are we manually simulating an event loop input during
43927        playback, then DOM events fired during the unordered cycle could
43928        run JavaScript and diverge the execution.
43929
43930        During playback, we can assert that EventLoopInputDispatcher is dispatching
43931        when a DOM event is be dispatched to a document that is being replayed.
43932
43933        During capturing, event loop inputs are captured rather than
43934        dispatched, so we add some accounting to track what caused a DOM
43935        event. To approximate the extent of computation triggered by an
43936        event loop input, we add RAII helpers to call sites where event
43937        loop inputs are captured.
43938
43939        The assertions are disabled by default until the most common
43940        sources of nondeterminism are handled and playback errors are
43941        gracefully surfaced to the user. <https://webkit.org/b/131279>
43942
43943        No new tests. This patch adds extra assertions for debugging purposes.
43944
43945        * WebCore.xcodeproj/project.pbxproj:
43946        * inspector/InspectorInstrumentation.cpp: Notify ReplayAgent of dispatched DOM event.
43947        (WebCore::InspectorInstrumentation::willDispatchEventImpl):
43948        (WebCore::InspectorInstrumentation::willDispatchEventOnWindowImpl):
43949        * inspector/InspectorReplayAgent.cpp: Forward dispatched DOM events to ReplayController.
43950        (WebCore::InspectorReplayAgent::willDispatchEvent): Added.
43951        * inspector/InspectorReplayAgent.h:
43952        * replay/CapturingInputCursor.cpp:
43953        (WebCore::CapturingInputCursor::CapturingInputCursor):
43954        (WebCore::CapturingInputCursor::setWithinEventLoopInputExtent): Added.
43955        * replay/CapturingInputCursor.h:
43956        * replay/EventLoopInput.cpp: Added.
43957        (WebCore::EventLoopInputExtent::EventLoopInputExtent): Added.
43958        (WebCore::EventLoopInputExtent::~EventLoopInputExtent): Added.
43959        * replay/EventLoopInput.h:
43960        * replay/EventLoopInputDispatcher.h:
43961        (WebCore::EventLoopInputDispatcher::isDispatching): Add a getter.
43962        * replay/ReplayController.cpp:
43963        (WebCore::logDispatchedDOMEvent): Added. This is useful for understanding script-visible events.
43964        (WebCore::ReplayController::willDispatchEvent): Added.
43965        * replay/ReplayController.h:
43966        * replay/UserInputBridge.cpp: Add extent helpers to call sites that capture inputs.
43967        (WebCore::UserInputBridge::handleMousePressEvent):
43968        (WebCore::UserInputBridge::handleMouseReleaseEvent):
43969        (WebCore::UserInputBridge::handleMouseMoveEvent):
43970        (WebCore::UserInputBridge::handleMouseMoveOnScrollbarEvent):
43971        (WebCore::UserInputBridge::handleKeyEvent):
43972        (WebCore::UserInputBridge::handleWheelEvent):
43973        (WebCore::UserInputBridge::scrollRecursively):
43974        (WebCore::UserInputBridge::logicalScrollRecursively):
43975
439762014-04-07  Timothy Hatcher  <timothy@apple.com>
43977
43978        Remove copy of combine-javascript-resources.pl that isn't used anymore
43979        https://bugs.webkit.org/show_bug.cgi?id=131307
43980
43981        Reviewed by Joseph Pecoraro.
43982
43983        * WebCore.xcodeproj/project.pbxproj:
43984        * inspector/combine-javascript-resources.pl: Removed.
43985
439862014-04-07  Zoltan Horvath  <zoltan@webkit.org>
43987
43988        [CSS Shapes] Clean up invalid FIXME
43989        https://bugs.webkit.org/show_bug.cgi?id=131304
43990
43991        Reviewed by Andreas Kling.
43992
43993        No new tests, no behavior change.
43994
43995        * page/animation/CSSPropertyAnimation.cpp:
43996        (WebCore::blendFunc):
43997
439982014-04-07  Ryuan Choi  <ryuan.choi@samsung.com>
43999
44000        [EFL] Turn on ENABLE_MEDIA_CONTROLS_SCRIPT
44001        https://bugs.webkit.org/show_bug.cgi?id=131257
44002
44003        Reviewed by Gyuyoung Kim.
44004
44005        no new tests. just rebased exisiting tests.
44006
44007        * PlatformEfl.cmake: Added the media controls script associated files.
44008        * css/mediaControlsEfl.css: Removed.
44009        * css/mediaControlsEflFullscreen.css: Removed.
44010        * platform/efl/DefaultTheme/CMakeLists.txt:
44011        * platform/efl/DefaultTheme/default.edc:
44012        * platform/efl/DefaultTheme/widget/mediacontrol/fullscreenbutton/enterfullscreenbutton.png: Removed.
44013        * platform/efl/DefaultTheme/widget/mediacontrol/fullscreenbutton/exitfullscreenbutton.png: Removed.
44014        * platform/efl/DefaultTheme/widget/mediacontrol/fullscreenbutton/fullscreen_button.edc: Removed.
44015        * platform/efl/DefaultTheme/widget/mediacontrol/mutebutton/mute_button.edc: Removed.
44016        * platform/efl/DefaultTheme/widget/mediacontrol/mutebutton/mutebutton.png: Removed.
44017        * platform/efl/DefaultTheme/widget/mediacontrol/mutebutton/unmutebutton.png: Removed.
44018        * platform/efl/DefaultTheme/widget/mediacontrol/playpausebutton/pausebutton.png: Removed.
44019        * platform/efl/DefaultTheme/widget/mediacontrol/playpausebutton/playbutton.png: Removed.
44020        * platform/efl/DefaultTheme/widget/mediacontrol/playpausebutton/playpause_button.edc: Removed.
44021        * platform/efl/DefaultTheme/widget/mediacontrol/seekbackwardbutton/seekbackward_button.edc: Removed.
44022        * platform/efl/DefaultTheme/widget/mediacontrol/seekbackwardbutton/seekbackwardbutton.png: Removed.
44023        * platform/efl/DefaultTheme/widget/mediacontrol/seekforwardbutton/seekforward_button.edc: Removed.
44024        * platform/efl/DefaultTheme/widget/mediacontrol/seekforwardbutton/seekforwardbutton.png: Removed.
44025        * platform/efl/DefaultTheme/widget/mediacontrol/togglecaptionsbutton/closedcaption.png: Removed.
44026        * platform/efl/DefaultTheme/widget/mediacontrol/togglecaptionsbutton/closedcaption_disabled.png: Removed.
44027        * platform/efl/DefaultTheme/widget/mediacontrol/togglecaptionsbutton/toggle_captions_button.edc: Removed.
44028        * platform/efl/RenderThemeEfl.cpp:
44029        (WebCore::toEdjeGroup):
44030        (WebCore::RenderThemeEfl::RenderThemeEfl):
44031        (WebCore::RenderThemeEfl::adjustSliderThumbSize):
44032        (WebCore::RenderThemeEfl::mediaControlsStyleSheet): Modified to load bundle style sheet.
44033        (WebCore::RenderThemeEfl::mediaControlsScript): Added to load bundle scripts.
44034        (WebCore::RenderThemeEfl::emitMediaButtonSignal): Deleted.
44035        (WebCore::RenderThemeEfl::extraMediaControlsStyleSheet): Deleted.
44036        (WebCore::RenderThemeEfl::extraFullScreenStyleSheet): Deleted.
44037        (WebCore::RenderThemeEfl::formatMediaControlsCurrentTime): Deleted.
44038        (WebCore::RenderThemeEfl::hasOwnDisabledStateHandlingFor): Deleted.
44039        (WebCore::RenderThemeEfl::paintMediaFullscreenButton): Deleted.
44040        (WebCore::RenderThemeEfl::paintMediaMuteButton): Deleted.
44041        (WebCore::RenderThemeEfl::paintMediaPlayButton): Deleted.
44042        (WebCore::RenderThemeEfl::paintMediaSeekBackButton): Deleted.
44043        (WebCore::RenderThemeEfl::paintMediaSeekForwardButton): Deleted.
44044        (WebCore::RenderThemeEfl::paintMediaSliderTrack): Deleted.
44045        (WebCore::RenderThemeEfl::paintMediaSliderThumb): Deleted.
44046        (WebCore::RenderThemeEfl::paintMediaVolumeSliderContainer): Deleted.
44047        (WebCore::RenderThemeEfl::paintMediaVolumeSliderTrack): Deleted.
44048        (WebCore::RenderThemeEfl::paintMediaVolumeSliderThumb): Deleted.
44049        (WebCore::RenderThemeEfl::paintMediaCurrentTime): Deleted.
44050        (WebCore::RenderThemeEfl::supportsClosedCaptioning): Deleted.
44051        (WebCore::RenderThemeEfl::paintMediaToggleClosedCaptionsButton): Deleted.
44052        * platform/efl/RenderThemeEfl.h:
44053
440542014-04-07  Benjamin Poulain  <benjamin@webkit.org>
44055
44056        CSS JIT: change the node flags directly instead of using function calls when possible
44057        https://bugs.webkit.org/show_bug.cgi?id=131292
44058
44059        Reviewed by Andreas Kling.
44060
44061        For historical reasons, changing the node flags was always done with function calls.
44062        This patch changes those calls to modify the nodes directly.
44063
44064        * cssjit/SelectorCompiler.cpp:
44065        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
44066        (WebCore::SelectorCompiler::setNodeFlag):
44067        (WebCore::SelectorCompiler::SelectorCodeGenerator::markParentElementIfResolvingStyle):
44068        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
44069        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLastChild):
44070        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsOnlyChild):
44071        (WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByLastChildRules): Deleted.
44072        (WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByFirstChildAndLastChildRules): Deleted.
44073        * dom/Element.cpp:
44074        (WebCore::Element::setChildrenAffectedByFirstChildRules): Deleted.
44075        (WebCore::Element::setChildrenAffectedByDirectAdjacentRules): Deleted.
44076        * dom/Element.h:
44077        * dom/Node.h:
44078        (WebCore::Node::flagChildrenAffectedByFirstChildRulesFlag):
44079        (WebCore::Node::flagChildrenAffectedByLastChildRulesFlag):
44080        (WebCore::Node::flagChildrenAffectedByDirectAdjacentRulesFlag):
44081
440822014-04-07  Krzysztof Czech  <k.czech@samsung.com>
44083
44084        Remove unused header from PlatformSpeechSynthesizer.h
44085        https://bugs.webkit.org/show_bug.cgi?id=131103
44086
44087        Reviewed by Anders Carlsson.
44088
44089        Since WebSpeech has switched to use std::unique_ptr, we do not need to include PassOwnPtr.
44090
44091        No new tests. No behaviour change, just quick fix.
44092
44093        * platform/PlatformSpeechSynthesizer.h:
44094
440952014-04-06  Mihnea Ovidenie  <mihnea@adobe.com>
44096
44097        [CSSRegions] Use RenderRegion::isValid() before using a region
44098        https://bugs.webkit.org/show_bug.cgi?id=131232
44099
44100        Reviewed by Andreas Kling.
44101
44102        RenderRegion method isValid() should be used to test whether a region
44103        is good to use instead of a mix between isValid() and flowThread().
44104        When the region is designed to fragment content from a parent flow thread,
44105        the m_flowThread is not nullified anymore, thus ensuring the same treatment for all invalid
44106        regions.
44107        Covered by existing regions tests.
44108
44109        * inspector/InspectorOverlay.cpp:
44110        (WebCore::buildObjectForElementInfo):
44111        * rendering/RenderBox.cpp:
44112        (WebCore::RenderBox::layoutOverflowRectForPropagation):
44113        * rendering/RenderBoxModelObject.cpp:
44114        (WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
44115        * rendering/RenderLayer.cpp:
44116        (WebCore::RenderLayer::updateLayerPositions):
44117        (WebCore::RenderLayer::paintLayer):
44118        (WebCore::RenderLayer::hitTestLayer):
44119        (WebCore::RenderLayer::calculateClipRects):
44120        * rendering/RenderNamedFlowFragment.cpp:
44121        (WebCore::RenderNamedFlowFragment::pageLogicalHeight):
44122        (WebCore::RenderNamedFlowFragment::maxPageLogicalHeight):
44123        * rendering/RenderNamedFlowThread.cpp:
44124        (WebCore::RenderNamedFlowThread::getRanges):
44125        (WebCore::RenderNamedFlowThread::clearRenderObjectCustomStyle):
44126        (WebCore::RenderNamedFlowThread::checkRegionsWithStyling):
44127        * rendering/RenderRegion.cpp:
44128        (WebCore::RenderRegion::RenderRegion):
44129        (WebCore::RenderRegion::positionForPoint):
44130        (WebCore::RenderRegion::pageLogicalWidth):
44131        (WebCore::RenderRegion::pageLogicalHeight):
44132        (WebCore::RenderRegion::styleDidChange):
44133        (WebCore::RenderRegion::installFlowThread):
44134        (WebCore::RenderRegion::attachRegion):
44135        (WebCore::RenderRegion::detachRegion):
44136        (WebCore::RenderRegion::ensureOverflowForBox):
44137        (WebCore::RenderRegion::renderBoxRegionInfo):
44138
441392014-04-06  Benjamin Poulain  <benjamin@webkit.org>
44140
44141        Fix the debug bots after r166863
44142
44143        * css/PageRuleCollector.cpp:
44144        (WebCore::checkPageSelectorComponents): I forgot to update one call site for PagePseudoClass.
44145
441462014-04-06  Darin Adler  <darin@apple.com>
44147
44148        Make some bindings improvements, with smaller code size for error message generation
44149        https://bugs.webkit.org/show_bug.cgi?id=131285
44150
44151        Reviewed by Andreas Kling.
44152
44153        * WebCore.exp.in: Updated to remove old and add new functions, for use by the Internals
44154        JavaScript bindings.
44155
44156        * bindings/js/JSDOMBinding.cpp:
44157        (WebCore::makeDOMBindingsTypeErrorStringInternal): Deleted.
44158        (WebCore::throwTypeError): Added. Helper to avoid repeating throwVMError/createTypeError.
44159        (WebCore::appendArgumentMustBe): Added. Helper for building up argument error strings.
44160        (WebCore::reportDeprecatedGetterError): Added. For bindings to use.
44161        (WebCore::throwArgumentMustBeEnumError): Ditto.
44162        (WebCore::throwArgumentMustBeFunctionError): Ditto.
44163        (WebCore::throwArgumentTypeError): Ditto.
44164        (WebCore::throwArrayElementTypeError): Ditto.
44165        (WebCore::throwAttributeTypeError): Ditto.
44166        (WebCore::throwConstructorDocumentUnavailableError): Ditto.
44167        (WebCore::throwGetterTypeError): Ditto.
44168        (WebCore::throwSequenceTypeError): Ditto.
44169        (WebCore::throwSetterTypeError): Ditto.
44170        (WebCore::throwThisTypeError): Ditto.
44171
44172        * bindings/js/JSDOMBinding.h: Added declarations for new functions. Removed forward
44173        declarations for things not used in this file. Use nullptr instead of 0. Format
44174        templates consistently. Use a better for loop in the jsArray function. Removed
44175        unused HasMemoryCostMemberFunction, makeDOMBindingsTypeErrorString, and
44176        makeDOMBindingsTypeErrorStringInternal.
44177
44178        * bindings/js/JSNavigatorCustom.cpp: Fixed a hand-written binding that was using
44179        makeDOMBindingsTypeErrorString to make a string.
44180
44181        * bindings/js/ScriptController.h: Updated forward declarations.
44182
44183        * bindings/scripts/CodeGeneratorJS.pm:
44184        (GenerateImplementation): Cut down on use of UNUSED_PARAM. Use the new functions
44185        for errors, keeping the code in the generated file to a minimum.
44186        (GenerateParametersCheck): Ditto.
44187        (GenerateConstructorDefinition): Ditto.
44188
44189        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
44190        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
44191        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
44192        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
44193        * bindings/scripts/test/JS/JSTestException.cpp:
44194        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
44195        * bindings/scripts/test/JS/JSTestInterface.cpp:
44196        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
44197        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
44198        * bindings/scripts/test/JS/JSTestNode.cpp:
44199        * bindings/scripts/test/JS/JSTestObj.cpp:
44200        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
44201        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
44202        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
44203        * bindings/scripts/test/JS/JSattribute.cpp:
44204        * bindings/scripts/test/JS/JSreadonly.cpp:
44205        Updated expected results for changes above.
44206
442072014-04-06  Benjamin Poulain  <benjamin@webkit.org>
44208
44209        Move the PseudoPageClass types out of the pseudo element/class mix
44210        https://bugs.webkit.org/show_bug.cgi?id=131284
44211
44212        Reviewed by Darin Adler.
44213
44214        Some more cleanup of Selector's pseudo types. This patch moves the page pseudo
44215        class types into their own enumeration (PagePseudoClassType).
44216
44217        * css/CSSParserValues.cpp:
44218        (WebCore::CSSParserSelector::parsePagePseudoSelector):
44219        * css/CSSSelector.cpp:
44220        (WebCore::CSSSelector::specificityForPage):
44221        (WebCore::CSSSelector::pseudoId):
44222        (WebCore::CSSSelector::selectorText):
44223        * css/CSSSelector.h:
44224        (WebCore::CSSSelector::setPagePseudoType):
44225        (WebCore::CSSSelector::pagePseudoClassType):
44226        * css/PageRuleCollector.cpp:
44227        (WebCore::checkPageSelectorComponents):
44228        * cssjit/SelectorCompiler.cpp:
44229        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
44230
442312014-04-06  Benjamin Poulain  <benjamin@webkit.org>
44232
44233        CSS JIT: add support for :last-child and :only-child
44234        https://bugs.webkit.org/show_bug.cgi?id=131283
44235
44236        Reviewed by Andreas Kling.
44237
44238        This is the straightforward implementation of :last-child and :only-child.
44239
44240        Both are extremely similar to :first-child. There are only minor differences:
44241        -:last-child has an additional check for the flag IsParsingChildrenFinished.
44242        -:only-child is like :first-child + :last-child but with combined marking.
44243
44244        * cssjit/SelectorCompiler.cpp:
44245        (WebCore::SelectorCompiler::addPseudoType):
44246        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToNextAdjacentElement):
44247        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
44248        (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNoPreviousAdjacentElement):
44249        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
44250        (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNoNextAdjacentElement):
44251        (WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByLastChildRules):
44252        (WebCore::SelectorCompiler::setLastChildState):
44253        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLastChild):
44254        (WebCore::SelectorCompiler::markElementWithSetChildrenAffectedByFirstChildAndLastChildRules):
44255        (WebCore::SelectorCompiler::setOnlyChildState):
44256        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsOnlyChild):
44257        * dom/Node.h:
44258        (WebCore::Node::nextSiblingMemoryOffset):
44259        (WebCore::Node::flagIsParsingChildrenFinished):
44260        * rendering/style/RenderStyle.h:
44261        Removed the unused flags, I will add them back later as needed.
44262
442632014-04-06  Darin Adler  <darin@apple.com>
44264
44265        Rework CSS calc logic, fixing some reference count mistakes in Length
44266        https://bugs.webkit.org/show_bug.cgi?id=131280
44267        rdar://problem/16400823
44268
44269        Reviewed by Andreas Kling.
44270
44271        New unit test in TestWebKitAPI.
44272
44273        Changed the classes related to CSS "calc" to make the code a bit easier to read by
44274        moving code out of class definitions. Also used final some more, made more things private,
44275        used references instead of pointers, and other such changes. Biggest change, though, is to
44276        Length, which had a broken system for managing reference counted calculated objects.
44277        There were multiple bugs including a basic design mistake of not having a reference count
44278        and trying to use the reference count in the object itself. Fixed and covered by the unit
44279        test now; test found multiple problems in both the old and new implementations.
44280
44281        * WebCore.exp.in: Updated exports, including symbols to make the unit test practical.
44282
44283        * WebCore.xcodeproj/project.pbxproj: Made CalculationValue.h a Private file so it can
44284        be used in a unit test. Also let Xcode update the file type for a gperf file.
44285
44286        * css/CSSCalculationValue.cpp:
44287        (WebCore::CSSCalcValue::equals): Updated since m_expression is a Ref now.
44288        (WebCore::CSSCalcValue::clampToPermittedRange): Marked inline and updated for data member
44289        name change.
44290        (WebCore::isIntegerResult): Changed argument order to put the operator first and use
44291        references instead of pointers. Also marked inline.
44292        (WebCore::createBlendHalf): Added. Helper to make the other functions more readable.
44293        (WebCore::createExpressionNode): Made non-member function private to this file. Also made
44294        many small improvements.
44295        (WebCore::CSSCalcValue::create): Updated so both of these call the same constructor.
44296
44297        * css/CSSCalculationValue.h: Cut down CSSCalcValue class by making more things private
44298        and deleting unneeded things. Also use Ref instead of RefPtr.
44299
44300        * css/CSSComputedStyleDeclaration.cpp:
44301        (WebCore::getPositionOffsetValue): Use isFixed function instead of type function.
44302
44303        * css/CSSGradientValue.cpp:
44304        (WebCore::CSSGradientValue::addStops): Updated code since toCalcValue now returns PassRef
44305        instead of PassRefPtr. Unfortunately the new code is a bit more verbose.
44306        (WebCore::positionFromValue): Ditto.
44307
44308        * css/CSSParser.cpp:
44309        (WebCore::CSSParser::parseCalculation):
44310
44311        * css/CSSPrimitiveValue.cpp:
44312        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Updated to pass reference rather than pointer.
44313        (WebCore::CSSPrimitiveValue::init): Ditto.
44314
44315        * css/CSSToStyleMap.h: Removed unneeded include of LengthBox.h.
44316
44317        * css/DeprecatedStyleBuilder.cpp:
44318        (WebCore::ApplyPropertyLength::applyValue): Updated for function name change.
44319        (WebCore::ApplyPropertyBorderRadius::applyValue): Removed extra parentheses.
44320        (WebCore::ApplyPropertyFontSize::applyValue): Ditto. Also updated since toCalcValue returns Ref.
44321
44322        * css/LengthFunctions.cpp:
44323        (WebCore::floatValueForLength): Updated to call value instead of getFloatValue; both are the same.
44324
44325        * css/StyleResolver.cpp:
44326        (WebCore::addIntrinsicMargins): Updated for function name change.
44327        (WebCore::createGridTrackBreadth): Ditto.
44328
44329        * platform/CalculationValue.cpp:
44330        (WebCore::CalculationValue::create): Changed to return PassRef.
44331        (WebCore::CalcExpressionNumber::evaluate): Moved this function out of the header, since it's
44332        virtual and not really going to be inlined.
44333        (WebCore::CalcExpressionNumber::operator==): Ditto.
44334        (WebCore::CalculationValue::evaluate): Ditto.
44335        (WebCore::CalcExpressionBinaryOperation::operator==): Ditto.
44336        (WebCore::CalcExpressionLength::evaluate): Ditto.
44337        (WebCore::CalcExpressionLength::operator==): Ditto.
44338        (WebCore::CalcExpressionBlendLength::evaluate): Ditto.
44339        (WebCore::CalcExpressionBlendLength::operator==): Ditto.
44340
44341        * platform/CalculationValue.h: Moved most functions out of the class bodies so the classes are
44342        easier to see. Made all the == operator functions non-member ones except for the polymorphic
44343        one from the base class. Changed the casting functions to work on references instead of pointers.
44344        Tweaked name of some members.
44345
44346        * platform/Length.cpp: Reworked the CalculationValueMap (formerly CalculationValueHandleMap) to
44347        use unsigned instead of int, and store reference counts in the map rather than trying to share the
44348        reference count of the underlying CalculationValue object, which can lead to storage leaks where
44349        handles end up in the map permanently.
44350        (WebCore::calculationValues): Use NeverDestroyed instead of DEPRECATED_DEFINE_STATIC_LOCAL.
44351        (WebCore::Length::Length): Updated some data member names.
44352        (WebCore::Length::calculationValue): Updated to return a reference instead of a PassRefPtr.
44353        (WebCore::Length::ref): Renamed and updated for new interface to the map.
44354        (WebCore::Length::deref): Ditto.
44355        (WebCore::Length::nonNanCalculatedValue): Updated to use a reference instead of a pointer.
44356        (WebCore::Length::isCalculatedEqual): Updated since this is now only called if both objects are
44357        known to be calculated values.
44358
44359        * platform/Length.h: Moved most functions out of the class definition to make the class definition
44360        easier to read. Reworked the constructors and assignment operators to handle the reference counting
44361        correctly. Added various FIXMEs and assertions. Removed some unused functions, made others private.
44362
44363        * platform/LengthBox.h: Renamed some one-letter arguments to use words instead.
44364
44365        * rendering/AutoTableLayout.cpp:
44366        (WebCore::AutoTableLayout::recalcColumn): Updated for change to Length::setValue.
44367        * rendering/FixedTableLayout.cpp:
44368        (WebCore::FixedTableLayout::calcWidthArray): Ditto.
44369
44370        * rendering/style/FillLayer.h:
44371        (WebCore::FillLayer::initialFillXPosition): Updated to not convert a double to a float at runtime.
44372        (WebCore::FillLayer::initialFillYPosition): Ditto.
44373
44374        * rendering/style/RenderStyle.cpp:
44375        (WebCore::RenderStyle::setWordSpacing): Removed a bogus FALLTHROUGH that was clearly wrong, but
44376        harmless. Updated for changes to Length.
44377
44378        * rendering/style/RenderStyle.h: Updated for name changes and to avoid converting doubles to floats
44379        at runtime.
44380
443812014-04-06  Brent Fulgham  <bfulgham@apple.com>
44382
44383        Honor System-Level User Preferences for Caption Display
44384        https://bugs.webkit.org/show_bug.cgi?id=131258
44385
44386        Reviewed by Eric Carlson.
44387
44388        * html/HTMLMediaElement.cpp:
44389        (WebCore::HTMLMediaElement::setSelectedTextTrack): Allow preferenced change to fully dispatch
44390        so we can properly deal with captions being turned off.
44391        (WebCore::HTMLMediaElement::captionPreferencesChanged): Use 'webkit' variant of the
44392        setWebKitClosedCaptionsVisible method so we properly adjust settings needed for the JS API call.
44393        * html/shadow/MediaControlElements.cpp:
44394        (WebCore::MediaControlTextTrackContainerElement::updateDisplay): When captions are turned off, e.g.
44395        because the user turned off the preference, don't inadvertently turn them back on just bacause there
44396        was an existing track that was not in a 'hidden' state.
44397
443982014-04-06  Brian J. Burg  <burg@cs.washington.edu>
44399
44400        Web Replay: add methods to encode a frame's index based on its FrameTree position
44401        https://bugs.webkit.org/show_bug.cgi?id=131281
44402
44403        Reviewed by Timothy Hatcher.
44404
44405        Given a frame, its encoded index is computed by traversing the frame tree
44406        and saving how many nodes have been traversed to reach a given frame.
44407
44408        This is used to disambiguate frames when dispatching frame-specific event
44409        loop inputs during replay, such as timers and resource loaders.
44410
44411        * replay/SerializationMethods.cpp:
44412        (WebCore::frameIndexFromDocument): Added.
44413        (WebCore::frameIndexFromFrame): Added.
44414        (WebCore::documentFromFrameIndex): Added.
44415        (WebCore::frameFromFrameIndex): Added.
44416        * replay/SerializationMethods.h:
44417
444182014-04-06  Alexey Proskuryakov  <ap@apple.com>
44419
44420        iOS build fix.
44421
44422        * WebCore.exp.in: Move newly exported function to a right section of this file.
44423
444242014-04-06  Darin Adler  <darin@apple.com>
44425
44426        Refactor post-attach and HTMLObjectElement-related code
44427        https://bugs.webkit.org/show_bug.cgi?id=131282
44428
44429        Reviewed by Antti Koivisto.
44430
44431        * dom/ContainerNode.cpp: Moved the post-attach callback code from here to
44432        StyleResolveTree.h/cpp.
44433        * dom/ContainerNode.h: Ditto.
44434
44435        * dom/Document.cpp:
44436        (WebCore::Document::recalcStyle): Use Style::PostResolutionCallbackDisabler instead of
44437        PostAttachCallbackDisabler.
44438
44439        * dom/Element.h: Moved the post-attach callback code from here to StyleResolveTree.h/cpp.
44440
44441        * html/HTMLEmbedElement.cpp:
44442        (WebCore::HTMLEmbedElement::parseAttribute): Simplified the code for typeAttr, turning
44443        it into a 1-liner. Added a FIXME in codeAttr about the fact that it does not have the
44444        code to trigger image loads.
44445
44446        * html/HTMLFormControlElement.cpp:
44447        (WebCore::HTMLFormControlElement::didAttachRenderers): Updated to use
44448        Style::queuePostResolutionCallback and use a lambda instead of a function.
44449        (WebCore::HTMLFormControlElement::didRecalcStyle): Ditto. Also added RefPtr instead
44450        of just using wishful thinking to keep the object alive.
44451        * html/HTMLFrameOwnerElement.cpp:
44452        (WebCore::HTMLFrameOwnerElement::scheduleSetNeedsStyleRecalc): Ditto.
44453
44454        * html/HTMLObjectElement.cpp:
44455        (WebCore::HTMLObjectElement::parseAttribute):: Simplified the code for typeAttr, turning
44456        it into a 1-liner. Made dataAttr call setNeedsWidgetUpdate(true) unconditionally after
44457        checking carefully to see that's harmless if there is no renderer. Changed classidAttr
44458        to call setNeedsWidgetUpdate(true) unconditionally and not set m_classId.
44459        (WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk): Use fastGetAttribute
44460        instead of classId and descendantsOfType instead of getElementsByTagName.
44461        (WebCore::HTMLObjectElement::hasValidClassId): Use fastGetAttribute instead of classId.
44462        (WebCore::HTMLObjectElement::renderFallbackContent): Use imageLoader instead of m_imageLoader.
44463
44464        * html/HTMLObjectElement.h: Removed classId, since there is no reason to cache that
44465        attribute in a data member. Rearranged header, making more private, and fixing some typos,
44466        and doing a "using" instead of a function to disambiguate the inherited form functions.
44467
44468        * html/HTMLPlugInImageElement.cpp:
44469        (WebCore::HTMLPlugInImageElement::createElementRenderer): Fixed some code that assumed the
44470        first child of the shadow root is guaranteed to be an element.
44471        (WebCore::HTMLPlugInImageElement::didMoveToNewDocument): Removed null check on oldDocument,
44472        since m_needsDocumentActivationCallbacks can't be true if the old document was null.
44473        (WebCore::is100Percent): Added helper to make function below more readable.
44474        (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Restructured the code a
44475        bit. The part that attracted my attention was the local variable of type RenderBox, which
44476        was named renderEmbeddedObject. Turns out the caller guarantees to only call this if there
44477        is a renderer of type RenderEmbeddedObject, so depend on that.
44478
44479        * html/HTMLPlugInImageElement.h: Trimmed includes a bit. Made more members private.
44480        Marked more function members final. Made a protected imageLoader function so that
44481        m_imageLoader can be private eventually. Made m_imageLoader be std::unique_ptr.
44482
44483        * style/StyleResolveTree.cpp:
44484        (WebCore::Style::needsPseudoElement): Fixed spelling error in the name of this function.
44485        (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded): Updated for name change.
44486        (WebCore::Style::attachRenderTree): Update for new name of PostResolutionCallbackDisabler.
44487        (WebCore::Style::updateBeforeOrAfterPseudoElement): Updated for name change.
44488        (WebCore::Style::postResolutionCallbackQueue): Added.
44489        (WebCore::Style::queuePostResolutionCallback): Added.
44490        (WebCore::Style::suspendMemoryCacheClientCalls): Added. This is a side effect of the original
44491        PostAttachCallbackDisabler that is now done in a cleaner way, using the callback queue, instead
44492        of as a special case. It should not work for multiple documents across multiple pages instead of
44493        only the outermost one.
44494        (WebCore::Style::PostResolutionCallbackDisabler::PostResolutionCallbackDisabler): Added.
44495        Calls suspendMemoryCacheClientCalls, but a FIXME tries to point out why that isn't so great.
44496        (WebCore::Style::PostResolutionCallbackDisabler::~PostResolutionCallbackDisabler): Added.
44497        (WebCore::Style::postResolutionCallbacksAreSuspended): Added.
44498
44499        * style/StyleResolveTree.h: Added queuePostResolutionCallback and
44500        postResolutionCallbacksAreSuspended. Also added PostResolutionCallbackDisabler, which should
44501        eventually become a private implementation detail.
44502
445032014-04-04  Brian J. Burg  <burg@cs.washington.edu>
44504
44505        Enable WEB_REPLAY for PLATFORM(MAC)
44506        https://bugs.webkit.org/show_bug.cgi?id=130700
44507
44508        Reviewed by Timothy Hatcher.
44509
44510        Switch on WEB_REPLAY feature flag for non-production builds.
44511
44512        * Configurations/FeatureDefines.xcconfig:
44513        * replay/ReplayInputDispatchMethods.cpp: Fix the ENABLE(WEB_REPLAY) build.
44514        It was broken by the bool to enum refactoring in r166684.
44515        (WebCore::InitialNavigation::dispatch):
44516
445172014-04-05  Brian J. Burg  <burg@cs.washington.edu>
44518
44519        Web Inspector: remove unused test hook setInspectorResourcesDataSizeLimits
44520        https://bugs.webkit.org/show_bug.cgi?id=131268
44521
44522        Reviewed by Timothy Hatcher.
44523
44524        This was used in the old inspector frontend tests for the Network panel.
44525        It's no longer used by any tests or frontend code.
44526
44527        * WebCore.exp.in: Remove symbols.
44528        * inspector/InspectorController.cpp:
44529        (WebCore::InspectorController::setInspectorResourcesDataSizeLimits): Deleted.
44530        * inspector/InspectorController.h:
44531        * inspector/InspectorResourceAgent.cpp:
44532        (WebCore::InspectorResourceAgent::setResourcesDataSizeLimitsFromInternals): Deleted.
44533        * inspector/InspectorResourceAgent.h:
44534        * inspector/NetworkResourcesData.cpp:
44535        (WebCore::NetworkResourcesData::setResourcesDataSizeLimits): Deleted.
44536        * inspector/NetworkResourcesData.h:
44537        * testing/Internals.cpp:
44538        (WebCore::Internals::setInspectorResourcesDataSizeLimits): Deleted.
44539        * testing/Internals.h:
44540        * testing/Internals.idl:
44541
445422014-04-05  Alexey Proskuryakov  <ap@apple.com>
44543
44544        REGRESSION (NetworkProcess): Subresources fail to load from AppCache
44545        https://bugs.webkit.org/show_bug.cgi?id=131262
44546        <rdar://problem/15370653>
44547
44548        Reviewed by Sam Weinig.
44549
44550        Exported ApplicationCacheHost::maybeLoadResource. Changed it to take a const
44551        reference to ResourceRequest, as appropriate for WebResourceLoadScheduler.
44552
44553        * WebCore.exp.in:
44554        * WebCore.xcodeproj/project.pbxproj:
44555        * loader/appcache/ApplicationCacheHost.cpp:
44556        (WebCore::ApplicationCacheHost::maybeLoadResource):
44557        * loader/appcache/ApplicationCacheHost.h:
44558
445592014-04-05  Brian J. Burg  <burg@cs.washington.edu>
44560
44561        Web Inspector: remove unused metrics and commands from the Timeline agent
44562        https://bugs.webkit.org/show_bug.cgi?id=131184
44563
44564        Reviewed by Timothy Hatcher.
44565
44566        This patch removes several instrumentation hooks that are not being
44567        used by the frontend in any way. Most of them are not hooked up to
44568        produce any data, so they just clutter up InspectorClient and the agent.
44569
44570        * WebCore.exp.in: Remove didBeginFrame/didCancelFrame.
44571        * inspector/InspectorClient.h: Remove client methods that are never overridden.
44572        (WebCore::InspectorClient::canMonitorMainThread): Deleted.
44573        (WebCore::InspectorClient::supportsFrameInstrumentation): Deleted.
44574        (WebCore::InspectorClient::getAllocatedObjects): Deleted.
44575        (WebCore::InspectorClient::dumpUncountedAllocatedObjects): Deleted.
44576
44577        * inspector/InspectorController.cpp: Remove unused instrumentation.
44578        (WebCore::InspectorController::didBeginFrame): Deleted.
44579        (WebCore::InspectorController::didCancelFrame): Deleted.
44580        (WebCore::InspectorController::didComposite): Deleted.
44581        (WebCore::InspectorController::wilComposite): Deleted.
44582        * inspector/InspectorController.h:
44583
44584        * inspector/InspectorTimelineAgent.cpp: Remove the backend's BeginFrame enum
44585        value, but keep it in the protocol for when it is reimplemented. Remove
44586        management of the current frame record, and simplify some code.
44587        (WebCore::toProtocol):
44588        (WebCore::InspectorTimelineAgent::addRecordToTimeline):
44589        (WebCore::InspectorTimelineAgent::didCompleteCurrentRecord):
44590        (WebCore::InspectorTimelineAgent::pushCurrentRecord):
44591        (WebCore::InspectorTimelineAgent::clearRecordStack):
44592        (WebCore::InspectorTimelineAgent::canMonitorMainThread): Deleted.
44593        (WebCore::InspectorTimelineAgent::supportsFrameInstrumentation): Deleted.
44594        (WebCore::InspectorTimelineAgent::didBeginFrame): Deleted.
44595        (WebCore::InspectorTimelineAgent::didCancelFrame): Deleted.
44596        (WebCore::InspectorTimelineAgent::didComposite): Deleted.
44597        (WebCore::InspectorTimelineAgent::wilComposite): Deleted.
44598        (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline): Deleted. Undo telescoping.
44599        (WebCore::usedHeapSize): Deleted.
44600        (WebCore::InspectorTimelineAgent::commitFrameRecord): Deleted.
44601        * inspector/InspectorTimelineAgent.h:
44602        (WebCore::InspectorTimelineAgent::TimelineRecordEntry::TimelineRecordEntry):
44603        * inspector/protocol/Timeline.json:
44604
44605        * platform/graphics/texmap/coordinated/CompositingCoordinator.cpp: Remove
44606        instrumentation hook for beginFrame. This is the only backend that implements it.
44607        (WebCore::CompositingCoordinator::syncDisplayState):
44608
44609        * testing/Internals.cpp: Remove crufty test methods that aren't used.
44610        (WebCore::Internals::emitInspectorDidBeginFrame): Deleted.
44611        (WebCore::Internals::emitInspectorDidCancelFrame): Deleted.
44612        * testing/Internals.h:
44613        * testing/Internals.idl:
44614
446152014-04-05  Alexey Proskuryakov  <ap@apple.com>
44616
44617        REGRESSION (r163914): Application cache cannot be used in main frame
44618        https://bugs.webkit.org/show_bug.cgi?id=131263
44619        <rdar://problem/16532063>
44620
44621        Reviewed by Sam Weinig.
44622
44623        * loader/appcache/ApplicationCacheHost.cpp: (WebCore::ApplicationCacheHost::isApplicationCacheBlockedForRequest):
44624        Don't check main frame origin when loading into main frame, it's not a 3rd party
44625        subframe, and the URL is unrelated to the page we are loading now.
44626
44627        * loader/appcache/ApplicationCacheGroup.cpp: (WebCore::ApplicationCacheGroup::cacheForMainRequest):
44628        Removed the same incorrect check that was duplicated here. The only caller already
44629        checks isApplicationCacheBlockedForRequest().
44630
446312014-04-05  Dan Bernstein  <mitz@apple.com>
44632
44633        [Xcode] Clean up the platform/graphics group
44634        https://bugs.webkit.org/show_bug.cgi?id=131271
44635
44636        Reviewed by Eric Carlson.
44637
44638        * WebCore.xcodeproj/project.pbxproj: Created an opentype group and moved opentype file
44639        references into it. Removed duplicate file references.
44640
446412014-04-05  Andreas Kling  <akling@apple.com>
44642
44643        Remove unused type casting helpers for HTMLUnknownElement...
44644
44645        ...to fix the debug build.
44646
44647        * html/HTMLUnknownElement.h:
44648
446492014-04-05  Dirk Schulze  <krit@webkit.org>
44650
44651        Canvas strokeText and fillText with SourceIn, DestinationIn, SourceOut, DestinationAtop and Copy have errors
44652        https://bugs.webkit.org/show_bug.cgi?id=66766
44653
44654        Reviewed by Andreas Kling.
44655
44656        Use transparency layers to draw text with certain compositing modes on
44657        the canvas. This follows the Canvas specification and makes WebKit fully
44658        compatible with IE. It also makes it more compatible with Firefox, even though
44659        Firefox still has some bugs.
44660
44661        Test: fast/canvas/canvas-composite-text-alpha.html
44662
44663        * html/canvas/CanvasRenderingContext2D.cpp:
44664        (WebCore::CanvasRenderingContext2D::drawTextInternal):
44665
446662014-04-05  Andreas Kling  <akling@apple.com>
44667
44668        Devirtualize isHTMLUnknownElement().
44669        <https://webkit.org/b/131269>
44670
44671        We were hitting isHTMLUnknownElement() pretty hard when marking
44672        out-of-document Nodes. (The check is part of isHTMLAudioElement()
44673        which is called by JSNodeOwner::isReachableFromOpaqueRoots().)
44674
44675        This patch uses a Node flag for the unknown element instead.
44676        I'm also adding HTMLUnknownElement.{h,idl} to the Xcode project
44677        since they were suspiciously missing.
44678
44679        Reviewed by Benjamin Poulain.
44680
44681        * WebCore.xcodeproj/project.pbxproj:
44682        * dom/Node.h:
44683        * html/HTMLElement.h:
44684        (WebCore::HTMLElement::isHTMLUnknownElement):
44685        * html/HTMLUnknownElement.h:
44686        (WebCore::toHTMLUnknownElement): Deleted.
44687
446882014-04-05  Dirk Schulze  <krit@webkit.org>
44689
44690        Canvas stroke and strokeRect with SourceIn, DestinationIn, SourceOut, DestinationAtop and Copy have errors
44691        https://bugs.webkit.org/show_bug.cgi?id=66762
44692
44693        Reviewed by Andreas Kling.
44694
44695        For fill operations we create a new ImageBuffer to ensure that the results are composited
44696        correctly according to the Canvas spec. This patch creates a new transparency layer
44697        for stroking on certain compositing operators to archive the same. This makes WebKit's
44698        behavior interoperable with Firefox and IE as well. 
44699
44700        Test: fast/fast/canvas/canvas-composite-stroke-alpha.html
44701
44702        * html/canvas/CanvasRenderingContext2D.cpp:
44703        (WebCore::CanvasRenderingContext2D::strokeInternal):
44704        (WebCore::CanvasRenderingContext2D::strokeRect):
44705
447062014-04-05  Yusuke Suzuki  <utatane.tea@gmail.com>
44707
44708        Use preallocated stack reference to store adjacentBacktrackingStart
44709        https://bugs.webkit.org/show_bug.cgi?id=131237
44710
44711        Reviewed by Benjamin Poulain.
44712
44713        * cssjit/SelectorCompiler.cpp:
44714        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
44715        (WebCore::SelectorCompiler::SelectorCodeGenerator::computeBacktrackingInformation):
44716        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
44717        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
44718        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAdjacentBacktrackingTail):
44719        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateBacktrackingTailsIfNeeded):
44720        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToPreviousAdjacent): Deleted.
44721        (WebCore::SelectorCompiler::SelectorCodeGenerator::linkFailures): Deleted.
44722        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDescendantBacktrackingTail): Deleted.
44723        * cssjit/StackAllocator.h:
44724        (WebCore::StackAllocator::allocateUninitialized):
44725
447262014-04-05  Jeongeun Kim  <je_julie.kim@samsung.com>
44727
44728        bad values from HTMLImageElement x and y attributes (CSSOM-View)
44729        https://bugs.webkit.org/show_bug.cgi?id=130308
44730        
44731        Reviewed by Simon Fraser.
44732
44733        According to CSSOM-View, interface HTMLImageElement,
44734        The x attribute must return the x-coordinate.
44735        If style is not updated when x() is called, it can’t return anything.
44736        Style and layout should be done before getting value for x() and y(). 
44737
44738        Test: cssom/cssom-view-img-attributes-001.html
44739
44740        * html/HTMLImageElement.cpp:
44741        (WebCore::HTMLImageElement::x):
44742        (WebCore::HTMLImageElement::y):
44743
447442014-04-05  Zoltan Horvath  <zoltan@webkit.org>
44745
44746        [CSS Shapes] Remove CSSBoxType member from BasicShape and CSSBasicShape
44747        https://bugs.webkit.org/show_bug.cgi?id=129706
44748
44749        Reviewed by Andreas Kling.
44750
44751        The CSSBoxType has been moved up to ShapeValue and is no longer needed in the BasicShape classes.
44752
44753        No new tests, no behavior change.
44754
44755        * css/BasicShapeFunctions.cpp:
44756        (WebCore::valueForBasicShape):
44757        (WebCore::basicShapeForValue):
44758        * rendering/style/BasicShapes.cpp:
44759        (WebCore::BasicShape::canBlend):
44760        * rendering/style/BasicShapes.h:
44761        (WebCore::BasicShape::referenceBox): Deleted.
44762        (WebCore::BasicShape::setReferenceBox): Deleted.
44763        (WebCore::BasicShape::BasicShape): Deleted.
44764
447652014-04-05  Mark Rowe  <mrowe@apple.com>
44766
44767        Fix the 32-bit build after r166818.
44768
44769        * WebCore.exp.in:
44770
447712014-04-03  Brian J. Burg  <burg@cs.washington.edu>
44772
44773        Web Inspector: hook up probe samples to TimelineAgent's records
44774        https://bugs.webkit.org/show_bug.cgi?id=131127
44775
44776        Reviewed by Timothy Hatcher.
44777
44778        Hook up probe callbacks from ScriptDebugListener so that timeline records are
44779        created for probe samples. The record includes the probe identifier and hit count.
44780        The actual probe evaluation result is sent separately by DebuggerAgent, and
44781        can be looked up in frontend models using the identifier and hit count.
44782
44783        * inspector/InspectorTimelineAgent.cpp: Only listen to the debug server when recording.
44784        (WebCore::InspectorTimelineAgent::start):
44785        (WebCore::InspectorTimelineAgent::stop):
44786        (WebCore::InspectorTimelineAgent::breakpointActionProbe):
44787        (WebCore::toProtocol):
44788        * inspector/InspectorTimelineAgent.h:
44789        * inspector/TimelineRecordFactory.cpp:
44790        (WebCore::TimelineRecordFactory::createProbeSampleData):
44791        * inspector/TimelineRecordFactory.h:
44792        * inspector/protocol/Timeline.json: Add new enum value.
44793
447942014-04-04  Andreas Kling  <akling@apple.com>
44795
44796        Streamline cached wrapper lookup for Nodes in the normal world.
44797        <https://webkit.org/b/131249>
44798
44799        Inline the hot path for toJS(..., Node*) for cached wrapper lookups
44800        in the normal world. (Or really, out-of-line the cold path, since
44801        that was preventing the compiler from inlining this function.)
44802
44803        Also have JSDOMGlobalObject cache the "is normal world" flag from
44804        the DOMWrapperWorld so we can avoid the extra load.
44805
44806        Reviewed by Benjamin Poulain.
44807
44808        * WebCore.exp.in:
44809        * bindings/js/JSDOMGlobalObject.cpp:
44810        (WebCore::JSDOMGlobalObject::JSDOMGlobalObject):
44811        * bindings/js/JSDOMGlobalObject.h:
44812        (WebCore::JSDOMGlobalObject::worldIsNormal):
44813        * bindings/js/JSNodeCustom.cpp:
44814        (WebCore::getOutOfLineCachedWrapper):
44815        * bindings/js/JSNodeCustom.h:
44816        (WebCore::toJS):
44817
448182014-04-04  Brady Eidson  <beidson@apple.com>
44819
44820        Show DataDetector UI on scanned phone numbers.
44821        <rdar://problem/16379588> and https://bugs.webkit.org/show_bug.cgi?id=131247
44822
44823        Reviewed by Tim Horton.
44824
44825        Gather the ranges of the scanned telephone numbers and send them up to WK2:
44826        * editing/Editor.cpp:
44827        (WebCore::Editor::respondToChangedSelection):
44828        (WebCore::Editor::scanSelectionForTelephoneNumbers):
44829        (WebCore::Editor::scanRangeForTelephoneNumbers):
44830        * editing/Editor.h:
44831
44832        Add client method to receive scanned telephone number ranges:
44833        * page/EditorClient.h:
44834        (WebCore::EditorClient::selectedTelephoneNumberRangesChanged):
44835
44836        Remove unneeded placeholder UI:
44837        * rendering/InlineTextBox.cpp:
44838        (WebCore::InlineTextBox::paintDocumentMarkers):
44839        (WebCore::InlineTextBox::computeRectForReplacementMarker): Deleted.
44840        (WebCore::InlineTextBox::paintCompositionUnderline): Deleted.
44841        * rendering/InlineTextBox.h:
44842        (WebCore::InlineTextBox::expansionBehavior): Deleted.
44843
448442014-04-04  James Craig  <jcraig@apple.com>
44845
44846        AX: supportsARIAExpanded should always return true for a few roles: combobox, disclosure.
44847        https://bugs.webkit.org/show_bug.cgi?id=129787
44848
44849        Reviewed by Chris Fleizach.
44850
44851        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
44852
44853        * accessibility/AccessibilityObject.cpp:
44854        (WebCore::AccessibilityObject::supportsARIAExpanded):
44855
448562014-04-04  Andreas Kling  <akling@apple.com>
44857
44858        JSGenerateToNativeObject should use fast JSNode/JSElement casts.
44859        <https://webkit.org/b/131245>
44860
44861        Make JSGenerateToNativeObject spit out code using the fast new wrapper
44862        casts for JSNode and JSElement.
44863
44864        This avoids walking the ClassInfo chain in many core functions, e.g:
44865
44866            - Node.insertBefore()
44867            - Node.replaceChild()
44868            - Node.removeChild()
44869            - Node.appendChild()
44870            - window.getComputedStyle()
44871
44872        Reviewed by Geoff Garen.
44873
44874        * bindings/scripts/CodeGeneratorJS.pm:
44875        (GenerateImplementation):
44876
448772014-04-04  Zoltan Horvath  <zoltan@webkit.org>
44878
44879        [CSS Shapes] polygon y-value calc() args serialize incorrectly
44880        https://bugs.webkit.org/show_bug.cgi?id=129842
44881
44882        Reviewed by Bem Jones-Bey.
44883
44884        The code hit ASSERT(isCalculation(value)) in CSSParser::createPrimitiveNumbericValue, because
44885        CSSParser::validUnit had been called on both coordinates, which set the value for m_parsedCalculation,
44886        but only one of the coordinates was calculation value. I reordered calling valudUnit and
44887        createPrimitiveNumbericValue to be called in the correct order on the coordinates.
44888
44889        I added the new test case to parsing-test-utils.js.
44890
44891        * css/CSSParser.cpp:
44892        (WebCore::CSSParser::parseBasicShapePolygon):
44893
448942014-04-04  Brian J. Burg  <burg@cs.washington.edu>
44895
44896        Web Replay: capture and replay wheel events and scroll commands
44897        https://bugs.webkit.org/show_bug.cgi?id=129402
44898
44899        Reviewed by Timothy Hatcher and Simon Fraser.
44900
44901        To capture and replay scrolling, the scrolling coordinator will force synchronous 
44902        scrolling during capture and replay. If the page is capturing or replaying,
44903        ForceOnMainThread will be added to the coordinator's SynchronousScrollingReasons.
44904
44905        A callback was added to signal that replay session state have changed,
44906        and thus the synchronous scrolling reasons should be recomputed.
44907
44908        Automated replay reftests for scrolling are not included, because they will be
44909        too flaky until more nondeterminism is handled. Specifically, resource loading,
44910        initial focus/active state, and parsing are known blocking issues.
44911
44912        Test: ManualTests/inspector/replay-wheel-events.html
44913
44914        * page/scrolling/ScrollingCoordinator.cpp: Add a new callback for replay state
44915        session changes. Add ForceOnMainThread if the page's active input cursor is
44916        capturing or replaying.
44917
44918        (WebCore::ScrollingCoordinator::synchronousScrollingReasons):
44919        (WebCore::ScrollingCoordinator::replaySessionStateDidChange): Added.
44920        * page/scrolling/ScrollingCoordinator.h:
44921
44922        * platform/PlatformWheelEvent.h:
44923        * platform/ScrollTypes.h: Add explicit enum storage types so these enums can
44924        be forward-declared. This is necessary to generate enum encode/decode implementations.
44925
44926        * replay/ReplayController.cpp:
44927        (WebCore::ReplayController::setForceDeterministicSettings): If async scrolling
44928        support is available, tell the scrolling tree to behave deterministically.
44929
44930        * replay/ReplayInputDispatchMethods.cpp:
44931        (WebCore::HandleWheelEvent::dispatch): Added.
44932        (WebCore::LogicalScrollPage::dispatch): Added.
44933        (WebCore::ScrollPage::dispatch): Added.
44934        * replay/SerializationMethods.cpp: Introduce more specific macros for values
44935        deserialized to arbitraray lvalues, scalars, RefPtr, and unique_ptr. Fix existing
44936        uses of decode macros.
44937
44938        (JSC::EncodingTraits<NondeterministicInputBase>::encodeValue): Fix macro name.
44939        (JSC::EncodingTraits<KeypressCommand>::encodeValue): Fix macro name.
44940        (JSC::EncodingTraits<PlatformKeyboardEvent>::encodeValue): Fix macro name.
44941        (JSC::EncodingTraits<PlatformMouseEvent>::encodeValue): Fix macro name.
44942        (JSC::PlatformWheelEventCocoa::PlatformWheelEventCocoa): Added. Encapsulate
44943        and initialize data members specific to PLATFORM(COCOA).
44944
44945        (JSC::EncodingTraits<PlatformWheelEvent>::encodeValue): Added.
44946        (JSC::EncodingTraits<PlatformWheelEvent>::decodeValue): Added.
44947        * replay/SerializationMethods.h:
44948        * replay/UserInputBridge.cpp: Fill in bridge methods to capture inputs.
44949        (WebCore::UserInputBridge::handleWheelEvent):
44950        (WebCore::UserInputBridge::scrollRecursively):
44951        (WebCore::UserInputBridge::logicalScrollRecursively):
44952        * replay/WebInputs.json: Add inputs and new enum types.
44953
449542014-04-04  Yusuke Suzuki  <utatane.tea@gmail.com>
44955
44956        Upgrade to SelectorFailsAllSiblings when Child selector is failed.
44957        https://bugs.webkit.org/show_bug.cgi?id=130961
44958
44959        Reviewed by Benjamin Poulain.
44960
44961        When Child selector fails, we should resume matching from the closest
44962        Descendant selector.
44963        So upgrading SelectorFailsLocally to SelectorFailsAllSibling at least
44964        to prevent unnecessary direct/indirect adjacent selectors matching.
44965
44966        * css/SelectorChecker.cpp:
44967        (WebCore::SelectorChecker::matchRecursively):
44968
449692014-04-04  Roger Fong  <roger_fong@apple.com>
44970
44971        Keep track of filtered active attribute/uniform indices per shader program.
44972        https://bugs.webkit.org/show_bug.cgi?id=131235.
44973
44974        Reviewed by Dean Jackson.
44975
44976        Tests: Covered by existing Khronos Conformance tests. 
44977        Will create a test to use multiple shader programs in a follow-up patch.
44978
44979        * html/canvas/WebGLProgram.cpp:
44980        (WebCore::WebGLProgram::cacheActiveAttribLocations): Use getActiveAttribImpl. We do not need to use the filtered list of attributes here.
44981        * html/canvas/WebGLRenderingContext.cpp:
44982        (WebCore::WebGLRenderingContext::getUniformLocation): Use filtered list of uniforms for uniform count.
44983        * platform/graphics/GraphicsContext3D.h: Create a map of shader programs to ActiveShaderSymbolCounts.
44984        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
44985        (WebCore::GraphicsContext3D::attachShader): 
44986        When attaching or detaching a shader the shader program's active symbols list will change. Clear it so that it will be updated later.
44987        (WebCore::GraphicsContext3D::detachShader): Ditto.
44988        (WebCore::GraphicsContext3D::compileShader): No need to clear symbol counts here.
44989        (WebCore::GraphicsContext3D::getActiveAttrib): getActiveAttrib should only be able to query for attributes in the filtered list.
44990        (WebCore::GraphicsContext3D::getActiveUniform): getActiveUniform should only be able to query for uniforms in the filtered list.
44991        (WebCore::GraphicsContext3D::getNonBuiltInActiveSymbolCount): Return the filtered symbol count for a shader program.
44992
449932014-04-04  Ion Rosca  <rosca@adobe.com>
44994
44995        [CSS Blending] Add compositing reason for isolation.
44996        https://bugs.webkit.org/show_bug.cgi?id=131153
44997
44998        Reviewed by Joseph Pecoraro.
44999
45000        There are 2 reasons involving blend modes for a layer to be composited:
45001        1) the layer has blend mode and has composited descendants: CompositingReasonBlendingWithCompositedDescendants.
45002        2) the layer has to isolate composited blending descendants: CompositingReasonIsolatesCompositedBlendingDescendants
45003
45004        Test: inspector-protocol/layers/layers-blending-compositing-reasons.html
45005
45006        * inspector/InspectorLayerTreeAgent.cpp:
45007        (WebCore::InspectorLayerTreeAgent::reasonsForCompositingLayer):
45008        * inspector/protocol/LayerTree.json:
45009        * rendering/RenderLayerCompositor.cpp:
45010        (WebCore::RenderLayerCompositor::reasonsForCompositing):
45011        (WebCore::RenderLayerCompositor::logReasonsForCompositing):
45012        * rendering/RenderLayerCompositor.h: adding CompositingReasonIsolatesCompositedBlendingDescendants.
45013
450142014-04-04  Bem Jones-Bey  <bjonesbe@adobe.com>
45015
45016        Use more const refs in ShapeOutsideInfo and some misc cleanup
45017        https://bugs.webkit.org/show_bug.cgi?id=131192
45018
45019        Reviewed by Dirk Schulze.
45020
45021        Use const refs for pretty much everything that can't be null. Also
45022        cleanup some code that got a bit messy when ShapeInfo was merged into
45023        ShapeOutsideInfo.
45024
45025        No new tests, no behavior change.
45026
45027        * rendering/shapes/ShapeOutsideInfo.cpp:
45028        (WebCore::ShapeOutsideInfo::shapeToRendererPoint):
45029        (WebCore::ShapeOutsideInfo::shapeToRendererSize):
45030        (WebCore::referenceBox):
45031        (WebCore::ShapeOutsideInfo::setReferenceBoxLogicalSize):
45032        (WebCore::getShapeImageAndRect):
45033        (WebCore::ShapeOutsideInfo::computedShape):
45034        (WebCore::ShapeOutsideInfo::logicalTopOffset):
45035        (WebCore::ShapeOutsideInfo::logicalLeftOffset):
45036        * rendering/shapes/ShapeOutsideInfo.h:
45037
450382014-04-04  Alexey Proskuryakov  <ap@apple.com>
45039
45040        REGRESSION (r166615): Pressing return doesn’t submit search term at bing.com
45041        https://bugs.webkit.org/show_bug.cgi?id=131212
45042        <rdar://problem/16521788>
45043
45044        Reviewed by Dan Bernstein.
45045
45046        Test: fast/forms/submit-while-you-submit.html
45047
45048        Turns out that m_shouldSubmit can actually be modified in a code path where we can't
45049        directly return the result. I'm not sure if the current behavior is entirely correct
45050        (we have open bugs about submitting forms multiple times), but let's restore it to
45051        pre-r166615 state.
45052
45053        * html/HTMLFormElement.cpp:
45054        (WebCore::HTMLFormElement::HTMLFormElement):
45055        (WebCore::HTMLFormElement::prepareForSubmission):
45056        (WebCore::HTMLFormElement::submit):
45057        * html/HTMLFormElement.h:
45058
450592014-04-04  Martin Hock  <mhock@apple.com>
45060
45061        [Mac] Change operation queue width to NSOperationQueueDefaultMaxConcurrentOperationCount.
45062        https://bugs.webkit.org/show_bug.cgi?id=131231
45063
45064        <rdar://problem/13913483>
45065
45066        Reviewed by Brady Eidson.
45067
45068        No new tests, no behavior change.
45069
45070        * platform/network/mac/ResourceHandleMac.mm:
45071        (WebCore::operationQueueForAsyncClients):
45072
450732014-04-04  Hans Muller  <hmuller@adobe.com>
45074
45075        [CSS Shapes] Simplify Polygon implementation
45076        https://bugs.webkit.org/show_bug.cgi?id=130975
45077
45078        Reviewed by Andreas Kling.
45079
45080        Only floats can specify shape-outside. For polygon shape-outside values, the problem
45081        of finding the left and right exclusion edges reduces to finding the X axis
45082        limits of the polygon edges that overlap a particular layout line. This is a much
45083        simpler version of the problem that PolygonShape was originally designed for, and so
45084        the implementation can also be simplified. There's more about the new algorithm in
45085        http://hansmuller-webkit.blogspot.com/2014/03/a-simpler-algorithm-for-css-shapes.html.
45086
45087        No new tests, since functionality was only removed.
45088
45089        * platform/graphics/FloatRect.h:
45090        (WebCore::FloatRect::overlapsYRange):
45091        (WebCore::FloatRect::overlapsXRange):
45092        * rendering/shapes/PolygonShape.cpp:
45093        (WebCore::OffsetPolygonEdge::xIntercept):
45094        (WebCore::circleXIntercept):
45095        (WebCore::OffsetPolygonEdge::clippedEdgeXRange): X axis extent of the edge clipped to a vertical interval.
45096        (WebCore::clippedCircleXRange): X axis extent of a circle clipped to a vertical interval.
45097        (WebCore::PolygonShape::shapeMarginLogicalBoundingBox):
45098        (WebCore::PolygonShape::getExcludedIntervals):
45099        (WebCore::PolygonShape::buildDisplayPaths):
45100        * rendering/shapes/PolygonShape.h:
45101        (WebCore::OffsetPolygonEdge::OffsetPolygonEdge):
45102        (WebCore::OffsetPolygonEdge::isWithinYRange):
45103        (WebCore::OffsetPolygonEdge::overlapsYRange):
45104        (WebCore::PolygonShape::PolygonShape):
45105        * rendering/shapes/ShapeInterval.h:
45106        (WebCore::ShapeInterval::isEmpty):
45107        (WebCore::ShapeInterval::unite):
45108
451092014-04-04  Bem Jones-Bey  <bjonesbe@adobe.com>
45110
45111        [CSS Shapes] shape-margin in percentage units always computes to 0px
45112        https://bugs.webkit.org/show_bug.cgi?id=130369
45113
45114        Reviewed by Andreas Kling.
45115
45116        Make shape-margin parsing accept percentages and properly compute the
45117        length once the percentage is accepted.
45118
45119        Test: fast/shapes/shape-outside-floats/shape-outside-floats-shape-margin-percent.html
45120
45121        * css/CSSParser.cpp:
45122        (WebCore::CSSParser::parseValue):
45123        * rendering/shapes/Shape.cpp:
45124        (WebCore::Shape::createShape):
45125        (WebCore::Shape::createRasterShape):
45126        (WebCore::Shape::createBoxShape):
45127        * rendering/shapes/Shape.h:
45128        * rendering/shapes/ShapeOutsideInfo.cpp:
45129        (WebCore::ShapeOutsideInfo::computedShape):
45130
451312014-04-04  Zoltan Horvath  <zoltan@webkit.org>
45132
45133        [CSS Shapes] Remove outside-shape CSS value
45134        https://bugs.webkit.org/show_bug.cgi?id=131201
45135
45136        Reviewed by Bem Jones-Bey.
45137
45138        Outside-shape is not a valid CSS value anymore. This patch removes it.
45139
45140        No new tests, existing tests are removed.
45141
45142        * css/CSSComputedStyleDeclaration.cpp:
45143        (WebCore::shapePropertyValue):
45144        * css/CSSValueKeywords.in:
45145        * css/DeprecatedStyleBuilder.cpp:
45146        (WebCore::ApplyPropertyShape::applyValue):
45147        * rendering/shapes/ShapeOutsideInfo.cpp:
45148        (WebCore::ShapeOutsideInfo::computedShape):
45149        (WebCore::ShapeOutsideInfo::isEnabledFor):
45150        * rendering/style/ShapeValue.h:
45151        (WebCore::ShapeValue::createOutsideValue): Deleted.
45152
451532014-04-04  Dirk Schulze  <krit@webkit.org>
45154
45155        Gradient offsets are off if compositing operator != source-over
45156        https://bugs.webkit.org/show_bug.cgi?id=129791
45157
45158        Reviewed by Andreas Kling.
45159
45160        Instead of transforming the path before drawing it on the context,
45161        the whole context should be transformed. This will make the gradient
45162        map correctly to the context space.
45163
45164        Test: fast/canvas/canvas-gradient-on-compositing.html
45165
45166        * html/canvas/CanvasRenderingContext2D.cpp:
45167        (WebCore::CanvasRenderingContext2D::fullCanvasCompositedFill):
45168
451692014-04-04  Zalan Bujtas  <zalan@apple.com>
45170
45171        Subpixel rendering: Move background images to device pixel boundaries.
45172        https://bugs.webkit.org/show_bug.cgi?id=131144
45173
45174        Reviewed by Simon Fraser.
45175
45176        Replace integral snapping with device pixel snapping.
45177        Background image geometry calculation uses LayoutUnits and we snap to device pixels right before painting.
45178
45179        Tests: fast/backgrounds/hidpi-bitmap-background-on-subpixel-position.html
45180               fast/backgrounds/hidpi-bitmap-background-origin-on-subpixel-position.html
45181               fast/backgrounds/hidpi-bitmap-background-repeat-on-subpixel-position.html
45182               fast/backgrounds/hidpi-generated-gradient-background-on-subpixel-position.html
45183
45184        * platform/graphics/GraphicsLayer.h:
45185        (WebCore::GraphicsLayer::setContentsTilePhase):
45186        (WebCore::GraphicsLayer::contentsTilePhase):
45187        (WebCore::GraphicsLayer::setContentsTileSize):
45188        (WebCore::GraphicsLayer::contentsTileSize):
45189        * platform/graphics/texmap/TextureMapperLayer.cpp:
45190        (WebCore::TextureMapperLayer::setContentsTileSize):
45191        (WebCore::TextureMapperLayer::setContentsTilePhase):
45192        * platform/graphics/texmap/TextureMapperLayer.h:
45193        * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
45194        (WebCore::CoordinatedGraphicsLayer::setContentsTileSize):
45195        (WebCore::CoordinatedGraphicsLayer::setContentsTilePhase):
45196        * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.h:
45197        * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
45198        * rendering/RenderBox.cpp:
45199        (WebCore::RenderBox::repaintLayerRectsForImage):
45200        * rendering/RenderBoxModelObject.cpp:
45201        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
45202        (WebCore::resolveWidthForRatio):
45203        (WebCore::resolveHeightForRatio):
45204        (WebCore::resolveAgainstIntrinsicWidthOrHeightAndRatio):
45205        (WebCore::resolveAgainstIntrinsicRatio):
45206        (WebCore::RenderBoxModelObject::calculateImageIntrinsicDimensions):
45207        (WebCore::RenderBoxModelObject::calculateFillTileSize):
45208        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setNoRepeatX):
45209        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setNoRepeatY):
45210        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::useFixedAttachment):
45211        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::clip):
45212        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::relativePhase):
45213        (WebCore::getSpace):
45214        (WebCore::RenderBoxModelObject::pixelSnapBackgroundImageGeometryForPainting):
45215        (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
45216        (WebCore::RenderBoxModelObject::getGeometryForBackgroundImage):
45217        (WebCore::RenderBoxModelObject::paintNinePieceImage):
45218        (WebCore::applySubPixelHeuristicForTileSize): Deleted.
45219        * rendering/RenderBoxModelObject.h:
45220        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::destOrigin):
45221        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setDestOrigin):
45222        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::destRect):
45223        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setDestRect):
45224        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::phase):
45225        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setPhase):
45226        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::tileSize):
45227        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setTileSize):
45228        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::spaceSize):
45229        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setSpaceSize):
45230        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setPhaseX):
45231        (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setPhaseY):
45232        * rendering/RenderLayerBacking.cpp:
45233        (WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundImage):
45234        * rendering/shapes/ShapeOutsideInfo.cpp:
45235        (WebCore::getShapeImageAndRect):
45236
452372014-04-04  Brent Fulgham  <bfulgham@apple.com>
45238
45239        [Win] Unreviewed test fix (crash in debug build).
45240
45241        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
45242        (WebCore::AVFWrapper::legibleOutputCallback): Correct assertion. This
45243        callback is scheduled for the caption queue, not the main queue.
45244
452452014-04-03  Brent Fulgham  <bfulgham@apple.com>
45246
45247        [Win] Load Media Controls js/css from bundle
45248        https://bugs.webkit.org/show_bug.cgi?id=131194
45249
45250        Reviewed by Dean Jackson.
45251
45252        * DerivedSources.cpp: Remove no-longer generated file.
45253        * DerivedSources.make: Don't generate unneeded files.
45254        * WebCore.vcxproj/WebCore.vcxproj: Don't compile unneeded files.
45255        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
45256        * WebCore.vcxproj/copyWebCoreResourceFiles.cmd: Copy css/js to resource
45257        * rendering/RenderThemeSafari.cpp:
45258        * rendering/RenderThemeSafari.h:
45259        * rendering/RenderThemeWin.cpp:
45260        * rendering/RenderThemeWin.h:
45261
452622014-04-04  Mihnea Ovidenie  <mihnea@adobe.com>
45263
45264        [CSSRegions] Region's behaviour not updated when becoming valid from invalid
45265        https://bugs.webkit.org/show_bug.cgi?id=131211
45266
45267        Reviewed by Andrei Bucur.
45268
45269        When a region becomes valid again from invalid, it was part of a dependency cycle and the dependency cycle was broken,
45270        it needs to behave like a valid region again: if it has autoheight then it should compute its height based on the
45271        named flow content, if it has region styling then it should apply the additional style to the flowed content.
45272
45273        Added a new method, updateRegionFlags, that is used to ensure that auto-height and region-styling flags
45274        are properly set in several situations. Checking the behaviour, autoheight or styling, is done only
45275        if the region is valid.
45276
45277        Tests: fast/regions/auto-size/autoheight-region-valid-from-invalid.html
45278               fast/regions/region-styling/region-withstyling-valid-from-invalid.html
45279
45280        * rendering/RenderNamedFlowFragment.cpp:
45281        (WebCore::RenderNamedFlowFragment::updateRegionFlags):
45282        (WebCore::RenderNamedFlowFragment::styleDidChange):
45283        (WebCore::RenderNamedFlowFragment::updateRegionHasAutoLogicalHeightFlag):
45284        (WebCore::RenderNamedFlowFragment::checkRegionStyle):
45285        (WebCore::RenderNamedFlowFragment::attachRegion):
45286        (WebCore::RenderNamedFlowFragment::detachRegion):
45287        * rendering/RenderNamedFlowFragment.h:
45288        * rendering/RenderNamedFlowThread.cpp:
45289        (WebCore::RenderNamedFlowThread::addFragmentToNamedFlowThread):
45290
452912014-04-04  Raphael Kubo da Costa  <raphael.kubo.da.costa@intel.com>
45292
45293        [GTK][CMake] Remove FindXt.cmake.
45294        https://bugs.webkit.org/show_bug.cgi?id=131227
45295
45296        Reviewed by Anders Carlsson.
45297
45298        * PlatformGTK.cmake: Use FindX11.cmake's Xt variables instead of our own FindXt.cmake's ones.
45299
453002014-04-03  Andreas Kling  <akling@apple.com>
45301
45302        Fast-path for casting JS wrappers to JSElement.
45303        <https://webkit.org/b/131210>
45304
45305        Add an extended JSType for Element wrappers so we can avoid walking
45306        the ClassInfo chain in those bindings as well.
45307
45308        Generalized the code to select a casting helper in the bindings
45309        generator into a function (GetCastingHelperForThisObject.)
45310        Updated all the jsDynamicCast call sites to go through this, in case
45311        there's an optimized cast available for the desired type.
45312
45313        Reviewed by Benjamin Poulain.
45314
45315        * WebCore.xcodeproj/project.pbxproj:
45316        * bindings/js/JSDOMWrapper.h:
45317        * bindings/js/JSElementCustom.h: Added.
45318        (WebCore::jsElementCast):
45319        * bindings/js/JSNodeCustom.h:
45320        (WebCore::jsNodeCast):
45321        * bindings/scripts/CodeGeneratorJS.pm:
45322        (GenerateHeader):
45323        (GetCastingHelperForThisObject):
45324        (GenerateImplementation):
45325        * dom/Element.idl:
45326
453272014-04-03  Andreas Kling  <akling@apple.com>
45328
45329        Rebaseline a bindings test.
45330
45331        * bindings/scripts/test/JS/JSTestNode.h:
45332        (WebCore::JSTestNode::createStructure):
45333
453342014-04-03  Andreas Kling  <akling@apple.com>
45335
45336        Fast-path for casting JS wrappers to JSNode.
45337        <https://webkit.org/b/131196>
45338
45339        Add a way to quickly determine that a given JSObject is a JSNode.
45340        This lets us avoid walking the ClassInfo chain in the DOM bindings
45341        for WebCore::Node.
45342
45343        Reviewed by Mark Hahnenberg and Geoff Garen.
45344
45345        * bindings/js/JSDOMWrapper.h:
45346
45347            Added a JSNodeType constant that extends beyond JSC::JSType.
45348
45349        * bindings/js/JSNodeCustom.h:
45350        (WebCore::jsNodeCast):
45351
45352            Added. Fast cast from JSValue to JSNode.
45353
45354        * bindings/scripts/CodeGeneratorJS.pm:
45355        (GenerateHeader):
45356        (GenerateImplementation):
45357
45358            Generate code that uses jsNodeCast in Node interfaces.
45359
453602014-04-03  Bem Jones-Bey  <bjonesbe@adobe.com>
45361
45362        Merge ShapeInfo & ShapeOutsideInfo now that ShapeInsideInfo is no more
45363        https://bugs.webkit.org/show_bug.cgi?id=131180
45364
45365        Reviewed by Andreas Kling.
45366
45367        Now that ShapeInsideInfo is gone, having a class hiearachy and
45368        templates doesn't make any sense. As a first step to cleaning up the
45369        code, this remove ShapeInfo and puts all of its functionality into
45370        ShapeOutsideInfo.
45371
45372        No new tests, no behavior change.
45373
45374        * CMakeLists.txt:
45375        * WebCore.vcxproj/WebCore.vcxproj:
45376        * WebCore.vcxproj/WebCore.vcxproj.filters:
45377        * WebCore.xcodeproj/project.pbxproj:
45378        * rendering/shapes/ShapeInfo.cpp: Removed.
45379        * rendering/shapes/ShapeInfo.h: Removed.
45380        * rendering/shapes/ShapeOutsideInfo.cpp:
45381        (WebCore::ShapeOutsideInfo::computedShapePhysicalBoundingBox):
45382        (WebCore::ShapeOutsideInfo::shapeToRendererPoint):
45383        (WebCore::ShapeOutsideInfo::shapeToRendererSize):
45384        (WebCore::referenceBox):
45385        (WebCore::ShapeOutsideInfo::setReferenceBoxLogicalSize):
45386        (WebCore::checkShapeImageOrigin):
45387        (WebCore::getShapeImageAndRect):
45388        (WebCore::getShapeImageMarginRect):
45389        (WebCore::ShapeOutsideInfo::computedShape):
45390        (WebCore::borderBeforeInWritingMode):
45391        (WebCore::borderAndPaddingBeforeInWritingMode):
45392        (WebCore::ShapeOutsideInfo::logicalTopOffset):
45393        (WebCore::borderStartWithStyleForWritingMode):
45394        (WebCore::borderAndPaddingStartWithStyleForWritingMode):
45395        (WebCore::ShapeOutsideInfo::logicalLeftOffset):
45396        (WebCore::ShapeOutsideInfo::computeSegmentsForLine):
45397        (WebCore::ShapeOutsideInfo::updateDeltasForContainingBlockLine):
45398        (WebCore::ShapeOutsideInfo::shapeValue): Deleted.
45399        (WebCore::ShapeOutsideInfo::styleForWritingMode): Deleted.
45400        * rendering/shapes/ShapeOutsideInfo.h:
45401
454022014-04-03  Andreas Kling  <akling@apple.com>
45403
45404        Fix over-retain in SharedBufferCF's createCFData().
45405        <https://webkit.org/b/131139>
45406
45407        Constructing the return type (RetainPtr<CFDataRef>) will also retain
45408        the pointee, so this would end up leaking.
45409
45410        Reviewed by Anders Carlsson.
45411
45412        * platform/cf/SharedBufferCF.cpp:
45413        (WebCore::SharedBuffer::createCFData):
45414
454152014-04-03  Brent Fulgham  <bfulgham@apple.com>
45416
45417        [Win] Turn on ENABLE_CSS_GRID_LAYOUT
45418        https://bugs.webkit.org/show_bug.cgi?id=131147
45419
45420        Reviewed by Simon Fraser.
45421
45422        Covered by existing fast/css/getComputedStyle tests.
45423
45424        * css/CSSAllInOne.cpp: Add CSSGridLineNamesValue.cpp when building
45425        with ENABLE(CSS_GRID_LAYOUT)
45426
454272014-04-03  Simon Fraser  <simon.fraser@apple.com>
45428
45429        Pixelated WebView when display is changed from hiDPI to regularDPI
45430        https://bugs.webkit.org/show_bug.cgi?id=131185
45431
45432        Reviewed by Tim Horton.
45433
45434        r166309 added a short circuit in GraphicsLayerCA::updateContentsScale()
45435        when the scale didn't change. This broke layers which expected to
45436        unconditionally receive a setContentsScale(), namely the WebTiledBackingLayer
45437        which owns the TileController. WebTiledBackingLayer overrode -setContentsScale:
45438        to pass the scale down to the TileController; however, it didn't override
45439        -contentsScale, and it mucked with the scale passed in.
45440        
45441        Fix by having setting and fetching contentsScale on a WebTiledBackingLayer
45442        work as expected. Also rename the TileController functions to mirror the
45443        CALayer functions better.
45444
45445        * WebCore.exp.in:
45446        * platform/graphics/ca/GraphicsLayerCA.cpp:
45447        (WebCore::GraphicsLayerCA::updateContentsScale):
45448        * platform/graphics/ca/mac/TileController.h:
45449        * platform/graphics/ca/mac/TileController.mm:
45450        (WebCore::TileController::TileController):
45451        (WebCore::TileController::contentsScale):
45452        (WebCore::TileController::setContentsScale):
45453        (WebCore::TileController::scale): Deleted.
45454        (WebCore::TileController::setScale): Deleted.
45455        * platform/graphics/ca/mac/WebTiledBackingLayer.mm:
45456        (-[WebTiledBackingLayer setContentsScale:]):
45457        (-[WebTiledBackingLayer contentsScale]):
45458
454592014-04-03  Zoltan Horvath  <zoltan@webkit.org>
45460
45461        [CSS Shapes] LineSegment logicalLeft and logicalRight members should be floats
45462        https://bugs.webkit.org/show_bug.cgi?id=116160
45463
45464        Reviewed by Andreas Kling. 
45465
45466        LineSegment edges should not have been changed to LayoutUnit. These are
45467        used only as floats. I modified them back to floats. 
45468
45469        No new tests are needed, no behavior change.
45470
45471        * rendering/shapes/Shape.h:
45472
454732014-04-03  Dirk Schulze  <krit@webkit.org>
45474
45475        [CG] Canvas lineDashOffset does not handle negative numbers correctly
45476        https://bugs.webkit.org/show_bug.cgi?id=80560
45477
45478        Reviewed by Dean Jackson.
45479
45480        CG ignores negative dash array offsets. Check if we have a negative offset, if yes
45481        then calculate the length of the dash array and modulo the dash array offset with
45482        the dash array length.
45483
45484        Test: fast/canvas/canvas-negative-lineDashOffset.html
45485
45486        * platform/graphics/cg/GraphicsContextCG.cpp:
45487        (WebCore::GraphicsContext::setLineDash):
45488
454892014-04-03  David Hyatt  <hyatt@apple.com>
45490
45491        REGRESSION: fast/css/relative-positioned-block-nested-with-inline-parent-multiple-descendant-blocks-dynamic.html broken
45492        https://bugs.webkit.org/show_bug.cgi?id=131183
45493
45494        Reviewed by Simon Fraser.
45495
45496        Revert the loop to continue rather than breaking when an invalid block is encountered.
45497        This is what it used to do if it encountered a non-continuation block.
45498
45499        * rendering/RenderInline.cpp:
45500        (WebCore::updateStyleOfAnonymousBlockContinuations):
45501
455022014-04-02  Simon Fraser  <simon.fraser@apple.com>
45503
45504        Harden FilterOperation type casting
45505        https://bugs.webkit.org/show_bug.cgi?id=131142
45506
45507        Reviewed by Sam Weinig.
45508
45509        DefaultFilterOperation had an error-prone behavior where it set the base class
45510        OperationType to the type of some other filter class, but overrode isDefault(). 
45511        This made it very easy to write incorrect code that casted incorrectly based on type().
45512        
45513        Fix by making adding a DEFAULT filter operation type, and storing the represented
45514        type on DefaultFilterOperation().
45515        
45516        Also remove the OperationType argument for constructors of FilterOperations that
45517        can only be of one type, to avoid possible mistakes.
45518        
45519        Make the type cast macros a bit more normal, and use them in a few places.
45520        
45521        Fixed PlatformCAFiltersMac to handle the default filter case more cleanly.
45522
45523        * WebCore.exp.in:
45524        * css/CSSComputedStyleDeclaration.cpp:
45525        (WebCore::ComputedStyleExtractor::valueForFilter):
45526        * css/StyleResolver.cpp:
45527        (WebCore::StyleResolver::createFilterOperations):
45528        * platform/graphics/ca/PlatformCAFilters.h:
45529        * platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
45530        (PlatformCAFilters::filterValueForOperation):
45531        (PlatformCAFilters::colorMatrixValueForFilter):
45532        * platform/graphics/filters/FilterOperation.cpp:
45533        (WebCore::DefaultFilterOperation::operator==):
45534        (WebCore::ReferenceFilterOperation::ReferenceFilterOperation):
45535        (WebCore::ReferenceFilterOperation::operator==):
45536        (WebCore::BlurFilterOperation::operator==):
45537        (WebCore::BlurFilterOperation::blend):
45538        (WebCore::DropShadowFilterOperation::operator==):
45539        (WebCore::DropShadowFilterOperation::blend):
45540        * platform/graphics/filters/FilterOperation.h:
45541        (WebCore::FilterOperation::blend):
45542        (WebCore::FilterOperation::type):
45543        (WebCore::FilterOperation::isBasicColorMatrixFilterOperation):
45544        (WebCore::FilterOperation::isBasicComponentTransferFilterOperation):
45545        (WebCore::FilterOperation::isSameType):
45546        (WebCore::DefaultFilterOperation::create):
45547        (WebCore::DefaultFilterOperation::representedType):
45548        (WebCore::DefaultFilterOperation::DefaultFilterOperation):
45549        (WebCore::ReferenceFilterOperation::create):
45550        (WebCore::BlurFilterOperation::create):
45551        (WebCore::BlurFilterOperation::BlurFilterOperation):
45552        (WebCore::DropShadowFilterOperation::create):
45553        (WebCore::DropShadowFilterOperation::DropShadowFilterOperation):
45554        (WebCore::FilterOperation::isDefault): Deleted.
45555        * platform/graphics/filters/FilterOperations.cpp:
45556        (WebCore::FilterOperations::outsets):
45557        * rendering/FilterEffectRenderer.cpp:
45558        (WebCore::FilterEffectRenderer::build):
45559        * rendering/RenderLayerFilterInfo.cpp:
45560        (WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients):
45561
455622014-04-03  Andreas Kling  <akling@apple.com>
45563
45564        Stop throwing away the Document's StyleResolver on a timer.
45565        <https://webkit.org/b/131168>
45566        <rdar://problem/15227045>
45567
45568        This was causing some unfortunate pauses when returning to idle pages
45569        after a long-ish time. There's already a mechanism in place that will
45570        throw these away if the system comes under memory pressure.
45571
45572        Reviewed by Sam Weinig.
45573
45574        * css/StyleResolver.cpp:
45575        (WebCore::StyleResolver::styleForElement):
45576        (WebCore::StyleResolver::styleForKeyframe):
45577        (WebCore::StyleResolver::pseudoStyleForElement):
45578        (WebCore::StyleResolver::styleForPage):
45579        * dom/Document.cpp:
45580        (WebCore::Document::Document):
45581        (WebCore::Document::didAccessStyleResolver): Deleted.
45582        (WebCore::Document::styleResolverThrowawayTimerFired): Deleted.
45583        * dom/Document.h:
45584
455852014-04-02  Simon Fraser  <simon.fraser@apple.com>
45586
45587        Assertion under RenderLayerCompositor::updateScrollCoordinatedLayer on time.com on iOS
45588        https://bugs.webkit.org/show_bug.cgi?id=131150
45589
45590        Reviewed by Beth Dakin.
45591
45592        When calling updateScrollCoordinatedLayer() under styleChanged, we haven't done
45593        layout yet so our composting layers haven't been hooked together. Don't try
45594        to add a zero nodeID to the map in this case.
45595
45596        * rendering/RenderLayerCompositor.cpp:
45597        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
45598
455992014-04-03  David Hyatt  <hyatt@apple.com>
45600
45601        Continuations casting issue.
45602        https://bugs.webkit.org/show_bug.cgi?id=130057
45603        <rdar://problem/16283406>
45604
45605        Reviewed by Simon Fraser.
45606
45607        The code to update relative positioned anonymous block continuations should not
45608        have assumed that all siblings were RenderBlocks. Make the code smarter and
45609        make it bail when it hits something that isn't part of the block continuation
45610        chain.
45611
45612        Added fast/block/continuation-crash.html
45613
45614        * rendering/RenderInline.cpp:
45615        (WebCore::updateStyleOfAnonymousBlockContinuations):
45616
456172014-04-03  Bem Jones-Bey  <bjonesbe@adobe.com>
45618
45619        [CSS Shapes] CRASH with calc() value args in inset round
45620        https://bugs.webkit.org/show_bug.cgi?id=129816
45621
45622        Reviewed by Andreas Kling.
45623
45624        The code to parse the inset rounded corners was adding the parser
45625        value arguments to a temporary CSSParserValueList. Unfortunately,
45626        CSSParserValueList expects to own the values it contains, and it frees
45627        the values it contains when the list is destroyed. This was a problem
45628        because the values are owned by the CSSParserValueList passed in to
45629        parseInsetRoundedCorners, and thus the calc's argument list would get
45630        double freed, resulting in a crash. This patch fixes this by using a
45631        Vector to hold the pointers instead.
45632
45633        Test: fast/shapes/shape-outside-floats/shape-outside-inset-round-calc-crash.html
45634
45635        * css/CSSParser.cpp:
45636        (WebCore::CSSParser::parseInsetRoundedCorners):
45637
456382014-04-03  Jer Noble  <jer.noble@apple.com>
45639
45640        Leaving a streaming movie by going "Back" keeps playing the audio
45641        https://bugs.webkit.org/show_bug.cgi?id=131149
45642
45643        Reviewed by Eric Carlson.
45644
45645        When stopping a HTMLMediaElement, call userCancelledLoad() (which clears the
45646        MediaPlayer) only after calling setPausedInternal() (which pauses the MediaPlayer).
45647        Previously, and in the reverse order, the MediaPlayer would never get a chance to pause
45648        before being cleared. There is an underlying error with the QTKit media engine which
45649        is causing it to continue playing even after its last reference is released, but this
45650        does fix the symptom of playback continuing even after stopping.
45651
45652        * html/HTMLMediaElement.cpp:
45653        (WebCore::HTMLMediaElement::stop):
45654
456552014-04-03  Jer Noble  <jer.noble@apple.com>
45656
45657        [EME] Crash when passing a NULL initData to MediaKeys.createSession()
45658        https://bugs.webkit.org/show_bug.cgi?id=131156
45659
45660        Reviewed by Eric Carlson.
45661
45662        Update the checks at the start of createSession() to match the current spec, notably
45663        bailing early if the initData parameter is NULL or empty.
45664
45665        * Modules/encryptedmedia/MediaKeys.cpp:
45666        (WebCore::MediaKeys::createSession):
45667
456682014-04-03  Eric Carlson  <eric.carlson@apple.com>
45669
45670        [iOS] add missing QuickTime plug-in replacement API
45671        https://bugs.webkit.org/show_bug.cgi?id=131042
45672
45673        Reviewed by Dean Jackson.
45674
45675        Rename QuickTimePluginReplacement.cpp to QuickTimePluginReplacement.mm to make it possible
45676        to use the ObjC JSC API.
45677        * Modules/plugins/QuickTimePluginReplacement.cpp:
45678        * Modules/plugins/QuickTimePluginReplacement.h:
45679        (WebCore::QuickTimePluginReplacement::parentElement):
45680        * Modules/plugins/QuickTimePluginReplacement.idl:
45681
45682        * Modules/plugins/QuickTimePluginReplacement.js:
45683        (Replacement.prototype.timedMetadataUpdates): Implement.
45684        (Replacement.prototype.accessLog): Ditto.
45685        (Replacement.prototype.errorLog): Ditto.
45686
45687        Use the JSC ObjC API to create a JavaScript object from an array of AVMetadataItems. The
45688        JSC ObjC API supports basic NSTypes, but an AVMetadataItem can also contain NSData which 
45689        the existing plug-in returns as base-64 encoded data, so create wrappers for NSDictionary
45690        and NSArray.
45691        * Modules/plugins/QuickTimePluginReplacement.mm: Copied from Source/WebCore/Modules/plugins/QuickTimePluginReplacement.cpp.
45692        (WebCore::QuickTimePluginReplacement::ensureReplacementScriptInjected): Disambiguate with "JSC::"
45693        (WebCore::QuickTimePluginReplacement::installReplacement): Ditto.
45694        (WebCore::jsValueWithDataInContext): Create JSValue* from NSData.
45695        (WebCore::jsValueWithArrayInContext): Create JSValue* from NSArray.
45696        (WebCore::jsValueWithDictionaryInContext): Create JSValue* from NSDictionary.
45697        (WebCore::jsValueWithValueInContext): Create JSValue* from basic NSTypes plus AVMetadataItem
45698            and NSData.
45699        (WebCore::jsValueWithAVMetadataItemInContext): Create JSValue* from AVMetadataItem.
45700        (WebCore::JSQuickTimePluginReplacement::timedMetaData): Script interface.
45701        (WebCore::JSQuickTimePluginReplacement::accessLog): Ditto.
45702        (WebCore::JSQuickTimePluginReplacement::errorLog): Ditto.
45703
45704        * WebCore.xcodeproj/project.pbxproj: QuickTimePluginReplacement.cpp -> QuickTimePluginReplacement.mm.
45705
45706        * platform/graphics/MediaPlayer.cpp:
45707        (WebCore::MediaPlayer::timedMetadata): iOS only accessor.
45708        (WebCore::MediaPlayer::accessLog): Ditto.
45709        (WebCore::MediaPlayer::errorLog): Ditto.
45710        * platform/graphics/MediaPlayer.h:
45711        * platform/graphics/MediaPlayerPrivate.h:
45712
45713        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
45714        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
45715        (WebCore::MediaPlayerPrivateAVFoundationObjC::timedMetadata):
45716        (WebCore::MediaPlayerPrivateAVFoundationObjC::accessLog):
45717        (WebCore::MediaPlayerPrivateAVFoundationObjC::errorLog):
45718        (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive):
45719        (WebCore::itemKVOProperties):
45720        (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]):
45721
457222014-04-03  Andrei Bucur  <abucur@adobe.com>
45723
45724        [CSS Regions] Include region range information when printing the render tree
45725        https://bugs.webkit.org/show_bug.cgi?id=131159
45726
45727        Reviewed by Mihnea Ovidenie.
45728
45729        With this change showRenderObject() will print the region range for objects inside
45730        a flow thread. The format is:
45731        Rs: <startRegion> Re: <endRegion>
45732
45733        Because this can be called anytime during debugging, it's necessary to disable the
45734        current flow thread caching to prevent using the wrong flow thread for an object.
45735
45736        Tests: No new tests, no functional change.
45737
45738        * rendering/RenderFlowThread.cpp:
45739        (WebCore::CurrentRenderFlowThreadDisabler::CurrentRenderFlowThreadDisabler):
45740        (WebCore::CurrentRenderFlowThreadDisabler::~CurrentRenderFlowThreadDisabler):
45741        * rendering/RenderFlowThread.h:
45742        * rendering/RenderObject.cpp:
45743        (WebCore::RenderObject::showRegionsInformation): Added.
45744        (WebCore::RenderObject::showRenderObject):
45745        * rendering/RenderObject.h:
45746
457472014-04-03  Antti Koivisto  <antti@apple.com>
45748
45749        RenderSnapshottedPlugIn::paint should use iterator for traversal.
45750        https://bugs.webkit.org/show_bug.cgi?id=131158
45751
45752        Reviewed by Dean Jackson.
45753
45754        * rendering/RenderSnapshottedPlugIn.cpp:
45755        (WebCore::RenderSnapshottedPlugIn::paint):
45756
457572014-03-27  Sergio Villar Senin  <svillar@igalia.com>
45758
45759        [CSS Grid Layout] <string> not allowed in grid-{area | row | column} syntax
45760        https://bugs.webkit.org/show_bug.cgi?id=129713
45761
45762        Reviewed by Darin Adler.
45763
45764        Grid positioning properties no longer accept <string> values for
45765        named grid lines as they did in previous versions of the specs. They
45766        were first replaced by <ident> and since the beginning of 2014 they
45767        should only accept <custom-ident>.
45768
45769        Updated the parser and the style resolver to this new syntax. Also
45770        updated the tests accordingly.
45771
45772        Test: fast/css-grid-layout/grid-container-change-named-grid-lines-recompute-child.html
45773
45774        * css/CSSParser.cpp:
45775        (WebCore::isValidCustomIdent): New function that checks that the
45776        <custom-ident> is valid.
45777        (WebCore::CSSParser::parseIntegerOrCustomIdentFromGridPosition):
45778        (WebCore::CSSParser::parseGridPosition):
45779        (WebCore::CSSParser::parseIntegerOrStringFromGridPosition):
45780        Replaced by WebCore::CSSParser::parseIntegerOrCustomIdentFromGridPosition.
45781        * css/CSSParser.h:
45782        * css/StyleResolver.cpp:
45783        (WebCore::createGridPosition):
45784
457852014-04-03  Antti Koivisto  <antti@apple.com>
45786
45787        Crash after mutating after pseudo style
45788        https://bugs.webkit.org/show_bug.cgi?id=130881
45789
45790        Reviewed by Andreas Kling.
45791
45792        Test: fast/css/pseudo-after-crash.html
45793
45794        * style/StyleResolveTree.cpp:
45795        (WebCore::Style::updateBeforeOrAfterPseudoElement):
45796        
45797            Invalidate the cached renderer for pseudo elements too.
45798    
45799        (WebCore::Style::needsPseudeElement): Deleted.
45800        
45801            Fix spelling.
45802
458032014-04-02  Chris Fleizach  <cfleizach@apple.com>
45804
45805        AX: AccessibilityObject::children() returns invalid results sometimes
45806        https://bugs.webkit.org/show_bug.cgi?id=130563
45807
45808        Reviewed by Joseph Pecoraro.
45809
45810        Allow the DOM inspector to handle AX objects that do not have Node equivalents
45811        (e.g. anonymous renderers).
45812
45813        * inspector/InspectorDOMAgent.cpp:
45814        (WebCore::InspectorDOMAgent::processAccessibilityChildren):
45815        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
45816        * inspector/InspectorDOMAgent.h:
45817
458182014-04-02  Alexey Proskuryakov  <ap@apple.com>
45819
45820        Sandbox violation in NetworkProcess when uploading a bundle
45821        https://bugs.webkit.org/show_bug.cgi?id=131133
45822
45823        Reviewed by Brady Eidson.
45824
45825        Track generated file ownership explicitly, so that each copy of FormData would know
45826        whether to delete the file.
45827
45828        This part is needed to prevent asserting in FormData destructor in NetworkProcess,
45829        because it doesn't delete the files. Also, some cleanup.
45830
45831        * WebCore.exp.in: Don't export FormData::removeGeneratedFilesIfNeeded(), WebKit2
45832        doesn't need it any more.
45833        * platform/network/FormData.cpp: Removed m_hasGeneratedFiles. There is no problem
45834        iterating over FormDataElements to compute it, and that's more robust when FormDatas
45835        are passed or stored on disk permanently.
45836        Updated touched functions to use C++ iteration, and renamed "e" to "element".
45837        (WebCore::FormData::encode): Keep encoding a boolean for hasGeneratedFiles, because
45838        the encoded FormData can be stored persitently, and we can't change the format.
45839
45840        * platform/network/FormData.h: (WebCore::FormDataElement::FormDataElement):
45841        Added m_ownsGeneratedFile. FormData will only delete files it owns. Since files
45842        are generated immediately before form submission, it's always the FormData being
45843        submitted that owns the generated files.
45844
458452014-04-02  Mihnea Ovidenie  <mihnea@adobe.com>
45846
45847        [CSSRegions] Use RenderStyle::hasFlowInto when needed
45848        https://bugs.webkit.org/show_bug.cgi?id=131092
45849
45850        Reviewed by Andrei Bucur.
45851
45852        Add hasFlowInto() helper method on RenderStyle to be used
45853        instead of directly checking the presence or absence of flowThread value.
45854        No new functionality, no new tests.
45855
45856        * css/CSSComputedStyleDeclaration.cpp:
45857        (WebCore::ComputedStyleExtractor::propertyValue):
45858        * dom/Element.cpp:
45859        (WebCore::Element::shouldMoveToFlowThread):
45860        * rendering/style/RenderStyle.h:
45861        * style/StyleResolveTree.cpp:
45862        (WebCore::Style::isRendererReparented):
45863
458642014-04-02  Benjamin Poulain  <benjamin@webkit.org>
45865
45866        CSS JIT: the adjacent position is never reset
45867        https://bugs.webkit.org/show_bug.cgi?id=131145
45868
45869        Reviewed by Andreas Kling.
45870
45871        Corresponding radar: <rdar://problem/16440036>. The backtracking action would use a tail
45872        when not needed.
45873
45874        Test: fast/selectors/multiple-adjacent-chain-without-adjacent-tail.html
45875
45876        * cssjit/SelectorCompiler.cpp:
45877        (WebCore::SelectorCompiler::updateChainStates):
45878
458792014-04-02  Brent Fulgham  <bfulgham@apple.com>
45880
45881        Speculative build fix for Windows.
45882
45883        * DerivedSources.make: Make sure we generate our media control
45884        scripts for Apple Windows (but not WinCairo)
45885
458862014-04-02  Tim Horton  <timothy_horton@apple.com>
45887
45888        Fix the !USE(IOSURFACE) iOS build.
45889
45890        * platform/ios/MemoryPressureHandlerIOS.mm:
45891        (WebCore::MemoryPressureHandler::platformReleaseMemory):
45892
458932014-04-02  Mark Rowe  <mrowe@apple.com>
45894
45895        <https://webkit.org/b/131136> Remove FrameLoadRequest's m_lockHistory member since it's always false.
45896
45897        Reviewed by Andreas Kling.
45898
45899        * loader/FrameLoadRequest.cpp:
45900        (WebCore::FrameLoadRequest::FrameLoadRequest):
45901        * loader/FrameLoadRequest.h:
45902        (WebCore::FrameLoadRequest::FrameLoadRequest):
45903        (WebCore::FrameLoadRequest::lockHistory): Deleted.
45904        (WebCore::FrameLoadRequest::setLockHistory): Deleted.
45905        * loader/FrameLoader.cpp:
45906        (WebCore::FrameLoader::load): Remove an if whose body was never executed.
45907
459082014-04-02  Mark Rowe  <mrowe@apple.com>
45909
45910        <https://webkit.org/b/131135> Introduce LockHistory and LockBackForwardList enums to use in place of bools.
45911
45912        These arguments are often passed using literals at the call site, where the use of bools severely hinders
45913        the readability of the code.
45914
45915        Reviewed by Andreas Kling.
45916
45917        * WebCore.exp.in:
45918        * html/HTMLAnchorElement.cpp:
45919        (WebCore::HTMLAnchorElement::handleClick):
45920        * html/HTMLFormElement.cpp:
45921        (WebCore::HTMLFormElement::submit):
45922        * html/HTMLFrameElementBase.cpp:
45923        (WebCore::HTMLFrameElementBase::openURL):
45924        (WebCore::HTMLFrameElementBase::setLocation):
45925        * html/HTMLFrameElementBase.h:
45926        * inspector/InspectorFrontendClientLocal.cpp:
45927        (WebCore::InspectorFrontendClientLocal::openInNewTab):
45928        * inspector/InspectorPageAgent.cpp:
45929        (WebCore::InspectorPageAgent::navigate):
45930        * loader/FormSubmission.cpp:
45931        (WebCore::FormSubmission::FormSubmission):
45932        (WebCore::FormSubmission::create):
45933        * loader/FormSubmission.h:
45934        (WebCore::FormSubmission::lockHistory):
45935        * loader/FrameLoader.cpp:
45936        (WebCore::FrameLoader::changeLocation):
45937        (WebCore::FrameLoader::urlSelected):
45938        (WebCore::FrameLoader::loadURLIntoChildFrame):
45939        (WebCore::FrameLoader::loadFrameRequest):
45940        (WebCore::FrameLoader::loadURL):
45941        (WebCore::FrameLoader::loadWithNavigationAction):
45942        (WebCore::FrameLoader::clientRedirected):
45943        (WebCore::FrameLoader::loadPostRequest):
45944        (WebCore::FrameLoader::continueLoadAfterNewWindowPolicy):
45945        (WebCore::FrameLoader::loadDifferentDocumentItem):
45946        * loader/FrameLoader.h:
45947        * loader/FrameLoaderTypes.h:
45948        * loader/NavigationScheduler.cpp:
45949        (WebCore::ScheduledNavigation::ScheduledNavigation):
45950        (WebCore::ScheduledNavigation::lockHistory):
45951        (WebCore::ScheduledNavigation::lockBackForwardList):
45952        (WebCore::ScheduledURLNavigation::ScheduledURLNavigation):
45953        (WebCore::ScheduledRedirect::ScheduledRedirect):
45954        (WebCore::ScheduledLocationChange::ScheduledLocationChange):
45955        (WebCore::ScheduledRefresh::ScheduledRefresh):
45956        (WebCore::ScheduledHistoryNavigation::ScheduledHistoryNavigation):
45957        (WebCore::ScheduledFormSubmission::ScheduledFormSubmission):
45958        (WebCore::NavigationScheduler::scheduleRedirect):
45959        (WebCore::NavigationScheduler::mustLockBackForwardList):
45960        (WebCore::NavigationScheduler::scheduleLocationChange):
45961        (WebCore::NavigationScheduler::scheduleFormSubmission):
45962        * loader/NavigationScheduler.h:
45963        * loader/SubframeLoader.cpp:
45964        (WebCore::SubframeLoader::requestFrame):
45965        (WebCore::SubframeLoader::requestObject):
45966        (WebCore::SubframeLoader::loadOrRedirectSubframe):
45967        * loader/SubframeLoader.h:
45968        * page/ContextMenuController.cpp:
45969        (WebCore::openNewWindow):
45970        (WebCore::ContextMenuController::contextMenuItemSelected):
45971        * page/DOMWindow.cpp:
45972        (WebCore::DOMWindow::setLocation):
45973        (WebCore::DOMWindow::createWindow):
45974        (WebCore::DOMWindow::open):
45975        * svg/SVGAElement.cpp:
45976        (WebCore::SVGAElement::defaultEventHandler):
45977
459782014-04-02  Tim Horton  <timothy_horton@apple.com>
45979
45980        Pool IOSurfaces to help with allocation cost
45981        https://bugs.webkit.org/show_bug.cgi?id=131096
45982        <rdar://problem/15373942>
45983
45984        Reviewed by Simon Fraser.
45985
45986        * WebCore.exp.in:
45987        * WebCore.xcodeproj/project.pbxproj:
45988        
45989        * platform/Timer.h:
45990        (WebCore::TimerBase::startRepeating): Add a std::chrono startRepeating.
45991
45992        * platform/graphics/cg/IOSurfacePool.h: Added.
45993        (WebCore::IOSurfacePool::CachedSurfaceDetails::CachedSurfaceDetails):
45994        (WebCore::IOSurfacePool::CachedSurfaceDetails::resetLastUseTime):
45995        * platform/graphics/cg/ImageBufferBackingStoreCache.cpp: Removed.
45996        * platform/graphics/cg/ImageBufferBackingStoreCache.h: Removed.
45997        * platform/graphics/cg/IOSurfacePool.cpp: Added.
45998        (WebCore::IOSurfacePool::IOSurfacePool):
45999        (WebCore::IOSurfacePool::sharedPool):
46000        (WebCore::surfaceMatchesParameters):
46001        (WebCore::IOSurfacePool::willAddSurface):
46002        (WebCore::IOSurfacePool::didRemoveSurface):
46003        (WebCore::IOSurfacePool::didUseSurfaceOfSize):
46004        (WebCore::IOSurfacePool::takeSurface):
46005        (WebCore::IOSurfacePool::addSurface):
46006        (WebCore::IOSurfacePool::insertSurfaceIntoPool):
46007        (WebCore::IOSurfacePool::setPoolSize):
46008        (WebCore::IOSurfacePool::tryEvictInUseSurface):
46009        (WebCore::IOSurfacePool::tryEvictOldestCachedSurface):
46010        (WebCore::IOSurfacePool::evict):
46011        (WebCore::IOSurfacePool::collectInUseSurfaces):
46012        (WebCore::IOSurfacePool::markOlderSurfacesPurgeable):
46013        (WebCore::IOSurfacePool::collectionTimerFired):
46014        (WebCore::IOSurfacePool::scheduleCollectionTimer):
46015        (WebCore::IOSurfacePool::discardAllSurfaces):
46016        (WebCore::IOSurfacePool::showPoolStatistics):
46017        Add a pool of IOSurfaces. It behaves as such:
46018
46019            - Keeps up to 64MB of surfaces.
46020            - Keeps unused and in-use surfaces (but never gets more than 1/2 full with the latter)
46021            - Marks surfaces purgeable after they've been unused for 2 seconds.
46022            - Tries to move surfaces from the in-use pool to the unused pool every 500ms.
46023            - Evicts in an LRU-ish fashion, interleaving eviction of the oldest
46024              surfaces and the in-use surfaces (since in-use surfaces are not immediately
46025              useful for the pool, but they are desirous because they were recently used).
46026            - Throws everything away under memory pressure.
46027
46028        * platform/graphics/cocoa/IOSurface.mm:
46029        (IOSurface::create):
46030        Try to grab a surface from the IOSurfacePool.
46031
46032        * platform/ios/MemoryPressureHandlerIOS.mm:
46033        (WebCore::MemoryPressureHandler::platformReleaseMemory):
46034        * platform/mac/MemoryPressureHandlerMac.mm:
46035        (WebCore::MemoryPressureHandler::install):
46036        (WebCore::MemoryPressureHandler::platformReleaseMemory):
46037        * platform/MemoryPressureHandler.cpp:
46038        (WebCore::MemoryPressureHandler::platformReleaseMemory):
46039        Fix some includes, and throw away all surfaces when we're under memory pressure.
46040
460412014-04-02  Stephanie Lewis  <slewis@apple.com>
46042
46043        Roll out http://trac.webkit.org/changeset/166144
46044        <rdar://problem/16481284> PLT stops loading on news.google.com
46045
46046        Unreviewed rollout.
46047
46048        Rollout 166144 since it prevents the PLT from completing.
46049
46050        * dom/ContainerNode.cpp:
46051        (WebCore::ContainerNode::suspendPostAttachCallbacks):
46052        (WebCore::ContainerNode::resumePostAttachCallbacks):
46053        (WebCore::ContainerNode::queuePostAttachCallback):
46054        (WebCore::ContainerNode::postAttachCallbacksAreSuspended):
46055        (WebCore::ContainerNode::dispatchPostAttachCallbacks):
46056        * dom/ContainerNode.h:
46057        * dom/Document.cpp:
46058        (WebCore::Document::recalcStyle):
46059        * dom/Element.h:
46060        (WebCore::PostAttachCallbackDisabler::PostAttachCallbackDisabler):
46061        (WebCore::PostAttachCallbackDisabler::~PostAttachCallbackDisabler):
46062        * html/HTMLEmbedElement.cpp:
46063        (WebCore::HTMLEmbedElement::parseAttribute):
46064        * html/HTMLFormControlElement.cpp:
46065        (WebCore::focusPostAttach):
46066        (WebCore::HTMLFormControlElement::didAttachRenderers):
46067        (WebCore::updateFromElementCallback):
46068        (WebCore::HTMLFormControlElement::didRecalcStyle):
46069        * html/HTMLFrameOwnerElement.cpp:
46070        (WebCore::needsStyleRecalcCallback):
46071        (WebCore::HTMLFrameOwnerElement::scheduleSetNeedsStyleRecalc):
46072        * html/HTMLObjectElement.cpp:
46073        (WebCore::HTMLObjectElement::parseAttribute):
46074        (WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk):
46075        (WebCore::HTMLObjectElement::hasValidClassId):
46076        (WebCore::HTMLObjectElement::renderFallbackContent):
46077        * html/HTMLObjectElement.h:
46078        * html/HTMLPlugInImageElement.cpp:
46079        (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
46080        (WebCore::HTMLPlugInImageElement::createElementRenderer):
46081        (WebCore::HTMLPlugInImageElement::didAttachRenderers):
46082        (WebCore::HTMLPlugInImageElement::willDetachRenderers):
46083        (WebCore::HTMLPlugInImageElement::updateWidgetIfNecessary):
46084        (WebCore::HTMLPlugInImageElement::didMoveToNewDocument):
46085        (WebCore::HTMLPlugInImageElement::updateWidgetCallback):
46086        (WebCore::HTMLPlugInImageElement::startLoadingImage):
46087        (WebCore::HTMLPlugInImageElement::startLoadingImageCallback):
46088        (WebCore::HTMLPlugInImageElement::createShadowIFrameSubtree):
46089        (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn):
46090        (WebCore::HTMLPlugInImageElement::didRecalcStyle): Deleted.
46091        (WebCore::HTMLPlugInImageElement::scheduleUpdateForAfterStyleResolution): Deleted.
46092        (WebCore::HTMLPlugInImageElement::updateAfterStyleResolution): Deleted.
46093        (WebCore::HTMLPlugInImageElement::removedFrom): Deleted.
46094        (WebCore::is100Percent): Deleted.
46095        (WebCore::HTMLPlugInImageElement::setNeedsImageReload): Deleted.
46096        * html/HTMLPlugInImageElement.h:
46097        (WebCore::HTMLPlugInImageElement::imageLoader): Deleted.
46098        (WebCore::HTMLPlugInImageElement::updateImageLoaderWithNewURLSoon): Deleted.
46099        * style/StyleResolveTree.cpp:
46100        (WebCore::Style::needsPseudeElement):
46101        (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded):
46102        (WebCore::Style::attachRenderTree):
46103        (WebCore::Style::updateBeforeOrAfterPseudoElement):
46104        (WebCore::Style::needsPseudoElement): Deleted.
46105        (WebCore::Style::postResolutionCallbackQueue): Deleted.
46106        (WebCore::Style::queuePostResolutionCallback): Deleted.
46107        (WebCore::Style::suspendMemoryCacheClientCalls): Deleted.
46108        (WebCore::Style::PostResolutionCallbackDisabler::PostResolutionCallbackDisabler): Deleted.
46109        (WebCore::Style::PostResolutionCallbackDisabler::~PostResolutionCallbackDisabler): Deleted.
46110        (WebCore::Style::postResolutionCallbacksAreSuspended): Deleted.
46111        * style/StyleResolveTree.h:
46112
461132014-04-02  Jinwoo Song  <jinwoo7.song@samsung.com>
46114
46115        Page should use std::unique_ptr for PointerLockController
46116        https://bugs.webkit.org/show_bug.cgi?id=131098
46117
46118        Reviewed by Anders Carlsson.
46119
46120        Make Page keep a std::unique_ptr to PointerLockController. Store page 
46121        references and return controller references where possible.
46122
46123        * dom/Document.cpp:
46124        (WebCore::Document::prepareForDestruction):
46125        (WebCore::Document::webkitExitPointerLock):
46126        (WebCore::Document::webkitPointerLockElement):
46127        * dom/Element.cpp:
46128        (WebCore::Element::removedFrom):
46129        (WebCore::Element::webkitRequestPointerLock):
46130        * page/Page.cpp:
46131        (WebCore::Page::Page):
46132        * page/Page.h:
46133        (WebCore::Page::pointerLockController):
46134        * page/PointerLockController.cpp:
46135        (WebCore::PointerLockController::PointerLockController):
46136        (WebCore::PointerLockController::requestPointerLock):
46137        (WebCore::PointerLockController::requestPointerUnlock):
46138        (WebCore::PointerLockController::create): Deleted.
46139        * page/PointerLockController.h:
46140
461412014-04-02  Dean Jackson  <dino@apple.com>
46142
46143        Load Media Controls js/css from bundle
46144        https://bugs.webkit.org/show_bug.cgi?id=131086
46145
46146        Followup comments from Eric Carlson.
46147
46148        Remove the booleans that were guarding loading the resources.
46149
46150        * rendering/RenderThemeIOS.h:
46151        * rendering/RenderThemeIOS.mm:
46152        (WebCore::RenderThemeIOS::mediaControlsStyleSheet):
46153        (WebCore::RenderThemeIOS::mediaControlsScript):
46154        (WebCore::RenderThemeIOS::RenderThemeIOS):
46155        * rendering/RenderThemeMac.h:
46156        * rendering/RenderThemeMac.mm:
46157        (WebCore::RenderThemeMac::RenderThemeMac):
46158        (WebCore::RenderThemeMac::mediaControlsStyleSheet):
46159        (WebCore::RenderThemeMac::mediaControlsScript):
46160
461612014-04-01  Dean Jackson  <dino@apple.com>
46162
46163        Load Media Controls js/css from bundle
46164        https://bugs.webkit.org/show_bug.cgi?id=131086
46165
46166        Reviewed by Eric Carlson.
46167
46168        Rather than embed encoded versions of the JS and CSS files
46169        into C++ source, just load the files directly from the bundle.
46170
46171        * DerivedSources.make: Removed now unnecessary rules.
46172        * WebCore.xcodeproj/project.pbxproj: Copy mediaControls files to the bundle.
46173        * rendering/RenderThemeIOS.h:
46174        * rendering/RenderThemeIOS.mm:
46175        (WebCore::RenderThemeIOS::RenderThemeIOS):
46176        (WebCore::RenderThemeIOS::mediaControlsStyleSheet): Load from the bundle.
46177        (WebCore::RenderThemeIOS::mediaControlsScript): Ditto.
46178        * rendering/RenderThemeMac.h:
46179        * rendering/RenderThemeMac.mm:
46180        (WebCore::RenderThemeMac::RenderThemeMac):
46181        (WebCore::RenderThemeMac::mediaControlsStyleSheet):
46182        (WebCore::RenderThemeMac::mediaControlsScript):
46183
461842014-04-02  Daniel Bates  <dabates@apple.com>
46185
46186        Move focus management API from HTMLDocument to Document
46187        https://bugs.webkit.org/show_bug.cgi?id=131079
46188        <rdar://problem/16220103>
46189
46190        Reviewed by Timothy Hatcher.
46191
46192        Merged from Blink (patch by Christophe Dumez):
46193        https://src.chromium.org/viewvc/blink?view=rev&revision=165515
46194
46195        Move hasFocus() and attribute activeElement from interface HTMLDocument
46196        to DOMDocument as per section Focus management APIs of the HTML5 standard:
46197        <http://www.whatwg.org/specs/web-apps/current-work/#focus-management-apis> (1 April 2014).
46198
46199        Test: fast/dom/Document/xml-document-focus.xml
46200
46201        * bindings/objc/PublicDOMInterfaces.h: Moved hasFocus() and property activeElement from
46202        interface DOMHTMLDocument to DOMDocument.
46203        * dom/Document.cpp:
46204        (WebCore::Document::activeElement): Added.
46205        (WebCore::Document::hasFocus): Added.
46206        * dom/Document.h:
46207        * dom/Document.idl:
46208        * html/HTMLDocument.cpp:
46209        (WebCore::HTMLDocument::activeElement): Deleted.
46210        (WebCore::HTMLDocument::hasFocus): Deleted.
46211        * html/HTMLDocument.h:
46212        * html/HTMLDocument.idl:
46213
462142014-04-02  Benjamin Poulain  <benjamin@webkit.org>
46215
46216        Refactor the function call generator to take the arguments by value
46217        https://bugs.webkit.org/show_bug.cgi?id=131129
46218
46219        Reviewed by Andreas Kling.
46220
46221        Nothing forces the pointed address to stay alive between setOneArgument/setTwoArguments
46222        and prepareAndCall.
46223
46224        This patch changes FunctionCall to:
46225        -Keep the register by value instead of using pointers.
46226        -Crash at compile time if a register is invalid.
46227
46228        * cssjit/FunctionCall.h:
46229        (WebCore::FunctionCall::FunctionCall):
46230        (WebCore::FunctionCall::setOneArgument):
46231        (WebCore::FunctionCall::setTwoArguments):
46232        (WebCore::FunctionCall::swapArguments):
46233        (WebCore::FunctionCall::prepareAndCall):
46234        * cssjit/RegisterAllocator.h:
46235        (WebCore::RegisterAllocator::isValidRegister):
46236
462372014-04-02  Daniel Bates  <dabates@apple.com>
46238
46239        Remove Settings::maximumDecodedImageSize()
46240        https://bugs.webkit.org/show_bug.cgi?id=131057
46241        <rdar://problem/15626368>
46242
46243        Reviewed by Darin Adler.
46244
46245        The setting Settings::maximumDecodedImageSize() and its related logic have various
46246        shortcomings, including the inability to cancel an image load when the estimated
46247        decoded image size exceeds the maximum decoded image size. In the iOS port, this
46248        setting is less useful given image subsampling support. For now, we remove this
46249        setting and its related logic. Should it turn out that such a setting is useful
46250        then we can implement it again taking care to address the shortcomings in the
46251        original design.
46252
46253        * html/HTMLCanvasElement.cpp: For the iOS port, define MaxCanvasArea to be 4580 * 1145
46254        pixels such that the maximum size of the image buffer is 20 MB (assumes 4 bytes per pixel).
46255        (WebCore::HTMLCanvasElement::HTMLCanvasElement):
46256        (WebCore::HTMLCanvasElement::createImageBuffer):
46257        * html/HTMLCanvasElement.h:
46258        * html/canvas/CanvasRenderingContext2D.cpp:
46259        (WebCore::CanvasRenderingContext2D::createImageData):
46260        (WebCore::CanvasRenderingContext2D::getImageData):
46261        * loader/cache/CachedImage.cpp:
46262        (WebCore::CachedImage::addIncrementalDataBuffer):
46263        (WebCore::CachedImage::finishLoading):
46264        * loader/cache/CachedImage.h:
46265        * page/Settings.in:
46266
462672014-04-02  Martin Hock  <mhock@apple.com>
46268
46269        Unify private browsing with sessions.
46270        https://bugs.webkit.org/show_bug.cgi?id=130099
46271
46272        Reviewed by Alexey Proskuryakov.
46273
46274        Unless otherwise noted, the following consists solely of mechanical changes to replace querying WebCore::Settings::privateBrowsingEnabled() with Page::usesEphemeralSession().
46275
46276        * Modules/webdatabase/DatabaseContext.cpp:
46277        (WebCore::DatabaseContext::allowDatabaseAccess):
46278        * WebCore.exp.in: Remove Settings::setPrivateBrowsingEnabled, add Page::legacyPrivateBrowsingEnabled.
46279        * html/HTMLMediaElement.cpp:
46280        (WebCore::HTMLMediaElement::parseAttribute):
46281        * loader/HistoryController.cpp:
46282        (WebCore::HistoryController::updateForStandardLoad):
46283        (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
46284        (WebCore::HistoryController::updateForClientRedirect):
46285        (WebCore::HistoryController::updateForSameDocumentNavigation):
46286        (WebCore::HistoryController::pushState):
46287        (WebCore::HistoryController::replaceState):
46288        * loader/appcache/ApplicationCacheGroup.cpp:
46289        (WebCore::ApplicationCacheGroup::cacheForMainRequest):
46290        (WebCore::ApplicationCacheGroup::selectCache):
46291        (WebCore::ApplicationCacheGroup::selectCacheWithoutManifestURL):
46292        (WebCore::ApplicationCacheGroup::update):
46293        * loader/appcache/ApplicationCacheHost.cpp:
46294        (WebCore::ApplicationCacheHost::isApplicationCacheEnabled):
46295        * loader/icon/IconController.cpp:
46296        (WebCore::IconController::continueLoadWithDecision):
46297        * page/Page.cpp:
46298        (WebCore::Page::Page): Initialize with defaultSessionID.
46299        (WebCore::Page::legacyPrivateBrowsingEnabled): Legacy setting for private browsing.
46300        (WebCore::Page::privateBrowsingStateChanged): Move implementation to setSessionID.
46301        (WebCore::Page::sessionID): Simplify to just return m_sessionID.
46302        (WebCore::Page::setSessionID): Also perform privateBrowsingStateChanged action.a
46303        (WebCore::Page::privateBrowsingStateChanged): Deleted.
46304        (WebCore::Page::checkSubframeCountConsistency): Deleted.
46305        * page/Page.h:
46306        * page/PageConsole.cpp:
46307        (WebCore::PageConsole::addMessage):
46308        (WebCore::PageConsole::messageWithTypeAndLevel):
46309        * page/Settings.cpp: Remove privateBrowsingEnabled setting.
46310        (WebCore::Settings::Settings):
46311        (WebCore::Settings::setPrivateBrowsingEnabled): Page reflects setting using session.
46312        * page/Settings.h:
46313        * plugins/PluginView.cpp:
46314        (WebCore::PluginView::getValue):
46315        * rendering/RenderSearchField.cpp:
46316        (WebCore::RenderSearchField::addSearchResult):
46317        * storage/Storage.cpp:
46318        (WebCore::Storage::isDisabledByPrivateBrowsing):
46319
463202014-04-02  Antti Koivisto  <antti@apple.com>
46321
46322        Try to fix test failures.
46323
46324        * platform/graphics/ca/mac/TileGrid.mm:
46325        (WebCore::TileGrid::TileGrid):  Initialize a field.
46326
463272014-04-02  Timothy Hatcher  <timothy@apple.com>
46328
46329        Remove Input domain from the Web Inspector protocol.
46330
46331        https://bugs.webkit.org/show_bug.cgi?id=131073
46332
46333        Reviewed by Joseph Pecoraro.
46334
46335        * CMakeLists.txt:
46336        * DerivedSources.make:
46337        * WebCore.vcxproj/WebCore.vcxproj:
46338        * WebCore.vcxproj/WebCore.vcxproj.filters:
46339        * WebCore.xcodeproj/project.pbxproj:
46340        * inspector/InspectorAllInOne.cpp:
46341        * inspector/InspectorController.cpp:
46342        (WebCore::InspectorController::InspectorController):
46343        * inspector/InspectorInputAgent.cpp: Removed.
46344        * inspector/InspectorInputAgent.h: Removed.
46345        * inspector/protocol/Input.json: Removed.
46346
463472014-04-02  Antti Koivisto  <antti@apple.com>
46348
46349        Split tile grid out from TileController
46350        https://bugs.webkit.org/show_bug.cgi?id=131102
46351
46352        Reviewed by Simon Fraser.
46353
46354        Add a TileGrid class that encapsulates tiles, zoom level and the related metadata.
46355        This will make it possible to have multiple grids per TileController later.
46356
463572014-03-31  Brent Fulgham  <bfulgham@apple.com>
46358
46359        [Win] Correct media controls for test harness
46360        https://bugs.webkit.org/show_bug.cgi?id=131008 
46361
46362        Reviewed by Eric Carlson.
46363
46364        * rendering/RenderThemeSafari.cpp: Revise to match RenderThemeWin logic.
46365        (WebCore::RenderThemeSafari::systemFont):
46366        (WebCore::RenderThemeSafari::paintMenuList):
46367        (WebCore::RenderThemeSafari::paintSearchFieldResultsButton):
46368        (WebCore::RenderThemeSafari::mediaControlsStyleSheet):
46369        (WebCore::RenderThemeSafari::mediaControlsScript):
46370        (WebCore::RenderThemeSafari::paintMediaFullscreenButton): Deleted.
46371        (WebCore::RenderThemeSafari::paintMediaMuteButton): Deleted.
46372        (WebCore::RenderThemeSafari::paintMediaPlayButton): Deleted.
46373        (WebCore::RenderThemeSafari::paintMediaSeekBackButton): Deleted.
46374        (WebCore::RenderThemeSafari::paintMediaSeekForwardButton): Deleted.
46375        (WebCore::RenderThemeSafari::paintMediaSliderTrack): Deleted.
46376        (WebCore::RenderThemeSafari::paintMediaSliderThumb): Deleted.
46377        * rendering/RenderThemeSafari.h:
46378
463792014-04-02  peavo@outlook.com  <peavo@outlook.com>
46380
46381        [WinCairo] Compile error.
46382        https://bugs.webkit.org/show_bug.cgi?id=131110
46383
46384        Reviewed by Simon Fraser.
46385
46386        Image::size() now returns a FloatSize instead of an IntSize.
46387
46388        * platform/win/DragImageCairoWin.cpp:
46389        (WebCore::createDragImageFromImage):
46390
463912014-04-02  David Kilzer  <ddkilzer@apple.com>
46392
46393        Use outermost containing isolate when constructing bidi runs
46394        <http://webkit.org/b/131107>
46395        <rdar://problem/15690021>
46396
46397        Reviewed by Darin Adler.
46398
46399        Merged from Blink (patch by jww@chromium.org):
46400        https://src.chromium.org/viewvc/blink?revision=157268&view=revision
46401        http://crbug.com/279277
46402
46403            Update containingIsolate to go back all the way to top
46404            isolate from current root, rather than stopping at the first
46405            isolate it finds. This works because the current root is
46406            always updated with each isolate run.
46407
46408        Tests: fast/text/international/unicode-bidi-isolate-nested-with-removes-not-adjacent.html
46409               fast/text/international/unicode-bidi-isolate-nested-with-removes.html
46410
46411        * rendering/InlineIterator.h:
46412        (WebCore::highestContainingIsolateWithinRoot):
46413        * rendering/RenderBlockLineLayout.cpp:
46414        (WebCore::constructBidiRunsForSegment):
46415
464162014-04-02  Chris Fleizach  <cfleizach@apple.com>
46417
46418        AX: Improve ARIA live region reliability by sending notifications when live regions are created/shown and hidden/destroyed
46419        https://bugs.webkit.org/show_bug.cgi?id=124381
46420
46421        Reviewed by Mario Sanchez Prada.
46422
46423        Re-organize some code so that when we detect a new node has been created, we can safely determine its live region status.
46424        If it is a live region, we fire off a live region created notification.
46425
46426        Test: platform/mac/accessibility/live-region-creation-notification.html
46427
46428        * accessibility/AXObjectCache.cpp:
46429        (WebCore::AXObjectCache::handleLiveRegionCreated):
46430        (WebCore::AXObjectCache::childrenChanged):
46431        (WebCore::AXObjectCache::handleAttributeChanged):
46432        * accessibility/AXObjectCache.h:
46433        (WebCore::AXObjectCache::childrenChanged):
46434        * accessibility/AccessibilityObject.cpp:
46435        (WebCore::AccessibilityObject::defaultLiveRegionStatusForRole):
46436        (WebCore::AccessibilityObject::liveRegionStatusIsEnabled):
46437        (WebCore::AccessibilityObject::supportsARIALiveRegion):
46438        * accessibility/AccessibilityObject.h:
46439        (WebCore::AccessibilityObject::ariaLiveRegionStatus):
46440        * accessibility/AccessibilityRenderObject.cpp:
46441        (WebCore::AccessibilityRenderObject::ariaLiveRegionStatus):
46442        * accessibility/AccessibilityRenderObject.h:
46443        * accessibility/ios/AXObjectCacheIOS.mm:
46444        (WebCore::AXObjectCache::postPlatformNotification):
46445        * accessibility/ios/WebAccessibilityObjectWrapperIOS.h:
46446        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
46447        (-[WebAccessibilityObjectWrapper postLiveRegionCreatedNotification]):
46448        * accessibility/mac/AXObjectCacheMac.mm:
46449        (WebCore::AXObjectCache::postPlatformNotification):
46450
464512014-04-02  Martin Robinson  <mrobinson@igalia.com>
46452
46453        REGRESSION(r165704): [GTK] Inspector resources not correctly generated
46454        https://bugs.webkit.org/show_bug.cgi?id=130343
46455
46456        Reviewed by Gustavo Noronha Silva.
46457
46458        * CMakeLists.txt: Generate the web inspector JS file into the new WebInspectorUI derived sources
46459        directory.
46460
464612014-04-02  Zalan Bujtas  <zalan@apple.com>
46462
46463        Unreviewed build fix after r166642.
46464        (WinCairo should really turn subpixel layout on.)
46465
46466        * platform/graphics/LayoutSize.h:
46467        (WebCore::flooredForPainting):
46468
464692014-04-02  Zalan Bujtas  <zalan@apple.com>
46470
46471        Subpixel rendering: Make GraphicsContext::drawTiledImage* functions float based.
46472        https://bugs.webkit.org/show_bug.cgi?id=131062
46473
46474        Reviewed by Simon Fraser.
46475
46476        This is in preparation to support subpixel positioned/sized background images. Generated images
46477        need to be able to sized on device pixels.
46478
46479        No change in behavior.
46480
46481        * platform/graphics/GraphicsContext.cpp:
46482        (WebCore::GraphicsContext::drawImage):
46483        (WebCore::GraphicsContext::drawTiledImage):
46484        * platform/graphics/GraphicsContext.h:
46485
464862014-04-02  Alex Christensen  <achristensen@webkit.org>
46487
46488        [WinCairo] Build fix after r166496.
46489        https://bugs.webkit.org/show_bug.cgi?id=131006
46490
46491        Reviewed by Carlos Garcia Campos.
46492
46493        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
46494        (WebCore::InbandTextTrackPrivateGStreamer::handleSample):
46495        (WebCore::InbandTextTrackPrivateGStreamer::streamChanged):
46496        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
46497        (WebCore::MediaPlayerPrivateGStreamer::changePipelineState):
46498        (WebCore::MediaPlayerPrivateGStreamer::videoChanged):
46499        (WebCore::MediaPlayerPrivateGStreamer::videoCapsChanged):
46500        (WebCore::MediaPlayerPrivateGStreamer::audioChanged):
46501        (WebCore::MediaPlayerPrivateGStreamer::textChanged):
46502        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
46503        (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
46504        (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
46505        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
46506        (WebCore::TrackPrivateBaseGStreamer::activeChanged):
46507        (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
46508        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
46509        (webkitVideoSinkRender):
46510        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
46511        (webKitWebSrcChangeState):
46512        (webKitWebSrcNeedDataCb):
46513        (webKitWebSrcEnoughDataCb):
46514        (webKitWebSrcSeekDataCb):
46515        Added std::function<void()> constructors to help Visual Studio decide which version of 
46516        GMainLoopSource::schedule or GMainLoopSource::scheduleAfterDelay to use.
46517
465182014-04-02  Zalan Bujtas  <zalan@apple.com>
46519
46520        Subpixel rendering: Transition class CSSImageGeneratorValue/class StyleImage (and its dependencies) from 
46521        IntSize to FloatSize to enable subpixel sized (generated)images.
46522        https://bugs.webkit.org/show_bug.cgi?id=130659
46523
46524        Reviewed by Simon Fraser and Andreas Kling.
46525
46526        This is in preparation to support subpixel positioned/sized background images. Generated images
46527        needs to be able to sized on device pixels.
46528
46529        No change in behavior.
46530
46531        * WebCore.vcxproj/WebCore.vcxproj:
46532        * WebCore.vcxproj/WebCore.vcxproj.filters:
46533        * WebCore.xcodeproj/project.pbxproj:
46534        * css/CSSCanvasValue.cpp:
46535        (WebCore::CSSCanvasValue::fixedSize):
46536        (WebCore::CSSCanvasValue::image):
46537        * css/CSSCanvasValue.h:
46538        * css/CSSCrossfadeValue.cpp:
46539        (WebCore::CSSCrossfadeValue::fixedSize):
46540        (WebCore::CSSCrossfadeValue::image):
46541        * css/CSSCrossfadeValue.h:
46542        * css/CSSFilterImageValue.cpp:
46543        (WebCore::CSSFilterImageValue::fixedSize):
46544        (WebCore::CSSFilterImageValue::image):
46545        * css/CSSFilterImageValue.h:
46546        * css/CSSGradientValue.cpp:
46547        (WebCore::CSSGradientValue::image):
46548        (WebCore::positionFromValue):
46549        (WebCore::CSSGradientValue::computeEndPoint):
46550        (WebCore::endPointsFromAngle):
46551        (WebCore::CSSLinearGradientValue::createGradient):
46552        (WebCore::CSSRadialGradientValue::createGradient):
46553        * css/CSSGradientValue.h:
46554        (WebCore::CSSGradientValue::fixedSize):
46555        * css/CSSImageGeneratorValue.cpp:
46556        (WebCore::CSSImageGeneratorValue::cachedImageForSize):
46557        (WebCore::CSSImageGeneratorValue::saveCachedImageForSize):
46558        (WebCore::CSSImageGeneratorValue::evictCachedGeneratedImage):
46559        (WebCore::CSSImageGeneratorValue::CachedGeneratedImage::CachedGeneratedImage):
46560        (WebCore::CSSImageGeneratorValue::image):
46561        (WebCore::CSSImageGeneratorValue::fixedSize):
46562        * css/CSSImageGeneratorValue.h:
46563        * loader/cache/CachedImage.cpp:
46564        (WebCore::CachedImage::setContainerSizeForRenderer):
46565        * loader/cache/CachedImage.h:
46566        * platform/graphics/FloatSizeHash.h: Added.
46567        (WTF::FloatHash<WebCore::FloatSize>::hash):
46568        (WTF::FloatHash<WebCore::FloatSize>::equal):
46569        (WTF::HashTraits<WebCore::FloatSize>::constructDeletedValue):
46570        (WTF::HashTraits<WebCore::FloatSize>::isDeletedValue):
46571        * platform/graphics/LayoutSize.h:
46572        (WebCore::flooredForPainting):
46573        * rendering/RenderImageResourceStyleImage.h:
46574        * rendering/RenderListMarker.cpp:
46575        (WebCore::RenderListMarker::computePreferredLogicalWidths):
46576        * rendering/style/StyleCachedImage.cpp:
46577        (WebCore::StyleCachedImage::imageSize):
46578        (WebCore::StyleCachedImage::setContainerSizeForRenderer):
46579        (WebCore::StyleCachedImage::image):
46580        * rendering/style/StyleCachedImage.h:
46581        * rendering/style/StyleCachedImageSet.cpp:
46582        (WebCore::StyleCachedImageSet::imageSize):
46583        (WebCore::StyleCachedImageSet::setContainerSizeForRenderer):
46584        (WebCore::StyleCachedImageSet::image):
46585        * rendering/style/StyleCachedImageSet.h:
46586        * rendering/style/StyleGeneratedImage.cpp:
46587        (WebCore::StyleGeneratedImage::imageSize):
46588        (WebCore::StyleGeneratedImage::computeIntrinsicDimensions):
46589        (WebCore::StyleGeneratedImage::image):
46590        * rendering/style/StyleGeneratedImage.h:
46591        * rendering/style/StyleImage.h:
46592        * rendering/style/StylePendingImage.h:
46593        * svg/graphics/SVGImageCache.cpp:
46594        (WebCore::SVGImageCache::setContainerSizeForRenderer):
46595        * svg/graphics/SVGImageCache.h:
46596
465972014-04-02  Gergo Balogh  <gbalogh.u-szeged@partner.samsung.com>
46598
46599        Warning fix for RenderLayer.
46600        https://bugs.webkit.org/show_bug.cgi?id=131090
46601
46602        Reviewed by Csaba Osztrogonác.
46603
46604        * rendering/RenderLayer.cpp:
46605        (WebCore::RenderLayer::updateDescendantDependentFlags):
46606
466072014-04-02  Frédéric Wang  <fred.wang@free.fr>
46608
46609        Operator stretching: read the Open Type MATH table
46610        https://bugs.webkit.org/show_bug.cgi?id=130324
46611
46612        Reviewed by Chris Fleizach.
46613
46614        We parse and expose some data from the OpenType MATH table that will be
46615        be relevant for at least the MathML operator stretching (bug 130322):
46616        math constants, italic corrections and size variants / glyph assembly.
46617        This will be tested when the MathML code uses the data.
46618
46619        * WebCore.xcodeproj/project.pbxproj: Add OpenTypeTypes.h to the Mac build.
46620        * platform/graphics/opentype/OpenTypeMathData.cpp: We implement the low-level parsing of the MATH table.
46621        (WebCore::OpenType::MathItalicsCorrectionInfo::getItalicCorrection):
46622        (WebCore::OpenType::MathGlyphInfo::mathItalicsCorrectionInfo):
46623        (WebCore::OpenType::GlyphAssembly::getAssemblyParts):
46624        (WebCore::OpenType::MathGlyphConstruction::getSizeVariants):
46625        (WebCore::OpenType::MathGlyphConstruction::getAssemblyParts):
46626        (WebCore::OpenType::MathVariants::mathGlyphConstruction):
46627        (WebCore::OpenType::MATHTable::mathConstants):
46628        (WebCore::OpenType::MATHTable::mathGlyphInfo):
46629        (WebCore::OpenType::MATHTable::mathVariants):
46630        (WebCore::OpenTypeMathData::OpenTypeMathData): We load the MATH table.
46631        (WebCore::OpenTypeMathData::getMathConstant): We add a function to get values from the MathConstant subtable.
46632        (WebCore::OpenTypeMathData::getItalicCorrection): We add a function to get italic correction from the MathGlyphInfo subtable.
46633        (WebCore::OpenTypeMathData::getMathVariants): We add a function to get size variants / glyph assembly from the MathVariants subtable.
46634        * platform/graphics/opentype/OpenTypeMathData.h: We expose three new functions to get math data.
46635        * platform/graphics/opentype/OpenTypeTypes.h: We share the coverage tables that are common to vertical and math data.
46636        (WebCore::OpenType::TableWithCoverage::getCoverageIndex): We add a function to get the coverage index from a given glyph.
46637        * platform/graphics/opentype/OpenTypeVerticalData.cpp: We move the coverage tables to OpenTypeTypes.h.
46638
466392014-04-02  Ion Rosca  <rosca@adobe.com>
46640
46641        [CSS Blending] Compositing requirements for blending are not computed correctly
46642        https://bugs.webkit.org/show_bug.cgi?id=130664
46643
46644        Reviewed by Dean Jackson.
46645
46646        Tests: css3/compositing/blend-mode-accelerated-with-multiple-stacking-contexts.html
46647               css3/compositing/blend-mode-with-accelerated-sibling.html
46648
46649        Compositing requirements for blending: if a layer having blend mode
46650        other than normal is composited for any reason, its closest stacking
46651        context ancestor should be composited as well.
46652
46653        * rendering/RenderLayer.cpp:
46654        (WebCore::RenderLayer::RenderLayer):
46655        * rendering/RenderLayer.h: added a new field,
46656        m_hasUnisolatedCompositedBlendingDescendants, which is true if the layer
46657        has composited blending descendants not isolated by any stacking context child;
46658        added a new method: isolatesCompositedBlending(), which is true if we should
46659        accelerate that layer in order to perform isolation correctly.
46660
46661        * rendering/RenderLayerCompositor.cpp:
46662        (WebCore::CompositingState::CompositingState): m_subtreeHasBlending was renamed
46663        m_hasUnisolatedCompositedBlendingDescendants in order to be more self-explanatory.
46664        (WebCore::RenderLayerCompositor::computeCompositingRequirements):
46665        computes the isolation requirements for composited blending by
46666        (re)setting RenderLayer::m_hasUnisolatedCompositedBlendingDescendants flag.
46667
46668        (WebCore::RenderLayerCompositor::reasonsForCompositing):
46669        fixed the reason of compositing: isolation instead of blending.
46670
46671        (WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason):
46672        * rendering/RenderLayerCompositor.h:
46673
466742014-04-02  Frédéric Wang  <fred.wang@free.fr>
46675
46676        Operator stretching: expose a math data API
46677        https://bugs.webkit.org/show_bug.cgi?id=130572
46678
46679        Reviewed by Chris Fleizach.
46680
46681        We expose a new SimpleFontData API to give access to the data from the
46682        OpenType MATH table. The class OpenTypeMathData will
46683        be implemented in bug 130324. On Darwin platform, we also implement the
46684        missing FontPlatformData::openTypeTable function which will be necessary
46685        to load the OpenType MATH table. The changes are intended to be used
46686        for MathML operator stretching (bug 130322) so tests are not added yet.
46687
46688        * CMakeLists.txt: add new OpenTypeMathData files.
46689        * WebCore.vcxproj/WebCore.vcxproj: ditto.
46690        * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
46691        * WebCore.xcodeproj/project.pbxproj: ditto.
46692        * platform/graphics/FontPlatformData.cpp:
46693        (WebCore::FontPlatformData::openTypeTable): We implement openTypeTable() on Darwin platform.
46694        * platform/graphics/FontPlatformData.h: We expose openTypeTable() on Darwin platform.
46695        * platform/graphics/SimpleFontData.cpp:
46696        (WebCore::SimpleFontData::SimpleFontData):
46697        (WebCore::SimpleFontData::mathData): Initialize and return the math data.
46698        * platform/graphics/SimpleFontData.h: We expose a mathData() function to access the MATH data.
46699        * platform/graphics/opentype/OpenTypeMathData.cpp: Added. This is a new class that will be used to parse the data from the OpenType MATH table.
46700        (WebCore::OpenTypeMathData::OpenTypeMathData):
46701        * platform/graphics/opentype/OpenTypeMathData.h: Added.
46702        (WebCore::OpenTypeMathData::create):
46703        (WebCore::OpenTypeMathData::hasMathData):
46704
467052014-04-01  Mihnea Ovidenie  <mihnea@adobe.com>
46706
46707        [CSSRegions] Displaying region's children in another region not supported
46708        https://bugs.webkit.org/show_bug.cgi?id=130735
46709
46710        Reviewed by David Hyatt.
46711
46712        With http://trac.webkit.org/changeset/166353, we disabled the possibility
46713        of collecting the region's children into another flow and displaying them
46714        in another region.
46715        I added a new test for this and also changed the plain ASSERT in Element dtor
46716        to ASSERT_WITH_SECURITY_IMPLICATION to better reflect the meaning of the assertion.
46717
46718        Test: fast/regions/region-child-not-flowed.html
46719
46720        * dom/Element.cpp:
46721        (WebCore::Element::~Element):
46722
467232014-04-01  Andrei Bucur  <abucur@adobe.com>
46724
46725        [CSS Regions] Simplify the RenderFlowThread state pusher
46726        https://bugs.webkit.org/show_bug.cgi?id=131035
46727
46728        Reviewed by David Hyatt.
46729
46730        The RenderFlowThread state pusher is desynchronized from the RenderView layout state pusher
46731        by one renderer. This patch fixes the anomaly by correctly ordering the push and pop operations
46732        between the two systems.
46733
46734        Tests: no functional change, no new tests.
46735
46736        * rendering/RenderFlowThread.cpp:
46737        (WebCore::RenderFlowThread::pushFlowThreadLayoutState):
46738        (WebCore::RenderFlowThread::popFlowThreadLayoutState):
46739        (WebCore::RenderFlowThread::offsetFromLogicalTopOfFirstRegion):
46740        * rendering/RenderView.cpp:
46741        (WebCore::RenderView::pushLayoutState):
46742        * rendering/RenderView.h:
46743
467442014-04-01  Beth Dakin  <bdakin@apple.com>
46745
46746        willReveal edge events should be hooked up for overflow:scroll
46747        https://bugs.webkit.org/show_bug.cgi?id=131071
46748        -and corresponding-
46749        <rdar://problem/16190392>
46750
46751        Reviewed by Sam Weinig.
46752
46753        This patch moves the will reveal logic from FrameView to Document so that it can 
46754        be shared for RenderLayers.
46755
46756        This is mostly just a moved function, but now the function takes an Element* that 
46757        represents the target of the event if the target is not the window.
46758        * dom/Document.cpp:
46759        (WebCore::Document::sendWillRevealEdgeEventsIfNeeded):
46760        * dom/Document.h:
46761
46762        No longer implement sendWillRevealEdgeEventsIfNeeded() on FrameView or 
46763        ScrollableArea at all. Call into Document instead.
46764        * page/FrameView.cpp:
46765        (WebCore::FrameView::scrollPositionChanged):
46766        (WebCore::FrameView::sendWillRevealEdgeEventsIfNeeded): Deleted.
46767        * page/FrameView.h:
46768        * platform/ScrollableArea.h:
46769        (WebCore::ScrollableArea::sendWillRevealEdgeEventsIfNeeded): Deleted.
46770
46771        Call sendWillRevealEdgeEventsIfNeeded() after sending scroll events. 
46772        * rendering/RenderLayer.cpp:
46773        (WebCore::RenderLayer::scrollTo):
46774
467752014-04-01  Jon Honeycutt  <jhoneycutt@apple.com>
46776
46777        Crash in WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients
46778
46779        <https://bugs.webkit.org/show_bug.cgi?id=121887>
46780        <rdar://problem/15073043>
46781
46782        Reviewed by Dean Jackson.
46783
46784        Test: svg/filters/first-letter-crash.html
46785
46786        * rendering/FilterEffectRenderer.cpp:
46787        (WebCore::FilterEffectRenderer::buildReferenceFilter):
46788        Added a null check to prevent crashes for anonymous RenderObjects.
46789
46790        * rendering/RenderLayer.cpp:
46791        (WebCore::RenderLayer::filterNeedsRepaint):
46792        Get the enclosing element, if there is one, and recalculate its style.
46793        We use the enclosing element so that we recalculate style for the
46794        ancestor of an anonymous RenderElement.
46795        (WebCore::RenderLayer::enclosingElement):
46796        Remove an assertion; we may now reach this condition if loading a
46797        cached SVG document results in RenderLayer::filterNeedsRepaint() being
46798        called before the object has been inserted into the render tree.
46799
46800        * rendering/RenderLayerFilterInfo.cpp:
46801        (WebCore::RenderLayer::FilterInfo::notifyFinished):
46802        Tell the RenderLayer that the filter needs repainting.
46803        (WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients):
46804        Get the Element from the renderer rather than asking the renderer's
46805        Element, which will be null for anonymous RenderObjects.
46806
46807        * rendering/RenderLayerFilterInfo.h:
46808        Removed declaration for the old workaround function, layerElement().
46809
468102014-04-01  Ryuan Choi  <ryuan.choi@samsung.com>
46811
46812        Build break when disabled VIDEO since r166261
46813        https://bugs.webkit.org/show_bug.cgi?id=131087
46814
46815        Reviewed by Gyuyoung Kim.
46816
46817        * testing/Internals.cpp: Added ENABLE(VIDEO) guards
46818        (WebCore::Internals::simulateSystemSleep):
46819        (WebCore::Internals::simulateSystemWake):
46820
468212014-04-01  Timothy Hatcher  <timothy@apple.com>
46822
46823        Remove HeapProfiler from the Web Inspector protocol.
46824
46825        https://bugs.webkit.org/show_bug.cgi?id=131070
46826
46827        Reviewed by Joseph Pecoraro.
46828
46829        * CMakeLists.txt:
46830        * DerivedSources.make:
46831        * WebCore.vcxproj/WebCore.vcxproj:
46832        * WebCore.vcxproj/WebCore.vcxproj.filters:
46833        * WebCore.xcodeproj/project.pbxproj:
46834        * bindings/js/ScriptHeapSnapshot.h: Removed.
46835        * bindings/js/ScriptProfiler.h:
46836        (WebCore::ScriptProfiler::takeHeapSnapshot): Deleted.
46837        (WebCore::ScriptProfiler::isSampling): Deleted.
46838        (WebCore::ScriptProfiler::hasHeapProfiler): Deleted.
46839        * inspector/InspectorAllInOne.cpp:
46840        * inspector/InspectorController.cpp:
46841        (WebCore::InspectorController::InspectorController):
46842        * inspector/InspectorHeapProfilerAgent.cpp: Removed.
46843        * inspector/InspectorHeapProfilerAgent.h: Removed.
46844        * inspector/InspectorInstrumentation.cpp:
46845        (WebCore::InspectorInstrumentation::didCommitLoadImpl):
46846        * inspector/InspectorProfilerAgent.cpp:
46847        (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
46848        (WebCore::InspectorProfilerAgent::getProfileHeaders):
46849        (WebCore::InspectorProfilerAgent::removeProfile):
46850        (WebCore::InspectorProfilerAgent::resetState): The CommandLineAPIHost call to
46851        clear inspected objects should have not been here. It was only needed by the
46852        HeapProfilerAgent.
46853        (WebCore::InspectorProfilerAgent::resetFrontendProfiles):
46854        (WebCore::InspectorProfilerAgent::collectGarbage): Deleted.
46855        (WebCore::InspectorProfilerAgent::createSnapshotHeader): Deleted.
46856        (WebCore::InspectorProfilerAgent::isSampling): Deleted.
46857        (WebCore::InspectorProfilerAgent::hasHeapProfiler): Deleted.
46858        (WebCore::InspectorProfilerAgent::getHeapSnapshot): Deleted.
46859        (WebCore::InspectorProfilerAgent::takeHeapSnapshot): Deleted.
46860        (WebCore::InspectorProfilerAgent::getObjectByHeapObjectId): Deleted.
46861        (WebCore::InspectorProfilerAgent::getHeapObjectId): Deleted.
46862        * inspector/InspectorProfilerAgent.h:
46863        * inspector/InstrumentingAgents.h:
46864        (WebCore::InstrumentingAgents::inspectorHeapProfilerAgent): Deleted.
46865        (WebCore::InstrumentingAgents::setInspectorHeapProfilerAgent): Deleted.
46866        * inspector/WebConsoleAgent.cpp:
46867        (WebCore::WebConsoleAgent::addInspectedHeapObject): Deleted.
46868        * inspector/WebConsoleAgent.h:
46869        * inspector/WorkerInspectorController.cpp:
46870        (WebCore::WorkerInspectorController::WorkerInspectorController):
46871        * inspector/protocol/HeapProfiler.json: Removed.
46872        * inspector/protocol/Profiler.json:
46873
468742014-04-01  Zoltan Horvath  <zoltan@webkit.org>
46875
46876        [CSS Exclusions] Remove exclusions parsing support
46877        https://bugs.webkit.org/show_bug.cgi?id=131046
46878
46879        Reviewed by David Hyatt.
46880
46881        CSS Exclusions specification [1] needs some evolution before the actual implementation happens.
46882        We have only the parsing code in WebKit for -webkit-wrap-flow and -webkit-wrap-through.
46883        This patch removes the code from the trunk for now, it doesn't make sense to keep it around.
46884
46885        [1] http://www.w3.org/TR/css3-exclusions/
46886
46887        Removed existing parsing tests.
46888
46889        * css/CSSComputedStyleDeclaration.cpp:
46890        (WebCore::ComputedStyleExtractor::propertyValue):
46891        * css/CSSParser.cpp:
46892        (WebCore::isValidKeywordPropertyAndValue):
46893        (WebCore::isKeywordPropertyID):
46894        (WebCore::CSSParser::parseValue):
46895        * css/CSSPrimitiveValueMappings.h:
46896        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Deleted.
46897        (WebCore::CSSPrimitiveValue::operator WrapFlow): Deleted.
46898        (WebCore::CSSPrimitiveValue::operator WrapThrough): Deleted.
46899        * css/CSSPropertyNames.in:
46900        * css/CSSValueKeywords.in:
46901        * css/DeprecatedStyleBuilder.cpp:
46902        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
46903        * css/StyleResolver.cpp:
46904        (WebCore::StyleResolver::applyProperty):
46905        * rendering/style/RenderStyle.cpp:
46906        (WebCore::RenderStyle::changeRequiresLayout):
46907        * rendering/style/RenderStyle.h:
46908        * rendering/style/RenderStyleConstants.h:
46909        * rendering/style/StyleRareNonInheritedData.cpp:
46910        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
46911        (WebCore::StyleRareNonInheritedData::operator==):
46912        * rendering/style/StyleRareNonInheritedData.h:
46913
469142014-04-01  Timothy Hatcher  <timothy@apple.com>
46915
46916        Remove the rest of the old Canvas inspection support.
46917
46918        https://bugs.webkit.org/show_bug.cgi?id=131066
46919
46920        Reviewed by Joseph Pecoraro.
46921
46922        * CMakeLists.txt: Removed Canvas.json.
46923        * DerivedSources.make: Ditto.
46924        * inspector/InjectedScriptCanvasModuleSource.js: Removed.
46925        * inspector/protocol/Canvas.json: Removed.
46926
469272014-04-01  Alexey Proskuryakov  <ap@apple.com>
46928
46929        Eliminate HTMLFormElement::m_shouldSubmit
46930        https://bugs.webkit.org/show_bug.cgi?id=131055
46931
46932        Reviewed by Tim Horton.
46933
46934        m_shouldSubmit was used for two purposes:
46935        - as a return value in a function whose return value is ignored by all callers;
46936        - to make a decision that's local to a function.
46937
46938        There is no need for it to be an instance variable.
46939
46940        * html/HTMLFormElement.cpp:
46941        (WebCore::HTMLFormElement::HTMLFormElement):
46942        (WebCore::HTMLFormElement::prepareForSubmission):
46943        (WebCore::HTMLFormElement::submit):
46944        * html/HTMLFormElement.h:
46945
469462014-04-01  Benjamin Poulain  <bpoulain@apple.com>
46947
46948        Remove a couple of useless static strings
46949        https://bugs.webkit.org/show_bug.cgi?id=131003
46950
46951        Reviewed by David Kilzer.
46952
46953        There is zero value in keeping those strings alive.
46954
46955        * css/StyleProperties.cpp:
46956        (WebCore::isInitialOrInherit):
46957
469582014-04-01  Myles C. Maxfield  <mmaxfield@apple.com>
46959
46960        svg/text/text-overflow-ellipsis-svgfont-kerning-ligatures.html and svg/css/font-face-crash.html frequently assert in ComplexTextController::offsetForPosition
46961        https://bugs.webkit.org/show_bug.cgi?id=119747
46962
46963        Reviewed by Simon Fraser.
46964
46965        Even though kerning and ligatures currently don't work with the
46966        simple text path, messing those up is better than creating null
46967        CTRun and CTLine objects.
46968
46969        Rather than calling the badly-named renderingContext() function on TextRun objects
46970        to determine if they are drawn with an SVG font, this patch creates a wrapper function
46971        with a better name and uses that instead.
46972
46973        Test: svg/text/svg-font-hittest.html
46974
46975        * platform/graphics/Font.cpp:
46976        (WebCore::isDrawnWithSVGFont): Wrapper around renderingContext()
46977        (WebCore::Font::drawText): Use wrapper function
46978        (WebCore::Font::drawEmphasisMarks): Use wrapper function
46979        (WebCore::Font::width): Use wrapper function
46980        (WebCore::Font::selectionRectForText): Use wrapper function
46981        (WebCore::Font::offsetForPosition): If we are using an SVG font, use the simple path
46982        instead of the complex one
46983        (WebCore::Font::codePath): Use wrapper function
46984        * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
46985        (WebCore::FontPlatformData::ctFont):
46986
469872014-04-01  Daniel Bates  <dabates@apple.com>
46988
46989        RenderQuote must destroy remaining text renderer before first letter renderer
46990        https://bugs.webkit.org/show_bug.cgi?id=78023
46991        <rdar://problem/10830009>
46992
46993        Reviewed by Brent Fulgham.
46994
46995        Merged from Blink (patch by Abhishek Arya):
46996        https://src.chromium.org/viewvc/blink?view=rev&revision=151270
46997
46998        Following the fix for <https://bugs.webkit.org/show_bug.cgi?id=114586>, a
46999        RenderQuote may have child render objects for the first letter of its text
47000        and everything following the first letter so as to support the CSS first-
47001        letter property. The latter renderer is responsible for destroying the former
47002        on destruction. It's sufficient to reverse the destruction of the children of
47003        RenderQuote to ensure that we destroy the remaining text renderer before we
47004        destroy the first letter renderer.
47005
47006        Test: fast/css-generated-content/quote-first-letter-crash.html
47007
47008        * rendering/RenderQuote.cpp:
47009        (WebCore::RenderQuote::updateText):
47010
470112014-04-01  David Kilzer  <ddkilzer@apple.com>
47012
47013        Do not allow HTTP refresh headers to refresh to javascript: URLs
47014        <http://webkit.org/b/119051>
47015        <rdar://problem/14536453>
47016
47017        Reviewed by Alexey Proskuryakov.
47018
47019        Merged from Blink (patch by tsepez@chromium.org):
47020        https://src.chromium.org/viewvc/blink?revision=153912&view=revision
47021        http://crbug.com/258151
47022
47023            This behaviour has been standard in IE since IE7.  This makes us both
47024            more compatible and less vulnerable to XSS.
47025
47026        Tests: http/tests/security/no-javascript-location-percent-escaped.html
47027               http/tests/security/no-javascript-location.html
47028               http/tests/security/no-javascript-refresh-percent-escaped.php
47029               http/tests/security/no-javascript-refresh-spaces.php
47030               http/tests/security/no-javascript-refresh-static-percent-escaped.html
47031               http/tests/security/no-javascript-refresh-static-spaces.html
47032               http/tests/security/no-javascript-refresh-static.html
47033               http/tests/security/no-javascript-refresh.php
47034
47035        * dom/Document.cpp:
47036        (WebCore::Document::processHttpEquiv):
47037        * loader/FrameLoader.cpp:
47038        (WebCore::FrameLoader::receivedFirstData):
47039        - Do not fire meta http refresh for a javascript: URL protocol.
47040
470412014-04-01  Pratik Solanki  <psolanki@apple.com>
47042
47043        Unreviewed build fix. Remove duplicate file entries.
47044
47045        * WebCore.xcodeproj/project.pbxproj:
47046
470472014-03-31  Simon Fraser  <simon.fraser@apple.com>
47048
47049        Enable WEB_TIMING on Mac and iOS
47050        https://bugs.webkit.org/show_bug.cgi?id=128064
47051
47052        Reviewed by Sam Weinig, Brent Fulgham.
47053
47054        Enable WEB_TIMING. Add PerformanceTiming.cpp and JSPerformanceTiming.cpp
47055        to the project.
47056        
47057        * Configurations/FeatureDefines.xcconfig:
47058        * WebCore.xcodeproj/project.pbxproj:
47059
470602014-04-01  James Craig  <jcraig@apple.com>
47061
47062        AX: AccessibilityRenderObject::ariaLiveRegionAtomic() should default to true if
47063        roleValue is ApplicationAlertRole || ApplicationStatusRole
47064        https://bugs.webkit.org/show_bug.cgi?id=130907
47065
47066        Reviewed by Chris Fleizach.
47067
47068        Tests: inspector-protocol/dom/getAccessibilityPropertiesForNode_liveRegion.html:
47069               platform/mac/accessibility/aria-liveregions-attributes.html:
47070
47071        Updated AccessibilityRenderObject::ariaLiveRegionAtomic() to match ARIA spec.
47072
47073        * accessibility/AccessibilityRenderObject.cpp:
47074        (WebCore::AccessibilityRenderObject::ariaLiveRegionAtomic):
47075
470762014-04-01  Zan Dobersek  <zdobersek@igalia.com>
47077
47078        Unreviewed. Fixing debug builds after r166586.
47079
47080        * svg/SVGElement.cpp:
47081        (WebCore::SVGElement::addEventListener): Fix the ASSERT.
47082        (WebCore::SVGElement::removeEventListener): Ditto.
47083
470842014-04-01  Zan Dobersek  <zdobersek@igalia.com>
47085
47086        Prevent unnecessary copies in compareEqual template
47087        https://bugs.webkit.org/show_bug.cgi?id=131014
47088
47089        Reviewed by Antti Koivisto.
47090
47091        * rendering/style/RenderStyle.h:
47092        (compareEqual): Casting the second parameter to a non-const, non-reference type
47093        causes an extra copy of that object. Casting to the const reference type of the
47094        first parameter avoids that.
47095
470962014-04-01  Zan Dobersek  <zdobersek@igalia.com>
47097
47098        Avoid unnecessary HashSet copies when calling collectInstancesForSVGElement
47099        https://bugs.webkit.org/show_bug.cgi?id=131020
47100
47101        Reviewed by Andreas Kling.
47102
47103        Remove collectInstancesForSVGElement() to avoid HashSet copies when assigning a const
47104        HashSet reference to a non-const HashSet reference. Instead, range-based for-loops are
47105        deployed to iterate directly over the const reference to HashSet that's returned by
47106        SVGElement::instancesForElement(). SVGElement::containingShadowRoot() return value
47107        is checked to see if the iteration should be performed in the first place, preserving
47108        the behavior of collectInstancesForSVGElement().
47109
47110        * svg/SVGElement.cpp:
47111        (WebCore::SVGElement::addEventListener):
47112        (WebCore::SVGElement::removeEventListener):
47113        (WebCore::collectInstancesForSVGElement): Deleted.
47114
471152014-04-01  Zan Dobersek  <zdobersek@igalia.com>
47116
47117        Move the attributes HashMap out of the parseAttributes function
47118        https://bugs.webkit.org/show_bug.cgi?id=131019
47119
47120        Reviewed by Andreas Kling.
47121
47122        * xml/parser/XMLDocumentParserLibxml2.cpp:
47123        (WebCore::parseAttributes): Avoid copying the HashMap object that's being returned by
47124        converting it to an xvalue through using std::move() in the return statement.
47125
471262014-04-01  Zalan Bujtas  <zalan@apple.com>
47127
47128        Subpixel rendering: Transition class Image (and its dependencies) from int to float to enable subpixel positioned/sized images.
47129        https://bugs.webkit.org/show_bug.cgi?id=130643
47130
47131        Reviewed by Simon Fraser.
47132
47133        This is in preparation to support subpixel positioned/sized background images. While 1x bitmap images can't take
47134        subpixel sizing on hidpi resolutions, both generated and hidpi images can.
47135        This patch does not change Image behavior in general as both position and size are still snapped to integral values.  
47136
47137        No change in behavior.
47138
47139        * WebCore.exp.in:
47140        * css/CSSCrossfadeValue.cpp:
47141        (WebCore::CSSCrossfadeValue::fixedSize):
47142        * css/CSSFilterImageValue.cpp:
47143        (WebCore::CSSFilterImageValue::fixedSize):
47144        * html/canvas/WebGLRenderingContext.cpp:
47145        (WebCore::WebGLRenderingContext::drawImageIntoBuffer):
47146        * loader/cache/CachedImage.cpp:
47147        (WebCore::CachedImage::imageSizeForRenderer):
47148        * page/EventHandler.cpp:
47149        (WebCore::EventHandler::selectCursor):
47150        * platform/Cursor.cpp:
47151        (WebCore::determineHotSpot):
47152        * platform/graphics/BitmapImage.cpp:
47153        (WebCore::BitmapImage::size):
47154        (WebCore::BitmapImage::currentFrameSize):
47155        * platform/graphics/BitmapImage.h:
47156        * platform/graphics/CrossfadeGeneratedImage.cpp:
47157        (WebCore::CrossfadeGeneratedImage::CrossfadeGeneratedImage):
47158        (WebCore::drawCrossfadeSubimage):
47159        (WebCore::CrossfadeGeneratedImage::drawCrossfade):
47160        * platform/graphics/CrossfadeGeneratedImage.h:
47161        * platform/graphics/GeneratedImage.h:
47162        * platform/graphics/Gradient.cpp:
47163        (WebCore::Gradient::adjustParametersForTiledDrawing):
47164        * platform/graphics/Gradient.h:
47165        * platform/graphics/GradientImage.cpp:
47166        (WebCore::GradientImage::drawPattern):
47167        * platform/graphics/GradientImage.h:
47168        * platform/graphics/GraphicsContext.cpp:
47169        (WebCore::GraphicsContext::createCompatibleBuffer):
47170        * platform/graphics/GraphicsContext.h:
47171        * platform/graphics/Image.cpp:
47172        (WebCore::Image::adjustSourceRectForDownSampling):
47173        * platform/graphics/Image.h:
47174        (WebCore::Image::setContainerSize):
47175        (WebCore::Image::rect):
47176        (WebCore::Image::width):
47177        (WebCore::Image::height):
47178        * platform/graphics/ImageBuffer.cpp:
47179        (WebCore::ImageBuffer::createCompatibleBuffer):
47180        * platform/graphics/ImageBuffer.h:
47181        (WebCore::ImageBuffer::create):
47182        * platform/graphics/IntPoint.cpp:
47183        (WebCore::IntPoint::IntPoint):
47184        * platform/graphics/IntPoint.h:
47185        * platform/graphics/IntSize.cpp:
47186        (WebCore::IntSize::IntSize):
47187        * platform/graphics/IntSize.h:
47188        * platform/graphics/cairo/ImageBufferCairo.cpp:
47189        (WebCore::ImageBuffer::ImageBuffer):
47190        * platform/graphics/cairo/ImageCairo.cpp:
47191        (WebCore::Image::drawPattern):
47192        * platform/graphics/cg/ImageBufferCG.cpp:
47193        (WebCore::ImageBuffer::ImageBuffer):
47194        * platform/graphics/cg/ImageBufferDataCG.cpp:
47195        * platform/graphics/cg/PDFDocumentImage.cpp:
47196        (WebCore::PDFDocumentImage::size):
47197        (WebCore::PDFDocumentImage::updateCachedImageIfNeeded):
47198        (WebCore::applyRotationForPainting):
47199        * platform/graphics/cg/PDFDocumentImage.h:
47200        * platform/graphics/cg/PatternCG.cpp:
47201        (WebCore::Pattern::createPlatformPattern):
47202        * platform/graphics/mac/GraphicsContextMac.mm:
47203        * platform/graphics/mac/IconMac.mm:
47204        * platform/graphics/texmap/TextureMapperTiledBackingStore.cpp:
47205        (WebCore::TextureMapperTiledBackingStore::updateContentsFromImageIfNeeded):
47206        * platform/graphics/texmap/coordinated/CoordinatedImageBacking.cpp:
47207        (WebCore::CoordinatedImageBacking::update):
47208        * platform/graphics/win/ImageCGWin.cpp:
47209        (WebCore::BitmapImage::getHBITMAPOfSize):
47210        (WebCore::BitmapImage::drawFrameMatchingSourceSize):
47211        * platform/graphics/win/ImageCairoWin.cpp:
47212        (WebCore::BitmapImage::getHBITMAPOfSize):
47213        (WebCore::BitmapImage::drawFrameMatchingSourceSize):
47214        * platform/mac/DragImageMac.mm:
47215        (WebCore::createDragImageFromImage):
47216        * platform/win/DragImageCGWin.cpp:
47217        (WebCore::createDragImageFromImage):
47218        * platform/win/PasteboardWin.cpp:
47219        (WebCore::Pasteboard::writeImage):
47220        * rendering/RenderImage.cpp:
47221        (WebCore::RenderImage::imageSizeForError):
47222        (WebCore::RenderImage::paintReplaced):
47223        * rendering/RenderLayer.cpp:
47224        (WebCore::RenderLayer::drawPlatformResizerImage):
47225        * svg/graphics/SVGImage.cpp:
47226        (WebCore::SVGImage::setContainerSize):
47227        * svg/graphics/SVGImage.h:
47228        * svg/graphics/SVGImageCache.cpp:
47229        (WebCore::SVGImageCache::imageSizeForRenderer):
47230        * svg/graphics/SVGImageCache.h:
47231        * svg/graphics/SVGImageForContainer.cpp:
47232        (WebCore::SVGImageForContainer::size):
47233        * svg/graphics/SVGImageForContainer.h:
47234        * svg/graphics/filters/SVGFEImage.cpp:
47235        (WebCore::FEImage::externalRepresentation):
47236        * testing/Internals.cpp:
47237        (WebCore::Internals::getCurrentCursorInfo):
47238
472392014-04-01  Ryuan Choi  <ryuan.choi@samsung.com>
47240
47241        Unreviewed build fix when disabled ACCESSIBILITY
47242
47243        * accessibility/atk/WebKitAccessibleInterfaceTableCell.cpp:
47244        Separated macros not to check ATK version when disabled ACCESSIBILITY
47245
472462014-04-01  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
47247
47248        [CMake][EFL] Enable CSS JIT
47249        https://bugs.webkit.org/show_bug.cgi?id=131010
47250
47251        Reviewed by Benjamin Poulain.
47252
47253        Add an inclusion path for enabling CSS JIT on EFL and GTK ports.
47254        This patch only enables it for EFL port.
47255
47256        * CMakeLists.txt:
47257
472582014-04-01  Martin Robinson  <mrobinson@igalia.com>
47259
47260        [GTK] Readonly attributes installed as readwrite in GObject DOM bindings
47261        https://bugs.webkit.org/show_bug.cgi?id=130978
47262
47263        Reviewed by Carlos Garcia Campos.
47264
47265        Unify how we decide if an attribute is readable or writeable and improve the code.
47266        This results in some attributes now being marked as read-only which didn't have
47267        corresponding case statements in the set_property switch statements and also correctly
47268        installs set_property support for some more POD types.
47269
47270        * bindings/scripts/CodeGeneratorGObject.pm:
47271        (IsPropertyReadable): Added this helper to simplify deciding if an attribute is readable.
47272        (IsPropertyWriteable): Added this helper to simplify deciding if an attribute is writeable. Also
47273        update the list of types to reflect the full list of types we can generate setters for.
47274        (GenerateProperty): Use the IsPropertyWriteable helper instead of checking whether the attribute is read-only.
47275        Also fix generation of the blurb by using $mutableString instead of $mutableStringconst which isn't used.
47276        (GenerateProperties): Use grep and the new helpers to simplify the code.
47277        (GetReadableProperties): Deleted.
47278        (GetWriteableProperties): Deleted.
47279        * bindings/scripts/test/GObject: Update results
47280
472812014-03-31  Ryuan Choi  <ryuan.choi@samsung.com>
47282
47283        [EFL][WK2] Extract the control of page background out of color_set
47284        https://bugs.webkit.org/show_bug.cgi?id=127539
47285
47286        Reviewed by Gyuyoung Kim.
47287
47288        * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
47289        Added m_viewBackgroundColor to clear when m_setDrawsBackground is false.
47290        (WebCore::CoordinatedGraphicsScene::CoordinatedGraphicsScene):
47291        (WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext):
47292        (WebCore::CoordinatedGraphicsScene::paintToGraphicsContext):
47293        * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
47294        (WebCore::CoordinatedGraphicsScene::setViewBackgroundColor):
47295        (WebCore::CoordinatedGraphicsScene::viewBackgroundColor):
47296        * rendering/RenderLayerBacking.cpp:
47297        (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
47298        Added EFL guard not to set opaque as a default for MainFrameRenderViewLayer.
47299        * rendering/RenderLayerCompositor.cpp:
47300        (WebCore::RenderLayerCompositor::ensureRootLayer):
47301        Added EFL guard to apply page scale on RenderView like IOS.
47302
473032014-03-31  Byungseon Shin  <sun.shin@lge.com>
47304
47305        [WebGL][OpenGLES] Enable MSAA support for WebGL Canvas
47306        https://bugs.webkit.org/show_bug.cgi?id=130955
47307
47308        Reviewed by Dean Jackson.
47309
47310        To avoid aliasing issues when we render content to WebGL canvas,
47311         we need to implement MSAA support.
47312        - Imagination OpenGLES GPU Driver already support MSAA, so we
47313         need a separate code path to enable it.
47314
47315        * platform/graphics/Extensions3D.h:
47316        * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
47317        (WebCore::Extensions3DOpenGLCommon::Extensions3DOpenGLCommon):
47318        * platform/graphics/opengl/Extensions3DOpenGLCommon.h:
47319        (WebCore::Extensions3DOpenGLCommon::isImagination):
47320        * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
47321        (WebCore::GraphicsContext3D::reshapeFBOs):
47322
473232014-03-31  Alexey Proskuryakov  <ap@apple.com>
47324
47325        Crashes in PageConsole::addMessage
47326        https://bugs.webkit.org/show_bug.cgi?id=130991
47327        <rdar://problem/14795232>
47328
47329        Reviewed by Geoffrey Garen.
47330
47331        Test: http/tests/misc/detached-frame-console.html
47332
47333        * page/DOMWindow.cpp: (WebCore::DOMWindow::printErrorMessage): Added a null check.
47334        It's legitimate for this to be called for a window that is not currently displayed
47335        in a frame.
47336
473372014-03-31  Simon Fraser  <simon.fraser@apple.com>
47338
47339        [UI-side compositing] Proxy animations to the UI process
47340        https://bugs.webkit.org/show_bug.cgi?id=130946
47341
47342        Reviewed by Tim Horton.
47343        
47344        To proxy CA animations, make PlatformCAAnimation a pure virtual base class
47345        and subclass for Mac, Windows, and Remote (just like PlatformCALayer).
47346        
47347        Add coding support for TimingFunctions.
47348        
47349        Do some minor #include tidyup.
47350        
47351        Minor refactor in GraphicsLayerCA to share some animations code.
47352
47353        * WebCore.exp.in:
47354        * WebCore.xcodeproj/project.pbxproj:
47355        * platform/animation/TimingFunction.h: Add setters need for encode/decode.
47356        (WebCore::CubicBezierTimingFunction::setValues):
47357        (WebCore::CubicBezierTimingFunction::setTimingFunctionPreset):
47358        (WebCore::StepsTimingFunction::create):
47359        (WebCore::StepsTimingFunction::setNumberOfSteps):
47360        (WebCore::StepsTimingFunction::setStepAtStart):
47361        * platform/graphics/ca/GraphicsLayerCA.cpp:
47362        (WebCore::GraphicsLayerCA::createPlatformCAAnimation):
47363        (WebCore::GraphicsLayerCA::animationCanBeAccelerated): Minor refactor so we can share
47364        code with GraphicsLayerCARemote.
47365        (WebCore::GraphicsLayerCA::addAnimation):
47366        (WebCore::GraphicsLayerCA::createBasicAnimation):
47367        (WebCore::PassRefPtr<PlatformCAAnimation>GraphicsLayerCA::createKeyframeAnimation):
47368        * platform/graphics/ca/GraphicsLayerCA.h:
47369        * platform/graphics/ca/PlatformCAAnimation.h:
47370        (WebCore::PlatformCAAnimation::~PlatformCAAnimation):
47371        (WebCore::PlatformCAAnimation::isPlatformCAAnimationMac):
47372        (WebCore::PlatformCAAnimation::isPlatformCAAnimationWin):
47373        (WebCore::PlatformCAAnimation::isPlatformCAAnimationRemote):
47374        (WebCore::PlatformCAAnimation::PlatformCAAnimation):
47375        (WebCore::PlatformCAAnimation::setType):
47376        * platform/graphics/ca/PlatformCALayer.h:
47377        * platform/graphics/ca/mac/PlatformCAAnimationMac.h: Added.
47378        * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
47379        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
47380        (PlatformCALayerMac::addAnimationForKey):
47381        (PlatformCALayerMac::animationForKey):
47382        * platform/graphics/ca/mac/TileController.mm:
47383        * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
47384        * platform/graphics/ca/win/PlatformCAAnimationWin.h: Added.
47385
473862014-03-31  Benjamin Poulain  <benjamin@webkit.org>
47387
47388        CSS JIT: compile the first-child pseudo class
47389        https://bugs.webkit.org/show_bug.cgi?id=130954
47390
47391        Reviewed by Andreas Kling.
47392
47393        * css/ElementRuleCollector.cpp:
47394        (WebCore::ElementRuleCollector::collectMatchingRules):
47395        The compiler use the context's style directly when resolving style. An error introduced
47396        in the rule collector would cause a crash in the compiled code which would be hard to debug.
47397        Add an assertion early in the stack to catch errors where it is easier to debug them.
47398
47399        * css/StyleResolver.cpp:
47400        (WebCore::StyleResolver::State::initForStyleResolve):
47401        * cssjit/SelectorCompiler.cpp:
47402        (WebCore::SelectorCompiler::addPseudoType):
47403        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
47404        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToPreviousAdjacentElement):
47405        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToPreviousAdjacent):
47406        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
47407        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateIndirectAdjacentTreeWalker):
47408        Refactor those to be able to reuse the code getting a sibling element preceding the current element.
47409
47410        (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNotResolvingStyle):
47411        Extract the code checking the current mode from SelectorCodeGenerator::markParentElementIfResolvingStyle()
47412        in a separate function. This will be useful for all the pseudo class with marking.
47413
47414        (WebCore::SelectorCompiler::SelectorCodeGenerator::markParentElementIfResolvingStyle):
47415        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
47416        (WebCore::SelectorCompiler::setFirstChildState):
47417        This is the slow path for when the first-child pseudo class is on a fragment that is not
47418        the rightmost.
47419        The reason to use a slow path is accessing renderStyle() is not trivial and this case isn't not
47420        as common. We should improve this later.
47421
47422        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFirstChild):
47423        This is just implementing the test for first-child plus the tree marking. Nothing fancy,
47424        this is basically the same thing as SelectorChecker.
47425
47426        * dom/Element.cpp:
47427        (WebCore::Element::setChildrenAffectedByFirstChildRules):
47428        * dom/Element.h:
47429        C++ fallback to set the flag, to be improved later with the other flags.
47430
47431        * rendering/style/RenderStyle.h:
47432        I accidentaly put noninheritedFlagsMemoryOffset() as private in the RenderStyle refactoring.
47433
47434        Also update the flags accessor to make them easier to work with from the compiler. In particular,
47435        setFirstChildStateFlags() sets both isUnique and firstChild. Currently the JIT does not need to access
47436        the value so individual flags are made private.
47437
474382014-03-31  Dean Jackson  <dino@apple.com>
47439
47440        Remove WEB_ANIMATIONS
47441        https://bugs.webkit.org/show_bug.cgi?id=130989
47442
47443        Reviewed by Simon Fraser.
47444
47445        Remove this feature flag until we plan to implement.
47446
47447        * Configurations/FeatureDefines.xcconfig:
47448
474492014-03-31  Simon Fraser  <simon.fraser@apple.com>
47450
47451        Fix iOS build.
47452
47453        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
47454        (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterDelegatedScroll):
47455
474562014-03-31  Pratik Solanki  <psolanki@apple.com>
47457
47458        Unreviewed. iOS build fix after r166532. Add missing comma.
47459
47460        * dom/DocumentMarker.h:
47461
474622014-03-31  Brady Eidson  <beidson@apple.com>
47463
47464        Add variant of phone number parsing that use DocumentMarker in the current selection
47465        <rdar://problem/16379566> and https://bugs.webkit.org/show_bug.cgi?id=130917
47466
47467        Reviewed by Darin Adler.
47468
47469        * dom/DocumentMarker.h:
47470        (WebCore::DocumentMarker::AllMarkers::AllMarkers): Add a new TelephoneNumber document marker type.
47471
47472        * editing/Editor.cpp:
47473        (WebCore::Editor::respondToChangedSelection):
47474        (WebCore::Editor::scanSelectionForTelephoneNumbers): TextIterate over the selected range looking for numbers.
47475        (WebCore::Editor::scanRangeForTelephoneNumbers): Scan the given range for a telephone number,
47476          adding the DocumentMarker to any that are found.
47477        (WebCore::Editor::clearDataDetectedTelephoneNumbers):
47478        * editing/Editor.h:
47479
47480        * html/parser/HTMLTreeBuilder.cpp:
47481        (WebCore::HTMLTreeBuilder::processCharacterBufferForInBody): Only linkify on iOS.
47482
47483        * rendering/InlineTextBox.cpp:
47484        (WebCore::InlineTextBox::paintTelephoneNumberMarker): Placeholder UI while the feature is developed.
47485        (WebCore::InlineTextBox::paintDocumentMarkers):
47486        * rendering/InlineTextBox.h:
47487
47488        * testing/Internals.cpp:
47489        (WebCore::markerTypesFrom):
47490
474912014-03-31  Simon Fraser  <simon.fraser@apple.com>
47492
47493        [iOS WK2] Hook up scroll events for accelerated overflow:scroll
47494        https://bugs.webkit.org/show_bug.cgi?id=130976
47495
47496        Reviewed by Tim Horton.
47497
47498        When an accelerated overflow:scroll is scrolled in the UI process,
47499        tell the WebProcess that the scroll happened to update RenderLayer
47500        state and fire events.
47501        
47502        In the WebProcess, RemoteScrollingCoordinator gets a message from the
47503        UI process and calls AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll().
47504        Fixed that function to handle scrolling nodes other than the root, which
47505        required storing a map of ScrollingNodeID->RenderLayer* on RenderLayerCompositor,
47506        accessible through FrameView::scrollableAreaForScrollLayerID().
47507
47508        * WebCore.exp.in:
47509        * page/FrameView.cpp:
47510        (WebCore::FrameView::scrollableAreaForScrollLayerID):
47511        * page/FrameView.h:
47512        * page/scrolling/AsyncScrollingCoordinator.cpp:
47513        (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll): Handle
47514        overflow as well as main frame scrolling nodes.
47515        * page/scrolling/ScrollingTree.cpp:
47516        (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling): Use isScrollingNode().
47517        (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling): When an overflow
47518        scroll node was scrolled externally, we have to update layers in decendant nodes,
47519        and then call scrollingTreeNodeDidScroll() which tells the ScrollingCoordinator that
47520        we scrolled.
47521        * page/scrolling/ScrollingTree.h: Try to reduce confusion between the roles played
47522        by these various functions, some of which happen in the UI process with UI-side
47523        compositing.
47524        * page/scrolling/ScrollingTreeScrollingNode.h:
47525        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h: Need some functions to be
47526        callable by subclasses.
47527        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
47528        (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterDelegatedScroll):
47529        * rendering/RenderLayerCompositor.cpp:
47530        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer): Add
47531        scrolling layers to the m_scrollingNodeToLayerMap
47532        (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer): Remove
47533        layer from the m_scrollingNodeToLayerMap.
47534        (WebCore::RenderLayerCompositor::scrollableAreaForScrollLayerID):
47535        * rendering/RenderLayerCompositor.h:
47536
475372014-03-31  Antti Koivisto  <antti@apple.com>
47538
47539        Rename TileCache to LegacyTileCache
47540        https://bugs.webkit.org/show_bug.cgi?id=130986
47541
47542        Reviewed by Simon Fraser.
47543
47544        Rename iOS WebKit1 tile cache classes to reflect its status.
47545        This also frees some good type names.
47546
47547        TileCache -> LegacyTileCache
47548        TileGrid -> LegacyTileGrid
47549        TileGridTile -> LegacyTileGridTile
47550        etc.
47551
475522014-03-31  Tim Horton  <timothy_horton@apple.com>
47553
47554        Small adjustments to WebCore::IOSurface
47555        https://bugs.webkit.org/show_bug.cgi?id=130981
47556
47557        Reviewed by Simon Fraser.
47558
47559        * WebCore.exp.in:
47560        Export some more things.
47561
47562        * platform/graphics/cocoa/IOSurface.h:
47563        createImage() can't be const because it calls ensurePlatformContext().
47564
47565        * platform/graphics/cocoa/IOSurface.mm:
47566        (IOSurface::createImage):
47567        We should be able to create an image even if the CGContext has been cleared (or never created).
47568
47569        (IOSurface::isInUse):
47570        Rename inUse() to isInUse().
47571
47572        (IOSurface::clearGraphicsContext):
47573        Add clearGraphicsContext().
47574
475752014-03-31  Tim Horton  <timothy_horton@apple.com>
47576
47577        Allocate IOSurfaces with the same cache mode that CoreAnimation uses
47578        https://bugs.webkit.org/show_bug.cgi?id=130982
47579
47580        Reviewed by Simon Fraser.
47581
47582        * platform/graphics/cocoa/IOSurface.mm:
47583        (IOSurface::IOSurface):
47584        CA uses kIOMapWriteCombineCache for IOSurfaces allocated on iOS.
47585
475862014-03-31  Ion Rosca  <rosca@adobe.com>
47587
47588        [CSS Blending] Blend mode property is propagated to multiple GraphicLayers
47589        https://bugs.webkit.org/show_bug.cgi?id=130337
47590
47591        Reviewed by Dean Jackson.
47592
47593        Resets the blend mode for graphicsLayer when it has an ancestorClippingLayer.
47594
47595        Test: css3/compositing/blend-mode-ancestor-clipping-layer.html
47596
47597        * rendering/RenderLayer.cpp:
47598        (WebCore::RenderLayer::updateBlendMode):
47599        (WebCore::RenderLayer::calculateClipRects):
47600        * rendering/RenderLayerBacking.cpp:
47601        (WebCore::RenderLayerBacking::updateBlendMode):
47602        * rendering/RenderLayerBacking.h:
47603
476042014-03-31  Ion Rosca  <rosca@adobe.com>
47605
47606        [CSS Blending] showLayerTree should dump layer's blend mode and isolation properties
47607        https://bugs.webkit.org/show_bug.cgi?id=130922
47608
47609        Reviewed by Simon Fraser.
47610
47611        This change only updates existing tests involving blending. No new test required,
47612        as there is no new or changed functionality.
47613
47614        * rendering/RenderLayer.h: adding blendMode() getter.
47615        * rendering/RenderTreeAsText.cpp:
47616        (WebCore::write):
47617        adding blendMode property and layer's isolation status (does layer isolate blending descendants or not?).
47618
476192014-03-31  Benjamin Poulain  <benjamin@webkit.org>
47620
47621        CSS JIT: clean up the functions ending when generating a checker with context
47622        https://bugs.webkit.org/show_bug.cgi?id=130959
47623
47624        Reviewed by Andreas Kling.
47625
47626        This code got refactored over time and now both branches do the exact same action
47627        on the stack.
47628        This patch removes the stack split and move the stack cleanup in the common ending
47629        just before restoring the callee saved registers.
47630
47631        * cssjit/SelectorCompiler.cpp:
47632        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
47633
476342014-03-31  Beth Dakin  <bdakin@apple.com>
47635
47636        ThemeMac should use std::array instead of IntSize* for control sizes
47637        https://bugs.webkit.org/show_bug.cgi?id=130985
47638
47639        Reviewed by Darin Adler.
47640
47641        Replace uses of const IntSize* with const std::array<IntSize, 3>
47642        * platform/mac/ThemeMac.mm:
47643        (WebCore::sizeFromNSControlSize):
47644        (WebCore::sizeFromFont):
47645        (WebCore::controlSizeFromPixelSize):
47646        (WebCore::setControlSize):
47647        (WebCore::checkboxSizes):
47648        (WebCore::radioSizes):
47649        (WebCore::buttonSizes):
47650        (WebCore::setUpButtonCell):
47651        (WebCore::stepperSizes):
47652
476532014-03-31  Hans Muller  <hmuller@adobe.com>
47654
47655        [CSS Shapes] Simplify RasterShape implementation
47656        https://bugs.webkit.org/show_bug.cgi?id=130916
47657
47658        Reviewed by Dean Jackson.
47659
47660        Since only floats can specify shape-outside, the RasterShapeIntervals
47661        class only needs to track the first and last above threshold pixel column
47662        (x1 and x2 in the implementation) for each row. Removed code for dealing with
47663        multiple "runs" per row as well as shape-inside internals.
47664
47665        No new tests, since functionality was only removed.
47666
47667        * rendering/shapes/RasterShape.cpp:
47668        (WebCore::RasterShapeIntervals::computeShapeMarginIntervals):
47669        (WebCore::RasterShapeIntervals::initializeBounds):
47670        (WebCore::RasterShapeIntervals::buildBoundsPath):
47671        (WebCore::RasterShape::getExcludedIntervals):
47672        * rendering/shapes/RasterShape.h:
47673        (WebCore::RasterShapeIntervals::RasterShapeIntervals):
47674        (WebCore::RasterShapeIntervals::intervalAt):
47675        (WebCore::RasterShape::RasterShape):
47676        * rendering/shapes/Shape.cpp:
47677        (WebCore::Shape::createRasterShape):
47678        * rendering/shapes/ShapeInterval.h:
47679        (WebCore::ShapeInterval::unite):
47680
476812014-03-31  Andreas Kling  <akling@apple.com>
47682
47683        Always inline toJS() for NodeList.
47684        <https://webkit.org/b/130974>
47685
47686        This is a pretty cheesy optimization, but it's a 3% progression on
47687        Dromaeo/dom-query.html on my MBP.
47688
47689        Reviewed by Benjamin Poulain.
47690
47691        * WebCore.exp.in:
47692        * WebCore.xcodeproj/project.pbxproj:
47693        * bindings/js/JSNodeListCustom.h: Added.
47694        (WebCore::toJS):
47695        * dom/NodeList.idl:
47696
476972014-03-31  Benjamin Poulain  <bpoulain@apple.com>
47698
47699        Attempt to fix the 32bits debug builds
47700
47701        The additional debug flags in RefCounted cause the structure to have different alignment
47702        with the 64bits flags.
47703
47704        * rendering/style/RenderStyle.cpp:
47705
477062014-03-29  Simon Fraser  <simon.fraser@apple.com>
47707
47708        Clarify some scrolling tree terminology
47709        https://bugs.webkit.org/show_bug.cgi?id=130929
47710
47711        Reviewed by Tim Horton.
47712
47713        Attempt to reduce some ambiguity in scrolling tree terminology.
47714        When async scrolling occurs, there are two tasks we have to perform:
47715        1. Layers need to be updated to reflect the scroll
47716        2. WebCore state has to be updated.
47717        The "updateForViewport" name didn't clearly reflect which of these
47718        tasks was being performed, so rename it to updateLayersAfterViewportChange()
47719        to reflect the fact that it only does the first.
47720        
47721        Remove the Mac implementation of updateLayersAfterViewportChange(), since
47722        it was confsued about this, and was never called anyway.
47723
47724        * WebCore.exp.in:
47725        * page/scrolling/ScrollingTree.cpp:
47726        (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling):
47727        * page/scrolling/ScrollingTreeScrollingNode.h:
47728        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
47729        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
47730        (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterViewportChange):
47731        (WebCore::ScrollingTreeScrollingNodeIOS::updateForViewport): Deleted.
47732        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
47733        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
47734        (WebCore::ScrollingTreeScrollingNodeMac::updateLayersAfterViewportChange):
47735        (WebCore::ScrollingTreeScrollingNodeMac::updateForViewport): Deleted.
47736
477372014-03-31  Tim Horton  <timothy_horton@apple.com>
47738
47739        [iOS WebKit2] Disable tile cohort retention for now
47740        https://bugs.webkit.org/show_bug.cgi?id=130926
47741        <rdar://problem/16465413>
47742
47743        Reviewed by Simon Fraser.
47744
47745        * WebCore.exp.in:
47746        * page/Settings.cpp:
47747        (WebCore::Settings::Settings):
47748        (WebCore::Settings::setScrollingPerformanceLoggingEnabled):
47749        (WebCore::Settings::setAggressiveTileRetentionEnabled): Deleted.
47750        * page/Settings.h:
47751        (WebCore::Settings::aggressiveTileRetentionEnabled): Deleted.
47752        * page/Settings.in:
47753        Use Settings.in for these simple settings.
47754
47755        * platform/graphics/GraphicsLayerClient.h:
47756        (WebCore::GraphicsLayerClient::shouldAggressivelyRetainTiles):
47757        (WebCore::GraphicsLayerClient::shouldTemporarilyRetainTileCohorts):
47758        * platform/graphics/TiledBacking.h:
47759        * platform/graphics/ca/GraphicsLayerCA.cpp:
47760        (WebCore::GraphicsLayerCA::platformCALayerShouldAggressivelyRetainTiles):
47761        (WebCore::GraphicsLayerCA::platformCALayerShouldTemporarilyRetainTileCohorts):
47762        * platform/graphics/ca/GraphicsLayerCA.h:
47763        * platform/graphics/ca/PlatformCALayerClient.h:
47764        (WebCore::PlatformCALayerClient::platformCALayerShouldAggressivelyRetainTiles):
47765        (WebCore::PlatformCALayerClient::platformCALayerShouldTemporarilyRetainTileCohorts):
47766        * rendering/RenderLayerBacking.cpp:
47767        (WebCore::RenderLayerBacking::shouldAggressivelyRetainTiles):
47768        (WebCore::RenderLayerBacking::shouldTemporarilyRetainTileCohorts):
47769        * rendering/RenderLayerBacking.h:
47770        Plumb the two tile-retention settings through to TileController in a pull manner
47771        instead of a push manner, as there were some cases (especially on iOS) where
47772        the settings weren't always getting pushed down.
47773
47774        * platform/graphics/ca/mac/TileController.h:
47775        * platform/graphics/ca/mac/TileController.mm:
47776        (WebCore::TileController::TileController):
47777        (WebCore::TileController::tileRevalidationTimerFired):
47778        (WebCore::TileController::revalidateTiles):
47779        (WebCore::TileController::drawTileMapContents):
47780        Aggressive tile retention wins over temporary retention. If we aren't
47781        using temporary (cohort) retention, throw away the cohort as soon as it
47782        is created.
47783
477842014-03-31  Beth Dakin  <bdakin@apple.com>
47785
47786        Radio buttons and checkboxes should share code
47787        https://bugs.webkit.org/show_bug.cgi?id=130915
47788
47789        Reviewed by Sam Weinig.
47790
47791        Radio buttons and checkboxes now share a lot of code. The common term for both is 
47792        toggle buttons.
47793
47794        Move these radio-sizing functions up in the file to be next to the checkbox sizing 
47795        functions.
47796        * platform/mac/ThemeMac.mm:
47797        (WebCore::radioSizes):
47798        (WebCore::radioMargins):
47799        (WebCore::radioSize):
47800
47801        Configures a radio button or a checkbox.
47802        (WebCore::configureToggleButton):
47803
47804        Creates a radio button or a checkbox.
47805        (WebCore::createToggleButtonCell):
47806
47807        Still have a shared cell for each.
47808        (WebCore::sharedRadioCell):
47809        (WebCore::sharedCheckboxCell):
47810
47811        Does the work of the old paintRadio() and paintCheckbox().
47812        (WebCore::paintToggleButton):
47813
47814        Use sharedRadioCell() here.
47815        (WebCore::ThemeMac::inflateControlPaintRect):
47816
47817        Call paintToggleButton() for radio buttons and checkboxes.
47818        (WebCore::ThemeMac::paint):
47819
47820        All gone.
47821        (WebCore::configureCheckbox): Deleted.
47822        (WebCore::createCheckboxCell): Deleted.
47823        (WebCore::paintCheckbox): Deleted.
47824        (WebCore::radio): Deleted.
47825        (WebCore::paintRadio): Deleted.
47826
478272014-03-31  Samuel White  <samuel_white@apple.com>
47828
47829        AX: Need ability to get line range for text marker.
47830        https://bugs.webkit.org/show_bug.cgi?id=130906
47831
47832        Reviewed by Chris Fleizach.
47833
47834        Added ability to get line range from any marker on that line. This matches the functionality of existing
47835        attributes such as AXParagraphTextMarkerRangeForTextMarker and AXSentenceTextMarkerRangeForTextMarker.
47836
47837        Test: platform/mac/accessibility/line-range-for-text-marker.html
47838
47839        * accessibility/AccessibilityObject.cpp:
47840        (WebCore::AccessibilityObject::visiblePositionRangeForRange):
47841        (WebCore::AccessibilityObject::lineRangeForPosition):
47842        * accessibility/AccessibilityObject.h:
47843        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
47844        (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
47845        (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
47846
478472014-03-31  Anders Carlsson  <andersca@apple.com>
47848
47849        Fix iOS build.
47850
47851        * page/ChromeClient.h:
47852        (WebCore::ChromeClient::updateViewportConstrainedLayers):
47853
478542014-03-31  Jer Noble  <jer.noble@apple.com>
47855
47856        [MSE][Mac] Support lease-renewal.
47857        https://bugs.webkit.org/show_bug.cgi?id=130919
47858
47859        Reviewed by Eric Carlson.
47860
47861        Trigger a new key request when receiving an update message containting "renew".
47862
47863        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
47864        (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest): Drive-by fix; generate a UTF-8
47865            based array.
47866        (WebCore::CDMSessionMediaSourceAVFObjC::update):
47867
478682014-03-31  Alexey Proskuryakov  <ap@apple.com>
47869
47870        Remove special handling of soft hyphens in search code
47871        https://bugs.webkit.org/show_bug.cgi?id=130940
47872
47873        Reviewed by Anders Carlsson.
47874
47875        ICU knows to ignore soft hyphens, so we don't need to replace them before searching.
47876
47877        Covered by existing tests.
47878
47879        * editing/TextIterator.cpp:
47880        (WebCore::foldQuoteMark):
47881        (WebCore::foldQuoteMarks):
47882        (WebCore::SearchBuffer::SearchBuffer):
47883        (WebCore::SearchBuffer::append):
47884        (WebCore::foldQuoteMarkOrSoftHyphen): Deleted.
47885        (WebCore::foldQuoteMarksAndSoftHyphens): Deleted.
47886
478872014-03-31  Alex Christensen  <achristensen@webkit.org>
47888
47889        Preparation for using Soup on Windows.
47890        https://bugs.webkit.org/show_bug.cgi?id=130615
47891
47892        Reviewed by Carlos Garcia Campos.
47893
47894        * WebCore.vcxproj/WebCore.vcxproj:
47895        * WebCore.vcxproj/WebCore.vcxproj.filters:
47896        Added Soup source files in WinCairo build.
47897        * loader/soup/CachedRawResourceSoup.cpp:
47898        * loader/soup/SubresourceLoaderSoup.cpp:
47899        * platform/soup/SharedBufferSoup.cpp:
47900        * platform/soup/URLSoup.cpp:
47901        * platform/network/NetworkStorageSessionStub.cpp:
47902        Only build if USE(SOUP) to prevent building when USE(CURL) is true.
47903        * platform/network/soup/ResourceHandleSoup.cpp:
47904        Only include unistd.h in non-Visual Studio builds.
47905        This would normally be done with a HAVE_UNISTD_H macro when compiling glib and Soup,
47906        but that would need to be left undefined for Visual Studio.
47907
479082014-03-31  Zan Dobersek  <zdobersek@igalia.com>
47909
47910        Unreviewed. Addressing reviewing comments for r166491 that I forgot
47911        to address before landing.
47912
47913        * html/FormController.cpp:
47914        (WebCore::SavedFormState::deserialize): No need to move the std::unique_ptr
47915        object on the way out.
47916        (WebCore::FormController::createSavedFormStateMap): FormKeyGenerator can be
47917        allocated on the stack.
47918        (WebCore::FormController::formStatesFromStateVector): Use auto.
47919
479202014-03-20  Carlos Garcia Campos  <cgarcia@igalia.com>
47921
47922        [GTK] Use GMainLoopSource for idle and timeout sources in WebCore
47923        https://bugs.webkit.org/show_bug.cgi?id=130078
47924
47925        Reviewed by Philippe Normand.
47926
47927        * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
47928        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
47929        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h:
47930        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
47931        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
47932        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
47933        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
47934        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
47935        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:
47936        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
47937        * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
47938        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
47939        * platform/gtk/GtkDragAndDropHelper.cpp:
47940        * platform/gtk/SharedTimerGtk.cpp:
47941
479422014-03-31  Andrei Bucur  <abucur@adobe.com>
47943
47944        Wrong layout while animating content in regions
47945        https://bugs.webkit.org/show_bug.cgi?id=125086
47946
47947        Reviewed by David Hyatt.
47948
47949        The region to layer and regions to layer mappings should be cleared when the region chain changes.
47950
47951        Test: fast/regions/layers/region-removed-during-animation.html
47952
47953        * rendering/RenderFlowThread.cpp:
47954        (WebCore::RenderFlowThread::invalidateRegions): Clear the two maps and flag them for recomputation.
47955        (WebCore::RenderFlowThread::cachedRegionForCompositedLayer): Assert that the returned region exists.
47956
479572014-03-31  Dániel Bátyai  <dbatyai.u-szeged@partner.samsung.com>
47958
47959        Remove hostThisRegister() and hostThisValue()
47960        https://bugs.webkit.org/show_bug.cgi?id=130895
47961
47962        Reviewed by Geoffrey Garen.
47963
47964        Removed hostThisRegister() and hostThisValue() and instead use thisArgumentOffset() and thisValue() respectively.
47965
47966        No new tests, no behavior changes.
47967
47968        * bindings/js/JSNavigatorCustom.cpp:
47969        (WebCore::JSNavigator::webkitGetUserMedia):
47970        * bindings/js/JSPluginElementFunctions.cpp:
47971        (WebCore::callPlugin):
47972        * bindings/scripts/CodeGeneratorJS.pm:
47973        (GenerateImplementation):
47974        * bindings/scripts/test/JS/JSFloat64Array.cpp:
47975        (WebCore::jsFloat64ArrayPrototypeFunctionFoo):
47976        (WebCore::jsFloat64ArrayPrototypeFunctionSet):
47977        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
47978        (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
47979        (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):
47980        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
47981        (WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):
47982        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
47983        (WebCore::jsTestEventTargetPrototypeFunctionItem):
47984        (WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
47985        (WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
47986        (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
47987        * bindings/scripts/test/JS/JSTestInterface.cpp:
47988        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod1):
47989        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
47990        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod3):
47991        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod1):
47992        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
47993        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod3):
47994        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
47995        (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
47996        * bindings/scripts/test/JS/JSTestObj.cpp:
47997        (WebCore::jsTestObjPrototypeFunctionVoidMethod):
47998        (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
47999        (WebCore::jsTestObjPrototypeFunctionByteMethod):
48000        (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
48001        (WebCore::jsTestObjPrototypeFunctionOctetMethod):
48002        (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
48003        (WebCore::jsTestObjPrototypeFunctionLongMethod):
48004        (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
48005        (WebCore::jsTestObjPrototypeFunctionObjMethod):
48006        (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
48007        (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
48008        (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
48009        (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
48010        (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
48011        (WebCore::jsTestObjPrototypeFunctionSerializedValue):
48012        (WebCore::jsTestObjPrototypeFunctionOptionsObject):
48013        (WebCore::jsTestObjPrototypeFunctionMethodWithException):
48014        (WebCore::jsTestObjPrototypeFunctionCustomMethod):
48015        (WebCore::jsTestObjPrototypeFunctionCustomMethodWithArgs):
48016        (WebCore::jsTestObjPrototypeFunctionAddEventListener):
48017        (WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
48018        (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoid):
48019        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
48020        (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoidException):
48021        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
48022        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContext):
48023        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptState):
48024        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
48025        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
48026        (WebCore::jsTestObjPrototypeFunctionWithScriptArgumentsAndCallStack):
48027        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
48028        (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
48029        (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
48030        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalString):
48031        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefined):
48032        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullString):
48033        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
48034        (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
48035        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
48036        (WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
48037        (WebCore::jsTestObjPrototypeFunctionConditionalMethod2):
48038        (WebCore::jsTestObjPrototypeFunctionConditionalMethod3):
48039        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
48040        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
48041        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
48042        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
48043        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
48044        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
48045        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
48046        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
48047        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod9):
48048        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
48049        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
48050        (WebCore::jsTestObjPrototypeFunctionClassMethodWithClamp):
48051        (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
48052        (WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
48053        (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
48054        (WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
48055        (WebCore::jsTestObjPrototypeFunctionConvert1):
48056        (WebCore::jsTestObjPrototypeFunctionConvert2):
48057        (WebCore::jsTestObjPrototypeFunctionConvert4):
48058        (WebCore::jsTestObjPrototypeFunctionConvert5):
48059        (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
48060        (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
48061        (WebCore::jsTestObjPrototypeFunctionOrange):
48062        (WebCore::jsTestObjPrototypeFunctionStrictFunction):
48063        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
48064        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithArray):
48065        (WebCore::jsTestObjPrototypeFunctionVariadicStringMethod):
48066        (WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethod):
48067        (WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
48068        (WebCore::jsTestObjPrototypeFunctionAny):
48069        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
48070        (WebCore::jsTestTypedefsPrototypeFunctionFunc):
48071        (WebCore::jsTestTypedefsPrototypeFunctionSetShadow):
48072        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
48073        (WebCore::jsTestTypedefsPrototypeFunctionNullableArrayArg):
48074        (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClamp):
48075        (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
48076        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction):
48077        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction2):
48078        (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
48079        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithException):
48080        * bridge/objc/objc_runtime.mm:
48081        (JSC::Bindings::callObjCFallbackObject):
48082        * bridge/runtime_method.cpp:
48083        (JSC::callRuntimeMethod):
48084
480852014-03-31  Zan Dobersek  <zdobersek@igalia.com>
48086
48087        Move the rest of Source/WebCore/html/ code to std::unique_ptr
48088        https://bugs.webkit.org/show_bug.cgi?id=129669
48089
48090        Reviewed by Anders Carlsson.
48091
48092        Replace the remaining uses of OwnPtr, PassOwnPtr under Source/WebCore/html/ with std::unique_ptr.
48093
48094        * html/FormController.cpp:
48095        (WebCore::SavedFormState::SavedFormState):
48096        (WebCore::SavedFormState::deserialize):
48097        (WebCore::FormController::createSavedFormStateMap):
48098        (WebCore::FormController::formElementsState):
48099        (WebCore::FormController::takeStateForFormElement):
48100        (WebCore::FormController::formStatesFromStateVector):
48101        * html/FormController.h:
48102        * html/HTMLAreaElement.cpp:
48103        (WebCore::HTMLAreaElement::mapMouseEvent):
48104        * html/HTMLAreaElement.h:
48105        * html/HTMLCanvasElement.cpp:
48106        (WebCore::HTMLCanvasElement::setSurfaceSize):
48107        (WebCore::HTMLCanvasElement::createImageBuffer):
48108        * html/HTMLCanvasElement.h:
48109        * html/HTMLCollection.h:
48110        * html/HTMLEmbedElement.cpp:
48111        (WebCore::HTMLEmbedElement::parseAttribute):
48112        * html/HTMLFormControlElement.cpp:
48113        (WebCore::HTMLFormControlElement::updateVisibleValidationMessage):
48114        * html/HTMLFormControlElement.h:
48115        * html/HTMLFormElement.cpp:
48116        (WebCore::HTMLFormElement::addToPastNamesMap):
48117        * html/HTMLFormElement.h:
48118        * html/HTMLInputElement.cpp:
48119        (WebCore::HTMLInputElement::imageLoader):
48120        (WebCore::HTMLInputElement::resetListAttributeTargetObserver):
48121        * html/HTMLInputElement.h:
48122        (WebCore::HTMLInputElement::hasImageLoader):
48123        * html/HTMLObjectElement.cpp:
48124        (WebCore::HTMLObjectElement::parseAttribute):
48125        * html/HTMLPlugInImageElement.cpp:
48126        (WebCore::HTMLPlugInImageElement::startLoadingImage):
48127        * html/HTMLPlugInImageElement.h:
48128        * html/HTMLVideoElement.cpp:
48129        (WebCore::HTMLVideoElement::didAttachRenderers):
48130        (WebCore::HTMLVideoElement::parseAttribute):
48131        * html/HTMLVideoElement.h:
48132        * html/ValidationMessage.cpp:
48133        (WebCore::ValidationMessage::ValidationMessage):
48134        (WebCore::ValidationMessage::setMessage):
48135        (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
48136        (WebCore::ValidationMessage::requestToHideMessage):
48137        * html/ValidationMessage.h:
48138
481392014-03-31  Maurice van der Pot  <griffon26@kfk4ever.com>
48140
48141        Fix mixed use of booleans in JPEGImageDecoder.cpp
48142        https://bugs.webkit.org/show_bug.cgi?id=122412
48143
48144        Reviewed by Darin Adler.
48145
48146        Trivial fix for compilation error; no new tests.
48147
48148        * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
48149        (WebCore::JPEGImageReader::decode):
48150        (WebCore::fill_input_buffer):
48151        Use TRUE/FALSE defined by libjpeg for libjpeg booleans
48152
481532014-03-23  Zan Dobersek  <zdobersek@igalia.com>
48154
48155        Move Source/WebCore/rendering/ code to std::unique_ptr
48156        https://bugs.webkit.org/show_bug.cgi?id=129664
48157
48158        Reviewed by Anders Carlsson.
48159
48160        Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/rendering/ with std::unique_ptr.
48161
48162        * platform/graphics/FloatPolygon.cpp:
48163        (WebCore::FloatPolygon::FloatPolygon):
48164        * platform/graphics/FloatPolygon.h:
48165        * rendering/ClipPathOperation.h:
48166        * rendering/FlowThreadController.cpp:
48167        (WebCore::FlowThreadController::ensureRenderFlowThreadWithName):
48168        * rendering/FlowThreadController.h:
48169        * rendering/HitTestLocation.h:
48170        * rendering/HitTestResult.cpp:
48171        (WebCore::HitTestResult::HitTestResult):
48172        (WebCore::HitTestResult::operator=):
48173        (WebCore::HitTestResult::rectBasedTestResult):
48174        (WebCore::HitTestResult::mutableRectBasedTestResult):
48175        * rendering/HitTestResult.h:
48176        * rendering/HitTestingTransformState.cpp:
48177        * rendering/ImageQualityController.h:
48178        * rendering/RenderBlock.cpp:
48179        (WebCore::removeBlockFromDescendantAndContainerMaps):
48180        (WebCore::RenderBlock::finishDelayUpdateScrollInfo):
48181        (WebCore::RenderBlock::addContinuationWithOutline):
48182        (WebCore::RenderBlock::paintContinuationOutlines):
48183        (WebCore::RenderBlock::insertIntoTrackedRendererMaps):
48184        (WebCore::RenderBlock::removeFromTrackedRendererMaps):
48185        (WebCore::RenderBlock::setComputedColumnCountAndWidth):
48186        * rendering/RenderBlock.h:
48187        * rendering/RenderBlockFlow.cpp:
48188        (WebCore::RenderBlockFlow::createFloatingObjects):
48189        * rendering/RenderBlockFlow.h:
48190        * rendering/RenderBoxRegionInfo.h:
48191        * rendering/RenderButton.cpp:
48192        (WebCore::RenderButton::styleDidChange):
48193        * rendering/RenderButton.h:
48194        * rendering/RenderCounter.cpp:
48195        (WebCore::makeCounterNode):
48196        * rendering/RenderFlowThread.cpp:
48197        (WebCore::RenderFlowThread::updateAllLayerToRegionMappings):
48198        (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
48199        * rendering/RenderFlowThread.h:
48200        * rendering/RenderGeometryMap.cpp:
48201        (WebCore::RenderGeometryMap::push):
48202        (WebCore::RenderGeometryMap::pushView):
48203        * rendering/RenderGeometryMap.h:
48204        * rendering/RenderGrid.cpp:
48205        (WebCore::RenderGrid::GridIterator::nextEmptyGridArea):
48206        (WebCore::RenderGrid::placeItemsOnGrid):
48207        (WebCore::RenderGrid::populateExplicitGridAndOrderIterator):
48208        (WebCore::RenderGrid::placeSpecifiedMajorAxisItemsOnGrid):
48209        (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid):
48210        (WebCore::RenderGrid::resolveGridPositionsFromStyle):
48211        (WebCore::RenderGrid::resolveGridPositionAgainstOppositePosition):
48212        (WebCore::RenderGrid::resolveNamedGridLinePositionAgainstOppositePosition):
48213        (WebCore::RenderGrid::resolveRowStartColumnStartNamedGridLinePositionAgainstOppositePosition):
48214        (WebCore::RenderGrid::resolveRowEndColumnEndNamedGridLinePositionAgainstOppositePosition):
48215        * rendering/RenderGrid.h:
48216        * rendering/RenderImageResource.h:
48217        * rendering/RenderLayer.cpp:
48218        (WebCore::RenderLayer::updateDescendantsAreContiguousInStackingOrder):
48219        (WebCore::RenderLayer::updateTransform):
48220        (WebCore::RenderLayer::setupFilters):
48221        (WebCore::RenderLayer::paintLayerContents):
48222        (WebCore::RenderLayer::paintChildLayerIntoColumns):
48223        (WebCore::RenderLayer::hitTestChildLayerColumns):
48224        (WebCore::RenderLayer::updateClipRects):
48225        (WebCore::RenderLayer::calculateClipRects):
48226        * rendering/RenderLayer.h:
48227        (WebCore::RenderLayer::clearZOrderLists):
48228        * rendering/RenderLayerCompositor.cpp:
48229        (WebCore::RenderLayerCompositor::notifyFlushBeforeDisplayRefresh):
48230        (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
48231        * rendering/RenderLayerCompositor.h:
48232        * rendering/RenderLayerFilterInfo.cpp:
48233        (WebCore::RenderLayer::FilterInfo::map):
48234        (WebCore::RenderLayer::FilterInfo::get):
48235        * rendering/RenderLayerFilterInfo.h:
48236        * rendering/RenderRegion.cpp:
48237        (WebCore::RenderRegion::setRenderBoxRegionInfo):
48238        (WebCore::RenderRegion::takeRenderBoxRegionInfo):
48239        * rendering/RenderRegion.h:
48240        * rendering/RenderTable.cpp:
48241        (WebCore::RenderTable::styleDidChange):
48242        * rendering/RenderTable.h:
48243        * rendering/RenderView.cpp:
48244        (WebCore::RenderView::selectionBounds):
48245        (WebCore::RenderView::setSelection):
48246        (WebCore::RenderView::compositor):
48247        (WebCore::RenderView::flowThreadController):
48248        (WebCore::RenderView::imageQualityController):
48249        * rendering/RenderView.h:
48250        * rendering/RootInlineBox.h:
48251        (WebCore::RootInlineBox::appendFloat):
48252        * rendering/TextAutosizer.h:
48253        * rendering/shapes/PolygonShape.cpp:
48254        (WebCore::computeShapePaddingBounds):
48255        (WebCore::computeShapeMarginBounds):
48256        * rendering/shapes/PolygonShape.h:
48257        (WebCore::PolygonShape::PolygonShape):
48258        * rendering/shapes/RasterShape.cpp:
48259        (WebCore::RasterShapeIntervals::computeShapeMarginIntervals):
48260        * rendering/shapes/RasterShape.h:
48261        (WebCore::RasterShape::RasterShape):
48262        * rendering/shapes/Shape.cpp:
48263        (WebCore::createInsetShape):
48264        (WebCore::createRectangleShape):
48265        (WebCore::createCircleShape):
48266        (WebCore::createEllipseShape):
48267        (WebCore::createPolygonShape):
48268        (WebCore::Shape::createShape):
48269        (WebCore::Shape::createRasterShape):
48270        (WebCore::Shape::createLayoutBoxShape):
48271        * rendering/shapes/Shape.h:
48272        * rendering/shapes/ShapeInfo.h:
48273        (WebCore::ShapeInfo::markShapeAsDirty):
48274        (WebCore::ShapeInfo::isShapeDirty):
48275        * rendering/shapes/ShapeInsideInfo.h:
48276        * rendering/style/ContentData.h:
48277        * rendering/style/CounterDirectives.cpp:
48278        (WebCore::clone):
48279        * rendering/style/CounterDirectives.h:
48280        * rendering/style/GridCoordinate.h:
48281        * rendering/style/RenderStyle.cpp:
48282        (WebCore::RenderStyle::addCachedPseudoStyle):
48283        (WebCore::RenderStyle::accessCounterDirectives):
48284        (WebCore::RenderStyle::accessAnimations):
48285        (WebCore::RenderStyle::accessTransitions):
48286        * rendering/style/RenderStyle.h:
48287        * rendering/style/StyleRareNonInheritedData.cpp:
48288        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
48289        * rendering/style/StyleRareNonInheritedData.h:
48290        * rendering/svg/RenderSVGResourceGradient.cpp:
48291        (WebCore::RenderSVGResourceGradient::applyResource):
48292        * rendering/svg/RenderSVGResourceGradient.h:
48293        * rendering/svg/RenderSVGResourcePattern.cpp:
48294        (WebCore::RenderSVGResourcePattern::buildPattern):
48295        * rendering/svg/RenderSVGResourcePattern.h:
48296        * rendering/svg/RenderSVGShape.cpp:
48297        (WebCore::RenderSVGShape::updateShapeFromElement):
48298        * rendering/svg/RenderSVGShape.h:
48299        * rendering/svg/SVGResources.cpp:
48300        (WebCore::SVGResources::setClipper):
48301        (WebCore::SVGResources::setFilter):
48302        (WebCore::SVGResources::setMarkerStart):
48303        (WebCore::SVGResources::setMarkerMid):
48304        (WebCore::SVGResources::setMarkerEnd):
48305        (WebCore::SVGResources::setMasker):
48306        (WebCore::SVGResources::setFill):
48307        (WebCore::SVGResources::setStroke):
48308        * rendering/svg/SVGResources.h:
48309        * rendering/svg/SVGResourcesCache.cpp:
48310        (WebCore::SVGResourcesCache::addResourcesFromRenderer):
48311        (WebCore::SVGResourcesCache::removeResourcesFromRenderer):
48312        * rendering/svg/SVGResourcesCache.h:
48313        * rendering/svg/SVGTextMetricsBuilder.cpp:
48314        (WebCore::SVGTextMetricsBuilder::initializeMeasurementWithTextRenderer):
48315        * rendering/svg/SVGTextMetricsBuilder.h:
48316
483172014-03-28  Sergio Villar Senin  <svillar@igalia.com>
48318
48319        Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in loader
48320        https://bugs.webkit.org/show_bug.cgi?id=130893
48321
48322        Reviewed by Darin Adler.
48323
48324        * loader/ImageLoader.cpp:
48325        (WebCore::beforeLoadEventSender):
48326        (WebCore::loadEventSender):
48327        (WebCore::errorEventSender):
48328        * loader/appcache/ApplicationCacheStorage.cpp:
48329        (WebCore::cacheStorage):
48330        * loader/appcache/ApplicationCacheStorage.h:
48331        * loader/archive/ArchiveFactory.cpp:
48332        (WebCore::archiveMIMETypes):
48333        * loader/cache/CachedImage.cpp:
48334        (WebCore::CachedImage::brokenImage):
48335        * loader/cache/CachedRawResource.cpp:
48336        (WebCore::shouldIgnoreHeaderForCacheReuse):
48337        * loader/cache/MemoryCache.cpp:
48338        (WebCore::dummyCachedImageClient):
48339
483402014-03-28  Sergio Villar Senin  <svillar@igalia.com>
48341
48342        Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in css
48343        https://bugs.webkit.org/show_bug.cgi?id=130409
48344
48345        Reviewed by Darin Adler.
48346
48347        * css/CSSComputedStyleDeclaration.cpp:
48348        (WebCore::logUnimplementedPropertyID):
48349        * css/CSSDefaultStyleSheets.cpp:
48350        (WebCore::screenEval):
48351        (WebCore::printEval):
48352        * css/CSSParser.cpp:
48353        (WebCore::strictCSSParserContext):
48354        * css/CSSPrimitiveValue.cpp:
48355        (WebCore::cssTextCache):
48356        * css/CSSProperty.cpp:
48357        (WebCore::borderDirections):
48358        * css/CSSStyleRule.cpp:
48359        (WebCore::selectorTextCache):
48360        * css/CSSValuePool.cpp:
48361        (WebCore::cssValuePool):
48362        * css/CSSValuePool.h:
48363        * css/DeprecatedStyleBuilder.cpp:
48364        (WebCore::ApplyPropertyPageSize::getPageSizeFromName):
48365        (WebCore::DeprecatedStyleBuilder::sharedStyleBuilder):
48366        * css/DeprecatedStyleBuilder.h:
48367
483682014-03-30  Xabier Rodriguez Calvar  <calvaris@igalia.com>
48369
48370        [GTK] [TextureMapper] Weird brightness with some videos with acceletared compositing
48371        https://bugs.webkit.org/show_bug.cgi?id=130665
48372
48373        Reviewed by Martin Robinson.
48374
48375        When we uploaded a video texture to the mapper we were not
48376        considering that some videos could be decoded into a format
48377        without alpha component. Now we check if the video has alpha and
48378        if it does not, we remove the alpha flag when retrieving the
48379        texture from the pool. For this, the method to get the texture
48380        from the pool was modified to receive the flags, that is mapped to
48381        have alpha by default in order not to break any other existing
48382        code.
48383
48384        Though we have a problem with AC in WTR and that makes it
48385        currently not testable, no new tests are needed because once this
48386        is fixed the current test set suffices to detect a possible
48387        regression in this.
48388
48389        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
48390        (WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): Check
48391        the video format and decide if the texture shall be pulled with
48392        alpha support or not.
48393        * platform/graphics/texmap/TextureMapper.cpp:
48394        (WebCore::TextureMapper::acquireTextureFromPool): Use the flags
48395        when resetting the texture.
48396        * platform/graphics/texmap/TextureMapper.h:
48397        (WebCore::BitmapTexture::Flag::None): Added with 0x00.
48398        (WebCore::TextureMapper::acquireTextureFromPool): Added flag
48399        parameter to set up the texture with the default for including
48400        alpha channel.
48401
484022014-03-30  Jinwoo Song  <jinwoo7.song@samsung.com>
48403
48404        Adopt range-based for loops to TextCheckerEnchant
48405        https://bugs.webkit.org/show_bug.cgi?id=130714
48406
48407        Reviewed by Darin Adler.
48408
48409        * platform/text/enchant/TextCheckerEnchant.cpp:
48410        (WebCore::TextCheckerEnchant::ignoreWord):
48411        (WebCore::TextCheckerEnchant::learnWord):
48412        (WebCore::TextCheckerEnchant::checkSpellingOfWord):
48413        (WebCore::TextCheckerEnchant::getGuessesForWord):
48414        (WebCore::TextCheckerEnchant::updateSpellCheckingLanguages):
48415        (WebCore::TextCheckerEnchant::loadedSpellCheckingLanguages):
48416        (WebCore::TextCheckerEnchant::availableSpellCheckingLanguages):
48417        (WebCore::TextCheckerEnchant::freeEnchantBrokerDictionaries):
48418
484192014-03-30  Benjamin Poulain  <benjamin@webkit.org>
48420
48421        Second attempt to fix 32bits build after r166465
48422
48423        * rendering/style/RenderStyle.h:
48424        The compiler probably complain about the return value, that makes more sense.
48425
484262014-03-30  Benjamin Poulain  <benjamin@webkit.org>
48427
48428        Attempt to fix 32bits build after r166465
48429
48430        * rendering/style/RenderStyle.h:
48431
484322014-03-30  Benjamin Poulain  <benjamin@webkit.org>
48433
48434        Make RenderStyle's non inherited flags more JSC friendly
48435        https://bugs.webkit.org/show_bug.cgi?id=130939
48436
48437        Reviewed by Andreas Kling.
48438
48439        Make RenderStyle::NonInheritedFlags accessible to the JIT:
48440        -Make the struct public to give access to the offset.
48441        -Move away from a bit field to static offsets we can use
48442         with the MacroAssembler.
48443        -Reorder the field to simplify bit access of the flags we need.
48444
48445        * css/DeprecatedStyleBuilder.cpp:
48446        (WebCore::ApplyPropertyVerticalAlign::createHandler):
48447        (WebCore::ApplyPropertyDisplay::applyInitialValue):
48448        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
48449        * css/StyleResolver.cpp:
48450        (WebCore::StyleResolver::adjustRenderStyle):
48451        * rendering/style/RenderStyle.cpp:
48452        (WebCore::RenderStyle::RenderStyle):
48453        (WebCore::RenderStyle::copyNonInheritedFrom):
48454        (WebCore::RenderStyle::hashForTextAutosizing):
48455        (WebCore::RenderStyle::equalForTextAutosizing):
48456        (WebCore::RenderStyle::changeRequiresLayout):
48457        * rendering/style/RenderStyle.h:
48458        (WebCore::RenderStyle::hasAnyPublicPseudoStyles):
48459        (WebCore::RenderStyle::hasPseudoStyle):
48460        (WebCore::RenderStyle::setHasPseudoStyle):
48461        * rendering/style/StyleMultiColData.cpp:
48462        (WebCore::StyleMultiColData::StyleMultiColData):
48463        * rendering/style/StyleRareNonInheritedData.cpp:
48464        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
48465
484662014-03-30  David Kilzer  <ddkilzer@apple.com>
48467
48468        [iOS] Fix build of HTMLConverter.mm after r166454
48469
48470        Fixes the following build failures:
48471
48472            WebCore/editing/cocoa/HTMLConverter.mm:1507:13: error: value of type 'WebCore::Element' is not contextually convertible to 'bool'
48473                    if (element)
48474                        ^~~~~~~
48475            WebCore/editing/cocoa/HTMLConverter.mm:1508:49: error: no matching function for call to 'core'
48476                        _caches->floatPropertyValueForNode(*core(element), CSSPropertyVerticalAlign, verticalAlign);
48477                                                            ^~~~
48478            In file included from WebCore/editing/cocoa/HTMLConverter.mm:41:
48479            In file included from WebCore/page/Frame.h:42:
48480            In file included from WebCore/editing/VisibleSelection.h:30:
48481            In file included from WebCore/editing/VisiblePosition.h:30:
48482            In file included from WebCore/dom/Position.h:31:
48483            WebCore/editing/TextAffinity.h:54:27: note: candidate function not viable: no known conversion from 'WebCore::Element' to 'NSSelectionAffinity' (aka '_NSSelectionAffinity') for 1st argument
48484            inline WebCore::EAffinity core(NSSelectionAffinity affinity)
48485                                      ^
48486            WebCore/editing/cocoa/HTMLConverter.mm:1509:81: error: reference to non-static member function must be called; did you mean to call it with no arguments?
48487                    attachment.get().bounds = CGRectMake(0, (verticalAlign / 100) * element.clientHeight, element.clientWidth, element.clientHeight);
48488                                                                                    ~~~~~~~~^~~~~~~~~~~~
48489                                                                                                        ()
48490            WebCore/editing/cocoa/HTMLConverter.mm:1509:103: error: reference to non-static member function must be called; did you mean to call it with no arguments?
48491                    attachment.get().bounds = CGRectMake(0, (verticalAlign / 100) * element.clientHeight, element.clientWidth, element.clientHeight);
48492                                                                                                          ~~~~~~~~^~~~~~~~~~~
48493                                                                                                                             ()
48494            WebCore/editing/cocoa/HTMLConverter.mm:1509:124: error: reference to non-static member function must be called; did you mean to call it with no arguments?
48495                    attachment.get().bounds = CGRectMake(0, (verticalAlign / 100) * element.clientHeight, element.clientWidth, element.clientHeight);
48496                                                                                                                               ~~~~~~~~^~~~~~~~~~~~
48497                                                                                                                                                   ()
48498            5 errors generated.
48499
48500        * editing/cocoa/HTMLConverter.mm:
48501        (HTMLConverter::_addAttachmentForElement):
48502
485032014-03-30  Andreas Kling  <akling@apple.com>
48504
48505        Make NodeList and HTMLCollection caching helpers use PassRef.
48506        <https://webkit.org/b/130943>
48507
48508        Tweak the helpers in NodeListsNodeData to return PassRef instead of
48509        PassRefPtr. This knocks 2 branches off of some pretty hot code on
48510        Dromaeo/dom-query.
48511
48512        Reviewed by Antti Koivisto.
48513
48514        * dom/ChildNodeList.h:
48515        * dom/ClassNodeList.h:
48516        * dom/NameNodeList.h:
48517        * dom/NodeRareData.h:
48518        (WebCore::NodeListsNodeData::ensureChildNodeList):
48519        (WebCore::NodeListsNodeData::ensureEmptyChildNodeList):
48520        (WebCore::NodeListsNodeData::addCacheWithAtomicName):
48521        (WebCore::NodeListsNodeData::addCacheWithName):
48522        (WebCore::NodeListsNodeData::addCacheWithQualifiedName):
48523        (WebCore::NodeListsNodeData::addCachedCollection):
48524        * dom/TagNodeList.h:
48525        * html/HTMLCollection.cpp:
48526        (WebCore::HTMLCollection::create):
48527        * html/HTMLCollection.h:
48528        * html/HTMLFormControlsCollection.cpp:
48529        (WebCore::HTMLFormControlsCollection::create):
48530        * html/HTMLFormControlsCollection.h:
48531        * html/RadioNodeList.h:
48532
485332014-03-29  Antti Koivisto  <antti@apple.com>
48534
48535        LiveNodeLists should use ElementDescendantIterator
48536        https://bugs.webkit.org/show_bug.cgi?id=130931
48537
48538        Reviewed by Andreas Kling.
48539        
48540        Make LiveNodeList traversal use the common DOM tree iterator.
48541
48542        * dom/ChildNodeList.cpp:
48543        (WebCore::ChildNodeList::ChildNodeList):
48544        (WebCore::ChildNodeList::collectionBegin):
48545        (WebCore::ChildNodeList::collectionTraverseForward):
48546        (WebCore::ChildNodeList::collectionTraverseBackward):
48547        (WebCore::ChildNodeList::invalidateCache):
48548        (WebCore::ChildNodeList::collectionFirst): Deleted.
48549        
48550            Iterator for ChildNodeList is still just Node*.
48551
48552        * dom/ChildNodeList.h:
48553        * dom/CollectionIndexCache.h:
48554        (WebCore::CollectionIndexCache::hasValidCache):
48555        (WebCore::Iterator>::CollectionIndexCache):
48556        (WebCore::Iterator>::nodeCount):
48557        (WebCore::Iterator>::computeNodeCountUpdatingListCache):
48558        (WebCore::Iterator>::traverseBackwardTo):
48559        (WebCore::Iterator>::traverseForwardTo):
48560        (WebCore::Iterator>::nodeAt):
48561        (WebCore::Iterator>::invalidate):
48562        
48563            Make CollectionIndexCache iterator based instead of using NodeType*. The iterator type may
48564            still be a Node* though.
48565
48566        (WebCore::NodeType>::CollectionIndexCache): Deleted.
48567        (WebCore::NodeType>::nodeCount): Deleted.
48568        (WebCore::NodeType>::computeNodeCountUpdatingListCache): Deleted.
48569        (WebCore::NodeType>::nodeBeforeCached): Deleted.
48570        (WebCore::NodeType>::nodeAfterCached): Deleted.
48571        (WebCore::NodeType>::nodeAt): Deleted.
48572        (WebCore::NodeType>::invalidate): Deleted.
48573        * dom/ElementDescendantIterator.h:
48574        (WebCore::ElementDescendantIterator::operator--):
48575        
48576            Add backward iteration support.
48577
48578        (WebCore::ElementDescendantIteratorAdapter::last):
48579        (WebCore::ElementDescendantConstIteratorAdapter::last):
48580        
48581            Add a way to get the last item.
48582            Provide std::iterator_traits so we can extract the type.
48583
48584        * dom/LiveNodeList.h:
48585        (WebCore::CachedLiveNodeList::collectionEnd):
48586        (WebCore::CachedLiveNodeList<NodeListType>::CachedLiveNodeList):
48587        (WebCore::CachedLiveNodeList<NodeListType>::~CachedLiveNodeList):
48588        (WebCore::CachedLiveNodeList<NodeListType>::collectionBegin):
48589        (WebCore::CachedLiveNodeList<NodeListType>::collectionLast):
48590        (WebCore::CachedLiveNodeList<NodeListType>::collectionTraverseForward):
48591        (WebCore::CachedLiveNodeList<NodeListType>::collectionTraverseBackward):
48592        (WebCore::CachedLiveNodeList<NodeListType>::invalidateCache):
48593        (WebCore::CachedLiveNodeList<NodeListType>::collectionFirst): Deleted.
48594        
48595            Make LiveNodeList traversal use ElementDescendantIterator.
48596
48597        (WebCore::nextMatchingElement): Deleted.
48598        (WebCore::previousMatchingElement): Deleted.
48599        * html/HTMLCollection.cpp:
48600        (WebCore::HTMLCollection::HTMLCollection):
48601        (WebCore::HTMLCollection::~HTMLCollection):
48602        (WebCore::HTMLCollection::collectionBegin):
48603        (WebCore::HTMLCollection::collectionTraverseForward):
48604        (WebCore::HTMLCollection::collectionTraverseBackward):
48605        (WebCore::HTMLCollection::invalidateCache):
48606        (WebCore::HTMLCollection::collectionFirst): Deleted.
48607        * html/HTMLCollection.h:
48608        (WebCore::HTMLCollection::collectionEnd):
48609        
48610            HTMLCollection still uses Element* as iterator for now.
48611
486122014-03-29  Commit Queue  <commit-queue@webkit.org>
48613
48614        Unreviewed, rolling out r166434.
48615        https://bugs.webkit.org/show_bug.cgi?id=130938
48616
48617        Caused crashes and other failures on cache tests (Requested by
48618        ap on #webkit).
48619
48620        Reverted changeset:
48621
48622        "Web Replay: add page-level setting to bypass the MemoryCache"
48623        https://bugs.webkit.org/show_bug.cgi?id=130728
48624        http://trac.webkit.org/changeset/166434
48625
486262014-03-29  David Kilzer  <ddkilzer@apple.com>
48627
48628        Preserve selection end positions in directionOfSelection
48629        <http://webkit.org/b/104813>
48630        <rdar://problem/13666417>
48631
48632        Reviewed by Brent Fulgham.
48633
48634        Merged from Blink (patch by kenrb@chromium.org):
48635        https://src.chromium.org/viewvc/blink?revision=150621&view=revision
48636        http://crbug.com/164263
48637
48638            VisibleSelection::visibleStart() and VisibleSelection::visibleEnd()
48639            can both cause layouts, which has the potential to invalidate any
48640            rendertree-based objects. This was causing a problem in
48641            FrameSelection::directionOfSelection(), where a reference to a
48642            lineBox was being held across a call to visibleEnd().
48643
48644            This patch ensures that the any layout is completed before linebox
48645            references are retrieved.
48646
48647        Test: editing/selection/layout-during-move-selection-crash.html
48648
48649        * editing/FrameSelection.cpp:
48650        (WebCore::FrameSelection::directionOfSelection):
48651
486522014-03-29  Zalan Bujtas  <zalan@apple.com>
48653
48654        Subpixel rendering: Simple line layout should not round to integral position while painting.
48655        https://bugs.webkit.org/show_bug.cgi?id=130934
48656
48657        Reviewed by Simon Fraser.
48658
48659        Remove rounding to integral position. When RenderLayer is injected and hides subpixel positions,
48660        integral rounding produces different paint position.
48661
48662        Test: fast/flexbox/hidpi-simple-line-layout-with-flexbox-and-transition.html
48663
48664        * rendering/SimpleLineLayoutFunctions.cpp:
48665        (WebCore::SimpleLineLayout::paintFlow):
48666
486672014-03-29  Zalan Bujtas  <zalan@apple.com>
48668
48669        Subpixel rendering: Make GraphicsContext::drawImageBuffer* functions float based.
48670        https://bugs.webkit.org/show_bug.cgi?id=130932
48671
48672        Reviewed by Simon Fraser.
48673        
48674        This is in preparation to support device pixel based filter painting.
48675        Filter calculation is still integral based.
48676
48677        No change in behavior.
48678
48679        * platform/graphics/GraphicsContext.cpp:
48680        (WebCore::GraphicsContext::drawImageBuffer):
48681        * platform/graphics/GraphicsContext.h:
48682        * platform/graphics/filters/FilterEffect.cpp: This will eventually be fully float based.
48683        Right now, this IntRect->FloatRect change is only to ensure that we can call 
48684        the float based drawImageBuffer(). 
48685        (WebCore::FilterEffect::drawingRegionOfInputImage):
48686        * platform/graphics/filters/FilterEffect.h:
48687
486882014-03-27  Sam Weinig  <sam@webkit.org>
48689
48690        Convert yet more of HTMLConverter to C++
48691        https://bugs.webkit.org/show_bug.cgi?id=130850
48692
48693        Reviewed by Anders Carlsson.
48694
48695        * editing/cocoa/HTMLConverter.mm:
48696        (HTMLConverterCaches::isAncestorsOfStartToBeConverted):
48697        (HTMLConverter::HTMLConverter):
48698        (HTMLConverter::~HTMLConverter):
48699        (HTMLConverter::convert):
48700        (HTMLConverter::computedAttributesForElement):
48701        (HTMLConverter::attributesForElement):
48702        (HTMLConverter::_newParagraphForElement):
48703        (HTMLConverter::_newLineForElement):
48704        (HTMLConverter::_newTabForElement):
48705        (HTMLConverter::_addAttachmentForElement):
48706        (HTMLConverter::_addQuoteForElement):
48707        (HTMLConverter::_addValue):
48708        (HTMLConverter::_processHeadElement):
48709        (HTMLConverter::_enterElement):
48710        (HTMLConverter::_addTableCellForElement):
48711        (HTMLConverter::_processElement):
48712        (HTMLConverter::_addMarkersToList):
48713        (HTMLConverter::_exitElement):
48714        (HTMLConverter::_processText):
48715        (HTMLConverter::_traverseNode):
48716        (HTMLConverter::_traverseFooterNode):
48717        (WebCore::attributedStringFromRange):
48718        (_childrenForNode): Deleted.
48719        (HTMLConverter::_computedAttributesForElement): Deleted.
48720        (HTMLConverter::_attributesForElement): Deleted.
48721        (HTMLConverter::_loadFromDOMRange): Deleted.
48722
487232014-03-28  Csaba Osztrogonác  <ossy@webkit.org>
48724
48725        Unreviewed buildfix after r166441 and r166443.
48726
48727        * CMakeLists.txt: Add platform/audio/AudioHardwareListener.cpp.
48728
487292014-03-28  Javier Fernandez  <jfernandez@igalia.com>
48730
48731        [CSS Grid Layout] The 'auto' height must be adapted to the item's margin.
48732        https://bugs.webkit.org/show_bug.cgi?id=130920
48733
48734        Reviewed by Darin Adler.
48735
48736        Adding the grid-item's marginLogicalHeight to the used breadth when computing
48737        content based grid-track sizes.
48738
48739        Test: fast/css-grid-layout/grid-item-margin-auto-columns-rows.html
48740
48741        * rendering/RenderGrid.cpp:
48742        (WebCore::RenderGrid::logicalContentHeightForChild):
48743
487442014-03-28  James Craig  <jcraig@apple.com>
48745
48746        Web Inspector: AXI: support for live regions
48747        https://bugs.webkit.org/show_bug.cgi?id=130725
48748
48749        Reviewed by Timothy Hatcher.
48750
48751        Tests: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
48752               inspector-protocol/dom/getAccessibilityPropertiesForNode_liveRegion.html
48753
48754        Initial support for @aria-live, @aria-atomic, and @aria-busy.
48755
48756        * inspector/InspectorDOMAgent.cpp:
48757        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
48758        * inspector/protocol/DOM.json:
48759
487602014-03-28  Darin Adler  <darin@apple.com>
48761
48762        Fix recently-introduced off-by-one error in centerTruncateToBuffer
48763        https://bugs.webkit.org/show_bug.cgi?id=130889
48764        <rdar://problem/16408694>
48765
48766        Reviewed by Alexey Proskuryakov.
48767
48768        * platform/graphics/StringTruncator.cpp:
48769        (WebCore::centerTruncateToBuffer): Simplified expression that computes truncatedLength.
48770        Removed incorrect "+ 1" from computation of where to write characters.
48771
487722014-03-28  Benjamin Poulain  <bpoulain@apple.com>
48773
48774        Update the code related to SelectorPseudoTypeMap to reflect its new purpose
48775        https://bugs.webkit.org/show_bug.cgi?id=130620
48776
48777        Reviewed by Andreas Kling.
48778
48779        Since r166094, SelectorPseudoTypeMap only contains PseudoClass instances and the 4 compatibility PseudoElement.
48780
48781        This patch rename SelectorPseudoTypeMap to SelectorPseudoClassAndCompatibilityElementMap and update the parsing
48782        to split PseudoClass and PseudoElement.
48783
48784        * CMakeLists.txt:
48785        * DerivedSources.make:
48786        * WebCore.xcodeproj/project.pbxproj:
48787        * css/CSSGrammar.y.in:
48788        * css/CSSParserValues.cpp:
48789        (WebCore::CSSParserSelector::parsePseudoClassAndCompatibilityElementSelector):
48790        (WebCore::CSSParserSelector::setPseudoClassValue):
48791        * css/CSSParserValues.h:
48792        * css/CSSSelector.cpp:
48793        (WebCore::appendPseudoClassFunctionTail):
48794        (WebCore::CSSSelector::selectorText):
48795        * css/SelectorPseudoClassAndCompatibilityElementMap.in: Renamed from Source/WebCore/css/SelectorPseudoTypeMap.in.
48796        * css/SelectorPseudoTypeMap.h:
48797        * css/makeSelectorPseudoClassAndCompatibilityElementMap.py: Renamed from Source/WebCore/css/makeSelectorPseudoTypeMap.py.
48798        (enumerablePseudoType):
48799        (expand_ifdef_condition):
48800
488012014-03-28  Stephanie Lewis  <slewis@apple.com>
48802
48803        Unreviewed build fix.
48804
48805        * platform/audio/AudioHardwareListener.cpp:
48806        (WebCore::AudioHardwareListener::create):
48807        (WebCore::AudioHardwareListener::audioHardwareListenerIsSupported): Deleted.
48808        * platform/audio/AudioHardwareListener.h:
48809
488102014-03-28  Lukasz Bialek  <l.bialek@samsung.com>
48811
48812        Refactor cut and copy functions as suggested in FIXME line
48813        https://bugs.webkit.org/show_bug.cgi?id=129867
48814
48815        Reviewed by Darin Adler.
48816
48817        Cut and Copy functions in Editor.cpp use lots of common code.
48818        Those functions are merged into one to share code, several
48819        additional conditions are added to preserve Cut and Copy
48820        functionality.
48821
48822        * editing/Editor.cpp:
48823        (WebCore::Editor::cut):
48824        (WebCore::Editor::copy):
48825        (WebCore::Editor::performCutOrCopy):
48826        * editing/Editor.h:
48827
488282014-03-28  Stephanie Lewis  <slewis@apple.com>
48829
48830        Rename pluginDidEvaluate to better represent when it’s called.
48831        Part of <rdar://problem/16061257> PluginProcess should AppNap when no plugins on active tab.
48832
48833        Reviewed by Anders Carlsson.
48834
48835        No new test because it’s just a name change.
48836
48837        * page/PageThrottler.h:
48838        (WebCore::PageThrottler::pluginDidEvaluateWhileAudioIsPlaying):
48839
488402014-03-28  Stephanie Lewis  <slewis@apple.com>
48841
48842        Notification handler for telling if audio hardware is active.
48843        https://bugs.webkit.org/show_bug.cgi?id=130743
48844
48845        Reviewed by Jer Noble.
48846
48847        Not web-exposed so no easy way to test.
48848
48849        Listen to CoreAudio to see if audio hardware is active in the current process.
48850
48851        * WebCore.exp.in:
48852        * WebCore.xcodeproj/project.pbxproj:
48853        * platform/audio/AudioHardwareListener.cpp: Added.
48854        (WebCore::AudioHardwareListener::create):
48855        (WebCore::AudioHardwareListener::AudioHardwareListener):
48856        * platform/audio/AudioHardwareListener.h: Added.
48857        (WebCore::AudioHardwareListener::Client::~Client):
48858        (WebCore::AudioHardwareListener::~AudioHardwareListener):
48859        (WebCore::AudioHardwareListener::isHardwareActive):
48860        * platform/audio/mac/AudioHardwareListenerMac.cpp: Added.
48861        (WebCore::isAudioHardwareProcessRunning):
48862        (WebCore::AudioHardwareListener::create):
48863        (WebCore::AudioHardwareListenerMac::create):
48864        (WebCore::AudioHardwareListenerMac::AudioHardwareListenerMac):
48865        (WebCore::AudioHardwareListenerMac::~AudioHardwareListenerMac):
48866        (WebCore::AudioHardwareListenerMac::setHardwareActive):
48867        * platform/audio/mac/AudioHardwareListenerMac.h: Added.
48868
488692014-03-28  James Craig  <jcraig@apple.com>
48870
48871        Web Inspector: AXI: expose what elements get generic "clickable" status
48872        https://bugs.webkit.org/show_bug.cgi?id=130721
48873
48874        Reviewed by Timothy Hatcher.
48875
48876        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html:
48877        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode_mouseEventNodeId.html
48878
48879        Expose ancestor element link to "Click Listener" or generic "Clickable: Yes" if current node has mouse handler.
48880
48881        Update AccessibilityNodeObject::mouseButtonListener() to optionally return body element if 
48882            requested so that Web Inspector can display body event delegate handlers.
48883
48884        * accessibility/AccessibilityNodeObject.cpp:
48885        (WebCore::AccessibilityNodeObject::mouseButtonListener):
48886        * accessibility/AccessibilityNodeObject.h:
48887        * inspector/InspectorDOMAgent.cpp:
48888        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
48889        * inspector/protocol/DOM.json:
48890
488912014-03-28  Joseph Pecoraro  <pecoraro@apple.com>
48892
48893        Web Inspector: Really drop all locks in nested run loop on iOS if WebThread is enabled
48894        https://bugs.webkit.org/show_bug.cgi?id=130912
48895
48896        Reviewed by Geoffrey Garen.
48897
48898        Previously we were calling DropAllLocks inside of a single line if statement,
48899        so the JSLock was getting reaquired very quickly. We really want to DropAllLocks
48900        for the duration of running the nested run loop on iOS if there is a WebThread.
48901
48902        * bindings/js/PageScriptDebugServer.h:
48903        * bindings/js/PageScriptDebugServer.cpp:
48904        (WebCore::PageScriptDebugServer::runEventLoopWhilePaused):
48905        (WebCore::PageScriptDebugServer::runEventLoopWhilePausedInternal):
48906
489072014-03-28  Brent Fulgham  <bfulgham@apple.com>
48908
48909        [Win] Enable Media Track testing features on Windows
48910        https://bugs.webkit.org/show_bug.cgi?id=130851
48911
48912        Reviewed by Eric Carlson.
48913
48914        * testing/Internals.cpp:
48915        (WebCore::Internals::resetToConsistentState): Execute code on Windows as well.
48916        (WebCore::Internals::Internals): Ditto.
48917        (WebCore::Internals::captionsStyleSheetOverride): Ditto.
48918        (WebCore::Internals::setCaptionsStyleSheetOverride): Ditto.
48919        (WebCore::Internals::setPrimaryAudioTrackLanguageOverride): Ditto.
48920        (WebCore::Internals::setCaptionDisplayMode): Ditto.
48921
489222014-03-28  Brian Burg  <bburg@apple.com>
48923
48924        Web Replay: add page-level setting to bypass the MemoryCache
48925        https://bugs.webkit.org/show_bug.cgi?id=130728
48926
48927        Reviewed by Timothy Hatcher.
48928
48929        When replaying a specific Page we don't want to store its cached resources in the
48930        MemoryCache. This patch adds a page setting to prevent the page's resources from
48931        being saved in the MemoryCache.
48932
48933        If Settings::usesMemoryCache() is false, page resources are given the special
48934        SessionID bypassCacheSessionID(). The cached resource loader and memory cache
48935        act as if the memory cache is disabled if the resource has this special session id.
48936
48937        Hook up ReplayController to override the memory cache setting during capture/replay.
48938
48939        Test: http/tests/cache/bypass-memory-cache-after-reload.html
48940
48941        * loader/cache/CachedResourceLoader.cpp:
48942        (WebCore::CachedResourceLoader::requestResource):
48943        (WebCore::CachedResourceLoader::revalidateResource):
48944        * loader/cache/MemoryCache.cpp:
48945        (WebCore::MemoryCache::add):
48946        * page/Page.cpp:
48947        (WebCore::Page::sessionID):
48948        * page/SessionID.h:
48949        (WebCore::SessionID::bypassCacheSessionID):
48950        * page/Settings.cpp:
48951        (WebCore::Settings::Settings):
48952        * page/Settings.h:
48953        (WebCore::Settings::setUsesMemoryCache):
48954        (WebCore::Settings::usesMemoryCache):
48955        * replay/ReplayController.cpp:
48956        (WebCore::ReplayController::setForceDeterministicSettings):
48957        * replay/ReplayController.h:
48958        * testing/InternalSettings.cpp:
48959        (WebCore::InternalSettings::Backup::Backup):
48960        (WebCore::InternalSettings::Backup::restoreTo):
48961        (WebCore::InternalSettings::setUsesMemoryCache):
48962        * testing/InternalSettings.h:
48963        * testing/InternalSettings.idl:
48964
489652014-03-28  Radu Stavila  <stavila@adobe.com>
48966
48967        In some situations, partial layouts of floating elements produce incorrect results.
48968        https://bugs.webkit.org/show_bug.cgi?id=122668
48969
48970        Reviewed by David Hyatt.
48971
48972        When performing partial layout of float elements and checking if other float
48973        elements are encountered, incorrect results were obtained by not checking
48974        the size of the existing floats vector.
48975
48976        Test: fast/block/float/floats-in-clean-line-crash.html
48977
48978        * rendering/RenderBlockLineLayout.cpp:
48979        (WebCore::RenderBlockFlow::checkFloatsInCleanLine):
48980
489812014-03-28  Beth Dakin  <bdakin@apple.com>
48982
48983        Build fix.
48984
48985        * rendering/RenderTheme.cpp:
48986        (WebCore::RenderTheme::paint):
48987
489882014-03-28  Jer Noble  <jer.noble@apple.com>
48989
48990        [MSE] Implement support for SourceBuffer.remove()
48991        https://bugs.webkit.org/show_bug.cgi?id=121562
48992
48993        Reviewed by Eric Carlson.
48994
48995        Test: media/media-source/media-source-remove.html
48996
48997        Add support for SourceBuffer.remove().
48998
48999        * Modules/mediasource/SourceBuffer.cpp:
49000        (WebCore::SourceBuffer::SourceBuffer): Initialize new member variables.
49001        (WebCore::SourceBuffer::setTimestampOffset): Update comments to match spec.
49002        (WebCore::SourceBuffer::remove): Added; start removeTimer.
49003        (WebCore::SourceBuffer::abortIfUpdating): Cancel removeTimer.
49004        (WebCore::SourceBuffer::removedFromMediaSource): Call abortIfUpdating().
49005        (WebCore::SourceBuffer::stop): Cancel removeTimer.
49006        (WebCore::SourceBuffer::removeCodedFrames): Added.
49007        (WebCore::SourceBuffer::removeTimerFired): Added.
49008        * Modules/mediasource/SourceBuffer.h:
49009        * Modules/mediasource/SourceBuffer.idl:
49010
490112014-03-27  Dean Jackson  <dino@apple.com>
49012
49013        Support form controls that may need incremental redraw
49014        https://bugs.webkit.org/show_bug.cgi?id=130736
49015
49016        Reviewed by Beth Dakin.
49017
49018        There are some form controls that change appearance
49019        over time. Expand the ControlStates so that it can
49020        hold a little more information, including a reference
49021        to the native form control. This way the Theme implementation
49022        can repaint the existing native control if necessary. At
49023        least ThemeMac was reusing a single control for painting
49024        all instances before this change.
49025
49026        Since ControlStates is now a class, pass it around by
49027        reference.
49028
49029        The other major change is keeping a timer to trigger a
49030        repaint in RenderBox, which happens if Theme/RenderTheme
49031        update the ControlState to request one.
49032
49033        * WebCore.xcodeproj/project.pbxproj: Add ControlStates.h.
49034        * WebCore.vcxproj/WebCore.vcxproj: Ditto.
49035        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
49036        * dom/Element.cpp:
49037        (WebCore::Element::setActive): States now within ControlStates.
49038        (WebCore::Element::setHovered): Ditto.
49039        * editing/FrameSelection.cpp:
49040        (WebCore::FrameSelection::focusedOrActiveStateChanged): Ditto.
49041        * html/HTMLFormControlElement.cpp:
49042        (WebCore::HTMLFormControlElement::disabledStateChanged): Ditto.
49043        (WebCore::HTMLFormControlElement::readOnlyAttributeChanged): Ditto.
49044        * html/HTMLInputElement.cpp:
49045        (WebCore::HTMLInputElement::setChecked): Ditto.
49046        (WebCore::HTMLInputElement::setIndeterminate): Ditto.
49047        * html/HTMLOptionElement.cpp:
49048        (WebCore::HTMLOptionElement::parseAttribute): Ditto.
49049        * platform/ControlStates.h: New file. Copied the old ControlStates enum,
49050        and added accessors to hold whether or not the state is dirty, and
49051        a reference to a platform control if necessary.
49052        * platform/Theme.h:
49053        (WebCore::Theme::selectionColor): Pass ControlStates pointer.
49054        (WebCore::Theme::paint): Ditto.
49055        (WebCore::Theme::inflateControlPaintRect): Ditto.
49056        * platform/ThemeTypes.h: Remove ControlStates enum.
49057        * platform/efl/RenderThemeEfl.cpp:
49058        (WebCore::RenderThemeEfl::applyEdjeStateFromForm): Pass ControlStates pointer.
49059        (WebCore::RenderThemeEfl::paintThemePart): Ditto.
49060        * platform/efl/RenderThemeEfl.h: Ditto.
49061        * platform/mac/ThemeMac.h: Ditto.
49062        * platform/mac/ThemeMac.mm:
49063        (-[WebCoreThemeView addSubview:]): New method to make sure we don't add CALayer backed
49064        views to the NSView we're using for rendering.
49065        (WebCore::updateStates): Use the private animated setters if necessary.
49066        (WebCore::convertControlStatesToThemeDrawState): Namespacing.
49067        (WebCore::configureCheckbox): Pass ControlStates pointer.
49068        (WebCore::createCheckboxCell): New helper since we're creating non-static cells.
49069        (WebCore::sharedCheckboxCell): The old static provider, renamed.
49070        (WebCore::paintCheckbox): Check if this paint was triggered by a state change
49071        or an animation. Update the ControlStates if we need to be repainted.
49072        (WebCore::radio): Parameter is now ControlStates*.
49073        (WebCore::paintRadio): Ditto.
49074        (WebCore::setUpButtonCell): Ditto.
49075        (WebCore::button): Ditto.
49076        (WebCore::paintButton): Ditto.
49077        (WebCore::paintStepper): Ditto.
49078        (WebCore::ThemeMac::ensuredView): Ditto.
49079        (WebCore::ThemeMac::inflateControlPaintRect): Ditto.
49080        (WebCore::ThemeMac::paint): Ditto.
49081        (WebCore::checkbox): Deleted.
49082        * rendering/RenderBox.cpp:
49083        (WebCore::RenderBox::RenderBox): Initialize timer.
49084        (WebCore::RenderBox::~RenderBox): Stop any pending timers and delete the ControlState if necessary.
49085        (WebCore::RenderBox::paintBoxDecorations): Create a ControlStates if needed. Paint, and start the repaint
49086        timer if the ControlStates say we should.
49087        (WebCore::RenderBox::repaintTimerFired): Call repaint when the timer fires.
49088        * rendering/RenderBox.h: Add a timer for repainting.
49089        * rendering/RenderElement.cpp:
49090        (WebCore::controlStatesRendererMap): A static HashMap that associates renderers with ControlStates.
49091        (WebCore::RenderElement::hasControlStatesForRenderer):
49092        (WebCore::RenderElement::controlStatesForRenderer):
49093        (WebCore::RenderElement::removeControlStatesForRenderer):
49094        (WebCore::RenderElement::addControlStatesForRenderer):
49095        * rendering/RenderElement.h:
49096        * rendering/RenderTheme.cpp:
49097        (WebCore::RenderTheme::paint): Use a pointer to ControlStates.
49098        (WebCore::RenderTheme::adjustRepaintRect): Ditto.
49099        (WebCore::RenderTheme::stateChanged): Ditto.
49100        (WebCore::RenderTheme::updateControlStatesForRenderer): New method that just updates the states part of ControlStates.
49101        (WebCore::RenderTheme::extractControlStatesForRenderer): New method that calculates the state.
49102        (WebCore::RenderTheme::controlStatesForRenderer): Deleted.
49103        * rendering/RenderTheme.h:
49104        * rendering/RenderThemeMac.mm:
49105        (WebCore::RenderThemeMac::documentViewFor): Use a ControlStates pointer.
49106
491072014-03-28  Myles C. Maxfield  <mmaxfield@apple.com>
49108
49109        Clear SVGInlineTextBox fragments when the text changes.
49110        https://bugs.webkit.org/show_bug.cgi?id=130879
49111
49112        Reviewed by Darin Adler.
49113
49114        Ported from Blink: https://src.chromium.org/viewvc/blink?revision=150456&view=revision
49115
49116        This patch modifies SVGInlineTextBox::dirtyLineBoxes to clear all
49117        following text boxes when invoked. Typically this method is called
49118        when the underlying text string changes, and that change needs to
49119        be propagated to all the boxes that use the text beyond the point
49120        where the text is first modified.
49121        
49122        Also cleans up final function keywords for SVGRootInlineBox.
49123
49124        Test: svg/custom/unicode-in-tspan-multi-svg-crash.html
49125
49126        * rendering/InlineTextBox.h: Added (non-recursive) dirtyOwnLineBoxes() function
49127        (WebCore::InlineTextBox::dirtyOwnLineBoxes): Calls dirtyLineBoxes()
49128        * rendering/svg/SVGInlineTextBox.h: Added (non-recursive) dirtyOwnLineBoxes() function
49129        (WebCore::SVGInlineTextBox::dirtyOwnLineBoxes):
49130        * rendering/svg/SVGInlineTextBox.cpp:
49131        (WebCore::SVGInlineTextBox::dirtyOwnLineBoxes): Non-recursive part of dirtyLineBoxes()
49132        (WebCore::SVGInlineTextBox::dirtyLineBoxes): Calls dirtyOwnLineBoxes() in a loop
49133        * rendering/svg/SVGRootInlineBox.h:
49134
491352014-03-28  Andreas Kling  <akling@apple.com>
49136
49137        Rebaseline bindings tests.
49138
491392014-03-28  Michael Saboff  <msaboff@apple.com>
49140
49141        Unreviewed, rolling r166248 back in.
49142
49143        Turns out r166070 didn't cause a 2% performance loss in page load times
49144
49145        Reverted changeset:
49146
49147        Unreviewed, rolling out r166126.
49148        Rollout r166126 in prepartion to roll out prerequisite r166070
49149
491502014-03-26  Antonio Gomes  <a1.gomes@sisa.samsung.com>
49151
49152        [Bindings] constants are always typed to 'int'
49153        https://bugs.webkit.org/show_bug.cgi?id=130775
49154
49155        Reviewed by Darin Adler.
49156
49157        Patch fixes a bug where all constant getter generated
49158        methods were returning 'integer' values due to static_cast.
49159
49160        Compilers should be smarth enough to properly infer which
49161        jsNumber class construtor to call given a literal value.
49162
49163        Patch also fixes a bug where values whose representation
49164        is bigger an integer maximum were overflowing. For instance,
49165        NodeFilter.SHOW_ALL (0xFFFFFFFF).
49166
49167        Tests:
49168        Binding tests updated.
49169        Rebaselined fast/dom/constants.html
49170
49171        * bindings/scripts/CodeGeneratorJS.pm:
49172        (GenerateImplementation):
49173        * bindings/scripts/test/JS/JSTestInterface.cpp:
49174        (WebCore::jsTestInterfaceIMPLEMENTSCONSTANT1):
49175        (WebCore::jsTestInterfaceIMPLEMENTSCONSTANT2):
49176        (WebCore::jsTestInterfaceSUPPLEMENTALCONSTANT1):
49177        (WebCore::jsTestInterfaceSUPPLEMENTALCONSTANT2):
49178        * bindings/scripts/test/JS/JSTestObj.cpp:
49179        (WebCore::jsTestObjCONDITIONAL_CONST):
49180        (WebCore::jsTestObjCONST_VALUE_0):
49181        (WebCore::jsTestObjCONST_VALUE_1):
49182        (WebCore::jsTestObjCONST_VALUE_2):
49183        (WebCore::jsTestObjCONST_VALUE_4):
49184        (WebCore::jsTestObjCONST_VALUE_8):
49185        (WebCore::jsTestObjCONST_VALUE_9):
49186        (WebCore::jsTestObjCONST_VALUE_11):
49187        (WebCore::jsTestObjCONST_VALUE_12):
49188        (WebCore::jsTestObjCONST_VALUE_13):
49189        (WebCore::jsTestObjCONST_VALUE_14):
49190        (WebCore::jsTestObjCONST_JAVASCRIPT):
49191        (WebCore::jsTestObjReadonly):
49192
491932014-03-28  Myles C. Maxfield  <mmaxfield@apple.com>
49194
49195        A TrailingObject's endpoint might get decremented twice
49196        https://bugs.webkit.org/show_bug.cgi?id=130874
49197
49198        Reviewed by Darin Adler.
49199
49200        There are two places where we might shave off a trailing space from the end
49201        of a line. We don't want to hit both codepaths for a single line.
49202
49203        Fixes fast/block/update-midpoints-for-trailing-boxes-crash.html after r166245.
49204
49205        * rendering/line/BreakingContextInlineHeaders.h:
49206        (WebCore::checkMidpoints):
49207        (WebCore::BreakingContext::handleEndOfLine):
49208
492092014-03-28  Andreas Kling  <akling@apple.com>
49210
49211        Inline JSDOMWrapper subclasses' finishCreation().
49212        <https://webkit.org/b/130890>
49213
49214        finishCreation() is really a no-op for JSDOMWrapper subclasses in
49215        release builds. None of the ancestor classes do anything but assert
49216        in their implementations.
49217
49218        Generate the function inline, reducing binary size, and removing
49219        an unnecessary call from the JSFoo::create() helpers.
49220
49221        Reviewed by Sam Weinig.
49222
49223        * bindings/scripts/CodeGeneratorJS.pm:
49224        (GenerateHeader):
49225        (GenerateImplementation):
49226
492272014-03-28  Jer Noble  <jer.noble@apple.com>
49228
49229        [Mac] HLS streams will report an incorrect natural size.
49230        https://bugs.webkit.org/show_bug.cgi?id=130859
49231
49232        Reviewed by Eric Carlson.
49233
49234        Some HLS streams will report incorrect naturalSizes due to the asset's preferredTransform
49235        property not being  available at the same time as the track's natural size. Given that
49236        AVFoundation only allows one video track to be selected at a time, simply use the asset's
49237        presentation size, cached in m_cachedPresentation size in all cases.
49238
49239        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
49240        (WebCore::MediaPlayerPrivateAVFoundationObjC::sizeChanged):
49241
492422014-03-28  Antti Koivisto  <antti@apple.com>
49243
49244        Remove NodeListRootType flag
49245        https://bugs.webkit.org/show_bug.cgi?id=130896
49246
49247        Reviewed by Anders Carlsson.
49248
49249        This can be handled statically (except for the RadioNodeList case) removing
49250        a branch from NodeList traversal.
49251
49252        * dom/ClassNodeList.h:
49253        * dom/Document.cpp:
49254        (WebCore::Document::registerNodeListForInvalidation):
49255        (WebCore::Document::unregisterNodeListForInvalidation):
49256        (WebCore::Document::registerNodeList): Deleted.
49257        (WebCore::Document::unregisterNodeList): Deleted.
49258        
49259            Mark document invalidation registered lists with a bit.
49260            Renamed for clarity.
49261
49262        * dom/Document.h:
49263        * dom/LiveNodeList.cpp:
49264        (WebCore::LiveNodeList::LiveNodeList):
49265        (WebCore::LiveNodeList::rootNode):
49266        
49267            Base class version that invokes virtual isRootedAtDocument. It is needed to support 
49268            LiveNodeList::namedItem.
49269
49270        * dom/LiveNodeList.h:
49271        (WebCore::LiveNodeList::isRegisteredForInvalidationAtDocument):
49272        (WebCore::LiveNodeList::setRegisteredForInvalidationAtDocument):
49273        (WebCore::LiveNodeList::document):
49274        (WebCore::CachedLiveNodeList<NodeListType>::CachedLiveNodeList):
49275        (WebCore::CachedLiveNodeList<NodeListType>::~CachedLiveNodeList):
49276        (WebCore::CachedLiveNodeList<NodeListType>::rootNode):
49277        
49278            Call isRootedAtDocument on the final leaf type. Except for RadioNodeList this
49279            resolves statically.
49280
49281        (WebCore::CachedLiveNodeList<NodeListType>::willValidateIndexCache):
49282        (WebCore::CachedLiveNodeList<NodeListType>::invalidateCache):
49283        (WebCore::LiveNodeList::isRootedAtDocument): Deleted.
49284        (WebCore::LiveNodeList::rootType): Deleted.
49285        (WebCore::LiveNodeList::rootNode): Deleted.
49286        * dom/NameNodeList.h:
49287        * dom/NodeRareData.h:
49288        (WebCore::NodeListsNodeData::adoptDocument):
49289        * dom/TagNodeList.h:
49290        * html/HTMLCollection.cpp:
49291        (WebCore::rootTypeFromCollectionType):
49292        * html/HTMLCollection.h:
49293        (WebCore::HTMLCollection::isRootedAtDocument):
49294        (WebCore::HTMLCollection::rootType):
49295        
49296            HTMLCollections still needs the flag.
49297
49298        * html/LabelsNodeList.cpp:
49299        (WebCore::LabelsNodeList::LabelsNodeList):
49300        * html/LabelsNodeList.h:
49301        * html/RadioNodeList.cpp:
49302        (WebCore::RadioNodeList::RadioNodeList):
49303        * html/RadioNodeList.h:
49304
493052014-03-28  Mario Sanchez Prada  <mario.prada@samsung.com>
49306
49307        [GTK] Geoclue2 providers won't work after reloading
49308        https://bugs.webkit.org/show_bug.cgi?id=130898
49309
49310        Reviewed by Martin Robinson.
49311
49312        Don't reuse the Geoclue2 client proxy between different calls to
49313        startPosition(), and create a new client proxy each time instead.
49314
49315        * platform/geoclue/GeolocationProviderGeoclue2.cpp:
49316        (GeolocationProviderGeoclue::startUpdating): Don't reuse the
49317        client proxy, by always calling geoclue_manager_call_get_client().
49318        (GeolocationProviderGeoclue::stopUpdating): Disconnect from the
49319        'location-updated' signal and dispose the client proxy.
49320
493212014-03-28  Diego Pino Garcia  <dpino@igalia.com>
49322
49323        [GTK] Too many redirects visiting www.globalforestwatch.org
49324        https://bugs.webkit.org/show_bug.cgi?id=129681
49325
49326        Reviewed by Martin Robinson.
49327
49328        * platform/gtk/UserAgentGtk.cpp:
49329        (WebCore::standardUserAgent): Append Safari version to UserAgent
49330        string.
49331
493322014-03-28  Michael Saboff  <msaboff@apple.com>
49333
49334        Unreviewed, rolling r166249 back in.
49335
49336        Turns out r166070 didn't cause a 2% performance loss in page load times
49337
49338        Reverted changeset:
49339
49340        Unreviewed, rolling out r166070.
49341        Rollout r166070 due to 2% performance loss in page load times
49342
493432014-03-28  James Craig  <jcraig@apple.com>
49344
49345        Web Inspector: Copy/paste error. EventListener block in DOM.json uses description from Node.
49346        https://bugs.webkit.org/show_bug.cgi?id=130158
49347
49348        Reviewed by Timothy Hatcher.
49349
49350        * inspector/protocol/DOM.json: Fixed a copy/paste annoyance.
49351
493522014-03-27  James Craig  <jcraig@apple.com>
49353
49354        Web Inspector: AXI: expose selectedChildNodeIds of list boxes, tree controls, etc., and reconcile UI with childNodeIds
49355        https://bugs.webkit.org/show_bug.cgi?id=130827
49356
49357        Reviewed by Timothy Hatcher.
49358
49359        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
49360
49361        Support for selectedChildNodeIds in inspector-protocol: DOM.getAccessibilityPropertiesForNode.
49362
49363        * inspector/InspectorDOMAgent.cpp:
49364        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
49365        * inspector/protocol/DOM.json:
49366
493672014-03-27  Brent Fulgham  <bfulgham@apple.com>
49368
49369        Specify Shadow DOM Pseudo IDs in Media Element Constructors
49370        https://bugs.webkit.org/show_bug.cgi?id=130882
49371
49372        Reviewed by Eric Carlson.
49373
49374        * html/shadow/MediaControlElements.cpp:
49375        (WebCore::MediaControlPanelElement::MediaControlPanelElement): Call setPseudoId in constructor.
49376        (WebCore::MediaControlPanelEnclosureElement::MediaControlPanelEnclosureElement): Ditto.
49377        (WebCore::MediaControlTimelineContainerElement::MediaControlTimelineContainerElement): Ditto.
49378        (WebCore::MediaControlVolumeSliderContainerElement::MediaControlVolumeSliderContainerElement): Ditto.
49379        (WebCore::MediaControlStatusDisplayElement::MediaControlStatusDisplayElement): Ditto.
49380        (WebCore::MediaControlPanelMuteButtonElement::MediaControlPanelMuteButtonElement): Ditto.
49381        (WebCore::MediaControlVolumeSliderMuteButtonElement::MediaControlVolumeSliderMuteButtonElement): Ditto.
49382        (WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement): Ditto.
49383        (WebCore::MediaControlOverlayPlayButtonElement::MediaControlOverlayPlayButtonElement): Ditto.
49384        (WebCore::MediaControlSeekForwardButtonElement::MediaControlSeekForwardButtonElement): Ditto.
49385        (WebCore::MediaControlSeekBackButtonElement::MediaControlSeekBackButtonElement): Ditto.
49386        (WebCore::MediaControlRewindButtonElement::MediaControlRewindButtonElement): Ditto.
49387        (WebCore::MediaControlReturnToRealtimeButtonElement::MediaControlReturnToRealtimeButtonElement): Ditto.
49388        (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement): Ditto.
49389        (WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement): Ditto.
49390        (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement): Ditto.
49391        (WebCore::MediaControlTimelineElement::MediaControlTimelineElement): Ditto.
49392        (WebCore::MediaControlPanelVolumeSliderElement::MediaControlPanelVolumeSliderElement): Ditto.
49393        (WebCore::MediaControlFullscreenVolumeSliderElement::MediaControlFullscreenVolumeSliderElement): Ditto.
49394        (WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement): Ditto.
49395        (WebCore::MediaControlFullscreenVolumeMinButtonElement::MediaControlFullscreenVolumeMinButtonElement): Ditto.
49396        (WebCore::MediaControlFullscreenVolumeMaxButtonElement::MediaControlFullscreenVolumeMaxButtonElement): Ditto.
49397        (WebCore::MediaControlTimeRemainingDisplayElement::MediaControlTimeRemainingDisplayElement): Ditto.
49398        (WebCore::MediaControlCurrentTimeDisplayElement::MediaControlCurrentTimeDisplayElement): Ditto.
49399        (WebCore::MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement): Ditto.
49400
494012014-03-27  Benjamin Poulain  <bpoulain@apple.com>
49402
49403        [iOS][WK2] Adjust the tile coverage on the scrollview's edges
49404        https://bugs.webkit.org/show_bug.cgi?id=130884
49405
49406        Reviewed by Dan Bernstein.
49407
49408        * platform/ios/ScrollViewIOS.mm:
49409        (WebCore::ScrollView::computeCoverageRect):
49410        Pull back the future rect inside the contentRect if it goes outside.
49411        There is no point in retiling for rubberbanding and the extra tiles should be always be
49412        on the opposite side to the edges.
49413
494142014-03-27  Joseph Pecoraro  <pecoraro@apple.com>
49415
49416        Remove unused LocaleMac::create method
49417        https://bugs.webkit.org/show_bug.cgi?id=130870
49418
49419        Reviewed by Andreas Kling.
49420
49421        * platform/text/mac/LocaleMac.h:
49422        * platform/text/mac/LocaleMac.mm:
49423        (WebCore::LocaleMac::create): Deleted.
49424        (WebCore::LocaleMac::shortDateFormatter): Deleted.
49425
494262014-03-27  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
49427
49428        Clean up unneeded "mutable" keyword
49429        https://bugs.webkit.org/show_bug.cgi?id=130832
49430
49431        Reviewed by Andreas Kling.
49432
49433        As r166350, this patch cleans up unneeded "mutable" keywords.
49434        Additionally, m_validatedSelectionCache is removed because it is not used anywhere else.
49435
49436        * css/CSSFontFaceRule.h:
49437        * css/CSSStyleRule.h:
49438        * editing/FrameSelection.h:
49439
494402014-03-27  Enrica Casucci  <enrica@apple.com>
49441
49442        Add support for AirPlay picker in WK2 for iOS.
49443        https://bugs.webkit.org/show_bug.cgi?id=130855
49444        <rdar://problem/15349859>
49445
49446        Reviewed by Eric Carlson, Joseph Pecoraro and Benjamin Poulain.
49447
49448        Adds support in HTMLMediaSession to display the airplay picker
49449        and to monitor presence of available wireless targets.
49450
49451        * html/HTMLMediaSession.cpp:
49452        (WebCore::HTMLMediaSession::showPlaybackTargetPicker):
49453        (WebCore::HTMLMediaSession::hasWirelessPlaybackTargets):
49454        (WebCore::HTMLMediaSession::setHasPlaybackTargetAvailabilityListeners):
49455        * loader/EmptyClients.h:
49456        * page/ChromeClient.h:
49457        * platform/audio/MediaSessionManager.cpp:
49458        (WebCore::MediaSessionManager::wirelessRoutesAvailableChanged):
49459        * platform/audio/MediaSessionManager.h:
49460        (WebCore::MediaSessionManager::hasWirelessTargetsAvailable):
49461        (WebCore::MediaSessionManager::startMonitoringAirPlayRoutes):
49462        (WebCore::MediaSessionManager::stopMonitoringAirPlayRoutes):
49463        * platform/audio/ios/MediaSessionManagerIOS.h:
49464        * platform/audio/ios/MediaSessionManagerIOS.mm:
49465        (WebCore::MediaSessionManageriOS::hasWirelessTargetsAvailable):
49466        (WebCore::MediaSessionManageriOS::startMonitoringAirPlayRoutes):
49467        (WebCore::MediaSessionManageriOS::stopMonitoringAirPlayRoutes):
49468        (-[WebMediaSessionHelper initWithCallback:]):
49469        (-[WebMediaSessionHelper hasWirelessTargetsAvailable]):
49470        (-[WebMediaSessionHelper startMonitoringAirPlayRoutes]):
49471        (-[WebMediaSessionHelper stopMonitoringAirPlayRoutes]):
49472        (-[WebMediaSessionHelper wirelessRoutesAvailableDidChange:]):
49473        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
49474        (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessVideoPlaybackDisabled):
49475        (WebCore::MediaPlayerPrivateAVFoundationObjC::setWirelessVideoPlaybackDisabled):
49476
494772014-03-27  Bem Jones-Bey  <bjonesbe@adobe.com>
49478
49479        [CSS Shapes][css clip-path] rounded corner calculation for box shapes is wrong
49480        https://bugs.webkit.org/show_bug.cgi?id=127982
49481
49482        Reviewed by Simon Fraser.
49483
49484        Calculate rounded corners for box shapes as defined in the CSS Shapes
49485        spec.
49486
49487        Tests: css3/masking/clip-path-border-radius-border-box-000.html
49488               css3/masking/clip-path-border-radius-content-box-000.html
49489               css3/masking/clip-path-border-radius-content-box-001.html
49490               css3/masking/clip-path-border-radius-padding-box-000.html
49491               css3/masking/clip-path-border-radius-padding-box-001.html
49492               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-border-box-000.html
49493               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-border-box-001.html
49494               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-border-box-002.html
49495               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-content-box-000.html
49496               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-content-box-001.html
49497               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-content-box-002.html
49498               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-content-box-003.html
49499               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-margin-box-000.html
49500               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-margin-box-001.html
49501               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-margin-box-002.html
49502               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-margin-box-003.html
49503               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-margin-box-004.html
49504               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-padding-box-000.html
49505               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-padding-box-001.html
49506               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-padding-box-002.html
49507               fast/shapes/shape-outside-floats/shape-outside-floats-border-radius-padding-box-003.html
49508
49509        * platform/graphics/RoundedRect.h:
49510        (WebCore::RoundedRect::Radii::transposedRadii): Transpose radii for
49511            vertical writing modes.
49512        (WebCore::RoundedRect::moveBy): Add method for use with clip path.
49513        (WebCore::RoundedRect::transposedRect): Transpose rect for vertical
49514            writing modes.
49515        * rendering/RenderBox.h:
49516        (WebCore::RenderBox::marginBoxRect): Return the margin box rect for
49517            the RenderBox.
49518        * rendering/RenderLayer.cpp:
49519        (WebCore::RenderLayer::setupClipPath): Call the new function for the
49520            rounded corner calculation.
49521        * rendering/shapes/ShapeInfo.cpp:
49522        (WebCore::ShapeInfo<RenderType>::computedShape): Call the new function
49523            for the rounded corner calculation.
49524        * rendering/shapes/BoxShape.cpp:
49525        (WebCore::adjustRadiusForMarginBoxShape): Helper function for
49526            computeRoundedRectForLayoutBoxShape.
49527        (WebCore::computeMarginBoxShapeRadius): Ditto.
49528        (WebCore::computeMarginBoxShapeRadii): Ditto.
49529        (WebCore::computeRoundedRectForBoxShape): Utility function to do the
49530            rounded corner calculation.
49531        * rendering/shapes/BoxShape.h: Add new function.
49532        * rendering/style/RenderStyle.h:
49533        (WebCore::RenderStyle::getRoundedInnerBorderFor): Add default argument
49534            values.
49535
495362014-03-27  Commit Queue  <commit-queue@webkit.org>
49537
49538        Unreviewed, rolling out r166364.
49539        https://bugs.webkit.org/show_bug.cgi?id=130872
49540
49541        Caused a test assertion (Requested by smfr on #webkit).
49542
49543        Reverted changeset:
49544
49545        "Operator stretching: expose a math data API"
49546        https://bugs.webkit.org/show_bug.cgi?id=130572
49547        http://trac.webkit.org/changeset/166364
49548
495492014-03-27  Benjamin Poulain  <bpoulain@apple.com>
49550
49551        [iOS][WK2] Compute a good exposed rect when scaling WKContentView
49552        https://bugs.webkit.org/show_bug.cgi?id=130761
49553
49554        Reviewed by Simon Fraser.
49555
49556        * WebCore.exp.in:
49557        * platform/ScrollView.h:
49558        * platform/ios/ScrollViewIOS.mm:
49559        (WebCore::ScrollView::setScrollVelocity):
49560        (WebCore::ScrollView::computeCoverageRect):
49561        While scaling in, do not add margins tiles. When scaling out, add 1 margin tile size
49562        all around.
49563
495642014-03-27  Commit Queue  <commit-queue@webkit.org>
49565
49566        Unreviewed, rolling out r166360.
49567        https://bugs.webkit.org/show_bug.cgi?id=130869
49568
49569        Seems to have broken PLT (Requested by ap on #webkit).
49570
49571        Reverted changeset:
49572
49573        "Connection::dispatchOneMessage() can be re-entered while
49574        handling Cmd-key menu"
49575        https://bugs.webkit.org/show_bug.cgi?id=130767
49576        http://trac.webkit.org/changeset/166360
49577
495782014-03-27  Antti Koivisto  <antti@apple.com>
49579
49580        Remove LiveNodeList::Type
49581        https://bugs.webkit.org/show_bug.cgi?id=130866
49582
49583        Reviewed by Andreas Kling.
49584
49585        We don't need dynamic type information anymore.
49586
49587        * dom/ClassNodeList.cpp:
49588        (WebCore::ClassNodeList::ClassNodeList):
49589        * dom/ContainerNode.cpp:
49590        (WebCore::ContainerNode::getElementsByTagName):
49591        (WebCore::ContainerNode::getElementsByName):
49592        (WebCore::ContainerNode::getElementsByClassName):
49593        (WebCore::ContainerNode::radioNodeList):
49594        * dom/LiveNodeList.cpp:
49595        (WebCore::LiveNodeList::LiveNodeList):
49596        * dom/LiveNodeList.h:
49597        (WebCore::LiveNodeList::invalidationType):
49598        (WebCore::CachedLiveNodeList<NodeListType>::CachedLiveNodeList):
49599        (WebCore::LiveNodeList::type): Deleted.
49600        * dom/NameNodeList.cpp:
49601        (WebCore::NameNodeList::NameNodeList):
49602        (WebCore::NameNodeList::nodeMatches): Deleted.
49603        * dom/NameNodeList.h:
49604        (WebCore::NameNodeList::nodeMatches):
49605        * dom/NodeRareData.h:
49606        (WebCore::NodeListTypeIdentifier<ClassNodeList>::value):
49607        (WebCore::NodeListTypeIdentifier<NameNodeList>::value):
49608        (WebCore::NodeListTypeIdentifier<TagNodeList>::value):
49609        (WebCore::NodeListTypeIdentifier<HTMLTagNodeList>::value):
49610        (WebCore::NodeListTypeIdentifier<RadioNodeList>::value):
49611        (WebCore::NodeListTypeIdentifier<LabelsNodeList>::value):
49612        
49613            Get unique id from type for key generation purposes only.
49614
49615        (WebCore::NodeListsNodeData::addCacheWithAtomicName):
49616        (WebCore::NodeListsNodeData::addCacheWithName):
49617        (WebCore::NodeListsNodeData::removeCacheWithAtomicName):
49618        (WebCore::NodeListsNodeData::removeCacheWithName):
49619        (WebCore::NodeListsNodeData::namedNodeListKey):
49620        * dom/TagNodeList.cpp:
49621        (WebCore::TagNodeList::TagNodeList):
49622        (WebCore::HTMLTagNodeList::HTMLTagNodeList):
49623        * dom/TagNodeList.h:
49624        * html/LabelableElement.cpp:
49625        (WebCore::LabelableElement::labels):
49626        * html/LabelsNodeList.cpp:
49627        (WebCore::LabelsNodeList::LabelsNodeList):
49628        * html/LabelsNodeList.h:
49629        * html/RadioNodeList.cpp:
49630        (WebCore::RadioNodeList::RadioNodeList):
49631        * html/RadioNodeList.h:
49632
496332014-03-27  Simon Fraser  <simon.fraser@apple.com>
49634
49635        Fix crash when RenderView is cleared inside of frame flattening layout
49636        https://bugs.webkit.org/show_bug.cgi?id=130864
49637
49638        Reviewed by Dan Bernstein.
49639        
49640        Navigating on http://wallstcheatsheet.com pages on iOS in WebKit1 would
49641        sometimes crash when, inside the inChildFrameLayoutWithFrameFlattening clause,
49642        our frame's RenderView would be null after doing a layout from the root frame,
49643        possibly also when WebCore was being re-entered from another thread.
49644        
49645        Add a null check to fix this.
49646        
49647        Crash was timing-dependent and hard to test.
49648
49649        * page/FrameView.cpp:
49650        (WebCore::FrameView::layout):
49651
496522014-03-27  Antti Koivisto  <antti@apple.com>
49653
49654        Remove some unnecessary branches from LiveNodeList traversal
49655        https://bugs.webkit.org/show_bug.cgi?id=130854
49656
49657        Reviewed by Andreas Kling.
49658
49659        Compile different traversal code paths for all NodeList subclasses.
49660
49661        * dom/ClassNodeList.cpp:
49662        (WebCore::ClassNodeList::ClassNodeList):
49663        (WebCore::ClassNodeList::~ClassNodeList):
49664        (WebCore::ClassNodeList::nodeMatches): Deleted.
49665        * dom/ClassNodeList.h:
49666        (WebCore::ClassNodeList::nodeMatches):
49667        (WebCore::ClassNodeList::nodeMatchesInlined): Deleted.
49668        
49669            Remove separate nodeMatchesInlined functions. 
49670            We now rely on exact types and marking classes final.
49671
49672        * dom/LiveNodeList.cpp:
49673        (WebCore::LiveNodeList::LiveNodeList):
49674        (WebCore::LiveNodeList::~LiveNodeList):
49675        (WebCore::LiveNodeList::namedItem):
49676        (WebCore::LiveNodeList::rootNode): Deleted.
49677        (WebCore::isMatchingElement): Deleted.
49678        (WebCore::firstMatchingElement): Deleted.
49679        (WebCore::lastMatchingElement): Deleted.
49680        (WebCore::nextMatchingElement): Deleted.
49681        (WebCore::previousMatchingElement): Deleted.
49682        (WebCore::traverseMatchingElementsForward): Deleted.
49683        (WebCore::traverseMatchingElementsBackward): Deleted.
49684        (WebCore::LiveNodeList::collectionFirst): Deleted.
49685        (WebCore::LiveNodeList::collectionLast): Deleted.
49686        (WebCore::LiveNodeList::collectionTraverseForward): Deleted.
49687        (WebCore::LiveNodeList::collectionTraverseBackward): Deleted.
49688        (WebCore::LiveNodeList::length): Deleted.
49689        (WebCore::LiveNodeList::item): Deleted.
49690        (WebCore::LiveNodeList::memoryCost): Deleted.
49691        (WebCore::LiveNodeList::invalidateCache): Deleted.
49692        * dom/LiveNodeList.h:
49693        (WebCore::LiveNodeList::invalidateCacheForAttribute):
49694        (WebCore::CachedLiveNodeList::collectionCanTraverseBackward):
49695        (WebCore::LiveNodeList::rootNode):
49696        (WebCore::CachedLiveNodeList<NodeListType>::CachedLiveNodeList):
49697        
49698            Add CachedLiveNodeList<NodeListType> utility type that interfaces with CollectionIndexCache.
49699            It is the base class for all concrete LiveNodeLists.
49700
49701        (WebCore::CachedLiveNodeList<NodeListType>::~CachedLiveNodeList):
49702        (WebCore::CachedLiveNodeList<NodeListType>::collectionFirst):
49703        (WebCore::CachedLiveNodeList<NodeListType>::collectionLast):
49704        (WebCore::nextMatchingElement):
49705        (WebCore::CachedLiveNodeList<NodeListType>::collectionTraverseForward):
49706        (WebCore::previousMatchingElement):
49707        (WebCore::CachedLiveNodeList<NodeListType>::collectionTraverseBackward):
49708        (WebCore::CachedLiveNodeList<NodeListType>::willValidateIndexCache):
49709        (WebCore::CachedLiveNodeList<NodeListType>::invalidateCache):
49710        (WebCore::CachedLiveNodeList<NodeListType>::length):
49711        (WebCore::CachedLiveNodeList<NodeListType>::item):
49712        (WebCore::CachedLiveNodeList<NodeListType>::memoryCost):
49713        
49714            Templated code moves to header.
49715
49716        (WebCore::LiveNodeList::LiveNodeList): Deleted.
49717        (WebCore::LiveNodeList::~LiveNodeList): Deleted.
49718        (WebCore::LiveNodeList::invalidateCache): Deleted.
49719        (WebCore::LiveNodeList::collectionCanTraverseBackward): Deleted.
49720        (WebCore::LiveNodeList::willValidateIndexCache): Deleted.
49721        * dom/NameNodeList.cpp:
49722        (WebCore::NameNodeList::NameNodeList):
49723        * dom/NameNodeList.h:
49724        * dom/Node.cpp:
49725        (WebCore::Document::invalidateNodeListAndCollectionCaches):
49726        (WebCore::NodeListsNodeData::invalidateCaches):
49727        * dom/TagNodeList.cpp:
49728        (WebCore::TagNodeList::TagNodeList):
49729        (WebCore::HTMLTagNodeList::HTMLTagNodeList):
49730        (WebCore::HTMLTagNodeList::~HTMLTagNodeList):
49731        (WebCore::TagNodeList::nodeMatches): Deleted.
49732        (WebCore::HTMLTagNodeList::nodeMatches): Deleted.
49733        * dom/TagNodeList.h:
49734        (WebCore::TagNodeList::nodeMatches):
49735        (WebCore::HTMLTagNodeList::nodeMatches):
49736        (WebCore::TagNodeList::create): Deleted.
49737        (WebCore::HTMLTagNodeList::nodeMatchesInlined): Deleted.
49738        * html/LabelsNodeList.cpp:
49739        (WebCore::LabelsNodeList::LabelsNodeList):
49740        * html/LabelsNodeList.h:
49741        * html/RadioNodeList.cpp:
49742        (WebCore::RadioNodeList::RadioNodeList):
49743        * html/RadioNodeList.h:
49744
497452014-03-27  Adenilson Cavalcanti  <cavalcantii@gmail.com>
49746
49747        Remove comment from Filter.h
49748        https://bugs.webkit.org/show_bug.cgi?id=130848
49749
49750        Reviewed by Simon Fraser.
49751
49752        Exploring the use of consts on applyScale() methods didn't yield
49753        good results.
49754
49755        No new tests, no change on behavior.
49756
49757        * platform/graphics/filters/Filter.h:
49758
497592014-03-27  Frédéric Wang  <fred.wang@free.fr>
49760
49761        Operator stretching: expose a math data API
49762        https://bugs.webkit.org/show_bug.cgi?id=130572
49763
49764        Reviewed by Chris Fleizach.
49765
49766        We expose a new SimpleFontData API to give access to the data from the
49767        OpenType MATH table using a font cache. The class OpenTypeMathData will
49768        be implemented in bug 130324. On Darwin platform, we also implement the
49769        missing FontPlatformData::openTypeTable function which will be necessary
49770        to load the OpenType MATH table. The changes are intended to be used
49771        for MathML operator stretching (bug 130322) so tests are not added yet.
49772
49773        * CMakeLists.txt: add new OpenTypeMathData files.
49774        * WebCore.vcxproj/WebCore.vcxproj: ditto.
49775        * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
49776        * WebCore.xcodeproj/project.pbxproj: ditto.
49777        * platform/graphics/FontCache.cpp: We add a FontCache::getMathData function to implement a cache for the math data.
49778        We make the math and vertical data share the same key for the cache.
49779        (WebCore::fontMathDataCacheInstance):
49780        (WebCore::FontCache::getMathData):
49781        (WebCore::fontVerticalDataCacheInstance):
49782        * platform/graphics/FontCache.h: We declare FontCache::getMathData and FontFileKey on all platforms.
49783        * platform/graphics/FontPlatformData.cpp:
49784        (WebCore::FontPlatformData::openTypeTable): We implement openTypeTable() on Darwin platform.
49785        * platform/graphics/FontPlatformData.h: We expose openTypeTable() on Darwin platform.
49786        * platform/graphics/SimpleFontData.cpp: We initialize m_mathData from the font cache.
49787        (WebCore::SimpleFontData::SimpleFontData):
49788        * platform/graphics/SimpleFontData.h: We expose a mathData() function to access the MATH data.
49789        * platform/graphics/opentype/OpenTypeMathData.cpp: Added. This is a new class that will be used to parse the data from the OpenType MATH table.
49790        (WebCore::OpenTypeMathData::OpenTypeMathData):
49791        * platform/graphics/opentype/OpenTypeMathData.h: Added.
49792        (WebCore::OpenTypeMathData::create):
49793        (WebCore::OpenTypeMathData::hasMathData):
49794
497952014-03-27  Brent Fulgham  <bfulgham@apple.com>
49796
49797        Fix a crash caused by track insertion after load()
49798        https://bugs.webkit.org/show_bug.cgi?id=130777
49799
49800        Reviewed by Eric Carlson.
49801
49802        Test: media/track/track-insert-after-load-crash.html
49803
49804        Based on the Blink change (patch by acolwell@chromium.org):
49805        https://codereview.chromium.org/211373009/
49806
49807        * html/HTMLMediaElement.cpp:
49808        (WebCore::HTMLMediaElement::parseAttribute): Remove stale LoadMediaResource flag after explicit load.
49809
498102014-03-27  Alexey Proskuryakov  <ap@apple.com>
49811
49812        Connection::dispatchOneMessage() can be re-entered while handling Cmd-key menu
49813        equivalents, ASSERT(!_data->_keyDownEventBeingResent)
49814        https://bugs.webkit.org/show_bug.cgi?id=130767
49815        <rdar://problem/16307487>
49816
49817        Added a wrapper for RunLoop::initializeMainThread that also adds modal run loop
49818        mode to it on Mac.
49819
49820        * CMakeLists.txt:
49821        * WebCore.exp.in:
49822        * WebCore.vcxproj/WebCore.vcxproj:
49823        * WebCore.vcxproj/WebCore.vcxproj.filters:
49824        * WebCore.xcodeproj/project.pbxproj:
49825        * platform/MainRunLoop.cpp: Added.
49826        (WebCore::initializeMainRunLoop):
49827        * platform/MainRunLoop.h: Added.
49828        * platform/mac/MainRunLoop.mm: Added.
49829        (WebCore::initializeMainRunLoop):
49830
498312014-03-27  Krzysztof Czech  <k.czech@samsung.com>
49832
49833        AX: Returns const reference to static string.
49834        https://bugs.webkit.org/show_bug.cgi?id=130835
49835
49836        Reviewed by Mario Sanchez Prada.
49837
49838        Avoiding some unnecessary copies by returning const reference to static string.
49839
49840        No new tests. No behaviour change.
49841
49842        * accessibility/AccessibilityMediaControls.cpp:
49843        (WebCore::AccessibilityMediaControl::controlTypeName):
49844        (WebCore::AccessibilityMediaControlsContainer::elementTypeName):
49845        * accessibility/AccessibilityMediaControls.h:
49846
498472014-03-27  Mihnea Ovidenie  <mihnea@adobe.com>
49848
49849        [CSSRegions] Rename inNamedFlow flag to isNamedFlowContentNode flag
49850        https://bugs.webkit.org/show_bug.cgi?id=130731
49851
49852        Reviewed by Andrei Bucur.
49853
49854        Currently, the inNamedFlow flag in Node class tells if a node is a content node, one that has a style with flow-into.
49855        Since it is used only for those nodes and not propagated through hierarchy, i want to renamed it to a more meaningful name.
49856        No new functionality, no new tests.
49857
49858        * dom/ContainerNode.cpp:
49859        (WebCore::destroyRenderTreeIfNeeded):
49860        * dom/Element.cpp:
49861        (WebCore::Element::~Element):
49862        (WebCore::Element::unregisterNamedFlowContentElement):
49863        * dom/Node.h:
49864        (WebCore::Node::isNamedFlowContentNode):
49865        (WebCore::Node::setIsNamedFlowContentNode):
49866        (WebCore::Node::clearIsNamedFlowContentNode):
49867        * rendering/RenderNamedFlowThread.cpp:
49868        (WebCore::RenderNamedFlowThread::clearContentElements):
49869        (WebCore::RenderNamedFlowThread::registerNamedFlowContentElement):
49870        (WebCore::RenderNamedFlowThread::unregisterNamedFlowContentElement):
49871        (WebCore::nextNodeInsideContentElement):
49872        * style/StyleResolveTree.cpp:
49873        (WebCore::Style::attachChildren):
49874        (WebCore::Style::resolveLocal):
49875
498762014-03-27  Mihnea Ovidenie  <mihnea@adobe.com>
49877
49878        [CSSRegions] Crash when cloning a region child with a content node child
49879        https://bugs.webkit.org/show_bug.cgi?id=129811
49880
49881        Reviewed by David Hyatt.
49882
49883        Collecting the children of a region in another named flow will be supported
49884        again in the future and it will be revisited when we will implement the content
49885        keyword: http://dev.w3.org/csswg/css-regions-1/#the-flow-into-property.
49886        Remove the support for now as it introduces unnecessary complexity in the code
49887        and potential wrong behavior.
49888
49889        Test: fast/regions/region-content-node-child-clone-crash.html
49890
49891        * dom/Element.cpp:
49892        (WebCore::Element::shouldMoveToFlowThread):
49893        (WebCore::Element::clearStyleDerivedDataBeforeDetachingRenderer):
49894        * dom/Element.h:
49895        * dom/ElementRareData.h:
49896        (WebCore::ElementRareData::ElementRareData):
49897        * rendering/FlowThreadController.cpp:
49898        * rendering/FlowThreadController.h:
49899        * style/StyleResolveTree.cpp:
49900        (WebCore::Style::moveToFlowThreadIfNeeded):
49901        (WebCore::Style::createRendererIfNeeded):
49902
499032014-03-27  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
49904
49905        Remove unneeded mutable keyword in some member variables 
49906        https://bugs.webkit.org/show_bug.cgi?id=130813
49907
49908        Reviewed by Andreas Kling.
49909
49910        Some member variables have mutable keyword though they don't used by const function.
49911        This patch removes them. 
49912
49913        No new tests, no behavior changes. Just clean up.
49914
49915        * storage/StorageAreaSync.h:
49916        * svg/animation/SVGSMILElement.h:
49917
499182014-03-27  Commit Queue  <commit-queue@webkit.org>
49919
49920        Unreviewed, rolling out r166296 and r166331.
49921        https://bugs.webkit.org/show_bug.cgi?id=130822
49922
49923        caused some crashes and frequent assertion failures, and the
49924        fix is going to take a little while (Requested by thorton on
49925        #webkit).
49926
49927        Reverted changesets:
49928
49929        "[iOS WebKit2] Flush all surfaces after painting into all of
49930        them, instead of after painting into each one"
49931        https://bugs.webkit.org/show_bug.cgi?id=130768
49932        http://trac.webkit.org/changeset/166296
49933
49934        "Assertion failure in RemoteLayerBackingStore::flush"
49935        https://bugs.webkit.org/show_bug.cgi?id=130810
49936        http://trac.webkit.org/changeset/166331
49937
499382014-03-26  Simon Fraser  <simon.fraser@apple.com>
49939
49940        Fix failing scrolling tests by reverting to previous behavior where
49941        the scrolling geometry for the main frame scrolling node was only
49942        updated from frameViewLayoutUpdated() and no-where else.
49943
49944        * WebCore.exp.in:
49945        * page/scrolling/AsyncScrollingCoordinator.cpp:
49946        (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
49947        * page/scrolling/AsyncScrollingCoordinator.h:
49948        * page/scrolling/ScrollingCoordinator.h:
49949        (WebCore::ScrollingCoordinator::updateScrollingNode):
49950        * rendering/RenderLayerCompositor.cpp:
49951        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
49952        (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer): Deleted.
49953
499542014-03-26  Ryosuke Niwa  <rniwa@webkit.org>
49955
49956        HTMLConverter::_processText is slow because it walks up ancestor elements
49957        https://bugs.webkit.org/show_bug.cgi?id=130820
49958
49959        Reviewed by Sam Weinig.
49960
49961        Avoid walking up the tree from each text node by caching the aggregated attributed strings for each element.
49962        Also compute the attributed strings top-down to avoid calling mutableCopy in every iteration. 
49963
49964        This reduces the runtime of Interactive/CopyAll.html from 15s to 13s (15%).
49965
49966        * editing/cocoa/HTMLConverter.mm:
49967        (HTMLConverter::_attributesForElement):
49968        (HTMLConverter::attributesForElement):
49969        (HTMLConverter::aggregatedAttributesForAncestors):
49970        (HTMLConverter::_processText):
49971
499722014-03-26  Sam Weinig  <sam@webkit.org>
49973
49974        Fix iOS build.
49975
49976        * editing/cocoa/HTMLConverter.mm:
49977        (_font):
49978
499792014-03-26  Ryosuke Niwa  <rniwa@webkit.org>
49980
49981        Make _processText and _traverseNode in HTMLConverter more efficient
49982        https://bugs.webkit.org/show_bug.cgi?id=130769
49983
49984        Reviewed by Sam Weinig.
49985
49986        Rewrote a bunch of code in C++ and avoided creating wrappers.
49987        This reduces the runtime of Interactive/CopyAll.html from ~16.5s to 15s.
49988
49989        * editing/cocoa/HTMLConverter.mm:
49990        (HTMLConverterCaches::isAncestorsOfStartToBeConverted):
49991        (HTMLConverter::HTMLConverter):
49992        (HTMLConverter::~HTMLConverter):
49993        (HTMLConverter::_processElement):
49994        (HTMLConverter::_processText):
49995        (HTMLConverter::_traverseNode):
49996        (HTMLConverter::_traverseFooterNode):
49997        (HTMLConverterCaches::cacheAncestorsOfStartToBeConverted):
49998        (HTMLConverter::_loadFromDOMRange):
49999
500002014-03-26  Adenilson Cavalcanti  <cavalcantii@gmail.com>
50001
50002        FEGaussianBlur: unify and const-ify calculateKernelSize
50003        https://bugs.webkit.org/show_bug.cgi?id=130779
50004
50005        Some methods can benefit of using const refs as also make sense to
50006        unify the interface (i.e. parameters) in calculateKernelSize/Unscaled.
50007
50008        FilterEffect::filter() will now return a reference, which helps since
50009        its descendants were accessing methods into the pointer without testing
50010        for it.
50011
50012        Reviewed by Simon Fraser.
50013
50014        No new tests, no changes on behavior.
50015
50016        * platform/graphics/filters/FEDisplacementMap.cpp:
50017        (WebCore::FEDisplacementMap::platformApplySoftware):
50018        * platform/graphics/filters/FEDropShadow.cpp:
50019        (WebCore::FEDropShadow::determineAbsolutePaintRect):
50020        (WebCore::FEDropShadow::platformApplySoftware):
50021        * platform/graphics/filters/FEGaussianBlur.cpp:
50022        (WebCore::FEGaussianBlur::calculateUnscaledKernelSize):
50023        (WebCore::FEGaussianBlur::calculateKernelSize):
50024        (WebCore::FEGaussianBlur::determineAbsolutePaintRect):
50025        (WebCore::FEGaussianBlur::platformApplySoftware):
50026        * platform/graphics/filters/FEGaussianBlur.h:
50027        * platform/graphics/filters/FEMorphology.cpp:
50028        (WebCore::FEMorphology::determineAbsolutePaintRect):
50029        (WebCore::FEMorphology::platformApplySoftware):
50030        * platform/graphics/filters/FEOffset.cpp:
50031        (WebCore::FEOffset::determineAbsolutePaintRect):
50032        (WebCore::FEOffset::platformApplySoftware):
50033        * platform/graphics/filters/FETile.cpp:
50034        (WebCore::FETile::platformApplySoftware):
50035        * platform/graphics/filters/FETurbulence.cpp:
50036        (WebCore::FETurbulence::fillRegion):
50037        * platform/graphics/filters/Filter.h:
50038        (WebCore::Filter::applyHorizontalScale):
50039        (WebCore::Filter::applyVerticalScale):
50040        * platform/graphics/filters/FilterEffect.h:
50041        (WebCore::FilterEffect::filter):
50042        * platform/graphics/filters/SourceAlpha.cpp:
50043        (WebCore::SourceAlpha::determineAbsolutePaintRect):
50044        (WebCore::SourceAlpha::platformApplySoftware):
50045        * platform/graphics/filters/SourceGraphic.cpp:
50046        (WebCore::SourceGraphic::determineAbsolutePaintRect):
50047        (WebCore::SourceGraphic::platformApplySoftware):
50048        * rendering/svg/RenderSVGResourceFilterPrimitive.cpp:
50049        (WebCore::RenderSVGResourceFilterPrimitive::determineFilterPrimitiveSubregion):
50050        * svg/graphics/filters/SVGFEImage.cpp:
50051        (WebCore::FEImage::determineAbsolutePaintRect):
50052        (WebCore::FEImage::platformApplySoftware):
50053
500542014-03-26  Simon Fraser  <simon.fraser@apple.com>
50055
50056        Make sure childContainmentLayer is parented
50057        https://bugs.webkit.org/show_bug.cgi?id=130808
50058
50059        Reviewed by Tim Horton.
50060
50061        m_childContainmentLayer was never parented if the page
50062        created no other compositing layers, which left a dangling
50063        GraphicsLayer which in turn confused UI-side compositing a little.
50064        Fix by always parenting this layer.
50065
50066        * rendering/RenderLayerBacking.cpp:
50067        (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
50068
500692014-03-26  Brian Burg  <bburg@apple.com>
50070
50071        Web Replay: disable page cache during capture/replay
50072        https://bugs.webkit.org/show_bug.cgi?id=130672
50073
50074        Reviewed by Timothy Hatcher.
50075
50076        Save, set, and restore page cache settings at the correct times.
50077
50078        No new tests. If this code fails, then the tests for network replay will fail.
50079
50080        * replay/ReplayController.cpp:
50081        (WebCore::ReplayController::setForceDeterministicSettings): Added.
50082        (WebCore::ReplayController::startCapturing):
50083        (WebCore::ReplayController::stopCapturing):
50084        (WebCore::ReplayController::cancelPlayback):
50085        (WebCore::ReplayController::replayToPosition):
50086        * replay/ReplayController.h:
50087
500882014-03-26  Sam Weinig  <sam@webkit.org>
50089
50090        Convert more of HTMLConverter to C++
50091        https://bugs.webkit.org/show_bug.cgi?id=130811
50092
50093        Reviewed by Anders Carlsson.
50094
50095        * editing/cocoa/HTMLConverter.mm:
50096        (HTMLConverter::HTMLConverter):
50097        (HTMLConverter::~HTMLConverter):
50098        (HTMLConverter::_blockLevelElementForNode):
50099        (HTMLConverter::_colorForElement):
50100        (HTMLConverter::_computedAttributesForElement):
50101        (HTMLConverter::_attributesForElement):
50102        (HTMLConverter::_fillInBlock):
50103        (HTMLConverter::_enterElement):
50104        (HTMLConverter::_addTableForElement):
50105        (HTMLConverter::_addTableCellForElement):
50106        (HTMLConverter::_processElement):
50107        (HTMLConverter::_exitElement):
50108        (HTMLConverter::_getFloat): Deleted.
50109        (HTMLConverter::_elementIsBlockLevel): Deleted.
50110        (HTMLConverter::_elementHasOwnBackgroundColor): Deleted.
50111        (HTMLConverter::_colorForNode): Deleted.
50112
501132014-03-26  Simon Fraser  <simon.fraser@apple.com>
50114
50115        Hook up -webkit-overflow-scrolling:touch for iOS WK2
50116        https://bugs.webkit.org/show_bug.cgi?id=130809
50117
50118        Reviewed by Tim Horton.
50119
50120        Get -webkit-overflow-scrolling: touch working for iOS WK2.
50121        
50122        * WebCore.exp.in:
50123        * page/scrolling/AsyncScrollingCoordinator.cpp:
50124        (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
50125        Send in ScrollingGeometry when we update scrolling nodes.
50126        * page/scrolling/AsyncScrollingCoordinator.h:
50127        * page/scrolling/ScrollingCoordinator.h:
50128        (WebCore::ScrollingCoordinator::updateScrollingNode):
50129        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
50130        Need to get to the scrolling layer in a subclass.
50131        (WebCore::ScrollingTreeScrollingNodeIOS::scrollLayer):
50132        * rendering/RenderLayer.cpp:
50133        (WebCore::RenderLayer::hasAcceleratedTouchScrolling): Remove code
50134        that temporarily disabled touch-scrolling.
50135        * rendering/RenderLayerCompositor.cpp:
50136        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer): When we
50137        update scrolling nodes, send in the right scrolling geometry.
50138
501392014-03-26  Timothy Hatcher  <timothy@apple.com>
50140
50141        Modernize the loops in InspectorPageAgent.cpp.
50142
50143        Also moves the check for hiddenFromInspector to a lower level.
50144        This hides hidden resources from more places.
50145
50146        https://bugs.webkit.org/show_bug.cgi?id=130803
50147
50148        Reviewed by Joseph Pecoraro.
50149
50150        * inspector/InspectorPageAgent.cpp:
50151        (WebCore::buildArrayForCookies):
50152        (WebCore::cachedResourcesForFrame):
50153        (WebCore::allResourcesURLsForFrame):
50154        (WebCore::InspectorPageAgent::getCookies):
50155        (WebCore::InspectorPageAgent::searchInResources):
50156        (WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
50157        (WebCore::InspectorPageAgent::loaderDetachedFromFrame):
50158        (WebCore::InspectorPageAgent::buildObjectForFrameTree):
50159
501602014-03-26  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
50161
50162        Add platform implementation for RTCOfferAnswerOptions and RTCOfferOptions
50163        https://bugs.webkit.org/show_bug.cgi?id=130689
50164
50165        Reviewed by Eric Carlson.
50166
50167        RTCOfferAnswerOptions and RTCOfferOptions objects were being passed to platform class, causing a layer
50168        violation.
50169
50170        * Modules/mediastream/RTCOfferAnswerOptions.cpp:
50171        (WebCore::RTCOfferAnswerOptions::initialize):
50172        (WebCore::RTCOfferOptions::initialize):
50173        * Modules/mediastream/RTCOfferAnswerOptions.h:
50174        (WebCore::RTCOfferAnswerOptions::requestIdentity):
50175        (WebCore::RTCOfferAnswerOptions::privateOfferAnswerOptions):
50176        (WebCore::RTCOfferAnswerOptions::RTCOfferAnswerOptions):
50177        (WebCore::RTCOfferOptions::offerToReceiveVideo):
50178        (WebCore::RTCOfferOptions::offerToReceiveAudio):
50179        (WebCore::RTCOfferOptions::voiceActivityDetection):
50180        (WebCore::RTCOfferOptions::iceRestart):
50181        (WebCore::RTCOfferOptions::privateOfferOptions):
50182        (WebCore::RTCOfferOptions::RTCOfferOptions):
50183        * Modules/mediastream/RTCPeerConnection.cpp:
50184        (WebCore::RTCPeerConnection::createOffer):
50185        (WebCore::RTCPeerConnection::createAnswer):
50186        * platform/mediastream/RTCOfferAnswerOptionsPrivate.h: Added.
50187        * platform/mediastream/RTCPeerConnectionHandler.h:
50188        * platform/mock/RTCPeerConnectionHandlerMock.cpp:
50189        (WebCore::RTCPeerConnectionHandlerMock::createOffer):
50190        (WebCore::RTCPeerConnectionHandlerMock::createAnswer):
50191        * platform/mock/RTCPeerConnectionHandlerMock.h:
50192
501932014-03-26  Zalan Bujtas  <zalan@apple.com>
50194
50195        Device scale factor should always be greater than 0.
50196        https://bugs.webkit.org/show_bug.cgi?id=130798
50197
50198        Reviewed by David Kilzer.
50199
50200        Rendering context requires a device scale factor > 0 so that we can map CSS pixels
50201        to device pixels properly. Neither 0 nor a negative device pixel ratio are considered to be valid.
50202
50203        * page/Page.cpp:
50204        (WebCore::Page::setDeviceScaleFactor):
50205
502062014-03-26  Myles C. Maxfield  <mmaxfield@apple.com>
50207
50208        Skipping underlines disregard points completely inside the underline rect
50209        https://bugs.webkit.org/show_bug.cgi?id=130800
50210
50211        Reviewed by Dean Jackson.
50212
50213        When determining bounds for underline skipping, endpoints of glyph contours
50214        that lie entirely within the rect of the underline are ignored. This patch
50215        makes these points affect the skipping regions the same way that intersections
50216        do.
50217
50218        Test: fast/css3-text/css3-text-decoration/text-decoration-skip/glyph-inside-underline.html
50219
50220        * platform/graphics/mac/FontMac.mm:
50221        (WebCore::updateX): Refactored common code into a function
50222        (WebCore::findPathIntersections): Test for endpoints which lie entirely within
50223        the underline bounds
50224
502252014-03-26  Pratik Solanki  <psolanki@apple.com>
50226
50227        Unreviewed. iOS build fix after r166312. Soft link CMTimeRangeGetEnd.
50228
50229        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
50230
502312014-03-26  Timothy Hatcher  <timothy@apple.com>
50232
50233        Propagate the hiddenFromInspector flag on ResourceRequest in
50234        places when a new request a made or passed between processes.
50235
50236        https://bugs.webkit.org/show_bug.cgi?id=130741
50237
50238        Reviewed by Joseph Pecoraro.
50239
50240        * WebCore.exp.in: Updated symbols for updateFromDelegatePreservingOldProperties.
50241        * platform/network/cf/ResourceRequest.h:
50242        * platform/network/cf/ResourceRequestCFNet.cpp:
50243        (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
50244        (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
50245        * platform/network/curl/ResourceRequest.h:
50246        (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
50247        (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
50248        * platform/network/mac/ResourceRequestMac.mm:
50249        (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
50250        (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
50251        * platform/network/soup/ResourceRequest.h:
50252        (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): Added.
50253        (WebCore::ResourceRequest::updateFromDelegatePreservingOldHTTPBody): Deleted.
50254
502552014-03-26  Zoltan Horvath  <zoltan@webkit.org>
50256
50257        [CSS Shapes] Remove no-longer-used shape-inside geometry code
50258        https://bugs.webkit.org/show_bug.cgi?id=130740
50259
50260        Reviewed by David Hyatt.
50261
50262        This patch removes shape-padding support, since it can be used only with shape-inside.
50263        Shape-inside support has been removed in r166301.
50264
50265        No new tests needed, existing tests have been removed by r166301.
50266
50267        * rendering/shapes/BoxShape.cpp:
50268        (WebCore::BoxShape::shapePaddingLogicalBoundingBox): Deleted.
50269        (WebCore::BoxShape::shapePaddingBounds): Deleted.
50270        (WebCore::BoxShape::getIncludedIntervals): Deleted.
50271        (WebCore::BoxShape::firstIncludedIntervalLogicalTop): Deleted.
50272        * rendering/shapes/BoxShape.h:
50273        * rendering/shapes/PolygonShape.cpp:
50274        (WebCore::leftSide): Deleted.
50275        (WebCore::isReflexVertex): Deleted.
50276        (WebCore::computeShapePaddingBounds): Deleted.
50277        (WebCore::PolygonShape::shapePaddingBounds): Deleted.
50278        (WebCore::PolygonShape::getIncludedIntervals): Deleted.
50279        (WebCore::firstFitRectInPolygon): Deleted.
50280        (WebCore::aboveOrToTheLeft): Deleted.
50281        (WebCore::PolygonShape::firstIncludedIntervalLogicalTop): Deleted.
50282        * rendering/shapes/PolygonShape.h:
50283        (WebCore::PolygonShape::PolygonShape):
50284        * rendering/shapes/RasterShape.cpp:
50285        (WebCore::RasterShapeIntervals::firstIncludedIntervalY): Deleted.
50286        (WebCore::RasterShapeIntervals::getIncludedIntervals): Deleted.
50287        (WebCore::RasterShape::paddingIntervals): Deleted.
50288        (WebCore::RasterShape::getIncludedIntervals): Deleted.
50289        (WebCore::RasterShape::firstIncludedIntervalLogicalTop): Deleted.
50290        * rendering/shapes/RasterShape.h:
50291        * rendering/shapes/RectangleShape.cpp:
50292        (WebCore::ellipseYIntercept): Deleted.
50293        (WebCore::RectangleShape::shapePaddingBounds): Deleted.
50294        (WebCore::RectangleShape::getIncludedIntervals): Deleted.
50295        (WebCore::cornerInterceptForWidth): Deleted.
50296        (WebCore::RectangleShape::firstIncludedIntervalLogicalTop): Deleted.
50297        * rendering/shapes/RectangleShape.h:
50298        * rendering/shapes/Shape.cpp:
50299        (WebCore::Shape::createShape):
50300        (WebCore::Shape::createRasterShape):
50301        (WebCore::Shape::createBoxShape):
50302        * rendering/shapes/Shape.h:
50303        (WebCore::Shape::lineOverlapsShapePaddingBounds): Deleted.
50304        (WebCore::Shape::shapePadding): Deleted.
50305        * rendering/shapes/ShapeInfo.cpp:
50306        (WebCore::ShapeInfo<RenderType>::computedShape):
50307        * rendering/style/RenderStyle.cpp:
50308        (WebCore::RenderStyle::changeRequiresLayout):
50309        * rendering/style/RenderStyle.h:
50310        * rendering/style/StyleRareNonInheritedData.cpp:
50311        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
50312        (WebCore::StyleRareNonInheritedData::operator==):
50313        * rendering/style/StyleRareNonInheritedData.h:
50314
503152014-03-26  Jeremy Jones  <jeremyj@apple.com>
50316
50317        Implement hasLiveStreamingContent property in WebAVPlayerController
50318        https://bugs.webkit.org/show_bug.cgi?id=128684
50319
50320        Reviewed by Simon Fraser.
50321
50322        * WebCore.exp.in:
50323        Add export for WebVideoFullscreenInterfaceAVKit::setSeekableRanges().
50324
50325        * platform/ios/WebVideoFullscreenInterface.h:
50326        Add setSeekableRanges()
50327
50328        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
50329        Add setSeekableRanges()
50330
50331        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
50332        Remove vestigial playerLayer property. Add seekableTimeRanges property.
50333
50334        (-[WebAVPlayerController dealloc]):
50335        Release _seekableTimeRanges.
50336        Remove references to _playerLayer.
50337
50338        (-[WebAVPlayerController hasLiveStreamingContent]):
50339        Implement based on duration. Live stream has an infinite duration.
50340
50341        (+[WebAVPlayerController keyPathsForValuesAffectingHasLiveStreamingContent]):
50342        Describe dependent keys for computed property hasLiveStreamingContent.
50343
50344        (-[WebAVPlayerController skipBackwardThirtySeconds:]):
50345        Seek back 30 seconds if that time is in the seekable ranges.
50346
50347        (-[WebAVPlayerController gotoEndOfSeekableRanges:]):
50348        Jump to live by going to the of the seekable ranges.
50349
50350        (WebVideoFullscreenInterfaceAVKit::setSeekableRanges):
50351        Convert TimeRange to CMTimeRange.
50352
50353        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
50354        (WebVideoFullscreenModelMediaElement::setMediaElement):
50355        Set initial seekable ranges.
50356
50357        (WebVideoFullscreenModelMediaElement::handleEvent):
50358        Update seekable ranges when time changes.
50359
503602014-03-26  Brent Fulgham  <bfulgham@apple.com>
50361
50362        Fix OS X build.
50363
50364        * WebCore.exp.in: Add missing export symbol.
50365
503662014-03-26  Simon Fraser  <simon.fraser@apple.com>
50367
50368        Fix the Windows build. Add a no-op impl for Mac non-UI-side.
50369
50370        * platform/graphics/ca/mac/PlatformCALayerMac.h:
50371        * platform/graphics/ca/win/PlatformCALayerWin.cpp:
50372        (PlatformCALayerWin::PlatformCALayerWin):
50373        * platform/graphics/ca/win/PlatformCALayerWin.h:
50374
503752014-03-26  Simon Fraser  <simon.fraser@apple.com>
50376
50377        REGRESSION (r155977): matrix animations no longer animate
50378        https://bugs.webkit.org/show_bug.cgi?id=130789
50379        <rdar://problem/15650946>
50380
50381        Reviewed by Dean Jackson.
50382        
50383        r155977 erroneously removed two lines that set the end points for
50384        matrix animations (used when transform lists don't match), so
50385        put them back.
50386        
50387        Also don't repaint when updateContentsScale()
50388        is called and doesn't change the contents scale.
50389
50390        Test: compositing/animation/matrix-animation.html
50391
50392        * platform/graphics/ca/GraphicsLayerCA.cpp:
50393        (WebCore::GraphicsLayerCA::updateRootRelativeScale):
50394        (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints):
50395        (WebCore::GraphicsLayerCA::updateContentsScale):
50396
503972014-03-26  Simon Fraser  <simon.fraser@apple.com>
50398
50399        Add a custom behavior flag to GraphicsLayer, piped down to PlatformCALayer, for scrolling layers
50400        https://bugs.webkit.org/show_bug.cgi?id=130778
50401
50402        Reviewed by Tim Horton.
50403
50404        Make it possible to put a "custom behavior" flag on a layer so that,
50405        with UI-side compositing, we know to create a specific type of
50406        layer or view for that GraphicsLayer.
50407
50408        * WebCore.exp.in:
50409        * platform/graphics/GraphicsLayer.cpp:
50410        (WebCore::GraphicsLayer::GraphicsLayer):
50411        * platform/graphics/GraphicsLayer.h:
50412        (WebCore::GraphicsLayer::setCustomBehavior):
50413        (WebCore::GraphicsLayer::customBehavior):
50414        * platform/graphics/ca/GraphicsLayerCA.cpp:
50415        (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
50416        (WebCore::GraphicsLayerCA::updateCustomBehavior):
50417        (WebCore::GraphicsLayerCA::setCustomBehavior):
50418        * platform/graphics/ca/GraphicsLayerCA.h:
50419        * platform/graphics/ca/PlatformCALayer.h:
50420        * platform/graphics/ca/mac/PlatformCALayerMac.h:
50421        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
50422        (PlatformCALayerMac::PlatformCALayerMac):
50423        * rendering/RenderLayerBacking.cpp:
50424        (WebCore::RenderLayerBacking::updateScrollingLayers):
50425
504262014-03-26  Brent Fulgham  <bfulgham@apple.com>
50427
50428        Unreviewed test correction.
50429
50430        Because of the way DRT on Windows links to WebCore, having the implementaion of the update
50431        method in the header caused a runtime failure due to duplicate symbols being bound to the
50432        compilation unit.
50433
50434        * accessibility/AXObjectCache.cpp:
50435        (WebCore::AXObjectCache::setEnhancedUserInterfaceAccessibility): Moved from header.
50436        * accessibility/AXObjectCache.h:
50437        (WebCore::AXObjectCache::setEnhancedUserInterfaceAccessibility): Deleted.
50438
504392014-03-26  Jer Noble  <jer.noble@apple.com>
50440
50441        REGRESSION(r162679): Poster image visible under the video
50442        https://bugs.webkit.org/show_bug.cgi?id=130783
50443
50444        Reviewed by Simon Fraser.
50445
50446        In the listed revision, we started checking for isRenderImage()
50447        instead of isImage(). RenderMedias return 'true' for the first
50448        but 'false' for the second. Change the if() statement to check
50449        for isRenderMedia() in addition to !isRenderImage().
50450
50451        * rendering/RenderLayerBacking.cpp:
50452        (WebCore::RenderLayerBacking::isDirectlyCompositedImage):
50453
504542014-03-26  Antti Koivisto  <antti@apple.com>
50455
50456        Render tree construction is O(N^2) in number of siblings
50457        https://bugs.webkit.org/show_bug.cgi?id=129065
50458
50459        Reviewed by Darin Adler.
50460        
50461        When adding a new renderer to the tree we would search for the correct render tree
50462        position by traversing DOM children forward to find something that already has a renderer.
50463        In common case there is no such renderer. This would be repeated for each inserted renderer
50464        leading to O(n^2) in respect to child node count.
50465        
50466        This patch caches the computed render tree insertion position and passes it to siblings.
50467        Until the cached position is reached it can be used for all new renderers.
50468
50469        Test: perf/sibling-renderer-On2.html
50470
50471        * style/StyleResolveTree.cpp:
50472        (WebCore::Style::RenderTreePosition::parent):
50473        (WebCore::Style::RenderTreePosition::RenderTreePosition):
50474        (WebCore::Style::RenderTreePosition::canInsert):
50475        (WebCore::Style::RenderTreePosition::insert):
50476        (WebCore::Style::RenderTreePosition::computeNextSibling):
50477        (WebCore::Style::RenderTreePosition::invalidateNextSibling):
50478        (WebCore::Style::styleForElement):
50479        (WebCore::Style::elementInsideRegionNeedsRenderer):
50480        (WebCore::Style::createRendererIfNeeded):
50481        (WebCore::Style::createTextRendererIfNeeded):
50482        (WebCore::Style::attachTextRenderer):
50483        (WebCore::Style::updateTextRendererAfterContentChange):
50484        (WebCore::Style::attachChildren):
50485        (WebCore::Style::attachDistributedChildren):
50486        (WebCore::Style::attachShadowRoot):
50487        (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded):
50488        (WebCore::Style::attachRenderTree):
50489        (WebCore::Style::resolveLocal):
50490        (WebCore::Style::resolveTextNode):
50491        (WebCore::Style::resolveShadowTree):
50492        (WebCore::Style::updateBeforeOrAfterPseudoElement):
50493        (WebCore::Style::resolveTree):
50494
504952014-03-26  Commit Queue  <commit-queue@webkit.org>
50496
50497        Unreviewed, rolling out r166264.
50498        https://bugs.webkit.org/show_bug.cgi?id=130785
50499
50500        Broke some window.opener tests for WK2 Mavericks (Requested by
50501        brrian__ on #webkit).
50502
50503        Reverted changeset:
50504
50505        "Web Replay: resource unique identifiers should be unique-per-
50506        frame, not globally"
50507        https://bugs.webkit.org/show_bug.cgi?id=130632
50508        http://trac.webkit.org/changeset/166264
50509
505102014-03-26  Zoltan Horvath  <zoltan@webkit.org>
50511
50512        [CSS Shapes] Remove shape-inside support
50513        https://bugs.webkit.org/show_bug.cgi?id=130698
50514
50515        Reviewed by David Hyatt.
50516
50517        CSS Shapes Level 1 (CR) only contains shape-outside. We are focusing our efforts on finalizing
50518        the implementation of shape-outside, it's worth to remove shape-inside code at this point for now.
50519
50520        A list of reasons for the removal:
50521          - Shape-inside is only part of Shapes Level 2, which needs to be improved on some topics.
50522          - Shape-inside is lack of new shapes support (e.g. inset).
50523          - Deprecated shapes (r165472) are removed from the code (e.g. rectangle), which affects shape-inside. 
50524          - The current shape-inside code spreads across the layout code.
50525          - The current shape-inside implementation is experimental in some areas,
50526            and the partially implemented code can have security implications.
50527          - Removal of shape-inside opens possibilities for code complexity and performance
50528            optimizations for shape-outside. (e.g. simpler geometry code)
50529
50530        No new tests are needed.
50531
50532        * CMakeLists.txt:
50533        * Configurations/FeatureDefines.xcconfig:
50534        * GNUmakefile.list.am:
50535        * WebCore.xcodeproj/project.pbxproj:
50536        * css/CSSComputedStyleDeclaration.cpp:
50537        (WebCore::ComputedStyleExtractor::propertyValue):
50538        * css/CSSParser.cpp:
50539        (WebCore::isSimpleLengthPropertyID):
50540        (WebCore::CSSParser::parseValue):
50541        (WebCore::CSSParser::parseShapeProperty):
50542        * css/CSSPropertyNames.in:
50543        * css/DeprecatedStyleBuilder.cpp:
50544        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
50545        * css/StyleResolver.cpp:
50546        (WebCore::StyleResolver::applyProperty):
50547        (WebCore::StyleResolver::loadPendingImages):
50548        * page/animation/CSSPropertyAnimation.cpp:
50549        (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
50550        * rendering/LayoutState.cpp:
50551        (WebCore::LayoutState::LayoutState):
50552        * rendering/LayoutState.h:
50553        (WebCore::LayoutState::LayoutState):
50554        (WebCore::LayoutState::shapeInsideInfo): Deleted.
50555        * rendering/RenderBlock.cpp:
50556        (WebCore::RenderBlock::styleDidChange):
50557        (WebCore::RenderBlock::imageChanged):
50558        (WebCore::RenderBlock::preparePaginationBeforeBlockLayout):
50559        (WebCore::RenderBlock::relayoutShapeDescendantIfMoved): Deleted.
50560        (WebCore::RenderBlock::logicalOffsetFromShapeAncestorContainer): Deleted.
50561        (WebCore::RenderBlock::updateShapeInsideInfoAfterStyleChange): Deleted.
50562        (WebCore::RenderBlock::ensureShapeInsideInfo): Deleted.
50563        (WebCore::RenderBlock::shapeInsideInfo): Deleted.
50564        (WebCore::RenderBlock::setShapeInsideInfo): Deleted.
50565        (WebCore::RenderBlock::markShapeInsideDescendantsForLayout): Deleted.
50566        (WebCore::RenderBlock::layoutShapeInsideInfo): Deleted.
50567        (WebCore::shapeInfoRequiresRelayout): Deleted.
50568        (WebCore::RenderBlock::computeShapeSize): Deleted.
50569        (WebCore::RenderBlock::updateShapesBeforeBlockLayout): Deleted.
50570        (WebCore::RenderBlock::updateShapesAfterBlockLayout): Deleted.
50571        (WebCore::RenderBlock::prepareShapesAndPaginationBeforeBlockLayout): Deleted.
50572        * rendering/RenderBlock.h:
50573        (WebCore::RenderBlock::allowsShapeInsideInfoSharing): Deleted.
50574        * rendering/RenderBlockFlow.cpp:
50575        (WebCore::RenderBlockFlow::layoutBlock):
50576        (WebCore::RenderBlockFlow::layoutBlockChild):
50577        (WebCore::RenderBlockFlow::computeLogicalLocationForFloat):
50578        * rendering/RenderBlockFlow.h:
50579        * rendering/RenderBlockLineLayout.cpp:
50580        (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForLine):
50581        (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
50582        (WebCore::constructBidiRunsForLine): Deleted.
50583        (WebCore::pushShapeContentOverflowBelowTheContentBox): Deleted.
50584        (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLine): Deleted.
50585        (WebCore::RenderBlockFlow::updateShapeAndSegmentsForCurrentLineInFlowThread): Deleted.
50586        (WebCore::adjustLogicalLineTop): Deleted.
50587        (WebCore::RenderBlockFlow::adjustLogicalLineTopAndLogicalHeightIfNeeded): Deleted.
50588        * rendering/RenderDeprecatedFlexibleBox.cpp:
50589        (WebCore::RenderDeprecatedFlexibleBox::layoutBlock):
50590        * rendering/RenderElement.cpp:
50591        (WebCore::RenderElement::~RenderElement):
50592        (WebCore::RenderElement::initializeStyle):
50593        (WebCore::RenderElement::setStyle):
50594        * rendering/RenderFlexibleBox.cpp:
50595        (WebCore::RenderFlexibleBox::layoutBlock):
50596        * rendering/RenderGrid.cpp:
50597        (WebCore::RenderGrid::layoutBlock):
50598        * rendering/RenderNamedFlowFragment.cpp:
50599        (WebCore::RenderNamedFlowFragment::createStyle):
50600        * rendering/RenderView.h:
50601        * rendering/SimpleLineLayout.cpp:
50602        (WebCore::SimpleLineLayout::canUseFor):
50603        * rendering/line/BreakingContextInlineHeaders.h:
50604        (WebCore::BreakingContext::handleText):
50605        (WebCore::BreakingContext::handleEndOfLine):
50606        (WebCore::updateSegmentsForShapes): Deleted.
50607        * rendering/line/LineBreaker.cpp:
50608        (WebCore::LineBreaker::nextLineBreak):
50609        * rendering/line/LineWidth.cpp:
50610        (WebCore::LineWidth::LineWidth):
50611        (WebCore::LineWidth::updateAvailableWidth):
50612        (WebCore::LineWidth::wrapNextToShapeOutside):
50613        (WebCore::LineWidth::fitBelowFloats):
50614        (WebCore::LineWidth::updateLineSegment): Deleted.
50615        (WebCore::LineWidth::updateCurrentShapeSegment): Deleted.
50616        * rendering/line/LineWidth.h:
50617        * rendering/shapes/ShapeInsideInfo.cpp: Removed.
50618        * rendering/shapes/ShapeInsideInfo.h: Removed.
50619        * rendering/style/RenderStyle.cpp:
50620        (WebCore::RenderStyle::changeRequiresLayout):
50621        * rendering/style/RenderStyle.h:
50622        * rendering/style/StyleRareNonInheritedData.cpp:
50623        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
50624        (WebCore::StyleRareNonInheritedData::operator==):
50625        * rendering/style/StyleRareNonInheritedData.h:
50626
506272014-03-25  Brent Fulgham  <bfulgham@apple.com>
50628
50629        Avoid duplicate size checks when creating empty image
50630        https://bugs.webkit.org/show_bug.cgi?id=130730
50631
50632        Reviewed by Dean Jackson.
50633
50634        Merged from Blink (patch by ch.dumez@samsung.com):
50635        https://chromium.googlesource.com/chromium/blink/+/4861a71bc1f284fc97417f405ab7d08dc6947b88
50636        http://crbug.com/190633011
50637
50638        * html/canvas/CanvasRenderingContext2D.cpp:
50639        (WebCore::createEmptyImageData): Don't perform overflow calculation twice.
50640
506412014-03-26  Sergio Villar Senin  <svillar@igalia.com>
50642
50643        [CSS Grid Layout] getComputedStyle() must return the specified value for positioning properties
50644        https://bugs.webkit.org/show_bug.cgi?id=130010
50645
50646        Reviewed by Darin Adler.
50647
50648        According to the specs
50649        http://dev.w3.org/csswg/css-grid/#property-index and also to
50650        http://lists.w3.org/Archives/Public/www-style/2014Mar/0162.html
50651        the function getComputedStyle() must return the specified values
50652        for positioning properties, i.e, grid-{columns|rows}-{start|end}.
50653
50654        We were in some cases, adjusting the style in the StyleResolver
50655        (for example with two opposing spans) something that is now done
50656        in the RenderGrid because we cannot alter the original style.
50657
50658        The code moved to the renderer became more self explanatory and it
50659        now supports named grid areas with names ending in "-start" and
50660        "-end".
50661
50662        Test: fast/css-grid-layout/named-grid-lines-with-named-grid-areas-get-set.html
50663
50664        * css/StyleResolver.cpp:
50665        (WebCore::StyleResolver::adjustRenderStyle):
50666        (WebCore::gridLineDefinedBeforeGridArea): Deleted.
50667        (WebCore::StyleResolver::adjustNamedGridItemPosition): Deleted.
50668        (WebCore::StyleResolver::adjustGridItemPosition): Deleted.
50669        * css/StyleResolver.h:
50670        * rendering/RenderGrid.cpp:
50671        (WebCore::isColumnSide):
50672        (WebCore::RenderGrid::explicitGridSizeForSide):
50673        (WebCore::gridLineDefinedBeforeGridArea):
50674        (WebCore::setNamedLinePositionIfDefinedBeforeArea):
50675        (WebCore::RenderGrid::adjustNamedGridItemPosition):
50676        (WebCore::RenderGrid::adjustGridPositionsFromStyle):
50677        (WebCore::RenderGrid::resolveGridPositionsFromStyle):
50678        (WebCore::RenderGrid::resolveNamedGridLinePositionFromStyle):
50679        (WebCore::RenderGrid::resolveNamedGridLinePositionAgainstOppositePosition):
50680        * rendering/RenderGrid.h:
50681        * rendering/style/GridPosition.h:
50682        (WebCore::GridPosition::setAutoPosition): New helper function.
50683
506842014-03-26  Simon Fraser  <simon.fraser@apple.com>
50685
50686        Fix the iOS build.
50687
50688        * WebCore.exp.in:
50689
506902014-03-26  Tim Horton  <timothy_horton@apple.com>
50691
50692        [iOS WebKit2] Flush all surfaces after painting into all of them, instead of after painting into each one
50693        https://bugs.webkit.org/show_bug.cgi?id=130768
50694        <rdar://problem/16421471>
50695
50696        Reviewed by Simon Fraser.
50697
50698        * platform/graphics/cocoa/IOSurface.h:
50699        Add a non-ensuring platformContext() getter.
50700
507012014-03-26  James Craig  <jcraig@apple.com>
50702
50703        Web Inspector: AXI: crash when inspecting "bar" text node in getAccessibilityPropertiesForNode layout test
50704        https://bugs.webkit.org/show_bug.cgi?id=130290
50705
50706        Reviewed by Timothy Hatcher.
50707
50708        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
50709
50710        Fixing regression from r165590. http://webkit.org/b/129779
50711        Verify isElementNode to avoid calling toElement on document or text nodes.
50712
50713        * inspector/InspectorDOMAgent.cpp:
50714        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
50715
507162014-03-25  Sergio Villar Senin  <svillar@igalia.com>
50717
50718        Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in editing/
50719        https://bugs.webkit.org/show_bug.cgi?id=130722
50720
50721        Reviewed by Antti Koivisto.
50722
50723        * editing/AlternativeTextController.cpp:
50724        (WebCore::markerTypesForAutocorrection):
50725        (WebCore::markerTypesForReplacement):
50726        (WebCore::markerTypesForAppliedDictationAlternative):
50727        * editing/EditingStyle.cpp:
50728        (WebCore::htmlElementEquivalents):
50729        (WebCore::htmlAttributeEquivalents):
50730        * editing/FormatBlockCommand.cpp:
50731        (WebCore::isElementForFormatBlock):
50732        * editing/RemoveFormatCommand.cpp:
50733        (WebCore::isElementForRemoveFormatCommand):
50734        * editing/ReplaceSelectionCommand.cpp:
50735        (WebCore::isProhibitedParagraphChild):
50736        * editing/atk/FrameSelectionAtk.cpp:
50737        (WebCore::maybeEmitTextFocusChange):
50738
507392014-03-25  Simon Fraser  <simon.fraser@apple.com>
50740
50741        Add a new type of scrolling tree node for overflow scrolling
50742        https://bugs.webkit.org/show_bug.cgi?id=130763
50743
50744        Reviewed by Tim Horton.
50745
50746        Prepare for overflow scrolling via the scrolling tree by adding
50747        a new scrolling node type for overflow:scroll nodes. Mostly
50748        this is a new ScrollingNodeType that gets mapped to the same
50749        scrolling state nodes and scrolling nodes, but iOS creates
50750        state and scrolling nodes specific to overflow:scroll.
50751        
50752        Change the type checking on nodes to use virtual functions instead
50753        of just checking the node type, to allow the macros to work with
50754        the new scrolling node type.
50755
50756        * WebCore.exp.in:
50757        * page/scrolling/AsyncScrollingCoordinator.cpp:
50758        (WebCore::AsyncScrollingCoordinator::ensureRootStateNodeForFrameView):
50759        * page/scrolling/ScrollingCoordinator.h:
50760        * page/scrolling/ScrollingStateFixedNode.h:
50761        * page/scrolling/ScrollingStateNode.h:
50762        (WebCore::ScrollingStateNode::isFixedNode):
50763        (WebCore::ScrollingStateNode::isStickyNode):
50764        (WebCore::ScrollingStateNode::isScrollingNode):
50765        * page/scrolling/ScrollingStateScrollingNode.cpp:
50766        (WebCore::ScrollingStateScrollingNode::create):
50767        (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
50768        * page/scrolling/ScrollingStateScrollingNode.h:
50769        * page/scrolling/ScrollingStateStickyNode.h:
50770        * page/scrolling/ScrollingStateTree.cpp:
50771        (WebCore::ScrollingStateTree::attachNode):
50772        * page/scrolling/ScrollingTree.cpp:
50773        (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling):
50774        (WebCore::ScrollingTree::updateTreeFromStateNode):
50775        * page/scrolling/ScrollingTreeNode.h:
50776        (WebCore::ScrollingTreeNode::isFixedNode):
50777        (WebCore::ScrollingTreeNode::isStickyNode):
50778        (WebCore::ScrollingTreeNode::isScrollingNode):
50779        * page/scrolling/ScrollingTreeScrollingNode.cpp:
50780        (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
50781        * page/scrolling/ScrollingTreeScrollingNode.h:
50782        * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
50783        (WebCore::ScrollingCoordinatorIOS::createScrollingTreeNode):
50784        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
50785        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
50786        (WebCore::ScrollingTreeScrollingNodeIOS::create):
50787        (WebCore::ScrollingTreeScrollingNodeIOS::ScrollingTreeScrollingNodeIOS):
50788        * page/scrolling/mac/ScrollingCoordinatorMac.mm:
50789        (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode):
50790        * page/scrolling/mac/ScrollingTreeFixedNode.h:
50791        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
50792        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
50793        (WebCore::ScrollingTreeScrollingNodeMac::create):
50794        (WebCore::ScrollingTreeScrollingNodeMac::ScrollingTreeScrollingNodeMac):
50795        * page/scrolling/mac/ScrollingTreeStickyNode.h:
50796        * rendering/RenderLayerCompositor.cpp:
50797        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
50798
507992014-03-26  Krzysztof Czech  <k.czech@samsung.com>
50800
50801        [ATK] Utilize new AtkValue interface coming in ATK 2.11.92
50802        https://bugs.webkit.org/show_bug.cgi?id=130575
50803
50804        Reviewed by Mario Sanchez Prada.
50805
50806        ATK 2.11.92 introduces some new API and deprecates an old one.
50807        Adjust current implementation to meet requirements of the new API.
50808
50809        No new tests. Covered by existing ones.
50810
50811        * accessibility/atk/AXObjectCacheAtk.cpp:
50812        (WebCore::AXObjectCache::postPlatformNotification):
50813        * accessibility/atk/WebKitAccessibleInterfaceValue.cpp:
50814        (webkitAccessibleSetNewValue):
50815        (webkitAccessibleGetIncrementValue):
50816        (webkitAccessibleGetValueAndText):
50817        (webkitAccessibleGetIncrement):
50818        (webkitAccessibleSetValue):
50819        (webkitAccessibleGetRange):
50820        (webkitAccessibleValueSetCurrentValue):
50821        (webkitAccessibleValueGetMinimumIncrement):
50822        (webkitAccessibleValueInterfaceInit):
50823
508242014-03-26  Zan Dobersek  <zdobersek@igalia.com>
50825
50826        Unreviewed. Removing the remaining Automake cruft.
50827
50828        * GNUmakefile.list.am: Removed.
50829
508302014-03-25  Pratik Solanki  <psolanki@apple.com>
50831
50832        iOS build fix. Add missing semicolon.
50833
50834        * editing/cocoa/HTMLConverter.mm:
50835        (HTMLConverter::_addAttachmentForElement):
50836
508372014-03-25  Sam Weinig  <sam@webkit.org>
50838
50839        Speculative iOS build fix.
50840
50841        * editing/cocoa/HTMLConverter.mm:
50842        (HTMLConverter::_addAttachmentForElement):
50843
508442014-03-25  Jer Noble  <jer.noble@apple.com>
50845
50846        [MSE] Duplicate 'seeked' events.
50847        https://bugs.webkit.org/show_bug.cgi?id=130754
50848
50849        Reviewed by Eric Carlson.
50850
50851        Test: media/media-source/media-source-duplicate-seeked.html
50852
50853        During certain seek operations, HTMLMediaElement::finishSeek() can be called re-entrantly due to
50854        the ready state changing as a result of MediaSource::monitorSourceBuffers(). Move this call to the
50855        end of finishSeek() after m_seeking has been cleared.
50856
50857        * html/HTMLMediaElement.cpp:
50858        (WebCore::HTMLMediaElement::parseAttribute):
50859
508602014-03-25  James Craig  <jcraig@apple.com>
50861
50862        Web Inspector: AXI: add support for aria-activedescendant and reconcile UI/testing with parentNode
50863        https://bugs.webkit.org/show_bug.cgi?id=130712
50864
50865        Reviewed by Timothy Hatcher.
50866
50867        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
50868
50869        Support for @aria-activedescendant; code reuse changes w/ parentNode and activeDescendantNode.
50870
50871        * inspector/InspectorDOMAgent.cpp:
50872        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
50873        * inspector/protocol/DOM.json:
50874
508752014-03-25  Sanghyup Lee  <sh53.lee@samsung.com>
50876
50877        When the mouse is upped after dragged out of shadowDOM, it should lose :active.
50878        https://bugs.webkit.org/show_bug.cgi?id=130660
50879
50880        Reviewed by Darin Adler.
50881
50882        This caused a regression after r165037.
50883        When we have to clear :active style of shadow DOM, we should clear host's style.
50884        This patch replaces parentElement() by parentOrShadowHostElement().
50885
50886        * dom/Document.cpp:
50887        (WebCore::Document::updateHoverActiveState):
50888
508892014-03-25  Eric Carlson  <eric.carlson@apple.com>
50890
50891        [Mac] Always retry a failed MediaDocument as a PluginDocument
50892        https://bugs.webkit.org/show_bug.cgi?id=130742
50893
50894        Reviewed by Jer Noble.
50895
50896        * html/HTMLMediaElement.cpp:
50897        (WebCore::HTMLMediaElement::mediaLoadingFailedFatally): If the element is in a media document,
50898            tell it that loading failed so it can retry as a plug-in.
50899
509002014-03-25  Ryosuke Niwa  <rniwa@webkit.org>
50901
50902        Replace HTMLConverter::_stringForNode by propertyValueForNode
50903        https://bugs.webkit.org/show_bug.cgi?id=130711
50904
50905        Reviewed by Sam Weinig.
50906
50907        Replaced all calls to HTMLConverter::_stringForNode by that to propertyValueForNode.
50908
50909        * editing/cocoa/HTMLConverter.mm:
50910        (HTMLConverter::_computedAttributesForElement):
50911        (HTMLConverter::_addAttachmentForElement):
50912        (HTMLConverter::_enterElement):
50913        (HTMLConverter::_addTableForElement):
50914        (HTMLConverter::_addTableCellForElement):
50915        (HTMLConverter::_processElement):
50916        (HTMLConverter::_exitElement):
50917        (HTMLConverter::_processText):
50918        (HTMLConverter::_traverseNode):
50919        (HTMLConverter::_traverseFooterNode):
50920        (HTMLConverter::_stringForNode): Deleted.
50921
509222014-03-25  Pratik Solanki  <psolanki@apple.com>
50923
50924        Attempt to fix iOS build after r166261.
50925
50926        * WebCore.xcodeproj/project.pbxproj: Make SystemSleepListener.h a private header.
50927
509282014-03-21  Jer Noble  <jer.noble@apple.com>
50929
50930        [iOS] Enable caption support in full screen.
50931        https://bugs.webkit.org/show_bug.cgi?id=130603
50932
50933        Reviewed by Eric Carlson.
50934
50935        Add TextTrackRepresentation support to MediaPlayerPrivateAVFoundationObjC.
50936
50937        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
50938        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
50939        (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Add the m_textTrackRepresenationLayer if present.
50940        (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenLayer): Ditto.
50941        (WebCore::MediaPlayerPrivateAVFoundationObjC::requiresTextTrackRepresentation): True, if a m_videoFullscreenLayer is present.
50942        (WebCore::MediaPlayerPrivateAVFoundationObjC::setTextTrackRepresentation): Remove the old, and add the new m_textTrackRepresenationLayer.
50943
50944        Make the text track container a stacking context for painting purposes.
50945        * Modules/mediacontrols/mediaControlsiOS.css:
50946        (video::-webkit-media-text-track-container):
50947
509482014-03-25  Brian Burg  <bburg@apple.com>
50949
50950        Web Replay: resource unique identifiers should be unique-per-frame, not globally
50951        https://bugs.webkit.org/show_bug.cgi?id=130632
50952
50953        Reviewed by Timothy Hatcher.
50954
50955        For replay purposes, we want to deterministically assign resource load identifiers
50956        to resource loaders, provided that the resource loaders are created in the same
50957        order.
50958
50959        To do this, we convert unique identifiers from being globally-unique to being
50960        frame-unique. When a new frame is being loaded, unique identifiers for
50961        subresources of that frame begin counting from 1.
50962
50963        No new tests. Identifier invariants are exercised by existing assertions and tests.
50964
50965        * loader/ProgressTracker.cpp:
50966        (WebCore::ProgressTracker::ProgressTracker):
50967        (WebCore::ProgressTracker::reset):
50968        (WebCore::ProgressTracker::createUniqueIdentifier):
50969        * loader/ProgressTracker.h:
50970
509712014-03-25  Jer Noble  <jer.noble@apple.com>
50972
50973        [Mac] Pause the media element during system sleep.
50974        https://bugs.webkit.org/show_bug.cgi?id=130718
50975
50976        Reviewed by Eric Carlson.
50977
50978        Test: media/video-system-sleep.html
50979
50980        Relying on the platform media system to pause and restart playback during
50981        system sleep can cause problems on some platforms, especially where hardware
50982        decoders are concerned. Rather than implicitly pausing the media during
50983        system sleep, explicitly pause the media before sleeping and resume (if
50984        appropriate) upon waking.
50985
50986        Add a new class to be used for system sleep notifications:
50987        * platform/SystemSleepListener.cpp: Added.
50988        (WebCore::SystemSleepListener::create):
50989        (WebCore::SystemSleepListener::SystemSleepListener):
50990        * platform/SystemSleepListener.h: Added.
50991        (WebCore::SystemSleepListener::Client::~Client):
50992        (WebCore::SystemSleepListener::~SystemSleepListener):
50993        (WebCore::SystemSleepListener::client):
50994
50995        Add a Mac-specific implementation:
50996        * platform/mac/SystemSleepListenerMac.h: Added.
50997        * platform/mac/SystemSleepListenerMac.mm: Added.
50998        (WebCore::SystemSleepListener::create):
50999        (WebCore::SystemSleepListenerMac::SystemSleepListenerMac):
51000        (WebCore::SystemSleepListenerMac::~SystemSleepListenerMac):
51001
51002        Listen for system sleep notifications in MediaSessionManager:
51003        * platform/audio/MediaSessionManager.cpp:
51004        (WebCore::MediaSessionManager::MediaSessionManager):
51005        (WebCore::MediaSessionManager::systemWillSleep):
51006        (WebCore::MediaSessionManager::systemDidWake):
51007        * platform/audio/MediaSessionManager.h:
51008
51009        Drive-by fix; notify the MediaSession that playback will begin
51010        due to autoplay, but do not begin autoplaying if the session
51011        is already interrupted:
51012        * html/HTMLMediaElement.cpp:
51013        (WebCore::HTMLMediaElement::parseAttribute):
51014
51015        Add new files to project:
51016        * WebCore.vcxproj/WebCore.vcxproj:
51017        * WebCore.xcodeproj/project.pbxproj:
51018        * CMakeLists.txt:
51019        * GNUmakefile.list.am:
51020
510212014-03-25  Radu Stavila  <stavila@adobe.com>
51022
51023        [CSS Regions] The background of children of scrollable elements flowed into regions is not properly scrolled
51024        https://bugs.webkit.org/show_bug.cgi?id=130574
51025
51026        Reviewed by David Hyatt.
51027
51028        When computing the clip rect for painting the box decorations, the scrolled content offset
51029        must be computed by going up the containing block tree, up to the region.
51030
51031        Tests: fast/regions/scrollable-region-scrollable-absolute-content-background.html
51032               fast/regions/scrollable-region-scrollable-content-background.html
51033
51034        * rendering/RenderNamedFlowThread.cpp:
51035        (WebCore::RenderNamedFlowThread::decorationsClipRectForBoxInNamedFlowFragment):
51036
510372014-03-25  Joseph Pecoraro  <pecoraro@apple.com>
51038
51039        [iOS] Inspector View Indication Support
51040        https://bugs.webkit.org/show_bug.cgi?id=130709
51041
51042        Reviewed by Simon Fraser.
51043
51044        * inspector/InspectorClient.h:
51045        (WebCore::InspectorClient::showInspectorIndication):
51046        (WebCore::InspectorClient::hideInspectorIndication):
51047        * inspector/InspectorController.cpp:
51048        (WebCore::InspectorController::setIndicating):
51049        Rename indicate/hideIndication to show/hide names.
51050
510512014-03-25  Brent Fulgham  <bfulgham@apple.com>
51052
51053        Unreviewed build fix. Typo on checkin.
51054
51055        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
51056        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Left an unmatched open bracket.
51057
510582014-03-25  Jer Noble  <jer.noble@apple.com>
51059
51060        Even further unreviewed build fix after r166247. Unprotect the implementation of HTMLMediaElement::shouldDisableSleep().
51061
51062        * html/HTMLMediaElement.cpp:
51063        (WebCore::HTMLMediaElement::parseAttribute):
51064
510652014-03-25  Jer Noble  <jer.noble@apple.com>
51066
51067        Further unreviewed build fix after r166247. Add DisplaySleepDisabler to the windows project file and
51068        move the definition of DisplaySleepDisabler's constructor and destructor into the cpp file.
51069
51070        * WebCore.vcxproj/WebCore.vcxproj:
51071        * platform/DisplaySleepDisabler.cpp:
51072        (WebCore::DisplaySleepDisabler::DisplaySleepDisabler):
51073        (WebCore::DisplaySleepDisabler::~DisplaySleepDisabler):
51074        * platform/DisplaySleepDisabler.h:
51075
510762014-03-25  Jer Noble  <jer.noble@apple.com>
51077
51078        Unreviewed build fix after r166247. Un-platform-protect the declaration of HTMLMediaElement::shouldDisableSleep()
51079        and make WebVideoFullscreenController's _displaySleepDisabler a std::unique_ptr.
51080
51081        * html/HTMLMediaElement.h:
51082        * platform/mac/WebVideoFullscreenController.h:
51083
510842014-03-25  Brent Fulgham  <bfulgham@apple.com>
51085
51086        [iOS] Pass additional options to AVFoundation during playback.
51087        https://bugs.webkit.org/show_bug.cgi?id=130624
51088
51089        Reviewed by Eric Carlson.
51090
51091        * html/HTMLMediaElement.cpp:
51092        (WebCore::HTMLMediaElement::doesHaveAttribute): Return attribute value if the user
51093        passes a pointer to fill in.
51094        * html/HTMLMediaElement.h:
51095        * platform/graphics/MediaPlayer.cpp:
51096        (WebCore::MediaPlayer::doesHaveAttribute):
51097        * platform/graphics/MediaPlayer.h:
51098        (WebCore::MediaPlayerClient::doesHaveAttribute):
51099        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
51100        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Pass additional
51101        option if supplied by user.
51102
511032014-03-25  Michael Saboff  <msaboff@apple.com>
51104
51105        Unreviewed, rolling out r166070.
51106
51107        Rollout r166070 due to 2% performance loss in page load times
51108
51109        Reverted changeset:
51110
51111        "Change CodeGeneratorJS.pm special cases for "DOMWindow" to be
51112        general purpose"
51113        https://bugs.webkit.org/show_bug.cgi?id=130553
51114        http://trac.webkit.org/changeset/166070
51115
511162014-03-25  Michael Saboff  <msaboff@apple.com>
51117
51118        Unreviewed, rolling out r166126.
51119
51120        Rollout r166126 in prepartion to roll out prerequisite r166070
51121
51122        Reverted changeset:
51123
51124        "toThis() on a JSWorkerGlobalScope should return a JSProxy and
51125        not undefined"
51126        https://bugs.webkit.org/show_bug.cgi?id=130554
51127        http://trac.webkit.org/changeset/166126
51128
511292014-03-25  Jer Noble  <jer.noble@apple.com>
51130
51131        [iOS] Playing video does not disable display sleep.
51132        https://bugs.webkit.org/show_bug.cgi?id=130729
51133
51134        Reviewed by Eric Carlson.
51135
51136        DisplaySleepDisabler was broken by r161589, which replaced the iOS implementation with
51137        an empty one. Make a platform independent version with a Cocoa-platform subclass. Update
51138        the APIs to non-deprecated ones.
51139
51140        * platform/DisplaySleepDisabler.cpp: Added.
51141        (WebCore::DisplaySleepDisabler::create):
51142        * platform/DisplaySleepDisabler.h: Added.
51143        (WebCore::DisplaySleepDisabler::~DisplaySleepDisabler):
51144        (WebCore::DisplaySleepDisabler::DisplaySleepDisabler):
51145        * platform/cocoa/DisplaySleepDisablerCocoa.cpp: Renamed from Source/WebCore/platform/mac/DisplaySleepDisabler.cpp.
51146        (WebCore::DisplaySleepDisabler::create):
51147        (WebCore::DisplaySleepDisablerCocoa::DisplaySleepDisablerCocoa):
51148        (WebCore::DisplaySleepDisablerCocoa::~DisplaySleepDisablerCocoa):
51149        * platform/cocoa/DisplaySleepDisablerCocoa.h: Renamed from Source/WebCore/platform/mac/DisplaySleepDisabler.h.
51150
51151        Update m_sleepDisabler to be a std::unique_ptr, and unprotect the definition of methods which use it.
51152        * html/HTMLMediaElement.cpp:
51153        (WebCore::HTMLMediaElement::updateSleepDisabling):
51154        (WebCore::HTMLMediaElement::shouldDisableSleep):
51155        * html/HTMLMediaElement.h:
51156
51157        Add the new and renamed files to the project:
51158        * CMakeLists.txt:
51159        * GNUmakefile.list.am:
51160        * WebCore.xcodeproj/project.pbxproj:
51161
511622014-03-25  Dirk Schulze  <krit@webkit.org>
51163
51164        Implement ImageData constructors and WebWorkers exposure
51165        https://bugs.webkit.org/show_bug.cgi?id=130668
51166
51167        Reviewed by Dean Jackson.
51168
51169        Add new constructors for ImageData.
51170
51171        http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#pixel-manipulation
51172
51173        Test: fast/canvas/canvas-imageData.html
51174
51175        * html/ImageData.cpp: 
51176        (WebCore::ImageData::create):
51177        * html/ImageData.h:
51178        * html/ImageData.idl:
51179
511802014-03-25  Myles C. Maxfield  <mmaxfield@apple.com>
51181
51182        InlineIterator position (unsigned int) variable can wrap around
51183        https://bugs.webkit.org/show_bug.cgi?id=130540
51184
51185        Reviewed by Simon Fraser.
51186
51187        We trigger an ASSERT that occurs when we are ignoring spaces (to collapse them
51188        into a single whitespace mark) but then encounter a line break. Because we don't ignore
51189        the first space (but do ignore subsequent spaces), when we hit a newline in an RTL context
51190        we want to ignore that first space as well (so as not to push the text away from the right
51191        edge). We do this by decrementing the InlineIterator pointing to this first space, so all
51192        the spaces get ignored. However, if that space is the first character in a Text node, the
51193        decrement will try to go past the beginning of the node, and trigger an ASSERT.
51194
51195        This design is not great. At some point we should rework it to more elegantly handle
51196        collapsing whitespace in both RTL and LTR writing modes.
51197
51198        This patch adds an ASSERT earlier in this codepath to catch potential problems earlier.
51199        It also pulls our sentinel value out into a separate boolean to make it more clear what is
51200        going on.
51201
51202        Test: fast/text/whitespace-only-text-in-rtl.html
51203
51204        * rendering/InlineIterator.h:
51205        (WebCore::InlineIterator::moveTo): Use the set***() calls
51206        (WebCore::InlineIterator::setOffset): ASSERT early that our math hasn't wrapped
51207        * rendering/RenderBlockLineLayout.cpp:
51208        (WebCore::RenderBlockFlow::appendRunsForObject): Use new boolean value
51209        * rendering/line/BreakingContextInlineHeaders.h:
51210        (WebCore::BreakingContext::handleText): Guard against wraps
51211        (WebCore::checkMidpoints): Use new boolean value
51212        * rendering/line/TrailingObjects.cpp:
51213        (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): Use new boolean value
51214
512152014-03-25  Martin Robinson  <mrobinson@igalia.com>
51216
51217        [GTK] Remove the autotools build
51218        https://bugs.webkit.org/show_bug.cgi?id=130717
51219
51220        Reviewed by Anders Carlsson.
51221
51222        * GNUmakefile.am: Removed.
51223        * bindings/gobject/GNUmakefile.am: Removed.
51224        * config.h: Removed references to autotools configure file.
51225
512262014-03-24  Brent Fulgham  <bfulgham@apple.com>
51227
51228        Prevent 'removetrack' events from firing when all inband text tracks are removed.
51229        https://bugs.webkit.org/show_bug.cgi?id=130704
51230
51231        Reviewed by Eric Carlson.
51232
51233        Test: media/track/track-remove-track.html
51234
51235        Based on the Blink change (patch by acolwell@chromium.org):
51236        https://codereview.chromium.org/177243018/
51237
51238        * html/HTMLMediaElement.cpp:
51239        (WebCore::HTMLMediaElement::prepareForLoad): Reorder steps to match W3C specification.
51240        (WebCore::HTMLMediaElement::noneSupported): Forget tracks as required by specification.
51241        (WebCore::HTMLMediaElement::mediaLoadingFailed): Forget tracks as required by specification.
51242        (WebCore::HTMLMediaElement::removeTextTrack): Only request the 'removetracks' event if
51243        requested by caller.
51244        (WebCore::HTMLMediaElement::removeAllInbandTracks): Renamed to 'forgetResourceSpecificTracks'
51245        (WebCore::HTMLMediaElement::noneSupported): Specify that we want the 'removetracks' event
51246        fired for this use case.
51247        (WebCore::HTMLMediaElement::prepareForLoad): Switch to new 'forgetResourceSpecificTracks' name.
51248        * html/HTMLMediaElement.h:
51249        * html/track/TextTrackList.cpp:
51250        (TextTrackList::remove): Only fire the 'removetrack' event if the caller requests it.
51251        * html/track/TextTrackList.h: Add default argument to fire the 'removetrack' event
51252        when removing a track.
51253        * html/track/TrackListBase.cpp:
51254        (TrackListBase::remove): Only fire the 'removetrack' event if the caller requests it.
51255        * html/track/TrackListBase.h: Add default argument to fire the 'removetrack' event.
51256
512572014-03-25  David Kilzer  <ddkilzer@apple.com>
51258
51259        Hold a reference to firstSuccessfulSubmitButton in HTMLFormElement::submit
51260        <http://webkit.org/b/130713>
51261        <rdar://problem/15661876>
51262
51263        Reviewed by Darin Adler.
51264
51265        Merged from Blink (patch by Ian Beer):
51266        http://crbug.com/303657
51267        https://src.chromium.org/viewvc/blink?view=rev&revision=158938
51268
51269        Test: fast/forms/form-submission-crash-successful-submit-button.html
51270
51271        * html/HTMLFormElement.cpp:
51272        (WebCore::HTMLFormElement::submit):
51273
512742014-03-25  Gabor Rapcsanyi  <rgabor@webkit.org>
51275
51276        [ARM64] GNU assembler fails in TransformationMatrix::multiply
51277        https://bugs.webkit.org/show_bug.cgi?id=130454
51278
51279        Reviewed by Zoltan Herczeg.
51280
51281        Change the NEON intstructions to the proper style.
51282
51283        * platform/graphics/transforms/TransformationMatrix.cpp:
51284        (WebCore::TransformationMatrix::multiply):
51285
512862014-03-20  Sergio Villar Senin  <svillar@igalia.com>
51287
51288        [CSS Grid Layout] Vertical rectangles not considered as valid grid areas
51289        https://bugs.webkit.org/show_bug.cgi?id=130513
51290
51291        Reviewed by Andreas Kling.
51292
51293        Grid areas sized as vertical rectangles were incorrectly
51294        considered as invalid by the parser. That's because the condition
51295        checking that each new row was adjacent to the previous one was
51296        using the first row of the currently parsed grid area instead of
51297        the last one.
51298
51299        Test: fast/css-grid-layout/grid-template-areas-get-set.html
51300
51301        * css/CSSParser.cpp:
51302        (WebCore::CSSParser::parseGridTemplateAreas):
51303
513042014-03-25  Xabier Rodriguez Calvar  <calvaris@igalia.com>
51305
51306        [GTK] Volume slider shows below the panel with videos in certain cases
51307        https://bugs.webkit.org/show_bug.cgi?id=130608
51308
51309        Reviewed by Jer Noble.
51310
51311        We need to delay the moment we check if the volume slider shows up
51312        or down. If the video was not visible, the offsets were 0 and it
51313        was forced to be shown below the panel.
51314
51315        Test: media/video-initially-hidden-volume-slider-up.html
51316
51317        * Modules/mediacontrols/mediaControlsApple.js:
51318        (Controller.prototype.createControls): Moved volumebox pseudo from
51319        the subclass. The test checks for it and it would fail in Mac.
51320        * Modules/mediacontrols/mediaControlsGtk.js:
51321        (ControllerGtk.prototype.createControls): Moved volumebox pseudo
51322        to the superclass.
51323        (ControllerGtk.prototype.handleMuteButtonMouseOver): Check if
51324        volume slider should show up or down.
51325        (ControllerGtk.prototype.updateReadyState): Removed check for
51326        volume slider direction.
51327
513282014-03-24  Brent Fulgham  <bfulgham@apple.com>
51329
51330        [Win] Enable WebVTT Regions on Windows.
51331        https://bugs.webkit.org/show_bug.cgi?id=130680
51332
51333        Reviewed by Eric Carlson.
51334
51335        * DerivedSources.cpp: Add new build components.
51336        * WebCore.vcxproj/WebCore.vcxproj: Ditto.
51337        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
51338
513392014-03-24  Simon Fraser  <simon.fraser@apple.com>
51340
51341        Remove some unnecessary includes from PlatformCALayerClient.h
51342        https://bugs.webkit.org/show_bug.cgi?id=130703
51343
51344        Reviewed by Andreas Kling.
51345        
51346        No need for all these #includes.
51347
51348        * platform/graphics/ca/PlatformCALayerClient.h:
51349
513502014-03-24  Adenilson Cavalcanti  <cavalcantii@gmail.com>
51351
51352        [core] FEGaussianBlur: use IntSize to simplify member function interface
51353        https://bugs.webkit.org/show_bug.cgi?id=130695
51354
51355        Reviewed by Dean Jackson.
51356
51357        By returning an IntSize to store the calculated kernel size values
51358        it is possible to have less function parameters. This patch also
51359        streamlines a bit the code in calculateUnscaledKernelSize.
51360
51361        No new tests, no change in behavior.
51362
51363        * platform/graphics/filters/FEDropShadow.cpp:
51364        (WebCore::FEDropShadow::determineAbsolutePaintRect):
51365        * platform/graphics/filters/FEGaussianBlur.cpp:
51366        (WebCore::FEGaussianBlur::calculateUnscaledKernelSize):
51367        (WebCore::FEGaussianBlur::calculateKernelSize):
51368        (WebCore::FEGaussianBlur::determineAbsolutePaintRect):
51369        (WebCore::FEGaussianBlur::platformApplySoftware):
51370        * platform/graphics/filters/FEGaussianBlur.h:
51371        (if): Deleted.
51372        * platform/graphics/filters/FilterOperations.cpp:
51373        (WebCore::outsetSizeForBlur):
51374
513752014-03-24  Brian Burg  <bburg@apple.com>
51376
51377        Web Replay: capture and replay keyboard events
51378        https://bugs.webkit.org/show_bug.cgi?id=130314
51379
51380        Reviewed by Joseph Pecoraro.
51381
51382        Upstream support for capturing and replaying non-IME keyboard input.
51383        This works similarly to mouse events. It introduces optional fields and
51384        macros to encode/decode them.
51385
51386        Test: ManualTests/inspector/replay-keyboard-events.html
51387
51388        * replay/ReplayInputDispatchMethods.cpp:
51389        (WebCore::HandleKeyPress::dispatch):
51390        * replay/SerializationMethods.cpp:
51391        (JSC::EncodingTraits<NondeterministicInputBase>::encodeValue):
51392        (JSC::EncodingTraits<NondeterministicInputBase>::decodeValue): Switch existing
51393        encode/decode calls to use the shortening macros.
51394        (JSC::EncodingTraits<KeypressCommand>::encodeValue): Added.
51395        (JSC::EncodingTraits<KeypressCommand>::decodeValue): Added.
51396        (JSC::PlatformKeyboardEventAppKit::PlatformKeyboardEventAppKit): Subclass
51397        PlatformKeyboardEvent so that we can set AppKit-specific members not
51398        initialized through the main constructors.
51399        (JSC::EncodingTraits<PlatformKeyboardEvent>::encodeValue): Added.
51400        (JSC::EncodingTraits<PlatformKeyboardEvent>::decodeValue): Added.
51401        * replay/SerializationMethods.h:
51402        * replay/UserInputBridge.cpp:
51403        (WebCore::UserInputBridge::UserInputBridge): initialize m_state inside a guard.
51404        (WebCore::UserInputBridge::handleKeyEvent): fill in the implementation.
51405        * replay/WebInputs.json:
51406
514072014-03-24  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
51408
51409        Optimizing string construction for type error in JSNavigatorCustom.cpp
51410        https://bugs.webkit.org/show_bug.cgi?id=130683
51411
51412        Reviewed by Eric Carlson.
51413
51414        * bindings/js/JSNavigatorCustom.cpp:
51415        (WebCore::JSNavigator::webkitGetUserMedia):
51416
514172014-03-24  Beth Dakin  <bdakin@apple.com>
51418
51419        Legacy-style scrollbars constantly redraw after scrolling
51420        https://bugs.webkit.org/show_bug.cgi?id=130699
51421
51422        Reviewed by Simon Fraser.
51423
51424        The constant re-draw was happening because we were never calling [ScrollbarPainter 
51425        setUsePresentationValue:NO]. This is a silly bug where were should have been 
51426        looking at PlatformWheelEvent::momentumPhase() instead of 
51427        PlatformWheelEvent::phase()
51428
51429        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
51430        (WebCore::ScrollingTreeScrollingNodeMac::handleWheelEvent):
51431
514322014-03-24  Daniel Bates  <dabates@apple.com>
51433
51434        XSS Auditor doesn't block <script> injected before an existing <script>
51435        https://bugs.webkit.org/show_bug.cgi?id=130475
51436
51437        Merged from Blink (patch by Tom Sepez):
51438        https://src.chromium.org/viewvc/blink?view=rev&revision=169697
51439
51440        Tests: http/tests/security/xssAuditor/script-tag-expression-follows.html
51441               http/tests/security/xssAuditor/script-tag-near-start.html
51442
51443        * html/parser/XSSAuditor.cpp:
51444        (WebCore::startsHTMLCommentAt):
51445        (WebCore::startsSingleLineCommentAt):
51446        (WebCore::startsMultiLineCommentAt):
51447        (WebCore::startsOpeningScriptTagAt):
51448        (WebCore::XSSAuditor::decodedSnippetForJavaScript):
51449
514502014-03-24  Brent Fulgham  <bfulgham@apple.com>
51451
51452        Activate WebVTT Tests Once Merging is Complete
51453        https://bugs.webkit.org/show_bug.cgi?id=130420
51454
51455        Reviewed by Eric Carlson.
51456
51457        * Configurations/FeatureDefines.xcconfig: Turn on ENABLE(WEBVTT_REGIONS)
51458
514592014-03-24  Anders Carlsson  <andersca@apple.com>
51460
51461        Re-fix the build.
51462
51463        * WebCore.exp.in:
51464
514652014-03-24  Anders Carlsson  <andersca@apple.com>
51466
51467        Fix build.
51468
51469        * WebCore.exp.in:
51470        Move a CFNetwork only symbol inside the USE(CFNETWORK) section.
51471
514722014-03-24  Chris Fleizach  <cfleizach@apple.com>
51473
51474        Regression: AX: Don't expose role or notifications for invalid menus
51475        https://bugs.webkit.org/show_bug.cgi?id=129814
51476
51477        Reviewed by Mario Sanchez Prada.
51478
51479        If a role=menu has no menuitem children, it should not be a menu.
51480        This was a bit tricky to implement since we need to update the role after the children are created,
51481        but it means we have to be a bit more aggressive about when to updateChildren, so that the role
51482        is known to be valid.
51483
51484        Test: platform/mac/accessibility/invalid-menu-role-does-not-send-notification.html
51485
51486        * accessibility/AXObjectCache.cpp:
51487        (WebCore::AXObjectCache::notificationPostTimerFired):
51488        * accessibility/AccessibilityRenderObject.cpp:
51489        (WebCore::AccessibilityRenderObject::updateRoleAfterChildrenCreation):
51490        (WebCore::AccessibilityRenderObject::addChildren):
51491        * accessibility/AccessibilityRenderObject.h:
51492        * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
51493        (-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):
51494
514952014-03-24  Andy Estes  <aestes@apple.com>
51496
51497        [iOS] Download support by CFURLDownloadRef under USE(CFNETWORK).
51498        https://bugs.webkit.org/show_bug.cgi?id=129322
51499
51500        Reviewed by Anders Carlsson.
51501
51502        * platform/network/ResourceHandle.h:
51503        * platform/network/cf/ResourceHandleCFNet.cpp:
51504        (WebCore::ResourceHandle::releaseConnectionForDownload): Changed to
51505        return a RetainPtr that adopts the connection's retain count.
51506
515072014-03-24  Enrica Casucci  <enrica@apple.com>
51508
51509        Update Hindi fallback font.
51510        https://bugs.webkit.org/show_bug.cgi?id=130690
51511        <rdar://problem/16391601>
51512
51513        Reviewed by Sam Weinig.
51514
51515        Using the new available font for Hindi in the fallback list.
51516
51517        * platform/graphics/ios/FontCacheIOS.mm:
51518        (WebCore::FontCache::systemFallbackForCharacters):
51519
515202014-03-24  Brent Fulgham  <bfulgham@apple.com>
51521
51522        Merge Minor WebVTT Cleanups from Blink
51523        https://bugs.webkit.org/show_bug.cgi?id=130681
51524
51525        Reviewed by Eric Carlson.
51526
51527        Merged from Blink (patch by philipj@opera.com):
51528        https://chromium.googlesource.com/chromium/blink/+/693eb5e2933dca0eab5bbd604e9f3406fe9fd1ab
51529        http://crbug.com/52593009
51530        https://chromium.googlesource.com/chromium/blink/+/40b3602feab34e9be829fd742b6ad6ded322a09f
51531        http://crbug.com/104243003
51532
51533        * html/track/TextTrack.cpp:
51534        (WebCore::TextTrack::setMode):
51535        * html/track/TextTrack.idl:
51536        * html/track/TextTrackCue.h:
51537        * html/track/VTTCue.cpp:
51538        (WebCore::VTTCue::VTTCue):
51539        * html/track/VTTCue.h:
51540
515412014-03-24  Commit Queue  <commit-queue@webkit.org>
51542
51543        Unreviewed, rolling out r166169.
51544        https://bugs.webkit.org/show_bug.cgi?id=130682
51545
51546        This patch broke tests on Apple Mavericks (Requested by fredw
51547        on #webkit).
51548
51549        Reverted changeset:
51550
51551        "Operator stretching: expose a math data API"
51552        https://bugs.webkit.org/show_bug.cgi?id=130572
51553        http://trac.webkit.org/changeset/166169
51554
515552014-03-24  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
51556
51557        ENABLE(CSS_GRID_LAYOUT) guard for CSSGridLineNamesValue
51558        https://bugs.webkit.org/show_bug.cgi?id=130669
51559
51560        Reviewed by Sergio Villar Senin.
51561
51562        No new tests. No new functionality.
51563
51564        * css/CSSGridLineNamesValue.cpp:
51565        * css/CSSGridLineNamesValue.h:
51566
515672014-03-24  Chris Fleizach  <cfleizach@apple.com>
51568
51569        <hr> should expose AXRole/AXSubrole, etc
51570        https://bugs.webkit.org/show_bug.cgi?id=109015
51571
51572        Reviewed by Mario Sanchez Prada.
51573
51574        Expose the <hr> element to Mac and iOS through the accessibility interface.
51575
51576        Test: platform/mac/accessibility/hr-element.html
51577
51578        * English.lproj/Localizable.strings:
51579        * accessibility/AccessibilityNodeObject.cpp:
51580        (WebCore::AccessibilityNodeObject::isEnabled):
51581        * accessibility/AccessibilityObject.cpp:
51582        (WebCore::AccessibilityObject::computedRoleString):
51583        * accessibility/AccessibilityRenderObject.cpp:
51584        (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
51585        * accessibility/atk/AccessibilityObjectAtk.cpp:
51586        (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
51587        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
51588        (-[WebAccessibilityObjectWrapper determineIsAccessibilityElement]):
51589        (-[WebAccessibilityObjectWrapper accessibilityLabel]):
51590        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
51591        (createAccessibilityRoleMap):
51592        (-[WebAccessibilityObjectWrapper subrole]):
51593        (-[WebAccessibilityObjectWrapper roleDescription]):
51594        * platform/LocalizedStrings.cpp:
51595        (WebCore::AXHorizontalRuleDescriptionText):
51596        * platform/LocalizedStrings.h:
51597
515982014-03-24  Antti Koivisto  <antti@apple.com>
51599
51600        Invalidate sibling text node style when needed instead of attaching synchronously
51601        https://bugs.webkit.org/show_bug.cgi?id=130590
51602
51603        Reviewed by Andreas Kling.
51604        
51605        Make things simpler.
51606
51607        * style/StyleResolveTree.cpp:
51608        (WebCore::Style::invalidateWhitespaceOnlyTextSiblingsAfterAttachIfNeeded):
51609        
51610            Just invalidate instead of calling attach directly.
51611            Rename to match.
51612
51613        (WebCore::Style::textRendererIsNeeded):
51614        (WebCore::Style::createTextRendererIfNeeded):
51615        
51616            Move all testing to textRendererIsNeeded.
51617
51618        (WebCore::Style::updateTextRendererAfterContentChange):
51619        
51620            Call resolveTextNode instead of re-implementing the same thing.
51621
51622        (WebCore::Style::resolveLocal):
51623        (WebCore::Style::resolveTextNode):
51624        
51625            Avoid unnecessary reattaching.
51626            Rename for consistency.
51627
51628        (WebCore::Style::resolveShadowTree):
51629        (WebCore::Style::resolveTree):
51630        
516312014-03-24  Zsolt Borbely  <zsborbely.u-szeged@partner.samsung.com>
51632
51633        Fix !ENABLE(VIDEO) build
51634        https://bugs.webkit.org/show_bug.cgi?id=130671
51635
51636        Reviewed by Eric Carlson.
51637
51638        Add missing ENABLE(VIDEO) guards because many functions use
51639        the newly guarded functions.
51640
51641        * testing/Internals.cpp:
51642        * testing/Internals.h:
51643        * testing/Internals.idl:
51644
516452014-03-24  Antti Koivisto  <antti@apple.com>
51646
51647        Text autosizing does not determine line count correctly for simple line layout
51648        https://bugs.webkit.org/show_bug.cgi?id=130673
51649
51650        Reviewed by Daniel Bates.
51651        
51652        We don't count lines correctly in simple line layout case.
51653
51654        * page/Frame.cpp:
51655        (WebCore::Frame::textAutosizingWidth):
51656        (WebCore::Frame::setTextAutosizingWidth):
51657        * page/ios/FrameIOS.mm:
51658        (WebCore::Frame::textAutosizingWidth): Deleted.
51659        (WebCore::Frame::setTextAutosizingWidth): Deleted.
51660        
51661            Move to Frame.cpp to make enabling on non-iOS build easier.
51662
51663        * rendering/RenderBlockFlow.cpp:
51664        (WebCore::RenderBlockFlow::lineCount):
51665        
51666            Handle simple line layout case.
51667
51668        (WebCore::RenderBlockFlow::lineCountForTextAutosizing):
51669            
51670            Call lineCount() if children are inline.
51671            Rename for clarity.
51672
51673        (WebCore::RenderBlockFlow::adjustComputedFontSizes):
51674        (WebCore::RenderBlockFlow::immediateLineCount): Deleted.
51675        * rendering/RenderBlockFlow.h:
51676
516772014-03-24  Frédéric Wang  <fred.wang@free.fr>
51678
51679        [regression] background colors do not apply to <mo> elements.
51680        https://bugs.webkit.org/show_bug.cgi?id=130470.
51681
51682        Test: mathml/presentation/tokenElements-background-color.html
51683
51684        * rendering/mathml/RenderMathMLOperator.cpp:
51685        (WebCore::RenderMathMLOperator::paint): always call the parent painting to draw the background.
51686        (WebCore::RenderMathMLOperator::paintChildren): move the special case for invisible operator here.
51687
516882014-03-24  Frédéric Wang  <fred.wang@free.fr>
51689
51690        Operator stretching: expose a math data API
51691        https://bugs.webkit.org/show_bug.cgi?id=130572
51692
51693        Reviewed by Chris Fleizach.
51694
51695        We expose a new SimpleFontData API to give access to the data from the
51696        OpenType MATH table using a font cache. The class OpenTypeMathData will
51697        be implemented in bug 130324. On Darwin platform, we also implement the
51698        missing FontPlatformData::openTypeTable function which will be necessary
51699        to load the OpenType MATH table. The changes are intended to be used
51700        for MathML operator stretching (bug 130322) so tests are not added yet.
51701
51702        * CMakeLists.txt: add new OpenTypeMathData files.
51703        * GNUmakefile.list.am: ditto.
51704        * WebCore.vcxproj/WebCore.vcxproj: ditto.
51705        * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
51706        * WebCore.xcodeproj/project.pbxproj: ditto.
51707        * platform/graphics/FontCache.cpp: We add a FontCache::getMathData function to implement a cache for the math data.
51708        We make the math and vertical data share the same key for the cache.
51709        (WebCore::fontMathDataCacheInstance):
51710        (WebCore::FontCache::getMathData):
51711        (WebCore::fontVerticalDataCacheInstance):
51712        * platform/graphics/FontCache.h: We declare FontCache::getMathData and FontFileKey on all platforms.
51713        * platform/graphics/FontPlatformData.cpp:
51714        (WebCore::FontPlatformData::openTypeTable): We implement openTypeTable() on Darwin platform.
51715        * platform/graphics/FontPlatformData.h: We expose openTypeTable() on Darwin platform.
51716        * platform/graphics/SimpleFontData.cpp: We initialize m_mathData from the font cache.
51717        (WebCore::SimpleFontData::SimpleFontData):
51718        * platform/graphics/SimpleFontData.h: We expose a mathData() function to access the MATH data.
51719        * platform/graphics/opentype/OpenTypeMathData.cpp: Added. This is a new class that will be used to parse the data from the OpenType MATH table.
51720        (WebCore::OpenTypeMathData::OpenTypeMathData):
51721        * platform/graphics/opentype/OpenTypeMathData.h: Added.
51722        (WebCore::OpenTypeMathData::create):
51723        (WebCore::OpenTypeMathData::hasMathData):
51724
517252014-03-24  Jon Lee  <jonlee@apple.com>
51726
51727        Build fixes.
51728
51729        Unreviewed.
51730
51731        * editing/ios/EditorIOS.mm:
51732        (WebCore::Editor::writeSelectionToPasteboard): Convert to reference.
51733
517342014-03-24  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
51735
51736        ENABLE(VIDEO_TRACK) guard for CSSParserSelector::parsePseudoCueFunctionSelector
51737        https://bugs.webkit.org/show_bug.cgi?id=130666
51738
51739        Reviewed by Andreas Kling.
51740
51741        No new tests. No new functionality.
51742
51743        * css/CSSParserValues.cpp:
51744        (WebCore::CSSParserSelector::parsePseudoCueFunctionSelector): Deleted.
51745
517462014-03-24  Javier Fernandez  <jfernandez@igalia.com>
51747
51748        [CSS Grid Layout] Update named <grid-line> syntax to the last version of the specs
51749        https://bugs.webkit.org/show_bug.cgi?id=129041
51750
51751        Reviewed by Sergio Villar Senin.
51752
51753        From Blink r162555 by <svillar@igalia.com>
51754
51755        Names for grid lines are now specified as a list of whitespace separated
51756        idents enclosed in parentheses instead of as a list of strings.
51757
51758        Updated tests to match the new <grid-line> syntax.
51759
51760        * CMakeLists.txt:
51761        * GNUmakefile.list.am:
51762        * WebCore.xcodeproj/project.pbxproj: Added info of the new file for the CSSGridLineNamesValue class.
51763        * css/CSSComputedStyleDeclaration.cpp:
51764        (WebCore::addValuesForNamedGridLinesAtIndex): The named <grid-line> value is now a list.
51765        * css/CSSGrammar.y.in: New syntax for named <grid-line>.
51766        * css/CSSGridLineNamesValue.cpp: Added.
51767        (WebCore::CSSGridLineNamesValue::customCSSText): String representation of the named <grid-line> as a list of Strings.
51768        (WebCore::CSSGridLineNamesValue::CSSGridLineNamesValue): Constructor.
51769        (WebCore::CSSGridLineNamesValue::cloneForCSSOM): Ref counted cloning function.
51770        * css/CSSGridLineNamesValue.h: Added.
51771        (WebCore::CSSGridLineNamesValue::create): Ref counted constructor.
51772        * css/CSSParser.cpp:
51773        (WebCore::CSSParser::parseGridLineNames): It replaces the old parseGrdTrackNames.
51774        (WebCore::CSSParser::parseGridTrackList): Using the new named <grid-line> syntax.
51775        (WebCore::CSSParser::parseGridTrackRepeatFunction): Using the new named <grid-line> syntax.
51776        * css/CSSParser.h:
51777        * css/CSSParserValues.cpp:
51778        (WebCore::destroy): Handling the case of CSSValue being CSSValueList intances.
51779        (WebCore::CSSParserValue::createCSSValue): Handling the case of CSSValue being CSSValueList intances.
51780        * css/CSSParserValues.h:
51781        (WebCore::CSSParserValue::setFromValueList): Adds the named <grid-line> list to the CSSParserValueList instance.
51782        * css/CSSValue.cpp:
51783        (WebCore::CSSValue::equals): Handling the case of the new CSSGridLineNamesValue class.
51784        (WebCore::CSSValue::cssText): Handling the case of the new CSSGridLineNamesValue class.
51785        (WebCore::CSSValue::destroy): Handling the case of the new CSSGridLineNamesValue class.
51786        * css/CSSValue.h:
51787        (WebCore::CSSValue::isGridLineNamesValue): Type cast check for the new CSSGridLineNamesValue class.
51788        * css/StyleResolver.cpp:
51789        (WebCore::createGridTrackList): Using the new named <grid-line> syntax.
51790
517912014-03-23  Sam Weinig  <sam@webkit.org>
51792
51793        Convert WebHTMLConverter to C++
51794        https://bugs.webkit.org/show_bug.cgi?id=130655
51795
51796        Reviewed by Andreas Kling.
51797
51798        - Mechanically converts the Objective-C class WebHTMLConverter, to the C++ HTMLConverter (lots of cleanup to follow).
51799        - Removes unused members
51800            - _standardFontFamily (never assigned to)
51801            - _textSizeMultiplier (always exactly 1)
51802            - _webViewTextSizeMultiplier (always exactly 0)
51803            - _defaultFontSize (always exactly 12, changed to be constant)
51804            - _minimumFontSize (always exactly 1, changed to be constant)
51805            - _colorsForNodes (never assigned to)
51806            - _indexingLimit (always exactly 0)
51807            - _thumbnailLimit (always exactly 0)
51808            - _flags.isIndexing (always false)
51809            - _flags.isTesting (always false)
51810
51811        * editing/cocoa/HTMLConverter.mm:
51812        (HTMLConverter::convert):
51813        (HTMLConverter::HTMLConverter):
51814        (HTMLConverter::~HTMLConverter):
51815        (defaultParagraphStyle):
51816        (_childrenForNode):
51817        (HTMLConverter::_stringForNode):
51818        (HTMLConverter::_getFloat):
51819        (_webKitBundle):
51820        (HTMLConverter::_elementIsBlockLevel):
51821        (HTMLConverter::_elementHasOwnBackgroundColor):
51822        (HTMLConverter::_blockLevelElementForNode):
51823        (HTMLConverter::_colorForNode):
51824        (HTMLConverter::_computedAttributesForElement):
51825        (HTMLConverter::_attributesForElement):
51826        (HTMLConverter::_newParagraphForElement):
51827        (HTMLConverter::_newLineForElement):
51828        (HTMLConverter::_newTabForElement):
51829        (_WebMessageDocumentClass):
51830        (HTMLConverter::_addAttachmentForElement):
51831        (HTMLConverter::_addQuoteForElement):
51832        (HTMLConverter::_addValue):
51833        (HTMLConverter::_fillInBlock):
51834        (HTMLConverter::_processMetaElementWithName):
51835        (HTMLConverter::_processHeadElement):
51836        (HTMLConverter::_enterElement):
51837        (HTMLConverter::_addTableForElement):
51838        (HTMLConverter::_addTableCellForElement):
51839        (HTMLConverter::_processElement):
51840        (HTMLConverter::_addMarkersToList):
51841        (HTMLConverter::_exitElement):
51842        (HTMLConverter::_processText):
51843        (HTMLConverter::_traverseNode):
51844        (HTMLConverter::_traverseFooterNode):
51845        (HTMLConverter::_adjustTrailingNewline):
51846        (HTMLConverter::_loadFromDOMRange):
51847        (fileWrapperForURL):
51848        (fileWrapperForElement):
51849        (WebCore::attributedStringFromRange):
51850        (WebCore::editingAttributedStringFromRange):
51851
518522014-03-23  Jinwoo Song  <jinwoo7.song@samsung.com>
51853
51854        Remove Dead Stores from editing directory
51855        https://bugs.webkit.org/show_bug.cgi?id=130634
51856
51857        Reviewed by Darin Adler.
51858
51859        Remove Dead Stores from editing directory which assigning a value to a variable
51860        and never reading that value.
51861
51862        * editing/ApplyStyleCommand.cpp:
51863        (WebCore::ApplyStyleCommand::mergeStartWithPreviousIfIdentical):
51864        * editing/markup.cpp:
51865        (WebCore::createMarkupInternal):
51866
518672014-03-23  Hyowon Kim  <hw1008.kim@samsung.com>
51868
51869        Move all EFL typedefs into EflTypedefs.h.
51870        https://bugs.webkit.org/show_bug.cgi?id=130511
51871
51872        Reviewed by Gyuyoung Kim.
51873
51874        * platform/FileSystem.h: Remove EFL typedefs.
51875        * platform/Widget.h: Ditto.
51876        * platform/efl/EflScreenUtilities.h: Ditto.
51877        * platform/graphics/Icon.h: Ditto.
51878        * platform/graphics/Image.h: Ditto.
51879        * platform/graphics/IntPoint.h: Ditto.
51880        * platform/graphics/IntRect.h: Ditto.
51881        * platform/network/NetworkStateNotifier.h: Ditto.
51882
518832014-03-23  Sam Weinig  <sam@webkit.org>
51884
51885        Move HTMLConverter from platform/mac to editing/cocoa.
51886
51887        Rubber-stamped by Darin Adler.
51888
51889        * WebCore.xcodeproj/project.pbxproj:
51890        * editing/cocoa: Added.
51891        * editing/cocoa/HTMLConverter.h: Copied from platform/mac/HTMLConverter.h.
51892        * editing/cocoa/HTMLConverter.mm: Copied from platform/mac/HTMLConverter.mm.
51893        * platform/mac/HTMLConverter.h: Removed.
51894        * platform/mac/HTMLConverter.mm: Removed.
51895
518962014-03-23  Sam Weinig  <sam@webkit.org>
51897
51898        Simplify the HTMLConverter interface (Part 2)
51899        https://bugs.webkit.org/show_bug.cgi?id=130654
51900
51901        Reviewed by Darin Adler.
51902
51903        Switch HTMLConverter from using an Objective-C interface to C functions.
51904
51905        * WebCore.exp.in:
51906        * editing/ios/EditorIOS.mm:
51907        (WebCore::Editor::writeSelectionToPasteboard):
51908        * editing/mac/EditorMac.mm:
51909        (WebCore::Editor::dataSelectionForPasteboard):
51910        (WebCore::Editor::writeSelectionToPasteboard):
51911        * platform/ios/PasteboardIOS.mm:
51912        * platform/mac/HTMLConverter.h:
51913        * platform/mac/HTMLConverter.mm:
51914        (WebCore::attributedStringFromRange):
51915        (WebCore::editingAttributedStringFromRange):
51916        * platform/mac/PasteboardMac.mm:
51917
519182014-03-23  Darin Adler  <darin@apple.com>
51919
51920        Remove code in HTMLObjectElement attribute parsing that forces style resolution and layout
51921        https://bugs.webkit.org/show_bug.cgi?id=130653
51922
51923        Reviewed by Antti Koivisto.
51924
51925        * dom/ContainerNode.cpp: Moved the post-attach callback code from here to
51926        StyleResolveTree.h/cpp.
51927        * dom/ContainerNode.h: Ditto.
51928
51929        * dom/Document.cpp:
51930        (WebCore::Document::recalcStyle): Use Style::PostResolutionCallbackDisabler instead of
51931        PostAttachCallbackDisabler.
51932
51933        * dom/Element.h: Moved the post-attach callback code from here to StyleResolveTree.h/cpp.
51934
51935        * html/HTMLEmbedElement.cpp:
51936        (WebCore::HTMLEmbedElement::parseAttribute): Simplified the code for typeAttr, turning
51937        it into a 1-liner. Added a FIXME in codeAttr about the fact that it does not have the
51938        code to trigger image loads. Changed srcAttr to call updateImageLoaderWithNewURLSoon to
51939        do the image loading logic.
51940
51941        * html/HTMLFormControlElement.cpp:
51942        (WebCore::HTMLFormControlElement::didAttachRenderers): Updated to use
51943        Style::queuePostResolutionCallback and use a lambda instead of a function.
51944        (WebCore::HTMLFormControlElement::didRecalcStyle): Ditto. Also added RefPtr instead
51945        of just using wishful thinking to keep the object alive.
51946        * html/HTMLFrameOwnerElement.cpp:
51947        (WebCore::HTMLFrameOwnerElement::scheduleSetNeedsStyleRecalc): Ditto.
51948
51949        * html/HTMLObjectElement.cpp:
51950        (WebCore::HTMLObjectElement::parseAttribute):: Simplified the code for typeAttr, turning
51951        it into a 1-liner. Changed dataAttr to use updateImageLoaderWithNewURLSoon(). Also made
51952        it call setNeedsWidgetUpdate(true) unconditionally after checking carefully to see that's
51953        harmless if there is no renderer. Changed classidAttr to call setNeedsWidgetUpdate(true)
51954        unconditionally and not set m_classId.
51955        (WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk): Use fastGetAttribute
51956        instead of classId and descendantsOfType instead of getElementsByTagName.
51957        (WebCore::HTMLObjectElement::hasValidClassId): Use fastGetAttribute instead of classId.
51958        (WebCore::HTMLObjectElement::renderFallbackContent): Use imageLoader instead of m_imageLoader.
51959
51960        * html/HTMLObjectElement.h: Removed classId, since there is no reason to cache that
51961        attribute in a data member. Rearranged header, making more private, and fixing some typos,
51962        and doing a "using" instead of a function to disambiguate the inherited form functions.
51963
51964        * html/HTMLPlugInImageElement.cpp:
51965        (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): Initialize m_needsImageReload.
51966        (WebCore::HTMLPlugInImageElement::createElementRenderer): Fixed some code that assumed the
51967        first child of the shadow root is guaranteed to be an element.
51968        (WebCore::HTMLPlugInImageElement::didRecalcStyle): Added. Calls the new
51969        scheduleUpdateForAfterStyleResolution function.
51970        (WebCore::HTMLPlugInImageElement::didAttachRenderers): Moved all the logic from this
51971        function into scheduleUpdateForAfterStyleResolution. Also added a call through to the base
51972        class; cleaner even though it's just an assertion.
51973        (WebCore::HTMLPlugInImageElement::scheduleUpdateForAfterStyleResolution): Added.
51974        Schedules a call to updateAfterStyleResolution when needed.
51975        (WebCore::HTMLPlugInImageElement::updateAfterStyleResolution): Added.
51976        Combines updateWidgetIfNecessary and startLoadingImage, and also deals with the new
51977        m_needsImageReload boolean in cases where no actual loading is done.
51978        (WebCore::HTMLPlugInImageElement::removedFrom): Added. Do not delay the load event of
51979        document once this element is removed, clears m_needsImageReload.
51980        (WebCore::HTMLPlugInImageElement::didMoveToNewDocument): Removed null check on oldDocument,
51981        since m_needsDocumentActivationCallbacks can't be true if the old document was null.
51982        (WebCore::is100Percent): Added helper to make function below more readable.
51983        (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Restructured the code a
51984        bit. The part that attracted my attention was the local variable of type RenderBox, which
51985        was named renderEmbeddedObject. Turns out the caller guarantees to only call this if there
51986        is a renderer of type RenderEmbeddedObject, so depend on that.
51987        (WebCore::HTMLPlugInImageElement::setNeedsImageReload): Added. When called with true, sets
51988        the flag and triggers a style recalculation, and lets updateAfterStyleResolution do the rest.
51989        When called with false, reverses the effects and stops delaying the load event.
51990
51991        * html/HTMLPlugInImageElement.h: Trimmed includes a bit. Made more members private.
51992        Marked more function members final. Made a protected imageLoader function so that
51993        m_imageLoader can be private. Added new protected function updateImageLoaderWithNewURLSoon,
51994        as well as other new private functions. Made m_imageLoader be std::unique_ptr instead of
51995        OwnPtr, and added m_needsImageReload.
51996
51997        * style/StyleResolveTree.cpp:
51998        (WebCore::Style::needsPseudoElement): Fixed spelling error in the name of this function.
51999        (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded): Updated for name change.
52000        (WebCore::Style::attachRenderTree): Update for new name of PostResolutionCallbackDisabler.
52001        (WebCore::Style::updateBeforeOrAfterPseudoElement): Updated for name change.
52002        (WebCore::Style::postResolutionCallbackQueue): Added.
52003        (WebCore::Style::queuePostResolutionCallback): Added.
52004        (WebCore::Style::suspendMemoryCacheClientCalls): Added. This is a side effect of the original
52005        PostAttachCallbackDisabler that is now done in a cleaner way, using the callback queue, instead
52006        of as a special case. It should not work for multiple documents across multiple pages instead of
52007        only the outermost one.
52008        (WebCore::Style::PostResolutionCallbackDisabler::PostResolutionCallbackDisabler): Added.
52009        Calls suspendMemoryCacheClientCalls, but a FIXME tries to point out why that isn't so great.
52010        (WebCore::Style::PostResolutionCallbackDisabler::~PostResolutionCallbackDisabler): Added.
52011        (WebCore::Style::postResolutionCallbacksAreSuspended): Added.
52012
52013        * style/StyleResolveTree.h: Added queuePostResolutionCallback and
52014        postResolutionCallbacksAreSuspended. Also added PostResolutionCallbackDisabler, which should
52015        eventually become a private implementation detail.
52016
520172014-03-23  Sam Weinig  <sam@webkit.org>
52018
52019        Simplify the HTMLConverter interface (Part 1)
52020        https://bugs.webkit.org/show_bug.cgi?id=130654
52021
52022        Reviewed by Dan Bernstein.
52023
52024        Convert WebHTMLConverter's interface to only use class methods as the first
52025        step of simplifying the interface. 
52026
52027        * editing/ios/EditorIOS.mm:
52028        (WebCore::attributedStringForRange):
52029        * editing/mac/EditorMac.mm:
52030        (WebCore::attributedStringForRange):
52031        * platform/mac/HTMLConverter.h:
52032        * platform/mac/HTMLConverter.mm:
52033        (+[WebHTMLConverter attributedStringFromRange:]):
52034
520352014-03-23  James Craig  <jcraig@apple.com>
52036
52037        Web Inspector: AXI: add other ARIA one-to-many relationships: owns, flowto, controls.
52038        https://bugs.webkit.org/show_bug.cgi?id=130635
52039
52040        Reviewed by Timothy Hatcher.
52041
52042        Support for @aria-owns, @aria-controls, and @aria-flowto.
52043
52044        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
52045
52046        * inspector/InspectorDOMAgent.cpp:
52047        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
52048        * inspector/protocol/DOM.json:
52049
520502014-03-23  Simon Fraser  <simon.fraser@apple.com>
52051
52052        Clean up #includes by geometry classes
52053        https://bugs.webkit.org/show_bug.cgi?id=130645
52054
52055        Reviewed by Andreas Kling.
52056
52057        Pulling in <wtf/Vector.h> and <wtf/PrintStream.h> in the simple geometry
52058        classes brings in a lot of additional headers. Fix by adding a new
52059        GeometryUtilities file so that the basic files don't need Vector,
52060        and including GeometryUtilities.h where necessary.
52061        
52062        Also forward declare PrintStream.h and only bring in the header
52063        in implementation files.
52064
52065        * CMakeLists.txt:
52066        * GNUmakefile.list.am:
52067        * WebCore.vcxproj/WebCore.vcxproj:
52068        * WebCore.vcxproj/WebCore.vcxproj.filters:
52069        * WebCore.xcodeproj/project.pbxproj:
52070        * css/CSSToStyleMap.h:
52071        * html/HTMLCanvasElement.cpp:
52072        * platform/cairo/WidgetBackingStoreCairo.h:
52073        * platform/graphics/FloatPoint.cpp:
52074        * platform/graphics/FloatPoint.h:
52075        * platform/graphics/FloatRect.cpp:
52076        * platform/graphics/FloatRect.h:
52077        * platform/graphics/FloatSize.cpp:
52078        * platform/graphics/FloatSize.h:
52079        * platform/graphics/GeometryUtilities.cpp: Added.
52080        (WebCore::findSlope):
52081        (WebCore::findIntersection):
52082        (WebCore::unionRect):
52083        (WebCore::mapRect):
52084        * platform/graphics/GeometryUtilities.h: Copied from Source/WebCore/platform/graphics/TextTrackRepresentation.h.
52085        * platform/graphics/IntPoint.h:
52086        * platform/graphics/IntRect.cpp:
52087        * platform/graphics/IntRect.h:
52088        * platform/graphics/IntSize.h:
52089        * platform/graphics/TextTrackRepresentation.h:
52090        * platform/graphics/Tile.h:
52091        * platform/graphics/texmap/coordinated/UpdateAtlas.h:
52092        * platform/gtk/WidgetBackingStoreGtkX11.h:
52093        * rendering/RenderBoxModelObject.cpp:
52094        * rendering/RenderImage.cpp:
52095        * rendering/RenderObject.cpp:
52096
520972014-03-23  Simon Fraser  <simon.fraser@apple.com>
52098
52099        Clean up #includes by geometry classes
52100        https://bugs.webkit.org/show_bug.cgi?id=130645
52101
52102        Reviewed by Andreas Kling.
52103
52104        Pulling in <wtf/Vector.h> and <wtf/PrintStream.h> in the simple geometry
52105        classes brings in a lot of additional headers. Fix by adding a new
52106        GeometryUtilities file so that the basic files don't need Vector,
52107        and including GeometryUtilities.h where necessary.
52108        
52109        Also forward declare PrintStream.h and only bring in the header
52110        in implementation files.
52111
52112        * CMakeLists.txt:
52113        * GNUmakefile.list.am:
52114        * WebCore.vcxproj/WebCore.vcxproj:
52115        * WebCore.vcxproj/WebCore.vcxproj.filters:
52116        * WebCore.xcodeproj/project.pbxproj:
52117        * css/CSSToStyleMap.h:
52118        * html/HTMLCanvasElement.cpp:
52119        * platform/cairo/WidgetBackingStoreCairo.h:
52120        * platform/graphics/FloatPoint.cpp:
52121        * platform/graphics/FloatPoint.h:
52122        * platform/graphics/FloatRect.cpp:
52123        * platform/graphics/FloatRect.h:
52124        * platform/graphics/FloatSize.cpp:
52125        * platform/graphics/FloatSize.h:
52126        * platform/graphics/GeometryUtilities.cpp: Added.
52127        (WebCore::findSlope):
52128        (WebCore::findIntersection):
52129        (WebCore::unionRect):
52130        (WebCore::mapRect):
52131        * platform/graphics/GeometryUtilities.h: Copied from Source/WebCore/platform/graphics/TextTrackRepresentation.h.
52132        * platform/graphics/IntPoint.h:
52133        * platform/graphics/IntRect.cpp:
52134        * platform/graphics/IntRect.h:
52135        * platform/graphics/IntSize.h:
52136        * platform/graphics/TextTrackRepresentation.h:
52137        * platform/graphics/Tile.h:
52138        * platform/gtk/WidgetBackingStoreGtkX11.h:
52139        * rendering/RenderBoxModelObject.cpp:
52140        * rendering/RenderImage.cpp:
52141        * rendering/RenderObject.cpp:
52142
521432014-03-22  Chang Shu  <cshu@webkit.org>
52144
52145        Replace deprecatedIsCollapsibleWhitespace with RenderStyle::isCollapsibleWhiteSpace in TextIterator.
52146        https://bugs.webkit.org/show_bug.cgi?id=130612.
52147
52148        Reviewed by Darin Adler.
52149
52150        Some layout tests are affected by this change but the new behavior should be correct.
52151
52152        * editing/TextIterator.cpp:
52153        (WebCore::TextIterator::handleTextNode):
52154        (WebCore::TextIterator::handleTextBox):
52155
521562014-03-22  Sam Weinig  <sam@webkit.org>
52157
52158        Switch HTMLConverter to use CSSPropertyIDs to refer to CSS properties
52159        https://bugs.webkit.org/show_bug.cgi?id=130639
52160
52161        Reviewed by Darin Adler.
52162
52163        This is a ~15% speedup on PerformanceTests/Interactive/CopyAll.html.
52164
52165        - Removes gratuitous lookup of CSS properties that are known at compile time.
52166        - Removes attempted use of non-supported CSS properties (font-effect and horizontal-align) 
52167          that will alway yield the same results.
52168        - Fix some obvious typos where the author thought they were testing for fontKerning or fontLigatures
52169          but instead used the non-existent font-effect.
52170
52171        * platform/mac/HTMLConverter.mm:
52172        (HTMLConverterCaches::computedStylePropertyForElement):
52173        (HTMLConverterCaches::inlineStylePropertyForElement):
52174        (HTMLConverterCaches::propertyValueForNode):
52175        (-[WebHTMLConverter _stringForNode:property:]):
52176        (HTMLConverterCaches::floatPropertyValueForNode):
52177        (-[WebHTMLConverter _getFloat:forNode:property:]):
52178        (HTMLConverterCaches::isBlockElement):
52179        (HTMLConverterCaches::elementHasOwnBackgroundColor):
52180        (HTMLConverterCaches::colorPropertyValueForNode):
52181        (-[WebHTMLConverter _colorForNode:property:]):
52182        (-[WebHTMLConverter _computedAttributesForElement:]):
52183        (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
52184        (-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
52185        (-[WebHTMLConverter _addTableForElement:]):
52186        (-[WebHTMLConverter _addTableCellForElement:]):
52187        (-[WebHTMLConverter _processElement:tag:display:depth:]):
52188        (-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
52189        (-[WebHTMLConverter _processText:]):
52190        (-[WebHTMLConverter _traverseNode:depth:embedded:]):
52191
521922014-03-22  Andreas Kling  <akling@apple.com>
52193
52194        Fix debug build.
52195
52196        * bindings/js/JSDOMBinding.h:
52197        (WebCore::createWrapper):
52198
521992014-03-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
52200
52201        Add *final* keyword to NavigatorContentUtils class
52202        https://bugs.webkit.org/show_bug.cgi?id=130636
52203
52204        Reviewed by Darin Adler.
52205
52206        NavigatorContentUtils won't be used as a base class. So, added final keyword.
52207
52208        No new tests, no behavior changes.
52209
52210        * Modules/navigatorcontentutils/NavigatorContentUtils.h:
52211
522122014-03-22  Andreas Kling  <akling@apple.com>
52213
52214        CREATE_DOM_WRAPPER doesn't need the ExecState.
52215        <https://webkit.org/b/130648>
52216
52217        Remove the ExecState parameter from CREATE_DOM_WRAPPER and get all
52218        that we need from the global object instead.
52219
52220        toJS() and toJSNewlyCreated() still take an ExecState, that needs
52221        to be dealt with separately since some of them have scary looking
52222        currentWorld() checks.
52223
52224        Reviewed by Darin Adler.
52225
52226        * bindings/js/JSAudioContextCustom.cpp:
52227        (WebCore::JSAudioContextConstructor::constructJSAudioContext):
52228        * bindings/js/JSBlobCustom.cpp:
52229        (WebCore::toJS):
52230        (WebCore::JSBlobConstructor::constructJSBlob):
52231        * bindings/js/JSCDATASectionCustom.cpp:
52232        (WebCore::toJSNewlyCreated):
52233        * bindings/js/JSCSSRuleCustom.cpp:
52234        (WebCore::toJS):
52235        * bindings/js/JSCSSValueCustom.cpp:
52236        (WebCore::toJS):
52237        * bindings/js/JSCanvasRenderingContextCustom.cpp:
52238        (WebCore::toJS):
52239        * bindings/js/JSDOMBinding.h:
52240        (WebCore::createWrapper):
52241        (WebCore::wrap):
52242        (WebCore::createNewWrapper):
52243        * bindings/js/JSDocumentCustom.cpp:
52244        (WebCore::toJS):
52245        * bindings/js/JSElementCustom.cpp:
52246        (WebCore::toJSNewlyCreated):
52247        * bindings/js/JSEventCustom.cpp:
52248        (WebCore::toJS):
52249        * bindings/js/JSHTMLCollectionCustom.cpp:
52250        (WebCore::toJS):
52251        * bindings/js/JSHTMLTemplateElementCustom.cpp:
52252        (WebCore::JSHTMLTemplateElement::content):
52253        * bindings/js/JSIDBAnyCustom.cpp:
52254        (WebCore::toJS):
52255        * bindings/js/JSImageDataCustom.cpp:
52256        (WebCore::toJS):
52257        * bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
52258        (WebCore::toJS):
52259        * bindings/js/JSNodeCustom.cpp:
52260        (WebCore::createWrapperInline):
52261        * bindings/js/JSPerformanceEntryCustom.cpp:
52262        (WebCore::toJS):
52263        * bindings/js/JSRTCIceCandidateCustom.cpp:
52264        (WebCore::JSRTCIceCandidateConstructor::constructJSRTCIceCandidate):
52265        * bindings/js/JSRTCPeerConnectionCustom.cpp:
52266        (WebCore::JSRTCPeerConnectionConstructor::constructJSRTCPeerConnection):
52267        * bindings/js/JSRTCSessionDescriptionCustom.cpp:
52268        (WebCore::JSRTCSessionDescriptionConstructor::constructJSRTCSessionDescription):
52269        * bindings/js/JSSVGPathSegCustom.cpp:
52270        (WebCore::toJS):
52271        * bindings/js/JSStyleSheetCustom.cpp:
52272        (WebCore::toJS):
52273        * bindings/js/JSTextCustom.cpp:
52274        (WebCore::toJSNewlyCreated):
52275        * bindings/js/JSTextTrackCueCustom.cpp:
52276        (WebCore::toJS):
52277        * bindings/js/JSTouchCustom.cpp:
52278        (WebCore::toJSNewlyCreated):
52279        * bindings/js/JSTouchListCustom.cpp:
52280        (WebCore::toJSNewlyCreated):
52281        * bindings/js/JSTrackCustom.cpp:
52282        (WebCore::toJS):
52283        * bindings/scripts/CodeGeneratorJS.pm:
52284        (GenerateImplementation):
52285        * dom/make_names.pl:
52286        (printWrapperFunctions):
52287        (printWrapperFactoryCppFile):
52288        (printWrapperFactoryHeaderFile):
52289
522902014-03-22  Michael Saboff  <msaboff@apple.com>
52291
52292        toThis() on a JSWorkerGlobalScope should return a JSProxy and not undefined
52293        https://bugs.webkit.org/show_bug.cgi?id=130554
52294
52295        Reviewed by Geoffrey Garen.
52296
52297        Fixed toThis() on WorkerGlobalScope to return a JSProxy instead of the JSGlobalObject.
52298        Added cast from JSProxy->target() if the jsCast<>() to the native object fails
52299        in toJSDedicatedWorkerGlobalScope() and toJSSharedWorkerGlobalScope().
52300        The original cast is needed for access to the local side of the worker, while the JSProxy
52301        cast is used on the remote side of a worker.
52302
52303        Test: fast/workers/worker-strict.html
52304
52305        * bindings/js/JSWorkerGlobalScopeBase.cpp:
52306        (WebCore::toJSDedicatedWorkerGlobalScope):
52307        (WebCore::toJSSharedWorkerGlobalScope):
52308
52309        * bindings/js/WorkerScriptController.cpp:
52310        (WebCore::WorkerScriptController::evaluate): Changed to pass in the JSProxy and not
52311        the WorkerGlobalScope object as the this object to script evaluation.
52312
52313        * workers/DedicatedWorkerGlobalScope.idl:
52314        * workers/SharedWorkerGlobalScope.idl:
52315        * workers/WorkerGlobalScope.idl:
52316        Added the new CustomProxyToJSObject attribute so we'll call to<{nativeClass}>() for
52317        getting the object to use for global evaluation.
52318
523192014-03-22  Simon Fraser  <simon.fraser@apple.com>
52320
52321        Some #include hygiene in Node/Element etc
52322        https://bugs.webkit.org/show_bug.cgi?id=130642
52323
52324        Reviewed by Geoffrey Garen.
52325
52326        Clean up various #includes.
52327
52328        * accessibility/AccessibilityObject.h:
52329        * bindings/js/WebCoreTypedArrayController.h:
52330        * dom/Element.h:
52331        * dom/EventListenerMap.h:
52332        * dom/EventTarget.h:
52333        * dom/Node.h:
52334        * rendering/RenderObject.h:
52335        * rendering/svg/RenderSVGRoot.h:
52336
523372014-03-22  Simon Fraser  <simon.fraser@apple.com>
52338
52339        FloatRect.h on iOS should not suck in a system header
52340        https://bugs.webkit.org/show_bug.cgi?id=130641
52341
52342        Reviewed by Geoff Garen.
52343
52344        Don't pull in <CoreGraphics/CGGeometry.h> from FloatRect.h.
52345
52346        * platform/graphics/FloatRect.h:
52347
523482014-03-22  Dan Bernstein  <mitz@apple.com>
52349
52350        Fixed the iOS build.
52351
52352        Reviewed by Darin Adler.
52353
52354        * page/ios/FrameIOS.mm:
52355        (WebCore::Frame::interpretationsForCurrentRoot):
52356
523572014-03-22  Darin Adler  <darin@apple.com>
52358
52359        Remove String::deprecatedCharacters
52360        https://bugs.webkit.org/show_bug.cgi?id=126854
52361
52362        Reviewed by Sam Weinig.
52363
52364        * bindings/scripts/StaticString.pm:
52365        (GenerateStrings): Remove the code to generate the null m_copyData16 pointer.
52366
52367        * editing/TextIterator.cpp:
52368        (WebCore::SearchBuffer::prependContext): Changed to use the new append function in
52369        StringView.h and removed the one defined locally here.
52370
52371        * editing/VisibleUnits.cpp:
52372        (WebCore::wordBreakIteratorForMinOffsetBoundary): Use the new append function
52373        in StringView.h instead of using deprecatedCharacters.
52374        (WebCore::wordBreakIteratorForMaxOffsetBoundary): Ditto.
52375        Removed an append function defined locally here and use the one in StringView.h.
52376
52377        * editing/htmlediting.cpp:
52378        (WebCore::stringWithRebalancedWhitespace): Use StringView::getCharactersWithUpconvert.
52379
52380        * html/parser/HTMLToken.h:
52381        (WebCore::HTMLToken::appendToAttributeValue): Changed to take a StringView instead
52382        of a const String&.
52383
52384        * loader/appcache/ManifestParser.cpp:
52385        (WebCore::parseManifest): Use StringView and StringView::upconvertedCharacters.
52386
52387        * page/EventSource.cpp:
52388        (WebCore::EventSource::didReceiveData): Use the new append overload from StringView.h.
52389        Also added a comment about incorrect use of the decode function.
52390
52391        * page/ios/FrameIOS.mm:
52392        (WebCore::Frame::interpretationsForCurrentRoot): Use the new StringView append function.
52393        Also use simpler new-style for loops.
52394
52395        * platform/LinkHash.cpp:
52396        (WebCore::visitedURLInline): Use the new append function and StringView::substring.
52397        (WebCore::visitedLinkHash): Use upconvertedCharacters for the non-8-bit case.
52398
52399        * platform/URL.cpp:
52400        (WebCore::findFirstOf): Chagned to take a StringView.
52401        (WebCore::containsOnlyASCII): Added. Works on StringView. Could move to a WTF header in
52402        the future if it's needed elsewhere.
52403        (WebCore::protocolIs): Added. Works on StringView. Could put in URL.h if needed elsewhere,
52404        or consider replacing the one that takes const String& with just this one.
52405        (WebCore::appendEncodedHostname): Changed to take a StringView and use
52406        StringView::upconvertedCharacters.
52407        (WebCore::findHostnamesInMailToURL): Changed to take a StringView.
52408        (WebCore::findHostnameInHierarchicalURL): Ditto.
52409        (WebCore::encodeHostnames): Ditto.
52410        (WebCore::encodeRelativeString): Ditto.
52411
52412        * platform/graphics/StringTruncator.cpp:
52413        (WebCore::StringTruncator::width): Use StringView::upconvertedCharacters.
52414
52415        * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
52416        (WebCore::HarfBuzzShaper::setFontFeatures): Use indexing directly on the string instead
52417        of on a UChar*.
52418        (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns): Use StringView::upconvertedCharacters.
52419
52420        * platform/text/TextCodecICU.cpp:
52421        (WebCore::TextCodecICU::encode): Use a Vector<UChar> rather than a String to copy and
52422        replace the backslashes with yen signs. Also optimize case where there are no backslashes.
52423
52424        * rendering/RenderListMarker.cpp:
52425        (WebCore::RenderListMarker::paint): Use TextRun::setText(StringView).
52426
52427        * rendering/RenderText.cpp:
52428        (WebCore::maxWordFragmentWidth): Pass a String to RenderBlock::constructTextRun instead of
52429        calling StringBuilder::deprecatedCharacters.
52430
52431        * rendering/RenderText.h: Removed deprecatedCharacters function.
52432
52433        * rendering/line/BreakingContextInlineHeaders.h: Added now-needed header include.
52434
52435        * rendering/svg/SVGInlineTextBox.cpp:
52436        (WebCore::SVGInlineTextBox::constructTextRun): Use StringView version of TextRun constructor.
52437
52438        * rendering/svg/SVGTextMetrics.cpp:
52439        (WebCore::SVGTextMetrics::SVGTextMetrics): Take references instead of pointers.
52440        (WebCore::SVGTextMetrics::constructTextRun): Take references instead of pointers, and don't
52441        take a character pointer any more. Instead, extract the text and use the StringView version of
52442        the TextRun constructor.
52443        (WebCore::SVGTextMetrics::measureCharacterRange): Take references instead of pointers and
52444        update for above changes.
52445        * rendering/svg/SVGTextMetrics.h: Updated for changes above. Also tweaked style a bit.
52446
52447        * rendering/svg/SVGTextMetricsBuilder.cpp:
52448        (WebCore::SVGTextMetricsBuilder::advanceSimpleText): Updated for SVGTextMetrics changes.
52449        (WebCore::SVGTextMetricsBuilder::advanceComplexText): Ditto.
52450        (WebCore::SVGTextMetricsBuilder::initializeMeasurementWithTextRenderer): Ditto.
52451        (WebCore::SVGTextMetricsBuilder::measureTextRenderer): Change code to store a character
52452        for lastCharacter rather than storing a pointer to a character. Stop using TextRun::data16.
52453
52454        * rendering/svg/SVGTextQuery.cpp:
52455        (WebCore::SVGTextQuery::subStringLengthCallback): Updated for SVGTextMetrics changes.
52456        (WebCore::SVGTextQuery::startPositionOfCharacterCallback): Ditto.
52457        (WebCore::SVGTextQuery::endPositionOfCharacterCallback): Ditto.
52458        (WebCore::calculateGlyphBoundaries): Ditto.
52459
52460        * xml/XPathFunctions.cpp:
52461        (WebCore::XPath::atomicSubstring): Added.
52462        (WebCore::XPath::FunId::evaluate): Tweaked a bit to use a new style for loop.
52463        Use the atomicSubstring function to avoid making a temporary String just to make an AtomicString.
52464        That function also uses characters8/16 rather than depreccatedCharacters.
52465
52466        * xml/XPathNodeSet.h: Added begin and end so this collection can be iterated with new style for loop.
52467
52468        * xml/parser/XMLDocumentParserLibxml2.cpp:
52469        (WebCore::XMLDocumentParser::doWrite): Use StringView::upconvertedCharacters.
52470        (WebCore::parseAttributes): Ditto.
52471
524722014-03-22  Commit Queue  <commit-queue@webkit.org>
52473
52474        Unreviewed, rolling out r166118.
52475        https://bugs.webkit.org/show_bug.cgi?id=130640
52476
52477        Crashing things (Requested by weinig on #webkit).
52478
52479        Reverted changeset:
52480
52481        "Switch HTMLConverter to use CSSPropertyIDs to refer to CSS
52482        properties"
52483        https://bugs.webkit.org/show_bug.cgi?id=130639
52484        http://trac.webkit.org/changeset/166118
52485
524862014-03-22  Sam Weinig  <sam@webkit.org>
52487
52488        Switch HTMLConverter to use CSSPropertyIDs to refer to CSS properties
52489        https://bugs.webkit.org/show_bug.cgi?id=130639
52490
52491        Reviewed by Simon Fraser.
52492
52493        This is a ~15% speedup on PerformanceTests/Interactive/CopyAll.html.
52494
52495        - Removes gratuitous lookup of CSS properties that are known at compile time.
52496        - Removes attempted use of non-supported CSS properties (font-effect and horizontal-align) 
52497          that will alway yield the same results.
52498        - Fix some obvious typos where the author thought they were testing for fontKerning or fontLigatures
52499          but instead used the non-existent font-effect.
52500
52501        * platform/mac/HTMLConverter.mm:
52502        (HTMLConverterCaches::computedStylePropertyForElement):
52503        (HTMLConverterCaches::inlineStylePropertyForElement):
52504        (HTMLConverterCaches::propertyValueForNode):
52505        (-[WebHTMLConverter _stringForNode:property:]):
52506        (HTMLConverterCaches::floatPropertyValueForNode):
52507        (-[WebHTMLConverter _getFloat:forNode:property:]):
52508        (HTMLConverterCaches::isBlockElement):
52509        (HTMLConverterCaches::elementHasOwnBackgroundColor):
52510        (HTMLConverterCaches::colorPropertyValueForNode):
52511        (-[WebHTMLConverter _colorForNode:property:]):
52512        (-[WebHTMLConverter _computedAttributesForElement:]):
52513        (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
52514        (-[WebHTMLConverter _fillInBlock:forElement:backgroundColor:extraMargin:extraPadding:isTable:]):
52515        (-[WebHTMLConverter _addTableForElement:]):
52516        (-[WebHTMLConverter _addTableCellForElement:]):
52517        (-[WebHTMLConverter _processElement:tag:display:depth:]):
52518        (-[WebHTMLConverter _exitElement:tag:display:depth:startIndex:]):
52519        (-[WebHTMLConverter _processText:]):
52520        (-[WebHTMLConverter _traverseNode:depth:embedded:]):
52521
525222014-03-21  Simon Fraser  <simon.fraser@apple.com>
52523
52524        Don't flush compositing layers within FrameView::willPaintContents()
52525        https://bugs.webkit.org/show_bug.cgi?id=130627
52526        <rdar://problem/16368869>
52527
52528        Reviewed by Sam Weinig.
52529
52530        Remove the call to flushCompositingStateForThisFrame() here. We should
52531        have always flushed before painting via other mechanisms in WebKit2 and WebKit2.
52532        Flushing during painting is actually harmful, since we could be inside
52533        a CA commit already, and creating or destroying layers via flushing is bad.
52534
52535        * page/FrameView.cpp:
52536        (WebCore::FrameView::willPaintContents):
52537
525382014-03-22  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
52539
52540        ASSERTION FAILED: std::isfinite(num) in WebCore::CSSPrimitiveValue::CSSPrimitiveValue
52541        https://bugs.webkit.org/show_bug.cgi?id=127361
52542
52543        Huge numbers represented by the 'INF' value can not be used
52544        in CSS rules, so they make the assert fail. We have to make
52545        sure that the parsed property value is finite, otherwise
52546        the property will be dropped.
52547
52548        Test: fast/css/infinite-floating-value.html
52549
52550        * css/CSSValuePool.cpp:
52551        (WebCore::CSSValuePool::createValue):
52552
525532014-03-21  Zalan Bujtas  <zalan@apple.com>
52554
52555        Remove redundant friending from class Image.
52556        https://bugs.webkit.org/show_bug.cgi?id=130628
52557
52558        Reviewed by Simon Fraser.
52559
52560        Those friend classes are subclasses. No need to make them friend of their parent class.
52561
52562        No change in functionality.
52563
52564        * platform/graphics/Image.h:
52565
525662014-03-21  Benjamin Poulain  <bpoulain@apple.com>
52567
52568        [iOS][WK2] Reduce the tiling coverage to the current rect and 1 tile size ahead
52569        https://bugs.webkit.org/show_bug.cgi?id=130555
52570
52571        Reviewed by Simon Fraser.
52572
52573        * WebCore.exp.in:
52574        * platform/ScrollView.h:
52575        * platform/graphics/ca/mac/TileController.mm:
52576        (WebCore::TileController::computeTileCoverageRect):
52577        * platform/ios/ScrollViewIOS.mm:
52578        (WebCore::ScrollView::setScrollVelocityInformation):
52579        (WebCore::ScrollView::computeCoverageRect):
52580        * rendering/RenderLayerCompositor.cpp:
52581        (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
52582
525832014-03-21  Eric Carlson  <eric.carlson@apple.com>
52584
52585        [iOS] clean up fullscreen player controller when exiting fullscreen
52586        https://bugs.webkit.org/show_bug.cgi?id=130621
52587
52588        Reviewed by Jer Noble.
52589
52590        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
52591        (-[WebAVVideoLayer setBounds:]): Do nothing if _avPlayerController is nil.
52592        (-[WebAVVideoLayer setVideoLayerGravity:]): Ditto.
52593        (WebVideoFullscreenInterfaceAVKit::exitFullscreen): Set m_playerViewController delegate
52594            and player controller to nil.
52595
525962014-03-21  Eric Carlson  <eric.carlson@apple.com>
52597
52598        [iOS] remote command callbacks must happen on the WebThread
52599        https://bugs.webkit.org/show_bug.cgi?id=130618
52600
52601        Reviewed by Jer Noble.
52602
52603        * platform/ios/RemoteCommandListenerIOS.h:
52604        (WebCore::RemoteCommandListenerIOS::createWeakPtr):
52605        * platform/ios/RemoteCommandListenerIOS.mm:
52606        (WebCore::RemoteCommandListenerIOS::RemoteCommandListenerIOS): Dispatch commands to the
52607            main thread before making listener callbacks.
52608
526092014-03-21  Zalan Bujtas  <zalan@apple.com>
52610
52611        Subpixel rendering: Make <img> positioning subpixel aware.
52612        https://bugs.webkit.org/show_bug.cgi?id=130596
52613
52614        Reviewed by Simon Fraser.
52615
52616        Change <img> positioning from integral to device pixel. It enables us
52617        to paint hairline borders around <img> properly.
52618        This patch changes the behavior of broken image representation from constant 1 CSS px border
52619        to a dynamic 1 device px.
52620
52621        Test: fast/images/hidpi-image-position-on-device-pixels.html
52622
52623        * WebCore.exp.in:
52624        * platform/graphics/GraphicsContext.cpp:
52625        (WebCore::GraphicsContext::drawImage):
52626        * platform/graphics/GraphicsContext.h:
52627        * platform/graphics/cairo/GraphicsContextCairo.cpp:
52628        (WebCore::GraphicsContext::drawRect):
52629        * platform/graphics/cg/GraphicsContextCG.cpp:
52630        (WebCore::GraphicsContext::drawRect):
52631        * platform/graphics/wince/GraphicsContextWinCE.cpp:
52632        (WebCore::GraphicsContext::drawRect):
52633        * rendering/RenderImage.cpp:
52634        (WebCore::RenderImage::paintReplaced):
52635        (WebCore::RenderImage::paintIntoRect):
52636        * rendering/RenderImage.h:
52637        * rendering/RenderLayer.cpp:
52638        (WebCore::RenderLayer::drawPlatformResizerImage):
52639
526402014-03-21  Brent Fulgham  <bfulgham@apple.com>
52641
52642        Merge VTTScanner Code from Blink
52643        https://bugs.webkit.org/show_bug.cgi?id=130616
52644
52645        Reviewed by Eric Carlson.
52646
52647        Merged from Blink (patch by fs@opera.com):
52648        https://chromium.googlesource.com/chromium/blink/+/f1ceb058d574a1174b524c57f67350510a942071
52649        http://crbug.com/75273002
52650        https://chromium.googlesource.com/chromium/blink/+/3e2c67969486e86347b328c72c67cacabfe6f4a1
52651        http://crbug.com/134173002
52652        https://chromium.googlesource.com/chromium/blink/+/5962b7bbb001838f3fc7f24817637528b86bfd9b
52653        http://crbug.com/134153002
52654        https://chromium.googlesource.com/chromium/blink/+/6c81f51438013edca920a19fc6a31026fc562af2
52655        http://crbug.com/137033002
52656        https://chromium.googlesource.com/chromium/blink/+/fa286dca17a291da3ae8be80111e2264de6d5cfd
52657        http://crbug.com/140503004
52658        https://chromium.googlesource.com/chromium/blink/+/8f33b63aabcce7dd21dd15288d45c4eb37c02001
52659        http://crbug.com/139343006
52660        https://chromium.googlesource.com/chromium/blink/+/1872b54b908fac525f1ad9d6f15174b11e27c8af
52661        http://crbug.com/143983002
52662        https://chromium.googlesource.com/chromium/blink/+/e6494b3359e2077bd8772d86ab1fb709acf4c398
52663        http://crbug.com/144893002
52664 
52665        * CMakeLists.txt:
52666        * GNUmakefile.list.am:
52667        * WebCore.vcxproj/WebCore.vcxproj:
52668        * WebCore.vcxproj/WebCore.vcxproj.filters:
52669        * WebCore.xcodeproj/project.pbxproj:
52670        * html/track/ParsingUtilities.h: Added.
52671        (skipExactly):
52672        (skipUntil):
52673        (skipWhile):
52674        * html/track/VTTCue.cpp:
52675        (WebCore::VTTCue::markFutureAndPastNodes):
52676        (WebCore::VTTCue::settingName):
52677        (WebCore::scanPercentage):
52678        (WebCore::VTTCue::setCueSettings):
52679        * html/track/VTTCue.h:
52680        * html/track/VTTRegion.cpp:
52681        (WebCore::VTTRegion::setRegionSettings):
52682        (WebCore::VTTRegion::scanSettingName):
52683        (WebCore::parsedEntireRun):
52684        (WebCore::VTTRegion::parseSettingValue):
52685        * html/track/VTTRegion.h:
52686        * html/track/VTTScanner.cpp: Added.
52687        (WebCore::VTTScanner::VTTScanner):
52688        (WebCore::VTTScanner::scan):
52689        (WebCore::VTTScanner::scanRun):
52690        (WebCore::VTTScanner::skipRun):
52691        (WebCore::VTTScanner::extractString):
52692        (WebCore::VTTScanner::restOfInputAsString):
52693        (WebCore::VTTScanner::scanDigits):
52694        (WebCore::VTTScanner::scanFloat):
52695        * html/track/VTTScanner.h: Added.
52696        (WebCore::VTTScanner::Run::Run):
52697        (WebCore::VTTScanner::Run::start):
52698        (WebCore::VTTScanner::Run::end):
52699        (WebCore::VTTScanner::Run::isEmpty):
52700        (WebCore::VTTScanner::isAt):
52701        (WebCore::VTTScanner::isAtEnd):
52702        (WebCore::VTTScanner::match):
52703        (WebCore::VTTScanner::position):
52704        (WebCore::VTTScanner::end):
52705        (WebCore::VTTScanner::LCharPredicateAdapter):
52706        (WebCore::VTTScanner::Run::length):
52707        (WebCore::VTTScanner::scan):
52708        (WebCore::VTTScanner::skipWhile):
52709        (WebCore::VTTScanner::skipUntil):
52710        (WebCore::VTTScanner::collectWhile):
52711        (WebCore::VTTScanner::collectUntil):
52712        (WebCore::VTTScanner::seekTo):
52713        (WebCore::VTTScanner::currentChar):
52714        (WebCore::VTTScanner::advance):
52715        * html/track/WebVTTParser.cpp:
52716        (WebCore::WebVTTParser::parseFloatPercentageValue):
52717        (WebCore::WebVTTParser::parseFloatPercentageValuePair):
52718        (WebCore::WebVTTParser::collectTimingsAndSettings):
52719        (WebCore::WebVTTParser::collectTimeStamp):
52720        (WebCore::WebVTTTreeBuilder::constructTreeFromToken):
52721        * html/track/WebVTTParser.h:
52722
527232014-03-21  Benjamin Poulain  <bpoulain@apple.com>
52724
52725        Pseudo type cleanup part 2: split pseudo elements parsing
52726        https://bugs.webkit.org/show_bug.cgi?id=130370
52727
52728        Reviewed by Andreas Kling.
52729
52730        With this patch, pseudo elements are handled separately. The only thing left in
52731        the old path is compatibility pseudo elements and pseudo classes.
52732
52733        The list of special pseudo elements is now separated and is stored in SelectorPseudoElementTypeMap.in.
52734        The script makeSelectorPseudoElementsMap.py takes that list to make the pseudo elements hash table.
52735
52736        The other pseudo elements are the prefixed ones, they are filtered in CSSSelector::parsePseudoElementType().
52737
52738        All the non-compatibility selectors are removed from SelectorPseudoTypeMap.in. CSSParserSelector::setPseudoTypeValue()
52739        is updated accordingly. The next step will be to clean that part.
52740
52741        * CMakeLists.txt:
52742        * DerivedSources.make:
52743        * GNUmakefile.list.am:
52744        * WebCore.vcxproj/WebCore.vcxproj:
52745        * WebCore.vcxproj/WebCore.vcxproj.filters:
52746        * WebCore.xcodeproj/project.pbxproj:
52747        * css/CSSComputedStyleDeclaration.cpp:
52748        (WebCore::CSSComputedStyleDeclaration::CSSComputedStyleDeclaration):
52749        * css/CSSGrammar.y.in:
52750        * css/CSSParserValues.cpp:
52751        (WebCore::CSSParserSelector::parsePseudoElementSelector):
52752        (WebCore::CSSParserSelector::parsePseudoCueFunctionSelector):
52753        (WebCore::CSSParserSelector::setPseudoTypeValue):
52754        * css/CSSParserValues.h:
52755        * css/CSSSelector.cpp:
52756        (WebCore::CSSSelector::parsePseudoElementType):
52757        * css/CSSSelector.h:
52758        * css/SelectorPseudoElementTypeMap.in: Added.
52759        * css/SelectorPseudoTypeMap.h:
52760        * css/SelectorPseudoTypeMap.in:
52761        * css/html.css:
52762        (q::before):
52763        (q::after):
52764        * css/makeSelectorPseudoElementsMap.py: Added.
52765        (enumerablePseudoType):
52766        (expand_ifdef_condition):
52767        * page/DOMWindow.cpp:
52768        (WebCore::DOMWindow::getMatchedCSSRules):
52769
527702014-03-20  Andreas Kling  <akling@apple.com>
52771
52772        Less inclusion of JSCInlines.h.
52773        <https://webkit.org/b/130545>
52774
52775        Stop including JSCInlines.h from JSDOMGlobalObject.h!
52776
52777        Reviewed by Simon Fraser.
52778
52779        * ForwardingHeaders/runtime/IdentifierInlines.h: Added.
52780        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
52781        * bindings/js/JSCommandLineAPIHostCustom.cpp:
52782        * bindings/js/JSDOMGlobalObject.h:
52783        * bindings/js/JSDOMStringMapCustom.cpp:
52784        * bindings/js/JSHTMLAllCollectionCustom.cpp:
52785        * bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
52786        * bindings/js/JSLazyEventListener.cpp:
52787        * bindings/js/JSSQLResultSetRowListCustom.cpp:
52788        * bindings/js/JSStorageCustom.cpp:
52789        * bindings/js/ScriptGlobalObject.cpp:
52790        * dom/NodeIterator.cpp:
52791        * dom/TreeWalker.cpp:
52792        * testing/Internals.cpp:
52793        * testing/js/WebCoreTestSupport.cpp:
52794
527952014-03-21  Oliver Hunt  <oliver@apple.com>
52796
52797        Fix a crash when assigning an object to document.location
52798        https://bugs.webkit.org/show_bug.cgi?id=130213
52799
52800        Reviewed by Geoffrey Garen.
52801
52802        Convert location to string before we make use the document.
52803        This prevents us from attempting to navigate a frame that
52804        has already been removed.
52805
52806        Test: fast/dom/navigation-with-sideeffects-crash.html
52807
52808        * bindings/js/JSDocumentCustom.cpp:
52809        (WebCore::JSDocument::location):
52810        (WebCore::JSDocument::setLocation):
52811
528122014-03-21  Brian Burg  <bburg@apple.com>
52813
52814        Web Replay: replay controller is improperly setting user input bridge state
52815        https://bugs.webkit.org/show_bug.cgi?id=130606
52816
52817        Reviewed by Timothy Hatcher.
52818
52819        The user input bridge was being set based on the old session state,
52820        rather than the new session state.
52821
52822        * replay/ReplayController.cpp:
52823        (WebCore::ReplayController::setSessionState):
52824
528252014-03-21  James Craig  <jcraig@apple.com>
52826
52827        Web Inspector: AXI: Expose Accessibility Tree children of the selected node
52828        https://bugs.webkit.org/show_bug.cgi?id=130264
52829
52830        Reviewed by Timothy Hatcher.
52831
52832        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
52833
52834        Expose the accessibility tree children (different from DOM children) of the
52835        current node in the accessibility node inspector.
52836
52837        * inspector/InspectorDOMAgent.cpp: 
52838        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
52839        * inspector/InspectorDOMAgent.h:
52840        * inspector/protocol/DOM.json:
52841
528422014-03-21  Alex Christensen  <achristensen@webkit.org>
52843
52844        [Win] Compile fixes with video not enabled.
52845        https://bugs.webkit.org/show_bug.cgi?id=130597
52846
52847        Reviewed by Darin Adler.
52848
52849        * DerivedSources.make:
52850        Only generate UserAgentScripts.h if needed.
52851        * platform/audio/MediaSession.cpp:
52852        * platform/audio/MediaSessionManager.cpp:
52853        Only compile if video is enabled.
52854
528552014-03-21  Adenilson Cavalcanti  <cavalcantii@gmail.com>
52856
52857        Optimize FEGaussian blur
52858        https://bugs.webkit.org/show_bug.cgi?id=50881
52859
52860        Reviewed by Dirk Schulze.
52861
52862        Currently boxBlur() will calculate the filter for each channel in
52863        a loop and also uses Uint8ClampedArray::set() to write the
52864        resulting pixels into destination array.
52865
52866        Using Uint8ClampedArray::set() requires lots of unnecessary type
52867        conversions, not to mention other function calls. This patch
52868        updates the original written by Simon Fraser to apply cleanly to current
52869        trunk.
52870
52871        It also implements code to handle EdgeModes and finally avoids use
52872        of ::set() in the newly added boxBlurAlphaOnly()
52873        function. Assignment of calculated pixel values rely on pointers.
52874
52875        No new tests, no change on behavior.
52876
52877        * platform/graphics/filters/FEGaussianBlur.cpp:
52878        (WebCore::boxBlurAlphaOnly): Specialized version for alpha only cases.
52879        (WebCore::boxBlur):
52880
528812014-03-21  Simon Fraser  <simon.fraser@apple.com>
52882
52883        unobscuredContentRect() should have the same signature on iOS and other platforms,
52884        and should not recurse on iOS.
52885        https://bugs.webkit.org/show_bug.cgi?id=130604
52886        <rdar://problem/16392587>
52887
52888        Reviewed by Tim Horton and Beth Dakin.
52889
52890        Having different signatures on different platforms is a recipe for
52891        build breakage. Give the iOS unobscuredContentRect() an unused 
52892        VisibleContentRectIncludesScrollbars parameter.
52893        
52894        Also avoid recursion via unobscuredContentRect() calling visibleContentRectInternal().
52895
52896        * WebCore.exp.in:
52897        * platform/ScrollView.cpp:
52898        (WebCore::ScrollView::unobscuredContentRect):
52899        (WebCore::ScrollView::unobscuredContentRectInternal):
52900        (WebCore::ScrollView::visibleContentRectInternal):
52901        * platform/ScrollView.h:
52902        (WebCore::ScrollView::unobscuredContentRectIncludingScrollbars):
52903        * platform/ios/ScrollViewIOS.mm:
52904        (WebCore::ScrollView::unobscuredContentRect):
52905
529062014-03-21  Brent Fulgham  <bfulgham@apple.com>
52907
52908        Handle recovery on "timestamp-looking" lines in the WebVTT parser
52909        https://bugs.webkit.org/show_bug.cgi?id=130610
52910
52911        Reviewed by Eric Carlson.
52912
52913        Merged from Blink (patch by fs@opera.com):
52914        https://chromium.googlesource.com/chromium/blink/+/b669a380efbffe25f3b154b026b57b9822ce08e2
52915        http://crbug.com/75273002
52916
52917        Tests: media/track/track-webvtt-tc031-cue-recovery.html
52918               media/track/track-webvtt-tc032-degenerate-cues.html
52919
52920        * html/track/WebVTTParser.cpp:
52921        (WebCore::WebVTTParser::parse):
52922        (WebCore::WebVTTParser::collectCueText):
52923        (WebCore::WebVTTParser::recoverCue):
52924        (WebCore::WebVTTParser::ignoreBadCue):
52925        * html/track/WebVTTParser.h:
52926
529272014-03-21  Andreas Kling  <akling@apple.com>
52928
52929        Remove unused RenderView::repaintRectangleInViewAndCompositedLayers().
52930        <https://webkit.org/b/130605>
52931
52932        Reviewed by Antti Koivisto.
52933
52934        * rendering/RenderView.cpp:
52935        * rendering/RenderView.h:
52936
529372014-03-21  David Hyatt  <hyatt@apple.com>
52938
52939        Crash in RenderBlock::addChildIgnoringAnonymousColumnBlocks.
52940        https://bugs.webkit.org/show_bug.cgi?id=129948
52941        <rdar://problem/16074072>
52942        
52943        Reviewed by Simon Fraser.
52944
52945        When the marker was placed for multi-column list items, it was being inserted
52946        into the list item itself. Even though the add code in RenderBlock did the right
52947        thing and put the marker inside the multi-column flow thread, the list item code
52948        passed in a beforeChild that was computed using the incorrect parent. This resulted
52949        in the flow thread being used both as the parent of the marker and the sibling of
52950        the marker.
52951        
52952        The fix is to add some code to RenderListItem to make sure it uses the multi-column
52953        flow thread if it exists both as the parent of the marker and as the basis for the
52954        computation of the sibling that the marker should be placed in front of.
52955
52956        Added fast/multicol/multicol-li-crash.html
52957
52958        * rendering/RenderListItem.cpp:
52959        (WebCore::RenderListItem::insertOrMoveMarkerRendererIfNeeded):
52960
529612014-03-20  Andreas Kling  <akling@apple.com>
52962
52963        Stop pulling in JSCInlines.h all over the place.
52964        <https://webkit.org/b/130105>
52965
52966        JSDOMBinding.h is included by everyone and their uncle, so try to
52967        cut down on the amount of JSC *Inlines.h it includes.
52968
52969        Reviewed by Geoff Garen.
52970
52971        * ForwardingHeaders/heap/SlotVisitorInlines.h: Added.
52972        * ForwardingHeaders/runtime/JSCJSValueInlines.h: Added.
52973        * ForwardingHeaders/runtime/JSCellInlines.h: Added.
52974        * ForwardingHeaders/runtime/StructureInlines.h: Added.
52975        * bindings/js/JSDOMBinding.h:
52976
529772014-03-21  David Kilzer  <ddkilzer@apple.com>
52978
52979        WindowFeatures.{x|y|width|height} are not initialized
52980        <http://webkit.org/b/130547>
52981        <rdar://problem/16383151>
52982
52983        Reviewed by Darin Adler.
52984
52985        Based on a Blink patch in CRBug 342591 by zhaoqin.
52986
52987        * page/WindowFeatures.cpp:
52988        (WebCore::WindowFeatures::WindowFeatures):
52989        - Initialize x, y, width, height in String constructor.
52990        - Move 'resizeable' variable to short-hand initialization since
52991          it is true in both cases.
52992        - Use String::isEmpty() instead of checking its length.
52993        * page/WindowFeatures.h:
52994        (WebCore::WindowFeatures::WindowFeatures): Initialize x, y,
52995        width, height in no-argument constructor.
52996
529972014-03-21  Sergio Villar Senin  <svillar@igalia.com>
52998
52999        Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T> in bridge/
53000        https://bugs.webkit.org/show_bug.cgi?id=130601
53001
53002        Reviewed by Darin Adler.
53003
53004        * bridge/IdentifierRep.cpp:
53005        (WebCore::identifierSet):
53006        (WebCore::intIdentifierMap):
53007        (WebCore::stringIdentifierMap):
53008        * bridge/NP_jsobject.cpp:
53009        (objectMap):
53010        * bridge/runtime_root.cpp:
53011        (JSC::Bindings::rootObjectSet): Return a reference instead of
53012        a pointer.
53013        (JSC::Bindings::findProtectingRootObject):
53014        (JSC::Bindings::findRootObject):
53015        (JSC::Bindings::RootObject::RootObject):
53016        (JSC::Bindings::RootObject::invalidate):
53017
530182014-03-21  Michael Saboff  <msaboff@apple.com>
53019
53020        Change CodeGeneratorJS.pm special cases for "DOMWindow" to be general purpose
53021        https://bugs.webkit.org/show_bug.cgi?id=130553
53022
53023        Reviewed by Geoffrey Garen.
53024
53025        Eliminated 'if ($interfaceName eq "DOMWindow") {' sections in CodeGeneratorJS where
53026        it was used to do DOMWindow specific casting to a JSObject, either a JSDOMWindow* or
53027        a JSDOMWindowShell*.  Instead the code generator will use the existing 
53028        JSDOMWindow* toJSDOMWindow(JSValue value) function based on a newly added attribute
53029        "CustomProxyToJSObject".  That attribute will emit a call to the function
53030        ${className}* to${className}(JSValue).
53031
53032        This is being done to clean up the code generator and for a subsequent patch that
53033        will use a similar custom to{className} function for workers,
53034        JSDedicatedWorkerGlobalScope* toJSDedicatedWorkerGlobalScope(JSValue).
53035
53036        Changes covered by existing tests.
53037
53038        * bindings/scripts/CodeGeneratorJS.pm:
53039        (GenerateImplementation):
53040        * bindings/scripts/IDLAttributes.txt:
53041        * page/DOMWindow.idl:
53042
530432014-03-21  Krzysztof Czech  <k.czech@samsung.com>
53044
53045        AX: Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed
53046        https://bugs.webkit.org/show_bug.cgi?id=130594
53047
53048        Reviewed by Chris Fleizach.
53049
53050        Use static NeverDestroyed<T> in new code.
53051
53052        * accessibility/AccessibilityMediaControls.cpp:
53053        (WebCore::AccessibilityMediaControl::controlTypeName):
53054        (WebCore::AccessibilityMediaControl::title):
53055        (WebCore::AccessibilityMediaControlsContainer::elementTypeName):
53056        (WebCore::AccessibilityMediaTimeline::helpText):
53057        (WebCore::AccessibilityMediaTimeDisplay::accessibilityDescription):
53058        * accessibility/AccessibilityObject.cpp:
53059        (WebCore::AccessibilityObject::actionVerb):
53060        * accessibility/AccessibilityRenderObject.cpp:
53061        (WebCore::AccessibilityRenderObject::inheritsPresentationalRole):
53062        (WebCore::AccessibilityRenderObject::ariaLiveRegionStatus):
53063        (WebCore::AccessibilityRenderObject::ariaLiveRegionRelevant):
53064        (WebCore::AccessibilityRenderObject::actionVerb):
53065        * accessibility/atk/AXObjectCacheAtk.cpp:
53066        (WebCore::notifyChildrenSelectionChange):
53067
530682014-03-20  Brent Fulgham  <bfulgham@apple.com>
53069
53070        Merge WebVTT Tokenizer Updates
53071        https://bugs.webkit.org/show_bug.cgi?id=130565
53072
53073        Reviewed by Eric Carlson.
53074
53075        Merged from Blink (patch by fs@opera.com):
53076        https://chromium.googlesource.com/chromium/blink/+/923db263aa65d6efd71c5b55708ad7eea6b23f53
53077        http://crbug.com/73813002
53078        https://chromium.googlesource.com/chromium/blink/+/48375b1d56b2d8850ae93a6c6fb01c69fae82c75
53079        http://crbug.com/77553004
53080        https://chromium.googlesource.com/chromium/blink/+/98d4fc4f5cb716a31d11907120b10538d4ba0f09
53081        http://crbug.com/78833002
53082        https://chromium.googlesource.com/chromium/blink/+/0e53d4f9f140e979b7f32de495551684bc7f4cd2
53083        http://crbug.com/81113003
53084        https://chromium.googlesource.com/chromium/blink/+/730ef1e7f9a1919964f7e74e7ccb2f343e10a148
53085        http://crbug.com/97103002
53086        https://chromium.googlesource.com/chromium/blink/+/c373ee914ffabeaf833939129538251d8f2f4eca
53087        http://crbug.com/98763004
53088        https://chromium.googlesource.com/chromium/blink/+/4ddb4d57948228fa05e49e06bd58a1179c09f212
53089        http://crbug.com/118263002
53090 
53091        * html/track/VTTCue.cpp:
53092        (WebCore::scanPercentage):
53093        (WebCore::VTTCue::setCueSettings):
53094        * html/track/WebVTTParser.cpp:
53095        (WebCore::WebVTTTreeBuilder::buildFromString):
53096        (WebCore::WebVTTTreeBuilder::constructTreeFromToken):
53097        * html/track/WebVTTToken.h:
53098        (WebCore::WebVTTToken::WebVTTToken):
53099        (WebCore::WebVTTToken::StringToken):
53100        (WebCore::WebVTTToken::StartTag):
53101        (WebCore::WebVTTToken::EndTag):
53102        (WebCore::WebVTTToken::TimestampTag):
53103        (WebCore::WebVTTToken::type):
53104        (WebCore::WebVTTToken::name):
53105        (WebCore::WebVTTToken::characters):
53106        (WebCore::WebVTTToken::classes):
53107        (WebCore::WebVTTToken::annotation):
53108        * html/track/WebVTTTokenizer.cpp:
53109        (WebCore::addNewClass):
53110        (WebCore::emitToken):
53111        (WebCore::advanceAndEmitToken):
53112        (WebCore::WebVTTTokenizer::WebVTTTokenizer):
53113        (WebCore::WebVTTTokenizer::nextToken):
53114        * html/track/WebVTTTokenizer.h:
53115        (WebCore::WebVTTTokenizer::shouldSkipNullCharacters):
53116
531172014-03-21  Frédéric Wang  <fred.wang@free.fr>
53118
53119        Bug 130345 - Refine childShouldCreateRenderer for MathML elements
53120        https://bugs.webkit.org/show_bug.cgi?id=130345
53121
53122        Reviewed by Chris Fleizach.
53123
53124        This is a follow-up of bug 124128. We add more restrictions on foreign
53125        content of MathML elements.
53126
53127        Tests: mathml/presentation/annotation-children.html
53128               mathml/presentation/foreign-element-in-token.html
53129
53130        * mathml/MathMLElement.cpp:
53131        (WebCore::MathMLElement::isPresentationMathML): fix line wrapping
53132        (WebCore::MathMLElement::isPhrasingContent):
53133        - move the function from MathMLSelectElement.cpp
53134        - add the constraint "is descendant of a map element" for area.
53135        (WebCore::MathMLElement::isFlowContent): new function to test flow content.
53136        (WebCore::MathMLElement::childShouldCreateRenderer):
53137        - remove annotation since it is now tested in MathMLTextElement
53138        - refine testing of annotation-xml
53139        - do not create renderer for text content in MathML. Such content is only allowed inside token elements.
53140        * mathml/MathMLElement.h: Declare isPhrasingContent and isFlowContent.
53141        * mathml/MathMLSelectElement.cpp: Add new function to test MathML/SVG/HTML encodings.
53142        (WebCore::MathMLSelectElement::isMathMLEncoding):
53143        (WebCore::MathMLSelectElement::isSVGEncoding):
53144        (WebCore::MathMLSelectElement::isHTMLEncoding):
53145        (WebCore::MathMLSelectElement::getSelectedSemanticsChild): use the new functions.
53146        * mathml/MathMLSelectElement.h: Declare the new public functions.
53147        * mathml/MathMLTextElement.cpp: remove the isPhrasingContent function.
53148        (WebCore::MathMLTextElement::childShouldCreateRenderer): Just in case, use the generic StyledElement::childShouldCreateRenderer.
53149
531502014-03-21  Darin Adler  <darin@apple.com>
53151
53152        Stop using deprecatedCharacters in WebCore/platform/win
53153        https://bugs.webkit.org/show_bug.cgi?id=130515
53154
53155        Reviewed by Brent Fulgham.
53156
53157        * platform/graphics/TextRun.h:
53158        (WebCore::TextRun::TextRun): Add a constructor that takes a StringView.
53159        Later, we might want to exclusively use the StringView version and remove
53160        some of the others.
53161        (WebCore::TextRun::setText): Add a version of this function that takes a StringView.
53162
53163        * platform/graphics/win/FontCacheWin.cpp:
53164        (WebCore::FontCache::systemFallbackForCharacters): Use StringView::getCharactersWithUpconvert.
53165        (WebCore::createGDIFont): Ditto.
53166        (WebCore::FontCache::getTraitsInFamily): Ditto.
53167        * platform/win/BString.cpp:
53168        (WebCore::BString::BString): Use StringView::upconvertedCharacters.
53169        * platform/win/ClipboardUtilitiesWin.cpp:
53170        (WebCore::createGlobalData): Use StringView::getCharactersWithUpconvert.
53171        * platform/win/FileSystemWin.cpp:
53172        (WebCore::pathByAppendingComponent): Use StringBuilder and StringView::getCharactersWithUpconvert.
53173        (WebCore::fileSystemRepresentation): Use StringView::upconvertedCharacters.
53174        * platform/win/PasteboardWin.cpp:
53175        (WebCore::filesystemPathFromUrlOrTitle): Use StringView::getCharactersWithUpconvert.
53176        (WebCore::Pasteboard::writeURLToDataObject): Ditto.
53177        (WebCore::createGlobalImageFileDescriptor): Ditto.
53178
53179        * platform/win/PopupMenuWin.cpp:
53180        (WebCore::PopupMenuWin::calculatePositionAndSize): Use the new TextRun constructor.
53181        * platform/win/WebCoreTextRenderer.cpp:
53182        (WebCore::doDrawTextAtPoint): Ditto.
53183
531842014-03-21  Zalan Bujtas  <zalan@apple.com>
53185
53186        Subpixel rendering: RenderBox is positioned off by one when non-compositing transform is present.
53187        https://bugs.webkit.org/show_bug.cgi?id=130430
53188
53189        Reviewed by Simon Fraser.
53190
53191        div {
53192            position: absolute;
53193             top: 10.25px;
53194             left: 10.25px;
53195         }
53196
53197         The <div> with (10.25px, 10.25px) is painted to (10.5px, 10.5px) after device pixel snapping on 2x display.
53198         Moving <div> to its own RenderLayer should not change the painting position.
53199
53200         div {
53201             position: absolute;
53202             top: 10.25px;
53203             left: 10.25px;
53204             -webkit-transform: rotate(0deg);
53205         }
53206
53207        When we paint the RenderLayer's content, the graphics context is translated by the rounded value of
53208        renderer's offset from parent.
53209
53210            (10.25px,10.25px) -> rounded to (10.5px,10.5px).
53211
53212        When the translate moves the graphics context's origin over the renderer's top-left position,
53213        the renderer's relative top-left coordinates end up being negative.
53214
53215            Graphics context translated by (10.5px,10.5px) -> pushes renderer's relative top-left coords to (-0.25px,-0.25px)
53216
53217        When we round (pixel snap) these negative coordinates, half-way values get translated to the wrong direction.
53218
53219        (relative coords (-0.25px,-0.25px) -> pixel snapped to (-0.5px,-0.5px) -> final absolute(painting) coords (10px,10px))
53220
53221        This patch changes the rounding to flooring to ensure that the relative top-left position never gets negative as the result
53222        of subpixel shifting.
53223
53224        Tests: compositing/hidpi-box-positioned-off-by-one-when-non-compositing-transform-is-present.html
53225               fast/layers/hidpi-box-positioned-off-by-one-when-transform-is-present.html
53226
53227        * css/CSSComputedStyleDeclaration.cpp:
53228        (WebCore::computedTransform):
53229        * rendering/RenderLayer.cpp:
53230        (WebCore::RenderLayer::updateTransform):
53231        (WebCore::RenderLayer::currentTransform):
53232        (WebCore::RenderLayer::paintLayerByApplyingTransform):
53233        * rendering/RenderLayerBacking.cpp:
53234        (WebCore::RenderLayerBacking::updateTransform):
53235        * rendering/style/RenderStyle.cpp:
53236        * rendering/style/RenderStyle.h:
53237        * svg/SVGTextElement.cpp:
53238        (WebCore::SVGTextElement::animatedLocalTransform):
53239
532402014-03-21  Pratik Solanki  <psolanki@apple.com>
53241
53242        Unreviewed. iOS build fix after r166046.
53243
53244        * WebCore.exp.in:
53245
532462014-03-21  Laszlo Vidacs  <lvidacs.u-szeged@partner.samsung.com>
53247
53248        Fix the !ENABLE(FILTERS) build
53249        https://bugs.webkit.org/show_bug.cgi?id=130394
53250
53251        Reviewed by Gyuyoung Kim.
53252
53253        Add missing includes in rendering to fix compile errors, and include JSC headers to ImageBuffer.h to fix linker errors.
53254
53255        * platform/graphics/ImageBuffer.h:
53256        * rendering/svg/RenderSVGImage.cpp:
53257        * rendering/svg/RenderSVGRoot.cpp:
53258
532592014-03-21  Commit Queue  <commit-queue@webkit.org>
53260
53261        Unreviewed, rolling out r166052.
53262        https://bugs.webkit.org/show_bug.cgi?id=130571
53263
53264        It broke EFL build (Requested by KaL on #webkit).
53265
53266        Reverted changeset:
53267
53268        "[GTK] Use GMainLoopSource for idle and timeout sources in
53269        WebCore"
53270        https://bugs.webkit.org/show_bug.cgi?id=130078
53271        http://trac.webkit.org/changeset/166052
53272
532732014-03-21  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
53274
53275        Add *explicit* keyword to avoid implicit type conversion
53276        https://bugs.webkit.org/show_bug.cgi?id=130568
53277
53278        Reviewed by Antti Koivisto.
53279
53280        Constructors of RemoteFontFaceSource, SVGDocumentExtensions, XMLDocumentParserScope,
53281        and WorkerScriptDebugServer need to use *explicit* keyword because they have an argument.
53282        Besides removed a meaningless argument name.
53283
53284        * svg/SVGDocumentExtensions.h:
53285        * xml/parser/XMLDocumentParserScope.h:
53286
532872014-03-20  Sergio Villar Senin  <svillar@igalia.com>
53288
53289        Modules: replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T>
53290        https://bugs.webkit.org/show_bug.cgi?id=130407
53291
53292        Reviewed by Darin Adler.
53293
53294        * Modules/encryptedmedia/CDM.cpp:
53295        (WebCore::installedCDMFactories):
53296        * Modules/mediasource/MediaSourceRegistry.cpp:
53297        (WebCore::MediaSourceRegistry::registry):
53298        * Modules/mediasource/MediaSourceRegistry.h:
53299        * Modules/mediastream/MediaStreamRegistry.cpp:
53300        (WebCore::MediaStreamRegistry::registry):
53301
533022014-03-20  Carlos Garcia Campos  <cgarcia@igalia.com>
53303
53304        [GTK] Use GMainLoopSource for idle and timeout sources in WebCore
53305        https://bugs.webkit.org/show_bug.cgi?id=130078
53306
53307        Reviewed by Philippe Normand.
53308
53309        * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
53310        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp:
53311        * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h:
53312        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
53313        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
53314        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
53315        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
53316        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
53317        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h:
53318        * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
53319        * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
53320        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
53321        * platform/gtk/GtkDragAndDropHelper.cpp:
53322        * platform/gtk/SharedTimerGtk.cpp:
53323
533242014-03-21  Andreas Kling  <akling@apple.com>
53325
53326        HTMLFrameOwnerElement should obey the SubframeLoadingDisabler when creating subframes
53327        <rdar://problem/15675780>
53328
53329        Merge Blink r156744 by Adam Klein.
53330
53331        Test: fast/frames/set-iframe-src-in-pagehide-crash.html
53332
53333        * loader/SubframeLoader.cpp:
53334        (WebCore::SubframeLoader::loadSubframe):
53335
533362014-03-21  Darin Adler  <darin@apple.com>
53337
53338        Improve idiom used for string building in a few places
53339        https://bugs.webkit.org/show_bug.cgi?id=130561
53340
53341        Reviewed by Andreas Kling.
53342
53343        * Modules/indexeddb/IDBKeyData.cpp:
53344        (WebCore::IDBKeyData::loggingString): Use a StringBuilder, and get rid of
53345        an an unnecessary additional string allocation.
53346
53347        * Modules/websockets/ThreadableWebSocketChannel.cpp:
53348        (WebCore::ThreadableWebSocketChannel::create): Use StringBuilder.
53349
53350        * html/FTPDirectoryDocument.cpp:
53351        (WebCore::FTPDirectoryDocumentParser::createTDForFilename): Do a more efficient
53352        string concatenation.
53353        * html/ValidationMessage.cpp:
53354        (WebCore::ValidationMessage::updateValidationMessage): Ditto.
53355
53356        * inspector/InspectorApplicationCacheAgent.cpp:
53357        (WebCore::InspectorApplicationCacheAgent::buildObjectForApplicationCacheResource):
53358        Use a StringBuilder.
53359
53360        * inspector/InspectorStyleSheet.cpp: 
53361        (WebCore::InspectorStyle::shorthandValue): Use a StringBuilder.
53362
53363        * inspector/InspectorStyleTextEditor.cpp:
53364        (WebCore::InspectorStyleTextEditor::insertProperty): Use a more efficient idiom
53365        for string concatenation.
53366        (WebCore::InspectorStyleTextEditor::internalReplaceProperty): Ditto.
53367        * loader/FormSubmission.cpp:
53368        (WebCore::appendMailtoPostFormDataToURL): Ditto.
53369
53370        * page/Frame.cpp:
53371        (WebCore::createRegExpForLabels): Use a StringBuilder.
53372
53373        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
53374        (WebCore::InbandTextTrackPrivateAVF::processCueAttributes): Use a more efficient
53375        idiom for string concatenation.
53376
53377        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
53378        (WebCore::GraphicsContext3D::getUnmangledInfoLog): Use a StringBuilder.
53379
53380        * platform/network/MIMEHeader.cpp:
53381        (WebCore::MIMEHeader::parseHeader): Use a more efficient idiom for string
53382        concatenation.
53383        * platform/network/ResourceResponseBase.cpp:
53384        (WebCore::ResourceResponseBase::addHTTPHeaderField): Ditto.
53385        * rendering/RenderLayerCompositor.cpp:
53386        (WebCore::RenderLayerCompositor::layerTreeAsText): Ditto.
53387
53388        * rendering/RenderText.cpp:
53389        (WebCore::RenderText::secureText): Create a new string with the substring
53390        function rather than with the append function.
53391
53392        * xml/XMLHttpRequest.cpp:
53393        (WebCore::XMLHttpRequest::setRequestHeaderInternal): Use a more efficient idiom
53394        for string concatenation.
53395
533962014-03-21  Darin Adler  <darin@apple.com>
53397
53398        Add a combined decodeAndFlush to TextResourceDecoder
53399        https://bugs.webkit.org/show_bug.cgi?id=130560
53400
53401        Reviewed by Andreas Kling.
53402
53403        * WebCore.exp.in: Added new symbol for decodeAndFlush. Also re-did
53404        the geometry types #if so it would sort more logically.
53405
53406        * fileapi/FileReaderLoader.cpp:
53407        (WebCore::FileReaderLoader::convertToText): Use decodeAndFlush.
53408        * inspector/InspectorPageAgent.cpp:
53409        (WebCore::InspectorPageAgent::cachedResourceContent): Ditto.
53410        * inspector/NetworkResourcesData.cpp:
53411        (WebCore::NetworkResourcesData::ResourceData::decodeDataToContent): Ditto.
53412
53413        * loader/TextResourceDecoder.cpp:
53414        (WebCore::TextResourceDecoder::decodeAndFlush): Added.
53415        * loader/TextResourceDecoder.h: Ditto.
53416
53417        * loader/appcache/ManifestParser.cpp:
53418        (WebCore::parseManifest): Use decodeAndFlush.
53419        * loader/cache/CachedCSSStyleSheet.cpp:
53420        (WebCore::CachedCSSStyleSheet::sheetText): Ditto.
53421        (WebCore::CachedCSSStyleSheet::finishLoading): Ditto.
53422
53423        * loader/cache/CachedFont.cpp:
53424        (WebCore::CachedFont::ensureSVGFontData): Use decodeAndFlush. Also use nullptr.
53425        (WebCore::CachedFont::getSVGFontById): Use descendantsOfType<SVGFontElement>
53426        instead of using a NodeList. Much more efficient!
53427
53428        * loader/cache/CachedSVGDocument.cpp:
53429        (WebCore::CachedSVGDocument::finishLoading): Use decodeAndFlush.
53430        * loader/cache/CachedScript.cpp:
53431        (WebCore::CachedScript::script): Ditto.
53432        * loader/cache/CachedXSLStyleSheet.cpp:
53433        (WebCore::CachedXSLStyleSheet::finishLoading): Ditto.
53434        * page/Page.cpp:
53435        (WebCore::Page::userStyleSheet): Ditto.
53436
534372014-03-20  Darin Adler  <darin@apple.com>
53438
53439        Remove a couple of unused functions from CSSOMUtils
53440        https://bugs.webkit.org/show_bug.cgi?id=130558
53441
53442        Reviewed by Andreas Kling.
53443
53444        * css/CSSOMUtils.cpp: Remove String overloads. Callers all use the StringBuilder
53445        ones, which is good since that is a more efficient idiom.
53446        * css/CSSOMUtils.h: Ditto.
53447
534482014-03-20  Pratik Solanki  <psolanki@apple.com>
53449
53450        Unreviewed. iOS build fix after r166017, r166032.
53451
53452        * platform/ScrollView.cpp:
53453        (WebCore::ScrollView::visibleContentRectInternal):
53454
534552014-03-20  Hyowon Kim  <hw1008.kim@samsung.com>
53456
53457        Move to using std::unique_ptr for EFL objects.
53458        https://bugs.webkit.org/show_bug.cgi?id=129853
53459
53460        Reviewed by Gyuyoung Kim.
53461
53462        EflUniquePtr is a template alias of std::unique_ptr
53463        with a custom deleter for each Efl Objects, which is motivated by GUniquePtr.
53464        This patch replaces uses of OwnPtr and PassOwnPtr for Efl objects with EflUniquePtr.
53465
53466        No new tests. No new functionality.
53467
53468        * platform/efl/EflScreenUtilities.h:
53469        * platform/efl/RenderThemeEfl.cpp:
53470        (WebCore::RenderThemeEfl::ThemePartCacheEntry::create):
53471        (WebCore::RenderThemeEfl::loadTheme):
53472        * platform/efl/RenderThemeEfl.h:
53473        * platform/graphics/Icon.h:
53474        * platform/graphics/efl/EvasGLContext.h:
53475        (WebCore::EvasGLContext::create):
53476        * platform/graphics/efl/EvasGLSurface.h:
53477        (WebCore::EvasGLSurface::create):
53478
534792014-03-20  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
53480
53481        [EFL][GTK] Get CMake to find Freetype2 properly
53482        https://bugs.webkit.org/show_bug.cgi?id=130150
53483
53484        Reviewed by Martin Robinson.
53485
53486        Newer versions of CMake are not able to find Freetype2 correctly.
53487        FindFreetype2.cmake checks for the version number in freetype.h header, since it seems that bug exists in
53488        freetype2 repo, because a completely different version number is found in freetype2.pc.
53489
53490        * PlatformEfl.cmake:
53491        * PlatformGTK.cmake:
53492
534932014-03-20  Martin Robinson  <mrobinson@igalia.com>
53494
53495        [GTK] Suppress errors about using gdk_threads_enter gdk_threads_leave
53496        https://bugs.webkit.org/show_bug.cgi?id=130517
53497
53498        Reviewed by Sergio Villar Senin.
53499
53500        * plugins/gtk/gtk2xtbin.c: Use GCC suppression to suppress errors about deprecations.
53501
535022014-03-20  Simon Fraser  <simon.fraser@apple.com>
53503
53504        Cleanup in aisle r166017.
53505        
53506        visibleContentRectInternal() was dropping the scrollbar
53507        inclusiveness on the floor, and we need to reset the top inset
53508        between tests.
53509
53510        * platform/ScrollView.cpp:
53511        (WebCore::ScrollView::visibleContentRectInternal):
53512        * testing/Internals.cpp:
53513        (WebCore::Internals::resetToConsistentState):
53514
535152014-03-20  Enrica Casucci  <enrica@apple.com>
53516
53517        Build fix.
53518
53519        Removing unused variable.
53520        
53521        * page/FrameView.cpp:
53522        (WebCore::FrameView::didPaintContents):
53523
535242014-03-20  Brent Fulgham  <bfulgham@apple.com>
53525
53526        Rename TextTrackRegion/TextTrackRegionList to VTTRegion/VTTRegionList
53527        https://bugs.webkit.org/show_bug.cgi?id=130543
53528
53529        Reviewed by Dean Jackson.
53530
53531        Merged from Blink (patch by philipj@opera.com):
53532        https://chromium.googlesource.com/chromium/blink/+/69ee6d3399d64163e4936ac1bde222036c54c4b8
53533        http://crbug.com/55653003
53534
53535        Tests: media/track/regions-webvtt/vtt-region-constructor.html
53536               media/track/regions-webvtt/vtt-region-display.html
53537               media/track/regions-webvtt/vtt-region-dom-layout.html
53538               media/track/regions-webvtt/vtt-region-list.html
53539               media/track/regions-webvtt/vtt-region-parser.html
53540
53541        * Configurations/FeatureDefines.xcconfig:
53542        * DerivedSources.make:
53543        * WebCore.xcodeproj/project.pbxproj:
53544        * html/shadow/MediaControlElements.cpp:
53545        (WebCore::MediaControlTextTrackContainerElement::updateDisplay):
53546        * html/track/LoadableTextTrack.cpp:
53547        (WebCore::LoadableTextTrack::newRegionsAvailable):
53548        * html/track/TextTrack.cpp:
53549        (WebCore::TextTrack::ensureVTTRegionList):
53550        (WebCore::TextTrack::regions):
53551        (WebCore::TextTrack::addRegion):
53552        (WebCore::TextTrack::removeRegion):
53553        * html/track/TextTrack.h:
53554        * html/track/TextTrack.idl:
53555        * html/track/TextTrackCue.cpp:
53556        * html/track/TextTrackRegion.cpp: Removed.
53557        * html/track/TextTrackRegion.h: Removed.
53558        * html/track/TextTrackRegion.idl: Removed.
53559        * html/track/TextTrackRegionList.cpp: Removed.
53560        * html/track/TextTrackRegionList.h: Removed.
53561        * html/track/TextTrackRegionList.idl: Removed.
53562        * html/track/VTTCue.cpp:
53563        (WebCore::VTTCue::removeDisplayTree):
53564        * html/track/VTTRegion.cpp: Copied from Source/WebCore/html/track/TextTrackRegion.cpp.
53565        (WebCore::VTTRegion::VTTRegion):
53566        (WebCore::VTTRegion::~VTTRegion):
53567        (WebCore::VTTRegion::setTrack):
53568        (WebCore::VTTRegion::setId):
53569        (WebCore::VTTRegion::setWidth):
53570        (WebCore::VTTRegion::setHeight):
53571        (WebCore::VTTRegion::setRegionAnchorX):
53572        (WebCore::VTTRegion::setRegionAnchorY):
53573        (WebCore::VTTRegion::setViewportAnchorX):
53574        (WebCore::VTTRegion::setViewportAnchorY):
53575        (WebCore::VTTRegion::scroll):
53576        (WebCore::VTTRegion::setScroll):
53577        (WebCore::VTTRegion::updateParametersFromRegion):
53578        (WebCore::VTTRegion::setRegionSettings):
53579        (WebCore::VTTRegion::getSettingFromString):
53580        (WebCore::VTTRegion::parseSettingValue):
53581        (WebCore::VTTRegion::parseSetting):
53582        (WebCore::VTTRegion::textTrackCueContainerScrollingClass):
53583        (WebCore::VTTRegion::textTrackCueContainerShadowPseudoId):
53584        (WebCore::VTTRegion::textTrackRegionShadowPseudoId):
53585        (WebCore::VTTRegion::appendTextTrackCueBox):
53586        (WebCore::VTTRegion::displayLastTextTrackCueBox):
53587        (WebCore::VTTRegion::willRemoveTextTrackCueBox):
53588        (WebCore::VTTRegion::getDisplayTree):
53589        (WebCore::VTTRegion::prepareRegionDisplayTree):
53590        (WebCore::VTTRegion::startTimer):
53591        (WebCore::VTTRegion::stopTimer):
53592        (WebCore::VTTRegion::scrollTimerFired):
53593        * html/track/VTTRegion.h: Copied from Source/WebCore/html/track/TextTrackRegion.h.
53594        (WebCore::VTTRegion::create):
53595        * html/track/VTTRegion.idl: Copied from Source/WebCore/html/track/TextTrackRegion.idl.
53596        * html/track/VTTRegionList.cpp: Copied from Source/WebCore/html/track/TextTrackRegionList.cpp.
53597        (WebCore::VTTRegionList::VTTRegionList):
53598        (WebCore::VTTRegionList::length):
53599        (WebCore::VTTRegionList::item):
53600        (WebCore::VTTRegionList::getRegionById):
53601        (WebCore::VTTRegionList::add):
53602        (WebCore::VTTRegionList::remove):
53603        (WebCore::VTTRegionList::clear):
53604        * html/track/VTTRegionList.h: Copied from Source/WebCore/html/track/TextTrackRegionList.h.
53605        (WebCore::VTTRegionList::create):
53606        (WebCore::VTTRegionList::~VTTRegionList):
53607        * html/track/VTTRegionList.idl: Copied from Source/WebCore/html/track/TextTrackRegionList.idl.
53608        * html/track/WebVTTParser.cpp:
53609        (WebCore::WebVTTParser::parseFloatPercentageValue):
53610        (WebCore::WebVTTParser::getNewRegions):
53611        (WebCore::WebVTTParser::createNewRegion):
53612        * html/track/WebVTTParser.h:
53613        * loader/TextTrackLoader.cpp:
53614        (WebCore::TextTrackLoader::getNewRegions):
53615        * loader/TextTrackLoader.h:
53616
536172014-03-20  Simon Fraser  <simon.fraser@apple.com>
53618
53619        Fix the iOS build.
53620
53621        * page/FrameView.cpp:
53622        (WebCore::FrameView::willPaintContents):
53623        (WebCore::FrameView::didPaintContents):
53624
536252014-03-20  Hans Muller  <hmuller@adobe.com>
53626
53627        [CSS Shapes] clamp RasterShape shapeMargin to reference box size
53628        https://bugs.webkit.org/show_bug.cgi?id=130350
53629
53630        Reviewed by Dean Jackson.
53631
53632        Corrected the way the maximum shape-margin value was computed for image valued
53633        shapes. The limiting case is an image with just one above threshold pixel. The
53634        largest possible value for shapeMargin is the radius of a circle that encloses
53635        the size of the shape-outside element's margin-box, since the shape-outside's
53636        boundary is clipped to the margin-box. The radius is just sqrt(2) * the margin-box's
53637        largest dimension.
53638
53639        Also cleaned up up a few poorly named parameters.
53640
53641        Test: fast/shapes/shape-outside-floats/shape-outside-one-pixel.html
53642
53643        * rendering/shapes/RasterShape.cpp:
53644        (WebCore::RasterShape::marginIntervals):
53645        * rendering/shapes/RasterShape.h:
53646        (WebCore::RasterShape::RasterShape):
53647        * rendering/shapes/Shape.h:
53648
536492014-03-20  Beth Dakin  <bdakin@apple.com>
53650
53651        Build fix.
53652
53653        * page/FrameView.cpp:
53654        (WebCore::FrameView::paintContents):
53655
536562014-03-20  Beth Dakin  <bdakin@apple.com>
53657
53658        Implement contentInset for Mac WebKit2
53659        https://bugs.webkit.org/show_bug.cgi?id=130273
53660
53661        Reviewed by Simon Fraser.
53662
53663        This patch adds support for topContentInset(). If a page has a topContentInset(), 
53664        the root layer’s position is adjusted to account for the inset. It is assumed that 
53665        the area accounted for by the inset is visible but obscured, so scrollbars need to 
53666        be moved so that they only cover the non-obscured area, and most parts of WebCore 
53667        that wonder about visibleContentSize only care about the unobscured area, so this 
53668        patch makes that visibleContentRect return the unobscuredRect. Finally since this 
53669        is achieved by moving a layer’s position, the topContentInset() also needs to be 
53670        factored into various functions that are used to convert between coordinate 
53671        spaces. 
53672
53673        Return Page::topContentInset() if this is the main frame.
53674        * page/FrameView.cpp:
53675        (WebCore::FrameView::topContentInset):
53676        * page/FrameView.h:
53677
53678        Cache the inset on Page.
53679        * page/Page.cpp:
53680        (WebCore::Page::Page):
53681        * page/Page.h:
53682        (WebCore::Page::topContentInset):
53683        (WebCore::Page::setTopContentInset):
53684
53685        unobscuredContentRect() used to unconditionally return visibleContentRect() on 
53686        non-iOS platforms. Now that it is possible for some technically visible content to 
53687        be obscured, this code needed to be re-worked a bit to make some more sense. 
53688        visibleContentRect() now represents that visible content that is completely 
53689        unobscured, so it should call into unobscuredContentRect() rather than the other 
53690        way around.
53691        * platform/ScrollView.cpp:
53692        (WebCore::ScrollView::unobscuredContentRect):
53693
53694        unscaledTotalVisibleContentSize() includes the size of all content that might be 
53695        visible. Some of this content might be obscured.
53696        (WebCore::ScrollView::unscaledTotalVisibleContentSize):
53697
53698        Most of the time, we only care about the content that is FULLY visible. That is 
53699        what you get from unscaledUnobscuredVisibleContentSize().
53700        (WebCore::ScrollView::unscaledUnobscuredVisibleContentSize):
53701
53702        Use the unobscured size for these computations.
53703        (WebCore::ScrollView::visibleContentRectInternal):
53704        (WebCore::ScrollView::layoutSize):
53705
53706        Factor in the topContentInset().
53707        (WebCore::ScrollView::scrollOffsetRelativeToDocument):
53708        (WebCore::ScrollView::scrollPositionRelativeToDocument):
53709
53710        The scrollbars should be positioned to cover the non-obscured content only. 
53711        (WebCore::ScrollView::updateScrollbars):
53712
53713        Again, factor the topContentInset() into these conversions since the root layer’s 
53714        position has been adjusted to account for it.
53715        (WebCore::ScrollView::contentsToRootView):
53716        (WebCore::ScrollView::contentsToWindow):
53717
53718         Just like the scrollbars, the scroll corner must be moved the account for the 
53719        inset.
53720        (WebCore::ScrollView::scrollCornerRect):
53721        * platform/ScrollView.h:
53722        (WebCore::ScrollView::topContentInset):
53723
53724        RenderLayerCompositor cares about unscaledTotalVisibleContentSize(). It does not 
53725        care if some of that content is obscured.
53726        * rendering/RenderLayerCompositor.cpp:
53727        (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
53728
53729        Move the root layer’s position based on the contentInset.
53730        (WebCore::RenderLayerCompositor::updateRootLayerPosition):
53731        (WebCore::RenderLayerCompositor::ensureRootLayer):
53732
53733        Allow setting contentInset via Internals for testing purposes.
53734        * testing/Internals.cpp:
53735        (WebCore::Internals::setTopContentInset):
53736        * testing/Internals.h:
53737        * testing/Internals.idl:
53738
537392014-03-20  Laszlo Vidacs  <lvidacs.u-szeged@partner.samsung.com>
53740
53741        Optimize RenderTable::colToEffCol() for tables without colspans
53742        https://bugs.webkit.org/show_bug.cgi?id=129298
53743
53744        Reviewed by Simon Fraser.
53745
53746        Create an alternative fast path to RenderTable colToEffCol() and effColToCol()
53747        when there is no colspan or colspan does not exceed the width of table.
53748        Blink merge https://codereview.chromium.org/154243002 by rhogan
53749
53750        * rendering/RenderTable.cpp:
53751        (WebCore::RenderTable::RenderTable):
53752        (WebCore::RenderTable::appendColumn):
53753        (WebCore::RenderTable::recalcSections):
53754        * rendering/RenderTable.h:
53755        (WebCore::RenderTable::colToEffCol):
53756        (WebCore::RenderTable::effColToCol):
53757        (WebCore::RenderTable::hasCellColspanThatDeterminesTableWidth):
53758
537592014-03-20  Simon Fraser  <simon.fraser@apple.com>
53760
53761        FrameView::paintContents() is not called for composited content
53762        https://bugs.webkit.org/show_bug.cgi?id=130541
53763
53764        Reviewed by Beth Dakin.
53765
53766        FrameView::paintContents() is not called for frames that have
53767        composited contents, yet it contains code that is expected
53768        to run for all Frames.
53769        
53770        Fix by factoring into will/didPaintContents(), and calling
53771        the will/did functions from RenderLayerBacking::paintIntoLayer().
53772        
53773        Also add a SetLayoutNeededForbiddenScope check for composited-layer
53774        painting.
53775
53776        * page/FrameView.cpp:
53777        (WebCore::FrameView::updateControlTints):
53778        (WebCore::FrameView::willPaintContents):
53779        (WebCore::FrameView::didPaintContents):
53780        (WebCore::FrameView::paintContents):
53781        * page/FrameView.h:
53782        * rendering/RenderLayerBacking.cpp:
53783        (WebCore::RenderLayerBacking::paintIntoLayer):
53784
537852014-03-20  Tim Horton  <timothy_horton@apple.com>
53786
53787        Fix the Mountain Lion build.
53788
53789        * platform/graphics/cocoa/IOSurface.mm:
53790        (IOSurface::setIsPurgeable):
53791
537922014-03-20  Brian Burg  <bburg@apple.com>
53793
53794        Web Replay: capture and replay mouse events
53795        https://bugs.webkit.org/show_bug.cgi?id=129395
53796
53797        Reviewed by Joseph Pecoraro.
53798
53799        Add support for capturing and replaying mouse inputs that come from WebKit2.
53800        Hook up the UserInputBridge to session state changes in the ReplayController so
53801        that the bridge knows when to capture or deny mouse inputs.
53802
53803        Test: ManualTests/inspector/replay-mouse-events.html
53804
53805        * platform/PlatformEvent.h: Give explicit storage types to Modifiers and Type enums
53806        so they can be forward-declared.
53807        * platform/PlatformMouseEvent.h: Give an explicit storage type to enum MouseButton.
53808        Add operator== and operator!= for MouseButton to work around an MSVC bug.
53809
53810        * replay/ReplayController.cpp: Perform session state changes in a helper function, and
53811        at the same time change the state of the page's user input bridge.
53812        (WebCore::ReplayController::setSessionState):
53813        (WebCore::ReplayController::startCapturing):
53814        (WebCore::ReplayController::stopCapturing):
53815        (WebCore::ReplayController::startPlayback):
53816        (WebCore::ReplayController::cancelPlayback):
53817
53818        * replay/ReplayInputDispatchMethods.cpp: Add dispatch methods for new inputs.
53819        (WebCore::HandleMouseMove::dispatch):
53820        (WebCore::HandleMousePress::dispatch):
53821        (WebCore::HandleMouseRelease::dispatch):
53822
53823        * replay/SerializationMethods.cpp: Add helper macros so that encode/decode methods look
53824        symmetric with one data member per line. This helps reduce unintentional inconsistencies.
53825        (JSC::EncodingTraits<PlatformMouseEvent>::encodeValue): Added.
53826        (JSC::EncodingTraits<PlatformMouseEvent>::decodeValue): Added.
53827        * replay/SerializationMethods.h:
53828
53829        * replay/UserInputBridge.cpp: Fill in the bridge method implementations for mouse
53830        events, adding helpers and macros as necessary to reduce boilerplate.
53831        (WebCore::UserInputBridge::activeCursor): Added.
53832        (WebCore::UserInputBridge::handleMousePressEvent):
53833        (WebCore::UserInputBridge::handleMouseReleaseEvent):
53834        (WebCore::UserInputBridge::handleMouseMoveEvent):
53835        (WebCore::UserInputBridge::handleMouseMoveOnScrollbarEvent):
53836
53837        * replay/UserInputBridge.h: Add a bridge state enum along with getters and setters.
53838        The enum value controls whether the bridge should capture commands, deny non-synthetic
53839        commands (from the user), or allow anything to pass (the default).
53840        (WebCore::UserInputBridge::setState): Added.
53841        (WebCore::UserInputBridge::state): Added.
53842
53843        * replay/WebInputs.json: Add inputs HandleMouseMove, HandleMousePress, HandleMouseRelease.
53844        Add enum definitions for PlatformEvent::Type, PlatformEvent::Modifiers, and PlatformMouseEvent::MouseButton.
53845        Alphabetize the existing data type definitions.
53846
538472014-03-20  Tim Horton  <timothy_horton@apple.com>
53848
53849        Add WebCore::IOSurface wrapper
53850        https://bugs.webkit.org/show_bug.cgi?id=130529
53851
53852        Reviewed by Simon Fraser.
53853
53854        * WebCore.exp.in:
53855        * WebCore.xcodeproj/project.pbxproj:
53856        * platform/graphics/cg/ColorCG.cpp:
53857        * platform/graphics/cg/GraphicsContextCG.h:
53858        (WebCore::cachedCGColorSpace):
53859        Move cachedCGColorSpace out so that other clients of GraphicsContextCG
53860        can use its mapping from WebCore::ColorSpace -> CGColorSpaceRef.
53861
53862        * platform/graphics/cg/ImageBufferBackingStoreCache.cpp:
53863        * platform/graphics/cg/ImageBufferCG.cpp:
53864        Add FIXMEs for ImageBuffer to adopt WebCore::IOSurface.
53865
53866        * platform/graphics/cocoa/IOSurface.h: Added.
53867        * platform/graphics/cocoa/IOSurface.mm: Added.
53868        (IOSurface::create):
53869        (IOSurface::createFromMachPort):
53870        (IOSurface::createFromSurface):
53871        (IOSurface::IOSurface):
53872        (IOSurface::maximumSize):
53873        (IOSurface::createMachPort):
53874        (IOSurface::createImage):
53875        (IOSurface::ensurePlatformContext):
53876        (IOSurface::ensureGraphicsContext):
53877        (IOSurface::state):
53878        (IOSurface::isPurgeable):
53879        (IOSurface::setIsPurgeable):
53880        (IOSurface::inUse):
53881        Add WebCore::IOSurface.
53882
538832014-03-20  Pratik Solanki  <psolanki@apple.com>
53884
53885        iOS build fix after r165992.
53886
53887        * generate-export-file:
53888        (preprocessorMacros):
53889
538902014-03-20  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
53891
53892        [WebRTC] Moving RTCConfiguration and RTCIceServer to Modules/mediastream
53893        https://bugs.webkit.org/show_bug.cgi?id=130434
53894
53895        Reviewed by Eric Carlson.
53896
53897        Those classes are defined in WebRTC spec, so they should not be in platform layer.
53898        Adding a platform implementation to be passed to handler classes.
53899
53900        * Modules/mediastream/RTCConfiguration.h: Copied from Source/WebCore/platform/mediastream/RTCConfiguration.h.
53901        * Modules/mediastream/RTCIceServer.h: Copied from Source/WebCore/platform/mediastream/RTCIceServer.h.
53902        * Modules/mediastream/RTCPeerConnection.cpp:
53903        (WebCore::RTCPeerConnection::RTCPeerConnection):
53904        (WebCore::RTCPeerConnection::updateIce):
53905        * WebCore.xcodeproj/project.pbxproj:
53906        * platform/mediastream/RTCConfigurationPrivate.h: Added.
53907        * platform/mediastream/RTCIceServerPrivate.h: Added.
53908        * platform/mediastream/RTCPeerConnectionHandler.h:
53909        * platform/mock/RTCPeerConnectionHandlerMock.cpp:
53910        (WebCore::RTCPeerConnectionHandlerMock::initialize):
53911        (WebCore::RTCPeerConnectionHandlerMock::updateIce):
53912        * platform/mock/RTCPeerConnectionHandlerMock.h:
53913
539142014-03-20  Alex Christensen  <achristensen@webkit.org>
53915
53916        [WinCairo] Unreviewed speculative build after my r165996.
53917
53918        * platform/network/soup/AuthenticationChallengeSoup.cpp:
53919        * platform/network/soup/CertificateInfo.cpp:
53920        * platform/network/soup/CookieJarSoup.cpp:
53921        * platform/network/soup/ResourceRequestSoup.cpp:
53922        * platform/network/soup/ResourceResponseSoup.cpp:
53923        * platform/network/soup/SynchronousLoaderClientSoup.cpp:
53924
539252014-03-20  Brent Fulgham  <bfulgham@apple.com>
53926
53927        Add a flushing mechanism for the WebVTTParser
53928        https://bugs.webkit.org/show_bug.cgi?id=130532
53929
53930        Reviewed by Eric Carlson.
53931
53932        Merged from Blink (patch by vcarbune@chromium.org):
53933        https://chromium.googlesource.com/chromium/blink/+/1ac2b3081492ab8661429230004013a9a3623f0f
53934        http://crbug.com/54203003
53935        https://chromium.googlesource.com/chromium/blink/+/24343d32bc36d20d59ef3e10040faddde65929e6
53936        http://crbug.com/59453002
53937        https://chromium.googlesource.com/chromium/blink/+/ef2793f1d9d207389589ecf9a136ea5c7170b4af
53938        http://crbug.com/75233002
53939        https://chromium.googlesource.com/chromium/blink/+/a29f2f8324abcd4826b41e7dc34373dee2ec57a9
53940        http://crbug.com/52713005
53941        https://chromium.googlesource.com/chromium/blink/+/7ce003c8d47b39f116f1f2a592a5dfb4a9e77228
53942        http://crbug.com/64303004
53943        https://chromium.googlesource.com/chromium/blink/+/18f896b3498478311e880f782813d5dfc8c0c7d1
53944        http://crbug.com/96933004
53945        https://chromium.googlesource.com/chromium/blink/+/8670e8ecb13254a651f5493ec83f4484d18c154e
53946        http://crbug.com/98783005
53947        https://chromium.googlesource.com/chromium/blink/+/4ac55780a6af3d76e0159c1d145330964ad56647
53948        http://crbug.com/104713002
53949
53950        Tests: http/tests/media/track/track-webvtt-slow-loading-2.html
53951               http/tests/media/track/track-webvtt-slow-loading.html
53952
53953        * CMakeLists.txt:
53954        * GNUmakefile.list.am:
53955        * WebCore.vcxproj/WebCore.vcxproj:
53956        * WebCore.vcxproj/WebCore.vcxproj.filters:
53957        * WebCore.xcodeproj/project.pbxproj:
53958        * html/track/BufferedLineReader.cpp: Added.
53959        * html/track/BufferedLineReader.h: Added.
53960        * html/track/TextTrackRegion.cpp:
53961        * html/track/VTTCue.cpp:
53962        * html/track/WebVTTParser.cpp:
53963        * html/track/WebVTTParser.h:
53964        * loader/TextTrackLoader.cpp:
53965
539662014-03-20  Alex Christensen  <achristensen@webkit.org>
53967
53968        Preparation for using Soup on Windows.
53969        https://bugs.webkit.org/show_bug.cgi?id=130472
53970
53971        Reviewed by Brent Fulgham.
53972
53973        * WebCore.vcxproj/WebCore.vcxproj:
53974        * WebCore.vcxproj/WebCore.vcxproj.filters:
53975        Added Soup source to build on WinCairo.
53976        * platform/network/curl/CookieJarCurl.cpp:
53977        * platform/network/curl/CredentialStorageCurl.cpp:
53978        * platform/network/curl/CurlCacheEntry.cpp:
53979        * platform/network/curl/CurlCacheManager.cpp:
53980        * platform/network/curl/CurlDownload.cpp:
53981        * platform/network/curl/DNSCurl.cpp:
53982        * platform/network/curl/FormDataStreamCurl.cpp:
53983        * platform/network/curl/MultipartHandle.cpp:
53984        * platform/network/curl/ProxyServerCurl.cpp:
53985        * platform/network/curl/ResourceHandleCurl.cpp:
53986        * platform/network/curl/ResourceHandleManager.cpp:
53987        * platform/network/curl/SSLHandle.cpp:
53988        * platform/network/curl/SocketStreamHandleCurl.cpp:
53989        Protected with USE(CURL) to avoid duplicate symbols when linking.
53990        * platform/network/soup/AuthenticationChallengeSoup.cpp:
53991        * platform/network/soup/CertificateInfo.cpp:
53992        * platform/network/soup/CookieJarSoup.cpp:
53993        * platform/network/soup/CookieStorageSoup.cpp:
53994        * platform/network/soup/CredentialStorageSoup.cpp:
53995        * platform/network/soup/DNSSoup.cpp:
53996        * platform/network/soup/NetworkStorageSessionSoup.cpp:
53997        * platform/network/soup/ProxyResolverSoup.cpp:
53998        * platform/network/soup/ProxyServerSoup.cpp:
53999        * platform/network/soup/ResourceErrorSoup.cpp:
54000        * platform/network/soup/ResourceHandleSoup.cpp:
54001        * platform/network/soup/ResourceRequestSoup.cpp:
54002        * platform/network/soup/ResourceResponseSoup.cpp:
54003        * platform/network/soup/SocketStreamHandleSoup.cpp:
54004        * platform/network/soup/SoupNetworkSession.cpp:
54005        * platform/network/soup/SynchronousLoaderClientSoup.cpp:
54006        Protected with USE(CURL) to avoid duplicate symbols when linking.
54007
540082014-03-20  Pratik Solanki  <psolanki@apple.com>
54009
54010        iOS build fix after r165979.
54011
54012        * generate-export-file:
54013        (preprocessorMacros):
54014
540152014-03-20  David Hyatt  <hyatt@apple.com>
54016
54017        [New Multicolumn] getClientRects returns wrong rectangle
54018        https://bugs.webkit.org/show_bug.cgi?id=128614
54019
54020        Reviewed by Sam Weinig.
54021
54022        Added fast/multicol/newmulticol/client-rects.html and beefed up existing
54023        fast/multicol/client-rects.html to use more writing modes.
54024
54025        * rendering/LayoutState.h:
54026        Removed unused function.
54027
54028        * rendering/RenderFlowThread.h:
54029        Make mapFlowToRegion virtual so that RenderMultiColumnFlowThread can
54030        override it.
54031
54032        * rendering/RenderMultiColumnFlowThread.cpp:
54033        (WebCore::RenderMultiColumnFlowThread::mapFromFlowToRegion):
54034        * rendering/RenderMultiColumnFlowThread.h:
54035        Implement mapFlowToRegion to correctly translate a flow thread position
54036        into a column offset within a region.
54037
54038        * rendering/RenderMultiColumnSet.cpp:
54039        (WebCore::RenderMultiColumnSet::columnTranslationForOffset):
54040        (WebCore::RenderMultiColumnSet::adjustRegionBoundsFromFlowThreadPortionRect):
54041        * rendering/RenderMultiColumnSet.h:
54042        Refactored some code to make a columnTranslationForOffset helper that
54043        can be used by RenderMultiColumnFlowThread.
54044
540452014-03-20  Daniel Bates  <dabates@apple.com>
54046
54047        Preserve original document URL for XSSAuditor reports
54048
54049        Merged from Blink (patch by Tom Sepez):
54050        https://src.chromium.org/viewvc/blink?view=rev&revision=158406
54051
54052        Test: http/tests/security/xssAuditor/report-script-tag-replace-state.html
54053
54054        * html/parser/XSSAuditor.cpp:
54055        (WebCore::XSSAuditor::filterToken):
54056        * html/parser/XSSAuditorDelegate.cpp:
54057        (WebCore::buildConsoleError):
54058        (WebCore::XSSAuditorDelegate::generateViolationReport):
54059        (WebCore::XSSAuditorDelegate::didBlockScript):
54060        * html/parser/XSSAuditorDelegate.h:
54061        (WebCore::XSSInfo::XSSInfo):
54062
540632014-03-20  Daniel Bates  <dabates@apple.com>
54064
54065        XSSAuditor bypass with frameset tags
54066
54067        Merged from Blink (patch by Tom Sepez):
54068        https://src.chromium.org/viewvc/blink?view=rev&revision=157794
54069
54070        Test: http/tests/security/xssAuditor/frameset-injection.html
54071
54072        * html/parser/XSSAuditor.cpp:
54073        (WebCore::XSSAuditor::filterStartToken):
54074        (WebCore::XSSAuditor::filterFrameToken):
54075        * html/parser/XSSAuditor.h:
54076
540772014-03-20  Brian Burg  <bburg@apple.com>
54078
54079        Web Replay: fix some oversights in the replay backend
54080        https://bugs.webkit.org/show_bug.cgi?id=130435
54081
54082        Reviewed by Andreas Kling.
54083
54084        This functionality will be covered by tests in https://webkit.org/b/130145.
54085
54086        * inspector/InspectorInstrumentation.cpp:
54087        (WebCore::InspectorInstrumentation::playbackFinishedImpl):
54088        * inspector/InspectorInstrumentation.h:
54089        (WebCore::InspectorInstrumentation::playbackFinished):
54090        * inspector/InspectorReplayAgent.cpp:
54091        (WebCore::buildInspectorObjectForSegment):
54092        (WebCore::InspectorReplayAgent::playbackFinished):
54093        * inspector/InspectorReplayAgent.h: Add a playbackFinished event to Inspector
54094        instrumentation. This is fired by ReplayController when playback is cancelled or 
54095        playback of the final segment has completed.
54096
54097        * replay/EventLoopInputDispatcher.cpp:
54098        (WebCore::EventLoopInputDispatcher::dispatchInputSoon): Fix wrong cast.
54099        (WebCore::EventLoopInputDispatcher::dispatchInput): Ensure that m_dispatching is
54100        false when m_running is false.
54101        * replay/EventLoopInputDispatcher.h: Distinguish 'dispaching' and 'running' in comments.
54102        (WebCore::EventLoopInputDispatcher::isRunning): Added.
54103
54104        * replay/FunctorInputCursor.h: Since the base class InputCursor is RefCounted, the
54105        Functor subclass cannot be put into a unique_ptr. Add create() method instead.
54106
54107        * replay/ReplayController.cpp:
54108        (WebCore::ReplayController::loadSegmentAtIndex): Renamed from loadSegment(). Callers
54109        now pass in the desired segment index rather than the segment itself. The index is
54110        necessary to properly reset m_position after the segment is loaded.
54111
54112        (WebCore::ReplayController::startPlayback): Set the dispatcher's speed before run().
54113        (WebCore::ReplayController::pausePlayback): Only pause the dispatcher if it's running.
54114        (WebCore::ReplayController::cancelPlayback): Add playbackFinished instrumentation.
54115        (WebCore::ReplayController::replayToPosition):
54116        (WebCore::ReplayController::didDispatchFinalInput): If there are no more segments to load,
54117        manually adjust the final m_position and defer to cancelPlayback to unload the segment.
54118        * replay/ReplayController.h:
54119        * replay/ReplaySessionSegment.cpp:
54120        (WebCore::ReplaySessionSegment::createFunctorCursor):
54121        * replay/ReplaySessionSegment.h:
54122
541232014-03-20  Pratik Solanki  <psolanki@apple.com>
54124
54125        [iOS] Get code to compile on older iOS versions
54126        https://bugs.webkit.org/show_bug.cgi?id=130142
54127        <rdar://problem/16302908>
54128
54129        Reviewed by Darin Adler.
54130
54131        * WebCore.exp.in:
54132        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
54133        (-[WebVideoFullscreenController WebCore::]):
54134        (-[WebVideoFullscreenController enterFullscreen:]):
54135        (-[WebVideoFullscreenController exitFullscreen]):
54136        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
54137        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
54138        * platform/mac/HTMLConverter.mm:
54139        (_dateForString):
54140        * platform/network/cf/CookieJarCFNet.cpp:
54141        (WebCore::copyCookiesForURLWithFirstPartyURL):
54142        * platform/text/ios/LocalizedDateCache.mm:
54143        (WebCore::LocalizedDateCache::calculateMaximumWidth):
54144        * platform/text/mac/LocaleMac.mm:
54145        (WebCore::LocaleMac::LocaleMac):
54146
541472014-03-20  Simon Fraser  <simon.fraser@apple.com>
54148
54149        Followup build fix: AnimationBase.h needs to be private because
54150        it's included by AnimationController.h.
54151
54152        * WebCore.xcodeproj/project.pbxproj:
54153
541542014-03-20  Simon Fraser  <simon.fraser@apple.com>
54155
54156        A completed fill-forwards animation should not disable overlap testing
54157        https://bugs.webkit.org/show_bug.cgi?id=130522
54158        <rdar://problem/15862395>
54159
54160        Reviewed by Dean Jackson.
54161        
54162        Previously, if -webkit-transform was being keyframe-animated, and the
54163        animation had fill-forwards, then we would continue to think that the
54164        animation is running and turn off compositing overlap testing. This
54165        caused some sites to keep too much backing store around.
54166        
54167        Fix by having isRunning{Accelerated}AnimationOnRenderer take some flags
54168        so that more specific questions about the running state can be asked.
54169        For layer creation, keep using the same criteria as before (for now)
54170        which includes paused and fill-forwards animations. For overlap testing,
54171        don't include the fill-forwards test.
54172
54173        Tests: compositing/animation/filling-animation-overlap-at-end.html
54174               compositing/animation/filling-animation-overlap.html
54175               compositing/animation/layer-for-filling-animation.html
54176
54177        * page/animation/AnimationBase.h:
54178        (WebCore::AnimationBase::fillingForwards):
54179        (WebCore::AnimationBase::inPausedState):
54180        (WebCore::AnimationBase::isAnimatingProperty):
54181        * page/animation/AnimationController.cpp:
54182        (WebCore::AnimationControllerPrivate::isRunningAnimationOnRenderer):
54183        (WebCore::AnimationControllerPrivate::isRunningAcceleratedAnimationOnRenderer):
54184        (WebCore::AnimationController::isRunningAnimationOnRenderer):
54185        (WebCore::AnimationController::isRunningAcceleratedAnimationOnRenderer):
54186        * page/animation/AnimationController.h:
54187        * page/animation/AnimationControllerPrivate.h:
54188        * page/animation/CompositeAnimation.cpp:
54189        (WebCore::CompositeAnimation::isAnimatingProperty):
54190        * page/animation/CompositeAnimation.h:
54191        * rendering/RenderLayerBacking.cpp:
54192        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
54193        * rendering/RenderLayerCompositor.cpp:
54194        (WebCore::RenderLayerCompositor::requiresCompositingForAnimation):
54195        (WebCore::RenderLayerCompositor::isRunningAcceleratedTransformAnimation):
54196
541972014-03-20  Dirk Schulze  <krit@webkit.org>
54198
54199        Canvas methods clip/fill/stroke should not except 0 argument
54200        https://bugs.webkit.org/show_bug.cgi?id=130497
54201
54202        Reviewed by Dean Jackson.
54203
54204        Do not allow nullable argument for fill/stroke/clip.
54205
54206        No new tests. Updated existing tests.
54207
54208        * html/canvas/CanvasRenderingContext2D.idl:
54209
542102014-03-20  Eric Carlson  <eric.carlson@apple.com>
54211
54212        [iOS] Support MediaDocument when building with PLUGIN_PROXY_FOR_VIDEO
54213        https://bugs.webkit.org/show_bug.cgi?id=130520
54214
54215        Reviewed by Jer Noble.
54216
54217        * dom/DOMImplementation.cpp:
54218        (WebCore::DOMImplementation::createDocument): Check the isVideoPluginProxyEnabled setting 
54219            when building with ENABLE_PLUGIN_PROXY_FOR_VIDEO.
54220
542212014-03-20  Mihai Tica  <mitica@adobe.com>
54222
54223        [CSS Blending] Blending operation is not isolated when setting z-index on parent from javascript
54224        https://bugs.webkit.org/show_bug.cgi?id=129307
54225
54226        Reviewed by Dean Jackson.
54227
54228        Reimplement the logic behind isolating blend modes. The blending operation should be limited to the
54229        contents of the parent stacking context. The proposed solution implies adding logic in updateDescendantDependentFlags,
54230        to track child elements that have blending and create a transparency layer that triggers isolation.
54231
54232        Tests: css3/compositing/blend-mode-background.html
54233               fast/repaint/blend-mode-isolate-stacking-context.html
54234
54235        * rendering/RenderLayer.cpp:
54236        (WebCore::RenderLayer::RenderLayer): Remove old members, add new members to constructor.
54237        (WebCore::RenderLayer::updateBlendMode): Update parent stacking context isolation on blend mode change.
54238        (WebCore::RenderLayer::updateNonCompositedParentStackingContextHasBlendedChild):
54239        - Set m_hasBlendedElementInChildStackingContext for the non composited parent stacking context.
54240        (WebCore::RenderLayer::dirtyAncestorParentStackingContextHasBlendedElement):
54241        - Set flag so isolation should be considered in updateDescendantDependentFlags.
54242        (WebCore::RenderLayer::nonCompositedParentStackingContextHasBlendedChild):
54243        - Return whether the non composited parent stacking context isolates blending.
54244        (WebCore::RenderLayer::updateDescendantDependentFlags): Add logic for isolating blending.
54245        (WebCore::RenderLayer::addChild): Call to updateNonCompositedParentStackingContextHasBlendedChild if needed.
54246        (WebCore::RenderLayer::removeChild): Call to dirtyAncestorParentStackingContextHasBlendedElement if needed.
54247        (WebCore::RenderLayer::updateStackingContextsAfterStyleChange): Update isolation when a stacking context was set or unset.
54248        (WebCore::RenderLayer::styleChanged): Removed oldStyle parameter from updateBlendMode call.
54249         Update parent stacking context isolation on blend mode change.
54250        * rendering/RenderLayer.h:
54251        - Add members, getters and setters for tracking whether the element has a blended child:
54252            - m_hasBlendedElementInChildStackingContext
54253            - m_hasBlendedElementInChildStackingContextStatusDirty
54254        - Removed m_updateParentStackingContextShouldIsolateBlendingDirty (replaced with m_hasBlendedElementInChildStackingContextStatusDirty)
54255        - Removed m_isolatesBlending (replaced with m_hasBlendedElementInChildStackingContext)
54256        - Updated the isolatesBlending method to return true only when the element is a stacking context and has a blended child.
54257        * rendering/RenderLayerCompositor.cpp:
54258        (WebCore::RenderLayerCompositor::computeCompositingRequirements): Removed layer.updateParentStackingContextShouldIsolateBlending call.
54259
542602014-03-20  Martin Robinson  <mrobinson@igalia.com>
54261
54262        [GTK] [CMake] Do not compile ProxyResolverSoup.cpp
54263        https://bugs.webkit.org/show_bug.cgi?id=130516
54264
54265        Reviewed by Sergio Villar Senin.
54266
54267        * PlatformGTK.cmake: Remove the file from the source list.
54268
542692014-03-20  Commit Queue  <commit-queue@webkit.org>
54270
54271        Unreviewed, rolling out r165962.
54272        https://bugs.webkit.org/show_bug.cgi?id=130512
54273
54274        It broke the build (Requested by Ossy on #webkit).
54275
54276        Reverted changeset:
54277
54278        "[EFL][GTK] Get CMake to find Freetype2 properly"
54279        https://bugs.webkit.org/show_bug.cgi?id=130150
54280        http://trac.webkit.org/changeset/165962
54281
542822014-03-20  Lorenzo Tilve  <ltilve@igalia.com>
54283
54284        "input" event is not fired when changing a select element's value
54285        https://bugs.webkit.org/show_bug.cgi?id=117526
54286
54287        Reviewed by Antti Koivisto.
54288
54289        Add a call to dispatch input event when listbox or menulist
54290        values are modified.
54291
54292        According to the spec: "When the user agent is to send select update
54293        notifications, queue a task to first fire a simple even that bubbles
54294        named input at the select element, and then fire a simple event that
54295        bubbles named change at the select element, using the user interaction
54296        task source as the task source."
54297
54298        Tests: fast/forms/select/listbox-oninput-fired.html
54299               fast/forms/select/menulist-oninput-fired.html
54300
54301        * html/HTMLSelectElement.cpp:
54302        (WebCore::HTMLSelectElement::listBoxOnChange):
54303        (WebCore::HTMLSelectElement::dispatchChangeEventForMenuList):
54304
543052014-03-20  Radu Stavila  <stavila@adobe.com>
54306
54307        [CSS Regions] The height of a scrollable element flowed inside a scrollable region is not computed correctly
54308        https://bugs.webkit.org/show_bug.cgi?id=129487
54309
54310        Reviewed by Andrei Bucur.
54311
54312        When propagating the layout overflow from the flowed element up to the flow thread itself,
54313        the region's logical bottom padding and the element's logical bottom margin must be taken into consideration.
54314        However, if the flowed element has overflow, the overflow will be painted over the region's padding
54315        and the element's margin, in order to be compatible with the non-regions case.
54316        More info can be found here: http://lists.w3.org/Archives/Public/www-style/2014Jan/0089.html
54317
54318        Tests: fast/regions/scrollable-region-content-size-horiz-bt.html
54319               fast/regions/scrollable-region-content-size-no-overflow-horiz-bt.html
54320               fast/regions/scrollable-region-content-size-no-overflow-vert-rl.html
54321               fast/regions/scrollable-region-content-size-no-overflow.html
54322               fast/regions/scrollable-region-content-size-relative.html
54323               fast/regions/scrollable-region-content-size-vert-rl.html
54324               fast/regions/scrollable-region-content-size-vertical-lr.html
54325               fast/regions/scrollable-region-content-size.html
54326               fast/regions/scrollable-region-scrollable-content.html
54327
54328        * rendering/RenderFlowThread.cpp:
54329        (WebCore::RenderFlowThread::addRegionsOverflowFromChild):
54330        * rendering/RenderRegion.cpp:
54331        (WebCore::RenderRegion::rectFlowPortionForBox):
54332
543332014-03-20  Zalan Bujtas  <zalan@apple.com>
54334
54335        Subpixel rendering: Nested layers with subpixel accumulation paint to wrong position.
54336        https://bugs.webkit.org/show_bug.cgi?id=130153
54337
54338        Reviewed by Simon Fraser.
54339
54340        Subpixels (fractional device pixels here) can accumulate through nested layers. Subpixels
54341        need to be propagated through the layer tree so that painting coordinates match layout coordinates.
54342
54343        Subpixel accumulation through nesting (absolute positioning, 2x display):
54344        non-compositing case:
54345        (nested boxes)  (layout pos) (norm.paint pos) (translate accumulation, subpixel accumulation, final paint pos)
54346        div -> top: 1.3px   1.3px     1.5px      1.5px 0.2px -> snapped 0.0px -> 1.5px
54347         div -> top: 1.3px   2.6px     2.5px      3.0px 0.4px -> snapped 0.5px -> 2.5px
54348          div -> top: 1.3px   3.9px     4.0px      4.5px 0.6px -> snapped 0.5px -> 4.0px
54349           div -> top: 1.3px   5.2px     5.0px      6.0px 0.8px -> snapped 1.0px -> 5.0px
54350
54351        compositing case:
54352        (nested boxes)  (layout pos) (norm.paint pos) (device pixel offset + fractional offset, final pos)
54353        div -> top: 1.3px   1.3px      1.5px      1.0px + 0.3px -> snapped -> 1.5px
54354         div -> top: 1.3px   2.6px      2.5px      2.5px + 0.1px -> snapped -> 2.5px
54355          div -> top: 1.3px   3.9px      4.0px      3.5px + 0.4px -> snapped -> 4.0px
54356           div -> top: 1.3px   5.2px      5.0px      5.0px + 0.2px -> snapped -> 5.0px
54357
54358        Tests: compositing/hidpi-nested-compositing-layers-with-subpixel-accumulation.html
54359               fast/layers/hidpi-nested-layers-with-subpixel-accumulation.html
54360
54361        * rendering/RenderLayer.cpp:
54362        (WebCore::RenderLayer::paintLayerByApplyingTransform):
54363        * rendering/RenderLayerBacking.cpp:
54364        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
54365        * rendering/RenderLayerBacking.h:
54366        (WebCore::RenderLayerBacking::devicePixelFractionFromRenderer):
54367
543682014-03-20  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
54369
54370        [EFL][GTK] Get CMake to find Freetype2 properly
54371        https://bugs.webkit.org/show_bug.cgi?id=130150
54372
54373        Reviewed by Csaba Osztrogonác.
54374
54375        Newer versions of CMake are not able to find Freetype2 correctly.
54376        FindFreetype2.cmake checks for the version number in freetype.h header, since it seems that bug exists in
54377        freetype2 repo, because a completely different version number is found in freetype2.pc.
54378
54379        * PlatformEfl.cmake:
54380        * PlatformGTK.cmake:
54381
543822014-03-20  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
54383
54384        Refactor checking log channel state in MediaPlayerPrivateGStreamerBase.
54385        https://bugs.webkit.org/show_bug.cgi?id=130241
54386
54387        Reviewed by Philippe Normand.
54388
54389        The channel was passed around only to check its state. Cleaned this up
54390        by adding a method to check whether a log channel is enabled.
54391
54392        * platform/Logging.cpp:
54393        (WebCore::isLogChannelEnabled):
54394        * platform/Logging.h:
54395        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
54396        (WebCore::MediaPlayerPrivateGStreamerBase::createVideoSink):
54397
543982014-03-20  Lorenzo Tilve  <ltilve@igalia.com>
54399
54400        Dispatch input event for Range element keyboard event
54401        https://bugs.webkit.org/show_bug.cgi?id=129929
54402
54403        Reviewed by Kent Tamura.
54404
54405        For any value update, dispatch both input and change event.
54406        Also removes extra dispatch change event, as event is dispatched
54407        from TextFieldInputType:setValue.
54408
54409        Merged from Blink (patch by Habib Virji):
54410        https://src.chromium.org/viewvc/blink?revision=168558&view=revision
54411
54412        Test: fast/forms/range/range-keyboard-oninput-event.html
54413
54414        * html/RangeInputType.cpp:
54415        (WebCore::RangeInputType::handleKeydownEvent):
54416
544172014-03-20  Jinwoo Song  <jinwoo7.song@samsung.com>
54418
54419        Refine BatteryStatus module
54420        https://bugs.webkit.org/show_bug.cgi?id=130495
54421
54422        Reviewed by Andreas Kling.
54423
54424        Small refinements:
54425         - Return PassRef instead of PassRefPtr in create method
54426         - Switched to nullptr instead of 0 where appropriate.
54427         - Removed unused function and header file.
54428         - Removed unnecessary empty lines.
54429
54430        * Modules/battery/BatteryController.h:
54431        * Modules/battery/BatteryManager.cpp:
54432        (WebCore::BatteryManager::create): Make return passRef.
54433        * Modules/battery/BatteryManager.h:
54434        (WebCore::BatteryManager::batteryControllerDestroyed): Use nullptr.
54435        * Modules/battery/BatteryStatus.cpp:
54436        (WebCore::BatteryStatus::create): Make return passRef.
54437        * Modules/battery/BatteryStatus.h:
54438        * Modules/battery/NavigatorBattery.cpp:
54439        (WebCore::NavigatorBattery::webkitBattery): Remove batteryManager().
54440        * Modules/battery/NavigatorBattery.h:
54441
544422014-03-19  Pratik Solanki  <psolanki@apple.com>
54443
54444        [iOS] Get code to compile on older iOS versions
54445        https://bugs.webkit.org/show_bug.cgi?id=130142
54446        <rdar://problem/16302908>
54447
54448        Reviewed by Darin Adler.
54449
54450        * WebCore.exp.in:
54451        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
54452        (-[WebVideoFullscreenController WebCore::]):
54453        (-[WebVideoFullscreenController enterFullscreen:]):
54454        (-[WebVideoFullscreenController exitFullscreen]):
54455        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
54456        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
54457        * platform/mac/HTMLConverter.mm:
54458        (_dateForString):
54459        * platform/network/cf/CookieJarCFNet.cpp:
54460        (WebCore::copyCookiesForURLWithFirstPartyURL):
54461        * platform/text/ios/LocalizedDateCache.mm:
54462        (WebCore::LocalizedDateCache::calculateMaximumWidth):
54463        * platform/text/mac/LocaleMac.mm:
54464        (WebCore::LocaleMac::LocaleMac):
54465
544662014-03-19  Byungseon Shin  <sun.shin@lge.com>
54467
54468        Fix "WEBKIT_WEBGL_compressed_texture_pvrtc" extension support
54469        https://bugs.webkit.org/show_bug.cgi?id=130292
54470
54471        Reviewed by Dean Jackson.
54472
54473        WebGLRenderingContext::getExtension was not returning WEBGL_compressed_texture_pvrtc extension.
54474
54475        * html/canvas/WebGLRenderingContext.cpp:
54476        (WebCore::WebGLRenderingContext::getExtension):
54477
544782014-03-19  Brent Fulgham  <bfulgham@apple.com>
54479
54480        Merge Misc. WebVTT Updates from Blink.
54481        https://bugs.webkit.org/show_bug.cgi?id=130491
54482
54483        Reviewed by Eric Carlson.
54484
54485        Test: media/track/track-webvtt-tc030-interspersed-non-cue.html
54486
54487        Merged from Blink (patch by vcarbune@chromium.org):
54488        https://chromium.googlesource.com/chromium/blink/+/fb62b2b54944bd19026192c049a1db250756fc12
54489        http://crbug.com/40323003
54490        https://chromium.googlesource.com/chromium/blink/+/29176fb0b394a97e85f4dabc07e18329f3ceae41
54491        http://crbug.com/54463002
54492        https://chromium.googlesource.com/chromium/blink/+/29476f839a08cb17c5a3fc713f7e454e7cea9c60
54493        http://crbug.com/55853002
54494        https://chromium.googlesource.com/chromium/blink/+/ba2378ef873e786cf2937034e012669cdd37dfe8
54495        http://crbug.com/65343003
54496        https://chromium.googlesource.com/chromium/blink/+/1915b9aa1bba45aebf28531b40ae627ecf9a3d59
54497        http://crbug.com/62833005
54498        https://chromium.googlesource.com/chromium/blink/+/ea46dbd0f1f29779a1cd4f59b19361b803f09a9b
54499        http://crbug.com/64273013
54500        https://chromium.googlesource.com/chromium/blink/+/9eb4bb6b627357bb94d66386a4123ec004cccfc4
54501        http://crbug.com/101513002
54502        https://chromium.googlesource.com/chromium/blink/+/192a843b32eafb77bf92c50ec50d334ba935028a
54503        http://crbug.com/102403002
54504        https://chromium.googlesource.com/chromium/blink/+/15f9efcc952fcf73184e28fb9db79633c1fa6653
54505        http://crbug.com/104443002
54506        https://chromium.googlesource.com/chromium/blink/+/74fd66b451a464683f7cb748855b1740a54b2c16
54507        http://crbug.com/75243004
54508
54509        * html/track/TextTrackRegion.cpp:
54510        (WebCore::TextTrackRegion::parseSettingValue):
54511        * html/track/VTTCue.cpp:
54512        (WebCore::VTTCue::markFutureAndPastNodes):
54513        (WebCore::VTTCue::setCueSettings):
54514        * html/track/WebVTTParser.cpp:
54515        (WebCore::scanDigits):
54516        (WebCore::WebVTTParser::collectDigitsToInt):
54517        (WebCore::WebVTTParser::parseFloatPercentageValue):
54518        (WebCore::WebVTTParser::parseBytes):
54519        (WebCore::WebVTTParser::collectMetadataHeader):
54520        (WebCore::WebVTTParser::collectTimingsAndSettings):
54521        (WebCore::WebVTTParser::createDocumentFragmentFromCueText):
54522        (WebCore::WebVTTParser::createNewCue):
54523        (WebCore::WebVTTParser::createNewRegion):
54524        (WebCore::WebVTTParser::collectTimeStamp):
54525        (WebCore::tokenToNodeType):
54526        (WebCore::WebVTTParser::constructTreeFromToken):
54527        * html/track/WebVTTParser.h:
54528        * html/track/WebVTTToken.h:
54529        (WebCore::WebVTTToken::name):
54530        (WebCore::WebVTTToken::characters):
54531        (WebCore::WebVTTToken::appendToCharacter):
54532        (WebCore::WebVTTToken::addNewClass):
54533        (WebCore::WebVTTToken::classes):
54534        (WebCore::WebVTTToken::addNewAnnotation):
54535        (WebCore::WebVTTToken::annotation):
54536        * html/track/WebVTTTokenizer.cpp:
54537        (WebCore::equalLiteral):
54538        (WebCore::WebVTTTokenizer::WebVTTTokenizer):
54539        (WebCore::WebVTTTokenizer::nextToken):
54540        * html/track/WebVTTTokenizer.h:
54541
545422014-03-19  Mark Hahnenberg  <mhahnenberg@apple.com>
54543
54544        GC timer should intelligently choose between EdenCollections and FullCollections
54545        https://bugs.webkit.org/show_bug.cgi?id=128261
54546
54547        Reviewed by Geoffrey Garen.
54548
54549        No new tests.
54550
54551        Updated WebSafeGCActivityCallbacks for both Eden and Full timers.
54552
54553        * bindings/js/JSDOMWindowBase.cpp:
54554        (WebCore::JSDOMWindowBase::commonVM):
54555        * platform/ios/WebSafeGCActivityCallbackIOS.h:
54556
545572014-03-19  Andy Estes  <aestes@apple.com>
54558
54559        Fix the iOS build after r165917.
54560
54561        * platform/ios/WebCoreSystemInterfaceIOS.mm:
54562
545632014-03-19  Commit Queue  <commit-queue@webkit.org>
54564
54565        Unreviewed, rolling out r165926.
54566        https://bugs.webkit.org/show_bug.cgi?id=130488
54567
54568        broke the iOS build (Requested by estes on #webkit).
54569
54570        Reverted changeset:
54571
54572        "GC timer should intelligently choose between EdenCollections
54573        and FullCollections"
54574        https://bugs.webkit.org/show_bug.cgi?id=128261
54575        http://trac.webkit.org/changeset/165926
54576
545772014-03-19  Commit Queue  <commit-queue@webkit.org>
54578
54579        Unreviewed, rolling out r165929.
54580        https://bugs.webkit.org/show_bug.cgi?id=130487
54581
54582        in order to roll out r165926 (Requested by estes on #webkit).
54583
54584        Reverted changeset:
54585
54586        http://trac.webkit.org/changeset/165929
54587
545882014-03-19  Mark Hahnenberg  <mhahnenberg@apple.com>
54589
54590        Build fix for iOS after r165926
54591
54592        * bindings/js/JSDOMWindowBase.cpp:
54593        (WebCore::JSDOMWindowBase::commonVM):
54594        * platform/ios/WebSafeGCActivityCallbackIOS.h:
54595
545962014-03-19  Eric Carlson  <eric.carlson@apple.com>
54597
54598        Allow media engine to update HTMLMediaElement state when playing to external device
54599        https://bugs.webkit.org/show_bug.cgi?id=130480
54600
54601        Reviewed by Jer Noble.
54602
54603        * html/HTMLMediaElement.h: Add mediaPlayerHandlePlaybackCommand.
54604
54605        * platform/graphics/MediaPlayer.cpp:
54606        (WebCore::MediaPlayer::handlePlaybackCommand): New.
54607        * platform/graphics/MediaPlayer.h:
54608        (WebCore::MediaPlayerClient::mediaPlayerHandlePlaybackCommand):
54609
54610        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
54611        (WebCore::MediaPlayerPrivateAVFoundation::rateChanged): Send Play and Pause commands when
54612            playing to an external device.
54613
546142014-03-19  Dirk Schulze  <krit@webkit.org>
54615
54616        Implement isPointInPath and isPointInStroke with Path2D argument
54617        https://bugs.webkit.org/show_bug.cgi?id=130473
54618
54619        Reviewed by Dean Jackson.
54620
54621        Implement isPointInPath and isPointInStroke for 2D Canvas contxts
54622        with Path2D argument.
54623
54624
54625        Tests: fast/canvas/canvas-path-isPointInPath.html
54626               fast/canvas/canvas-path-isPointInStroke.html
54627
54628        * html/canvas/CanvasRenderingContext2D.cpp:
54629        (WebCore::CanvasRenderingContext2D::isPointInPath):
54630        (WebCore::CanvasRenderingContext2D::isPointInStroke):
54631        (WebCore::CanvasRenderingContext2D::isPointInPathInternal):
54632        (WebCore::CanvasRenderingContext2D::isPointInStrokeInternal):
54633        * html/canvas/CanvasRenderingContext2D.h:
54634        * html/canvas/CanvasRenderingContext2D.idl:
54635
546362014-03-13  Mark Hahnenberg  <mhahnenberg@apple.com>
54637
54638        GC timer should intelligently choose between EdenCollections and FullCollections
54639        https://bugs.webkit.org/show_bug.cgi?id=128261
54640
54641        Reviewed by Geoffrey Garen.
54642
54643        No new tests.
54644
54645        * platform/ios/WebSafeGCActivityCallbackIOS.h: Update WebSafeGCActivityCallback
54646        appropriately for the introduction of another type of GCActivityCallback.
54647
546482014-03-18  Mark Hahnenberg  <mhahnenberg@apple.com>
54649
54650        GC timer should intelligently choose between EdenCollections and FullCollections
54651        https://bugs.webkit.org/show_bug.cgi?id=128261
54652
54653        Reviewed by Geoffrey Garen.
54654
54655        No new tests.
54656
54657        Updated WebSafeGCActivityCallbacks for both Eden and Full timers.
54658
54659        * platform/ios/WebSafeGCActivityCallbackIOS.h:
54660
546612014-03-19  Antti Koivisto  <antti@apple.com>
54662
54663        Crash with long selector list
54664        https://bugs.webkit.org/show_bug.cgi?id=123006
54665
54666        Reviewed by Andreas Kling.
54667
54668        Test: fast/css/long-selector-list-crash.html
54669
54670        * css/CSSSelectorList.cpp:
54671        (WebCore::CSSSelectorList::CSSSelectorList):
54672        (WebCore::CSSSelectorList::adoptSelectorVector):
54673        (WebCore::CSSSelectorList::operator=):
54674        * css/StyleRule.cpp:
54675        (WebCore::StyleRule::create):
54676
54677            Add a bunch of asserts.
54678
54679        (WebCore::StyleRule::splitIntoMultipleRulesWithMaximumSelectorComponentCount):
54680        
54681            This could produce a zero-length selector list.
54682
546832014-03-19  Andreas Kling  <akling@apple.com>
54684
54685        Rebaseline bindings tests.
54686
54687        * bindings/scripts/test/JS/*:
54688
546892014-03-04  Jer Noble  <jer.noble@apple.com>
54690
54691        [iOS][MediaControls] Reverse-pinching using the built-in controls should enter full screen
54692        https://bugs.webkit.org/show_bug.cgi?id=129707
54693
54694        Reviewed by Eric Carlson.
54695
54696        The default controls on iOS should respond to a pinch gesture by entering fullscreen. Add a gesture
54697        event listener, and enter full screen if the user does a quick (>2 velocity) reverse (>1.25 scale) pinch.
54698
54699        * Modules/mediacontrols/mediaControlsiOS.js:
54700        (ControllerIOS.prototype.createBase):
54701        (ControllerIOS.prototype.handlePlayButtonTouchEnd):
54702        (ControllerIOS.prototype.handleBaseGestureStart):
54703        (ControllerIOS.prototype.handleBaseGestureChange):
54704        (ControllerIOS.prototype.handleBaseGestureEnd):
54705
547062014-03-19  Ryosuke Niwa  <rniwa@webkit.org>
54707
54708        REGRESSION(r156316): Scrollbar on a large document is broken
54709        https://bugs.webkit.org/show_bug.cgi?id=130474
54710        <rdar://problem/16371523>
54711
54712        Reviewed by Anders Carlsson.
54713
54714        The bug was caused by updateArrowPlacement() doing the work even though Scrollbar Overlay API is available.
54715        Prior to r156316, this function exited early:
54716        http://trac.webkit.org/browser/trunk/Source/WebCore/platform/mac/ScrollbarThemeMac.mm?rev=156315#L147
54717
54718        Fixed the bug by deleting updateArrowPlacement() entirely.
54719
54720        * platform/mac/ScrollbarThemeMac.mm:
54721        (WebCore::ScrollbarThemeMac::preferencesChanged):
54722
547232014-03-19  Jer Noble  <jer.noble@apple.com>
54724
54725        [Mac][EME] Query whether decoder support exists before creating a new MediaKeys object.
54726        https://bugs.webkit.org/show_bug.cgi?id=130459
54727
54728        Reviewed by Eric Carlson.
54729
54730        * WebCore.exp.in: Export the new WCSI method.
54731        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
54732        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsKeySystem): Bail early if we have no decoder support.
54733        * platform/mac/WebCoreSystemInterface.h: Provide a WCSI wrapper for WKSI.
54734        * platform/mac/WebCoreSystemInterface.mm: Ditto.
54735
547362014-03-19  Eric Carlson  <eric.carlson@apple.com>
54737
54738        Make Remote Control commands testable
54739        https://bugs.webkit.org/show_bug.cgi?id=130358
54740
54741        Reviewed by Jer Noble.
54742
54743        Test: media/video-remote-control-playpause.html
54744
54745        * html/HTMLMediaElement.cpp:
54746        (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Call session->clientWillPausePlayback.
54747        (WebCore::HTMLMediaElement::didReceiveRemoteControlCommand): Log the command.
54748
54749        * platform/audio/MediaSession.cpp:
54750        (WebCore::MediaSessionClient::mediaSessionTitle): Move from header file.
54751        (WebCore::MediaSessionClient::mediaSessionDuration): Ditto.
54752        (WebCore::MediaSessionClient::mediaSessionCurrentTime): Ditto.
54753        * platform/audio/MediaSession.h:
54754
54755        * platform/audio/MediaSessionManager.cpp:
54756        (WebCore::MediaSessionManager::MediaSessionManager): Get rid of m_activeSession.
54757        (WebCore::MediaSessionManager::removeSession): No need to clear m_activeSession because 
54758            we use the m_sessions vector.
54759        (WebCore::MediaSessionManager::sessionWillBeginPlayback): setCurrentSession takes a 
54760            MediaSession&.
54761        (WebCore::MediaSessionManager::sessionWillEndPlayback): Keep m_sessions sorted so playing
54762            sessions are before paused sessions.
54763        (WebCore::MediaSessionManager::setCurrentSession): Move the session that is beginning to
54764            play to the head of m_sessions.
54765        (WebCore::MediaSessionManager::currentSession): Return m_sessions[0] or nullptr.
54766        (WebCore::MediaSessionManager::didReceiveRemoteControlCommand):
54767        * platform/audio/MediaSessionManager.h:
54768
54769        * platform/audio/ios/MediaSessionManagerIOS.mm: Include MediaPlayer.h.
54770
54771        * testing/Internals.cpp:
54772        (WebCore::Internals::postRemoteControlCommand): New.
54773        * testing/Internals.h:
54774        * testing/Internals.idl:
54775
547762014-03-19  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
54777
54778        Improving webkitGetUserMedia error handling and error messages
54779        https://bugs.webkit.org/show_bug.cgi?id=130452
54780
54781        Reviewed by Eric Carlson.
54782
54783        Checking if first argument of webkitGetUserMedia is a valid Dictionary. If not, throw an exception with a
54784        clearer message of the error.
54785
54786        Test updated.
54787
54788        * Modules/mediastream/NavigatorMediaStream.idl:
54789        * UseJSC.cmake:
54790        * bindings/js/JSNavigatorCustom.cpp: Added.
54791
547922014-03-19  Andreas Kling  <akling@apple.com>
54793
54794        JSC bindings should use the passed-in global object for wrapper caching.
54795        <https://webkit.org/b/130458>
54796
54797        Take a shorter path to the DOMWrapperWorld by using the passed-in
54798        global object instead of getting the lexical global from ExecState.
54799        Removed an old FIXME that no longer applies since JSObjects can
54800        always find the right global object these days.
54801
54802        Reviewed by Geoff Garen.
54803
54804        * bindings/js/JSCSSRuleCustom.cpp:
54805        (WebCore::toJS):
54806        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
54807        (WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):
54808        * bindings/js/JSCSSValueCustom.cpp:
54809        (WebCore::toJS):
54810        * bindings/js/JSDOMBinding.h:
54811        (WebCore::createWrapper):
54812        (WebCore::wrap):
54813        (WebCore::getExistingWrapper):
54814        (WebCore::createNewWrapper):
54815        (WebCore::toJS):
54816        * bindings/js/JSDOMWindowCustom.cpp:
54817        (WebCore::JSDOMWindow::setTimeout):
54818        (WebCore::JSDOMWindow::setInterval):
54819        (WebCore::JSDOMWindow::addEventListener):
54820        (WebCore::JSDOMWindow::removeEventListener):
54821        * bindings/js/JSDocumentCustom.cpp:
54822        (WebCore::JSDocument::location):
54823        (WebCore::toJS):
54824        * bindings/js/JSElementCustom.cpp:
54825        (WebCore::toJSNewlyCreated):
54826        * bindings/js/JSEventCustom.cpp:
54827        (WebCore::toJS):
54828        * bindings/js/JSHTMLCollectionCustom.cpp:
54829        (WebCore::toJS):
54830        * bindings/js/JSHTMLTemplateElementCustom.cpp:
54831        (WebCore::JSHTMLTemplateElement::content):
54832        * bindings/js/JSImageDataCustom.cpp:
54833        (WebCore::toJS):
54834        * bindings/js/JSNodeCustom.cpp:
54835        (WebCore::createWrapperInline):
54836        * bindings/js/JSNodeCustom.h:
54837        (WebCore::toJS):
54838        * bindings/js/JSSVGPathSegCustom.cpp:
54839        (WebCore::toJS):
54840        * bindings/js/JSStyleSheetCustom.cpp:
54841        (WebCore::toJS):
54842        * bindings/js/JSTextTrackCueCustom.cpp:
54843        (WebCore::toJS):
54844        * bindings/js/JSTrackCustom.cpp:
54845        (WebCore::toJS):
54846        * bindings/js/JSWorkerGlobalScopeCustom.cpp:
54847        (WebCore::JSWorkerGlobalScope::setTimeout):
54848        (WebCore::JSWorkerGlobalScope::setInterval):
54849        * bindings/scripts/CodeGeneratorJS.pm:
54850        (GenerateImplementation):
54851
548522014-03-19  Benjamin Poulain  <bpoulain@apple.com>
54853
54854        Page::setPageScaleFactor should not force the scroll view position when using delegatesScrolling()
54855        https://bugs.webkit.org/show_bug.cgi?id=130429
54856
54857        Reviewed by Simon Fraser.
54858
54859        When setting the same scale mutliple time (for example on load), Page was asking the top scrollview
54860        to scroll to the origin. This is bogus since the scroll view is driving Page::setDeviceScaleFactor,
54861        not the other way around.
54862
54863        Simon fixed the general case in http://trac.webkit.org/changeset/165652/trunk/Source/WebCore/page/Page.cpp
54864        but this branch was still scrolling content.
54865
54866        * page/Page.cpp:
54867        (WebCore::Page::setPageScaleFactor):
54868
548692014-03-19  Brady Eidson  <beidson@apple.com>
54870
54871        Filter out editable services from image menu for non-contenteditable images
54872        <rdar://problem/16319645> and https://bugs.webkit.org/show_bug.cgi?id=130437
54873
54874        Reviewed by Tim Horton.
54875
54876        * WebCore.exp.in:
54877
548782014-03-19  Dirk Schulze  <krit@webkit.org>
54879
54880        Implement method addPath for Path2D
54881        https://bugs.webkit.org/show_bug.cgi?id=130461
54882
54883        Reviewed by Dean Jackson.
54884
54885        Add support for the Path2D method addPath. The method allows
54886        to append and existing Path2D object to another one. It can be
54887        combined with a transformation matrix SVGMatrix.
54888
54889        Test: fast/canvas/canvas-path-addPath.html
54890
54891        * html/canvas/DOMPath.h: Add new method addPath().
54892        (WebCore::DOMPath::addPath):
54893        * html/canvas/DOMPath.idl:
54894        * platform/graphics/Path.h: Add support for appending paths.
54895        * platform/graphics/cairo/PathCairo.cpp:
54896        (WebCore::Path::addPath):
54897        * platform/graphics/cg/PathCG.cpp:
54898        (WebCore::Path::addPath):
54899        * platform/graphics/wince/PathWinCE.cpp:
54900        (WebCore::Path::addPath):
54901
549022014-03-19  Yongjun Zhang  <yongjun_zhang@apple.com>
54903
54904        [iOS] WebKit2 Quicklook.
54905        https://bugs.webkit.org/show_bug.cgi?id=130360
54906
54907        Reviewed by Tim Horton.
54908
54909        Since ResourceLoaders using WebKit2 network process don't have ResourceHandle any more, we
54910        need to make it possible to create QuickLookHandle from ResourceLoader.
54911
54912        * WebCore.exp.in: Make some QuickLookHandle methods visible from WebKit2.
54913        * loader/ResourceLoader.h: Add m_quickLookHandle data member to ResourceLoader.
54914        (WebCore::ResourceLoader::quickLookHandle):
54915        (WebCore::ResourceLoader::setQuickLookHandle):
54916        * platform/network/ios/QuickLook.h: Add a new method to create QuickLookHandle from ResourceLoader.
54917        * platform/network/ios/QuickLook.mm:
54918        (WebCore::QuickLookHandle::create):
54919
549202014-03-19  Brent Fulgham  <bfulgham@apple.com>
54921
54922        Fix cue rendering test and include support for left/right alignment
54923        https://bugs.webkit.org/show_bug.cgi?id=130406
54924
54925        Reviewed by Eric Carlson.
54926
54927        Merged from Blink (patch by vcarbune@chromium.org):
54928        https://chromium.googlesource.com/chromium/blink/+/e695703cb603421c741e59a557a7989113c13b94
54929        http://crbug.com/25155003
54930
54931        No new tests. Covered by media/track/track-cue-rendering-snap-to-lines-not-set.html.
54932
54933        * html/track/VTTCue.cpp:
54934        (WebCore::leftKeyword): Added.
54935        (WebCore::rightKeyword): Added.
54936        (WebCore::VTTCueBox::applyCSSProperties): Added.
54937        (WebCore::VTTCue::VTTCue):
54938        (WebCore::VTTCue::align): Handle left/right alignment.
54939        (WebCore::VTTCue::setAlign): Ditto.
54940        (WebCore::VTTCue::calculateDisplayParameters): Refactored and revised for left/right tokens.
54941        (WebCore::VTTCue::setCueSettings): Ditto.
54942        (WebCore::VTTCue::getCSSAlignment): Added.
54943        (WebCore::VTTCue::getCSSWritingMode): Added.
54944        * html/track/VTTCue.h:
54945
549462014-03-18  Anders Carlsson  <andersca@apple.com>
54947
54948        Add new functionality that will be required by the history item decoding
54949        https://bugs.webkit.org/show_bug.cgi?id=130433
54950
54951        Reviewed by Sam Weinig.
54952
54953        * platform/KeyedCoding.h:
54954        (WebCore::KeyedDecoder::decodeConditionalObject):
54955
549562014-03-19  Tim Horton  <timothy_horton@apple.com>
54957
54958        Fix the iOS build.
54959
54960        * html/BaseDateAndTimeInputType.cpp:
54961        (WebCore::BaseDateAndTimeInputType::parseToDateComponents):
54962        Missing a StringView().
54963
549642014-03-19  Antti Koivisto  <antti@apple.com>
54965
54966        Tighten ElementRuleCollector::m_matchedRuleList typing
54967        https://bugs.webkit.org/show_bug.cgi?id=130446
54968
54969        Reviewed by Anders Carlsson.
54970
54971        StyleRuleBase -> StyleRule.
54972
54973        * css/ElementRuleCollector.cpp:
54974        (WebCore::ElementRuleCollector::matchedRuleList):
54975        * css/ElementRuleCollector.h:
54976        * css/StyleResolver.cpp:
54977        (WebCore::StyleResolver::styleRulesForElement):
54978        (WebCore::StyleResolver::pseudoStyleRulesForElement):
54979        * css/StyleResolver.h:
54980        * editing/EditingStyle.cpp:
54981        (WebCore::styleFromMatchedRulesForElement):
54982        * inspector/InspectorCSSAgent.cpp:
54983        (WebCore::InspectorCSSAgent::getMatchedStylesForNode):
54984        (WebCore::InspectorCSSAgent::buildArrayForMatchedRuleList):
54985        * inspector/InspectorCSSAgent.h:
54986        * page/DOMWindow.cpp:
54987        (WebCore::DOMWindow::getMatchedCSSRules):
54988
549892014-03-19  Mihnea Ovidenie  <mihnea@adobe.com>
54990
54991        [CSSRegions] An unsplittable box is always displayed in a single region
54992        https://bugs.webkit.org/show_bug.cgi?id=130451
54993
54994        Reviewed by Andrei Bucur.
54995
54996        Add an ASSERT stating that an unsplittable box region range always contains 1 region.
54997        No new functionality, no new tests.
54998
54999        * rendering/RenderFlowThread.cpp:
55000        (WebCore::RenderFlowThread::getRegionRangeForBox):
55001
550022014-03-19  Zalan Bujtas  <zalan@apple.com>
55003
55004        Subpixel rendering: Transform origin is miscalculated when RenderLayer's
55005        offsetfromRenderer has device pixel fraction value.
55006        https://bugs.webkit.org/show_bug.cgi?id=129859
55007
55008        Reviewed by Simon Fraser.
55009
55010        We need to calculate the transformed origin using the painting coordinates to produce
55011        pixel precise result.
55012
55013        * rendering/RenderLayerBacking.cpp:
55014        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
55015        (WebCore::RenderLayerBacking::computeTransformOriginForPainting):
55016        * rendering/RenderLayerBacking.h:
55017
550182014-03-19  Claudio Saavedra  <csaavedra@igalia.com>
55019
55020        [GStreamer] Clean timeout source ids
55021        https://bugs.webkit.org/show_bug.cgi?id=130450
55022
55023        Reviewed by Philippe Normand.
55024
55025        Sources IDs need to be cleaned up if the callback removes the
55026        source, otherwise we'll be attempting to remove an empty source at
55027        some point.
55028
55029        * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp:
55030        (webKitMediaVideoSrcStart): Clean the source id.
55031        (webKitMediaAudioSrcStart): Ditto.
55032        (webKitMediaVideoSrcSeekMainCb): Ditto.
55033        (webKitMediaAudioSrcSeekMainCb): Ditto.
55034
550352014-03-19  Mihnea Ovidenie  <mihnea@adobe.com>
55036
55037        [CSSRegions] Compute region ranges for children of inline blocks
55038        https://bugs.webkit.org/show_bug.cgi?id=130392
55039
55040        Reviewed by Andrei Bucur.
55041
55042        Extend the region ranges computation for children of inline blocks.
55043        When we cannot retrieve the region range for a box using cached information,
55044        either from region range map or from the region cached on the RootInlineBox,
55045        try to find the top most unsplittable box up to the flow thread boundary.
55046        If we find such unsplittable box and the box has a region range, then return
55047        this range.
55048
55049        Before this patch, method getRegionRangeForBox did not return true/false
55050        if it was able to retrieve the range and the caller checked the returned
55051        region values. I modified the method to return true if we were able to compute
55052        the range.
55053
55054        Tests: fast/regions/inline-block-inline-children-flowed-in-regions.html
55055               fast/regions/inline-blocks-dyn-enlarged-regions.html
55056               fast/regions/inline-blocks-dyn-shrunk-regions.html
55057               fast/regions/inline-blocks-in-two-regions.html
55058
55059        * inspector/InspectorOverlay.cpp:
55060        (WebCore::buildObjectForRendererFragments):
55061        * rendering/RenderBlock.cpp:
55062        (WebCore::RenderBlock::updateRegionRangeForBoxChild):
55063        * rendering/RenderBlockFlow.cpp:
55064        (WebCore::RenderBlockFlow::hasNextPage):
55065        * rendering/RenderBox.cpp:
55066        (WebCore::RenderBox::clampToStartAndEndRegions):
55067        (WebCore::RenderBox::borderBoxRectInRegion):
55068        (WebCore::RenderBox::computeRectForRepaint):
55069        (WebCore::RenderBox::layoutOverflowRectForPropagation):
55070        * rendering/RenderBoxModelObject.cpp:
55071        (WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
55072        * rendering/RenderFlowThread.cpp:
55073        (WebCore::RenderFlowThread::regionForCompositedLayer):
55074        (WebCore::RenderFlowThread::adjustedPositionRelativeToOffsetParent):
55075        (WebCore::RenderFlowThread::removeRenderBoxRegionInfo):
55076        (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock):
55077        (WebCore::RenderFlowThread::getRegionRangeForBoxFromCachedInfo):
55078        (WebCore::RenderFlowThread::getRegionRangeForBox):
55079        (WebCore::RenderFlowThread::objectShouldPaintInFlowRegion):
55080        (WebCore::RenderFlowThread::objectInFlowRegion):
55081        (WebCore::RenderFlowThread::addRegionsVisualEffectOverflow):
55082        (WebCore::RenderFlowThread::addRegionsVisualOverflowFromTheme):
55083        (WebCore::RenderFlowThread::addRegionsOverflowFromChild):
55084        (WebCore::RenderFlowThread::addRegionsLayoutOverflow):
55085        (WebCore::RenderFlowThread::addRegionsVisualOverflow):
55086        (WebCore::RenderFlowThread::clearRegionsOverflow):
55087        * rendering/RenderFlowThread.h:
55088        * rendering/RenderNamedFlowThread.cpp:
55089        (WebCore::RenderNamedFlowThread::fragmentFromAbsolutePointAndBox):
55090        * rendering/RenderObject.cpp:
55091        (WebCore::RenderObject::locateFlowThreadContainingBlock):
55092        Make sure we return the right render flow thread in the case of
55093        region-based multicolumn inside named flows.
55094        * rendering/RenderRegion.cpp:
55095        (WebCore::RenderRegion::rectFlowPortionForBox):
55096
550972014-03-19  Krzysztof Wolanski  <k.wolanski@samsung.com>
55098
55099        [EFL] vibration/cancelVibration-during-pattern-vibrating.html is failing after r165598
55100        https://bugs.webkit.org/show_bug.cgi?id=130333
55101
55102        Reviewed by Gyuyoung Kim.
55103
55104        Added setting m_state when calling Vibration::vibrate. It was missing after
55105        refactoring Vibration (r165598).
55106
55107        * Modules/vibration/Vibration.cpp:
55108        (WebCore::Vibration::vibrate):
55109
551102014-03-19  Sam Weinig  <sam@webkit.org>
55111
55112        Rewrite WebHTMLConverter::_colorForNode in C++
55113        https://bugs.webkit.org/show_bug.cgi?id=130443
55114
55115        Reviewed by Andreas Kling.
55116
55117        * platform/mac/HTMLConverter.mm:
55118        (_platformColor):
55119        Rename from _colorForRGBColor and simplify to just do the platform conversion.
55120
55121        (normalizedColor):
55122        Extract normalization out of _colorForRGBColor and remove cases that are impossible to hit
55123        due to us only ever using the device color space.
55124
55125        (HTMLConverterCaches::colorPropertyValueForNode):
55126        (-[WebHTMLConverter _colorForNode:property:]):
55127        Convert to C++.
55128
55129        (-[WebHTMLConverter dealloc]):
55130        (-[WebHTMLConverter init]):
55131        Remove caches, we already cache in ColorMac.
55132
551332014-03-18  Andrei Bucur  <abucur@adobe.com>
55134
55135        [CSS Regions] Strange layout for content with region breaks
55136        https://bugs.webkit.org/show_bug.cgi?id=121318
55137
55138        Reviewed by Mihnea Ovidenie.
55139
55140        When break-inside: avoid is used on an element, the implementation tries to
55141        force it inside a single fragmentation container even though the descendants
55142        of the element specify forced breaks. This leads to unexpected results and
55143        unstable layout.
55144
55145        The change extends the definition of unsplittable elements for flow threads
55146        using the same conditions found inside RenderBlockFlow::adjustForUnsplittableChild.
55147        This change forces elements that require break avoidance to have a single region
55148        in the region range. As a result, forced breaks have no effect inside them.
55149
55150        It should be noted this may not the behavior defined by the CSS3 Fragmentation spec.
55151        From my understanding of the text, forced breaks override any avoidance specified
55152        by ancestor elements. However, implementing this is a larger change that will require
55153        a fundamental new approach in handling break avoidance. This patch just brings
55154        consistency to the API.
55155
55156        Test: fast/regions/forced-break-inside-avoid-break.html
55157
55158        * rendering/RenderBlock.cpp:
55159        (WebCore::RenderBlock::childBoxIsUnsplittableForFragmentation):
55160        (WebCore::RenderBlock::computeRegionRangeForBoxChild):
55161        (WebCore::RenderBlock::estimateRegionRangeForBoxChild):
55162        * rendering/RenderBlock.h:
55163        * rendering/RenderBlockFlow.cpp:
55164        (WebCore::RenderBlockFlow::adjustForUnsplittableChild): Move the avoidance conditions inside
55165        a helper method RenderBlock::childBoxIsUnsplittableForFragmentation.
55166
551672014-03-18  Samuel White  <samuel_white@apple.com>
55168
55169        AX: Not able to use arrow keys to read text with VoiceOver before selection is set someplace (anyplace).
55170        https://bugs.webkit.org/show_bug.cgi?id=130250
55171
55172        Reviewed by Chris Fleizach.
55173
55174        If initial selection isn't set when we handle selection movement for accessibility, we need to set it. If we don't, using arrow
55175        keys to read text with VoiceOver doesn't work as expected. Things will only start working after the user holds shift and arrows
55176        around to select any arbitrary thing to force selection to get set. This logic handles that special case more gracefully.
55177
55178        Test: platform/mac/accessibility/selection-initial.html
55179
55180        * page/EventHandler.cpp:
55181        (WebCore::handleKeyboardSelectionMovement):
55182        (WebCore::EventHandler::handleKeyboardSelectionMovementForAccessibility):
55183        * testing/Internals.cpp:
55184        (WebCore::Internals::resetToConsistentState):
55185
551862014-03-18  Brent Fulgham  <bfulgham@apple.com>
55187
55188        TextTrackRegion Not Implemented
55189        https://bugs.webkit.org/show_bug.cgi?id=116546
55190
55191        Reviewed by Eric Carlson.
55192
55193        Merged from Blink (patch by vcarbune@chromium.org):
55194        https://chromium.googlesource.com/chromium/blink/+/4940f89a087fea5b5ea628e98d0b355d398a9eea
55195        http://crbug.com/25798003
55196
55197        Tests: media/track/regions-webvtt/text-track-region-display.html
55198               media/track/regions-webvtt/text-track-region-dom-layout.html
55199
55200        * html/HTMLMediaElement.cpp:
55201        (WebCore::HTMLMediaElement::parseAttribute):
55202        * html/track/LoadableTextTrack.cpp:
55203        (WebCore::LoadableTextTrack::newRegionsAvailable):
55204        * html/track/TextTrack.cpp:
55205        * html/track/TextTrack.h:
55206        * html/track/TextTrackRegion.cpp:
55207        (WebCore::TextTrackRegion::TextTrackRegion):
55208        (WebCore::TextTrackRegion::appendTextTrackCueBox):
55209        * html/track/TextTrackRegion.h:
55210        * html/track/VTTCue.cpp:
55211        (WebCore::VTTCue::VTTCue):
55212        (WebCore::VTTCue::notifyRegionWhenRemovingDisplayTree):
55213        (WebCore::VTTCue::removeDisplayTree):
55214        * html/track/VTTCue.h:
55215        * html/track/WebVTTParser.cpp:
55216        (WebCore::WebVTTParser::parseBytes):
55217        (WebCore::WebVTTParser::collectMetadataHeader):
55218        * html/track/WebVTTParser.h:
55219
552202014-03-18  Andreas Kling  <akling@apple.com>
55221
55222        Share MemoryPressureHandler::releaseMemory() between platforms.
55223        <https://webkit.org/b/130416>
55224
55225        Move the code that scours WebKit for things we can free up right now
55226        to the common part of MemoryPressureHandler. This will enable other
55227        platforms to do the same thing under pressure.
55228
55229        There's now also a platformReleaseMemory() where platform-specific
55230        pressure relief stuff can go.
55231
55232        Reviewed by Antti Koivisto.
55233
55234        * platform/MemoryPressureHandler.cpp:
55235        (WebCore::MemoryPressureHandler::releaseMemory):
55236        (WebCore::MemoryPressureHandler::platformReleaseMemory):
55237        * platform/MemoryPressureHandler.h:
55238        * platform/mac/MemoryPressureHandlerMac.mm:
55239        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
55240        (WebCore::MemoryPressureHandler::platformReleaseMemory):
55241
552422014-03-18  Dean Jackson  <dino@apple.com>
55243
55244        [WebGL] Destroy EAGLContext's backing store
55245        https://bugs.webkit.org/show_bug.cgi?id=130439
55246        <rdar://problem/16295217>
55247
55248        Reviewed by Tim Horton.
55249
55250        When a GraphicsContext3D is being destroyed, we should
55251        also remove any EAGLContext backing store.
55252
55253        * platform/graphics/mac/GraphicsContext3DMac.mm:
55254        (WebCore::GraphicsContext3D::~GraphicsContext3D):
55255
552562014-03-18  Tim Horton  <timothy_horton@apple.com>
55257
55258        [iOS][WebKit2] Mark layer contents as being opaque if they are
55259        https://bugs.webkit.org/show_bug.cgi?id=130427
55260        <rdar://problem/15540434>
55261
55262        Reviewed by Simon Fraser.
55263
55264        * platform/graphics/GraphicsLayerClient.h:
55265        (WebCore::GraphicsLayerClient::paintsOpaquelyAtNonIntegralScales):
55266        * platform/graphics/ca/GraphicsLayerCA.cpp:
55267        (WebCore::GraphicsLayerCA::updateContentsOpaque):
55268        * rendering/RenderLayerBacking.cpp:
55269        (WebCore::RenderLayerBacking::paintsOpaquelyAtNonIntegralScales):
55270        * rendering/RenderLayerBacking.h:
55271        r159463 stopped us from setting layers opaque if they were being painted
55272        at non-integral scale. This makes sense for compositing layers, which
55273        are painted by arbitrary elements, but the main frame's RenderView
55274        will always paint its entire contents. To restore the opaque contents
55275        optimization to the main frame's tiles, don't de-opaquify layers
55276        belonging to the main frame's RenderView.
55277
552782014-03-18  Jeffrey Pfau  <jpfau@apple.com>
55279
55280        Unify <media> element callback registration and unregistration
55281        https://bugs.webkit.org/show_bug.cgi?id=130417
55282
55283        Reviewed by Eric Carlson.
55284
55285        * html/HTMLMediaElement.cpp:
55286        (WebCore::HTMLMediaElement::HTMLMediaElement):
55287        (WebCore::HTMLMediaElement::~HTMLMediaElement):
55288        (WebCore::HTMLMediaElement::registerWithDocument):
55289        (WebCore::HTMLMediaElement::unregisterWithDocument):
55290        (WebCore::HTMLMediaElement::didMoveToNewDocument):
55291        * html/HTMLMediaElement.h:
55292
552932014-03-18  Jer Noble  <jer.noble@apple.com>
55294
55295        MediaDocument should set a max-width on its <video> element.
55296        https://bugs.webkit.org/show_bug.cgi?id=114691
55297
55298        Reviewed by Eric Carlson.
55299
55300        Set a style attribute containing max-width:100% and max-height:100% so that large videos
55301        are entirely visible within the browser window bounds.
55302
55303        * html/MediaDocument.cpp:
55304        (WebCore::MediaDocumentParser::createDocumentStructure):
55305
553062014-03-18  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
55307
55308        [WebRTC] Fix layering violation in RTCStatsRequest
55309        https://bugs.webkit.org/show_bug.cgi?id=130426
55310
55311        Reviewed by Eric Carlson.
55312
55313        RTCStatsRequest::track() should return a MediaStreamTrackPrivate*.
55314
55315        No new tests needed.
55316
55317        * Modules/mediastream/RTCPeerConnection.cpp:
55318        (WebCore::RTCPeerConnection::getStats):
55319        * Modules/mediastream/RTCStatsRequestImpl.cpp:
55320        (WebCore::RTCStatsRequestImpl::create):
55321        (WebCore::RTCStatsRequestImpl::RTCStatsRequestImpl):
55322        (WebCore::RTCStatsRequestImpl::track):
55323        * Modules/mediastream/RTCStatsRequestImpl.h:
55324        * platform/mediastream/RTCStatsRequest.h:
55325
553262014-03-18  Anders Carlsson  <andersca@apple.com>
55327
55328        Fix a trivial FIXME
55329        https://bugs.webkit.org/show_bug.cgi?id=130432
55330
55331        Reviewed by Tim Horton.
55332
55333        * history/HistoryItem.cpp:
55334        (WebCore::HistoryItem::encodeBackForwardTreeNode):
55335
553362014-03-18  Anders Carlsson  <andersca@apple.com>
55337
55338        Begin cleaning up KeyedDecoder and KeyedEncoder
55339        https://bugs.webkit.org/show_bug.cgi?id=130431
55340
55341        Reviewed by Tim Horton.
55342
55343        Rename KeyedDecoder::decodeVerifiedEnum to decodeEnum to match the encode function,
55344        and sort the decode functions to be in the same logical order as the encode functions.
55345
55346        * Modules/indexeddb/IDBKeyData.cpp:
55347        (WebCore::IDBKeyData::decode):
55348        * Modules/indexeddb/IDBKeyPath.cpp:
55349        (WebCore::IDBKeyPath::decode):
55350        * platform/KeyedCoding.h:
55351        (WebCore::KeyedDecoder::decodeEnum):
55352
553532014-03-18  Darin Adler  <darin@apple.com>
55354
55355        Reduce use of deprecatedCharacters in WebCore
55356        https://bugs.webkit.org/show_bug.cgi?id=130318
55357
55358        Reviewed by Andreas Kling.
55359
55360        * Modules/indexeddb/IDBKeyPath.cpp:
55361        (WebCore::IDBKeyPathLexer::IDBKeyPathLexer): Use StringView for parsing.
55362        (WebCore::IDBKeyPathLexer::lex): Ditto.
55363        (WebCore::IDBKeyPathLexer::lexIdentifier): Ditto.
55364
55365        * Modules/indexeddb/leveldb/IDBLevelDBCoding.cpp:
55366        (WebCore::IDBLevelDBCoding::encodeString): Index directly into string instead of
55367        using deprecatedCharacters.
55368
55369        * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
55370        (WebCore::ThreadableWebSocketChannelClientWrapper::setSubprotocol): Use
55371        StringView::getCharactersWithUpconvert.
55372        (WebCore::ThreadableWebSocketChannelClientWrapper::setExtensions): Ditto.
55373
55374        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
55375        (-[WebAccessibilityObjectWrapper arrayOfTextForTextMarkers:attributed:]):
55376        Use operator NSString * instead of explicitly creating an NSString.
55377
55378        * bindings/js/SerializedScriptValue.cpp:
55379        (WebCore::writeLittleEndianUInt16): Added.
55380        (WebCore::CloneSerializer::serialize): Added a separate code path for 8-bit strings.
55381        (WebCore::CloneSerializer::write): Ditto.
55382
55383        * bindings/objc/WebScriptObject.mm:
55384        (+[WebScriptObject _convertValueToObjcValue:JSC::originRootObject:rootObject:]):
55385        Use operator NSString * instead of explicitly creating an NSString.
55386
55387        * dom/Document.cpp:
55388        (WebCore::Document::parseQualifiedName): Index directly into string instead of
55389        using deprecatedCharacters.
55390        * editing/CompositeEditCommand.cpp:
55391        (WebCore::containsOnlyWhitespace): Ditto.
55392        * editing/SmartReplace.cpp:
55393        (WebCore::addAllCodePoints): Ditto.
55394        (WebCore::getSmartSet): Use StringView::upconvertedCharacters.
55395
55396        * editing/TextIterator.cpp:
55397        (WebCore::foldQuoteMarksAndSoftHyphens): Changed to return a value so it can be
55398        used in initialization rather than assignment.
55399        (WebCore::SearchBuffer::SearchBuffer): Use StringView::upconvertedCharacters.
55400
55401        * editing/TypingCommand.cpp:
55402        (WebCore::TypingCommand::insertText): Index directly into string instead of using
55403        deprecatedCharacters.
55404        * editing/VisiblePosition.cpp:
55405        (WebCore::VisiblePosition::characterAfter): Ditto.
55406        * editing/VisibleUnits.cpp:
55407        (WebCore::startOfParagraph): Ditto.
55408        (WebCore::endOfParagraph): Ditto.
55409
55410        * fileapi/WebKitBlobBuilder.cpp:
55411        (WebCore::BlobBuilder::append): Pass a StringView to TextEncoding::encode.
55412
55413        * html/BaseDateAndTimeInputType.cpp:
55414        (WebCore::BaseDateAndTimeInputType::parseToDateComponents): Use
55415        StringView::upconvertedCharacters.
55416
55417        * html/FormDataList.cpp:
55418        (WebCore::FormDataList::appendString): Pass a StringView to TextEncoding::encode.
55419
55420        * html/canvas/CanvasRenderingContext2D.cpp:
55421        (WebCore::normalizeSpaces): Use StringView::getCharactersWithUpconvert.
55422
55423        * html/parser/HTMLParserIdioms.cpp:
55424        (WebCore::stripLeadingAndTrailingHTMLSpaces): Use characters16 for a code path
55425        that already handled 8-bit characters separately.
55426        (WebCore::parseHTMLNonNegativeInteger): Ditto.
55427        (WebCore::parseDescriptors): Added an 8-bit code path.
55428
55429        * inspector/InspectorStyleSheet.cpp:
55430        (WebCore::InspectorStyle::newLineAndWhitespaceDelimiters): Index directly into
55431        string instead of using deprecatedCharacters.
55432        * inspector/InspectorStyleTextEditor.cpp:
55433        (WebCore::InspectorStyleTextEditor::insertProperty): Ditto.
55434        (WebCore::InspectorStyleTextEditor::internalReplaceProperty): Ditto.
55435
55436        * page/ContentSecurityPolicy.cpp:
55437        (WebCore::isSourceListNone): Use StringView::upconvertedCharacters.
55438        (WebCore::CSPSourceList::parse): Ditto.
55439        (WebCore::NonceDirective::parse): Ditto.
55440        (WebCore::MediaListDirective::parse): Ditto.
55441        (WebCore::CSPDirectiveList::parse): Ditto.
55442        (WebCore::CSPDirectiveList::parseReportURI): Ditto.
55443        (WebCore::CSPDirectiveList::parseReflectedXSS): Ditto.
55444        (WebCore::ContentSecurityPolicy::didReceiveHeader): Ditto.
55445
55446        * page/PageSerializer.cpp:
55447        (WebCore::PageSerializer::serializeFrame): Pass a StringView into
55448        TextEncoding::encode.
55449        (WebCore::PageSerializer::serializeCSSStyleSheet): Ditto.
55450
55451        * platform/Length.cpp:
55452        (WebCore::countCharacter): Index directly into string instead of using
55453        deprecatedCharacters. Also changed to take a StringImpl&.
55454        (WebCore::newCoordsArray): Ditto. Call countCharacter the new way, and
55455        use StringView::upconvertedCharacters.
55456        (WebCore::newLengthArray): Ditto.
55457
55458        * platform/LinkHash.cpp:
55459        (WebCore::visitedLinkHash): Use characters16 for the 16-bit path.
55460        Also removed unused visitedURL function.
55461        * platform/LinkHash.h: Removed unused visitedURL function.
55462
55463        * platform/SharedBuffer.cpp:
55464        (WebCore::utf8Buffer): Added an 8-bit code path.
55465        * platform/URL.cpp:
55466        (WebCore::URL::port): Ditto.
55467        (WebCore::encodeRelativeString): Use StringView to call TextEncoding::encode.
55468
55469        * platform/graphics/Color.cpp:
55470        (WebCore::Color::parseHexColor): Use characters16 in the 16-bit path.
55471        (WebCore::Color::Color): Ditto.
55472
55473        * platform/graphics/harfbuzz/HarfBuzzFaceCairo.cpp:
55474        (WebCore::harfBuzzGetGlyph): Use StringView to call TextEncoding::encode.
55475
55476        * platform/graphics/StringTruncator.cpp:
55477        (WebCore::centerTruncateToBuffer): Use StringView::getCharactersWithUpconvert.
55478        (WebCore::rightTruncateToBuffer): Ditto.
55479        (WebCore::rightClipToCharacterBuffer): Ditto.
55480        (WebCore::rightClipToWordBuffer): Ditto.
55481        (WebCore::leftTruncateToBuffer): Ditto.
55482        (WebCore::truncateString): Ditto.
55483
55484        * platform/graphics/TextRun.h:
55485        (WebCore::TextRun::TextRun): Use characters16 in the 16-bit code path.
55486
55487        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
55488        (WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource):
55489        Use StringView::upconvertedCharacters.
55490
55491        * platform/network/DataURL.cpp:
55492        (WebCore::handleDataURL): Use StringView to call TextEncoding::encode.
55493        * platform/network/FormDataBuilder.cpp:
55494        (WebCore::FormDataBuilder::addFilenameToMultiPartHeader): Ditto.
55495
55496        * platform/sql/SQLiteStatement.cpp:
55497        (WebCore::SQLiteStatement::bindBlob): Use StringView::upconvertedCharacters.
55498        (WebCore::SQLiteStatement::bindText): Ditto.
55499
55500        * platform/text/DecodeEscapeSequences.h:
55501        (WebCore::Unicode16BitEscapeSequence::decodeRun): Changed to take a StringView.
55502        (WebCore::URLEscapeSequence::decodeRun): Ditto.
55503        (WebCore::decodeEscapeSequences): Pass StringView to decodeRun.
55504
55505        * platform/text/Hyphenation.cpp:
55506        (WebCore::lastHyphenLocation): Take a StringView.
55507        * platform/text/Hyphenation.h: Make lastHyphenLocation take a StringView.
55508
55509        * platform/text/TextBreakIterator.cpp:
55510        (WebCore::initializeIteratorWithRules): Use StringView::upconvertedCharacters.
55511
55512        * platform/text/TextEncoding.cpp:
55513        (WebCore::TextEncoding::encode): Use StringView::upconvertedCharacters.
55514        Change argument type to StringView.
55515        * platform/text/TextEncoding.h: Ditto.
55516
55517        * platform/text/TextEncodingRegistry.cpp:
55518        (WebCore::atomicCanonicalTextEncodingName): Use characters16 for the 16-bit path.
55519
55520        * platform/text/cf/HyphenationCF.cpp:
55521        (WebCore::lastHyphenLocation): Use StringView::text.createCFStringWithoutCopying.
55522        Change argument type to StringView.
55523
55524        * rendering/RenderBlock.cpp:
55525        (WebCore::RenderBlock::constructTextRun): Use characters16 for the 16-bit path.
55526
55527        * rendering/RenderCombineText.cpp:
55528        (WebCore::RenderCombineText::width): Removed check for null characters pointer,
55529        since the pointer will never be null, and even if it was there would be no need
55530        for an early exit.
55531
55532        * rendering/RenderText.cpp:
55533        (WebCore::maxWordFragmentWidth): Take a StringView.
55534        (WebCore::RenderText::computePreferredLogicalWidths): Pass in a StringView.
55535        * rendering/line/BreakingContextInlineHeaders.h:
55536        (WebCore::tryHyphenating): Ditto.
55537
55538        * rendering/svg/SVGTextLayoutEngine.cpp:
55539        (WebCore::SVGTextLayoutEngine::layoutTextOnLineOrPath): Use
55540        StringView::upconvertedCharacters.
55541
55542        * rendering/svg/SVGTextMetrics.cpp:
55543        (WebCore::SVGTextMetrics::SVGTextMetrics): Use String::substring.
55544
55545        * svg/SVGAngle.cpp:
55546        (WebCore::SVGAngle::setValueAsString): Use StringView::upconvertedCharacters.
55547        * svg/SVGAnimateMotionElement.cpp:
55548        (WebCore::parsePoint): Ditto.
55549        * svg/SVGAnimationElement.cpp:
55550        (WebCore::parseKeySplines): Ditto.
55551        * svg/SVGFitToViewBox.cpp:
55552        (WebCore::SVGFitToViewBox::parseViewBox): Ditto.
55553
55554        * svg/SVGFontData.cpp:
55555        (WebCore::SVGFontData::applySVGGlyphSelection): Pass StringView to
55556        createStringWIthMirroredCharacters.
55557        (WebCore::createStringWithMirroredCharacters): Changed to use StringView and
55558        use indexing into that instead of a characters pointer.
55559
55560        * svg/SVGFontData.h: Removed createStringWithMirroredCharacters member function,
55561        since it has nothing to do with the SVGFontData object. Now it's just a private
55562        helper function in the SVGFontData.cpp source file.
55563
55564        * svg/SVGFontElement.cpp:
55565        (WebCore::SVGFontElement::registerLigaturesInGlyphCache): Index into the string
55566        instead of using deprecatedCharacters.
55567
55568        * svg/SVGGlyphMap.h:
55569        (WebCore::SVGGlyphMap::addGlyph): Use StringView::upconvertedCharacters.
55570        (WebCore::SVGGlyphMap::collectGlyphsForString): Ditto.
55571        * svg/SVGGlyphRefElement.cpp:
55572        (WebCore::SVGGlyphRefElement::parseAttribute): Ditto.
55573        * svg/SVGLength.cpp:
55574        (WebCore::SVGLength::setValueAsString): Ditto.
55575        * svg/SVGLengthList.cpp:
55576        (WebCore::SVGLengthList::parse): Ditto.
55577        * svg/SVGNumberList.cpp:
55578        (WebCore::SVGNumberList::parse): Ditto.
55579        * svg/SVGParserUtilities.cpp:
55580        (WebCore::parseNumberFromString): Ditto.
55581        (WebCore::parseNumberOptionalNumber): Ditto.
55582        (WebCore::parseRect): Ditto.
55583        (WebCore::pointsListFromSVGData): Ditto.
55584        (WebCore::parseGlyphName): Ditto.
55585        (WebCore::parseKerningUnicodeString): Ditto.
55586        (WebCore::parseDelimitedString): Ditto.
55587        * svg/SVGPreserveAspectRatio.cpp:
55588        (WebCore::SVGPreserveAspectRatio::parse): Ditto.
55589        * svg/SVGStringList.cpp:
55590        (WebCore::SVGStringList::parse): Ditto.
55591        * svg/SVGTransformList.cpp:
55592        (WebCore::SVGTransformList::parse): Ditto.
55593        * svg/SVGTransformable.cpp:
55594        (WebCore::SVGTransformable::parseTransformType): Ditto.
55595        * svg/SVGViewSpec.cpp:
55596        (WebCore::SVGViewSpec::parseViewSpec): Ditto.
55597        * svg/SVGZoomAndPan.h:
55598        (WebCore::SVGZoomAndPan::parseAttribute): Ditto.
55599
55600        * xml/XMLHttpRequest.cpp:
55601        (WebCore::XMLHttpRequest::send): Pass a StringView to TextEncoding::encode.
55602
55603        * xml/XSLStyleSheetLibxslt.cpp:
55604        (WebCore::XSLStyleSheet::parseString): Use StringView::upconvertedCharacters.
55605
556062014-03-18  Bem Jones-Bey  <bjonesbe@adobe.com>
55607
55608        LayoutBox is a terrible name
55609        https://bugs.webkit.org/show_bug.cgi?id=130351
55610
55611        Reviewed by Simon Fraser.
55612
55613        Rename LayoutBox to CSSBoxType. Also rename the functions and methods
55614        that mention "LayoutBox" to something that makes sense for each
55615        specific situation.
55616
55617        No new tests, no behavior change.
55618
55619        * css/BasicShapeFunctions.cpp:
55620        (WebCore::valueForBasicShape):
55621        (WebCore::basicShapeForValue):
55622        * css/CSSBasicShapes.cpp:
55623        (WebCore::CSSBasicShapeCircle::cssText):
55624        (WebCore::CSSBasicShapeCircle::equals):
55625        (WebCore::CSSBasicShapeEllipse::cssText):
55626        (WebCore::CSSBasicShapeEllipse::equals):
55627        (WebCore::CSSBasicShapePolygon::cssText):
55628        (WebCore::CSSBasicShapePolygon::equals):
55629        (WebCore::CSSBasicShapeInset::cssText):
55630        * css/CSSBasicShapes.h:
55631        (WebCore::CSSBasicShape::referenceBox):
55632        (WebCore::CSSBasicShape::setReferenceBox):
55633        * css/CSSComputedStyleDeclaration.cpp:
55634        (WebCore::shapePropertyValue):
55635        * css/CSSPrimitiveValueMappings.h:
55636        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
55637        (WebCore::CSSPrimitiveValue::operator CSSBoxType):
55638        * css/DeprecatedStyleBuilder.cpp:
55639        (WebCore::ApplyPropertyClipPath::applyValue):
55640        (WebCore::ApplyPropertyShape::applyValue):
55641        * page/animation/CSSPropertyAnimation.cpp:
55642        (WebCore::blendFunc):
55643        * rendering/ClipPathOperation.h:
55644        (WebCore::ShapeClipPathOperation::setReferenceBox):
55645        (WebCore::ShapeClipPathOperation::referenceBox):
55646        (WebCore::BoxClipPathOperation::create):
55647        (WebCore::BoxClipPathOperation::referenceBox):
55648        (WebCore::BoxClipPathOperation::BoxClipPathOperation):
55649        * rendering/shapes/Shape.cpp:
55650        (WebCore::Shape::createBoxShape):
55651        * rendering/shapes/Shape.h:
55652        * rendering/shapes/ShapeInfo.cpp:
55653        (WebCore::ShapeInfo<RenderType>::computedShape):
55654        * rendering/shapes/ShapeInfo.h:
55655        * rendering/shapes/ShapeInsideInfo.h:
55656        * rendering/shapes/ShapeOutsideInfo.h:
55657        * rendering/style/BasicShapes.cpp:
55658        (WebCore::BasicShape::canBlend):
55659        * rendering/style/BasicShapes.h:
55660        (WebCore::BasicShape::referenceBox):
55661        (WebCore::BasicShape::setReferenceBox):
55662        (WebCore::BasicShape::BasicShape):
55663        * rendering/style/RenderStyleConstants.h:
55664        * rendering/style/ShapeValue.h:
55665        (WebCore::ShapeValue::createShapeValue):
55666        (WebCore::ShapeValue::createBoxShapeValue):
55667        (WebCore::ShapeValue::cssBox):
55668        (WebCore::ShapeValue::ShapeValue):
55669
556702014-03-18  Daniel Bates  <dabates@apple.com>
55671
55672        REGRESSION (r162334): RenderTableCol::styleDidChange uses out-of-date table information
55673        https://bugs.webkit.org/show_bug.cgi?id=129561
55674
55675        Reviewed by Antti Koivisto.
55676
55677        Test: fast/table/update-col-width-and-remove-table-cell-crash.html
55678
55679        Fixes an issue where a table column or table column group may query an out-
55680        of-date model of its associated table as part of its process to propagate
55681        style changes to affected table cells.
55682
55683        * rendering/RenderTableCol.cpp:
55684        (WebCore::RenderTableCol::styleDidChange): Ensure that all sections in the table
55685        are up-to-date before querying for a table cell.
55686        * rendering/RenderTableSection.cpp:
55687        (WebCore::RenderTableSection::recalcCells): Update comment to read well. In
55688        particular, remove the reference to RenderTableSection::fillRowsWithDefaultStartingAtPosition()
55689        as this function was removed in <http://trac.webkit.org/changeset/99919>.
55690        (WebCore::RenderTableSection::setNeedsCellRecalc): Clear the grid preemptively to
55691        to ensure that accessors cannot access stale data. We'll build the grid again
55692        in RenderTableSection::recalcCells().
55693        (WebCore::RenderTableSection::numColumns): Add ASSERT(!m_needsCellRecalc) to assert
55694        that the grid cells are up-to-date. That is, we don't need to calculate them again.
55695        * rendering/RenderTableSection.h: Add ASSERT(!m_needsCellRecalc) or call recalcCellsIfNeeded()
55696        before accessing the grid to ensure that it's up-to-date.
55697
556982014-03-18  Daniel Bates  <dabates@apple.com>
55699
55700        REGRESSION (r163560): ASSERTION FAILED: childrenInline() in WebCore::RenderSVGText::layout
55701        https://bugs.webkit.org/show_bug.cgi?id=130346
55702
55703        Reviewed by Andreas Kling.
55704
55705        Following <http://trac.webkit.org/changeset/163560>, SVG inline elements may be treated as block-
55706        level elements depending on their CSS styles (e.g. display: block). But such elements should always
55707        be treated as inline-level elements.
55708
55709        Partially revert <http://trac.webkit.org/changeset/164368> as it addressed a similar issue for
55710        <tspan> and <tref>. Instead we should implement RenderSVGInline::updateFromStyle() to ensure that
55711        RenderSVGInline and any derived classes (e.g. RenderSVGTSpan) are always treated as inline elements
55712        regardless of their CSS style because the SVG text layout code depends on this assumption as part
55713        of a performance optimization. We may want to revaluate the benefits of this optimization with respect
55714        to code clarity and ensuring the code is less error prone.
55715
55716        Test: svg/text/a-display-block.html
55717              svg/text/tref-display-inherit.html
55718
55719        * css/StyleResolver.cpp:
55720        (WebCore::StyleResolver::adjustRenderStyle): Revert changes from <http://trac.webkit.org/changeset/164368>.
55721        * rendering/RenderInline.h:
55722        * rendering/svg/RenderSVGInline.cpp:
55723        (WebCore::RenderSVGInline::updateFromStyle): Added; ensure that RenderSVGInline and any derived
55724        classes are treated as inline elements because the SVG text layout code depends on this assumption.
55725        * rendering/svg/RenderSVGInline.h:
55726
557272014-03-18  Hans Muller  <hmuller@adobe.com>
55728
55729        [CSS Shapes] shape-outside: ellipse(50% 50% at) causes crash
55730        https://bugs.webkit.org/show_bug.cgi?id=130366
55731
55732        Reviewed by Andreas Kling.
55733
55734        The BasicShape ellipse and circle functions now report a syntax error
55735        if the "at" keyword is not followed by a position.
55736
55737        The existing parsing tests have been updated to include this case.
55738
55739        * css/CSSParser.cpp:
55740        (WebCore::CSSParser::parseBasicShapeCircle):
55741        (WebCore::CSSParser::parseBasicShapeEllipse):
55742
557432014-03-18  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
55744
55745        Removing MediaStreamVector typedef
55746        https://bugs.webkit.org/show_bug.cgi?id=130402
55747
55748        Reviewed by Eric Carlson.
55749
55750        * Modules/mediastream/MediaStream.h:
55751        * Modules/mediastream/RTCPeerConnection.cpp:
55752        (WebCore::RTCPeerConnection::getLocalStreams):
55753        (WebCore::RTCPeerConnection::getRemoteStreams):
55754        (WebCore::RTCPeerConnection::getStreamById):
55755        (WebCore::RTCPeerConnection::hasLocalStreamWithTrackId):
55756        * Modules/mediastream/RTCPeerConnection.h:
55757
557582014-03-18  Commit Queue  <commit-queue@webkit.org>
55759
55760        Unreviewed, rolling out r165815.
55761        https://bugs.webkit.org/show_bug.cgi?id=130410
55762
55763        Broke many VTT tests (Requested by bfulgham on #webkit).
55764
55765        Reverted changeset:
55766
55767        "TextTrackRegion Not Implemented"
55768        https://bugs.webkit.org/show_bug.cgi?id=116546
55769        http://trac.webkit.org/changeset/165815
55770
557712014-03-18  Renata Hodovan  <rhodovan.u-szeged@partner.samsung.com>
55772
55773        Bad cast with toRenderBox in WebCore::RenderView::repaintViewRectangle
55774        https://bugs.webkit.org/show_bug.cgi?id=129104
55775
55776        Reviewed by Simon Fraser.
55777
55778        We should not cast the renderer of a RenderView's owner to RenderBox
55779        unless we are sure it is one.
55780
55781        Test: plugins/crash-invalid-data-reference.html
55782
55783        * rendering/RenderView.cpp:
55784        (WebCore::RenderView::repaintViewRectangle):
55785
557862014-03-18  Andreas Kling  <akling@apple.com>
55787
55788        Micro-optimize element descendant iterator.
55789        <https://webkit.org/b/130384>
55790
55791        Add a slightly more efficient ElementDescendantIterator that keeps a stack
55792        of relevant ancestor siblings instead of walking up the parent chain every
55793        time we run out of children.
55794
55795        Reviewed by Antti Koivisto.
55796
55797        * WebCore.xcodeproj/project.pbxproj:
55798        * dom/ElementDescendantIterator.h: Added.
55799        (WebCore::ElementDescendantIterator::ElementDescendantIterator):
55800        (WebCore::ElementDescendantIterator::operator++):
55801        (WebCore::ElementDescendantConstIterator::ElementDescendantConstIterator):
55802        (WebCore::ElementDescendantConstIterator::operator++):
55803        (WebCore::ElementDescendantIteratorAdapter::ElementDescendantIteratorAdapter):
55804        (WebCore::ElementDescendantIteratorAdapter::begin):
55805        (WebCore::ElementDescendantIteratorAdapter::end):
55806        (WebCore::ElementDescendantConstIteratorAdapter::ElementDescendantConstIteratorAdapter):
55807        (WebCore::ElementDescendantConstIteratorAdapter::begin):
55808        (WebCore::ElementDescendantConstIteratorAdapter::end):
55809        (WebCore::elementDescendants):
55810        * dom/ElementIterator.h:
55811        * dom/SelectorQuery.cpp:
55812        (WebCore::elementsForLocalName):
55813        (WebCore::anyElement):
55814        (WebCore::SelectorDataList::executeSingleTagNameSelectorData):
55815        (WebCore::SelectorDataList::executeSingleClassNameSelectorData):
55816        (WebCore::SelectorDataList::executeSingleSelectorData):
55817        (WebCore::SelectorDataList::executeSingleMultiSelectorData):
55818        (WebCore::SelectorDataList::executeCompiledSimpleSelectorChecker):
55819
558202014-03-18  Antti Koivisto  <antti@apple.com>
55821
55822        Mutating rules returned by getMatchedCSSRules can result in crash
55823        https://bugs.webkit.org/show_bug.cgi?id=130209
55824
55825        Reviewed by Andreas Kling.
55826        
55827        The non-standard getMatchedCSSRules API returns CSSStyleRule objects that don't
55828        have parent stylesheet pointer (as we don't know which sheet the rule originated from).
55829        Mutating the rule via such wrapper can lead to crashes later as we fail to invalidate
55830        the underlying stylesheet.
55831        
55832        Fix by disallowing mutation of style rules that don't have parent sheet pointer. CSSStyleRule
55833        has two mutable properties selectorText and style. The latter gives back CSSStyleDeclaration.
55834        This patch disallows mutations in both cases for CSSStyleRules that don't have parent stylesheet
55835        pointer.
55836        
55837        While it is technically possible to have CSSRules that are legitimately disconnected
55838        from stylesheet (by removing rule from sheet while holding a reference to it) it never
55839        makes sense to mutate such rule as there is no way to do anything with it afterwards.
55840
55841        Tests: fast/css/getMatchedCSSProperties-rule-mutation.html
55842               fast/css/getMatchedCSSRules-crash.html
55843
55844        * css/CSSStyleRule.cpp:
55845        (WebCore::CSSStyleRule::setSelectorText):
55846
55847            Bail out if parent stylesheet is null.
55848
55849        * css/PropertySetCSSStyleDeclaration.cpp:
55850        (WebCore::PropertySetCSSStyleDeclaration::setCssText):
55851        (WebCore::PropertySetCSSStyleDeclaration::setProperty):
55852        (WebCore::PropertySetCSSStyleDeclaration::removeProperty):
55853        (WebCore::PropertySetCSSStyleDeclaration::setPropertyInternal):
55854        
55855            Allow StyleRuleCSSStyleDeclaration subclass cancel the mutation via
55856            boolean return value from willMutate.
55857
55858        (WebCore::StyleRuleCSSStyleDeclaration::willMutate):
55859        
55860            Disallow mutation if the owning CSSStyleRule is null or has null stylesheet.
55861
55862        (WebCore::StyleRuleCSSStyleDeclaration::didMutate):
55863        
55864            We never get here with null rule or stylesheet anymore.
55865
55866        * css/PropertySetCSSStyleDeclaration.h:
55867        (WebCore::PropertySetCSSStyleDeclaration::willMutate):
55868
558692014-03-17  Jeffrey Pfau  <jpfau@apple.com>
55870
55871        <media> elements are not properly moved to new documents' visibility callback lists
55872        https://bugs.webkit.org/show_bug.cgi?id=127711
55873
55874        Reviewed by David Kilzer.
55875
55876        * html/HTMLMediaElement.cpp:
55877        (WebCore::HTMLMediaElement::didMoveToNewDocument):
55878
558792014-03-18  Filip Pizlo  <fpizlo@apple.com>
55880
55881        More FTL enabling.
55882
55883        Rubber stamped by Dan Bernstein and Mark Hahnenberg.
55884
55885        No new tests.
55886
55887        * Configurations/FeatureDefines.xcconfig:
55888
558892014-03-18  Brent Fulgham  <bfulgham@apple.com>
55890
55891        TextTrackRegion Not Implemented
55892        https://bugs.webkit.org/show_bug.cgi?id=116546
55893
55894        Reviewed by Eric Carlson.
55895
55896        Merged from Blink (patch by vcarbune@chromium.org):
55897        https://chromium.googlesource.com/chromium/blink/+/4940f89a087fea5b5ea628e98d0b355d398a9eea
55898        http://crbug.com/25798003
55899
55900        Tests: media/track/regions-webvtt/text-track-region-display.html
55901               media/track/regions-webvtt/text-track-region-dom-layout.html
55902
55903        * html/HTMLMediaElement.cpp:
55904        (WebCore::HTMLMediaElement::parseAttribute):
55905        * html/track/LoadableTextTrack.cpp:
55906        (WebCore::LoadableTextTrack::newRegionsAvailable):
55907        * html/track/TextTrack.cpp:
55908        * html/track/TextTrack.h:
55909        * html/track/TextTrackRegion.cpp:
55910        (WebCore::TextTrackRegion::TextTrackRegion):
55911        (WebCore::TextTrackRegion::appendTextTrackCueBox):
55912        * html/track/TextTrackRegion.h:
55913        * html/track/VTTCue.cpp:
55914        (WebCore::VTTCue::VTTCue):
55915        (WebCore::VTTCue::notifyRegionWhenRemovingDisplayTree):
55916        (WebCore::VTTCue::removeDisplayTree):
55917        * html/track/VTTCue.h:
55918        * html/track/WebVTTParser.cpp:
55919        (WebCore::WebVTTParser::parseBytes):
55920        (WebCore::WebVTTParser::collectMetadataHeader):
55921        * html/track/WebVTTParser.h:
55922
559232014-03-18  Philippe Normand  <pnormand@igalia.com>
55924
55925        [GTK] ResourceLoaderSoup.cpp was added by mistake
55926        https://bugs.webkit.org/show_bug.cgi?id=130396
55927
55928        Reviewed by Carlos Garcia Campos.
55929
55930        This file was committed by mistake in r152778 and is not built by
55931        any port.
55932
55933        * loader/soup/ResourceLoaderSoup.cpp: Removed.
55934
559352014-03-18  Andreas Kling  <akling@apple.com>
55936
55937        Rename ElementDescendantIterator to TypedElementDescendantIterator.
55938        Romper-stubbed by Antti "Latte Lung" Koivisto.
55939
55940        * GNUmakefile.list.am:
55941        * WebCore.vcxproj/WebCore.vcxproj:
55942        * WebCore.vcxproj/WebCore.vcxproj.filters:
55943        * WebCore.xcodeproj/project.pbxproj:
55944        * dom/ElementDescendantIterator.h: Removed.
55945        * dom/ElementIterator.h:
55946        * dom/TypedElementDescendantIterator.h: Added.
55947        (WebCore::TypedElementDescendantIterator<ElementType>::TypedElementDescendantIterator):
55948        (WebCore::TypedElementDescendantIterator<ElementType>::operator):
55949        (WebCore::TypedElementDescendantConstIterator<ElementType>::TypedElementDescendantConstIterator):
55950        (WebCore::TypedElementDescendantConstIterator<ElementType>::operator):
55951        (WebCore::TypedElementDescendantIteratorAdapter<ElementType>::TypedElementDescendantIteratorAdapter):
55952        (WebCore::TypedElementDescendantIteratorAdapter<ElementType>::begin):
55953        (WebCore::TypedElementDescendantIteratorAdapter<ElementType>::end):
55954        (WebCore::TypedElementDescendantIteratorAdapter<ElementType>::beginAt):
55955        (WebCore::TypedElementDescendantIteratorAdapter<ElementType>::from):
55956        (WebCore::TypedElementDescendantIteratorAdapter<ElementType>::first):
55957        (WebCore::TypedElementDescendantIteratorAdapter<ElementType>::last):
55958        (WebCore::TypedElementDescendantConstIteratorAdapter<ElementType>::TypedElementDescendantConstIteratorAdapter):
55959        (WebCore::TypedElementDescendantConstIteratorAdapter<ElementType>::begin):
55960        (WebCore::TypedElementDescendantConstIteratorAdapter<ElementType>::end):
55961        (WebCore::TypedElementDescendantConstIteratorAdapter<ElementType>::beginAt):
55962        (WebCore::TypedElementDescendantConstIteratorAdapter<ElementType>::from):
55963        (WebCore::TypedElementDescendantConstIteratorAdapter<ElementType>::first):
55964        (WebCore::TypedElementDescendantConstIteratorAdapter<ElementType>::last):
55965        (WebCore::descendantsOfType):
55966
559672014-03-18  Ion Rosca  <rosca@adobe.com>
55968
55969        Add blend mode property to dumped information in GraphicsLayer.
55970        https://bugs.webkit.org/show_bug.cgi?id=130331
55971
55972        Reviewed by Simon Fraser.
55973
55974        Functionality is not changed, therefore no new tests added.
55975        I adjusted the affected test results generated with layerTreeAsText.
55976
55977        * platform/graphics/GraphicsLayer.cpp:
55978        (WebCore::GraphicsLayer::dumpProperties):
55979
559802014-03-17  Sergio Villar Senin  <svillar@igalia.com>
55981
55982        webdatabase: Replace DEPRECATED_DEFINE_STATIC_LOCAL by static NeverDestroyed<T>
55983        https://bugs.webkit.org/show_bug.cgi?id=130347
55984
55985        Reviewed by Darin Adler.
55986
55987        * Modules/webdatabase/DatabaseTracker.cpp:
55988        (WebCore::DatabaseTracker::openDatabaseMutex):
55989        (WebCore::notificationMutex):
55990        (WebCore::notificationQueue):
55991
559922014-03-17  Jer Noble  <jer.noble@apple.com>
55993
55994        Add RemoteCommandListener support to MediaSessionManager.
55995        https://bugs.webkit.org/show_bug.cgi?id=130354
55996
55997        Reviewed by Eric Carlson.
55998
55999        Listen for remote commands in MediaSessionManager.
56000
56001        * platform/audio/MediaSessionManager.cpp:
56002        (WebCore::MediaSessionManager::addSession):
56003        (WebCore::MediaSessionManager::removeSession):
56004        * platform/audio/MediaSessionManager.h:
56005
56006        Add RemoteCommandListener to the project files:
56007        * CMakeLists.txt:
56008        * GNUmakefile.list.am:
56009        * WebCore.vcxproj/WebCore.vcxproj:
56010        * WebCore.vcxproj/WebCore.vcxproj.filters:
56011
560122014-03-17  Ryosuke Niwa  <rniwa@webkit.org>
56013
56014        Rewrite WebHTMLConverter::_elementHasOwnBackgroundColor in C++
56015        https://bugs.webkit.org/show_bug.cgi?id=130291
56016
56017        Reviewed by Andreas Kling.
56018
56019        Extracted HTMLConverterCaches::elementHasOwnBackgroundColor.
56020
56021        * platform/mac/HTMLConverter.mm:
56022        (HTMLConverterCaches::elementHasOwnBackgroundColor):
56023        (-[WebHTMLConverter _elementHasOwnBackgroundColor:]):
56024
560252014-03-17  Ryosuke Niwa  <rniwa@webkit.org>
56026
56027        Rewrite WebHTMLConverter::_elementIsBlockLevel in C++
56028        https://bugs.webkit.org/show_bug.cgi?id=130287
56029
56030        Reviewed by Andreas Kling.
56031
56032        Rewrote _elementIsBlockLevel as HTMLConverterCaches::isBlockElement. Also removed the code to update
56033        _elementIsBlockLevel in _traverseNode as computing the value of _elementIsBlockLevel is now fast.
56034
56035        * platform/mac/HTMLConverter.h:
56036        * platform/mac/HTMLConverter.mm:
56037        (HTMLConverterCaches::isBlockElement):
56038        (-[WebHTMLConverter _elementIsBlockLevel:]):
56039        (-[WebHTMLConverter _traverseNode:depth:embedded:]):
56040        (-[WebHTMLConverter dealloc]):
56041        (-[WebHTMLConverter init]):
56042
560432014-03-17  Ryosuke Niwa  <rniwa@webkit.org>
56044
56045        Rewrite WebHTMLConverter::_getComputedFloat in C++
56046        https://bugs.webkit.org/show_bug.cgi?id=130284
56047
56048        Reviewed by Andreas Kling.
56049
56050        Rewrote _getComputedFloat as HTMLConverterCaches::floatPropertyValueForNode.
56051
56052        * platform/mac/HTMLConverter.h:
56053        * platform/mac/HTMLConverter.mm:
56054        (HTMLConverterCaches::floatPropertyValueForNode):
56055        (-[WebHTMLConverter _getFloat:forNode:property:]): Now that computing the float value is fast, we don't need to
56056        store it in the cache.
56057        (-[WebHTMLConverter dealloc]):
56058        (-[WebHTMLConverter init]):
56059
560602014-03-16  Andreas Kling  <akling@apple.com>
56061
56062        HTMLInputElement::defaultEventHandler() shouldn't force style updates.
56063        <https://webkit.org/b/130303>
56064
56065        Move the updateStyleIfNeeded() call down to TextFieldInputType instead
56066        of doing it for every HTMLInputEvent.
56067
56068        There might be a better way to do this; we only want to know about this
56069        specific element's renderer, and don't need the rest of the tree.
56070        This is still an easy hack to avoid a lot of unnecessary work.
56071
56072        Reviewed by Anders Carlsson.
56073
56074        * html/HTMLInputElement.cpp:
56075        (WebCore::HTMLInputElement::defaultEventHandler):
56076        * html/TextFieldInputType.cpp:
56077        (WebCore::TextFieldInputType::forwardEvent):
56078
560792014-03-17  Brent Fulgham  <bfulgham@apple.com>
56080
56081        [WebVTT] Extending WebVTT Rendering with Regions
56082        https://bugs.webkit.org/show_bug.cgi?id=109822
56083
56084        Reviewed by Eric Carlson.
56085
56086        Merged from Blink (patch by Victor Carbune vcarbune@chromium.org):
56087        https://chromium.googlesource.com/chromium/blink/+/0cdebc1d76d41bfcb9c4b022e54a4fbff132225d
56088
56089        No new tests, as this feature is not active in default builds. New tests will be added
56090        in an upcoming bug.
56091
56092        * css/mediaControls.css:
56093        (video::-webkit-media-text-track-region):
56094        (video::-webkit-media-text-track-region-container):
56095        (video::-webkit-media-text-track-region-container.scrolling):
56096        (video::-webkit-media-text-track-display):
56097        * html/shadow/MediaControlElements.cpp:
56098        (WebCore::MediaControlTextTrackContainerElement::updateDisplay):
56099        * html/track/TextTrack.cpp:
56100        (WebCore::TextTrack::~TextTrack):
56101        * html/track/TextTrackCue.cpp:
56102        * html/track/TextTrackRegion.cpp:
56103        (WebCore::TextTrackRegion::TextTrackRegion):
56104        (WebCore::TextTrackRegion::textTrackCueContainerScrollingClass):
56105        (WebCore::TextTrackRegion::textTrackCueContainerShadowPseudoId):
56106        (WebCore::TextTrackRegion::textTrackRegionShadowPseudoId):
56107        (WebCore::TextTrackRegion::appendTextTrackCueBox):
56108        (WebCore::TextTrackRegion::displayLastTextTrackCueBox):
56109        (WebCore::TextTrackRegion::willRemoveTextTrackCueBox):
56110        (WebCore::TextTrackRegion::getDisplayTree):
56111        (WebCore::TextTrackRegion::prepareRegionDisplayTree):
56112        (WebCore::TextTrackRegion::startTimer):
56113        (WebCore::TextTrackRegion::stopTimer):
56114        (WebCore::TextTrackRegion::scrollTimerFired):
56115        * html/track/TextTrackRegion.h:
56116        (WebCore::TextTrackRegion::create):
56117        (WebCore::TextTrackRegion::isScrollingRegion):
56118        (WebCore::TextTrackRegion::ownerDocument):
56119        * html/track/TextTrackRegion.idl:
56120        * html/track/TextTrackRegionList.cpp:
56121        (WebCore::TextTrackRegionList::getRegionById):
56122        * html/track/VTTCue.cpp:
56123        (WebCore::VTTCueBox::applyCSSProperties):
56124        (WebCore::VTTCue::~VTTCue):
56125        (WebCore::VTTCue::setIsActive):
56126        (WebCore::VTTCue::removeDisplayTree):
56127        * html/track/WebVTTParser.cpp:
56128        (WebCore::WebVTTParser::createNewRegion):
56129        * rendering/RenderVTTCue.cpp:
56130        (WebCore::RenderVTTCue::layout):
56131
561322014-03-17  Brendan Long  <b.long@cablelabs.com>
56133
56134        [GStreamer] human readable language code for tracks
56135        https://bugs.webkit.org/show_bug.cgi?id=124514
56136
56137        Reviewed by Martin Robinson.
56138
56139        * PlatformEfl.cmake: Add GSTREAMER_TAG_INCLUDE_DIRS and GSTREAMER_TAG_LIBRARIES.
56140        * PlatformGTK.cmake: Same.
56141        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
56142        (WebCore::TrackPrivateBaseGStreamer::getLanguageCode): Run language codes though gst_tag_get_language_code_iso_639_1() to make sure they're valid.
56143        (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfTagsChanged): Use getLanguageCode() for languages instead of just getTag().
56144
561452014-03-17  Ryosuke Niwa  <rniwa@webkit.org>
56146
56147        [Mac] Rewrite WebHTMLConverter::_computedStringForNode in C++
56148        https://bugs.webkit.org/show_bug.cgi?id=130274
56149
56150        Reviewed by Andreas Kling.
56151
56152        Rewrote WebHTMLConverter::_computedStringForNode as HTMLConverterCaches::propertyValueForNode.
56153
56154        * platform/mac/HTMLConverter.h: Removed unused caches.
56155        * platform/mac/HTMLConverter.mm:
56156        (HTMLConverterCaches::computedStylePropertyForElement): Added use const String& instead of String& on property name.
56157        (HTMLConverterCaches::inlineStylePropertyForElement): Ditto.
56158        (HTMLConverterCaches::propertyValueForNode): Renamed and rewritten from _computedStringForNode.
56159        (-[WebHTMLConverter _stringForNode:property:]): Simply return the computed value instead of storing it in the cache
56160        now that the computing the value is fast.
56161        (-[WebHTMLConverter dealloc]):
56162        (-[WebHTMLConverter init]):
56163
561642014-03-17  Andreas Kling  <akling@apple.com>
56165
56166        Remove unnecessary JSC::Handle null checks in bindings code.
56167        <https://webkit.org/b/130356>
56168
56169        Use Handle::slot() directly instead of going through Handle::get().
56170        This avoids null checking the HandleSlot, which isn't necessary here
56171        anyway, and the code already assumes it'll never be null.
56172
56173        Reviewed by Gavin Barraclough.
56174
56175        * bindings/js/JSCSSRuleListCustom.cpp:
56176        (WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
56177        * bindings/js/JSCSSValueCustom.cpp:
56178        (WebCore::JSCSSValueOwner::isReachableFromOpaqueRoots):
56179        (WebCore::JSCSSValueOwner::finalize):
56180        * bindings/js/JSMutationObserverCustom.cpp:
56181        (WebCore::JSMutationObserverOwner::isReachableFromOpaqueRoots):
56182        * bindings/js/JSNodeCustom.cpp:
56183        (WebCore::JSNodeOwner::isReachableFromOpaqueRoots):
56184        * bindings/js/JSNodeListCustom.cpp:
56185        (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
56186        * bindings/js/JSTextTrackCueCustom.cpp:
56187        (WebCore::JSTextTrackCueOwner::isReachableFromOpaqueRoots):
56188        * bindings/js/WebCoreTypedArrayController.cpp:
56189        (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):
56190        (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::finalize):
56191        * bindings/scripts/CodeGeneratorJS.pm:
56192        (GenerateImplementation):
56193        * bridge/runtime_root.cpp:
56194        (JSC::Bindings::RootObject::finalize):
56195
561962014-03-17  Krzysztof Czech  <k.czech@samsung.com>
56197
56198        AX: Reducing some code by using helper function ariaElementsFromAttribute
56199        https://bugs.webkit.org/show_bug.cgi?id=130344
56200
56201        Reviewed by Chris Fleizach.
56202
56203        Change visibility of ariaElementsFromAttribute function from private to protected
56204        so that other classes that derives from AccessibilityRenderObject can use it.
56205
56206        No new tests. No behaviour change.
56207
56208        * accessibility/AccessibilityRenderObject.h:
56209        * accessibility/AccessibilityTableCell.cpp:
56210        (WebCore::AccessibilityTableCell::columnHeaders):
56211
562122014-03-16  Brent Fulgham  <bfulgham@apple.com>
56213
56214        Provide preference to enable additional AVFoundation options
56215        https://bugs.webkit.org/show_bug.cgi?id=130275
56216
56217        Reviewed by Eric Carlson.
56218
56219        * html/HTMLMediaElement.cpp:
56220        (WebCore::HTMLMediaElement::doesHaveAttribute): Added.
56221        * html/HTMLMediaElement.h:
56222        * page/Settings.in: Add new attribute.
56223        * platform/graphics/MediaPlayer.cpp:
56224        (WebCore::MediaPlayer::doesHaveAttribute): Added stub to call private player object's
56225        implementation of doesHaveAttribute.
56226        * platform/graphics/MediaPlayer.h:
56227        (WebCore::MediaPlayerClient::doesHaveAttribute):
56228        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
56229        (WebCore::MediaPlayerPrivateAVFoundationCF::AVFWrapper::createAssetForURL): Check the <media> object,
56230        and notify AVFoundationCF to use URI option if relevant.
56231        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
56232        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Check the <media> object,
56233        and notify AVFoundation to use URI option if relevant.
56234
562352014-03-17  Jer Noble  <jer.noble@apple.com>
56236
56237        [EME] Add NULL protections in SourceBuffer and MediaSource.
56238        https://bugs.webkit.org/show_bug.cgi?id=130266
56239
56240        Reviewed by Eric Carlson.
56241
56242        Add NULL checks in places which may be called after a SourceBuffer has been removed:
56243
56244        * Modules/mediasource/MediaSource.cpp:
56245        (WebCore::MediaSource::monitorSourceBuffers): Protect against a SourceBuffer being removed
56246            (and thus activeSourceBuffers being empty) when monitoring source buffer state.
56247        * Modules/mediasource/SourceBuffer.cpp:
56248        (WebCore::SourceBuffer::appendBufferTimerFired): Protect against SourceBuffer being removed.
56249        (WebCore::SourceBuffer::videoTracks): Ditto.
56250        (WebCore::SourceBuffer::audioTracks): Ditto.
56251        (WebCore::SourceBuffer::textTracks): Ditto.
56252        (WebCore::SourceBuffer::setActive): Ditto.
56253        (WebCore::SourceBuffer::sourceBufferPrivateDidEndStream): Ditto.
56254        (WebCore::SourceBuffer::hasCurrentTime): Ditto.
56255        (WebCore::SourceBuffer::canPlayThrough): Ditto.
56256        (WebCore::SourceBuffer::hasFutureTime): Ditto, and check for an empty buffered ranges.
56257
562582014-03-17  Tim Horton  <timothy_horton@apple.com>
56259
56260        WKThumbnailView should support snapshots
56261        https://bugs.webkit.org/show_bug.cgi?id=130335
56262        <rdar://problem/16255139>
56263
56264        Reviewed by Simon Fraser.
56265
56266        * WebCore.exp.in:
56267
562682014-01-29  Sergio Villar Senin  <svillar@igalia.com>
56269
56270        [CSS Grid Layout] getComputedStyle() not using author's order when showing named grid lines
56271        https://bugs.webkit.org/show_bug.cgi?id=127837
56272
56273        Reviewed by David Hyatt.
56274
56275        Added a couple of new Vectors to store the names of the grid lines
56276        respecting their order. They will be used to get the right outcome
56277        for getComputedStyle().
56278
56279        * css/CSSComputedStyleDeclaration.cpp:
56280        (WebCore::addValuesForNamedGridLinesAtIndex):
56281        (WebCore::valueForGridTrackList):
56282        * css/StyleResolver.cpp:
56283        (WebCore::createGridTrackList):
56284        (WebCore::StyleResolver::applyProperty):
56285        * rendering/style/RenderStyle.h:
56286        * rendering/style/StyleGridData.cpp:
56287        (WebCore::StyleGridData::StyleGridData):
56288        * rendering/style/StyleGridData.h:
56289        (WebCore::StyleGridData::operator==):
56290
562912014-03-17  Zsolt Borbely  <borbezs@inf.u-szeged.hu>
56292
56293        Fix the !ENABLE(PROMISES) build
56294        https://bugs.webkit.org/show_bug.cgi?id=130328
56295
56296        Reviewed by Darin Adler.
56297
56298        Add missing ENABLE(PROMISES) guards.
56299
56300        * bindings/js/JSDOMPromise.cpp:
56301        * bindings/js/JSDOMPromise.h:
56302
563032014-03-17  Gurpreet Kaur  <k.gurpreet@samsung.com>
56304
56305        Safari should not render a cell if the <td> is empty
56306        https://bugs.webkit.org/show_bug.cgi?id=15273
56307
56308        Reviewed by Darin Adler.
56309
56310        When table cell has no children and the doctype is not present or not
56311        correct the border for that cell should not be drawn. Firefox also
56312        follows the same behaviour hence making the changes to make it similiar
56313        to Firefox behaviour.
56314
56315        Tests: fast/table/table-cell-border-doctype.html
56316               fast/table/table-cell-border-no-doctype.html
56317
56318        * rendering/RenderTableCell.cpp:
56319        (WebCore::RenderTableCell::paintBoxDecorations):
56320        Added condition for not drawing the border when table cell has no child
56321        and doctype.
56322
56323
563242014-03-17  Frédéric Wang  <fred.wang@free.fr>
56325
56326        Fix handling of <annotation> in MathMLTextElement.
56327        https://bugs.webkit.org/show_bug.cgi?id=124128.
56328
56329        Reviewed by Darin Adler.
56330
56331        No new tests.
56332
56333        * mathml/MathMLTextElement.cpp:
56334        (WebCore::MathMLTextElement::createElementRenderer): do not create the special RenderMathMLToken for the <annotation> tag.
56335        (WebCore::MathMLTextElement::childShouldCreateRenderer): only allow text inside <annotation>.
56336
563372014-03-17  Martin Robinson  <mrobinson@igalia.com>
56338
56339        [GTK][CMake] Credential storage is not enabled
56340        https://bugs.webkit.org/show_bug.cgi?id=130149
56341
56342        Reviewed by Philippe Normand.
56343
56344        * PlatformGTK.cmake: Add the libsecret include directories and link line to the build.
56345
563462014-03-17  Zan Dobersek  <zdobersek@igalia.com>
56347
56348        Unreviewed.
56349
56350        Addressing reviewing comments by Darin in bug #130310 that I forgot
56351        to address before landing the changes in r165732.
56352        https://bugs.webkit.org/show_bug.cgi?id=130310
56353
56354        * rendering/InlineTextBox.cpp:
56355        * rendering/RenderLayer.cpp:
56356        * rendering/RenderObject.cpp:
56357
563582014-03-17  Jessie Berlin  <jberlin@apple.com>
56359
56360        Speculative build fix for ENABLE(TELEPHONE_NUMBER_DETECTION) after r165724.
56361
56362        * html/parser/HTMLTreeBuilder.cpp:
56363        (WebCore::HTMLTreeBuilder::linkifyPhoneNumbers):
56364
563652014-03-17  Zan Dobersek  <zdobersek@igalia.com>
56366
56367        Only supplement Page with UserMediaController once
56368        https://bugs.webkit.org/show_bug.cgi?id=130311
56369
56370        Reviewed by Darin Adler.
56371
56372        Don't supplement the Page with an UserMediaController object if that Page was
56373        already supplemented with one. This avoids triggering an assertion in
56374        Supplementable::provideSupplement() that ensures no supplement with the same key
56375        exists yet. The cause of this is calling provideUserMediaTo() in the Internals
56376        constructor that's using the same Page for two subsequent tests.
56377
56378        * Modules/mediastream/UserMediaController.cpp:
56379        (WebCore::provideUserMediaTo):
56380
563812014-03-17  Zan Dobersek  <zdobersek@igalia.com>
56382
56383        Explicitly include cstdio header for debug builds in InlineTextBox, RenderLayer, RenderObject
56384        https://bugs.webkit.org/show_bug.cgi?id=130310
56385
56386        Reviewed by Darin Adler.
56387
56388        Building the GTK port with Clang through CMake falls into a configuration where
56389        the cstdio header is not indirectly included in InlineTextBox, RenderLayer and
56390        RenderObject source files. fprintf() is required for helper functions that print
56391        out helpful debugging information in debug builds, so the cstdio header should
56392        be included explicitly in that case.
56393
56394        * rendering/InlineTextBox.cpp:
56395        * rendering/RenderLayer.cpp:
56396        * rendering/RenderObject.cpp:
56397
563982014-03-17  Carlos Garcia Campos  <cgarcia@igalia.com>
56399
56400        [GTK] Cleanup WebKitDOMObject
56401        https://bugs.webkit.org/show_bug.cgi?id=130246
56402
56403        Reviewed by Martin Robinson.
56404
56405        Remove unneeded getter and fix coding style.
56406
56407        * bindings/gobject/WebKitDOMObject.cpp:
56408        (webkitDOMObjectSetProperty):
56409        (webkit_dom_object_class_init):
56410
564112014-03-17  Darin Adler  <darin@apple.com>
56412
56413        Stop using deprecatedCharacters in HTMLTreeBuilder
56414        https://bugs.webkit.org/show_bug.cgi?id=130323
56415
56416        Reviewed by Andreas Kling.
56417
56418        Keeping this separate from other patches because of concern that this could affect
56419        page load performance.
56420
56421        * html/parser/HTMLTreeBuilder.cpp:
56422        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::ExternalCharacterTokenBuffer):
56423        Use a StringView instead of a character pointer.
56424        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::isEmpty): Ditto.
56425        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::skipAtMostOneLeadingNewline):
56426        Ditto.
56427        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::takeRemaining): Ditto.
56428        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::giveRemainingTo): Ditto.
56429        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::takeRemainingWhitespace): Ditto.
56430        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::skipLeading): Ditto.
56431        (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::takeLeading): Ditto.
56432        (WebCore::HTMLTreeBuilder::linkifyPhoneNumbers): Use StringView::upconvertedCharacters.
56433
564342014-03-17  Jinwoo Song  <jinwoo7.song@samsung.com>
56435
56436        Make some Module class constructors return PassRef.
56437        https://bugs.webkit.org/show_bug.cgi?id=130282
56438
56439        Reviewed by Andreas Kling.
56440
56441        Make the constructor helpers for the following classes return PassRef
56442        instead of PassRefPtr since they will never return null.
56443         - GamepadList
56444         - Geolocation
56445         - NavigatorContentUtils
56446         - NetworkInfoConnection
56447         - Notification
56448         - NotificationCenter
56449         - DeviceProximityEvent
56450
56451        * Modules/gamepad/GamepadList.h:
56452        (WebCore::GamepadList::create):
56453        * Modules/geolocation/Geolocation.cpp:
56454        (WebCore::Geolocation::create):
56455        * Modules/geolocation/Geolocation.h:
56456        (WebCore::Geolocation::GeoNotifier::create):
56457        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
56458        (WebCore::NavigatorContentUtils::create):
56459        * Modules/navigatorcontentutils/NavigatorContentUtils.h:
56460        * Modules/networkinfo/NetworkInfoConnection.cpp:
56461        (WebCore::NetworkInfoConnection::create):
56462        * Modules/networkinfo/NetworkInfoConnection.h:
56463        * Modules/notifications/Notification.cpp:
56464        (WebCore::Notification::create):
56465        * Modules/notifications/Notification.h:
56466        * Modules/notifications/NotificationCenter.cpp:
56467        (WebCore::NotificationCenter::create):
56468        * Modules/notifications/NotificationCenter.h:
56469        * Modules/proximity/DeviceProximityEvent.h:
56470        (WebCore::DeviceProximityEvent::create):
56471
564722014-03-16  Mihnea Ovidenie  <mihnea@adobe.com>
56473
56474        [CSSRegions]Do not compute region range for a box unless the parent has one
56475        https://bugs.webkit.org/show_bug.cgi?id=130249
56476
56477        Reviewed by Andrei Bucur.
56478
56479        If the containing block does not have a region range computed, do not attempt to compute
56480        a region range for a child. In such cases, the range computation for a child can lead to
56481        a result that is wrong, possibly leading to an incorrect clipping.
56482
56483        Test: fast/regions/inline-block-flowed-in-regions.html
56484
56485        * rendering/RenderBlock.cpp:
56486        (WebCore::canComputeRegionRangeForBox):
56487        (WebCore::RenderBlock::computeRegionRangeForBoxChild):
56488        (WebCore::RenderBlock::estimateRegionRangeForBoxChild):
56489        (WebCore::RenderBlock::updateRegionRangeForBoxChild):
56490        * rendering/RenderFlowThread.h:
56491
564922014-03-16  Andreas Kling  <akling@apple.com>
56493
56494        CSSValueList should assert that no null values are added to it.
56495        <https://webkit.org/b/130315>
56496
56497        Add assertions in CSSValueList's append() and prepend() that we are
56498        not adding a null value. This caught a single place in CSSParser
56499        that was appending an alread-released RefPtr to a CSSValueList.
56500        That list was eventually discarded anyway (due to "foundClip" now
56501        being true), so the fix is simply to remove the adding.
56502
56503        Eventually we should use Ref and PassRef all over for CSSValueList,
56504        this is just a first step on the way.
56505
56506        Reviewed by Darin Adler.
56507
56508        * css/CSSParser.cpp:
56509        (WebCore::CSSParser::parseFillShorthand):
56510        * css/CSSValueList.h:
56511        (WebCore::CSSValueList::append):
56512        (WebCore::CSSValueList::prepend):
56513
565142014-03-16  Praveen R Jadhav  <praveen.j@samsung.com>
56515
56516        AudioBufferSourceNode stop attribute shouldn't throw exception in finished state.
56517        https://bugs.webkit.org/show_bug.cgi?id=130000.
56518
56519        Reviewed by Jer Noble.
56520
56521        AudioBufferSourceNode may go to FINISHED_STATE even before "stop" method is called 
56522        as silence rendered after audio data is played out when its not looping.
56523        A call to "stop" method after this shouldn't throw exception.
56524
56525        * Modules/webaudio/AudioScheduledSourceNode.cpp:
56526        (WebCore::AudioScheduledSourceNode::stop):
56527
565282014-03-16  Brian Burg  <bburg@apple.com>
56529
56530        Web Inspector: generated backend commands should reflect build system ENABLE settings
56531        https://bugs.webkit.org/show_bug.cgi?id=130111
56532
56533        Reviewed by Timothy Hatcher.
56534
56535        Add guards for conditional inspector domains.
56536
56537        For Makefile-based build systems, force regeneration of the
56538        combined file if the list of domains has changed.
56539
56540        Combine only the Inspector domains listed in INSPECTOR_DOMAINS,
56541        instead of globbing any .json file.
56542
56543        * CMakeLists.txt:
56544        * DerivedSources.make:
56545        * GNUmakefile.am:
56546
565472014-03-16  David Kilzer  <ddkilzer@apple.com>
56548
56549        Follow-up: Double values passed to fabsf() in maxScaleFromTransform()
56550        <http://webkit.org/b/130297>
56551
56552        Reviewed by Darin Adler.
56553
56554        * platform/graphics/ca/GraphicsLayerCA.cpp:
56555        (WebCore::maxScaleFromTransform): Use narrowPrecisionToFloat()
56556        instead of static_cast<float>().
56557
565582014-03-16  Andreas Kling  <akling@apple.com>
56559
56560        ScriptExecutionContext::vm() should return a reference.
56561        <https://webkit.org/b/129611>
56562
56563        Every ScriptExecutionContext has a VM, so this can never return null.
56564        Made WorkerScriptController::vm() return a reference as well, since
56565        that was needed for this change.
56566
56567        Reviewed by Geoffrey Garen.
56568
56569        * bindings/js/WorkerScriptController.h:
56570        (WebCore::WorkerScriptController::vm):
56571        * bindings/js/WorkerScriptDebugServer.cpp:
56572        (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
56573        * css/ElementRuleCollector.cpp:
56574        (WebCore::ElementRuleCollector::ruleMatches):
56575        * dom/ScriptExecutionContext.cpp:
56576        (WebCore::ScriptExecutionContext::vm):
56577        * dom/ScriptExecutionContext.h:
56578        * dom/SelectorQuery.cpp:
56579        (WebCore::SelectorDataList::execute):
56580        * html/HTMLCanvasElement.cpp:
56581        (WebCore::HTMLCanvasElement::createImageBuffer):
56582        * xml/XMLHttpRequest.cpp:
56583        (WebCore::XMLHttpRequest::dropProtection):
56584        * testing/Internals.cpp:
56585        (WebCore::Internals::parserMetaData):
56586
565872014-03-16  Zan Dobersek  <zdobersek@igalia.com>
56588
56589        Remove OwnPtr.h, PassOwnPtr.h header inclusions in Source/WebCore/html/parser/ code
56590        https://bugs.webkit.org/show_bug.cgi?id=129667
56591
56592        Reviewed by Anders Carlsson.
56593
56594        Remove unnecessary inclusions of the OwnPtr.h and PassOwnPtr.h headers
56595        in the code under Source/WebCore/html/parser/.
56596
56597        * html/parser/HTMLParserScheduler.h:
56598        * html/parser/HTMLToken.h:
56599        * html/parser/HTMLTreeBuilder.h:
56600        * html/parser/XSSAuditor.h:
56601        * html/parser/XSSAuditorDelegate.h:
56602
566032014-03-16  Darin Adler  <darin@apple.com>
56604
56605        Remove uses of "cat" in DerivedSources.make outside platform-specific rules
56606        https://bugs.webkit.org/show_bug.cgi?id=130307
56607
56608        Reviewed by Anders Carlsson.
56609
56610        * DerivedSources.make: Use "perl -pe ''" instead of "cat".
56611
566122014-03-16  Brian Burg  <bburg@apple.com>
56613
56614        Web Inspector: vended backend commands file should be generated as part of the build
56615        https://bugs.webkit.org/show_bug.cgi?id=130110
56616
56617        Reviewed by Timothy Hatcher.
56618
56619        * WebCore.xcodeproj/project.pbxproj: Copy InspectorWebBackendCommands.js to the
56620        private headers directory.
56621
566222014-03-16  Frédéric Wang  <fred.wang@free.fr>
56623
56624        [regression] foreign content not displayed in MathML
56625        <https://webkit.org/b/124128>
56626
56627        Reviewed by Chris Fleizach.
56628
56629        This restores foreign content in <mtext>, <mn> and <mi> elements, but only when it is "phrasing content" as defined per the HTML5 specification. Other token elements are not handled here. This change makes mspace-units.html work again on Linux.
56630
56631        Tests: mathml/presentation/foreign-mi-dynamic.html
56632               mathml/presentation/foreign-mi.html
56633               mathml/presentation/foreign-mn.html
56634               mathml/presentation/foreign-mtext-rejected.html
56635               mathml/presentation/foreign-mtext.html
56636
56637        * mathml/MathMLTextElement.cpp:
56638        (WebCore::MathMLTextElement::createElementRenderer): create a RenderMathMLToken for mn, ms and mtext.
56639        (WebCore::isPhrasingContent): helper function to check phrasing content, as defined by the HTML spec.
56640        (WebCore::MathMLTextElement::childShouldCreateRenderer): <mi>, <mn>, <mtext> and, <ms> now accepts phrasing content.
56641        * rendering/mathml/RenderMathMLToken.cpp:
56642        (WebCore::RenderMathMLToken::RenderMathMLToken):
56643        (WebCore::RenderMathMLToken::updateTokenContent): initialize the m_containsElement boolean when updating the token content.
56644        (WebCore::RenderMathMLToken::updateStyle): move <mi> specific handling in its own section and only apply the single-char rule when it does not contain elements.
56645        * rendering/mathml/RenderMathMLToken.h: add an m_containsElement boolean to handle token element specifically.
56646
566472014-03-16  David Kilzer  <ddkilzer@apple.com>
56648
56649        PlatformTimeRanges::nearest() truncates closestDelta values from double to float
56650        <http://webkit.org/b/130298>
56651
56652        Reviewed by Darin Adler.
56653
56654        Fixes the following build failures using trunk clang:
56655
56656            WebCore/platform/graphics/PlatformTimeRanges.cpp:210:28: error: absolute value function 'fabsf' given an argument of type 'double' but has parameter of type 'float' which may cause truncation of value [-Werror,-Wabsolute-value]
56657                        closestDelta = fabsf(startTime - time);
56658                                       ^
56659            WebCore/platform/graphics/PlatformTimeRanges.cpp:210:28: note: use function 'fabs' instead
56660                        closestDelta = fabsf(startTime - time);
56661                                       ^~~~~
56662                                       fabs
56663            WebCore/platform/graphics/PlatformTimeRanges.cpp:214:28: error: absolute value function 'fabsf' given an argument of type 'double' but has parameter of type 'float' which may cause truncation of value [-Werror,-Wabsolute-value]
56664                        closestDelta = fabsf(endTime - time);
56665                                       ^
56666            WebCore/platform/graphics/PlatformTimeRanges.cpp:214:28: note: use function 'fabs' instead
56667                        closestDelta = fabsf(endTime - time);
56668                                       ^~~~~
56669                                       fabs
56670
56671        * platform/graphics/PlatformTimeRanges.cpp:
56672        (WebCore::PlatformTimeRanges::nearest): Extract start and end
56673        time deltas into local variables so they don't have to be
56674        computed twice, using fabs() instead of fabsf().
56675
566762014-03-16  Darin Adler  <darin@apple.com>
56677
56678        Optimize hasTagName when called on an HTMLElement
56679        https://bugs.webkit.org/show_bug.cgi?id=130090
56680
56681        Reviewed by Antti Koivisto.
56682
56683        Added new hasTagName functions that have the efficiency of hasLocalName.
56684        but are safe.
56685
56686        Now we can always use hasTagName, and we'll get a compile time error if
56687        we try to use an SVG tag name with an HTML element. All call sites that
56688        use the more specific tag name types are more efficient, and call sites
56689        that have a specific pointer type will get even more efficient checking
56690        that is exactly what we used to get by calling hasLocalName.
56691
56692        * accessibility/AccessibilityObject.cpp:
56693        (WebCore::AccessibilityObject::hasTagName): Cast explicitly to Element
56694        since Node::hasTagName no longer works on a general QualifiedName.
56695        * accessibility/AccessibilityRenderObject.cpp:
56696        (WebCore::AccessibilityRenderObject::isDescendantOfElementType): Use
56697        more specific type, RenderElement, so we can call hasTagName on Element
56698        instead of Node; eliminates an unnecessary branch.
56699
56700        * accessibility/AccessibilityTableColumn.cpp: Added now-needed include.
56701        * accessibility/atk/AccessibilityObjectAtk.cpp: Ditto.
56702
56703        * dom/DocumentStyleSheetCollection.cpp:
56704        (WebCore::DocumentStyleSheetCollection::collectActiveStyleSheets): Use
56705        new for loop and full words for variable names. Also use nullptr instead
56706        of 0. Call toHTMLElement and toSVGElement in code that checks hasTagName
56707        since it's already checking isHTMLElement and isSVGElement.
56708
56709        * dom/Element.cpp:
56710        (WebCore::attrNodeListMap): Use NeverDestroyed and put the vectors into
56711        the map rather than putting pointers to a vector into the map.
56712        (WebCore::attrNodeListForElement): Take a reference rather than a pointer,
56713        and update for the change above.
56714        (WebCore::ensureAttrNodeListForElement): Ditto.
56715        (WebCore::removeAttrNodeListForElement): Ditto.
56716        (WebCore::findAttrNodeInList): Ditto.
56717        (WebCore::Element::isFocusable): Use lineageOfType<HTMLCanvasElement>
56718        to fine the canvas rather than a hand-written loop.
56719        (WebCore::Element::attrNodeList): Update for above changes.
56720        (WebCore::Element::setAttributeNode): Ditto.
56721        (WebCore::Element::attrIfExists): Ditto.
56722        (WebCore::Element::ensureAttr): Ditto.
56723        (WebCore::Element::detachAttrNodeFromElementWithValue): Ditto.
56724        (WebCore::Element::detachAllAttrNodesFromElement): Ditto.
56725
56726        * dom/Element.h: Removed the overload of hasLocalName that takes a
56727        QualifiedName and ignores the non-local-name parts of it. Callers should
56728        use hasTagName instead, now that it's optimized appropriately. Added
56729        overloads of hasTagName for all the specific qualified name types. It's
56730        more efficient to use the Node versions of these functions rather than
56731        using QualifiedName::matches to do the check. Removed the hasTagName and
56732        hasLocalName functions from the Node class; the only convenience functions
56733        needed in Node are the specific checks for tags from HTML, MathML, and SVG,
56734        not the general purpose ones.
56735
56736        * dom/Node.h: Removed hasLocalName and replaced the single hasTagName
56737        that takes a QualifiedName with three faster ones that take HTML, MathML,
56738        and SVG qualified names instead. Also updated to use nullptr instead of 0.
56739
56740        * dom/PositionIterator.cpp: Added now-needed include.
56741        * dom/Text.cpp: Ditto.
56742
56743        * dom/make_names.pl:
56744        (printHeaderHead): Renamed an argument for clarity and added a definitions
56745        argument, which is where we insert the classes derived from QualifiedName.
56746        (printCppHead): Renamed an argument for clarity.
56747        (printTypeHelpers): Use hasTagName rather than hasLocalName, since the
56748        former is now optimized to be the same as what the latter was.
56749        (printNamesHeaderFile): Define a class derived from QualifiedName that can
56750        be used at compile time to avoid having to check the namespace.
56751        (printNamesCppFile): Use the new more-specific type as needed.
56752
56753        * editing/ApplyStyleCommand.cpp:
56754        (WebCore::isLegacyAppleStyleSpan): Use hasTagName instead of hasLocalName,
56755        and references instead of pointers.
56756        (WebCore::ApplyStyleCommand::ApplyStyleCommand): Removed uneeded explicit
56757        construction of a smart pointer.
56758        (WebCore::ApplyStyleCommand::shouldApplyInlineStyleToRun): Updated to use
56759        the enclosingElementWithTag function by its new name.
56760
56761        * editing/Editor.cpp:
56762        (WebCore::Editor::selectionUnorderedListState): Updated to use the
56763        enclosingElementWithTag function by its new name.
56764        (WebCore::Editor::selectionOrderedListState): Ditto.
56765
56766        * editing/InsertListCommand.cpp:
56767        (WebCore::InsertListCommand::doApply): Use a more-specific type for the list tag.
56768        (WebCore::InsertListCommand::doApplyForSingleParagraph): Ditto.
56769        * editing/InsertListCommand.h: Ditto.
56770
56771        * editing/MarkupAccumulator.cpp:
56772        (WebCore::MarkupAccumulator::serializeNodesWithNamespaces): Added an explicit
56773        cast to Element in the loop that is already guarded by an isElementNode check.
56774        Also use a modern C++ for loop.
56775
56776        * editing/ReplaceSelectionCommand.cpp:
56777        (WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
56778        Updated to use the enclosingElementWithTag function by its new name.
56779        (WebCore::ReplaceSelectionCommand::removeUnrenderedTextNodesAtEnds): Ditto.
56780        (WebCore::ReplaceSelectionCommand::positionAtEndOfInsertedContent): Ditto.
56781
56782        * editing/TypingCommand.cpp: Added now-needed includes.
56783        * editing/VisibleUnits.cpp: Ditto.
56784
56785        * editing/htmlediting.cpp:
56786        (WebCore::enclosingElementWithTag): Changed to return an Element instead of a Node,
56787        since nodes other than elements do not have tags.
56788        * editing/htmlediting.h: Ditto.
56789
56790        * editing/mac/EditorMac.mm:
56791        (WebCore::Editor::adjustedSelectionRange): Updated to use the enclosingElementWithTag
56792        function by its new name.
56793        * editing/markup.cpp:
56794        (WebCore::StyledMarkupAccumulator::appendText): Ditto.
56795        (WebCore::StyledMarkupAccumulator::traverseNodesForSerialization): Ditto.
56796        (WebCore::highestAncestorToWrapMarkup): Ditto.
56797        (WebCore::createMarkupInternal): Ditto.
56798        (WebCore::createContextualFragment): Ditto. Use hasTagName instead of hasLocalName,
56799        since the former is now optimized to be the same as the latter was before.
56800
56801        * html/HTMLCollection.cpp:
56802        (WebCore::isMatchingElement): Use hasTagName instead of hasLocalName,
56803        since the former is now optimized to be the same as the latter was before.
56804        (WebCore::nameShouldBeVisibleInDocumentAll): Ditto.
56805        * html/HTMLElement.cpp:
56806        (WebCore::HTMLElement::ieForbidsInsertHTML): Ditto.
56807        (WebCore::unicodeBidiAttributeForDirAuto): Ditto.
56808        (WebCore::HTMLElement::parseBorderWidthAttribute): Ditto.
56809        (WebCore::HTMLElement::setInnerHTML): Ditto.
56810        (WebCore::shouldProhibitSetInnerOuterText): Ditto. Added this to share code between
56811        setInnerText and setOuterText.
56812        (WebCore::HTMLElement::setInnerText): Ditto.
56813        (WebCore::HTMLElement::setOuterText): Ditto.
56814        (WebCore::HTMLElement::rendererIsNeeded): Ditto.
56815        (WebCore::HTMLElement::createElementRenderer): Ditto.
56816
56817        * html/HTMLElement.h: Added hasTagName, which hides the one inherited from Element
56818        and takes the more-specific HTMLQualifiedName type. This means we don't need to check
56819        the namespace at runtime because it's known at compile time. Also put the
56820        implementation of Node::hasTagName for HTMLQualifiedName into this header.
56821
56822        * html/HTMLObjectElement.cpp:
56823        (WebCore::isRecognizedTagName): Updated for change in return type of
56824        HTMLNames::getHTMLTags.
56825
56826        * html/HTMLSelectElement.cpp:
56827        (WebCore::HTMLSelectElement::add): Use hasTagName inastead of hasLocalName.
56828        (WebCore::HTMLSelectElement::value): Use isHTMLOptionElement instead of hasTagName.
56829        Also use a new style for loop and emptyString() instead of "".
56830        (WebCore::HTMLSelectElement::setValue): Ditto.
56831        (WebCore::HTMLSelectElement::setLength): Ditto.
56832        (WebCore::HTMLSelectElement::searchOptionsForValue): Ditto.
56833        (WebCore::HTMLSelectElement::restoreFormControlState): Ditto.
56834
56835        * html/HTMLTableColElement.cpp:
56836        (WebCore::HTMLTableColElement::additionalPresentationAttributeStyle): Use hasTagName
56837        instead of hasLocalName.
56838
56839        * html/HTMLTableRowsCollection.cpp:
56840        (WebCore::isInSection): Updated to use hasTagName and take a reference.
56841        (WebCore::HTMLTableRowsCollection::rowAfter): Pass a reference.
56842
56843        * html/parser/HTMLConstructionSite.cpp: Added now-needed include.
56844
56845        * html/parser/HTMLTreeBuilder.cpp:
56846        (WebCore::createCaseMap): Updated to return a map rather than filling one in, and to
56847        be flxible about the type of the table being used.
56848        (WebCore::adjustSVGTagNameCase): Updated to use NeverDestroyed.
56849        (WebCore::adjustAttributes): Added new helper so we can share more code. Updated
56850        template argument names for clarity.
56851        (WebCore::adjustSVGAttributes): Marked this inline, since it just turns around and
56852        calls a single non-inline function.
56853        (WebCore::adjustMathMLAttributes): Ditto.
56854        (WebCore::addNamesWithPrefix): Changed to take argument by reference instead of pointer.
56855        (WebCore::createForeignAttributesMap): Added. Factors out the map creation from the
56856        function below.
56857        (WebCore::adjustForeignAttributes): Updated for above changes.
56858        (WebCore::HTMLTreeBuilder::processStartTagForInBody): Updated to pass reference.
56859        (WebCore::HTMLTreeBuilder::processTokenInForeignContent): Ditto.
56860
56861        * inspector/InspectorStyleSheet.cpp: Added now-needed include.
56862
56863        * mathml/MathMLElement.h: Added hasTagName, which hides the one inherited from Element
56864        and takes the more-specific MathMLQualifiedName type. This means we don't need to check
56865        the namespace at runtime because it's known at compile time. Also put the
56866        implementation of Node::hasTagName for MathMLQualifiedName into this header.
56867
56868        * mathml/MathMLInlineContainerElement.cpp:
56869        (WebCore::MathMLInlineContainerElement::createElementRenderer): Use hasTagName.
56870
56871        * mathml/MathMLSelectElement.cpp:
56872        (WebCore::MathMLSelectElement::attributeChanged): Use hasTagName.
56873        (WebCore::MathMLSelectElement::getSelectedActionChildAndIndex): Ditto.
56874        (WebCore::MathMLSelectElement::getSelectedActionChild): Ditto.
56875        (WebCore::MathMLSelectElement::getSelectedSemanticsChild): Ditto.
56876        (WebCore::MathMLSelectElement::updateSelectedChild): Ditto.
56877        * mathml/MathMLTextElement.cpp:
56878        (WebCore::MathMLTextElement::createElementRenderer): Ditto.
56879        (WebCore::MathMLTextElement::childShouldCreateRenderer): Ditto.
56880
56881        * platform/gtk/PasteboardGtk.cpp: Added now-needed include.
56882        * platform/mac/HTMLConverter.mm: Ditto.
56883        * rendering/RenderBlockFlow.cpp: Ditto.
56884
56885        * rendering/RenderBoxModelObject.cpp:
56886        (WebCore::RenderBoxModelObject::paintFillLayerExtended): Use hasTagName.
56887        * rendering/RenderElement.cpp:
56888        (WebCore::RenderElement::rendererForRootBackground): Ditto.
56889        * rendering/RenderLayerBacking.cpp:
56890        (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer): Ditto.
56891
56892        * rendering/RenderReplaced.cpp: Added now-needed include.
56893
56894        * rendering/mathml/RenderMathMLScripts.cpp:
56895        (WebCore::RenderMathMLScripts::RenderMathMLScripts): Use hasTagName.
56896        * rendering/mathml/RenderMathMLUnderOver.cpp:
56897        (WebCore::RenderMathMLUnderOver::RenderMathMLUnderOver): Ditto.
56898
56899        * svg/SVGElement.h: Added hasTagName, which hides the one inherited from Element
56900        and takes the more-specific SVGQualifiedName type. This means we don't need to check
56901        the namespace at runtime because it's known at compile time. Also put the
56902        implementation of Node::hasTagName for SVGQualifiedName into this header.
56903
56904        * svg/SVGFontFaceSrcElement.cpp:
56905        (WebCore::SVGFontFaceSrcElement::childrenChanged): Use isSVGFontFaceElement instead
56906        of calling hasTagName.
56907
56908        * svg/SVGUseElement.cpp:
56909        (WebCore::isDirectReference): Changed to take a reference and a more specific type.
56910        (WebCore::SVGUseElement::toClipPath): Added a type cast.
56911        (WebCore::SVGUseElement::rendererClipChild): Use more specific types so we don't
56912        need a type cast.
56913
56914        * xml/parser/XMLDocumentParser.cpp:
56915        (WebCore::XMLDocumentParser::parseDocumentFragment): Added explicit calls to this
56916        unusual call site that has a good reason to use hasLocalName instead of hasTagName.
56917
569182014-03-16  Andreas Kling  <akling@apple.com>
56919
56920        Stop pulling in JSDOMBinding.h via JSEventListener.h
56921        <https://webkit.org/b/130299>
56922
56923        Just chippin' away at the compile time monster.
56924
56925        Reviewed by Darin Adler.
56926
56927        * bindings/js/IDBBindingUtilities.cpp:
56928        * bindings/js/JSEventListener.h:
56929
569302014-03-16  David Kilzer  <ddkilzer@apple.com>
56931
56932        Double values passed to fabsf() in maxScaleFromTransform()
56933        <http://webkit.org/b/130297>
56934
56935        Reviewed by Darin Adler.
56936
56937        Fixes the following build failures using trunk clang:
56938
56939            WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:287:21: error: absolute value function 'fabsf' given an argument of type 'double' but has parameter of type 'float' which may cause truncation of value [-Werror,-Wabsolute-value]
56940                return std::max(fabsf(decomposeData.scaleX), fabsf(decomposeData.scaleY));
56941                                ^
56942            WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:287:21: note: use function 'fabs' instead
56943                return std::max(fabsf(decomposeData.scaleX), fabsf(decomposeData.scaleY));
56944                                ^~~~~
56945                                fabs
56946            WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:287:50: error: absolute value function 'fabsf' given an argument of type 'double' but has parameter of type 'float' which may cause truncation of value [-Werror,-Wabsolute-value]
56947                return std::max(fabsf(decomposeData.scaleX), fabsf(decomposeData.scaleY));
56948                                                             ^
56949            WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:287:50: note: use function 'fabs' instead
56950                return std::max(fabsf(decomposeData.scaleX), fabsf(decomposeData.scaleY));
56951                                                             ^~~~~
56952                                                             fabs
56953
56954        * platform/graphics/ca/GraphicsLayerCA.cpp:
56955        (WebCore::maxScaleFromTransform): Use static_cast<float>() to
56956        convert float values to double values.
56957
569582014-03-15  Zalan Bujtas  <zalan@apple.com>
56959
56960        Move BorderEdge class to its own file.
56961        https://bugs.webkit.org/show_bug.cgi?id=130294
56962
56963        Reviewed by Sam Weinig.
56964
56965        This is in preparation to have better encapsulation for border box decoration painting.
56966
56967        No change in functionality.
56968
56969        * CMakeLists.txt:
56970        * GNUmakefile.list.am:
56971        * WebCore.vcxproj/WebCore.vcxproj:
56972        * WebCore.vcxproj/WebCore.vcxproj.filters:
56973        * WebCore.xcodeproj/project.pbxproj:
56974        * rendering/BorderEdge.cpp: Added.
56975        (WebCore::BorderEdge::BorderEdge):
56976        (WebCore::BorderEdge::getBorderEdgeInfo):
56977        (WebCore::BorderEdge::includesAdjacentEdges):
56978        (WebCore::BorderEdge::obscuresBackgroundEdge):
56979        (WebCore::BorderEdge::obscuresBackground):
56980        (WebCore::BorderEdge::getDoubleBorderStripeWidths):
56981        * rendering/BorderEdge.h: Added.
56982        (WebCore::BorderEdge::edgeFlagForSide):
56983        (WebCore::BorderEdge::includesEdge):
56984        (WebCore::BorderEdge::edgesShareColor):
56985        (WebCore::BorderEdge::hasVisibleColorAndStyle):
56986        (WebCore::BorderEdge::shouldRender):
56987        (WebCore::BorderEdge::presentButInvisible):
56988        (WebCore::BorderEdge::widthForPainting):
56989        (WebCore::BorderEdge::borderWidthInDevicePixel):
56990        * rendering/RenderBoxModelObject.cpp:
56991        (WebCore::borderStyleHasUnmatchedColorsAtCorner):
56992        (WebCore::colorsMatchAtCorner):
56993        (WebCore::colorNeedsAntiAliasAtCorner):
56994        (WebCore::willBeOverdrawn):
56995        (WebCore::joinRequiresMitre):
56996        (WebCore::RenderBoxModelObject::paintBorderSides):
56997        (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
56998        (WebCore::RenderBoxModelObject::paintBorder):
56999        (WebCore::RenderBoxModelObject::borderObscuresBackgroundEdge):
57000        (WebCore::RenderBoxModelObject::borderObscuresBackground):
57001        * rendering/RenderBoxModelObject.h:
57002
570032014-03-15  Martin Robinson  <mrobinson@igalia.com>
57004
57005        Fix WebCore unused parameter warnings for WebKitGTK+ CMake build
57006        https://bugs.webkit.org/show_bug.cgi?id=130252
57007
57008        Reviewed by Carlos Garcia Campos.
57009
57010        * Modules/mediastream/HTMLMediaElementMediaStream.cpp: Fix unused parameters.
57011        * html/RangeInputType.cpp: Ditto.
57012        * page/gtk/EventHandlerGtk.cpp: Ditto.
57013        * platform/graphics/cairo/GraphicsContextCairo.cpp: Ditto.
57014        * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp: Ditto.
57015        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp: Ditto.
57016        * platform/graphics/opengl/Extensions3DOpenGLES.cpp: Ditto.
57017        * platform/gtk/GamepadsGtk.cpp: Ditto.
57018        * platform/gtk/GtkClickCounter.cpp: Ditto.
57019        * platform/gtk/GtkPopupMenu.cpp: Ditto.
57020        * platform/gtk/GtkTouchContextHelper.cpp: Ditto.
57021        * platform/gtk/GtkVersioning.c: Ditto.
57022        * platform/gtk/MainFrameScrollbarGtk.cpp: Ditto.
57023        * platform/gtk/PasteboardGtk.cpp: Ditto.
57024        * platform/gtk/PasteboardHelper.cpp: Ditto.
57025        * platform/gtk/RedirectedXCompositeWindow.cpp: Ditto.
57026        * platform/gtk/RenderThemeGtk.cpp: Ditto.
57027        * platform/gtk/RenderThemeGtk.h: Ditto.
57028        * platform/gtk/RenderThemeGtk2.cpp: Ditto.
57029        * platform/gtk/ScrollbarThemeGtk.cpp: Ditto.
57030        * platform/gtk/ScrollbarThemeGtk2.cpp: Ditto.
57031        * platform/gtk/WidgetGtk.cpp: Ditto.
57032        * platform/network/gtk/CredentialBackingStore.cpp: Ditto.
57033        * platform/soup/SharedBufferSoup.cpp: Ditto.
57034        * plugins/gtk/PluginViewGtk.cpp: Ditto.
57035        * plugins/gtk/gtk2xtbin.c: Ditto.
57036        * rendering/InlineTextBox.cpp: Ditto.
57037
570382014-03-14  Myles C. Maxfield  <mmaxfield@apple.com>
57039
57040        RenderTextControl::hasValidAvgCharWidth doesn't detect System Font
57041        https://bugs.webkit.org/show_bug.cgi?id=130168
57042
57043        Reviewed by Dean Jackson.
57044
57045        No new tests.
57046
57047        * platform/graphics/Font.cpp: Moved functions from RenderTextControl
57048        (WebCore::Font::hasValidAverageCharWidth):
57049        (WebCore::Font::fastAverageCharWidthIfAvailable):
57050        * platform/graphics/Font.h:
57051        * rendering/RenderTextControl.cpp: Moved functions to Font.cpp
57052        (WebCore::RenderTextControl::getAverageCharWidth): Removed redundant function argument
57053        (WebCore::RenderTextControl::computeIntrinsicLogicalWidths):
57054        * rendering/RenderTextControl.h:
57055        * rendering/RenderTextControlMultiLine.cpp:
57056        (WebCore::RenderTextControlMultiLine::getAverageCharWidth): Removed redundant function argument
57057        * rendering/RenderTextControlMultiLine.h:
57058        * rendering/RenderTextControlSingleLine.cpp:
57059        (WebCore::RenderTextControlSingleLine::getAverageCharWidth): Removed redundant function argument
57060        (WebCore::RenderTextControlSingleLine::preferredContentLogicalWidth):
57061        * rendering/RenderTextControlSingleLine.h:
57062
570632014-03-15  David Kilzer  <ddkilzer@apple.com>
57064
57065        [iOS] Define SYSTEM_VERSION_PREFIX consistently
57066        <http://webkit.org/b/130293>
57067        <rdar://problem/15926359>
57068
57069        Reviewed by Dan Bernstein.
57070
57071        * Configurations/Version.xcconfig:
57072        (SYSTEM_VERSION_PREFIX_iphoneos): Sync with
57073        Source/WebKit/mac/Version.xcconfig.
57074
570752014-03-14  Mark Rowe  <mrowe@apple.com>
57076
57077        Fix the production build.
57078
57079        Don't rely on USE_INTERNAL_SDK being set for the Production configuration since UseInternalSDK.xcconfig won't
57080        be at the expected relative path when working from installed source.
57081
57082        * Configurations/Base.xcconfig:
57083
570842014-03-14  Maciej Stachowiak  <mjs@apple.com>
57085
57086        Replace "Apple Computer, Inc." with "Apple Inc." in copyright headers
57087        https://bugs.webkit.org/show_bug.cgi?id=130276
57088        <rdar://problem/16266927>
57089
57090        Reviewed by Simon Fraser.
57091
57092        No new tests because no behavior changes.
57093
57094        * DerivedSources.make:
57095        * Modules/airplay/WebKitPlaybackTargetAvailabilityEvent.cpp:
57096        * Modules/airplay/WebKitPlaybackTargetAvailabilityEvent.h:
57097        * Modules/airplay/WebKitPlaybackTargetAvailabilityEvent.idl:
57098        * Modules/encryptedmedia/MediaKeyMessageEvent.cpp:
57099        * Modules/encryptedmedia/MediaKeyMessageEvent.h:
57100        * Modules/encryptedmedia/MediaKeyMessageEvent.idl:
57101        * Modules/encryptedmedia/MediaKeyNeededEvent.cpp:
57102        * Modules/encryptedmedia/MediaKeyNeededEvent.h:
57103        * Modules/encryptedmedia/MediaKeyNeededEvent.idl:
57104        * Modules/encryptedmedia/MediaKeySession.idl:
57105        * Modules/encryptedmedia/MediaKeys.idl:
57106        * Modules/geolocation/NavigatorGeolocation.cpp:
57107        * Modules/indexeddb/DOMWindowIndexedDatabase.idl:
57108        * Modules/indexeddb/IDBCallbacks.h:
57109        * Modules/indexeddb/IDBDatabaseException.cpp:
57110        * Modules/indexeddb/IDBDatabaseMetadata.h:
57111        * Modules/indexeddb/IDBEventDispatcher.cpp:
57112        * Modules/indexeddb/IDBEventDispatcher.h:
57113        * Modules/indexeddb/IDBFactory.cpp:
57114        * Modules/indexeddb/IDBFactory.h:
57115        * Modules/indexeddb/IDBFactoryBackendInterface.cpp:
57116        * Modules/indexeddb/IDBFactoryBackendInterface.h:
57117        * Modules/indexeddb/IDBHistograms.h:
57118        * Modules/indexeddb/IDBIndexMetadata.h:
57119        * Modules/indexeddb/IDBObjectStoreMetadata.h:
57120        * Modules/indexeddb/IDBRecordIdentifier.h:
57121        * Modules/indexeddb/IDBRequest.cpp:
57122        * Modules/indexeddb/IDBRequest.h:
57123        * Modules/indexeddb/IDBRequest.idl:
57124        * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.cpp:
57125        * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.h:
57126        * Modules/indexeddb/WorkerGlobalScopeIndexedDatabase.idl:
57127        * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.cpp:
57128        * Modules/indexeddb/leveldb/IDBFactoryBackendLevelDB.h:
57129        * Modules/mediacontrols/MediaControlsHost.cpp:
57130        * Modules/mediacontrols/MediaControlsHost.h:
57131        * Modules/mediacontrols/MediaControlsHost.idl:
57132        * Modules/mediacontrols/mediaControlsApple.css:
57133        * Modules/mediacontrols/mediaControlsiOS.css:
57134        * Modules/mediasource/AudioTrackMediaSource.h:
57135        * Modules/mediasource/AudioTrackMediaSource.idl:
57136        * Modules/mediasource/TextTrackMediaSource.h:
57137        * Modules/mediasource/TextTrackMediaSource.idl:
57138        * Modules/mediasource/VideoTrackMediaSource.h:
57139        * Modules/mediasource/VideoTrackMediaSource.idl:
57140        * Modules/mediastream/AllAudioCapabilities.h:
57141        * Modules/mediastream/AllAudioCapabilities.idl:
57142        * Modules/mediastream/AllVideoCapabilities.h:
57143        * Modules/mediastream/AllVideoCapabilities.idl:
57144        * Modules/mediastream/AudioStreamTrack.cpp:
57145        * Modules/mediastream/AudioStreamTrack.h:
57146        * Modules/mediastream/AudioStreamTrack.idl:
57147        * Modules/mediastream/CapabilityRange.cpp:
57148        * Modules/mediastream/CapabilityRange.h:
57149        * Modules/mediastream/CapabilityRange.idl:
57150        * Modules/mediastream/MediaSourceStates.cpp:
57151        * Modules/mediastream/MediaSourceStates.h:
57152        * Modules/mediastream/MediaSourceStates.idl:
57153        * Modules/mediastream/MediaStreamCapabilities.cpp:
57154        * Modules/mediastream/MediaStreamCapabilities.h:
57155        * Modules/mediastream/MediaStreamCapabilities.idl:
57156        * Modules/mediastream/MediaTrackConstraint.cpp:
57157        * Modules/mediastream/MediaTrackConstraint.h:
57158        * Modules/mediastream/MediaTrackConstraint.idl:
57159        * Modules/mediastream/MediaTrackConstraintSet.cpp:
57160        * Modules/mediastream/MediaTrackConstraintSet.h:
57161        * Modules/mediastream/MediaTrackConstraints.cpp:
57162        * Modules/mediastream/MediaTrackConstraints.h:
57163        * Modules/mediastream/MediaTrackConstraints.idl:
57164        * Modules/mediastream/NavigatorMediaStream.cpp:
57165        * Modules/mediastream/NavigatorUserMediaError.cpp:
57166        * Modules/mediastream/RTCConfiguration.idl:
57167        * Modules/mediastream/RTCIceServer.idl:
57168        * Modules/mediastream/RTCOfferAnswerOptions.cpp:
57169        * Modules/mediastream/RTCOfferAnswerOptions.h:
57170        * Modules/mediastream/VideoStreamTrack.cpp:
57171        * Modules/mediastream/VideoStreamTrack.h:
57172        * Modules/mediastream/VideoStreamTrack.idl:
57173        * Modules/networkinfo/NetworkInfo.cpp:
57174        * Modules/networkinfo/NetworkInfo.h:
57175        * Modules/networkinfo/NetworkInfoConnection.cpp:
57176        * Modules/networkinfo/NetworkInfoConnection.h:
57177        * Modules/networkinfo/NetworkInfoController.cpp:
57178        * Modules/notifications/DOMWindowNotifications.cpp:
57179        * Modules/notifications/DOMWindowNotifications.h:
57180        * Modules/notifications/DOMWindowNotifications.idl:
57181        * Modules/notifications/NotificationController.cpp:
57182        * Modules/notifications/NotificationController.h:
57183        * Modules/notifications/NotificationPermissionCallback.h:
57184        * Modules/notifications/NotificationPermissionCallback.idl:
57185        * Modules/notifications/WorkerGlobalScopeNotifications.cpp:
57186        * Modules/notifications/WorkerGlobalScopeNotifications.h:
57187        * Modules/notifications/WorkerGlobalScopeNotifications.idl:
57188        * Modules/plugins/PluginReplacement.h:
57189        * Modules/plugins/QuickTimePluginReplacement.cpp:
57190        * Modules/plugins/QuickTimePluginReplacement.css:
57191        * Modules/plugins/QuickTimePluginReplacement.h:
57192        * Modules/plugins/QuickTimePluginReplacement.idl:
57193        * Modules/quota/DOMWindowQuota.idl:
57194        * Modules/speech/DOMWindowSpeechSynthesis.h:
57195        * Modules/speech/DOMWindowSpeechSynthesis.idl:
57196        * Modules/speech/SpeechSynthesis.cpp:
57197        * Modules/speech/SpeechSynthesis.h:
57198        * Modules/speech/SpeechSynthesis.idl:
57199        * Modules/speech/SpeechSynthesisEvent.cpp:
57200        * Modules/speech/SpeechSynthesisEvent.h:
57201        * Modules/speech/SpeechSynthesisEvent.idl:
57202        * Modules/speech/SpeechSynthesisUtterance.cpp:
57203        * Modules/speech/SpeechSynthesisUtterance.h:
57204        * Modules/speech/SpeechSynthesisUtterance.idl:
57205        * Modules/speech/SpeechSynthesisVoice.cpp:
57206        * Modules/speech/SpeechSynthesisVoice.h:
57207        * Modules/speech/SpeechSynthesisVoice.idl:
57208        * Modules/webaudio/AudioBuffer.cpp:
57209        * Modules/webaudio/AudioBuffer.h:
57210        * Modules/webaudio/AudioBuffer.idl:
57211        * Modules/webaudio/AudioListener.cpp:
57212        * Modules/webaudio/AudioListener.h:
57213        * Modules/webaudio/AudioListener.idl:
57214        * Modules/webaudio/AudioParam.h:
57215        * Modules/webaudio/AudioParam.idl:
57216        * Modules/webaudio/AudioParamTimeline.h:
57217        * Modules/webaudio/AudioScheduledSourceNode.h:
57218        * Modules/webaudio/ChannelMergerNode.cpp:
57219        * Modules/webaudio/ChannelMergerNode.h:
57220        * Modules/webaudio/ChannelMergerNode.idl:
57221        * Modules/webaudio/MediaStreamAudioSource.cpp:
57222        * Modules/webaudio/MediaStreamAudioSource.h:
57223        * Modules/webaudio/PeriodicWave.cpp:
57224        * Modules/webaudio/PeriodicWave.h:
57225        * Modules/webdatabase/ChangeVersionWrapper.cpp:
57226        * Modules/webdatabase/ChangeVersionWrapper.h:
57227        * Modules/webdatabase/DOMWindowWebDatabase.cpp:
57228        * Modules/webdatabase/DOMWindowWebDatabase.h:
57229        * Modules/webdatabase/DOMWindowWebDatabase.idl:
57230        * Modules/webdatabase/Database.cpp:
57231        * Modules/webdatabase/Database.h:
57232        * Modules/webdatabase/Database.idl:
57233        * Modules/webdatabase/DatabaseAuthorizer.cpp:
57234        * Modules/webdatabase/DatabaseAuthorizer.h:
57235        * Modules/webdatabase/DatabaseBackendBase.cpp:
57236        * Modules/webdatabase/DatabaseBackendBase.h:
57237        * Modules/webdatabase/DatabaseCallback.idl:
57238        * Modules/webdatabase/DatabaseContext.cpp:
57239        * Modules/webdatabase/DatabaseContext.h:
57240        * Modules/webdatabase/DatabaseDetails.h:
57241        * Modules/webdatabase/DatabaseTask.cpp:
57242        * Modules/webdatabase/DatabaseTask.h:
57243        * Modules/webdatabase/DatabaseThread.cpp:
57244        * Modules/webdatabase/DatabaseThread.h:
57245        * Modules/webdatabase/DatabaseTracker.cpp:
57246        * Modules/webdatabase/DatabaseTracker.h:
57247        * Modules/webdatabase/SQLCallbackWrapper.h:
57248        * Modules/webdatabase/SQLError.h:
57249        * Modules/webdatabase/SQLError.idl:
57250        * Modules/webdatabase/SQLException.cpp:
57251        * Modules/webdatabase/SQLResultSet.cpp:
57252        * Modules/webdatabase/SQLResultSet.h:
57253        * Modules/webdatabase/SQLResultSet.idl:
57254        * Modules/webdatabase/SQLResultSetRowList.cpp:
57255        * Modules/webdatabase/SQLResultSetRowList.h:
57256        * Modules/webdatabase/SQLResultSetRowList.idl:
57257        * Modules/webdatabase/SQLStatement.cpp:
57258        * Modules/webdatabase/SQLStatement.h:
57259        * Modules/webdatabase/SQLStatementBackend.cpp:
57260        * Modules/webdatabase/SQLStatementBackend.h:
57261        * Modules/webdatabase/SQLStatementCallback.h:
57262        * Modules/webdatabase/SQLStatementCallback.idl:
57263        * Modules/webdatabase/SQLStatementErrorCallback.h:
57264        * Modules/webdatabase/SQLStatementErrorCallback.idl:
57265        * Modules/webdatabase/SQLStatementSync.cpp:
57266        * Modules/webdatabase/SQLTransaction.cpp:
57267        * Modules/webdatabase/SQLTransaction.h:
57268        * Modules/webdatabase/SQLTransaction.idl:
57269        * Modules/webdatabase/SQLTransactionBackend.cpp:
57270        * Modules/webdatabase/SQLTransactionBackend.h:
57271        * Modules/webdatabase/SQLTransactionCallback.h:
57272        * Modules/webdatabase/SQLTransactionCallback.idl:
57273        * Modules/webdatabase/SQLTransactionErrorCallback.h:
57274        * Modules/webdatabase/SQLTransactionErrorCallback.idl:
57275        * Modules/webdatabase/WorkerGlobalScopeWebDatabase.cpp:
57276        * Modules/webdatabase/WorkerGlobalScopeWebDatabase.h:
57277        * Modules/webdatabase/WorkerGlobalScopeWebDatabase.idl:
57278        * Resources/deleteButton.tiff:
57279        * Resources/deleteButtonPressed.tiff:
57280        * WebCore.vcxproj/MigrateScripts:
57281        * WebCorePrefix.cpp:
57282        * accessibility/AXObjectCache.cpp:
57283        * accessibility/AXObjectCache.h:
57284        * accessibility/AccessibilityARIAGrid.cpp:
57285        * accessibility/AccessibilityARIAGrid.h:
57286        * accessibility/AccessibilityARIAGridCell.cpp:
57287        * accessibility/AccessibilityARIAGridCell.h:
57288        * accessibility/AccessibilityARIAGridRow.cpp:
57289        * accessibility/AccessibilityARIAGridRow.h:
57290        * accessibility/AccessibilityImageMapLink.cpp:
57291        * accessibility/AccessibilityImageMapLink.h:
57292        * accessibility/AccessibilityList.cpp:
57293        * accessibility/AccessibilityList.h:
57294        * accessibility/AccessibilityListBox.cpp:
57295        * accessibility/AccessibilityListBox.h:
57296        * accessibility/AccessibilityListBoxOption.cpp:
57297        * accessibility/AccessibilityListBoxOption.h:
57298        * accessibility/AccessibilityMediaControls.cpp:
57299        * accessibility/AccessibilityMediaControls.h:
57300        * accessibility/AccessibilityNodeObject.cpp:
57301        * accessibility/AccessibilityNodeObject.h:
57302        * accessibility/AccessibilityObject.cpp:
57303        * accessibility/AccessibilityObject.h:
57304        * accessibility/AccessibilityRenderObject.cpp:
57305        * accessibility/AccessibilityRenderObject.h:
57306        * accessibility/AccessibilitySVGRoot.cpp:
57307        * accessibility/AccessibilitySVGRoot.h:
57308        * accessibility/AccessibilityScrollbar.cpp:
57309        * accessibility/AccessibilityScrollbar.h:
57310        * accessibility/AccessibilitySlider.cpp:
57311        * accessibility/AccessibilitySlider.h:
57312        * accessibility/AccessibilityTable.cpp:
57313        * accessibility/AccessibilityTable.h:
57314        * accessibility/AccessibilityTableCell.cpp:
57315        * accessibility/AccessibilityTableCell.h:
57316        * accessibility/AccessibilityTableColumn.cpp:
57317        * accessibility/AccessibilityTableColumn.h:
57318        * accessibility/AccessibilityTableHeaderContainer.cpp:
57319        * accessibility/AccessibilityTableHeaderContainer.h:
57320        * accessibility/AccessibilityTableRow.cpp:
57321        * accessibility/AccessibilityTableRow.h:
57322        * accessibility/ios/AXObjectCacheIOS.mm:
57323        * accessibility/ios/AccessibilityObjectIOS.mm:
57324        * accessibility/ios/WebAccessibilityObjectWrapperIOS.h:
57325        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
57326        * accessibility/mac/AXObjectCacheMac.mm:
57327        * accessibility/mac/AccessibilityObjectMac.mm:
57328        * accessibility/mac/WebAccessibilityObjectWrapperBase.h:
57329        * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
57330        * accessibility/mac/WebAccessibilityObjectWrapperMac.h:
57331        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
57332        * bindings/gobject/WebKitDOMEventTarget.cpp:
57333        * bindings/gobject/WebKitDOMHTMLPrivate.cpp:
57334        * bindings/gobject/WebKitDOMHTMLPrivate.h:
57335        * bindings/js/Dictionary.cpp:
57336        * bindings/js/GCController.cpp:
57337        * bindings/js/GCController.h:
57338        * bindings/js/JSAttrCustom.cpp:
57339        * bindings/js/JSAudioTrackCustom.cpp:
57340        * bindings/js/JSAudioTrackListCustom.cpp:
57341        * bindings/js/JSCSSRuleCustom.cpp:
57342        * bindings/js/JSCSSRuleCustom.h:
57343        * bindings/js/JSCSSRuleListCustom.cpp:
57344        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
57345        * bindings/js/JSCSSValueCustom.cpp:
57346        * bindings/js/JSCallbackData.cpp:
57347        * bindings/js/JSCallbackData.h:
57348        * bindings/js/JSCanvasRenderingContextCustom.cpp:
57349        * bindings/js/JSClipboardCustom.cpp:
57350        * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
57351        * bindings/js/JSCustomXPathNSResolver.cpp:
57352        * bindings/js/JSCustomXPathNSResolver.h:
57353        * bindings/js/JSDOMGlobalObject.cpp:
57354        * bindings/js/JSDOMGlobalObject.h:
57355        * bindings/js/JSDOMWindowShell.cpp:
57356        * bindings/js/JSDOMWindowShell.h:
57357        * bindings/js/JSElementCustom.cpp:
57358        * bindings/js/JSEventCustom.cpp:
57359        * bindings/js/JSHTMLAppletElementCustom.cpp:
57360        * bindings/js/JSHTMLCanvasElementCustom.cpp:
57361        * bindings/js/JSHTMLDocumentCustom.cpp:
57362        * bindings/js/JSHTMLElementCustom.cpp:
57363        * bindings/js/JSHTMLEmbedElementCustom.cpp:
57364        * bindings/js/JSHTMLFormElementCustom.cpp:
57365        * bindings/js/JSHTMLFrameElementCustom.cpp:
57366        * bindings/js/JSHTMLFrameSetElementCustom.cpp:
57367        * bindings/js/JSHTMLObjectElementCustom.cpp:
57368        * bindings/js/JSHTMLSelectElementCustom.h:
57369        * bindings/js/JSHistoryCustom.cpp:
57370        * bindings/js/JSMediaListCustom.h:
57371        * bindings/js/JSMediaSourceStatesCustom.cpp:
57372        * bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
57373        * bindings/js/JSNamedNodeMapCustom.cpp:
57374        * bindings/js/JSNodeCustom.cpp:
57375        * bindings/js/JSNodeCustom.h:
57376        * bindings/js/JSNodeFilterCustom.cpp:
57377        * bindings/js/JSNodeListCustom.cpp:
57378        * bindings/js/JSSQLResultSetRowListCustom.cpp:
57379        * bindings/js/JSSQLTransactionCustom.cpp:
57380        * bindings/js/JSSQLTransactionSyncCustom.cpp:
57381        * bindings/js/JSSVGElementInstanceCustom.cpp:
57382        * bindings/js/JSStyleSheetCustom.cpp:
57383        * bindings/js/JSStyleSheetCustom.h:
57384        * bindings/js/JSStyleSheetListCustom.cpp:
57385        * bindings/js/JSTextTrackCueCustom.cpp:
57386        * bindings/js/JSTextTrackCustom.cpp:
57387        * bindings/js/JSTextTrackListCustom.cpp:
57388        * bindings/js/JSTouchCustom.cpp:
57389        * bindings/js/JSTouchListCustom.cpp:
57390        * bindings/js/JSTrackCustom.cpp:
57391        * bindings/js/JSTrackCustom.h:
57392        * bindings/js/JSTrackEventCustom.cpp:
57393        * bindings/js/JSVideoTrackCustom.cpp:
57394        * bindings/js/JSVideoTrackListCustom.cpp:
57395        * bindings/js/JSWebGLRenderingContextCustom.cpp:
57396        * bindings/js/JSWebKitPointCustom.cpp:
57397        * bindings/js/JSWorkerGlobalScopeBase.cpp:
57398        * bindings/js/JSWorkerGlobalScopeBase.h:
57399        * bindings/js/JSXMLHttpRequestCustom.cpp:
57400        * bindings/js/JSXSLTProcessorCustom.cpp:
57401        * bindings/js/ScriptControllerMac.mm:
57402        * bindings/js/ScriptProfile.cpp:
57403        * bindings/js/ScriptProfile.h:
57404        * bindings/js/ScriptProfileNode.h:
57405        * bindings/js/ScriptProfiler.cpp:
57406        * bindings/js/ScriptProfiler.h:
57407        * bindings/js/SerializedScriptValue.cpp:
57408        * bindings/js/SerializedScriptValue.h:
57409        * bindings/js/WorkerScriptController.cpp:
57410        * bindings/js/WorkerScriptController.h:
57411        * bindings/objc/DOM.h:
57412        * bindings/objc/DOM.mm:
57413        * bindings/objc/DOMAbstractView.mm:
57414        * bindings/objc/DOMAbstractViewFrame.h:
57415        * bindings/objc/DOMCSS.h:
57416        * bindings/objc/DOMCSS.mm:
57417        * bindings/objc/DOMCore.h:
57418        * bindings/objc/DOMCustomXPathNSResolver.h:
57419        * bindings/objc/DOMCustomXPathNSResolver.mm:
57420        * bindings/objc/DOMEventException.h:
57421        * bindings/objc/DOMEvents.h:
57422        * bindings/objc/DOMEvents.mm:
57423        * bindings/objc/DOMException.h:
57424        * bindings/objc/DOMExtensions.h:
57425        * bindings/objc/DOMHTML.h:
57426        * bindings/objc/DOMHTML.mm:
57427        * bindings/objc/DOMInternal.h:
57428        * bindings/objc/DOMInternal.mm:
57429        * bindings/objc/DOMObject.h:
57430        * bindings/objc/DOMObject.mm:
57431        * bindings/objc/DOMPrivate.h:
57432        * bindings/objc/DOMRangeException.h:
57433        * bindings/objc/DOMRanges.h:
57434        * bindings/objc/DOMStylesheets.h:
57435        * bindings/objc/DOMTraversal.h:
57436        * bindings/objc/DOMUIKitExtensions.h:
57437        * bindings/objc/DOMUIKitExtensions.mm:
57438        * bindings/objc/DOMUtility.mm:
57439        * bindings/objc/DOMViews.h:
57440        * bindings/objc/DOMXPath.h:
57441        * bindings/objc/DOMXPath.mm:
57442        * bindings/objc/DOMXPathException.h:
57443        * bindings/objc/ExceptionHandlers.h:
57444        * bindings/objc/ExceptionHandlers.mm:
57445        * bindings/objc/ObjCEventListener.h:
57446        * bindings/objc/ObjCEventListener.mm:
57447        * bindings/objc/ObjCNodeFilterCondition.h:
57448        * bindings/objc/ObjCNodeFilterCondition.mm:
57449        * bindings/objc/PublicDOMInterfaces.h:
57450        * bindings/objc/WebScriptObject.mm:
57451        * bindings/scripts/CodeGeneratorObjC.pm:
57452        * bindings/scripts/InFilesCompiler.pm:
57453        (license):
57454        * bindings/scripts/InFilesParser.pm:
57455        * bindings/scripts/generate-bindings.pl:
57456        * bindings/scripts/test/ObjC/DOMFloat64Array.h:
57457        * bindings/scripts/test/ObjC/DOMFloat64Array.mm:
57458        * bindings/scripts/test/ObjC/DOMFloat64ArrayInternal.h:
57459        * bindings/scripts/test/ObjC/DOMTestActiveDOMObject.h:
57460        * bindings/scripts/test/ObjC/DOMTestActiveDOMObject.mm:
57461        * bindings/scripts/test/ObjC/DOMTestActiveDOMObjectInternal.h:
57462        * bindings/scripts/test/ObjC/DOMTestCallback.h:
57463        * bindings/scripts/test/ObjC/DOMTestCallback.mm:
57464        * bindings/scripts/test/ObjC/DOMTestCallbackInternal.h:
57465        * bindings/scripts/test/ObjC/DOMTestCustomNamedGetter.h:
57466        * bindings/scripts/test/ObjC/DOMTestCustomNamedGetter.mm:
57467        * bindings/scripts/test/ObjC/DOMTestCustomNamedGetterInternal.h:
57468        * bindings/scripts/test/ObjC/DOMTestEventConstructor.h:
57469        * bindings/scripts/test/ObjC/DOMTestEventConstructor.mm:
57470        * bindings/scripts/test/ObjC/DOMTestEventConstructorInternal.h:
57471        * bindings/scripts/test/ObjC/DOMTestEventTarget.h:
57472        * bindings/scripts/test/ObjC/DOMTestEventTarget.mm:
57473        * bindings/scripts/test/ObjC/DOMTestEventTargetInternal.h:
57474        * bindings/scripts/test/ObjC/DOMTestException.h:
57475        * bindings/scripts/test/ObjC/DOMTestException.mm:
57476        * bindings/scripts/test/ObjC/DOMTestExceptionInternal.h:
57477        * bindings/scripts/test/ObjC/DOMTestGenerateIsReachable.h:
57478        * bindings/scripts/test/ObjC/DOMTestGenerateIsReachable.mm:
57479        * bindings/scripts/test/ObjC/DOMTestGenerateIsReachableInternal.h:
57480        * bindings/scripts/test/ObjC/DOMTestInterface.h:
57481        * bindings/scripts/test/ObjC/DOMTestInterface.mm:
57482        * bindings/scripts/test/ObjC/DOMTestInterfaceInternal.h:
57483        * bindings/scripts/test/ObjC/DOMTestMediaQueryListListener.h:
57484        * bindings/scripts/test/ObjC/DOMTestMediaQueryListListener.mm:
57485        * bindings/scripts/test/ObjC/DOMTestMediaQueryListListenerInternal.h:
57486        * bindings/scripts/test/ObjC/DOMTestNamedConstructor.h:
57487        * bindings/scripts/test/ObjC/DOMTestNamedConstructor.mm:
57488        * bindings/scripts/test/ObjC/DOMTestNamedConstructorInternal.h:
57489        * bindings/scripts/test/ObjC/DOMTestNode.h:
57490        * bindings/scripts/test/ObjC/DOMTestNode.mm:
57491        * bindings/scripts/test/ObjC/DOMTestNodeInternal.h:
57492        * bindings/scripts/test/ObjC/DOMTestObj.h:
57493        * bindings/scripts/test/ObjC/DOMTestObj.mm:
57494        * bindings/scripts/test/ObjC/DOMTestObjInternal.h:
57495        * bindings/scripts/test/ObjC/DOMTestOverloadedConstructors.h:
57496        * bindings/scripts/test/ObjC/DOMTestOverloadedConstructors.mm:
57497        * bindings/scripts/test/ObjC/DOMTestOverloadedConstructorsInternal.h:
57498        * bindings/scripts/test/ObjC/DOMTestSerializedScriptValueInterface.h:
57499        * bindings/scripts/test/ObjC/DOMTestSerializedScriptValueInterface.mm:
57500        * bindings/scripts/test/ObjC/DOMTestSerializedScriptValueInterfaceInternal.h:
57501        * bindings/scripts/test/ObjC/DOMTestTypedefs.h:
57502        * bindings/scripts/test/ObjC/DOMTestTypedefs.mm:
57503        * bindings/scripts/test/ObjC/DOMTestTypedefsInternal.h:
57504        * bindings/scripts/test/ObjC/DOMattribute.h:
57505        * bindings/scripts/test/ObjC/DOMattribute.mm:
57506        * bindings/scripts/test/ObjC/DOMattributeInternal.h:
57507        * bindings/scripts/test/ObjC/DOMreadonly.h:
57508        * bindings/scripts/test/ObjC/DOMreadonly.mm:
57509        * bindings/scripts/test/ObjC/DOMreadonlyInternal.h:
57510        * bindings/scripts/test/TestCallback.idl:
57511        * bindings/scripts/test/TestCustomNamedGetter.idl:
57512        * bindings/scripts/test/TestDomainSecurity.idl:
57513        * bindings/scripts/test/TestEventConstructor.idl:
57514        * bindings/scripts/test/TestEventTarget.idl:
57515        * bindings/scripts/test/TestException.idl:
57516        * bindings/scripts/test/TestImplements.idl:
57517        * bindings/scripts/test/TestInterface.idl:
57518        * bindings/scripts/test/TestMediaQueryListListener.idl:
57519        * bindings/scripts/test/TestNamedConstructor.idl:
57520        * bindings/scripts/test/TestObj.idl:
57521        * bindings/scripts/test/TestOverloadedConstructors.idl:
57522        * bindings/scripts/test/TestSupplemental.idl:
57523        * bridge/Bridge.h:
57524        * bridge/IdentifierRep.cpp:
57525        * bridge/IdentifierRep.h:
57526        * bridge/NP_jsobject.cpp:
57527        * bridge/NP_jsobject.h:
57528        * bridge/c/CRuntimeObject.cpp:
57529        * bridge/c/CRuntimeObject.h:
57530        * bridge/c/c_class.cpp:
57531        * bridge/c/c_class.h:
57532        * bridge/c/c_instance.cpp:
57533        * bridge/c/c_instance.h:
57534        * bridge/c/c_runtime.cpp:
57535        * bridge/c/c_runtime.h:
57536        * bridge/c/c_utility.cpp:
57537        * bridge/c/c_utility.h:
57538        * bridge/jsc/BridgeJSC.cpp:
57539        * bridge/jsc/BridgeJSC.h:
57540        * bridge/npruntime.cpp:
57541        * bridge/npruntime_impl.h:
57542        * bridge/npruntime_priv.h:
57543        * bridge/objc/ObjCRuntimeObject.h:
57544        * bridge/objc/ObjCRuntimeObject.mm:
57545        * bridge/objc/WebScriptObject.h:
57546        * bridge/objc/objc_class.h:
57547        * bridge/objc/objc_class.mm:
57548        * bridge/objc/objc_header.h:
57549        * bridge/objc/objc_instance.h:
57550        * bridge/objc/objc_instance.mm:
57551        * bridge/objc/objc_runtime.h:
57552        * bridge/objc/objc_runtime.mm:
57553        * bridge/objc/objc_utility.h:
57554        * bridge/objc/objc_utility.mm:
57555        * bridge/runtime_array.cpp:
57556        * bridge/runtime_array.h:
57557        * bridge/runtime_method.cpp:
57558        * bridge/runtime_method.h:
57559        * bridge/runtime_object.cpp:
57560        * bridge/runtime_object.h:
57561        * bridge/runtime_root.cpp:
57562        * bridge/runtime_root.h:
57563        * bridge/testbindings.mm:
57564        * css/CSSAllInOne.cpp:
57565        * css/CSSAspectRatioValue.cpp:
57566        * css/CSSAspectRatioValue.h:
57567        * css/CSSBorderImageSliceValue.cpp:
57568        * css/CSSBorderImageSliceValue.h:
57569        * css/CSSCanvasValue.cpp:
57570        * css/CSSCanvasValue.h:
57571        * css/CSSCrossfadeValue.cpp:
57572        * css/CSSCrossfadeValue.h:
57573        * css/CSSFontFace.cpp:
57574        * css/CSSFontFace.h:
57575        * css/CSSFontFaceSource.cpp:
57576        * css/CSSFontFaceSource.h:
57577        * css/CSSFontFaceSrcValue.cpp:
57578        * css/CSSFontFaceSrcValue.h:
57579        * css/CSSFontFeatureValue.cpp:
57580        * css/CSSFontFeatureValue.h:
57581        * css/CSSFontSelector.cpp:
57582        * css/CSSFontSelector.h:
57583        * css/CSSFontValue.cpp:
57584        * css/CSSGradientValue.cpp:
57585        * css/CSSGradientValue.h:
57586        * css/CSSImageGeneratorValue.cpp:
57587        * css/CSSImageGeneratorValue.h:
57588        * css/CSSMediaRule.cpp:
57589        * css/CSSProperty.cpp:
57590        * css/CSSProperty.h:
57591        * css/CSSReflectValue.cpp:
57592        * css/CSSReflectValue.h:
57593        * css/CSSReflectionDirection.h:
57594        * css/CSSRuleList.cpp:
57595        * css/CSSRuleList.h:
57596        * css/CSSRuleList.idl:
57597        * css/CSSSegmentedFontFace.cpp:
57598        * css/CSSSegmentedFontFace.h:
57599        * css/CSSShadowValue.cpp:
57600        * css/CSSTimingFunctionValue.cpp:
57601        * css/CSSTimingFunctionValue.h:
57602        * css/CSSUnicodeRangeValue.cpp:
57603        * css/CSSUnicodeRangeValue.h:
57604        * css/CSSUnknownRule.idl:
57605        * css/CSSValue.cpp:
57606        * css/CSSValueList.idl:
57607        * css/MediaAllInOne.cpp:
57608        * css/MediaFeatureNames.cpp:
57609        * css/MediaList.idl:
57610        * css/MediaQuery.cpp:
57611        * css/MediaQuery.h:
57612        * css/MediaQueryEvaluator.cpp:
57613        * css/MediaQueryEvaluator.h:
57614        * css/MediaQueryExp.cpp:
57615        * css/MediaQueryExp.h:
57616        * css/Pair.h:
57617        * css/PropertySetCSSStyleDeclaration.h:
57618        * css/RGBColor.cpp:
57619        * css/RGBColor.h:
57620        * css/SVGCSSParser.cpp:
57621        * css/SVGCSSStyleSelector.cpp:
57622        * css/StyleInvalidationAnalysis.cpp:
57623        * css/StyleInvalidationAnalysis.h:
57624        * css/StyleMedia.cpp:
57625        * css/StyleMedia.h:
57626        * css/StyleMedia.idl:
57627        * css/StyleSheet.cpp:
57628        * css/WebKitCSSFilterValue.cpp:
57629        * css/WebKitCSSFilterValue.h:
57630        * css/WebKitCSSFilterValue.idl:
57631        * css/WebKitCSSKeyframeRule.cpp:
57632        * css/WebKitCSSKeyframeRule.h:
57633        * css/WebKitCSSKeyframeRule.idl:
57634        * css/WebKitCSSKeyframesRule.cpp:
57635        * css/WebKitCSSKeyframesRule.h:
57636        * css/WebKitCSSKeyframesRule.idl:
57637        * css/WebKitCSSTransformValue.cpp:
57638        * css/WebKitCSSTransformValue.h:
57639        * css/WebKitCSSTransformValue.idl:
57640        * css/make-css-file-arrays.pl:
57641        * css/mediaControls.css:
57642        * css/mediaControlsEfl.css:
57643        * css/mediaControlsEflFullscreen.css:
57644        * css/mediaControlsGtk.css:
57645        * css/mediaControlsiOS.css:
57646        * css/svg.css:
57647        * dom/ActiveDOMObject.cpp:
57648        * dom/ActiveDOMObject.h:
57649        * dom/BeforeLoadEvent.h:
57650        * dom/BeforeLoadEvent.idl:
57651        * dom/BeforeTextInsertedEvent.cpp:
57652        * dom/BeforeTextInsertedEvent.h:
57653        * dom/BeforeUnloadEvent.cpp:
57654        * dom/BeforeUnloadEvent.h:
57655        * dom/BeforeUnloadEvent.idl:
57656        * dom/ClassNodeList.cpp:
57657        * dom/ClassNodeList.h:
57658        * dom/ClientRect.cpp:
57659        * dom/ClientRect.h:
57660        * dom/ClientRect.idl:
57661        * dom/ClientRectList.cpp:
57662        * dom/ClientRectList.h:
57663        * dom/ClientRectList.idl:
57664        * dom/Clipboard.cpp:
57665        * dom/Clipboard.idl:
57666        * dom/ClipboardAccessPolicy.h:
57667        * dom/ClipboardMac.mm:
57668        * dom/CompositionEvent.cpp:
57669        * dom/CompositionEvent.h:
57670        * dom/CompositionEvent.idl:
57671        * dom/ContextDestructionObserver.cpp:
57672        * dom/ContextDestructionObserver.h:
57673        * dom/CurrentScriptIncrementer.h:
57674        * dom/CustomEvent.cpp:
57675        * dom/CustomEvent.h:
57676        * dom/CustomEvent.idl:
57677        * dom/DOMCoreException.cpp:
57678        * dom/DOMCoreException.h:
57679        * dom/DOMCoreException.idl:
57680        * dom/DOMError.idl:
57681        * dom/DeviceMotionEvent.cpp:
57682        * dom/DeviceMotionEvent.h:
57683        * dom/DeviceMotionEvent.idl:
57684        * dom/DocumentEventQueue.cpp:
57685        * dom/DocumentEventQueue.h:
57686        * dom/DocumentMarker.h:
57687        * dom/DocumentParser.h:
57688        * dom/DocumentSharedObjectPool.cpp:
57689        * dom/DocumentSharedObjectPool.h:
57690        * dom/Entity.idl:
57691        * dom/EventContext.cpp:
57692        * dom/EventContext.h:
57693        * dom/EventException.cpp:
57694        * dom/EventException.h:
57695        * dom/EventException.idl:
57696        * dom/EventListener.idl:
57697        * dom/EventListenerMap.cpp:
57698        * dom/EventListenerMap.h:
57699        * dom/EventNames.cpp:
57700        * dom/EventQueue.h:
57701        * dom/EventTarget.cpp:
57702        * dom/EventTarget.h:
57703        * dom/ExceptionBase.cpp:
57704        * dom/ExceptionBase.h:
57705        * dom/GenericEventQueue.cpp:
57706        * dom/GenericEventQueue.h:
57707        * dom/KeyboardEvent.idl:
57708        * dom/MessageChannel.cpp:
57709        * dom/MessageChannel.h:
57710        * dom/MessageChannel.idl:
57711        * dom/MessageEvent.cpp:
57712        * dom/MessageEvent.h:
57713        * dom/MessageEvent.idl:
57714        * dom/MessagePort.cpp:
57715        * dom/MessagePort.h:
57716        * dom/MessagePort.idl:
57717        * dom/MouseRelatedEvent.h:
57718        * dom/MutationEvent.idl:
57719        * dom/Notation.idl:
57720        * dom/OverflowEvent.cpp:
57721        * dom/OverflowEvent.h:
57722        * dom/OverflowEvent.idl:
57723        * dom/PopStateEvent.cpp:
57724        * dom/PopStateEvent.h:
57725        * dom/PopStateEvent.idl:
57726        * dom/Position.cpp:
57727        * dom/Position.h:
57728        * dom/ProcessingInstruction.idl:
57729        * dom/ProgressEvent.cpp:
57730        * dom/ProgressEvent.h:
57731        * dom/ProgressEvent.idl:
57732        * dom/Range.idl:
57733        * dom/RangeException.cpp:
57734        * dom/RangeException.h:
57735        * dom/ScriptExecutionContext.cpp:
57736        * dom/ScriptExecutionContext.h:
57737        * dom/SecurityContext.cpp:
57738        * dom/SecurityContext.h:
57739        * dom/StaticNodeList.cpp:
57740        * dom/StaticNodeList.h:
57741        * dom/Text.idl:
57742        * dom/TextEvent.cpp:
57743        * dom/TextEvent.h:
57744        * dom/TextEvent.idl:
57745        * dom/Touch.cpp:
57746        * dom/Touch.h:
57747        * dom/Touch.idl:
57748        * dom/TouchEvent.cpp:
57749        * dom/TouchEvent.h:
57750        * dom/TouchEvent.idl:
57751        * dom/TouchList.cpp:
57752        * dom/TouchList.h:
57753        * dom/TouchList.idl:
57754        * dom/TransitionEvent.cpp:
57755        * dom/TransitionEvent.h:
57756        * dom/TransitionEvent.idl:
57757        * dom/TreeWalker.idl:
57758        * dom/UIEvent.idl:
57759        * dom/UIEventWithKeyState.cpp:
57760        * dom/WebKitAnimationEvent.cpp:
57761        * dom/WebKitAnimationEvent.h:
57762        * dom/WebKitAnimationEvent.idl:
57763        * dom/WebKitTransitionEvent.cpp:
57764        * dom/WebKitTransitionEvent.h:
57765        * dom/WebKitTransitionEvent.idl:
57766        * dom/make_dom_exceptions.pl:
57767        * dom/make_event_factory.pl:
57768        * dom/make_names.pl:
57769        (printLicenseHeader):
57770        * editing/AlternativeTextController.cpp:
57771        * editing/AlternativeTextController.h:
57772        * editing/AppendNodeCommand.cpp:
57773        * editing/AppendNodeCommand.h:
57774        * editing/ApplyStyleCommand.cpp:
57775        * editing/ApplyStyleCommand.h:
57776        * editing/BreakBlockquoteCommand.cpp:
57777        * editing/BreakBlockquoteCommand.h:
57778        * editing/CompositeEditCommand.cpp:
57779        * editing/CompositeEditCommand.h:
57780        * editing/CreateLinkCommand.cpp:
57781        * editing/CreateLinkCommand.h:
57782        * editing/DeleteButton.cpp:
57783        * editing/DeleteButton.h:
57784        * editing/DeleteButtonController.cpp:
57785        * editing/DeleteButtonController.h:
57786        * editing/DeleteFromTextNodeCommand.cpp:
57787        * editing/DeleteFromTextNodeCommand.h:
57788        * editing/DeleteSelectionCommand.cpp:
57789        * editing/DeleteSelectionCommand.h:
57790        * editing/EditAction.h:
57791        * editing/EditCommand.cpp:
57792        * editing/EditCommand.h:
57793        * editing/EditingBoundary.h:
57794        * editing/EditingStyle.cpp:
57795        * editing/Editor.cpp:
57796        * editing/Editor.h:
57797        * editing/EditorCommand.cpp:
57798        * editing/EditorDeleteAction.h:
57799        * editing/EditorInsertAction.h:
57800        * editing/FormatBlockCommand.cpp:
57801        * editing/FormatBlockCommand.h:
57802        * editing/FrameSelection.cpp:
57803        * editing/FrameSelection.h:
57804        * editing/HTMLInterchange.cpp:
57805        * editing/HTMLInterchange.h:
57806        * editing/IndentOutdentCommand.cpp:
57807        * editing/IndentOutdentCommand.h:
57808        * editing/InsertIntoTextNodeCommand.cpp:
57809        * editing/InsertIntoTextNodeCommand.h:
57810        * editing/InsertLineBreakCommand.cpp:
57811        * editing/InsertLineBreakCommand.h:
57812        * editing/InsertListCommand.cpp:
57813        * editing/InsertListCommand.h:
57814        * editing/InsertNodeBeforeCommand.cpp:
57815        * editing/InsertNodeBeforeCommand.h:
57816        * editing/InsertParagraphSeparatorCommand.cpp:
57817        * editing/InsertParagraphSeparatorCommand.h:
57818        * editing/InsertTextCommand.cpp:
57819        * editing/InsertTextCommand.h:
57820        * editing/MarkupAccumulator.h:
57821        * editing/MergeIdenticalElementsCommand.cpp:
57822        * editing/MergeIdenticalElementsCommand.h:
57823        * editing/ModifySelectionListLevel.cpp:
57824        * editing/ModifySelectionListLevel.h:
57825        * editing/MoveSelectionCommand.cpp:
57826        * editing/MoveSelectionCommand.h:
57827        * editing/RemoveCSSPropertyCommand.cpp:
57828        * editing/RemoveCSSPropertyCommand.h:
57829        * editing/RemoveFormatCommand.cpp:
57830        * editing/RemoveFormatCommand.h:
57831        * editing/RemoveNodeCommand.cpp:
57832        * editing/RemoveNodeCommand.h:
57833        * editing/RemoveNodePreservingChildrenCommand.cpp:
57834        * editing/RemoveNodePreservingChildrenCommand.h:
57835        * editing/ReplaceSelectionCommand.cpp:
57836        * editing/ReplaceSelectionCommand.h:
57837        * editing/SetNodeAttributeCommand.cpp:
57838        * editing/SetNodeAttributeCommand.h:
57839        * editing/SetSelectionCommand.cpp:
57840        * editing/SetSelectionCommand.h:
57841        * editing/SimplifyMarkupCommand.cpp:
57842        * editing/SimplifyMarkupCommand.h:
57843        * editing/SmartReplace.cpp:
57844        * editing/SmartReplace.h:
57845        * editing/SmartReplaceCF.cpp:
57846        * editing/SpellChecker.cpp:
57847        * editing/SpellChecker.h:
57848        * editing/SpellingCorrectionCommand.cpp:
57849        * editing/SpellingCorrectionCommand.h:
57850        * editing/SplitElementCommand.cpp:
57851        * editing/SplitElementCommand.h:
57852        * editing/SplitTextNodeCommand.cpp:
57853        * editing/SplitTextNodeCommand.h:
57854        * editing/SplitTextNodeContainingElementCommand.cpp:
57855        * editing/SplitTextNodeContainingElementCommand.h:
57856        * editing/TextAffinity.h:
57857        * editing/TextCheckingHelper.cpp:
57858        * editing/TextGranularity.h:
57859        * editing/TextIterator.cpp:
57860        * editing/TextIterator.h:
57861        * editing/TextIteratorBehavior.h:
57862        * editing/TypingCommand.cpp:
57863        * editing/TypingCommand.h:
57864        * editing/UnlinkCommand.cpp:
57865        * editing/UnlinkCommand.h:
57866        * editing/VisiblePosition.cpp:
57867        * editing/VisiblePosition.h:
57868        * editing/VisibleSelection.cpp:
57869        * editing/VisibleSelection.h:
57870        * editing/VisibleUnits.cpp:
57871        * editing/VisibleUnits.h:
57872        * editing/WrapContentsInDummySpanCommand.cpp:
57873        * editing/WrapContentsInDummySpanCommand.h:
57874        * editing/WritingDirection.h:
57875        * editing/efl/EditorEfl.cpp:
57876        * editing/htmlediting.cpp:
57877        * editing/htmlediting.h:
57878        * editing/mac/EditorMac.mm:
57879        * editing/mac/FrameSelectionMac.mm:
57880        * editing/markup.cpp:
57881        * editing/markup.h:
57882        * extract-localizable-strings.pl:
57883        * fileapi/FileException.cpp:
57884        * history/BackForwardClient.h:
57885        * history/BackForwardList.cpp:
57886        * history/BackForwardList.h:
57887        * history/CachedFrame.cpp:
57888        * history/CachedFrame.h:
57889        * history/CachedFramePlatformData.h:
57890        * history/CachedPage.cpp:
57891        * history/CachedPage.h:
57892        * history/HistoryItem.cpp:
57893        * history/HistoryItem.h:
57894        * history/PageCache.cpp:
57895        * history/PageCache.h:
57896        * history/mac/HistoryItemMac.mm:
57897        * html/FTPDirectoryDocument.cpp:
57898        * html/FTPDirectoryDocument.h:
57899        * html/HTMLAudioElement.cpp:
57900        * html/HTMLAudioElement.h:
57901        * html/HTMLAudioElement.idl:
57902        * html/HTMLCanvasElement.cpp:
57903        * html/HTMLCanvasElement.h:
57904        * html/HTMLCanvasElement.idl:
57905        * html/HTMLFieldSetElement.idl:
57906        * html/HTMLImageLoader.h:
57907        * html/HTMLMediaElement.cpp:
57908        * html/HTMLMediaElement.h:
57909        * html/HTMLMediaElement.idl:
57910        * html/HTMLOptionsCollection.cpp:
57911        * html/HTMLPlugInElement.cpp:
57912        * html/HTMLSourceElement.cpp:
57913        * html/HTMLSourceElement.h:
57914        * html/HTMLSourceElement.idl:
57915        * html/HTMLTablePartElement.cpp:
57916        * html/HTMLTableRowsCollection.cpp:
57917        * html/HTMLTableRowsCollection.h:
57918        * html/HTMLTitleElement.idl:
57919        * html/HTMLTrackElement.cpp:
57920        * html/HTMLTrackElement.h:
57921        * html/HTMLTrackElement.idl:
57922        * html/HTMLVideoElement.cpp:
57923        * html/HTMLVideoElement.h:
57924        * html/HTMLVideoElement.idl:
57925        * html/ImageData.cpp:
57926        * html/ImageData.h:
57927        * html/ImageData.idl:
57928        * html/ImageDocument.cpp:
57929        * html/ImageDocument.h:
57930        * html/MediaController.cpp:
57931        * html/MediaController.h:
57932        * html/MediaController.idl:
57933        * html/MediaControllerInterface.h:
57934        * html/MediaError.h:
57935        * html/MediaError.idl:
57936        * html/MediaFragmentURIParser.cpp:
57937        * html/MediaFragmentURIParser.h:
57938        * html/MediaKeyError.h:
57939        * html/MediaKeyError.idl:
57940        * html/MediaKeyEvent.cpp:
57941        * html/MediaKeyEvent.h:
57942        * html/MediaKeyEvent.idl:
57943        * html/PluginDocument.cpp:
57944        * html/PluginDocument.h:
57945        * html/TextDocument.cpp:
57946        * html/TextDocument.h:
57947        * html/TimeRanges.cpp:
57948        * html/TimeRanges.h:
57949        * html/TimeRanges.idl:
57950        * html/VoidCallback.h:
57951        * html/VoidCallback.idl:
57952        * html/canvas/CanvasGradient.cpp:
57953        * html/canvas/CanvasGradient.h:
57954        * html/canvas/CanvasGradient.idl:
57955        * html/canvas/CanvasPattern.cpp:
57956        * html/canvas/CanvasPattern.h:
57957        * html/canvas/CanvasPattern.idl:
57958        * html/canvas/CanvasRenderingContext.cpp:
57959        * html/canvas/CanvasRenderingContext.h:
57960        * html/canvas/CanvasRenderingContext.idl:
57961        * html/canvas/CanvasRenderingContext2D.cpp:
57962        * html/canvas/CanvasRenderingContext2D.h:
57963        * html/canvas/CanvasRenderingContext2D.idl:
57964        * html/canvas/CanvasStyle.cpp:
57965        * html/canvas/CanvasStyle.h:
57966        * html/canvas/DOMPath.idl:
57967        * html/canvas/OESVertexArrayObject.cpp:
57968        * html/canvas/OESVertexArrayObject.h:
57969        * html/canvas/OESVertexArrayObject.idl:
57970        * html/canvas/WebGLBuffer.cpp:
57971        * html/canvas/WebGLBuffer.h:
57972        * html/canvas/WebGLBuffer.idl:
57973        * html/canvas/WebGLContextGroup.cpp:
57974        * html/canvas/WebGLContextGroup.h:
57975        * html/canvas/WebGLContextObject.cpp:
57976        * html/canvas/WebGLContextObject.h:
57977        * html/canvas/WebGLFramebuffer.cpp:
57978        * html/canvas/WebGLFramebuffer.h:
57979        * html/canvas/WebGLFramebuffer.idl:
57980        * html/canvas/WebGLObject.cpp:
57981        * html/canvas/WebGLObject.h:
57982        * html/canvas/WebGLProgram.cpp:
57983        * html/canvas/WebGLProgram.h:
57984        * html/canvas/WebGLProgram.idl:
57985        * html/canvas/WebGLRenderbuffer.cpp:
57986        * html/canvas/WebGLRenderbuffer.h:
57987        * html/canvas/WebGLRenderbuffer.idl:
57988        * html/canvas/WebGLRenderingContext.cpp:
57989        * html/canvas/WebGLRenderingContext.h:
57990        * html/canvas/WebGLRenderingContext.idl:
57991        * html/canvas/WebGLShader.cpp:
57992        * html/canvas/WebGLShader.h:
57993        * html/canvas/WebGLShader.idl:
57994        * html/canvas/WebGLSharedObject.cpp:
57995        * html/canvas/WebGLSharedObject.h:
57996        * html/canvas/WebGLTexture.cpp:
57997        * html/canvas/WebGLTexture.h:
57998        * html/canvas/WebGLTexture.idl:
57999        * html/canvas/WebGLUniformLocation.cpp:
58000        * html/canvas/WebGLUniformLocation.h:
58001        * html/canvas/WebGLUniformLocation.idl:
58002        * html/canvas/WebGLVertexArrayObjectOES.cpp:
58003        * html/canvas/WebGLVertexArrayObjectOES.h:
58004        * html/canvas/WebGLVertexArrayObjectOES.idl:
58005        * html/forms/FileIconLoader.cpp:
58006        * html/forms/FileIconLoader.h:
58007        * html/parser/TextDocumentParser.cpp:
58008        * html/parser/TextDocumentParser.h:
58009        * html/shadow/MediaControlElementTypes.cpp:
58010        * html/shadow/MediaControlElementTypes.h:
58011        * html/shadow/MediaControlElements.cpp:
58012        * html/shadow/MediaControlElements.h:
58013        * html/shadow/MediaControls.cpp:
58014        * html/shadow/MediaControls.h:
58015        * html/shadow/MediaControlsApple.cpp:
58016        * html/shadow/MediaControlsApple.h:
58017        * html/shadow/MediaControlsGtk.cpp:
58018        * html/shadow/MediaControlsGtk.h:
58019        * html/shadow/SpinButtonElement.cpp:
58020        * html/shadow/SpinButtonElement.h:
58021        * html/shadow/TextControlInnerElements.cpp:
58022        * html/shadow/TextControlInnerElements.h:
58023        * html/track/AudioTrack.h:
58024        * html/track/AudioTrack.idl:
58025        * html/track/AudioTrackList.cpp:
58026        * html/track/AudioTrackList.h:
58027        * html/track/AudioTrackList.idl:
58028        * html/track/DataCue.cpp:
58029        * html/track/DataCue.h:
58030        * html/track/DataCue.idl:
58031        * html/track/InbandGenericTextTrack.cpp:
58032        * html/track/InbandGenericTextTrack.h:
58033        * html/track/InbandTextTrack.cpp:
58034        * html/track/InbandTextTrack.h:
58035        * html/track/InbandWebVTTTextTrack.cpp:
58036        * html/track/InbandWebVTTTextTrack.h:
58037        * html/track/LoadableTextTrack.cpp:
58038        * html/track/LoadableTextTrack.h:
58039        * html/track/TextTrack.h:
58040        * html/track/TextTrack.idl:
58041        * html/track/TextTrackCue.idl:
58042        * html/track/TextTrackCueGeneric.cpp:
58043        * html/track/TextTrackCueGeneric.h:
58044        * html/track/TextTrackCueList.cpp:
58045        * html/track/TextTrackCueList.h:
58046        * html/track/TextTrackCueList.idl:
58047        * html/track/TextTrackList.cpp:
58048        * html/track/TextTrackList.h:
58049        * html/track/TextTrackList.idl:
58050        * html/track/TextTrackRegion.idl:
58051        * html/track/TextTrackRegionList.cpp:
58052        * html/track/TextTrackRegionList.h:
58053        * html/track/TextTrackRegionList.idl:
58054        * html/track/TrackBase.cpp:
58055        * html/track/TrackBase.h:
58056        * html/track/TrackEvent.cpp:
58057        * html/track/TrackEvent.h:
58058        * html/track/TrackEvent.idl:
58059        * html/track/TrackListBase.cpp:
58060        * html/track/TrackListBase.h:
58061        * html/track/VTTCue.idl:
58062        * html/track/VideoTrack.h:
58063        * html/track/VideoTrack.idl:
58064        * html/track/VideoTrackList.cpp:
58065        * html/track/VideoTrackList.h:
58066        * html/track/VideoTrackList.idl:
58067        * html/track/WebVTTElement.cpp:
58068        * html/track/WebVTTElement.h:
58069        * inspector/CommandLineAPIHost.cpp:
58070        * inspector/CommandLineAPIHost.h:
58071        * inspector/CommandLineAPIModuleSource.js:
58072        * inspector/InspectorAllInOne.cpp:
58073        * inspector/InspectorClient.h:
58074        * inspector/InspectorDOMAgent.cpp:
58075        * inspector/InspectorDOMAgent.h:
58076        * inspector/InspectorDOMStorageAgent.cpp:
58077        * inspector/InspectorDOMStorageAgent.h:
58078        * inspector/InspectorDatabaseAgent.cpp:
58079        * inspector/InspectorDatabaseAgent.h:
58080        * inspector/InspectorDatabaseResource.cpp:
58081        * inspector/InspectorDatabaseResource.h:
58082        * inspector/InspectorForwarding.h:
58083        * inspector/InspectorFrontendHost.cpp:
58084        * inspector/InspectorFrontendHost.h:
58085        * inspector/InspectorLayerTreeAgent.h:
58086        * inspector/InspectorNodeFinder.cpp:
58087        * inspector/InspectorNodeFinder.h:
58088        * inspector/InspectorOverlay.cpp:
58089        * inspector/InspectorOverlay.h:
58090        * inspector/InspectorOverlayPage.html:
58091        * inspector/InspectorProfilerAgent.cpp:
58092        * inspector/InspectorProfilerAgent.h:
58093        * inspector/ScriptProfile.idl:
58094        * inspector/ScriptProfileNode.idl:
58095        * loader/CookieJar.h:
58096        * loader/CrossOriginAccessControl.cpp:
58097        * loader/CrossOriginAccessControl.h:
58098        * loader/CrossOriginPreflightResultCache.cpp:
58099        * loader/CrossOriginPreflightResultCache.h:
58100        * loader/DocumentLoader.cpp:
58101        * loader/DocumentLoader.h:
58102        * loader/DocumentWriter.cpp:
58103        * loader/EmptyClients.h:
58104        * loader/FormState.cpp:
58105        * loader/FormState.h:
58106        * loader/FrameLoadRequest.h:
58107        * loader/FrameLoader.cpp:
58108        * loader/FrameLoader.h:
58109        * loader/FrameLoaderClient.h:
58110        * loader/FrameLoaderTypes.h:
58111        * loader/HistoryController.cpp:
58112        * loader/HistoryController.h:
58113        * loader/MixedContentChecker.cpp:
58114        * loader/NavigationAction.cpp:
58115        * loader/NavigationAction.h:
58116        * loader/NavigationScheduler.cpp:
58117        * loader/NavigationScheduler.h:
58118        * loader/NetscapePlugInStreamLoader.cpp:
58119        * loader/NetscapePlugInStreamLoader.h:
58120        * loader/PolicyCallback.cpp:
58121        * loader/PolicyCallback.h:
58122        * loader/PolicyChecker.cpp:
58123        * loader/PolicyChecker.h:
58124        * loader/ProgressTracker.cpp:
58125        * loader/ProgressTracker.h:
58126        * loader/ResourceBuffer.cpp:
58127        * loader/ResourceBuffer.h:
58128        * loader/ResourceLoadNotifier.cpp:
58129        * loader/ResourceLoadNotifier.h:
58130        * loader/ResourceLoader.cpp:
58131        * loader/ResourceLoader.h:
58132        * loader/SinkDocument.cpp:
58133        * loader/SinkDocument.h:
58134        * loader/SubframeLoader.cpp:
58135        * loader/SubframeLoader.h:
58136        * loader/SubresourceLoader.cpp:
58137        * loader/SubresourceLoader.h:
58138        * loader/SubstituteData.h:
58139        * loader/TextTrackLoader.cpp:
58140        * loader/appcache/ApplicationCacheAllInOne.cpp:
58141        * loader/archive/Archive.cpp:
58142        * loader/archive/Archive.h:
58143        * loader/archive/ArchiveFactory.cpp:
58144        * loader/archive/ArchiveFactory.h:
58145        * loader/archive/ArchiveResource.cpp:
58146        * loader/archive/ArchiveResource.h:
58147        * loader/archive/ArchiveResourceCollection.cpp:
58148        * loader/archive/ArchiveResourceCollection.h:
58149        * loader/archive/cf/LegacyWebArchive.cpp:
58150        * loader/archive/cf/LegacyWebArchive.h:
58151        * loader/archive/cf/LegacyWebArchiveMac.mm:
58152        * loader/cache/CachePolicy.h:
58153        * loader/cache/CachedCSSStyleSheet.cpp:
58154        * loader/cache/CachedFont.cpp:
58155        * loader/cache/CachedFont.h:
58156        * loader/cache/CachedResourceRequest.cpp:
58157        * loader/cache/CachedResourceRequest.h:
58158        * loader/cache/CachedResourceRequestInitiators.cpp:
58159        * loader/cache/CachedResourceRequestInitiators.h:
58160        * loader/cf/ResourceLoaderCFNet.cpp:
58161        * loader/icon/IconController.cpp:
58162        * loader/icon/IconController.h:
58163        * loader/icon/IconDatabase.cpp:
58164        * loader/icon/IconDatabase.h:
58165        * loader/icon/IconDatabaseBase.cpp:
58166        * loader/icon/IconDatabaseBase.h:
58167        * loader/icon/IconDatabaseClient.h:
58168        * loader/icon/IconLoader.cpp:
58169        * loader/icon/IconLoader.h:
58170        * loader/icon/IconRecord.cpp:
58171        * loader/icon/IconRecord.h:
58172        * loader/icon/PageURLRecord.cpp:
58173        * loader/icon/PageURLRecord.h:
58174        * loader/mac/DocumentLoaderMac.cpp:
58175        * loader/mac/LoaderNSURLExtras.h:
58176        * loader/mac/LoaderNSURLExtras.mm:
58177        * loader/mac/ResourceBuffer.mm:
58178        * loader/mac/ResourceLoaderMac.mm:
58179        * loader/win/DocumentLoaderWin.cpp:
58180        * loader/win/FrameLoaderWin.cpp:
58181        * mathml/MathMLAllInOne.cpp:
58182        * page/AbstractView.idl:
58183        * page/AlternativeTextClient.h:
58184        * page/AutoscrollController.cpp:
58185        * page/AutoscrollController.h:
58186        * page/BarProp.cpp:
58187        * page/BarProp.h:
58188        * page/BarProp.idl:
58189        * page/ContentSecurityPolicy.cpp:
58190        * page/ContentSecurityPolicy.h:
58191        * page/ContextMenuClient.h:
58192        * page/ContextMenuContext.cpp:
58193        * page/ContextMenuContext.h:
58194        * page/ContextMenuController.cpp:
58195        * page/ContextMenuController.h:
58196        * page/DOMSecurityPolicy.cpp:
58197        * page/DOMSecurityPolicy.h:
58198        * page/DOMSelection.cpp:
58199        * page/DOMSelection.h:
58200        * page/DOMSelection.idl:
58201        * page/DOMTimer.cpp:
58202        * page/DOMTimer.h:
58203        * page/DOMWindow.cpp:
58204        * page/DOMWindow.h:
58205        * page/DOMWindow.idl:
58206        * page/DragActions.h:
58207        * page/DragClient.h:
58208        * page/DragController.cpp:
58209        * page/DragController.h:
58210        * page/DragSession.h:
58211        * page/DragState.h:
58212        * page/EditorClient.h:
58213        * page/EventHandler.cpp:
58214        * page/EventHandler.h:
58215        * page/FocusController.cpp:
58216        * page/FocusController.h:
58217        * page/FocusDirection.h:
58218        * page/FrameTree.h:
58219        * page/GestureTapHighlighter.cpp:
58220        * page/GestureTapHighlighter.h:
58221        * page/History.cpp:
58222        * page/History.h:
58223        * page/History.idl:
58224        * page/Location.cpp:
58225        * page/Location.h:
58226        * page/Location.idl:
58227        * page/MouseEventWithHitTestResults.cpp:
58228        * page/MouseEventWithHitTestResults.h:
58229        * page/Navigator.cpp:
58230        * page/NavigatorBase.cpp:
58231        * page/NavigatorBase.h:
58232        * page/PageConsole.cpp:
58233        * page/PageConsole.h:
58234        * page/Screen.cpp:
58235        * page/Screen.h:
58236        * page/Screen.idl:
58237        * page/SecurityOrigin.cpp:
58238        * page/SecurityOrigin.h:
58239        * page/SecurityOriginHash.h:
58240        * page/Settings.cpp:
58241        * page/Settings.h:
58242        * page/SpatialNavigation.cpp:
58243        * page/SuspendableTimer.cpp:
58244        * page/SuspendableTimer.h:
58245        * page/UserContentTypes.h:
58246        * page/UserContentURLPattern.cpp:
58247        * page/UserContentURLPattern.h:
58248        * page/UserScript.h:
58249        * page/UserScriptTypes.h:
58250        * page/UserStyleSheet.h:
58251        * page/UserStyleSheetTypes.h:
58252        * page/WebCoreKeyboardUIMode.h:
58253        * page/WebKitPoint.h:
58254        * page/WebKitPoint.idl:
58255        * page/WindowBase64.idl:
58256        * page/WindowFeatures.h:
58257        * page/WindowFocusAllowedIndicator.cpp:
58258        * page/WindowFocusAllowedIndicator.h:
58259        * page/WindowTimers.idl:
58260        * page/WorkerNavigator.cpp:
58261        * page/WorkerNavigator.h:
58262        * page/WorkerNavigator.idl:
58263        * page/animation/AnimationBase.cpp:
58264        * page/animation/AnimationBase.h:
58265        * page/animation/AnimationController.cpp:
58266        * page/animation/AnimationController.h:
58267        * page/animation/AnimationControllerPrivate.h:
58268        * page/animation/CSSPropertyAnimation.cpp:
58269        * page/animation/CSSPropertyAnimation.h:
58270        * page/animation/CompositeAnimation.cpp:
58271        * page/animation/CompositeAnimation.h:
58272        * page/animation/ImplicitAnimation.cpp:
58273        * page/animation/ImplicitAnimation.h:
58274        * page/animation/KeyframeAnimation.cpp:
58275        * page/animation/KeyframeAnimation.h:
58276        * page/efl/DragControllerEfl.cpp:
58277        * page/efl/EventHandlerEfl.cpp:
58278        * page/gtk/DragControllerGtk.cpp:
58279        * page/gtk/EventHandlerGtk.cpp:
58280        * page/ios/EventHandlerIOS.mm:
58281        * page/mac/DragControllerMac.mm:
58282        * page/mac/EventHandlerMac.mm:
58283        * page/mac/PageMac.cpp:
58284        * page/mac/WebCoreFrameView.h:
58285        * page/make_settings.pl:
58286        * page/win/DragControllerWin.cpp:
58287        * page/win/EventHandlerWin.cpp:
58288        * page/win/FrameCGWin.cpp:
58289        * page/win/FrameCairoWin.cpp:
58290        * page/win/FrameGdiWin.cpp:
58291        * page/win/FrameWin.cpp:
58292        * page/win/FrameWin.h:
58293        * pdf/ios/PDFDocument.h:
58294        * platform/Clock.cpp:
58295        * platform/Clock.h:
58296        * platform/ClockGeneric.cpp:
58297        * platform/ClockGeneric.h:
58298        * platform/ColorChooser.h:
58299        * platform/ColorChooserClient.h:
58300        * platform/ContentType.cpp:
58301        * platform/ContentType.h:
58302        * platform/ContextMenu.h:
58303        * platform/ContextMenuItem.h:
58304        * platform/Cookie.h:
58305        * platform/Cursor.h:
58306        * platform/DragData.cpp:
58307        * platform/DragData.h:
58308        * platform/DragImage.cpp:
58309        * platform/DragImage.h:
58310        * platform/FileChooser.cpp:
58311        * platform/FileChooser.h:
58312        * platform/FileSystem.h:
58313        * platform/FloatConversion.h:
58314        * platform/KillRing.h:
58315        * platform/LinkHash.h:
58316        * platform/LocalizedStrings.cpp:
58317        * platform/LocalizedStrings.h:
58318        * platform/Logging.cpp:
58319        * platform/Logging.h:
58320        * platform/MIMETypeRegistry.cpp:
58321        * platform/MIMETypeRegistry.h:
58322        * platform/MediaDescription.h:
58323        * platform/MediaSample.h:
58324        * platform/NotImplemented.h:
58325        * platform/PODFreeListArena.h:
58326        * platform/Pasteboard.h:
58327        * platform/PasteboardStrategy.h:
58328        * platform/PlatformExportMacros.h:
58329        * platform/PlatformKeyboardEvent.h:
58330        * platform/PlatformMenuDescription.h:
58331        * platform/PlatformMouseEvent.h:
58332        * platform/PlatformPasteboard.h:
58333        * platform/PlatformScreen.h:
58334        * platform/PlatformSpeechSynthesis.h:
58335        * platform/PlatformSpeechSynthesisUtterance.cpp:
58336        * platform/PlatformSpeechSynthesisUtterance.h:
58337        * platform/PlatformSpeechSynthesisVoice.cpp:
58338        * platform/PlatformSpeechSynthesisVoice.h:
58339        * platform/PlatformSpeechSynthesizer.cpp:
58340        * platform/PlatformSpeechSynthesizer.h:
58341        * platform/PlatformWheelEvent.h:
58342        * platform/PopupMenuClient.h:
58343        * platform/RemoteCommandListener.cpp:
58344        * platform/RemoteCommandListener.h:
58345        * platform/SSLKeyGenerator.h:
58346        * platform/SchemeRegistry.cpp:
58347        * platform/SchemeRegistry.h:
58348        * platform/ScrollTypes.h:
58349        * platform/ScrollView.cpp:
58350        * platform/ScrollView.h:
58351        * platform/Scrollbar.cpp:
58352        * platform/Scrollbar.h:
58353        * platform/SharedBuffer.cpp:
58354        * platform/SharedBuffer.h:
58355        * platform/SharedTimer.h:
58356        * platform/Sound.h:
58357        * platform/ThreadCheck.h:
58358        * platform/ThreadGlobalData.cpp:
58359        * platform/ThreadGlobalData.h:
58360        * platform/ThreadTimers.cpp:
58361        * platform/ThreadTimers.h:
58362        * platform/Timer.cpp:
58363        * platform/Timer.h:
58364        * platform/URL.cpp:
58365        * platform/URL.h:
58366        * platform/Widget.cpp:
58367        * platform/Widget.h:
58368        * platform/animation/AnimationUtilities.h:
58369        * platform/audio/AudioArray.h:
58370        * platform/audio/AudioBus.cpp:
58371        * platform/audio/AudioBus.h:
58372        * platform/audio/AudioChannel.cpp:
58373        * platform/audio/AudioChannel.h:
58374        * platform/audio/AudioDestination.h:
58375        * platform/audio/AudioFIFO.cpp:
58376        * platform/audio/AudioFIFO.h:
58377        * platform/audio/AudioFileReader.h:
58378        * platform/audio/AudioIOCallback.h:
58379        * platform/audio/AudioPullFIFO.cpp:
58380        * platform/audio/AudioPullFIFO.h:
58381        * platform/audio/AudioSourceProvider.h:
58382        * platform/audio/Biquad.cpp:
58383        * platform/audio/Biquad.h:
58384        * platform/audio/Cone.cpp:
58385        * platform/audio/Cone.h:
58386        * platform/audio/DirectConvolver.cpp:
58387        * platform/audio/DirectConvolver.h:
58388        * platform/audio/Distance.cpp:
58389        * platform/audio/Distance.h:
58390        * platform/audio/DownSampler.cpp:
58391        * platform/audio/DownSampler.h:
58392        * platform/audio/DynamicsCompressor.cpp:
58393        * platform/audio/DynamicsCompressor.h:
58394        * platform/audio/DynamicsCompressorKernel.cpp:
58395        * platform/audio/DynamicsCompressorKernel.h:
58396        * platform/audio/FFTConvolver.cpp:
58397        * platform/audio/FFTConvolver.h:
58398        * platform/audio/FFTFrame.cpp:
58399        * platform/audio/FFTFrame.h:
58400        * platform/audio/HRTFDatabase.cpp:
58401        * platform/audio/HRTFDatabase.h:
58402        * platform/audio/HRTFDatabaseLoader.cpp:
58403        * platform/audio/HRTFDatabaseLoader.h:
58404        * platform/audio/HRTFElevation.cpp:
58405        * platform/audio/HRTFElevation.h:
58406        * platform/audio/HRTFKernel.cpp:
58407        * platform/audio/HRTFKernel.h:
58408        * platform/audio/MultiChannelResampler.cpp:
58409        * platform/audio/MultiChannelResampler.h:
58410        * platform/audio/Panner.cpp:
58411        * platform/audio/Panner.h:
58412        * platform/audio/Reverb.cpp:
58413        * platform/audio/Reverb.h:
58414        * platform/audio/ReverbAccumulationBuffer.cpp:
58415        * platform/audio/ReverbAccumulationBuffer.h:
58416        * platform/audio/ReverbConvolver.cpp:
58417        * platform/audio/ReverbConvolver.h:
58418        * platform/audio/ReverbConvolverStage.cpp:
58419        * platform/audio/ReverbConvolverStage.h:
58420        * platform/audio/ReverbInputBuffer.cpp:
58421        * platform/audio/ReverbInputBuffer.h:
58422        * platform/audio/SincResampler.cpp:
58423        * platform/audio/SincResampler.h:
58424        * platform/audio/UpSampler.cpp:
58425        * platform/audio/UpSampler.h:
58426        * platform/audio/ZeroPole.cpp:
58427        * platform/audio/ZeroPole.h:
58428        * platform/audio/ios/AudioDestinationIOS.cpp:
58429        * platform/audio/ios/AudioDestinationIOS.h:
58430        * platform/audio/ios/AudioFileReaderIOS.cpp:
58431        * platform/audio/ios/AudioFileReaderIOS.h:
58432        * platform/audio/mac/AudioDestinationMac.cpp:
58433        * platform/audio/mac/AudioDestinationMac.h:
58434        * platform/audio/mac/AudioFileReaderMac.cpp:
58435        * platform/audio/mac/AudioFileReaderMac.h:
58436        * platform/audio/mac/FFTFrameMac.cpp:
58437        * platform/cf/FileSystemCF.cpp:
58438        * platform/cf/SharedBufferCF.cpp:
58439        * platform/cf/URLCF.cpp:
58440        * platform/cocoa/KeyEventCocoa.h:
58441        * platform/cocoa/KeyEventCocoa.mm:
58442        * platform/efl/CursorEfl.cpp:
58443        * platform/efl/EflKeyboardUtilities.cpp:
58444        * platform/efl/EflKeyboardUtilities.h:
58445        * platform/efl/FileSystemEfl.cpp:
58446        * platform/efl/LanguageEfl.cpp:
58447        * platform/efl/LocalizedStringsEfl.cpp:
58448        * platform/efl/MIMETypeRegistryEfl.cpp:
58449        * platform/efl/PlatformKeyboardEventEfl.cpp:
58450        * platform/efl/PlatformMouseEventEfl.cpp:
58451        * platform/efl/PlatformScreenEfl.cpp:
58452        * platform/efl/PlatformWheelEventEfl.cpp:
58453        * platform/efl/RenderThemeEfl.h:
58454        * platform/efl/ScrollbarEfl.h:
58455        * platform/efl/SharedTimerEfl.cpp:
58456        * platform/efl/SoundEfl.cpp:
58457        * platform/efl/TemporaryLinkStubs.cpp:
58458        * platform/efl/WidgetEfl.cpp:
58459        * platform/graphics/ANGLEWebKitBridge.cpp:
58460        * platform/graphics/ANGLEWebKitBridge.h:
58461        * platform/graphics/AudioTrackPrivate.h:
58462        * platform/graphics/BitmapImage.cpp:
58463        * platform/graphics/BitmapImage.h:
58464        * platform/graphics/Color.cpp:
58465        * platform/graphics/Color.h:
58466        * platform/graphics/CrossfadeGeneratedImage.cpp:
58467        * platform/graphics/CrossfadeGeneratedImage.h:
58468        * platform/graphics/DashArray.h:
58469        * platform/graphics/DisplayRefreshMonitor.cpp:
58470        * platform/graphics/DisplayRefreshMonitor.h:
58471        * platform/graphics/FloatPoint.cpp:
58472        * platform/graphics/FloatPoint.h:
58473        * platform/graphics/FloatQuad.cpp:
58474        * platform/graphics/FloatQuad.h:
58475        * platform/graphics/FloatRect.cpp:
58476        * platform/graphics/FloatRect.h:
58477        * platform/graphics/FloatSize.cpp:
58478        * platform/graphics/FloatSize.h:
58479        * platform/graphics/FontBaseline.h:
58480        * platform/graphics/FontCache.cpp:
58481        * platform/graphics/FontCache.h:
58482        * platform/graphics/FontData.cpp:
58483        * platform/graphics/FontData.h:
58484        * platform/graphics/FontDescription.cpp:
58485        * platform/graphics/FontFeatureSettings.cpp:
58486        * platform/graphics/FontFeatureSettings.h:
58487        * platform/graphics/FontGlyphs.cpp:
58488        * platform/graphics/FontOrientation.h:
58489        * platform/graphics/FontRenderingMode.h:
58490        * platform/graphics/FontSelector.h:
58491        * platform/graphics/FontWidthVariant.h:
58492        * platform/graphics/FormatConverter.cpp:
58493        * platform/graphics/FormatConverter.h:
58494        * platform/graphics/GeneratedImage.h:
58495        * platform/graphics/Glyph.h:
58496        * platform/graphics/GlyphBuffer.h:
58497        * platform/graphics/GlyphMetricsMap.h:
58498        * platform/graphics/GlyphPage.h:
58499        * platform/graphics/GlyphPageTreeNode.cpp:
58500        * platform/graphics/GlyphPageTreeNode.h:
58501        * platform/graphics/Gradient.cpp:
58502        * platform/graphics/Gradient.h:
58503        * platform/graphics/GradientImage.h:
58504        * platform/graphics/GraphicsContext.h:
58505        * platform/graphics/GraphicsContext3D.cpp:
58506        * platform/graphics/GraphicsContext3D.h:
58507        * platform/graphics/GraphicsLayer.cpp:
58508        * platform/graphics/GraphicsLayer.h:
58509        * platform/graphics/GraphicsLayerClient.h:
58510        * platform/graphics/GraphicsTypes.cpp:
58511        * platform/graphics/GraphicsTypes.h:
58512        * platform/graphics/GraphicsTypes3D.h:
58513        * platform/graphics/Image.cpp:
58514        * platform/graphics/Image.h:
58515        * platform/graphics/ImageBuffer.cpp:
58516        * platform/graphics/ImageBuffer.h:
58517        * platform/graphics/ImageBufferData.h:
58518        * platform/graphics/ImageObserver.h:
58519        * platform/graphics/ImageSource.cpp:
58520        * platform/graphics/ImageSource.h:
58521        * platform/graphics/InbandTextTrackPrivate.h:
58522        * platform/graphics/InbandTextTrackPrivateClient.h:
58523        * platform/graphics/IntPoint.cpp:
58524        * platform/graphics/IntPoint.h:
58525        * platform/graphics/IntSize.cpp:
58526        * platform/graphics/IntSize.h:
58527        * platform/graphics/MediaPlayer.cpp:
58528        * platform/graphics/MediaPlayer.h:
58529        * platform/graphics/MediaPlayerPrivate.h:
58530        * platform/graphics/MediaSourcePrivateClient.h:
58531        * platform/graphics/NativeImagePtr.h:
58532        * platform/graphics/OpenGLESShims.h:
58533        * platform/graphics/Path.cpp:
58534        * platform/graphics/Path.h:
58535        * platform/graphics/PathTraversalState.h:
58536        * platform/graphics/Pattern.cpp:
58537        * platform/graphics/Pattern.h:
58538        * platform/graphics/PlatformLayer.h:
58539        * platform/graphics/PlatformTimeRanges.cpp:
58540        * platform/graphics/PlatformTimeRanges.h:
58541        * platform/graphics/SegmentedFontData.cpp:
58542        * platform/graphics/SegmentedFontData.h:
58543        * platform/graphics/ShadowBlur.cpp:
58544        * platform/graphics/ShadowBlur.h:
58545        * platform/graphics/SimpleFontData.cpp:
58546        * platform/graphics/SourceBufferPrivateClient.h:
58547        * platform/graphics/StringTruncator.cpp:
58548        * platform/graphics/StringTruncator.h:
58549        * platform/graphics/TrackPrivateBase.h:
58550        * platform/graphics/VideoTrackPrivate.h:
58551        * platform/graphics/WindRule.h:
58552        * platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.h:
58553        * platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.mm:
58554        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
58555        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
58556        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
58557        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
58558        * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h:
58559        * platform/graphics/avfoundation/cf/CoreMediaSoftLinking.h:
58560        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.cpp:
58561        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.h:
58562        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateLegacyAVCF.cpp:
58563        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateLegacyAVCF.h:
58564        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
58565        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
58566        * platform/graphics/avfoundation/objc/AudioTrackPrivateMediaSourceAVFObjC.cpp:
58567        * platform/graphics/avfoundation/objc/AudioTrackPrivateMediaSourceAVFObjC.h:
58568        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h:
58569        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
58570        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateLegacyAVFObjC.h:
58571        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateLegacyAVFObjC.mm:
58572        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
58573        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
58574        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
58575        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
58576        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
58577        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
58578        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
58579        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
58580        * platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.h:
58581        * platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.mm:
58582        * platform/graphics/ca/GraphicsLayerCA.cpp:
58583        * platform/graphics/ca/GraphicsLayerCA.h:
58584        * platform/graphics/ca/LayerFlushScheduler.cpp:
58585        * platform/graphics/ca/LayerFlushScheduler.h:
58586        * platform/graphics/ca/LayerFlushSchedulerClient.h:
58587        * platform/graphics/ca/PlatformCAAnimation.h:
58588        * platform/graphics/ca/PlatformCAFilters.h:
58589        * platform/graphics/ca/PlatformCALayer.cpp:
58590        * platform/graphics/ca/PlatformCALayer.h:
58591        * platform/graphics/ca/PlatformCALayerClient.h:
58592        * platform/graphics/ca/TransformationMatrixCA.cpp:
58593        * platform/graphics/ca/mac/LayerFlushSchedulerMac.cpp:
58594        * platform/graphics/ca/mac/LayerPool.mm:
58595        * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
58596        * platform/graphics/ca/mac/PlatformCAFiltersMac.h:
58597        * platform/graphics/ca/mac/PlatformCAFiltersMac.mm:
58598        * platform/graphics/ca/mac/PlatformCALayerMac.h:
58599        * platform/graphics/ca/mac/PlatformCALayerMac.mm:
58600        * platform/graphics/ca/mac/WebTiledBackingLayer.h:
58601        * platform/graphics/ca/mac/WebTiledBackingLayer.mm:
58602        * platform/graphics/ca/win/AbstractCACFLayerTreeHost.h:
58603        * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
58604        * platform/graphics/ca/win/CACFLayerTreeHost.h:
58605        * platform/graphics/ca/win/CACFLayerTreeHostClient.h:
58606        * platform/graphics/ca/win/LayerChangesFlusher.cpp:
58607        * platform/graphics/ca/win/LayerChangesFlusher.h:
58608        * platform/graphics/ca/win/LegacyCACFLayerTreeHost.cpp:
58609        * platform/graphics/ca/win/LegacyCACFLayerTreeHost.h:
58610        * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
58611        * platform/graphics/ca/win/PlatformCAFiltersWin.cpp:
58612        * platform/graphics/ca/win/PlatformCALayerWin.cpp:
58613        * platform/graphics/ca/win/PlatformCALayerWin.h:
58614        * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
58615        * platform/graphics/ca/win/PlatformCALayerWinInternal.h:
58616        * platform/graphics/ca/win/WKCACFViewLayerTreeHost.cpp:
58617        * platform/graphics/ca/win/WKCACFViewLayerTreeHost.h:
58618        * platform/graphics/cairo/BitmapImageCairo.cpp:
58619        * platform/graphics/cairo/CairoUtilities.cpp:
58620        * platform/graphics/cairo/CairoUtilities.h:
58621        * platform/graphics/cairo/DrawingBufferCairo.cpp:
58622        * platform/graphics/cairo/FloatRectCairo.cpp:
58623        * platform/graphics/cairo/FontCairo.cpp:
58624        * platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
58625        * platform/graphics/cairo/GradientCairo.cpp:
58626        * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
58627        * platform/graphics/cairo/GraphicsContextCairo.cpp:
58628        * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
58629        * platform/graphics/cairo/ImageBufferCairo.cpp:
58630        * platform/graphics/cairo/ImageBufferDataCairo.h:
58631        * platform/graphics/cairo/ImageCairo.cpp:
58632        * platform/graphics/cairo/PatternCairo.cpp:
58633        * platform/graphics/cairo/PlatformContextCairo.cpp:
58634        * platform/graphics/cairo/PlatformContextCairo.h:
58635        * platform/graphics/cairo/TransformationMatrixCairo.cpp:
58636        * platform/graphics/cg/BitmapImageCG.cpp:
58637        * platform/graphics/cg/ColorCG.cpp:
58638        * platform/graphics/cg/FloatPointCG.cpp:
58639        * platform/graphics/cg/FloatRectCG.cpp:
58640        * platform/graphics/cg/FloatSizeCG.cpp:
58641        * platform/graphics/cg/GradientCG.cpp:
58642        * platform/graphics/cg/GraphicsContext3DCG.cpp:
58643        * platform/graphics/cg/GraphicsContextCG.cpp:
58644        * platform/graphics/cg/GraphicsContextCG.h:
58645        * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
58646        * platform/graphics/cg/ImageBufferCG.cpp:
58647        * platform/graphics/cg/ImageBufferDataCG.cpp:
58648        * platform/graphics/cg/ImageBufferDataCG.h:
58649        * platform/graphics/cg/ImageCG.cpp:
58650        * platform/graphics/cg/ImageSourceCG.cpp:
58651        * platform/graphics/cg/IntPointCG.cpp:
58652        * platform/graphics/cg/IntRectCG.cpp:
58653        * platform/graphics/cg/IntSizeCG.cpp:
58654        * platform/graphics/cg/PDFDocumentImage.cpp:
58655        * platform/graphics/cg/PDFDocumentImage.h:
58656        * platform/graphics/cg/PathCG.cpp:
58657        * platform/graphics/cg/PatternCG.cpp:
58658        * platform/graphics/cg/TransformationMatrixCG.cpp:
58659        * platform/graphics/efl/IconEfl.cpp:
58660        * platform/graphics/efl/ImageEfl.cpp:
58661        * platform/graphics/filters/FilterOperation.cpp:
58662        * platform/graphics/filters/FilterOperation.h:
58663        * platform/graphics/filters/FilterOperations.cpp:
58664        * platform/graphics/filters/FilterOperations.h:
58665        * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
58666        * platform/graphics/freetype/GlyphPageTreeNodeFreeType.cpp:
58667        * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
58668        * platform/graphics/gpu/mac/DrawingBufferMac.mm:
58669        * platform/graphics/gtk/GdkCairoUtilities.cpp:
58670        * platform/graphics/gtk/GdkCairoUtilities.h:
58671        * platform/graphics/gtk/IconGtk.cpp:
58672        * platform/graphics/gtk/ImageGtk.cpp:
58673        * platform/graphics/ios/DisplayRefreshMonitorIOS.mm:
58674        * platform/graphics/ios/FontCacheIOS.mm:
58675        * platform/graphics/ios/GraphicsContext3DIOS.h:
58676        * platform/graphics/ios/InbandTextTrackPrivateAVFIOS.h:
58677        * platform/graphics/ios/InbandTextTrackPrivateAVFIOS.mm:
58678        * platform/graphics/ios/MediaPlayerPrivateIOS.h:
58679        * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
58680        * platform/graphics/mac/ColorMac.h:
58681        * platform/graphics/mac/ColorMac.mm:
58682        * platform/graphics/mac/DisplayRefreshMonitorMac.cpp:
58683        * platform/graphics/mac/FloatPointMac.mm:
58684        * platform/graphics/mac/FloatRectMac.mm:
58685        * platform/graphics/mac/FloatSizeMac.mm:
58686        * platform/graphics/mac/FontCacheMac.mm:
58687        * platform/graphics/mac/FontCustomPlatformData.h:
58688        * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
58689        * platform/graphics/mac/GraphicsContext3DMac.mm:
58690        * platform/graphics/mac/GraphicsContextMac.mm:
58691        * platform/graphics/mac/ImageMac.mm:
58692        * platform/graphics/mac/IntPointMac.mm:
58693        * platform/graphics/mac/IntRectMac.mm:
58694        * platform/graphics/mac/IntSizeMac.mm:
58695        * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
58696        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
58697        * platform/graphics/mac/MediaPlayerProxy.h:
58698        * platform/graphics/mac/WebCoreCALayerExtras.h:
58699        * platform/graphics/mac/WebCoreCALayerExtras.mm:
58700        * platform/graphics/mac/WebGLLayer.h:
58701        * platform/graphics/mac/WebGLLayer.mm:
58702        * platform/graphics/mac/WebLayer.h:
58703        * platform/graphics/mac/WebLayer.mm:
58704        * platform/graphics/mac/WebTiledLayer.h:
58705        * platform/graphics/mac/WebTiledLayer.mm:
58706        * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
58707        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
58708        * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
58709        * platform/graphics/opentype/OpenTypeUtilities.cpp:
58710        * platform/graphics/opentype/OpenTypeUtilities.h:
58711        * platform/graphics/transforms/AffineTransform.cpp:
58712        * platform/graphics/transforms/AffineTransform.h:
58713        * platform/graphics/transforms/Matrix3DTransformOperation.cpp:
58714        * platform/graphics/transforms/Matrix3DTransformOperation.h:
58715        * platform/graphics/transforms/PerspectiveTransformOperation.cpp:
58716        * platform/graphics/transforms/PerspectiveTransformOperation.h:
58717        * platform/graphics/transforms/TransformState.cpp:
58718        * platform/graphics/transforms/TransformState.h:
58719        * platform/graphics/transforms/TransformationMatrix.cpp:
58720        * platform/graphics/transforms/TransformationMatrix.h:
58721        * platform/graphics/win/FontCGWin.cpp:
58722        * platform/graphics/win/FontCacheWin.cpp:
58723        * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
58724        * platform/graphics/win/FontWin.cpp:
58725        * platform/graphics/win/FullScreenController.cpp:
58726        * platform/graphics/win/FullScreenController.h:
58727        * platform/graphics/win/FullScreenControllerClient.h:
58728        * platform/graphics/win/GlyphPageTreeNodeCGWin.cpp:
58729        * platform/graphics/win/GlyphPageTreeNodeCairoWin.cpp:
58730        * platform/graphics/win/GraphicsContextCGWin.cpp:
58731        * platform/graphics/win/GraphicsContextCairoWin.cpp:
58732        * platform/graphics/win/GraphicsContextWin.cpp:
58733        * platform/graphics/win/ImageCGWin.cpp:
58734        * platform/graphics/win/ImageCairoWin.cpp:
58735        * platform/graphics/win/ImageWin.cpp:
58736        * platform/graphics/win/IntPointWin.cpp:
58737        * platform/graphics/win/IntRectWin.cpp:
58738        * platform/graphics/win/IntSizeWin.cpp:
58739        * platform/graphics/win/LocalWindowsContext.h:
58740        * platform/graphics/win/MediaPlayerPrivateTaskTimer.cpp:
58741        * platform/graphics/win/MediaPlayerPrivateTaskTimer.h:
58742        * platform/graphics/win/SimpleFontDataCGWin.cpp:
58743        * platform/graphics/win/SimpleFontDataCairoWin.cpp:
58744        * platform/graphics/win/SimpleFontDataWin.cpp:
58745        * platform/graphics/win/TransformationMatrixWin.cpp:
58746        * platform/graphics/wince/FontCacheWinCE.cpp:
58747        * platform/graphics/wince/FontWinCE.cpp:
58748        * platform/graphics/wince/MediaPlayerPrivateWinCE.h:
58749        * platform/graphics/wince/SimpleFontDataWinCE.cpp:
58750        * platform/gtk/CompositionResults.h:
58751        * platform/gtk/CursorGtk.cpp:
58752        * platform/gtk/GtkPluginWidget.cpp:
58753        * platform/gtk/GtkPluginWidget.h:
58754        * platform/gtk/LocalizedStringsGtk.cpp:
58755        * platform/gtk/MIMETypeRegistryGtk.cpp:
58756        * platform/gtk/PlatformKeyboardEventGtk.cpp:
58757        * platform/gtk/PlatformMouseEventGtk.cpp:
58758        * platform/gtk/PlatformScreenGtk.cpp:
58759        * platform/gtk/PlatformWheelEventGtk.cpp:
58760        * platform/gtk/RedirectedXCompositeWindow.cpp:
58761        * platform/gtk/RedirectedXCompositeWindow.h:
58762        * platform/gtk/RenderThemeGtk.h:
58763        * platform/gtk/ScrollViewGtk.cpp:
58764        * platform/gtk/SharedTimerGtk.cpp:
58765        * platform/gtk/TemporaryLinkStubs.cpp:
58766        * platform/gtk/UserAgentGtk.cpp:
58767        * platform/gtk/UserAgentGtk.h:
58768        * platform/gtk/WidgetGtk.cpp:
58769        * platform/gtk/WidgetRenderingContext.cpp:
58770        * platform/image-decoders/ImageDecoder.h:
58771        * platform/image-decoders/cairo/ImageDecoderCairo.cpp:
58772        * platform/image-decoders/gif/GIFImageDecoder.cpp:
58773        * platform/image-decoders/gif/GIFImageDecoder.h:
58774        * platform/image-decoders/gif/GIFImageReader.cpp:
58775        * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
58776        * platform/image-decoders/jpeg/JPEGImageDecoder.h:
58777        * platform/image-decoders/png/PNGImageDecoder.cpp:
58778        * platform/image-decoders/png/PNGImageDecoder.h:
58779        * platform/image-decoders/webp/WEBPImageDecoder.cpp:
58780        * platform/image-decoders/webp/WEBPImageDecoder.h:
58781        * platform/ios/CursorIOS.cpp:
58782        * platform/ios/DragImageIOS.mm:
58783        * platform/ios/KeyEventCodesIOS.h:
58784        * platform/ios/KeyEventIOS.mm:
58785        * platform/ios/PlatformPasteboardIOS.mm:
58786        * platform/ios/PlatformScreenIOS.mm:
58787        * platform/ios/PlatformSpeechSynthesizerIOS.mm:
58788        * platform/ios/RemoteCommandListenerIOS.h:
58789        * platform/ios/RemoteCommandListenerIOS.mm:
58790        * platform/ios/ScrollViewIOS.mm:
58791        * platform/ios/SoundIOS.mm:
58792        * platform/ios/SystemMemory.h:
58793        * platform/ios/SystemMemoryIOS.cpp:
58794        * platform/ios/WebCoreSystemInterfaceIOS.h:
58795        * platform/ios/WebCoreSystemInterfaceIOS.mm:
58796        * platform/ios/WidgetIOS.mm:
58797        * platform/mac/BlockExceptions.h:
58798        * platform/mac/BlockExceptions.mm:
58799        * platform/mac/ContextMenuItemMac.mm:
58800        * platform/mac/ContextMenuMac.mm:
58801        * platform/mac/CursorMac.mm:
58802        * platform/mac/DragDataMac.mm:
58803        * platform/mac/DragImageMac.mm:
58804        * platform/mac/FileSystemMac.mm:
58805        * platform/mac/KeyEventMac.mm:
58806        * platform/mac/LocalCurrentGraphicsContext.h:
58807        * platform/mac/LocalCurrentGraphicsContext.mm:
58808        * platform/mac/LoggingMac.mm:
58809        * platform/mac/MIMETypeRegistryMac.mm:
58810        * platform/mac/MediaTimeMac.cpp:
58811        * platform/mac/MediaTimeMac.h:
58812        * platform/mac/PasteboardMac.mm:
58813        * platform/mac/PlatformClockCA.cpp:
58814        * platform/mac/PlatformClockCA.h:
58815        * platform/mac/PlatformClockCM.h:
58816        * platform/mac/PlatformClockCM.mm:
58817        * platform/mac/PlatformPasteboardMac.mm:
58818        * platform/mac/PlatformScreenMac.mm:
58819        * platform/mac/PlatformSpeechSynthesisMac.mm:
58820        * platform/mac/PlatformSpeechSynthesizerMac.mm:
58821        * platform/mac/ScrollViewMac.mm:
58822        * platform/mac/SharedBufferMac.mm:
58823        * platform/mac/SharedTimerMac.mm:
58824        * platform/mac/SoftLinking.h:
58825        * platform/mac/SoundMac.mm:
58826        * platform/mac/ThreadCheck.mm:
58827        * platform/mac/URLMac.mm:
58828        * platform/mac/WebCoreNSStringExtras.h:
58829        * platform/mac/WebCoreNSStringExtras.mm:
58830        * platform/mac/WebCoreNSURLExtras.h:
58831        * platform/mac/WebCoreNSURLExtras.mm:
58832        * platform/mac/WebCoreObjCExtras.h:
58833        * platform/mac/WebCoreObjCExtras.mm:
58834        * platform/mac/WebCoreSystemInterface.h:
58835        * platform/mac/WebCoreSystemInterface.mm:
58836        * platform/mac/WebCoreView.h:
58837        * platform/mac/WebCoreView.m:
58838        * platform/mac/WebFontCache.h:
58839        * platform/mac/WebFontCache.mm:
58840        * platform/mac/WebWindowAnimation.h:
58841        * platform/mac/WebWindowAnimation.mm:
58842        * platform/mac/WidgetMac.mm:
58843        * platform/mediastream/MediaStreamConstraintsValidationClient.h:
58844        * platform/mediastream/MediaStreamCreationClient.h:
58845        * platform/mediastream/MediaStreamSourceCapabilities.h:
58846        * platform/mediastream/MediaStreamSourceStates.h:
58847        * platform/mediastream/MediaStreamTrackSourcesRequestClient.h:
58848        * platform/mediastream/RTCIceServer.h:
58849        * platform/mediastream/mac/AVAudioCaptureSource.h:
58850        * platform/mediastream/mac/AVAudioCaptureSource.mm:
58851        * platform/mediastream/mac/AVCaptureDeviceManager.h:
58852        * platform/mediastream/mac/AVCaptureDeviceManager.mm:
58853        * platform/mediastream/mac/AVMediaCaptureSource.h:
58854        * platform/mediastream/mac/AVMediaCaptureSource.mm:
58855        * platform/mediastream/mac/AVVideoCaptureSource.h:
58856        * platform/mediastream/mac/AVVideoCaptureSource.mm:
58857        * platform/mock/MockMediaStreamCenter.cpp:
58858        * platform/mock/MockMediaStreamCenter.h:
58859        * platform/mock/PlatformSpeechSynthesizerMock.cpp:
58860        * platform/mock/PlatformSpeechSynthesizerMock.h:
58861        * platform/mock/mediasource/MockBox.cpp:
58862        * platform/mock/mediasource/MockBox.h:
58863        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
58864        * platform/mock/mediasource/MockMediaPlayerMediaSource.h:
58865        * platform/mock/mediasource/MockMediaSourcePrivate.cpp:
58866        * platform/mock/mediasource/MockMediaSourcePrivate.h:
58867        * platform/mock/mediasource/MockSourceBufferPrivate.cpp:
58868        * platform/mock/mediasource/MockSourceBufferPrivate.h:
58869        * platform/mock/mediasource/MockTracks.cpp:
58870        * platform/mock/mediasource/MockTracks.h:
58871        * platform/network/AuthenticationChallengeBase.cpp:
58872        * platform/network/AuthenticationChallengeBase.h:
58873        * platform/network/Credential.cpp:
58874        * platform/network/Credential.h:
58875        * platform/network/DNS.h:
58876        * platform/network/DNSResolveQueue.cpp:
58877        * platform/network/DNSResolveQueue.h:
58878        * platform/network/DataURL.cpp:
58879        * platform/network/DataURL.h:
58880        * platform/network/HTTPHeaderMap.h:
58881        * platform/network/HTTPParsers.cpp:
58882        * platform/network/HTTPParsers.h:
58883        * platform/network/PlatformCookieJar.h:
58884        * platform/network/ProtectionSpace.cpp:
58885        * platform/network/ProtectionSpace.h:
58886        * platform/network/ResourceErrorBase.cpp:
58887        * platform/network/ResourceErrorBase.h:
58888        * platform/network/ResourceHandle.cpp:
58889        * platform/network/ResourceHandle.h:
58890        * platform/network/ResourceHandleClient.h:
58891        * platform/network/ResourceHandleInternal.h:
58892        * platform/network/ResourceRequestBase.cpp:
58893        * platform/network/ResourceRequestBase.h:
58894        * platform/network/ResourceResponseBase.cpp:
58895        * platform/network/ResourceResponseBase.h:
58896        * platform/network/cf/AuthenticationCF.cpp:
58897        * platform/network/cf/AuthenticationCF.h:
58898        * platform/network/cf/AuthenticationChallenge.h:
58899        * platform/network/cf/CookieJarCFNet.cpp:
58900        * platform/network/cf/CookieStorageCFNet.cpp:
58901        * platform/network/cf/DNSCFNet.cpp:
58902        * platform/network/cf/DownloadBundle.h:
58903        * platform/network/cf/FormDataStreamCFNet.cpp:
58904        * platform/network/cf/FormDataStreamCFNet.h:
58905        * platform/network/cf/ResourceError.h:
58906        * platform/network/cf/ResourceErrorCF.cpp:
58907        * platform/network/cf/ResourceHandleCFNet.cpp:
58908        * platform/network/cf/ResourceHandleCFURLConnectionDelegate.cpp:
58909        * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h:
58910        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
58911        * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.h:
58912        * platform/network/cf/ResourceRequest.h:
58913        * platform/network/cf/ResourceRequestCFNet.cpp:
58914        * platform/network/cf/ResourceRequestCFNet.h:
58915        * platform/network/cf/ResourceResponse.h:
58916        * platform/network/cf/ResourceResponseCFNet.cpp:
58917        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp:
58918        * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h:
58919        * platform/network/curl/AuthenticationChallenge.h:
58920        * platform/network/curl/CurlDownload.cpp:
58921        * platform/network/curl/CurlDownload.h:
58922        * platform/network/curl/DNSCurl.cpp:
58923        * platform/network/curl/DownloadBundle.h:
58924        * platform/network/curl/FormDataStreamCurl.cpp:
58925        * platform/network/curl/FormDataStreamCurl.h:
58926        * platform/network/curl/ResourceError.h:
58927        * platform/network/curl/ResourceHandleCurl.cpp:
58928        * platform/network/curl/ResourceHandleManager.cpp:
58929        * platform/network/curl/ResourceHandleManager.h:
58930        * platform/network/curl/ResourceRequest.h:
58931        * platform/network/curl/ResourceResponse.h:
58932        * platform/network/curl/SSLHandle.cpp:
58933        * platform/network/curl/SSLHandle.h:
58934        * platform/network/gtk/CredentialBackingStore.cpp:
58935        * platform/network/gtk/CredentialBackingStore.h:
58936        * platform/network/ios/WebCoreURLResponseIOS.h:
58937        * platform/network/ios/WebCoreURLResponseIOS.mm:
58938        * platform/network/mac/AuthenticationMac.h:
58939        * platform/network/mac/AuthenticationMac.mm:
58940        * platform/network/mac/CookieJarMac.mm:
58941        * platform/network/mac/CookieStorageMac.mm:
58942        * platform/network/mac/FormDataStreamMac.h:
58943        * platform/network/mac/FormDataStreamMac.mm:
58944        * platform/network/mac/ResourceErrorMac.mm:
58945        * platform/network/mac/ResourceHandleMac.mm:
58946        * platform/network/mac/ResourceRequestMac.mm:
58947        * platform/network/mac/ResourceResponseMac.mm:
58948        * platform/network/mac/WebCoreURLResponse.h:
58949        * platform/network/mac/WebCoreURLResponse.mm:
58950        * platform/network/soup/AuthenticationChallenge.h:
58951        * platform/network/soup/AuthenticationChallengeSoup.cpp:
58952        * platform/network/soup/CookieJarSoup.h:
58953        * platform/network/soup/DNSSoup.cpp:
58954        * platform/network/soup/ResourceError.h:
58955        * platform/network/soup/ResourceErrorSoup.cpp:
58956        * platform/network/soup/ResourceRequest.h:
58957        * platform/network/soup/ResourceResponse.h:
58958        * platform/network/soup/SoupNetworkSession.cpp:
58959        * platform/network/soup/SoupNetworkSession.h:
58960        * platform/network/win/CookieJarWin.cpp:
58961        * platform/network/win/DownloadBundleWin.cpp:
58962        * platform/network/win/ResourceError.h:
58963        * platform/network/win/ResourceHandleWin.cpp:
58964        * platform/network/win/ResourceRequest.h:
58965        * platform/network/win/ResourceResponse.h:
58966        * platform/posix/FileSystemPOSIX.cpp:
58967        * platform/posix/SharedBufferPOSIX.cpp:
58968        * platform/soup/URLSoup.cpp:
58969        * platform/sql/SQLValue.cpp:
58970        * platform/sql/SQLValue.h:
58971        * platform/sql/SQLiteAuthorizer.cpp:
58972        * platform/sql/SQLiteDatabase.cpp:
58973        * platform/sql/SQLiteDatabase.h:
58974        * platform/sql/SQLiteStatement.cpp:
58975        * platform/sql/SQLiteStatement.h:
58976        * platform/sql/SQLiteTransaction.cpp:
58977        * platform/sql/SQLiteTransaction.h:
58978        * platform/text/SuffixTree.h:
58979        * platform/text/TextAllInOne.cpp:
58980        * platform/text/TextBoundaries.cpp:
58981        * platform/text/TextBoundaries.h:
58982        * platform/text/TextCodec.cpp:
58983        * platform/text/TextCodec.h:
58984        * platform/text/TextCodecASCIIFastPath.h:
58985        * platform/text/TextCodecICU.cpp:
58986        * platform/text/TextCodecICU.h:
58987        * platform/text/TextCodecLatin1.cpp:
58988        * platform/text/TextCodecLatin1.h:
58989        * platform/text/TextCodecUTF16.cpp:
58990        * platform/text/TextCodecUTF16.h:
58991        * platform/text/TextCodecUTF8.cpp:
58992        * platform/text/TextCodecUTF8.h:
58993        * platform/text/TextCodecUserDefined.cpp:
58994        * platform/text/TextCodecUserDefined.h:
58995        * platform/text/TextDirection.h:
58996        * platform/text/TextEncoding.cpp:
58997        * platform/text/TextEncoding.h:
58998        * platform/text/TextEncodingRegistry.cpp:
58999        * platform/text/TextEncodingRegistry.h:
59000        * platform/text/TextStream.cpp:
59001        * platform/text/TextStream.h:
59002        * platform/text/UnicodeBidi.h:
59003        * platform/text/mac/CharsetData.h:
59004        * platform/text/mac/TextBoundaries.mm:
59005        * platform/text/mac/TextCodecMac.cpp:
59006        * platform/text/mac/TextCodecMac.h:
59007        * platform/text/mac/character-sets.txt:
59008        * platform/text/mac/make-charset-table.pl:
59009        * platform/text/win/TextCodecWin.h:
59010        * platform/win/BString.cpp:
59011        * platform/win/BString.h:
59012        * platform/win/COMPtr.h:
59013        * platform/win/ClipboardUtilitiesWin.cpp:
59014        * platform/win/ClipboardUtilitiesWin.h:
59015        * platform/win/ContextMenuItemWin.cpp:
59016        * platform/win/ContextMenuWin.cpp:
59017        * platform/win/CursorWin.cpp:
59018        * platform/win/DragDataWin.cpp:
59019        * platform/win/DragImageCGWin.cpp:
59020        * platform/win/DragImageCairoWin.cpp:
59021        * platform/win/DragImageWin.cpp:
59022        * platform/win/FileSystemWin.cpp:
59023        * platform/win/GDIObjectCounter.cpp:
59024        * platform/win/GDIObjectCounter.h:
59025        * platform/win/HWndDC.h:
59026        * platform/win/KeyEventWin.cpp:
59027        * platform/win/LanguageWin.cpp:
59028        * platform/win/MIMETypeRegistryWin.cpp:
59029        * platform/win/PasteboardWin.cpp:
59030        * platform/win/PlatformMouseEventWin.cpp:
59031        * platform/win/PlatformScreenWin.cpp:
59032        * platform/win/SharedBufferWin.cpp:
59033        * platform/win/SharedTimerWin.cpp:
59034        * platform/win/SoftLinking.h:
59035        * platform/win/SoundWin.cpp:
59036        * platform/win/StructuredExceptionHandlerSuppressor.cpp:
59037        * platform/win/TemporaryLinkStubs.cpp:
59038        * platform/win/WCDataObject.cpp:
59039        * platform/win/WCDataObject.h:
59040        * platform/win/WebCoreTextRenderer.cpp:
59041        * platform/win/WebCoreTextRenderer.h:
59042        * platform/win/WheelEventWin.cpp:
59043        * platform/win/WidgetWin.cpp:
59044        * platform/win/WindowMessageBroadcaster.cpp:
59045        * platform/win/WindowMessageBroadcaster.h:
59046        * platform/win/WindowMessageListener.h:
59047        * platform/win/WindowsTouch.h:
59048        * platform/win/makesafeseh.asm:
59049        * plugins/PluginDatabase.cpp:
59050        * plugins/PluginDatabase.h:
59051        * plugins/PluginDebug.cpp:
59052        * plugins/PluginDebug.h:
59053        * plugins/PluginPackage.cpp:
59054        * plugins/PluginPackage.h:
59055        * plugins/PluginQuirkSet.h:
59056        * plugins/PluginStream.cpp:
59057        * plugins/PluginStream.h:
59058        * plugins/PluginView.cpp:
59059        * plugins/PluginView.h:
59060        * plugins/efl/PluginPackageEfl.cpp:
59061        * plugins/efl/PluginViewEfl.cpp:
59062        * plugins/gtk/PluginPackageGtk.cpp:
59063        * plugins/gtk/PluginViewGtk.cpp:
59064        * plugins/mac/PluginPackageMac.cpp:
59065        * plugins/mac/PluginViewMac.mm:
59066        * plugins/npapi.cpp:
59067        * plugins/npfunctions.h:
59068        * plugins/npruntime.h:
59069        * plugins/win/PluginDatabaseWin.cpp:
59070        * plugins/win/PluginPackageWin.cpp:
59071        * plugins/win/PluginViewWin.cpp:
59072        * plugins/x11/PluginViewX11.cpp:
59073        * rendering/EllipsisBox.cpp:
59074        * rendering/EllipsisBox.h:
59075        * rendering/FilterEffectRenderer.cpp:
59076        * rendering/FilterEffectRenderer.h:
59077        * rendering/HitTestLocation.h:
59078        * rendering/HitTestRequest.h:
59079        * rendering/HitTestResult.h:
59080        * rendering/HitTestingTransformState.cpp:
59081        * rendering/HitTestingTransformState.h:
59082        * rendering/RenderBoxRegionInfo.h:
59083        * rendering/RenderButton.cpp:
59084        * rendering/RenderButton.h:
59085        * rendering/RenderDeprecatedFlexibleBox.cpp:
59086        * rendering/RenderDeprecatedFlexibleBox.h:
59087        * rendering/RenderFieldset.cpp:
59088        * rendering/RenderFrameBase.cpp:
59089        * rendering/RenderFrameBase.h:
59090        * rendering/RenderFrameSet.cpp:
59091        * rendering/RenderGeometryMap.cpp:
59092        * rendering/RenderGeometryMap.h:
59093        * rendering/RenderGrid.cpp:
59094        * rendering/RenderGrid.h:
59095        * rendering/RenderHTMLCanvas.cpp:
59096        * rendering/RenderHTMLCanvas.h:
59097        * rendering/RenderIFrame.cpp:
59098        * rendering/RenderIFrame.h:
59099        * rendering/RenderLayerBacking.cpp:
59100        * rendering/RenderLayerBacking.h:
59101        * rendering/RenderLayerCompositor.cpp:
59102        * rendering/RenderLayerCompositor.h:
59103        * rendering/RenderLineBoxList.cpp:
59104        * rendering/RenderLineBoxList.h:
59105        * rendering/RenderListBox.cpp:
59106        * rendering/RenderListBox.h:
59107        * rendering/RenderMarquee.h:
59108        * rendering/RenderMedia.cpp:
59109        * rendering/RenderMedia.h:
59110        * rendering/RenderMultiColumnFlowThread.cpp:
59111        * rendering/RenderMultiColumnFlowThread.h:
59112        * rendering/RenderMultiColumnSet.cpp:
59113        * rendering/RenderMultiColumnSet.h:
59114        * rendering/RenderNamedFlowThread.cpp:
59115        * rendering/RenderNamedFlowThread.h:
59116        * rendering/RenderRegionSet.cpp:
59117        * rendering/RenderRegionSet.h:
59118        * rendering/RenderReplica.cpp:
59119        * rendering/RenderReplica.h:
59120        * rendering/RenderTheme.cpp:
59121        * rendering/RenderTheme.h:
59122        * rendering/RenderThemeMac.h:
59123        * rendering/RenderThemeWin.h:
59124        * rendering/RenderThemeWinCE.cpp:
59125        * rendering/RenderThemeWinCE.h:
59126        * rendering/RenderTreeAsText.cpp:
59127        * rendering/RenderTreeAsText.h:
59128        * rendering/RenderVTTCue.cpp:
59129        * rendering/RenderVTTCue.h:
59130        * rendering/RenderVideo.cpp:
59131        * rendering/RenderVideo.h:
59132        * rendering/RenderView.h:
59133        * rendering/style/SVGRenderStyle.cpp:
59134        * rendering/style/SVGRenderStyle.h:
59135        * rendering/style/SVGRenderStyleDefs.cpp:
59136        * rendering/style/SVGRenderStyleDefs.h:
59137        * rendering/style/StyleFilterData.cpp:
59138        * rendering/style/StyleFilterData.h:
59139        * rendering/style/StylePendingImage.h:
59140        * rendering/svg/RenderSVGBlock.cpp:
59141        * rendering/svg/RenderSVGBlock.h:
59142        * rendering/svg/RenderSVGForeignObject.cpp:
59143        * rendering/svg/RenderSVGForeignObject.h:
59144        * rendering/svg/RenderSVGImage.cpp:
59145        * rendering/svg/RenderSVGInline.h:
59146        * rendering/svg/RenderSVGInlineText.cpp:
59147        * rendering/svg/RenderSVGPath.h:
59148        * rendering/svg/RenderSVGShape.h:
59149        * rendering/svg/RenderSVGTSpan.h:
59150        * rendering/svg/RenderSVGText.cpp:
59151        * rendering/svg/RenderSVGText.h:
59152        * rendering/svg/SVGInlineFlowBox.cpp:
59153        * rendering/svg/SVGInlineFlowBox.h:
59154        * rendering/svg/SVGRenderTreeAsText.cpp:
59155        * rendering/svg/SVGRenderTreeAsText.h:
59156        * rendering/svg/SVGRootInlineBox.cpp:
59157        * rendering/svg/SVGRootInlineBox.h:
59158        * storage/StorageEventDispatcher.h:
59159        * svg/SVGException.cpp:
59160        * svg/graphics/SVGImageChromeClient.h:
59161        * workers/Worker.cpp:
59162        * workers/Worker.h:
59163        * workers/Worker.idl:
59164        * workers/WorkerEventQueue.cpp:
59165        * workers/WorkerEventQueue.h:
59166        * workers/WorkerGlobalScope.cpp:
59167        * workers/WorkerGlobalScope.h:
59168        * workers/WorkerGlobalScope.idl:
59169        * workers/WorkerLocation.cpp:
59170        * workers/WorkerLocation.h:
59171        * workers/WorkerLocation.idl:
59172        * workers/WorkerMessagingProxy.cpp:
59173        * workers/WorkerMessagingProxy.h:
59174        * workers/WorkerScriptLoader.cpp:
59175        * workers/WorkerScriptLoader.h:
59176        * workers/WorkerScriptLoaderClient.h:
59177        * workers/WorkerThread.cpp:
59178        * workers/WorkerThread.h:
59179        * xml/DOMParser.h:
59180        * xml/DOMParser.idl:
59181        * xml/NativeXPathNSResolver.cpp:
59182        * xml/NativeXPathNSResolver.h:
59183        * xml/XMLHttpRequest.idl:
59184        * xml/XMLHttpRequestException.cpp:
59185        * xml/XMLHttpRequestException.h:
59186        * xml/XMLHttpRequestException.idl:
59187        * xml/XMLHttpRequestProgressEvent.h:
59188        * xml/XMLHttpRequestProgressEvent.idl:
59189        * xml/XMLHttpRequestUpload.idl:
59190        * xml/XMLSerializer.h:
59191        * xml/XMLSerializer.idl:
59192        * xml/XPathEvaluator.cpp:
59193        * xml/XPathEvaluator.h:
59194        * xml/XPathEvaluator.idl:
59195        * xml/XPathException.cpp:
59196        * xml/XPathException.h:
59197        * xml/XPathException.idl:
59198        * xml/XPathExpression.idl:
59199        * xml/XPathExpressionNode.cpp:
59200        * xml/XPathNSResolver.cpp:
59201        * xml/XPathNSResolver.h:
59202        * xml/XPathNSResolver.idl:
59203        * xml/XPathNodeSet.h:
59204        * xml/XPathResult.idl:
59205        * xml/XPathUtil.h:
59206        * xml/XPathVariableReference.cpp:
59207        * xml/XSLTProcessor.idl:
59208        * xml/XSLTUnicodeSort.cpp:
59209        * xml/XSLTUnicodeSort.h:
59210
592112014-03-14  Simon Fraser  <simon.fraser@apple.com>
59212
59213        Fix scrollperf logging
59214        https://bugs.webkit.org/show_bug.cgi?id=130278
59215        <rdar://problem/16320003>
59216
59217        Reviewed by Anders Carlsson.
59218        
59219        r165493 broke scrollperf logging by adding in the scroll position
59220        to the viewport rect, which used to be 0,0 based. Restore
59221        the previous behavior.
59222
59223        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
59224        (WebCore::ScrollingTreeScrollingNodeMac::logExposedUnfilledArea):
59225
592262014-03-14  Zalan Bujtas  <zalan@apple.com>
59227
59228        Subpixel rendering: border-radius painting falls back to rectangle at subpixel positions.
59229        https://bugs.webkit.org/show_bug.cgi?id=130272
59230
59231        Unreviewed. Missing piece from http://trac.webkit.org/changeset/165670
59232
59233        * platform/graphics/RoundedRect.cpp:
59234        (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
59235
592362014-03-14  Zalan Bujtas  <zalan@apple.com>
59237
59238        Subpixel rendering: border-radius painting falls back to rectangle at subpixel positions.
59239        https://bugs.webkit.org/show_bug.cgi?id=130272
59240
59241        Reviewed by Simon Fraser.
59242
59243        Rounded rectangle's radius needs adjustment after its containing rect gets pixel snapped.
59244        Keeping the old radius value could make rounded rectangle non-renderable, because the
59245        originally calculated radius length does not fit the snapped rectangle anymore.
59246
59247        Test: fast/borders/hidpi-border-radius-outer-border-goes-rectangle.html
59248
59249        * platform/graphics/RoundedRect.cpp:
59250        (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
59251        * rendering/RenderBoxModelObject.cpp:
59252        (WebCore::RenderBoxModelObject::paintBorder):
59253
592542014-03-14  Simon Fraser  <simon.fraser@apple.com>
59255
59256        [iOS WK2] background-attachment: fixed renders oddly, moves around
59257        https://bugs.webkit.org/show_bug.cgi?id=130277
59258        <rdar://problem/16332883>
59259
59260        Reviewed by Tim Horton.
59261
59262        If we have a counter-scrolling layer (for a fixed background), move
59263        it around when changing the viewport.
59264
59265        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
59266        (WebCore::ScrollingTreeScrollingNodeIOS::updateForViewport):
59267
592682014-03-14  Jae Hyun Park  <jaepark@webkit.org>
59269
59270        [Texmap] Remove duplicated code in TextureMapperLayer
59271        https://bugs.webkit.org/show_bug.cgi?id=130173
59272
59273        Reviewed by Martin Robinson.
59274
59275        This patch is a simple refactoring to remove duplicated code in
59276        TextureMapperLayer.
59277
59278        * platform/graphics/texmap/TextureMapperLayer.cpp:
59279        (WebCore::TextureMapperLayer::~TextureMapperLayer):
59280        (WebCore::TextureMapperLayer::removeFromParent):
59281
592822014-03-14  Simon Fraser  <simon.fraser@apple.com>
59283
59284        Release-assert if someone starts the WebThread in the WebProcess
59285        https://bugs.webkit.org/show_bug.cgi?id=130270
59286        <rdar://problem/16332380>
59287
59288        Reviewed by Sam Weinig.
59289
59290        If someone tries to start the WebThread in the WebProcess, assert,
59291        even in release builds, because this should never happen.
59292
59293        * platform/ios/wak/WebCoreThread.mm:
59294        (WebThreadEnable):
59295
592962014-03-14  Peter Molnar  <pmolnar.u-szeged@partner.samsung.com>
59297
59298        Clean up unused externs from WebCore logging.
59299        https://bugs.webkit.org/show_bug.cgi?id=130240
59300
59301        Reviewed by Andreas Kling.
59302
59303        * platform/Logging.h:
59304
593052014-03-14  James Craig  <jcraig@apple.com>
59306
59307        AX: AccessibilityObject::invalidStatus() is incorrect when aria-invalid="undefined" or whitespace
59308        https://bugs.webkit.org/show_bug.cgi?id=130071
59309
59310        Reviewed by Chris Fleizach.
59311
59312        Accounted for whitespace values and the explicit string, "undefined".
59313
59314        Test: accessibility/aria-invalid.html
59315
59316        * accessibility/AccessibilityObject.cpp:
59317        (WebCore::AccessibilityObject::invalidStatus):
59318        * accessibility/AccessibilityObject.h:
59319        * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
59320        (getAttributeSetForAccessibilityObject):
59321
593222014-03-14  Bear Travis  <betravis@adobe.com>
59323
59324        [CSS Shapes] CSS parser accepts trailing position arguments
59325        https://bugs.webkit.org/show_bug.cgi?id=129514
59326
59327        Reviewed by Andreas Kling.
59328
59329        Add a check to make sure there are no remaining function args
59330        following a position in the circle() and ellipse() css shape
59331        functions.
59332
59333        Updated existing parsing tests.
59334
59335        * css/CSSParser.cpp:
59336        (WebCore::CSSParser::parseBasicShapeCircle):
59337        (WebCore::CSSParser::parseBasicShapeEllipse):
59338
593392014-03-14  Simon Fraser  <simon.fraser@apple.com>
59340
59341        Fix the iOS build and sort the exports file.
59342
59343        * WebCore.exp.in:
59344
593452014-03-14  Simon Fraser  <simon.fraser@apple.com>
59346
59347        [iOS WK2] Improve behavior of fixed elments on zooming
59348        https://bugs.webkit.org/show_bug.cgi?id=130253
59349
59350        Reviewed by Beth Dakin.
59351
59352        Correctly reposition right- and bottom-relative position:fixed
59353        elements on zooming in WK2 iOS by telling the scrolling tree
59354        about zoom-related viewport changes.
59355
59356        * WebCore.exp.in:
59357        * page/FrameView.cpp:
59358        (WebCore::FrameView::rectForViewportConstrainedObjects):
59359        (WebCore::FrameView::viewportConstrainedObjectsRect): We need to be able to
59360        recompute the fixed position rect from the scrolling tree on iOS, so we need
59361        a static function, similar to scrollOffsetForFixedPosition(), that computes
59362        the constrained viewport.
59363        * page/FrameView.h:
59364        * page/Page.cpp:
59365        (WebCore::Page::setPageScaleFactor): When scrolling (and, by implication, zooming)
59366        is delegated, then setPageScaleFactor() should not affect the scroll position.
59367        * page/scrolling/AsyncScrollingCoordinator.cpp:
59368        (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated): Go back to just
59369        passing the visibleContentRect() for iOS.
59370        * page/scrolling/ScrollingTree.cpp:
59371        (WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling): Entrypoint to
59372        the scrolling tree, called when the viewport is changed by zooming.
59373        * page/scrolling/ScrollingTree.h:
59374        * page/scrolling/ScrollingTreeScrollingNode.h:
59375        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
59376        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
59377        (WebCore::ScrollingTreeScrollingNodeIOS::setScrollLayerPosition): Use the
59378        new FrameView::rectForViewportConstrainedObjects() to compute the correct viewport
59379        for fixed/sticky child nodes.
59380        (WebCore::ScrollingTreeScrollingNodeIOS::updateForViewport):
59381        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
59382        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
59383        (WebCore::ScrollingTreeScrollingNodeMac::updateForViewport):
59384
593852014-03-14  Dirk Schulze  <krit@webkit.org>
59386
59387        Refactor Path to Path2D and remove currentPath
59388        https://bugs.webkit.org/show_bug.cgi?id=130236
59389
59390        Reviewed by Dean Jackson.
59391
59392        Other implementations prefer Path2D over Path. Furthermore, currentPath is not the right
59393        way to apply a Path2D object to a context. Main argument is that currentPath creates a copy
59394        of the Path2D object. Instead we pass Path2D as argument to fill, stroke and clip now.
59395
59396        Tests: fast/canvas/canvas-clip-path.html
59397               fast/canvas/canvas-fill-path.html
59398               fast/canvas/canvas-stroke-path.html
59399
59400        * bindings/scripts/CodeGeneratorJS.pm: WebIDL parser didn't handle enumerations
59401            for overloaded methods at all.
59402        (GenerateParametersCheckExpression):
59403        * html/canvas/CanvasRenderingContext2D.cpp: New functions with DOMPath argument.
59404        (WebCore::CanvasRenderingContext2D::fill):
59405        (WebCore::CanvasRenderingContext2D::stroke):
59406        (WebCore::CanvasRenderingContext2D::clip):
59407        (WebCore::CanvasRenderingContext2D::fillInternal): Internal method to avoid code duplication
59408            and copy operation.
59409        (WebCore::CanvasRenderingContext2D::strokeInternal): Ditto.
59410        (WebCore::CanvasRenderingContext2D::clipInternal): Ditto.
59411        * html/canvas/CanvasRenderingContext2D.h:
59412        * html/canvas/CanvasRenderingContext2D.idl:
59413        * html/canvas/DOMPath.idl: Rename Path to Path2D.
59414
594152014-03-14  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
59416
59417        ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder should take a const reference to InsertedNodes
59418        https://bugs.webkit.org/show_bug.cgi?id=130232
59419
59420        Reviewed by Andreas Kling.
59421
59422        This method doesn't modify InsertedNodes object.
59423
59424        No new tests, no behavior change.
59425
59426        * editing/ReplaceSelectionCommand.cpp:
59427        (WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
59428        * editing/ReplaceSelectionCommand.h:
59429
594302014-03-14  Jer Noble  <jer.noble@apple.com>
59431
59432        [EME] Extend the lifetime of MediaKeySession.
59433        https://bugs.webkit.org/show_bug.cgi?id=129841
59434
59435        Reviewed by Eric Carlson.
59436
59437        Test: media/encrypted-media/encrypted-media-session-lifetime.html
59438
59439        In anticipation of guidance to be added to the EME Spec <https://www.w3.org/Bugs/Public/show_bug.cgi?id=24771>,
59440        extend the lifetime of MediaKeySession by making the session an ActiveDOMObject, and returning true to
59441        hasPendingActivity when the session is both not closed and is associated with a live MediaKeys object.
59442
59443        Additionally, keep the object from being destroyed while events are pending.
59444
59445        * Modules/encryptedmedia/MediaKeySession.cpp:
59446        (WebCore::MediaKeySession::MediaKeySession):
59447        * Modules/encryptedmedia/MediaKeySession.h:
59448        * Modules/encryptedmedia/MediaKeySession.idl:
59449
594502014-03-14  Ryosuke Niwa  <rniwa@webkit.org>
59451
59452        Remove an unused function fix builds.
59453
59454        * platform/mac/HTMLConverter.mm:
59455
594562014-03-14  Frédéric Wang  <fred.wang@free.fr>
59457
59458        FontCache: Replace DEPRECATED_DEFINE_STATIC_LOCAL with static NeverDestroyed<T>.
59459        https://bugs.webkit.org/show_bug.cgi?id=130233
59460
59461        Reviewed by Andreas Kling.
59462
59463        No new tests.
59464
59465        * platform/graphics/FontCache.cpp:
59466        (WebCore::fontCache):
59467        (WebCore::FontVerticalDataCacheKeyTraits::emptyValue):
59468        (WebCore::fontVerticalDataCacheInstance):
59469        (WebCore::FontDataCacheKeyTraits::emptyValue):
59470        * platform/graphics/FontCache.h:
59471
594722014-03-11  Oliver Hunt  <oliver@apple.com>
59473
59474        Improve dom error messages
59475        https://bugs.webkit.org/show_bug.cgi?id=130103
59476
59477        Reviewed by Andreas Kling.
59478
59479        Make the DOM error messages more descriptive, and update bindings tests.
59480
59481        * bindings/scripts/CodeGeneratorJS.pm:
59482        (GenerateImplementation):
59483        (GenerateParametersCheck):
59484        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
59485        (WebCore::jsTestActiveDOMObjectExcitingAttr):
59486        (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
59487        (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):
59488        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
59489        (WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):
59490        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
59491        (WebCore::jsTestEventConstructorAttr1):
59492        (WebCore::jsTestEventConstructorAttr2):
59493        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
59494        (WebCore::jsTestEventTargetPrototypeFunctionItem):
59495        (WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
59496        (WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
59497        (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
59498        * bindings/scripts/test/JS/JSTestException.cpp:
59499        (WebCore::jsTestExceptionName):
59500        * bindings/scripts/test/JS/JSTestInterface.cpp:
59501        (WebCore::jsTestInterfaceImplementsStr1):
59502        (WebCore::jsTestInterfaceImplementsStr2):
59503        (WebCore::jsTestInterfaceImplementsStr3):
59504        (WebCore::jsTestInterfaceImplementsNode):
59505        (WebCore::jsTestInterfaceSupplementalStr1):
59506        (WebCore::jsTestInterfaceSupplementalStr2):
59507        (WebCore::jsTestInterfaceSupplementalStr3):
59508        (WebCore::jsTestInterfaceSupplementalNode):
59509        (WebCore::setJSTestInterfaceImplementsStr2):
59510        (WebCore::setJSTestInterfaceImplementsStr3):
59511        (WebCore::setJSTestInterfaceImplementsNode):
59512        (WebCore::setJSTestInterfaceSupplementalStr2):
59513        (WebCore::setJSTestInterfaceSupplementalStr3):
59514        (WebCore::setJSTestInterfaceSupplementalNode):
59515        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod1):
59516        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
59517        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod3):
59518        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod1):
59519        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
59520        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod3):
59521        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
59522        (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
59523        * bindings/scripts/test/JS/JSTestObj.cpp:
59524        (WebCore::JSTestObjConstructor::constructJSTestObj):
59525        (WebCore::jsTestObjReadOnlyLongAttr):
59526        (WebCore::jsTestObjReadOnlyStringAttr):
59527        (WebCore::jsTestObjReadOnlyTestObjAttr):
59528        (WebCore::jsTestObjConstructorTestSubObj):
59529        (WebCore::jsTestObjTestSubObjEnabledBySettingConstructor):
59530        (WebCore::jsTestObjEnumAttr):
59531        (WebCore::jsTestObjByteAttr):
59532        (WebCore::jsTestObjOctetAttr):
59533        (WebCore::jsTestObjShortAttr):
59534        (WebCore::jsTestObjUnsignedShortAttr):
59535        (WebCore::jsTestObjLongAttr):
59536        (WebCore::jsTestObjLongLongAttr):
59537        (WebCore::jsTestObjUnsignedLongLongAttr):
59538        (WebCore::jsTestObjStringAttr):
59539        (WebCore::jsTestObjTestObjAttr):
59540        (WebCore::jsTestObjXMLObjAttr):
59541        (WebCore::jsTestObjCreate):
59542        (WebCore::jsTestObjReflectedStringAttr):
59543        (WebCore::jsTestObjReflectedIntegralAttr):
59544        (WebCore::jsTestObjReflectedUnsignedIntegralAttr):
59545        (WebCore::jsTestObjReflectedBooleanAttr):
59546        (WebCore::jsTestObjReflectedURLAttr):
59547        (WebCore::jsTestObjReflectedCustomIntegralAttr):
59548        (WebCore::jsTestObjReflectedCustomBooleanAttr):
59549        (WebCore::jsTestObjReflectedCustomURLAttr):
59550        (WebCore::jsTestObjTypedArrayAttr):
59551        (WebCore::jsTestObjAttrWithGetterException):
59552        (WebCore::jsTestObjAttrWithSetterException):
59553        (WebCore::jsTestObjStringAttrWithGetterException):
59554        (WebCore::jsTestObjStringAttrWithSetterException):
59555        (WebCore::jsTestObjCustomAttr):
59556        (WebCore::jsTestObjWithScriptStateAttribute):
59557        (WebCore::jsTestObjWithScriptExecutionContextAttribute):
59558        (WebCore::jsTestObjWithScriptStateAttributeRaises):
59559        (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
59560        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttribute):
59561        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
59562        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
59563        (WebCore::jsTestObjWithScriptArgumentsAndCallStackAttribute):
59564        (WebCore::jsTestObjConditionalAttr1):
59565        (WebCore::jsTestObjConditionalAttr2):
59566        (WebCore::jsTestObjConditionalAttr3):
59567        (WebCore::jsTestObjConditionalAttr4Constructor):
59568        (WebCore::jsTestObjConditionalAttr5Constructor):
59569        (WebCore::jsTestObjConditionalAttr6Constructor):
59570        (WebCore::jsTestObjCachedAttribute1):
59571        (WebCore::jsTestObjCachedAttribute2):
59572        (WebCore::jsTestObjAnyAttribute):
59573        (WebCore::jsTestObjContentDocument):
59574        (WebCore::jsTestObjMutablePoint):
59575        (WebCore::jsTestObjImmutablePoint):
59576        (WebCore::jsTestObjStrawberry):
59577        (WebCore::jsTestObjStrictFloat):
59578        (WebCore::jsTestObjDescription):
59579        (WebCore::jsTestObjId):
59580        (WebCore::jsTestObjHash):
59581        (WebCore::jsTestObjReplaceableAttribute):
59582        (WebCore::jsTestObjNullableDoubleAttribute):
59583        (WebCore::jsTestObjNullableLongAttribute):
59584        (WebCore::jsTestObjNullableBooleanAttribute):
59585        (WebCore::jsTestObjNullableStringAttribute):
59586        (WebCore::jsTestObjNullableLongSettableAttribute):
59587        (WebCore::jsTestObjNullableStringValue):
59588        (WebCore::jsTestObjAttribute):
59589        (WebCore::jsTestObjAttributeWithReservedEnumType):
59590        (WebCore::setJSTestObjTestSubObjEnabledBySettingConstructor):
59591        (WebCore::setJSTestObjEnumAttr):
59592        (WebCore::setJSTestObjByteAttr):
59593        (WebCore::setJSTestObjOctetAttr):
59594        (WebCore::setJSTestObjShortAttr):
59595        (WebCore::setJSTestObjUnsignedShortAttr):
59596        (WebCore::setJSTestObjLongAttr):
59597        (WebCore::setJSTestObjLongLongAttr):
59598        (WebCore::setJSTestObjUnsignedLongLongAttr):
59599        (WebCore::setJSTestObjStringAttr):
59600        (WebCore::setJSTestObjTestObjAttr):
59601        (WebCore::setJSTestObjXMLObjAttr):
59602        (WebCore::setJSTestObjCreate):
59603        (WebCore::setJSTestObjReflectedStringAttr):
59604        (WebCore::setJSTestObjReflectedIntegralAttr):
59605        (WebCore::setJSTestObjReflectedUnsignedIntegralAttr):
59606        (WebCore::setJSTestObjReflectedBooleanAttr):
59607        (WebCore::setJSTestObjReflectedURLAttr):
59608        (WebCore::setJSTestObjReflectedCustomIntegralAttr):
59609        (WebCore::setJSTestObjReflectedCustomBooleanAttr):
59610        (WebCore::setJSTestObjReflectedCustomURLAttr):
59611        (WebCore::setJSTestObjTypedArrayAttr):
59612        (WebCore::setJSTestObjAttrWithGetterException):
59613        (WebCore::setJSTestObjAttrWithSetterException):
59614        (WebCore::setJSTestObjStringAttrWithGetterException):
59615        (WebCore::setJSTestObjStringAttrWithSetterException):
59616        (WebCore::setJSTestObjCustomAttr):
59617        (WebCore::setJSTestObjWithScriptStateAttribute):
59618        (WebCore::setJSTestObjWithScriptExecutionContextAttribute):
59619        (WebCore::setJSTestObjWithScriptStateAttributeRaises):
59620        (WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
59621        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
59622        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
59623        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
59624        (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
59625        (WebCore::setJSTestObjConditionalAttr1):
59626        (WebCore::setJSTestObjConditionalAttr2):
59627        (WebCore::setJSTestObjConditionalAttr3):
59628        (WebCore::setJSTestObjConditionalAttr4Constructor):
59629        (WebCore::setJSTestObjConditionalAttr5Constructor):
59630        (WebCore::setJSTestObjConditionalAttr6Constructor):
59631        (WebCore::setJSTestObjAnyAttribute):
59632        (WebCore::setJSTestObjMutablePoint):
59633        (WebCore::setJSTestObjImmutablePoint):
59634        (WebCore::setJSTestObjStrawberry):
59635        (WebCore::setJSTestObjStrictFloat):
59636        (WebCore::setJSTestObjId):
59637        (WebCore::setJSTestObjReplaceableAttribute):
59638        (WebCore::setJSTestObjNullableLongSettableAttribute):
59639        (WebCore::setJSTestObjNullableStringValue):
59640        (WebCore::setJSTestObjAttributeWithReservedEnumType):
59641        (WebCore::jsTestObjPrototypeFunctionVoidMethod):
59642        (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
59643        (WebCore::jsTestObjPrototypeFunctionByteMethod):
59644        (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
59645        (WebCore::jsTestObjPrototypeFunctionOctetMethod):
59646        (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
59647        (WebCore::jsTestObjPrototypeFunctionLongMethod):
59648        (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
59649        (WebCore::jsTestObjPrototypeFunctionObjMethod):
59650        (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
59651        (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
59652        (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
59653        (WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
59654        (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
59655        (WebCore::jsTestObjPrototypeFunctionSerializedValue):
59656        (WebCore::jsTestObjPrototypeFunctionOptionsObject):
59657        (WebCore::jsTestObjPrototypeFunctionMethodWithException):
59658        (WebCore::jsTestObjPrototypeFunctionCustomMethod):
59659        (WebCore::jsTestObjPrototypeFunctionCustomMethodWithArgs):
59660        (WebCore::jsTestObjPrototypeFunctionAddEventListener):
59661        (WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
59662        (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoid):
59663        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
59664        (WebCore::jsTestObjPrototypeFunctionWithScriptStateVoidException):
59665        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
59666        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContext):
59667        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptState):
59668        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
59669        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
59670        (WebCore::jsTestObjPrototypeFunctionWithScriptArgumentsAndCallStack):
59671        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
59672        (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
59673        (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
59674        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalString):
59675        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefined):
59676        (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullString):
59677        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
59678        (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
59679        (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
59680        (WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackAndOptionalArg):
59681        (WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackArg):
59682        (WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
59683        (WebCore::jsTestObjPrototypeFunctionConditionalMethod2):
59684        (WebCore::jsTestObjPrototypeFunctionConditionalMethod3):
59685        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
59686        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
59687        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
59688        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
59689        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
59690        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
59691        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
59692        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
59693        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod9):
59694        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
59695        (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
59696        (WebCore::jsTestObjPrototypeFunctionClassMethodWithClamp):
59697        (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
59698        (WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
59699        (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
59700        (WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
59701        (WebCore::jsTestObjPrototypeFunctionConvert1):
59702        (WebCore::jsTestObjPrototypeFunctionConvert2):
59703        (WebCore::jsTestObjPrototypeFunctionConvert4):
59704        (WebCore::jsTestObjPrototypeFunctionConvert5):
59705        (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
59706        (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
59707        (WebCore::jsTestObjPrototypeFunctionOrange):
59708        (WebCore::jsTestObjPrototypeFunctionStrictFunction):
59709        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
59710        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithArray):
59711        (WebCore::jsTestObjPrototypeFunctionVariadicStringMethod):
59712        (WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethod):
59713        (WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
59714        (WebCore::jsTestObjPrototypeFunctionAny):
59715        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
59716        (WebCore::jsTestSerializedScriptValueInterfaceValue):
59717        (WebCore::jsTestSerializedScriptValueInterfaceReadonlyValue):
59718        (WebCore::jsTestSerializedScriptValueInterfaceCachedValue):
59719        (WebCore::jsTestSerializedScriptValueInterfacePorts):
59720        (WebCore::jsTestSerializedScriptValueInterfaceCachedReadonlyValue):
59721        (WebCore::setJSTestSerializedScriptValueInterfaceValue):
59722        (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
59723        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
59724        (WebCore::JSTestTypedefsConstructor::constructJSTestTypedefs):
59725        (WebCore::jsTestTypedefsUnsignedLongLongAttr):
59726        (WebCore::jsTestTypedefsImmutableSerializedScriptValue):
59727        (WebCore::jsTestTypedefsConstructorTestSubObj):
59728        (WebCore::jsTestTypedefsAttrWithGetterException):
59729        (WebCore::jsTestTypedefsAttrWithSetterException):
59730        (WebCore::jsTestTypedefsStringAttrWithGetterException):
59731        (WebCore::jsTestTypedefsStringAttrWithSetterException):
59732        (WebCore::setJSTestTypedefsUnsignedLongLongAttr):
59733        (WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
59734        (WebCore::setJSTestTypedefsAttrWithGetterException):
59735        (WebCore::setJSTestTypedefsAttrWithSetterException):
59736        (WebCore::setJSTestTypedefsStringAttrWithGetterException):
59737        (WebCore::setJSTestTypedefsStringAttrWithSetterException):
59738        (WebCore::jsTestTypedefsPrototypeFunctionFunc):
59739        (WebCore::jsTestTypedefsPrototypeFunctionSetShadow):
59740        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
59741        (WebCore::jsTestTypedefsPrototypeFunctionNullableArrayArg):
59742        (WebCore::jsTestTypedefsPrototypeFunctionFuncWithClamp):
59743        (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
59744        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction):
59745        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction2):
59746        (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
59747        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithException):
59748        * bindings/scripts/test/JS/JSattribute.cpp:
59749        (WebCore::jsattributeReadonly):
59750
597512014-03-14  Bear Travis  <betravis@adobe.com>
59752
59753        [CSS Shapes] polygon default fill-rule should be omitted from the serialization
59754        https://bugs.webkit.org/show_bug.cgi?id=129840
59755
59756        Reviewed by Dirk Schulze.
59757
59758        Modifying the default polygon string opening to be "polygon(" rather than
59759        "polygon(nonzero".
59760
59761        Updated existing parsing tests.
59762
59763        * css/CSSBasicShapes.cpp:
59764        (WebCore::buildPolygonString):
59765
597662014-03-14  Brent Fulgham  <bfulgham@apple.com>
59767
59768        Crash when using a mixture of In-Band and Out-of-Band Tracks
59769        https://bugs.webkit.org/show_bug.cgi?id=130247
59770
59771        Reviewed by Eric Carlson.
59772
59773        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
59774        (WebCore::MediaPlayerPrivateAVFoundation::processNewAndRemovedTextTracks): Do not include
59775        the new Out-of-Band placeholder tracks in our counts of in-band tracks.
59776
597772014-03-13  Ryosuke Niwa  <rniwa@webkit.org>
59778
59779        [Mac] Avoid creating DOMCSSStyleDeclaration in WebHTMLConverter
59780        https://bugs.webkit.org/show_bug.cgi?id=130226
59781
59782        Reviewed by Andreas Kling.
59783
59784        Extracted HTMLConverterCaches in C++ that directly calls getPropertyCSSValue on computed style
59785        and inline style to avoid creating Objective-C wrappers for CSSComputedStyleDeclaration.
59786
59787        This improves the runtime of PerformanceTests/Interactive/CopyAll.html from 31-32s to 25-26s (20%).
59788
59789        * platform/mac/HTMLConverter.h:
59790        * platform/mac/HTMLConverter.mm:
59791        (HTMLConverterCaches::computedStylePropertyForElement):
59792        (HTMLConverterCaches::inlineStylePropertyForElement):
59793        (stringFromCSSValue):
59794        (-[WebHTMLConverter _computedStringForNode:property:]):
59795        (floatValueFromPrimitiveValue):
59796        (_getFloat):
59797        (-[WebHTMLConverter _getComputedFloat:forNode:property:]):
59798        (-[WebHTMLConverter _computedColorForNode:property:]):
59799        (-[WebHTMLConverter dealloc]):
59800        (-[WebHTMLConverter init]):
59801
598022014-03-14  James Craig  <jcraig@apple.com>
59803
59804        Web Inspector: AXI: Include Role as an extra attribute in the page overlay.
59805        https://bugs.webkit.org/show_bug.cgi?id=130214
59806
59807        Reviewed by Timothy Hatcher.
59808
59809        Adding Role to the Web Inspector element overlay.
59810
59811        * inspector/InspectorOverlay.cpp:
59812        (WebCore::buildObjectForElementInfo):
59813        * inspector/InspectorOverlayPage.js:
59814        (_createElementTitle):
59815
598162014-03-14  James Craig  <jcraig@apple.com>
59817
59818        Web Inspector: AXI: Expose Accessibility Tree parent of the selected node
59819        https://bugs.webkit.org/show_bug.cgi?id=129943
59820
59821        Reviewed by Timothy Hatcher.
59822
59823        Tests: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
59824
59825        Web Accessibility Node Inspector now displays a link to the AX parent node,
59826        because it's not a 1:1 match with the DOMNode parent.
59827
59828        * inspector/InspectorDOMAgent.cpp: Support for DOMNode.role and AccessibilityProperties.axParentNodeId.
59829        (WebCore::InspectorDOMAgent::buildObjectForNode): Support for role.
59830        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties): Support for axParentNodeId.
59831        * inspector/protocol/DOM.json: Added axParentNodeId on AccessibilityProperties, and role on DOMNode.
59832
598332014-03-14  Andreas Kling  <akling@apple.com>
59834
59835        [Mac] Remove NSURLCache logic from WebCore pressure relief code.
59836        <https://webkit.org/b/130248>
59837
59838        The NSURLCache lives in the networking process and should be cleared
59839        on that end. Furthermore, this code doesn't really do what we thought
59840        it was doing; it merely sets and and resets the limits. No truncation
59841        ever occurred. The intended functionality was implemented in r165342.
59842
59843        Reviewed by Anders Carlsson.
59844
59845        * platform/mac/MemoryPressureHandlerMac.mm:
59846        (WebCore::MemoryPressureHandler::releaseMemory):
59847
598482014-03-14  Andreas Kling  <akling@apple.com>
59849
59850        Simplify jettisoning of style resolvers on memory pressure.
59851        <https://webkit.org/b/129644>
59852
59853        Now that we have Document::allDocuments(), we can jettison all the
59854        style resolvers by walking the set of live documents and calling
59855        clearStyleResolver() on each one, instead of having a function on
59856        Page that walks the frame tree of every living page, etc.
59857
59858        Reviewed by Antti Koivisto.
59859
59860        * page/Page.cpp:
59861        * page/Page.h:
59862        * platform/mac/MemoryPressureHandlerMac.mm:
59863        (WebCore::MemoryPressureHandler::releaseMemory):
59864
598652014-03-07  Jer Noble  <jer.noble@apple.com>
59866
59867        Add Remote Control command support to HTLMediaElement
59868        https://bugs.webkit.org/show_bug.cgi?id=129926
59869
59870        Reviewed by Eric Carlson.
59871
59872        Support the new MediaSession remote control commands by pulling in code from
59873        MediaControlElementTypes to control scanning.
59874
59875        * html/HTMLMediaElement.cpp:
59876        (WebCore::HTMLMediaElement::HTMLMediaElement):
59877        * html/HTMLMediaElement.h:
59878        * html/MediaController.cpp:
59879        (MediaController::beginScanning): Moved from MediaControlElementTypes.
59880        (MediaController::endScanning): Ditto.
59881        * html/MediaController.h:
59882        * html/MediaControllerInterface.h:
59883
59884        Remove all the scanning code from MediaControlSeekButtonElement.
59885        * html/shadow/MediaControlElementTypes.cpp:
59886        (WebCore::MediaControlSeekButtonElement::MediaControlSeekButtonElement):
59887        (WebCore::MediaControlSeekButtonElement::setActive):
59888        * html/shadow/MediaControlElementTypes.h:
59889
598902014-03-14  Krzysztof Czech  <k.czech@samsung.com>
59891
59892        Move WebSpeech code to use std::unique_ptr
59893        https://bugs.webkit.org/show_bug.cgi?id=130231
59894
59895        Reviewed by Anders Carlsson.
59896
59897        Replace uses of OwnPtr and PassOwnPtr in WebSpeech code with std::unique_ptr.
59898
59899        No new tests. Covered by existing ones.
59900
59901        * Modules/speech/SpeechRecognitionController.cpp:
59902        * Modules/speech/SpeechRecognitionController.h:
59903        * Modules/speech/SpeechSynthesis.cpp:
59904        (WebCore::SpeechSynthesis::setPlatformSynthesizer):
59905        (WebCore::SpeechSynthesis::getVoices):
59906        (WebCore::SpeechSynthesis::startSpeakingImmediately):
59907        * Modules/speech/SpeechSynthesis.h:
59908        * WebCore.exp.in:
59909        * platform/PlatformSpeechSynthesizer.cpp:
59910        * platform/PlatformSpeechSynthesizer.h:
59911        * platform/mock/PlatformSpeechSynthesizerMock.cpp:
59912        * platform/mock/PlatformSpeechSynthesizerMock.h:
59913        * testing/Internals.cpp:
59914        (WebCore::Internals::enableMockSpeechSynthesizer):
59915
599162014-03-13  Anders Carlsson  <andersca@apple.com>
59917
59918        Move visited link handling to VisitedLinkTableController and VisitedLinkProvider
59919        https://bugs.webkit.org/show_bug.cgi?id=130223
59920        <rdar://problem/16315792>
59921
59922        Reviewed by Dan Bernstein.
59923
59924        Export symbols needed by WebKit2.
59925
59926        * WebCore.exp.in:
59927
599282014-03-12  Martin Robinson  <mrobinson@igalia.com>
59929
59930        [GTK] Fix unused parameter warnings in the GObject WebKitDOM bindings
59931        https://bugs.webkit.org/show_bug.cgi?id=130174
59932
59933        Reviewed by Daniel Bates.
59934
59935        * bindings/gobject/DOMObjectCache.cpp:
59936        (WebKit::weakRefNotify): Fix unused parameters.
59937        * bindings/gobject/WebKitDOMDeprecated.cpp: Ditto.
59938        * bindings/gobject/WebKitDOMObject.cpp: Ditto.
59939        * bindings/scripts/CodeGeneratorGObject.pm: Generate UNUSED_PARAM when appropriate and clean
59940        up the getter and setter code generation a little to make it easier to read.
59941
599422014-03-14  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
59943
59944        Build fix with SUBPIXEL_LAYOUT disabled
59945        https://bugs.webkit.org/show_bug.cgi?id=130210
59946
59947        Reviewed by Daniel Bates.
59948
59949        Use pre-incremeent operator for LayoutUnit instead of post-increment operator as LayoutUnit doesn't support the
59950        latter and we don't make use of the return value.
59951
59952        * dom/Element.cpp:
59953        (WebCore::adjustForLocalZoom):
59954
599552014-03-14  Mihnea Ovidenie  <mihnea@adobe.com>
59956
59957        [CSSRegions] Inline-block child of content node incorrectly clipped
59958        https://bugs.webkit.org/show_bug.cgi?id=130229
59959
59960        Reviewed by Andrei Bucur.
59961
59962        Constrain the target box rect to the region box rect only if we are able
59963        to determine the region range for box. If we cannot do that, getRegionRangeForBox
59964        returns null values for start and end region and we should not perform the clamping.
59965
59966        Test: fast/regions/inlineblock-child-inlineblock-contentnode-in-region.html
59967
59968        * rendering/RenderRegion.cpp:
59969        (WebCore::RenderRegion::rectFlowPortionForBox):
59970
599712014-03-14  Zan Dobersek  <zdobersek@igalia.com>
59972
59973        Unnecessary ImplementationLacksVTable IDL attribute used for RTCConfiguration, RTCIceServer
59974        https://bugs.webkit.org/show_bug.cgi?id=130230
59975
59976        Reviewed by Philippe Normand.
59977
59978        The RTCConfiguration and RTCIceServer classes do not own virtual tables, so using the
59979        ImplementationLacksVTable attribute in the IDL interface leads to a compile-time assertion
59980        failure in the generates JSC wrappers because none of the classes is polymorphic.
59981
59982        * Modules/mediastream/RTCConfiguration.idl:
59983        * Modules/mediastream/RTCIceServer.idl:
59984
599852014-03-14  Javier Fernandez  <jfernandez@igalia.com>
59986
59987        [CSS Grid Layout] the "grid-template-areas" is not identified as computable property.
59988        https://bugs.webkit.org/show_bug.cgi?id=130073
59989
59990        Reviewed by Sergio Villar Senin.
59991
59992        The "grid-template-areas" property is a computable CSS property, so it should be
59993        handled accordingly by the Web Inspector.
59994
59995        No new tests.
59996
59997        * css/CSSComputedStyleDeclaration.cpp:
59998        CSSPropertyWebkitGridTemplateAreas added to the computedProperties array.
59999
600002014-03-14  Sergio Villar Senin  <svillar@igalia.com>
60001
60002        [CSS Grid layout] Initial position in span not correctly computed sometimes
60003        https://bugs.webkit.org/show_bug.cgi?id=130124
60004
60005        Reviewed by Darin Adler.
60006
60007        The code uses std::lower_bound() to get the first grid line
60008        position before a given resolved position in a Vector. That
60009        function returns an iterator pointing to the first value not
60010        "strictly less" than the given one. Consequently, the returned
60011        position might be actually located after the resolved final
60012        position. In those cases we need to select the previous position
60013        in the Vector (which is guaranted to be "< resolved position" due
60014        to how std::lower_bound() works).
60015
60016        For example, if we have vector=[2,5,8] as grid positions, and we
60017        need the first position before 7, std::lower_bound(vector, 7) will
60018        point to 8 (first value not < 7). It's obvious that we should
60019        select 5 instead. Should the pointed value be equal, then we
60020        should do nothing, because the indexes mean tracks, so the item
60021        will be placed in just one cell of the grid.
60022
60023        * rendering/RenderGrid.cpp:
60024        (WebCore::firstNamedGridLineBeforePosition):
60025        (WebCore::RenderGrid::resolveRowStartColumnStartNamedGridLinePositionAgainstOppositePosition):
60026
600272014-03-14  Zsolt Borbely  <borbezs@inf.u-szeged.hu>
60028
60029        Fix the !ENABLE(SVG_FONTS) build
60030        https://bugs.webkit.org/show_bug.cgi?id=130193
60031
60032        Reviewed by Dirk Schulze.
60033
60034        Add missing ENABLE(SVG_FONTS) guards for createGlyphToPathTranslator() function
60035        in SVGTextRunRenderingContext.h and TextRun.h, because when the SVG_FONTS are
60036        disabled the function is not implemented.
60037
60038        * platform/graphics/TextRun.h:
60039        * rendering/svg/SVGTextRunRenderingContext.h:
60040
600412014-03-14  Sergio Villar Senin  <svillar@igalia.com>
60042
60043        Unreviewed build fix after r165607. There were two missing replaces.
60044
60045        * bindings/scripts/CodeGeneratorJS.pm:
60046        (GenerateImplementation):
60047        * dom/Element.cpp:
60048        (WebCore::attrNodeListMap):
60049
600502014-03-14  Frédéric Wang  <fred.wang@free.fr>
60051
60052        Migrate the MathML stretchy code from UChar to Glyph.
60053        https://bugs.webkit.org/show_bug.cgi?id=128907
60054
60055        Reviewed by Chris Fleizach.
60056
60057        This prepares the MathML stretchy code for future support for the MATH
60058        table. In particular, this uses the glyph index for measuring and
60059        drawing instead of Unicode code point since the MATH table uses glyph
60060        indices. Also, this merges the preferred width and stretchy character
60061        selection into one common path since they will also have to share the
60062        size variants measuring/selection. Finally, we expose a drawGlyphs()
60063        method so that we can draw a glyph by index.
60064
60065        No new tests. This should not change the behavior of the stretchy code.
60066
60067        * platform/graphics/Font.h:
60068        * platform/graphics/GraphicsContext.cpp:
60069        (WebCore::GraphicsContext::drawGlyphs):
60070        * platform/graphics/GraphicsContext.h:
60071        * rendering/mathml/RenderMathMLOperator.cpp:
60072        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
60073        (WebCore::RenderMathMLOperator::boundsForGlyph):
60074        (WebCore::RenderMathMLOperator::heightForGlyph):
60075        (WebCore::RenderMathMLOperator::advanceForGlyph):
60076        (WebCore::RenderMathMLOperator::computePreferredLogicalWidths):
60077        (WebCore::RenderMathMLOperator::findStretchyData):
60078        (WebCore::RenderMathMLOperator::updateStyle):
60079        (WebCore::RenderMathMLOperator::firstLineBaseline):
60080        (WebCore::RenderMathMLOperator::computeLogicalHeight):
60081        (WebCore::RenderMathMLOperator::paintGlyph):
60082        (WebCore::RenderMathMLOperator::fillWithExtensionGlyph):
60083        (WebCore::RenderMathMLOperator::paint):
60084        (WebCore::RenderMathMLOperator::paintChildren):
60085        * rendering/mathml/RenderMathMLOperator.h:
60086
600872014-03-12  Sergio Villar Senin  <svillar@igalia.com>
60088
60089        Rename DEFINE_STATIC_LOCAL to DEPRECATED_DEFINE_STATIC_LOCAL
60090        https://bugs.webkit.org/show_bug.cgi?id=129612
60091
60092        Reviewed by Darin Adler.
60093
60094        For new code use static NeverDestroyed<T> instead.
60095
60096        Removed the list of changed files as it was huge.
60097
600982014-03-14  Gavin Barraclough  <barraclough@apple.com>
60099
60100        Reduce memory use for static property maps
60101        https://bugs.webkit.org/show_bug.cgi?id=129986
60102
60103        Unreviewed Windows build fix / update bindings test results following r165603.
60104
60105        * bindings/scripts/CodeGeneratorJS.pm:
60106        (GenerateHashTable):
60107        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
60108        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
60109        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
60110        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
60111        (WebCore::jsTestEventTargetPrototypeFunctionItem):
60112        (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
60113        * bindings/scripts/test/JS/JSTestException.cpp:
60114        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
60115        * bindings/scripts/test/JS/JSTestInterface.cpp:
60116        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
60117        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
60118        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
60119        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
60120        * bindings/scripts/test/JS/JSTestNode.cpp:
60121        * bindings/scripts/test/JS/JSTestObj.cpp:
60122        (WebCore::jsTestObjAttrWithGetterException):
60123        (WebCore::jsTestObjStringAttrWithGetterException):
60124        (WebCore::jsTestObjWithScriptStateAttributeRaises):
60125        (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
60126        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
60127        (WebCore::jsTestObjNullableStringValue):
60128        (WebCore::jsTestObjPrototypeFunctionByteMethod):
60129        (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
60130        (WebCore::jsTestObjPrototypeFunctionOctetMethod):
60131        (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
60132        (WebCore::jsTestObjPrototypeFunctionLongMethod):
60133        (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
60134        (WebCore::jsTestObjPrototypeFunctionObjMethod):
60135        (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
60136        (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
60137        (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
60138        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
60139        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
60140        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
60141        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
60142        (WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
60143        (WebCore::jsTestObjConstructorFunctionClassMethodWithOptional):
60144        (WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
60145        (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
60146        (WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
60147        (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
60148        (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
60149        (WebCore::jsTestObjPrototypeFunctionStrictFunction):
60150        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
60151        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithArray):
60152        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
60153        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
60154        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
60155        (WebCore::jsTestTypedefsAttrWithGetterException):
60156        (WebCore::jsTestTypedefsStringAttrWithGetterException):
60157        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
60158        (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
60159        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction):
60160        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction2):
60161        (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
60162        * bindings/scripts/test/JS/JSattribute.cpp:
60163        * bindings/scripts/test/JS/JSreadonly.cpp:
60164
601652014-03-14  Jinwoo Song  <jinwoo7.song@samsung.com>
60166
60167        Use override keyword in BatteryManager
60168        https://bugs.webkit.org/show_bug.cgi?id=130225
60169
60170        Reviewed by Daniel Bates.
60171
60172        * Modules/battery/BatteryManager.h:
60173
601742014-03-12  Gavin Barraclough  <barraclough@apple.com>
60175
60176        Reduce memory use for static property maps
60177        https://bugs.webkit.org/show_bug.cgi?id=129986
60178
60179        Reviewed by Andreas Kling.
60180
60181        Static property tables are currently duplicated on first use from read-only memory into dirty memory
60182        in every process, and since the entries are large (48 bytes) and the tables can be unusually sparse
60183        (we use a custom hash table without a rehash) a lot of memory may be wasted.
60184
60185        * bindings/js/JSDOMBinding.h:
60186        (WebCore::getStaticValueSlotEntryWithoutCaching):
60187        (WebCore::getStaticValueSlotEntryWithoutCaching<JSDOMWrapper>):
60188            - HashEntry -> HashTableValue.
60189        * bindings/js/JSDOMWindowCustom.cpp:
60190        (WebCore::JSDOMWindow::getOwnPropertySlot):
60191            - HashEntry -> HashTableValue.
60192        * bindings/js/JSHistoryCustom.cpp:
60193        (WebCore::JSHistory::getOwnPropertySlotDelegate):
60194            - HashEntry -> HashTableValue.
60195        * bindings/js/JSLocationCustom.cpp:
60196        (WebCore::JSLocation::getOwnPropertySlotDelegate):
60197        (WebCore::JSLocation::putDelegate):
60198            - HashEntry -> HashTableValue.
60199        * bindings/scripts/CodeGeneratorJS.pm:
60200        (GenerateGetOwnPropertySlotBody):
60201            - HashEntry -> HashTableValue.
60202        (GenerateHashTable):
60203            - emit the hash table index into the derived source (we were calculating this already to ensure chaining does not get too deep).
60204
602052014-03-13  Manish R Gurnaney  <m.gurnaney@samsung.com>
60206
60207        Scroll size is not recalculated when absolute left of child is updated
60208        https://bugs.webkit.org/show_bug.cgi?id=123958
60209
60210        Reviewed by Simon Fraser.
60211
60212        Test: fast/css/display-inline-block-scrollbar.html
60213        Actual issue was that whenever there is the content change in the
60214        RenderBlock having inline-block children, The InlineFlowBox while
60215        computing overflow never resets previous value.
60216        
60217        * rendering/InlineFlowBox.cpp:
60218        (WebCore::InlineFlowBox::computeOverflow):
60219        Added code to clear overflow when we start computing overflow for
60220        InlineFlowBox. So as to ScrollSize can be recalculated properly.
60221
602222014-03-13  Zalan Bujtas  <zalan@apple.com>
60223
60224        Pass const RenderStyle& to box decoration functions.
60225        https://bugs.webkit.org/show_bug.cgi?id=130201
60226
60227        Reviewed by Andreas Goran Kling.
60228
60229        No change in functionality.
60230
60231        * rendering/InlineFlowBox.cpp:
60232        (WebCore::InlineFlowBox::paintBoxShadow):
60233        (WebCore::InlineFlowBox::paintBoxDecorations):
60234        (WebCore::InlineFlowBox::paintMask):
60235        * rendering/RenderBox.cpp:
60236        (WebCore::RenderBox::paintBoxDecorations):
60237        (WebCore::RenderBox::paintMaskImages):
60238        * rendering/RenderBoxModelObject.cpp:
60239        (WebCore::RenderBoxModelObject::paintNinePieceImage):
60240        (WebCore::RenderBoxModelObject::paintOneBorderSide):
60241        (WebCore::RenderBoxModelObject::paintBorderSides):
60242        (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
60243        (WebCore::RenderBoxModelObject::paintBorder):
60244        (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
60245        (WebCore::RenderBoxModelObject::getBorderEdgeInfo):
60246        (WebCore::RenderBoxModelObject::borderObscuresBackgroundEdge):
60247        (WebCore::RenderBoxModelObject::borderObscuresBackground):
60248        (WebCore::RenderBoxModelObject::paintBoxShadow):
60249        * rendering/RenderBoxModelObject.h:
60250        * rendering/RenderFieldset.cpp:
60251        (WebCore::RenderFieldset::paintBoxDecorations):
60252        * rendering/RenderTable.cpp:
60253        (WebCore::RenderTable::paintBoxDecorations):
60254        * rendering/RenderTableCell.cpp:
60255        (WebCore::RenderTableCell::paintBoxDecorations):
60256
602572014-03-13  Jinwoo Jeong  <jw00.jeong@samsung.com>
60258
60259        Refactor Vibration algorithm to use only one timer.
60260        https://bugs.webkit.org/show_bug.cgi?id=130059
60261
60262        Reviewed by Darin Adler.
60263
60264        Currently Vibration is using two timers,
60265        one is to start a vibration and another is to check termination of a vibration.
60266        But they do not work in same time, if one of them is fired, then anothor will start.
60267        Thus this patch removes one of them, and manages vibration states by enumeration.
60268
60269        Also, this patch implement the missing part of the algorithm,
60270        which check the maximum length of the vibration pattern and the maximum duration of the vibration.
60271
60272        Lastly, this patch removes unused methods from Vibration.
60273
60274        * Modules/vibration/Vibration.cpp:
60275        (WebCore::Vibration::Vibration):
60276        (WebCore::Vibration::vibrate):
60277        (WebCore::Vibration::cancelVibration):
60278        Removed stopVibration() and its contents moved to cancelVibration().
60279        (WebCore::Vibration::timerFired): Combined timerStartFired() and timerStopFired().
60280        Removed suspendVibration() and resumeVibration(), which is never called since r.
60281        * Modules/vibration/Vibration.h: Added new enumertaion to specify states of Vibration.
60282        (WebCore::Vibration::isVibrating):
60283
602842014-03-13  James Craig  <jcraig@apple.com>
60285
60286        Web Inspector: AXI: Use loc strings for known aria-invalid types
60287        https://bugs.webkit.org/show_bug.cgi?id=129952
60288
60289        Reviewed by Joseph Pecoraro.
60290
60291        Updating inspector-protocol enum and UI display values for @aria-invalid.
60292
60293        Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
60294
60295        * inspector/InspectorDOMAgent.cpp: Enum for DOM.AccessibilityPropertiesInvalid
60296        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
60297        * inspector/protocol/DOM.json: Enum for DOM.AccessibilityPropertiesInvalid
60298
602992014-03-13  Dirk Schulze  <krit@webkit.org>
60300
60301        [SVG2] support paint-order presentation attribute
60302        https://bugs.webkit.org/show_bug.cgi?id=129373
60303
60304        Reviewed by Dean Jackson.
60305
60306        Add support for the paint-order property from SVG2. The presentation
60307        attribute/CSS property allows to paint fill, stroke and markers in any order
60308        the author desires.
60309
60310        Firefox supports this but behind a runtime flag. It is just activated in
60311        nightly builds by default.
60312
60313        Chromium supports it behind a runtime flag as well but is going to ship it
60314        pretty soon.
60315
60316        Tests: svg/paint-order/paint-order-fill-expected.svg
60317               svg/paint-order/paint-order-fill-markers-expected.svg
60318               svg/paint-order/paint-order-fill-markers.svg
60319               svg/paint-order/paint-order-fill.svg
60320               svg/paint-order/paint-order-markers-expected.svg
60321               svg/paint-order/paint-order-markers-stroke-expected.svg
60322               svg/paint-order/paint-order-markers-stroke.svg
60323               svg/paint-order/paint-order-markers.svg
60324               svg/paint-order/paint-order-normal-expected.svg
60325               svg/paint-order/paint-order-normal.svg
60326               svg/paint-order/paint-order-stroke-expected.svg
60327               svg/paint-order/paint-order-stroke-marker-expected.svg
60328               svg/paint-order/paint-order-stroke-marker.svg
60329               svg/paint-order/paint-order-stroke.svg
60330               svg/paint-order/paint-order-text-markers-expected.svg
60331               svg/paint-order/paint-order-text-markers.svg
60332               svg/paint-order/paint-order-text-normal-expected.svg
60333               svg/paint-order/paint-order-text-normal.svg
60334               svg/paint-order/paint-order-text-stroke-expected.svg
60335               svg/paint-order/paint-order-text-stroke.svg
60336               svg/paint-order/paint-order-text-tspan-001-expected.svg
60337               svg/paint-order/paint-order-text-tspan-001.svg
60338               svg/paint-order/paint-order-text-tspan-002-expected.svg
60339               svg/paint-order/paint-order-text-tspan-002.svg
60340               svg/paint-order/parsing-paint-order.html
60341
60342        * css/CSSComputedStyleDeclaration.cpp: Computed style for paint-order.
60343        (WebCore::ComputedStyleExtractor::propertyValue):
60344        * css/CSSParser.h:
60345        * css/CSSPropertyNames.in:
60346        * css/CSSValueKeywords.in:
60347        * css/SVGCSSComputedStyleDeclaration.cpp:
60348        (WebCore::paintOrder):
60349        (WebCore::ComputedStyleExtractor::svgPropertyValue):
60350        * css/SVGCSSParser.cpp: Parse paint-order. Take care of serialization
60351            at this point already to get element style correct.
60352        (WebCore::CSSParser::parseSVGValue):
60353        (WebCore::CSSParser::parsePaintOrder):
60354        * css/SVGCSSStyleSelector.cpp:
60355        (WebCore::StyleResolver::applySVGProperty):
60356        * rendering/style/SVGRenderStyle.cpp:
60357        (WebCore::SVGRenderStyle::paintTypesForPaintOrder):
60358        (WebCore::SVGRenderStyle::diff): Repaint on change.
60359        * rendering/style/SVGRenderStyle.h:
60360        (WebCore::SVGRenderStyle::initialPaintOrder):
60361        (WebCore::SVGRenderStyle::setPaintOrder):
60362        (WebCore::SVGRenderStyle::paintOrder):
60363        (WebCore::SVGRenderStyle::InheritedFlags::operator==):
60364        (WebCore::SVGRenderStyle::setBitDefaults):
60365        * rendering/style/SVGRenderStyleDefs.h:
60366        * rendering/svg/RenderSVGShape.cpp: Change order of painting based on paint-order.
60367        (WebCore::RenderSVGShape::strokeShape):
60368        (WebCore::RenderSVGShape::fillStrokeMarkers):
60369        (WebCore::RenderSVGShape::paint):
60370        (WebCore::RenderSVGShape::addFocusRingRects):
60371        * rendering/svg/RenderSVGShape.h:
60372        * rendering/svg/SVGInlineTextBox.cpp:
60373        (WebCore::SVGInlineTextBox::paint): Ditto.
60374        * svg/SVGElement.cpp: Make property a presentation attribute.
60375        (WebCore::populateAttributeNameToCSSPropertyIDMap):
60376        (WebCore::populateAttributeNameToAnimatedPropertyTypeMap):
60377        * svg/svgattrs.in: Add paint-order attribute.
60378
603792014-03-13  Andreas Kling  <akling@apple.com>
60380
60381        Network process instantiates JSC::VM under fake memory pressure.
60382        <https://webkit.org/b/130143>
60383
60384        Stop calling GCController::garbageCollectSoon() in the fake memory
60385        pressure callback. The pressure relief code already schedules GC
60386        by way of discardAllCode() which does reportAbandonedObjectGraph().
60387        This way we don't accidentally instantiate a VM in the networking
60388        process for no reason.
60389
60390        Reviewed by Geoffrey Garen.
60391
60392        * platform/mac/MemoryPressureHandlerMac.mm:
60393        (WebCore::MemoryPressureHandler::install):
60394
603952014-03-13  Diego Pino Garcia  <dpino@igalia.com>
60396
60397        Web Inspector: AXI: Expose focused/focusable state in the Accessibility Node Inspector
60398        https://bugs.webkit.org/show_bug.cgi?id=129779
60399
60400        Reviewed by Timothy Hatcher.
60401
60402        * inspector/InspectorDOMAgent.cpp: Set property "focused".
60403        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
60404        * inspector/protocol/DOM.json: Add property "focused" to
60405        AccessibilityProperties.
60406
604072014-03-12  Jae Hyun Park  <jaepark@webkit.org>
60408
60409        Remove remaining Nix port related files
60410        https://bugs.webkit.org/show_bug.cgi?id=130179
60411
60412        Reviewed by Csaba Osztrogonác.
60413
60414        GLContextFromCurrentEGL was added in r155360 as a part of nix
60415        upstreaming. As Nix port is removed from the source tree, these files
60416        are in no use.
60417
60418        * platform/graphics/egl/GLContextFromCurrentEGL.cpp: Removed.
60419        * platform/graphics/egl/GLContextFromCurrentEGL.h: Removed.
60420
604212014-03-13  Daniel Bates  <dabates@apple.com>
60422
60423        REGRESSION (r160806): Incorrect cascade order of prefixed and non-prefixed variants of
60424        CSS properties box-shadow and background-{clip, origin, size}
60425        https://bugs.webkit.org/show_bug.cgi?id=130102
60426        <rdar://problem/16187037>
60427
60428        Reviewed by Andreas Kling.
60429
60430        Fixes an issues in the computation of the final value for the CSS properties
60431        box-shadow and background-{clip, origin, size} when the definition of a selector
60432        uses both the prefixed and non-prefixed variants (in order) of these properties.
60433
60434        Tests: fast/css/cascade/background-clip-and-webkit-background-clip-cascade-order.html
60435               fast/css/cascade/background-origin-and-webkit-background-origin-cascade-order.html
60436               fast/css/cascade/background-size-and-webkit-background-size-cascade-order.html
60437               fast/css/cascade/box-shadow-and-webkit-box-shadow-cascade-order.html
60438
60439        * css/CSSPropertyNames.in: Add a comment to explain the difference between property
60440        -webkit-box-shadow and property box-shadow.
60441        * css/StyleResolver.cpp:
60442        (WebCore::shouldApplyPropertyInParseOrder): Add prefixed and non-prefixed variants
60443        of box-shadow and background-{clip, origin, size} to the list of properties that need
60444        to be applied in the same order as they were parsed from the stylesheet.
60445
604462014-03-13  Joseph Pecoraro  <pecoraro@apple.com>
60447
60448        Web Inspector: Remove InspectorFrontendHost.loadResourceSynchronously
60449        https://bugs.webkit.org/show_bug.cgi?id=130217
60450
60451        Reviewed by Timothy Hatcher.
60452
60453        This has been replaced by NetworkAgent.loadResource,
60454        which loads asynchronously through the backend.
60455
60456        * inspector/InspectorFrontendHost.cpp:
60457        * inspector/InspectorFrontendHost.h:
60458        * inspector/InspectorFrontendHost.idl:
60459
604602014-03-13  Joseph Pecoraro  <pecoraro@apple.com>
60461
60462        Web Inspector: Network.loadResource should include the response status code
60463        https://bugs.webkit.org/show_bug.cgi?id=130216
60464
60465        Reviewed by Timothy Hatcher.
60466
60467        * inspector/InspectorResourceAgent.cpp:
60468        Record and send the http status code.
60469
60470        * inspector/protocol/Network.json:
60471        Include status code property in the success callback.
60472
604732014-03-13  Joseph Pecoraro  <pecoraro@apple.com>
60474
60475        Web Inspector: Network.loadResource XHR crash if page reloaded while request is ongoing
60476        https://bugs.webkit.org/show_bug.cgi?id=130211
60477
60478        Reviewed by Timothy Hatcher.
60479
60480        Merged from Blink with changes, (patch by vsevik@chromium.org):
60481        http://src.chromium.org/viewvc/blink?view=revision&revision=152712
60482
60483        Using an XMLHttpRequest to download resources had a few issues. Being an
60484        Active DOM Object the load could be paused. Without an extra retain,
60485        when the load was cancelled (e.g. a page reload) the XHR would get
60486        destructed and could cause a crash if the list of active DOM objects
60487        was actively being iterated.
60488
60489        Switch to a DocumentThreadableLoader to manage the load ourselves.
60490        This still uses the Memory cache, but we have a little more control.
60491
60492        * inspector/InspectorResourceAgent.h:
60493        * inspector/InspectorResourceAgent.cpp:
60494        (WebCore::InspectorResourceAgent::InspectorResourceAgent):
60495        (WebCore::InspectorResourceAgent::loadResource):
60496        Switch from XHR to DocumentThreadableLoader.
60497
60498        * xml/XMLHttpRequest.h:
60499        * xml/XMLHttpRequest.cpp:
60500        (WebCore::XMLHttpRequest::XMLHttpRequest):
60501        (WebCore::XMLHttpRequest::createRequest):
60502        (WebCore::XMLHttpRequest::sendForInspector):
60503        Remove the now unnecessary XHR sendForInspector path.
60504
605052014-03-13  Commit Queue  <commit-queue@webkit.org>
60506
60507        Unreviewed, rolling out r165540.
60508        https://bugs.webkit.org/show_bug.cgi?id=130199
60509
60510        caused 1 hidpi test fail (Requested by zalan on #webkit).
60511
60512        Reverted changeset:
60513
60514        "Subpixel rendering: Nested layers with subpixel accumulation
60515        paint to wrong position."
60516        https://bugs.webkit.org/show_bug.cgi?id=130153
60517        http://trac.webkit.org/changeset/165540
60518
605192014-03-13  Benjamin Poulain  <bpoulain@apple.com>
60520
60521        Fix a bunch of mistakes in the parsing of ::cue( and ::cue
60522        https://bugs.webkit.org/show_bug.cgi?id=130113
60523
60524        Reviewed by Andreas Kling.
60525
60526        * css/CSSGrammar.y.in:
60527        * css/CSSParserValues.cpp:
60528        (WebCore::CSSParserSelector::setPseudoTypeValue):
60529        The ::cue() pseudo element "function" was passed as a PseudoClass.
60530        The type was then parsed and considered as a compatibility type to flip
60531        the match type back to PseudoElement.
60532
60533        Instead of all that jazz, just pass the right type from the grammar.
60534
60535        * css/CSSSelector.cpp:
60536        (WebCore::CSSSelector::parsePseudoType):
60537        The non-function ::cue pseudo element use shadow pseudo ID for matching the element.
60538        Since it is unprefixed, it needs to map to one of the Custom types. The previous code
60539        was using String::startsWith() for some reason, change that to a simple equality.
60540
605412014-03-13  Benjamin Poulain  <benjamin@webkit.org>
60542
60543        Clean up RenderStyle creation
60544        https://bugs.webkit.org/show_bug.cgi?id=130180
60545
60546        Reviewed by Andreas Kling.
60547
60548        Use the copy constructor with the default style instead of having a special
60549        constructor for that.
60550
60551        * rendering/style/RenderStyle.cpp:
60552        (WebCore::RenderStyle::create):
60553        (WebCore::RenderStyle::RenderStyle):
60554        * rendering/style/RenderStyle.h:
60555
605562014-03-13  Benjamin Poulain  <bpoulain@apple.com>
60557
60558        The viewport code should not depend on WebKitSystemInterface
60559        https://bugs.webkit.org/show_bug.cgi?id=130218
60560
60561        Reviewed by Tim Horton.
60562
60563        The viewport code cannot be generalized to other ports because it relies
60564        on WebKit system interface to get the device screen size.
60565        This patch fixes that by going through ChromeClient to get the data.
60566
60567        * dom/Document.cpp:
60568        (WebCore::Document::processViewport):
60569        Get the screensize from chrome client.
60570
60571        * dom/ViewportArguments.cpp:
60572        (WebCore::computeViewportAttributes):
60573        This is dead code. Nothing should ever use computeViewportAttributes().
60574
60575        (WebCore::finalizeViewportArguments):
60576        * dom/ViewportArguments.h:
60577        * page/ChromeClient.h:
60578        (WebCore::ChromeClient::viewportScreenSize):
60579
605802014-03-07  Jer Noble  <jer.noble@apple.com>
60581
60582        Add remote control command support to MediaSession.
60583        https://bugs.webkit.org/show_bug.cgi?id=129903
60584
60585        Reviewed by Eric Carlson.
60586
60587        Add the capability to receive remote control commands (currently iOS only) and to
60588        pass those commands through the MediaSessionManager.
60589
60590        Add a new platform class which can listen for remote control commands:
60591        * platform/RemoteCommandListener.cpp: Added.
60592        (WebCore::RemoteCommandListener::create):
60593        * platform/RemoteCommandListener.h: Added.
60594        (WebCore::RemoteCommandListenerClient::~RemoteCommandListenerClient):
60595        (WebCore::RemoteCommandListener::~RemoteCommandListener):
60596        (WebCore::RemoteCommandListener::RemoteCommandListener):
60597        * platform/ios/RemoteCommandListenerIOS.h: Added.
60598        * platform/ios/RemoteCommandListenerIOS.mm: Added.
60599        (WebCore::RemoteCommandListener::create):
60600        (WebCore::RemoteCommandListenerIOS::RemoteCommandListenerIOS):
60601        (WebCore::RemoteCommandListenerIOS::~RemoteCommandListenerIOS):
60602
60603        Handle remote control command events in HTMLMediaElement and AudioDestinationMac:
60604        * html/HTMLMediaElement.cpp:
60605        (WebCore::HTMLMediaElement::parseAttribute):
60606        * html/HTMLMediaElement.h:
60607        * platform/audio/mac/AudioDestinationMac.h:
60608        (WebCore::AudioDestinationMac::canReceiveRemoteControlCommands):
60609        (WebCore::AudioDestinationMac::didReceiveRemoteControlCommand):
60610
60611        Pipe command events through MediaSessionManager:
60612        * platform/audio/MediaSession.cpp:
60613        (WebCore::MediaSession::canReceiveRemoteControlCommands):
60614        (WebCore::MediaSession::didReceivRemoteControlCommand):
60615        * platform/audio/MediaSession.h:
60616        * platform/audio/MediaSessionManager.cpp:
60617        (WebCore::MediaSessionManager::addSession):
60618        (WebCore::MediaSessionManager::removeSession):
60619        (WebCore::MediaSessionManager::sessionWillBeginPlayback):
60620        (WebCore::MediaSessionManager::didReceiveRemoteControlCommand):
60621        (WebCore::MediaSessionManager::addClient):
60622        (WebCore::MediaSessionManager::removeClient):
60623        * platform/audio/MediaSessionManager.h:
60624        (WebCore::MediaSessionManagerClient::~MediaSessionManagerClient):
60625        (WebCore::MediaSessionManagerClient::MediaSessionManagerClient):
60626
60627        Make sessionWillBegin/EndPlayback() methods take non-const parameters:
60628        * platform/audio/MediaSessionManager.h:
60629        (WebCore::MediaSessionManager::sessionWillEndPlayback):
60630        * platform/audio/ios/MediaSessionManagerIOS.h:
60631        * platform/audio/ios/MediaSessionManagerIOS.mm:
60632        (WebCore::MediaSessionManagerIOS::sessionWillBeginPlayaback):
60633        (WebCore::MediaSessionManagerIOS::sessionWillEndPlayaback):
60634
60635        Add new files and export new symbols:
60636        * WebCore.exp.in:
60637        * WebCore.xcodeproj/project.pbxproj:
60638
606392014-03-13  Csaba Osztrogonác  <ossy@webkit.org>
60640
60641        Unreviewed, rolling out r165544 and r165560.
60642
60643        It broke EFL/GTK/Windows build
60644
60645        Reverted changesets:
60646
60647        "Optimize hasTagName when called on an HTMLElement"
60648        https://bugs.webkit.org/show_bug.cgi?id=130090
60649        http://trac.webkit.org/changeset/165544
60650
60651        http://trac.webkit.org/changeset/165560
60652
606532014-03-13  Antti Koivisto  <antti@apple.com>
60654
60655        Try to stop asserts in debug build.
60656
60657        * dom/Node.cpp:
60658        (WebCore::Document::invalidateNodeListAndCollectionCaches):
60659
606602014-03-13  Benjamin Poulain  <bpoulain@apple.com>
60661
60662        Update the build fix for r165544
60663
60664        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
60665        Fix typo :(
60666
606672014-03-13  Benjamin Poulain  <bpoulain@apple.com>
60668
60669        Update the build fix for r165544
60670
60671        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
60672        (-[WebAccessibilityObjectWrapper isSVGGroupElement]):
60673        Use the SVG version since the name being tested is a SVG name.
60674
606752014-03-13  Benjamin Poulain  <bpoulain@apple.com>
60676
60677        Attempt to fix the build after r165542
60678
60679        * dom/NodeRenderStyle.h:
60680
606812014-03-13  Benjamin Poulain  <bpoulain@apple.com>
60682
60683        Update WebAccessibilityObjectWrapperIOS after r165544
60684
60685        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
60686        (-[WebAccessibilityObjectWrapper isSVGGroupElement]):
60687
606882014-03-13  Antti Koivisto  <antti@apple.com>
60689
60690        REGRESSION(r165542): printing/page-rule-selection.html failing
60691        https://bugs.webkit.org/show_bug.cgi?id=130205
60692
60693        Reviewed by Andreas Kling.
60694
60695        * css/StyleResolver.cpp:
60696        (WebCore::StyleResolver::keyframeStylesForAnimation):
60697        (WebCore::StyleResolver::styleForPage):
60698        
60699            Use Document style as parent when resolving page style.
60700
60701        (WebCore::StyleResolver::applyPropertyToStyle):
60702        * css/StyleResolver.h:
60703        
60704            Get rid of the default null parameter.
60705
607062014-03-13  Benjamin Poulain  <bpoulain@apple.com>
60707
60708        Remove INPUT_LIST_BUTTON from the PseudoIds
60709        https://bugs.webkit.org/show_bug.cgi?id=130108
60710
60711        Reviewed by Andreas Kling.
60712
60713        * rendering/style/RenderStyleConstants.h:
60714        It is unused.
60715
607162014-03-12  Eric Carlson  <eric.carlson@apple.com>
60717
60718        [iOS] Sync media playback with now playing
60719        https://bugs.webkit.org/show_bug.cgi?id=130172
60720
60721        Reviewed by Jer Noble.
60722        
60723        * html/HTMLMediaElement.cpp:
60724        (WebCore::HTMLMediaElement::play): Move clientWillBeginPlayback to
60725            playInternal so it is called every time playback begins.
60726        (WebCore::HTMLMediaElement::playInternal): Call clientWillBeginPlayback.
60727        (WebCore::HTMLMediaElement::pause): Move clientWillPausePlayback to
60728            playInternal so it is called every time playback begins.
60729        (WebCore::HTMLMediaElement::playInternal): Call clientWillPausePlayback.
60730        (WebCore::HTMLMediaElement::mediaSessionTitle): New. Return the 'title' attribute,
60731            or currenSrc if that is empty.
60732        * html/HTMLMediaElement.h:
60733        (WebCore::HTMLMediaElement::mediaSessionDuration): Return duration.
60734        (WebCore::HTMLMediaElement::mediaSessionCurrentTime): Return current time.
60735
60736        * platform/audio/MediaSession.cpp:
60737        (WebCore::MediaSession::clientWillPausePlayback): New, passthrough to the
60738            media element.
60739        (WebCore::MediaSession::title): Ditto.
60740        (WebCore::MediaSession::duration): Ditto.
60741        (WebCore::MediaSession::currentTime): Ditto.
60742        * platform/audio/MediaSession.h:
60743        (WebCore::MediaSessionClient::mediaSessionTitle):
60744        (WebCore::MediaSessionClient::mediaSessionDuration):
60745        (WebCore::MediaSessionClient::mediaSessionCurrentTime):
60746
60747        * platform/audio/MediaSessionManager.cpp:
60748        (WebCore::MediaSessionManager::MediaSessionManager): Initialize m_activeSession.
60749        (WebCore::MediaSessionManager::removeSession): Set m_activeSession if the session
60750            being removed is currently active.
60751        (WebCore::MediaSessionManager::sessionWillBeginPlayback): Set m_activeSession.
60752        * platform/audio/MediaSessionManager.h:
60753        (WebCore::MediaSessionManager::sessionWillEndPlayback):
60754        (WebCore::MediaSessionManager::setCurrentSession):
60755        (WebCore::MediaSessionManager::currentSession):
60756
60757        * platform/audio/ios/MediaSessionManagerIOS.h:
60758        * platform/audio/ios/MediaSessionManagerIOS.mm:
60759        (WebCore::MediaSessionManageriOS::sessionWillBeginPlayback): Call updateNowPlayingInfo. 
60760        (WebCore::MediaSessionManageriOS::sessionWillEndPlayback): Ditto.
60761        (WebCore::MediaSessionManageriOS::updateNowPlayingInfo): Update MPNowPlayingInfoCenter
60762            with the current media item's title, duration, and current time.
60763        (-[WebMediaSessionHelper initWithCallback:]): Turn on deliver of remote control
60764            events, even though we don't respond to them yet, or Now Playing won't work.
60765
607662014-03-13  Radu Stavila  <stavila@adobe.com>
60767
60768        Webkit not building on XCode 5.1 due to garbage collection no longer being supported
60769        https://bugs.webkit.org/show_bug.cgi?id=130087
60770
60771        Reviewed by Mark Rowe.
60772
60773        Disable garbage collection on macosx when not using internal SDK.
60774
60775        No new tests required.
60776
60777        * Configurations/Base.xcconfig:
60778
607792014-03-13  Andreas Kling  <akling@apple.com>
60780
60781        Don't send synchronous resize events when FrameView has auto-sizing enabled.
60782        <https://webkit.org/b/130198>
60783        <rdar://problem/15991333>
60784
60785        Reviewed by Dan Bernstein.
60786
60787        * page/FrameView.cpp:
60788        (WebCore::FrameView::sendResizeEventIfNeeded):
60789
607902014-03-13  Antti Koivisto  <antti@apple.com>
60791
60792        Try to fix release build.
60793
60794        * css/MediaQueryMatcher.cpp:
60795        * css/StyleMedia.cpp:
60796        * html/HTMLTitleElement.cpp:
60797
607982014-03-11  Darin Adler  <darin@apple.com>
60799
60800        Avoid copy-prone idiom "for (auto item : collection)"
60801        https://bugs.webkit.org/show_bug.cgi?id=129990
60802
60803        Reviewed by Geoffrey Garen.
60804
60805        Most of these changes have no effect. A few of them get rid of unwanted
60806        copying of the items as we iterate them. Found these with the command
60807        'git grep "for (auto .*:"' or the equivalent.
60808
60809        * Modules/indexeddb/IDBKeyData.cpp:
60810        (WebCore::IDBKeyData::IDBKeyData): Use auto& to avoid copying the keys.
60811        (WebCore::IDBKeyData::maybeCreateIDBKey): Ditto.
60812        (WebCore::IDBKeyData::isolatedCopy): Ditto.
60813
60814        * dom/Node.cpp:
60815        (WebCore::Document::invalidateNodeListAndCollectionCaches): Use auto*
60816        to make explicit the fact that these are pointers. Stop using "it" for
60817        a variable that is not an iterator. Get rid of unneeded local variables
60818        for the collections themselves.
60819
60820        * dom/NodeRareData.h:
60821        (WebCore::NodeListsNodeData::adoptDocument): Use auto& to make sure we
60822        don't do any unnecessary copying. Stop using "it" for a variable that
60823        is not an iterator.
60824
60825        * html/HTMLTableRowsCollection.cpp:
60826        (WebCore::HTMLTableRowsCollection::lastRow): Use auto* to be explicit
60827        that these are pointers.
60828        * inspector/InspectorNodeFinder.cpp:
60829        (WebCore::InspectorNodeFinder::searchUsingDOMTreeTraversal): Ditto.
60830        * page/ios/FrameIOS.mm:
60831        (WebCore::Frame::interpretationsForCurrentRoot): Ditto. Also got rid of
60832        an unnecessary local variable.
60833
60834        * platform/FileChooser.cpp:
60835        (WebCore::FileChooser::chooseFiles): Use auto&. Also fix a FIXME.
60836        (WebCore::FileChooser::chooseMediaFiles): Ditto.
60837
60838        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
60839        (WebCore::SourceBufferPrivateAVFObjC::naturalSize): Use auto&.
60840
60841        * rendering/RenderIterator.h: Changed include from RenderObject.h to
60842        RenderElement.h; iterators are based on RenderElement now.
60843
60844        * rendering/svg/RenderSVGResource.cpp:
60845        (WebCore::removeFromCacheAndInvalidateDependencies): Use auto*.
60846
60847        * rendering/svg/RenderSVGResourceContainer.cpp:
60848        (WebCore::RenderSVGResourceContainer::markAllClientsForInvalidation): Use auto*.
60849        (WebCore::RenderSVGResourceContainer::markAllClientLayersForInvalidation): Ditto.
60850        (WebCore::RenderSVGResourceContainer::registerResource): Ditto.
60851
60852        * rendering/svg/SVGRenderSupport.cpp:
60853        (WebCore::SVGRenderSupport::layoutChildren): Updated to use a more specific
60854        type, to use auto* instead of of auto, and to eliminate the slightly sloppily
60855        capitalized and not-so-slightly ungrammatical notlayoutedObjects.
60856        (WebCore::SVGRenderSupport::applyStrokeStyleToContext): Use auto&.
60857        (WebCore::SVGRenderSupport::updateMaskedAncestorShouldIsolateBlending): Use auto*.
60858
60859        * rendering/svg/SVGResourcesCycleSolver.cpp:
60860        (WebCore::SVGResourcesCycleSolver::resourceContainsCycles): Use auto*.
60861        (WebCore::SVGResourcesCycleSolver::resolveCycles): Ditto. Also lineageOfType.
60862
60863        * svg/SVGAnimateMotionElement.cpp:
60864        (WebCore::SVGAnimateMotionElement::applyResultsToTarget): Use auto*.
60865        * svg/SVGPathElement.cpp:
60866        (WebCore::SVGPathElement::invalidateMPathDependencies): Ditto.
60867
608682014-03-13  Brian Burg  <bburg@apple.com>
60869
60870        Web Inspector: Remove unused callId parameter from evaluateInWebInspector
60871        https://bugs.webkit.org/show_bug.cgi?id=129744
60872
60873        Reviewed by Timothy Hatcher.
60874
60875        * WebCore.exp.in:
60876        * inspector/InspectorController.cpp:
60877        (WebCore::InspectorController::evaluateForTestInFrontend):
60878        * inspector/InspectorController.h:
60879
608802014-03-13  Darin Adler  <darin@apple.com>
60881
60882        Optimize hasTagName when called on an HTMLElement
60883        https://bugs.webkit.org/show_bug.cgi?id=130090
60884
60885        Reviewed by Antti Koivisto.
60886
60887        Added new hasTagName functions that have the efficiency of hasLocalName.
60888        but are safe.
60889
60890        Now we can always use hasTagName, and we'll get a compile time error if
60891        we try to use an SVG tag name with an HTML element. All call sites that
60892        use the more specific tag name types are more efficient, and call sites
60893        that have a specific pointer type will get even more efficient checking
60894        that is exactly what we used to get by calling hasLocalName.
60895
60896        * accessibility/AccessibilityObject.cpp:
60897        (WebCore::AccessibilityObject::hasTagName): Cast explicitly to Element
60898        since Node::hasTagName no longer works on a general QualifiedName.
60899        * accessibility/AccessibilityRenderObject.cpp:
60900        (WebCore::AccessibilityRenderObject::isDescendantOfElementType): Use
60901        more specific type, RenderElement, so we can call hasTagName on Element
60902        instead of Node; eliminates an unnecessary branch.
60903
60904        * dom/DocumentStyleSheetCollection.cpp:
60905        (WebCore::DocumentStyleSheetCollection::collectActiveStyleSheets): Use
60906        new for loop and full words for variable names. Also use nullptr instead
60907        of 0. Call toHTMLElement and toSVGElement in code that checks hasTagName
60908        since it's already checking isHTMLElement and isSVGElement.
60909
60910        * dom/Element.cpp:
60911        (WebCore::attrNodeListMap): Use NeverDestroyed and put the vectors into
60912        the map rather than putting pointers to a vector into the map.
60913        (WebCore::attrNodeListForElement): Take a reference rather than a pointer,
60914        and update for the change above.
60915        (WebCore::ensureAttrNodeListForElement): Ditto.
60916        (WebCore::removeAttrNodeListForElement): Ditto.
60917        (WebCore::findAttrNodeInList): Ditto.
60918        (WebCore::Element::isFocusable): Use ancestorsOfType<HTMLCanvasElement>
60919        to fine the canvas rather than a hand-written loop.
60920        (WebCore::Element::attrNodeList): Update for above changes.
60921        (WebCore::Element::setAttributeNode): Ditto.
60922        (WebCore::Element::attrIfExists): Ditto.
60923        (WebCore::Element::ensureAttr): Ditto.
60924        (WebCore::Element::detachAttrNodeFromElementWithValue): Ditto.
60925        (WebCore::Element::detachAllAttrNodesFromElement): Ditto.
60926
60927        * dom/Element.h: Removed the overload of hasLocalName that takes a
60928        QualifiedName and ignores the non-local-name parts of it. Callers should
60929        use hasTagName instead, now that it's optimized appropriately. Added
60930        overloads of hasTagName for all the specific qualified name types. It's
60931        more efficient to use the Node versions of these functions rather than
60932        using QualifiedName::matches to do the check. Removed the hasTagName and
60933        hasLocalName functions from the Node class; the only convenience functions
60934        needed in Node are the specific checks for tags from HTML, MathML, and SVG,
60935        not the general purpose ones.
60936
60937        * dom/Node.h: Removed hasLocalName and replaced the single hasTagName
60938        that takes a QualifiedName with three faster ones that take HTML, MathML,
60939        and SVG qualified names instead. Also updated to use nullptr instead of 0.
60940
60941        * dom/PositionIterator.cpp: Added now-needed include.
60942        * dom/Text.cpp: Ditto.
60943
60944        * dom/make_names.pl:
60945        (printHeaderHead): Renamed an argument for clarity and added a definitions
60946        argument, which is where we insert the classes derived from QualifiedName.
60947        (printCppHead): Renamed an argument for clarity.
60948        (printTypeHelpers): Use hasTagName rather than hasLocalName, since the
60949        former is now optimized to be the same as what the latter was.
60950        (printNamesHeaderFile): Define a class derived from QualifiedName that can
60951        be used at compile time to avoid having to check the namespace.
60952        (printNamesCppFile): Use the new more-specific type as needed.
60953
60954        * editing/ApplyStyleCommand.cpp:
60955        (WebCore::isLegacyAppleStyleSpan): Use hasTagName instead of hasLocalName,
60956        and references instead of pointers.
60957        (WebCore::ApplyStyleCommand::ApplyStyleCommand): Removed uneeded explicit
60958        construction of a smart pointer.
60959        (WebCore::ApplyStyleCommand::shouldApplyInlineStyleToRun): Updated to use
60960        the enclosingElementWithTag function by its new name.
60961
60962        * editing/Editor.cpp:
60963        (WebCore::Editor::selectionUnorderedListState): Updated to use the
60964        enclosingElementWithTag function by its new name.
60965        (WebCore::Editor::selectionOrderedListState): Ditto.
60966
60967        * editing/InsertListCommand.cpp:
60968        (WebCore::InsertListCommand::doApply): Use a more-specific type for the list tag.
60969        (WebCore::InsertListCommand::doApplyForSingleParagraph): Ditto.
60970        * editing/InsertListCommand.h: Ditto.
60971
60972        * editing/MarkupAccumulator.cpp:
60973        (WebCore::MarkupAccumulator::serializeNodesWithNamespaces): Added an explicit
60974        cast to Element in the loop that is already guarded by an isElementNode check.
60975        Also use a modern C++ for loop.
60976
60977        * editing/ReplaceSelectionCommand.cpp:
60978        (WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
60979        Updated to use the enclosingElementWithTag function by its new name.
60980        (WebCore::ReplaceSelectionCommand::removeUnrenderedTextNodesAtEnds): Ditto.
60981        (WebCore::ReplaceSelectionCommand::positionAtEndOfInsertedContent): Ditto.
60982
60983        * editing/TypingCommand.cpp: Added now-needed includes.
60984        * editing/VisibleUnits.cpp: Ditto.
60985
60986        * editing/htmlediting.cpp:
60987        (WebCore::enclosingElementWithTag): Changed to return an Element instead of a Node,
60988        since nodes other than elements do not have tags.
60989        * editing/htmlediting.h: Ditto.
60990
60991        * editing/mac/EditorMac.mm:
60992        (WebCore::Editor::adjustedSelectionRange): Updated to use the enclosingElementWithTag
60993        function by its new name.
60994        * editing/markup.cpp:
60995        (WebCore::StyledMarkupAccumulator::appendText): Ditto.
60996        (WebCore::StyledMarkupAccumulator::traverseNodesForSerialization): Ditto.
60997        (WebCore::highestAncestorToWrapMarkup): Ditto.
60998        (WebCore::createMarkupInternal): Ditto.
60999        (WebCore::createContextualFragment): Ditto. Use hasTagName instead of hasLocalName,
61000        since the former is now optimized to be the same as the latter was before.
61001
61002        * html/HTMLCollection.cpp:
61003        (WebCore::isMatchingElement): Use hasTagName instead of hasLocalName,
61004        since the former is now optimized to be the same as the latter was before.
61005        (WebCore::nameShouldBeVisibleInDocumentAll): Ditto.
61006        * html/HTMLElement.cpp:
61007        (WebCore::HTMLElement::ieForbidsInsertHTML): Ditto.
61008        (WebCore::unicodeBidiAttributeForDirAuto): Ditto.
61009        (WebCore::HTMLElement::parseBorderWidthAttribute): Ditto.
61010        (WebCore::HTMLElement::setInnerHTML): Ditto.
61011        (WebCore::shouldProhibitSetInnerOuterText): Ditto. Added this to share code between
61012        setInnerText and setOuterText.
61013        (WebCore::HTMLElement::setInnerText): Ditto.
61014        (WebCore::HTMLElement::setOuterText): Ditto.
61015        (WebCore::HTMLElement::rendererIsNeeded): Ditto.
61016        (WebCore::HTMLElement::createElementRenderer): Ditto.
61017
61018        * html/HTMLElement.h: Added hasTagName, which hides the one inherited from Element
61019        and takes the more-specific HTMLQualifiedName type. This means we don't need to check
61020        the namespace at runtime because it's known at compile time. Also put the
61021        implementation of Node::hasTagName for HTMLQualifiedName into this header.
61022
61023        * html/HTMLObjectElement.cpp:
61024        (WebCore::isRecognizedTagName): Updated for change in return type of
61025        HTMLNames::getHTMLTags.
61026
61027        * html/HTMLSelectElement.cpp:
61028        (WebCore::HTMLSelectElement::add): Use hasTagName inastead of hasLocalName.
61029        (WebCore::HTMLSelectElement::value): Use isHTMLOptionElement instead of hasTagName.
61030        Also use a new style for loop and emptyString() instead of "".
61031        (WebCore::HTMLSelectElement::setValue): Ditto.
61032        (WebCore::HTMLSelectElement::setLength): Ditto.
61033        (WebCore::HTMLSelectElement::searchOptionsForValue): Ditto.
61034        (WebCore::HTMLSelectElement::restoreFormControlState): Ditto.
61035
61036        * html/HTMLTableColElement.cpp:
61037        (WebCore::HTMLTableColElement::additionalPresentationAttributeStyle): Use hasTagName
61038        instead of hasLocalName.
61039
61040        * html/HTMLTableRowsCollection.cpp:
61041        (WebCore::isInSection): Updated to use hasTagName and take a reference.
61042        (WebCore::HTMLTableRowsCollection::rowAfter): Pass a reference.
61043
61044        * html/parser/HTMLConstructionSite.cpp: Added now-needed include.
61045
61046        * html/parser/HTMLTreeBuilder.cpp:
61047        (WebCore::createCaseMap): Updated to return a map rather than filling one in, and to
61048        be flxible about the type of the table being used.
61049        (WebCore::adjustSVGTagNameCase): Updated to use NeverDestroyed.
61050        (WebCore::adjustAttributes): Added new helper so we can share more code. Updated
61051        template argument names for clarity.
61052        (WebCore::adjustSVGAttributes): Marked this inline, since it just turns around and
61053        calls a single non-inline function.
61054        (WebCore::adjustMathMLAttributes): Ditto.
61055        (WebCore::addNamesWithPrefix): Changed to take argument by reference instead of pointer.
61056        (WebCore::createForeignAttributesMap): Added. Factors out the map creation from the
61057        function below.
61058        (WebCore::adjustForeignAttributes): Updated for above changes.
61059        (WebCore::HTMLTreeBuilder::processStartTagForInBody): Updated to pass reference.
61060        (WebCore::HTMLTreeBuilder::processTokenInForeignContent): Ditto.
61061
61062        * inspector/InspectorStyleSheet.cpp: Added now-needed include.
61063
61064        * mathml/MathMLElement.h: Added hasTagName, which hides the one inherited from Element
61065        and takes the more-specific MathMLQualifiedName type. This means we don't need to check
61066        the namespace at runtime because it's known at compile time. Also put the
61067        implementation of Node::hasTagName for MathMLQualifiedName into this header.
61068
61069        * mathml/MathMLInlineContainerElement.cpp:
61070        (WebCore::MathMLInlineContainerElement::createElementRenderer): Use hasTagName.
61071
61072        * mathml/MathMLSelectElement.cpp:
61073        (WebCore::MathMLSelectElement::attributeChanged): Use hasTagName.
61074        (WebCore::MathMLSelectElement::getSelectedActionChildAndIndex): Ditto.
61075        (WebCore::MathMLSelectElement::getSelectedActionChild): Ditto.
61076        (WebCore::MathMLSelectElement::getSelectedSemanticsChild): Ditto.
61077        (WebCore::MathMLSelectElement::updateSelectedChild): Ditto.
61078        * mathml/MathMLTextElement.cpp:
61079        (WebCore::MathMLTextElement::createElementRenderer): Ditto.
61080        (WebCore::MathMLTextElement::childShouldCreateRenderer): Ditto.
61081
61082        * platform/mac/HTMLConverter.mm: Added now-needed include.
61083        * rendering/RenderBlockFlow.cpp: Ditto.
61084
61085        * rendering/RenderBoxModelObject.cpp:
61086        (WebCore::RenderBoxModelObject::paintFillLayerExtended): Use hasTagName.
61087        * rendering/RenderElement.cpp:
61088        (WebCore::RenderElement::rendererForRootBackground): Ditto.
61089        * rendering/RenderLayerBacking.cpp:
61090        (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer): Ditto.
61091
61092        * rendering/RenderReplaced.cpp: Added now-needed include.
61093
61094        * rendering/mathml/RenderMathMLScripts.cpp:
61095        (WebCore::RenderMathMLScripts::RenderMathMLScripts): Use hasTagName.
61096        * rendering/mathml/RenderMathMLUnderOver.cpp:
61097        (WebCore::RenderMathMLUnderOver::RenderMathMLUnderOver): Ditto.
61098
61099        * svg/SVGElement.h: Added hasTagName, which hides the one inherited from Element
61100        and takes the more-specific SVGQualifiedName type. This means we don't need to check
61101        the namespace at runtime because it's known at compile time. Also put the
61102        implementation of Node::hasTagName for SVGQualifiedName into this header.
61103
61104        * svg/SVGFontFaceSrcElement.cpp:
61105        (WebCore::SVGFontFaceSrcElement::childrenChanged): Use isSVGFontFaceElement instead
61106        of calling hasTagName.
61107
61108        * svg/SVGUseElement.cpp:
61109        (WebCore::isDirectReference): Changed to take a reference and a more specific type.
61110        (WebCore::SVGUseElement::toClipPath): Added a type cast.
61111        (WebCore::SVGUseElement::rendererClipChild): Use more specific types so we don't
61112        need a type cast.
61113
61114        * xml/parser/XMLDocumentParser.cpp:
61115        (WebCore::XMLDocumentParser::parseDocumentFragment): Added explicit calls to this
61116        unusual call site that has a good reason to use hasLocalName instead of hasTagName.
61117
611182014-03-13  Antti Koivisto  <antti@apple.com>
61119
61120        Try to fix iOS build.
61121
61122        * page/FrameView.cpp:
61123        (WebCore::FrameView::performPostLayoutTasks):
61124
611252014-03-13  Antti Koivisto  <antti@apple.com>
61126
61127        Remove StyleResolver::State::m_parentNode
61128        https://bugs.webkit.org/show_bug.cgi?id=130194
61129
61130        Reviewed by Andreas Kling.
61131
61132        This variable was the "parent" node where the style was being inherited from, not the actual parent.
61133        The code would also recompute it even though the call sites generally know the rendering parent already.
61134
61135        If we consistently pass parent style to StyleResolver::styleForElement we won't need the variable and
61136        the associated code. We also get rid of one more client of NodeRenderingTraversal.
61137
61138        * css/MediaQueryMatcher.cpp:
61139        (WebCore::MediaQueryMatcher::prepareEvaluator):
61140        * css/SVGCSSStyleSelector.cpp:
61141        (WebCore::StyleResolver::applySVGProperty):
61142        * css/StyleMedia.cpp:
61143        (WebCore::StyleMedia::matchMedium):
61144        * css/StyleResolver.cpp:
61145        (WebCore::StyleResolver::State::clear):
61146        (WebCore::StyleResolver::StyleResolver):
61147        (WebCore::StyleResolver::State::initForStyleResolve):
61148        (WebCore::StyleResolver::applyProperty):
61149        * css/StyleResolver.h:
61150        (WebCore::StyleResolver::document):
61151        (WebCore::StyleResolver::State::State):
61152        * dom/Element.cpp:
61153        (WebCore::Element::customStyleForRenderer):
61154        
61155            Add parentStyle parameter.
61156
61157        * dom/Element.h:
61158        * dom/PseudoElement.cpp:
61159        (WebCore::PseudoElement::customStyleForRenderer):
61160        * dom/PseudoElement.h:
61161        * html/HTMLOptGroupElement.cpp:
61162        (WebCore::HTMLOptGroupElement::didAttachRenderers):
61163        (WebCore::HTMLOptGroupElement::updateNonRenderStyle):
61164        (WebCore::HTMLOptGroupElement::customStyleForRenderer):
61165        * html/HTMLOptGroupElement.h:
61166        * html/HTMLOptionElement.cpp:
61167        (WebCore::HTMLOptionElement::didAttachRenderers):
61168        (WebCore::HTMLOptionElement::updateNonRenderStyle):
61169        (WebCore::HTMLOptionElement::customStyleForRenderer):
61170        * html/HTMLOptionElement.h:
61171        * html/HTMLTitleElement.cpp:
61172        (WebCore::HTMLTitleElement::textWithDirection):
61173        * html/shadow/TextControlInnerElements.cpp:
61174        (WebCore::TextControlInnerElement::customStyleForRenderer):
61175        (WebCore::TextControlInnerTextElement::customStyleForRenderer):
61176        * html/shadow/TextControlInnerElements.h:
61177        * rendering/RenderNamedFlowFragment.cpp:
61178        (WebCore::RenderNamedFlowFragment::computeStyleInRegion):
61179        (WebCore::RenderNamedFlowFragment::computeChildrenStyleInRegion):
61180        (WebCore::RenderNamedFlowFragment::setRegionObjectsRegionStyle):
61181        * rendering/RenderNamedFlowFragment.h:
61182        * style/StyleResolveTree.cpp:
61183        (WebCore::Style::styleForElement):
61184        
61185            This used to be Element::styleForRenderer. It is now a standalone static.
61186
61187        (WebCore::Style::elementInsideRegionNeedsRenderer):
61188        (WebCore::Style::createRendererIfNeeded):
61189        (WebCore::Style::resolveLocal):
61190        * svg/SVGElement.cpp:
61191        (WebCore::SVGElement::customStyleForRenderer):
61192        * svg/SVGElement.h:
61193
611942014-03-13  Zalan Bujtas  <zalan@apple.com>
61195
61196        Subpixel rendering: Nested layers with subpixel accumulation paint to wrong position.
61197        https://bugs.webkit.org/show_bug.cgi?id=130153
61198
61199        Reviewed by Simon Fraser.
61200
61201        Subpixels (fractional device pixels here) can accumulate through nested layers. Subpixels
61202        need to be propagated through the layer tree so that painting coordinates match layout coordinates.
61203        
61204        Compositing case: (absolute positioning, 2x display)
61205        parent layer pos(0.3, 0.3) -> floored painting position (0, 0)
61206        child layer pos(10.2, 10.2) -> layout offset from parent (10.2, 10.2), 
61207        but the actual painting offset is (10.5, 10.5) as the result of parent flooring.
61208        
61209        Non-compositing case: (absolute positioning, 2x display)
61210        parent layer pos(0.3, 0.3) -> GraphicsContext is translated to (0, 0).
61211        child layer pos(10.2, 10.2) -> layout offset from parent (10.2, 10.2)
61212        but the GraphicsContext's offset is (10.5, 10.5) as the result of the parent's translate.   
61213
61214        In both cases, without the subpixel adjustment, we'd paint the current layer at (10.0, 10.0)
61215        after flooring, while its painting position is actually (10.5, 10.5).
61216        Subpixels do accumulate through nested layers.
61217
61218        Tests: compositing/hidpi-nested-compositing-layers-with-subpixel-accumulation.html
61219               fast/layers/hidpi-nested-layers-with-subpixel-accumulation.html
61220
61221        * rendering/RenderLayer.cpp:
61222        (WebCore::RenderLayer::paintLayerByApplyingTransform):
61223        * rendering/RenderLayerBacking.cpp:
61224        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
61225        * rendering/RenderLayerBacking.h:
61226        (WebCore::RenderLayerBacking::devicePixelFractionFromRenderer):
61227
612282014-03-13  Radu Stavila  <stavila@adobe.com>
61229
61230        The scrolledContentOffset method should handle the hasOverflowClip check
61231        https://bugs.webkit.org/show_bug.cgi?id=130028
61232
61233        Reviewed by Antti Koivisto.
61234
61235        Before this patch, every call to RenderBox::scrolledContentOffset was guarded by the
61236        hasOverflowClip check, because the scrolledContentOffset method would ASSERT(hasOverflowClip()).
61237        This was simplified by moving the hasOverflowClip check inside the scrolledContentOffset method
61238        and returning (0, 0) for elements that do not clip the overflow.
61239
61240        No new tests needed, just a refactor.
61241
61242        * editing/VisibleUnits.cpp:
61243        (WebCore::absoluteLineDirectionPointToLocalPointInBlock):
61244        * rendering/RenderBlock.cpp:
61245        (WebCore::RenderBlock::paintObject):
61246        (WebCore::RenderBlock::selectionGapRectsForRepaint):
61247        (WebCore::RenderBlock::paintSelection):
61248        (WebCore::RenderBlock::nodeAtPoint):
61249        (WebCore::RenderBlock::offsetForContents):
61250        * rendering/RenderBox.cpp:
61251        (WebCore::RenderBox::scrolledContentOffset):
61252        (WebCore::RenderBox::offsetFromContainer):
61253        * rendering/RenderInline.cpp:
61254        (WebCore::RenderInline::offsetFromContainer):
61255        * rendering/RenderLayer.cpp:
61256        (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
61257        (WebCore::RenderLayer::calculateClipRects):
61258        * rendering/RenderNamedFlowThread.cpp:
61259        (WebCore::RenderNamedFlowThread::decorationsClipRectForBoxInNamedFlowFragment):
61260        * rendering/RenderObject.cpp:
61261        (WebCore::RenderObject::mapLocalToContainer):
61262        (WebCore::RenderObject::pushMappingToContainer):
61263        (WebCore::RenderObject::mapAbsoluteToLocalPoint):
61264        (WebCore::RenderObject::offsetFromContainer):
61265        * rendering/RenderTextControl.cpp:
61266        (WebCore::RenderTextControl::hitInnerTextElement):
61267
612682014-03-13  Chris Fleizach  <cfleizach@apple.com>
61269
61270        AX: accessibility data table heuristics fail on this jQuery table
61271        https://bugs.webkit.org/show_bug.cgi?id=129369
61272
61273        Reviewed by Mario Sanchez Prada.
61274
61275        Updated accessibility/table-detection.html
61276
61277        If a table uses display style of table-row-group, the RenderTable gets disassociated from the HTMLTableElement.
61278        We can find that element in a different way by asking for the parent of the first table section.
61279
61280        * accessibility/AccessibilityRenderObject.cpp:
61281        (WebCore::AccessibilityRenderObject::activeDescendant):
61282            This method was accessing an object's element unsafely and this table change exposed the issue.
61283        * accessibility/AccessibilityTable.cpp:
61284        (WebCore::AccessibilityTable::tableElement):
61285        (WebCore::AccessibilityTable::isDataTable):
61286        * accessibility/AccessibilityTable.h:
61287
612882014-03-13  Antti Koivisto  <antti@apple.com>
61289
61290        Ensure that layout milestones complete in all cases
61291        https://bugs.webkit.org/show_bug.cgi?id=130101
61292        
61293        Reviewed by Darin Adler.
61294        
61295        Milestones fail to complete in some testing scenarios.
61296
61297        * dom/Document.cpp:
61298        (WebCore::Document::setParsing):
61299        
61300            Check if we need to fire layout milestones if parsing finishes without pending layout.
61301            Parsing status affects whether the document is considered non-empty and that affects
61302            layout milestones.
61303
61304            Remove explicit layout scheduling here, layout timer will be active already if there
61305            is a layout pending
61306
61307        * page/FrameView.cpp:
61308        (WebCore::FrameView::performPostLayoutTasks):
61309        (WebCore::FrameView::firePaintRelatedMilestonesIfNeeded):
61310        
61311            Renamed for consistency
61312
61313        (WebCore::FrameView::fireLayoutRelatedMilestonesIfNeeded):
61314        
61315            Factor layout milestone firing into a function.
61316
61317        * page/FrameView.h:
61318
613192014-03-12  Brian Burg  <bburg@apple.com>
61320
61321        Web Replay: add infrastructure for memoizing nondeterministic DOM APIs
61322        https://bugs.webkit.org/show_bug.cgi?id=129445
61323
61324        Reviewed by Timothy Hatcher.
61325
61326        Add two pieces of infrastructure to support memoization of selected DOM APIs.
61327
61328        The first piece is MemoizedDOMResult, a templated replay input class that knows
61329        how to serialize a DOM API's return value, ctype, and exception code.
61330
61331        The second piece is the addition of a new IDL attribute called `Nondeterministic`.
61332        When placed on a DOM function or attribute, the code generator will emit code
61333        to save the DOM API's return value or use a memoized return value instead,
61334        depending on the current replay state. This new emitted code path is behind
61335        a feature flag.
61336
61337        No new tests, as no new inputs are addressed by this change. Per-DOM API replay
61338        regression tests will be added when those APIs are marked as nondeterministic.
61339
61340        * WebCore.xcodeproj/project.pbxproj:
61341        * bindings/scripts/CodeGeneratorJS.pm: Add support of the `Nondeterministic` attribute.
61342        (GenerateImplementation): Handle cases for attributes and getters with exceptions.
61343        (GenerateImplementationFunctionCall): Handle function calls with and without exceptions.
61344        (GetNativeTypeForMemoization): Added. Converts DOMString to WTF::String.
61345        * bindings/scripts/IDLAttributes.txt: Add new `Nondeterministic` attribute.
61346        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
61347        (WebCore::jsTestEventTargetPrototypeFunctionItem):
61348        (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
61349        * bindings/scripts/test/JS/JSTestInterface.cpp:
61350        (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
61351        (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
61352        * bindings/scripts/test/JS/JSTestObj.cpp:
61353        (WebCore::jsTestObjAttrWithGetterException):
61354        (WebCore::jsTestObjStringAttrWithGetterException):
61355        (WebCore::jsTestObjWithScriptStateAttributeRaises):
61356        (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
61357        (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
61358        (WebCore::jsTestObjNullableStringValue):
61359        (WebCore::jsTestObjPrototypeFunctionByteMethod):
61360        (WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
61361        (WebCore::jsTestObjPrototypeFunctionOctetMethod):
61362        (WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
61363        (WebCore::jsTestObjPrototypeFunctionLongMethod):
61364        (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
61365        (WebCore::jsTestObjPrototypeFunctionObjMethod):
61366        (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
61367        (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
61368        (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
61369        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
61370        (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
61371        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
61372        (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
61373        (WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
61374        (WebCore::jsTestObjConstructorFunctionClassMethodWithOptional):
61375        (WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
61376        (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
61377        (WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
61378        (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
61379        (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
61380        (WebCore::jsTestObjPrototypeFunctionStrictFunction):
61381        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
61382        (WebCore::jsTestObjPrototypeFunctionStrictFunctionWithArray):
61383        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
61384        (WebCore::jsTestTypedefsAttrWithGetterException):
61385        (WebCore::jsTestTypedefsStringAttrWithGetterException):
61386        (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
61387        (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
61388        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction):
61389        (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction2):
61390        (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
61391
61392        * replay/AllReplayInputs.h:
61393        * replay/MemoizedDOMResult.cpp: Added.
61394        (WebCore::MemoizedDOMResultBase::type):
61395        (WebCore::MemoizedDOMResultBase::createFromEncodedResult):
61396        (InputTraits<MemoizedDOMResultBase>::type):
61397        (InputTraits<MemoizedDOMResultBase>::encode):
61398        (InputTraits<MemoizedDOMResultBase>::decode):
61399
61400        * replay/MemoizedDOMResult.h: Added. Every specialization of MemoizedDOMResult<T>
61401        stores a binding name, ctype, result value of type T, and optional exception code.
61402        The ctype-specific code uses the CTypeTraits struct to abstract over enum names and
61403        compiler types. The actual encode/decode methods just use methods from EncodingTraits<T>.
61404
61405        (WebCore::MemoizedDOMResultBase::MemoizedDOMResultBase):
61406        (WebCore::MemoizedDOMResultBase::~MemoizedDOMResultBase):
61407        (WebCore::MemoizedDOMResultBase::attribute):
61408        (WebCore::MemoizedDOMResultBase::ctype):
61409        (WebCore::MemoizedDOMResultBase::exceptionCode):
61410        (WebCore::CTypeTraits::decode):
61411        (WebCore::MemoizedDOMResultBase::convertTo):
61412        (JSC::InputTraits<MemoizedDOMResultBase>::queue):
61413        * replay/ReplayInputTypes.cpp: See below.
61414        (WebCore::ReplayInputTypes::ReplayInputTypes):
61415        * replay/ReplayInputTypes.h: See below.
61416        * replay/SerializationMethods.cpp: We need to special-case the encoding
61417        and decoding of MemoizedDOMResult inputs because the input is not part of
61418        the generated per-framework replay inputs enum.
61419        (JSC::EncodingTraits<NondeterministicInputBase>::encodeValue):
61420        (JSC::EncodingTraits<NondeterministicInputBase>::decodeValue):
61421
61422        * replay/WebInputs.json: Add the EncodedCType enum as an external enum type,
61423        so that we can use a generated EncodingTraits specialization to encode the enum.
61424
614252014-03-11  Jae Hyun Park  <jaepark@webkit.org>
61426
61427        Make HTMLCanvasElement::is3D private
61428        https://bugs.webkit.org/show_bug.cgi?id=130117
61429
61430        Reviewed by Anders Carlsson.
61431
61432        HTMLCanvasElement::is3D is not used anywhere except HTMLCanvasElement.
61433        So, make HTMLCanvasElement::is3D a private method. Also, make more use
61434        of is3D method.
61435
61436        * html/HTMLCanvasElement.cpp:
61437        (WebCore::HTMLCanvasElement::reset):
61438        (WebCore::HTMLCanvasElement::getImageData):
61439        * html/HTMLCanvasElement.h:
61440
614412014-03-12  Joseph Pecoraro  <pecoraro@apple.com>
61442
61443        Web Inspector: OS X View Indication
61444        https://bugs.webkit.org/show_bug.cgi?id=130119
61445
61446        Reviewed by Timothy Hatcher.
61447
61448        * inspector/InspectorController.cpp:
61449        (WebCore::InspectorController::setIndicating):
61450        OS X will handles this in the InspectorOverlay. iOS does not use the
61451        overlay, so it handles this in the client (already implemented).
61452
61453        * inspector/InspectorOverlay.h:
61454        Remove unused m_size, and add a boolean for the indicating state.
61455
61456        * inspector/InspectorOverlay.cpp:
61457        (WebCore::InspectorOverlay::InspectorOverlay):
61458        (WebCore::InspectorOverlay::shouldShowOverlay):
61459        Helper for determining if we should show the overlay or not.
61460
61461        (WebCore::InspectorOverlay::setIndicating):
61462        Set the state and trigger an overlay update.
61463
61464        (WebCore::InspectorOverlay::paint):
61465        (WebCore::InspectorOverlay::update):
61466        (WebCore::InspectorOverlay::drawGutter):
61467        (WebCore::InspectorOverlay::evaluateInOverlay):
61468        Simplification of existing methods.
61469
61470        * inspector/InspectorOverlayPage.css:
61471        (.indicate):
61472        Give the page a blue tint, matching the node highlight color.
61473
61474        * inspector/InspectorOverlayPage.js:
61475        (showPageIndication):
61476        (hidePageIndication):
61477        Add / remove a body style class.
61478
61479        (drawNodeHighlight):
61480        Remove unused parameters.
61481
614822014-03-12  Joseph Pecoraro  <pecoraro@apple.com>
61483
61484        Web Inspector: Disable REMOTE_INSPECTOR in earlier OS X releases
61485        https://bugs.webkit.org/show_bug.cgi?id=130118
61486
61487        Reviewed by Timothy Hatcher.
61488
61489        * Configurations/FeatureDefines.xcconfig:
61490
614912014-03-12  Tim Horton  <timothy_horton@apple.com>
61492
61493        Build fix for ENABLE(IMAGE_CONTROLS) after 165479
61494
61495        * rendering/RenderThemeMac.mm:
61496        (WebCore::RenderThemeMac::servicesRolloverButtonCell):
61497        (WebCore::RenderThemeMac::paintImageControlsButton):
61498        (WebCore::RenderThemeMac::imageControlsButtonSize):
61499        Don't try to use the AppKit methods that are only available on 64-bit.
61500
615012014-03-12  Brent Fulgham  <bfulgham@apple.com>
61502
61503        [WebVTT] HTML5 "space" cahracters around "-->" are not required
61504        https://bugs.webkit.org/show_bug.cgi?id=117421
61505
61506        Reviewed by Eric Carlson.
61507
61508        Merged from Blink (patch by caitpotter88@gmail.com):
61509        https://chromium.googlesource.com/chromium/blink/+/4ef469cd627a13696b88e285ae28a60e38f9c286
61510        http://crbug.com/242158
61511
61512        New tests: media/track/track-webvtt-tc029-timings-whitespace.html
61513
61514        * html/track/WebVTTParser.cpp:
61515        (WebCore::WebVTTParser::collectTimingsAndSettings): Make whitespace around cue-timings optional.
61516
615172014-03-12  Commit Queue  <commit-queue@webkit.org>
61518
61519        Unreviewed, rolling out r165482.
61520        https://bugs.webkit.org/show_bug.cgi?id=130157
61521
61522        Broke the windows build; "error C2466: cannot allocate an
61523        array of constant size 0" (Requested by jernoble on #webkit).
61524
61525        Reverted changeset:
61526
61527        "Reduce memory use for static property maps"
61528        https://bugs.webkit.org/show_bug.cgi?id=129986
61529        http://trac.webkit.org/changeset/165482
61530
615312014-03-12  Brian Burg  <bburg@apple.com>
61532
61533        Web Inspector receives spurious setScriptEnabled instrumentation calls
61534        https://bugs.webkit.org/show_bug.cgi?id=130147
61535
61536        Reviewed by Timothy Hatcher.
61537
61538        When page settings change, inspector instrumentation should only fire if
61539        the scriptsEnabled setting actually changes from the previous setting. But
61540        due to an unnecessary PLATFORM(IOS) guard, the inspector was being notified
61541        on every settings update even if nothing changed.
61542
61543        This manifested as lots of Page.scriptsEnabled messages being sent to
61544        the inspector frontend as the Inspector window is dragged.
61545
61546        * page/Settings.cpp:
61547        (WebCore::Settings::setScriptEnabled): Remove PLATFORM(IOS) from early return.
61548
615492014-03-12  Simon Fraser  <simon.fraser@apple.com>
61550
61551        Have the scrolling tree track the viewport size, not the viewport rect
61552        https://bugs.webkit.org/show_bug.cgi?id=130141
61553
61554        Reviewed by Beth Dakin.
61555
61556        The scrolling tree only needs to know the size of the viewport, not its
61557        origin, since the origin is deduced from the updated scroll position.
61558
61559        * WebCore.exp.in:
61560        * page/scrolling/AsyncScrollingCoordinator.cpp:
61561        (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
61562        * page/scrolling/ScrollingStateScrollingNode.cpp:
61563        (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
61564        (WebCore::ScrollingStateScrollingNode::setViewportSize):
61565        (WebCore::ScrollingStateScrollingNode::dumpProperties):
61566        * page/scrolling/ScrollingStateScrollingNode.h:
61567        * page/scrolling/ScrollingTreeScrollingNode.cpp:
61568        (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
61569        * page/scrolling/ScrollingTreeScrollingNode.h:
61570        (WebCore::ScrollingTreeScrollingNode::viewportSize):
61571        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
61572        (WebCore::ScrollingTreeScrollingNodeIOS::setScrollLayerPosition):
61573        (WebCore::ScrollingTreeScrollingNodeIOS::maximumScrollPosition):
61574        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
61575        (WebCore::ScrollingTreeScrollingNodeMac::updateAfterChildren):
61576        (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
61577        (WebCore::ScrollingTreeScrollingNodeMac::maximumScrollPosition):
61578        (WebCore::ScrollingTreeScrollingNodeMac::logExposedUnfilledArea):
61579
615802014-03-12  Simon Fraser  <simon.fraser@apple.com>
61581
61582        Spelling is hard
61583        https://bugs.webkit.org/show_bug.cgi?id=130146
61584
61585        Reviewed by Beth Dakin.
61586
61587        Fix spelling (constained -> constrained).
61588
61589        * rendering/RenderLayerModelObject.cpp:
61590        (WebCore::RenderLayerModelObject::styleDidChange):
61591
615922014-03-12  Simon Fraser  <simon.fraser@apple.com>
61593
61594        Change scrollOffsetForFixedPosition() to do LayoutUnit math
61595        https://bugs.webkit.org/show_bug.cgi?id=129981
61596
61597        Reviewed by Beth Dakin.
61598
61599        FrameView::scrollOffsetForFixedPosition() returned an IntSize,
61600        but to allow subpixel scroll offsets, we need it to return a LayoutSize.
61601        
61602        Fix code that calls this to use more LayoutUnit math.
61603        
61604        This progresses fixed background images on zoom, which cam now be subpixel
61605        positioned.
61606
61607        * WebCore.exp.in:
61608        * page/FrameView.cpp:
61609        (WebCore::FrameView::viewportConstrainedVisibleContentRect):
61610        (WebCore::FrameView::scrollOffsetForFixedPosition):
61611        * page/FrameView.h:
61612        * page/scrolling/AsyncScrollingCoordinator.cpp:
61613        (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
61614        * platform/ScrollableArea.cpp:
61615        (WebCore::ScrollableArea::constrainScrollPositionForOverhang):
61616        * platform/ScrollableArea.h:
61617        * rendering/RenderBoxModelObject.cpp:
61618        (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
61619        * rendering/RenderLayer.cpp:
61620        (WebCore::RenderLayer::calculateClipRects):
61621        * rendering/RenderLayerBacking.cpp:
61622        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
61623        * rendering/RenderLayerCompositor.cpp:
61624        (WebCore::RenderLayerCompositor::updateScrollLayerPosition):
61625
616262014-03-12  Gavin Barraclough  <barraclough@apple.com>
61627
61628        Reduce memory use for static property maps
61629        https://bugs.webkit.org/show_bug.cgi?id=129986
61630
61631        Reviewed by Andreas Kling.
61632
61633        Static property tables are currently duplicated on first use from read-only memory into dirty memory
61634        in every process, and since the entries are large (48 bytes) and the tables can be unusually sparse
61635        (we use a custom hash table without a rehash) a lot of memory may be wasted.
61636
61637        * bindings/js/JSDOMBinding.h:
61638        (WebCore::getStaticValueSlotEntryWithoutCaching):
61639        (WebCore::getStaticValueSlotEntryWithoutCaching<JSDOMWrapper>):
61640            - HashEntry -> HashTableValue.
61641        * bindings/js/JSDOMWindowCustom.cpp:
61642        (WebCore::JSDOMWindow::getOwnPropertySlot):
61643            - HashEntry -> HashTableValue.
61644        * bindings/js/JSHistoryCustom.cpp:
61645        (WebCore::JSHistory::getOwnPropertySlotDelegate):
61646            - HashEntry -> HashTableValue.
61647        * bindings/js/JSLocationCustom.cpp:
61648        (WebCore::JSLocation::getOwnPropertySlotDelegate):
61649        (WebCore::JSLocation::putDelegate):
61650            - HashEntry -> HashTableValue.
61651        * bindings/scripts/CodeGeneratorJS.pm:
61652        (GenerateGetOwnPropertySlotBody):
61653            - HashEntry -> HashTableValue.
61654        (GenerateHashTable):
61655            - emit the hash table index into the derived source (we were calculating this already to ensure chaining does not get too deep).
61656
616572014-03-12  Tim Horton  <timothy_horton@apple.com>
61658
61659        Hook up image controls for WebKit1
61660        https://bugs.webkit.org/show_bug.cgi?id=130062
61661        <rdar://problem/15964809>
61662
61663        Reviewed by Brady Eidson.
61664
61665        * WebCore.exp.in:
61666        * WebCore.xcodeproj/project.pbxproj:
61667        * css/CSSPrimitiveValueMappings.h:
61668        Fix some header ordering.
61669
61670        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
61671        Handle mapping ImageControlsButtonPart to the -webkit-appearance value CSSValueImageControlsButton.
61672
61673        * css/CSSValueKeywords.in:
61674        * platform/ThemeTypes.h:
61675        Add a -webkit-appearance value image-controls-button, and an associated control part.
61676
61677        * dom/Node.h:
61678        (WebCore::Node::isImageControlsButtonElement): Added.
61679
61680        * html/shadow/mac/ImageControlsButtonElementMac.cpp: Added.
61681        (WebCore::RenderImageControlsButton::RenderImageControlsButton):
61682        (WebCore::RenderImageControlsButton::~RenderImageControlsButton):
61683        (WebCore::RenderImageControlsButton::updateLogicalWidth):
61684        (WebCore::RenderImageControlsButton::computeLogicalHeight):
61685        (WebCore::ImageControlsButtonElementMac::ImageControlsButtonElementMac):
61686        (WebCore::ImageControlsButtonElementMac::~ImageControlsButtonElementMac):
61687        (WebCore::ImageControlsButtonElementMac::maybeCreate):
61688        (WebCore::ImageControlsButtonElementMac::defaultEventHandler):
61689        (WebCore::ImageControlsButtonElementMac::createElementRenderer):
61690        * html/shadow/mac/ImageControlsButtonElementMac.h: Added.
61691        Add a new element/renderer pair for the single button that comprises image controls on Mac.
61692        RenderImageControlsButton gets its size from the theme's imageControlsButtonSize.
61693
61694        * html/shadow/mac/ImageControlsRootElementMac.cpp:
61695        (WebCore::RenderImageControls::RenderImageControls):
61696        (WebCore::RenderImageControls::~RenderImageControls):
61697        (WebCore::RenderImageControls::updateLogicalWidth):
61698        (WebCore::RenderImageControls::computeLogicalHeight):
61699        (WebCore::ImageControlsRootElement::maybeCreate):
61700        (WebCore::ImageControlsRootElementMac::ImageControlsRootElementMac):
61701        (WebCore::ImageControlsRootElementMac::~ImageControlsRootElementMac):
61702        (WebCore::ImageControlsRootElementMac::createElementRenderer):
61703        * html/shadow/mac/ImageControlsRootElementMac.h:
61704        Add a custom renderer for the root image controls element on Mac, which inherits
61705        its size from the <img> that it is shadowing.
61706        Add a ImageControlsButtonElementMac as the sole child of the root element.
61707
61708        * html/shadow/mac/imageControlsMac.css:
61709        (.x-webkit-image-controls):
61710        (.x-webkit-image-controls-button):
61711        (.x-webkit-image-controls:hover .x-webkit-image-controls-button):
61712        The button should become opaque whenever *any* part of the image is hovered,
61713        not just the button itself. Also, use the new image-controls-button -webkit-appearance
61714        value to get the appropriate appearance from the theme.
61715
61716        * page/ContextMenuContext.cpp:
61717        (WebCore::ContextMenuContext::ContextMenuContext):
61718        * page/ContextMenuContext.h:
61719        (WebCore::ContextMenuContext::setControlledImage):
61720        (WebCore::ContextMenuContext::controlledImage):
61721        Store an image on the ContextMenuContext instead of just whether we hit an image.
61722
61723        * page/ContextMenuController.cpp:
61724        (WebCore::ContextMenuController::handleContextMenuEvent):
61725        (WebCore::ContextMenuController::showContextMenu):
61726        (WebCore::imageFromImageElementNode):
61727        (WebCore::ContextMenuController::maybeCreateContextMenu):
61728        (WebCore::ContextMenuController::populate):
61729        Keep track of the hit image in the ContextMenuContext.
61730
61731        (WebCore::ContextMenuController::replaceControlledImage):
61732        Replace the hit image with a new one.
61733
61734        * page/ContextMenuController.h:
61735
61736        * rendering/RenderReplaced.h:
61737        Fix a double-space typo.
61738
61739        * rendering/RenderTheme.cpp:
61740        (WebCore::RenderTheme::adjustStyle):
61741        (WebCore::RenderTheme::paint):
61742        (WebCore::RenderTheme::paintBorderOnly):
61743        (WebCore::RenderTheme::paintDecorations):
61744        Handle ImageControlsButtonPart in RenderTheme's switches.
61745
61746        * rendering/RenderTheme.h:
61747        (WebCore::RenderTheme::imageControlsButtonSize):
61748        (WebCore::RenderTheme::paintImageControlsButton):
61749        * rendering/RenderThemeMac.h:
61750        * rendering/RenderThemeMac.mm:
61751        (WebCore::RenderThemeMac::servicesRolloverButtonCell):
61752        (WebCore::RenderThemeMac::paintImageControlsButton):
61753        (WebCore::RenderThemeMac::imageControlsButtonSize):
61754        Paint the image controls button.
61755
61756        * editing/ios/EditorIOS.mm:
61757        (WebCore::Editor::WebContentReader::readImage):
61758        (WebCore::Editor::WebContentReader::readURL):
61759        * editing/mac/EditorMac.mm:
61760        (WebCore::Editor::WebContentReader::readImage):
61761        * platform/URL.cpp:
61762        (WebCore::URL::fakeURLWithRelativePart):
61763        * platform/URL.h:
61764        Factor out code to create a "fake" URL (with a UUID "hostname" and the
61765        webkit-fake-url protocol), and make use of it where we construct such URLs.
61766
617672014-03-12  Jer Noble  <jer.noble@apple.com>
61768
61769        [Mac] Crash when running media/fallback.html test in MediaPlayerPrivateAVFoundation::scheduleMainThreadNotification()
61770        https://bugs.webkit.org/show_bug.cgi?id=130136
61771
61772        Reviewed by Eric Carlson.
61773
61774        MediaPlayerPrivateAVFoundation is trying to lock its m_queueMutex from an async thread after
61775        while being destroyed in the main thread. To resolve this race condition, redispatch from
61776        the async thread to the main thread, and use a WeakPtr to determine whether the object has
61777        been destroyed or not.
61778
61779        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
61780        (WebCore::MediaPlayerPrivateAVFoundationObjC::checkPlayability):
61781
617822014-03-12  Brent Fulgham  <bfulgham@apple.com>
61783
61784        [Win] Remove use of QTSDK
61785        https://bugs.webkit.org/show_bug.cgi?id=130049
61786
61787        Reviewed by Darin Adler.
61788
61789        Media testing already covers this functionality.
61790
61791        * WebCore.vcxproj/WebCore.vcxproj: Remove QuickTime files.
61792        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
61793        * platform/graphics/MediaPlayer.h: Remove QuickTime and Chromium
61794        media references.
61795        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp: Removed.
61796        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h: Removed.
61797        * platform/graphics/win/QTCFDictionary.cpp: Removed.
61798        * platform/graphics/win/QTCFDictionary.h: Removed.
61799        * platform/graphics/win/QTDecompressionSession.cpp: Removed.
61800        * platform/graphics/win/QTDecompressionSession.h: Removed.
61801        * platform/graphics/win/QTMovie.cpp: Removed.
61802        * platform/graphics/win/QTMovie.h: Removed.
61803        * platform/graphics/win/QTMovieGWorld.cpp: Removed.
61804        * platform/graphics/win/QTMovieGWorld.h: Removed.
61805        * platform/graphics/win/QTMovieTask.cpp: Removed.
61806        * platform/graphics/win/QTMovieTask.h: Removed.
61807        * platform/graphics/win/QTMovieVisualContext.cpp: Removed.
61808        * platform/graphics/win/QTMovieVisualContext.h: Removed.
61809        * platform/graphics/win/QTMovieWinTimer.cpp: Removed.
61810        * platform/graphics/win/QTMovieWinTimer.h: Removed.
61811        * platform/graphics/win/QTPixelBuffer.cpp: Removed.
61812        * platform/graphics/win/QTPixelBuffer.h: Removed.
61813        * platform/graphics/win/QTTrack.cpp: Removed.
61814        * platform/graphics/win/QTTrack.h: Removed.
61815        * plugins/win/PluginDatabaseWin.cpp:
61816        (WebCore::PluginDatabase::defaultPluginDirectories): Don't look
61817        for the QuickTime plugin anymore.
61818
618192014-03-12  David Kilzer  <ddkilzer@apple.com>
61820
61821        Fix build after r165472
61822
61823        Fixes the following build failure:
61824
61825            WebCore/rendering/shapes/Shape.cpp:97:20: error: unused function 'ensureRadiiDoNotOverlap' [-Werror,-Wunused-function]
61826            static inline void ensureRadiiDoNotOverlap(FloatRect& bounds, FloatSize& radii)
61827                               ^
61828            1 error generated.
61829
61830        * rendering/shapes/Shape.cpp:
61831        (ensureRadiiDoNotOverlap): Remove unused function.
61832
618332014-03-12  Bem Jones-Bey  <bjonesbe@adobe.com>
61834
61835        [CSS Shapes] Remove deprecated shapes
61836        https://bugs.webkit.org/show_bug.cgi?id=125235
61837
61838        Reviewed by Dirk Schulze.
61839
61840        Remove support for deprecated shape types and syntax. These have
61841        already been removed from the CSS Shapes specification, so this aligns
61842        the implementation with the specification.
61843
61844        The "new" tests below were simply moved from the old csswg directory,
61845        as they were the only tests there that applied to the current syntax.
61846
61847        Tests: fast/shapes/shape-outside-floats/shape-outside-floats-polygon-000.html
61848               fast/shapes/shape-outside-floats/shape-outside-floats-polygon-001.html
61849               fast/shapes/shape-outside-floats/shape-outside-floats-polygon-002.html
61850
61851        * css/BasicShapeFunctions.cpp:
61852        (WebCore::valueForBasicShape):
61853        (WebCore::basicShapeForValue):
61854        * css/BasicShapeFunctions.h:
61855        * css/CSSBasicShapes.cpp:
61856        * css/CSSBasicShapes.h:
61857        * css/CSSParser.cpp:
61858        (WebCore::CSSParser::parseBasicShape):
61859        * rendering/shapes/Shape.cpp:
61860        (WebCore::Shape::createShape):
61861        * rendering/shapes/ShapeInsideInfo.cpp:
61862        (WebCore::ShapeInsideInfo::isEnabledFor):
61863        * rendering/style/BasicShapes.cpp:
61864        * rendering/style/BasicShapes.h:
61865
618662014-03-12  Carlos Garcia Campos  <cgarcia@igalia.com>
61867
61868        [GTK] [Stable] deadlock in gobject introspection
61869        https://bugs.webkit.org/show_bug.cgi?id=125651
61870
61871        Reviewed by Sergio Villar Senin.
61872
61873        Make the default SoupNetworkSession a destroyable object to ensure
61874        the wrapped SoupSession is finalized when the process finishes. This
61875        is important because soup cancels any ongoing connection when finalized.
61876
61877        * platform/network/soup/SoupNetworkSession.cpp:
61878        (WebCore::SoupNetworkSession::defaultSession): Do not use NeverDestroyed.
61879        * platform/network/soup/SoupNetworkSession.h:
61880
618812014-03-12  Antti Koivisto  <antti@apple.com>
61882
61883        Don't use NodeRenderingTraversal for pseudo elements
61884        https://bugs.webkit.org/show_bug.cgi?id=130091
61885
61886        Reviewed by Andreas Kling.
61887
61888        Make traversing during style resolve more comprehensible by handling before/after pseudo elements explicitly.
61889
61890        With this patch NodeRenderingTraversal is only needed for InsertionPoints (which are nothing but an implementation
61891        detail of the <details> element at this point).
61892
61893        * dom/Element.cpp:
61894        (WebCore::shouldUseNodeRenderingTraversalSlowPath):
61895        
61896            PseudoElements don't need the slow path anymore.
61897
61898        (WebCore::Element::setBeforePseudoElement):
61899        (WebCore::Element::setAfterPseudoElement):
61900        (WebCore::Element::clearBeforePseudoElement):
61901        (WebCore::Element::clearAfterPseudoElement):
61902        * dom/NodeRenderingTraversal.cpp:
61903        (WebCore::NodeRenderingTraversal::traverseParent):
61904        (WebCore::NodeRenderingTraversal::firstChildSlow):
61905        (WebCore::NodeRenderingTraversal::nextSiblingSlow):
61906        (WebCore::NodeRenderingTraversal::previousSiblingSlow):
61907        * dom/NodeRenderingTraversal.h:
61908        (WebCore::NodeRenderingTraversal::firstChild):
61909        * style/StyleResolveTree.cpp:
61910        (WebCore::Style::nextSiblingRenderer):
61911        
61912            Add ::before/::after pseudo element handling here.
61913
61914        (WebCore::Style::shouldCreateRenderer):
61915        (WebCore::Style::elementInsideRegionNeedsRenderer):
61916        (WebCore::Style::createRendererIfNeeded):
61917        (WebCore::Style::previousSiblingRenderer):
61918        
61919            Add ::before pseudo element handling here (text node can't be ::after).
61920
61921        (WebCore::Style::reattachTextRenderersForWhitespaceOnlySiblingsAfterAttachIfNeeded):
61922        (WebCore::Style::textRendererIsNeeded):
61923        (WebCore::Style::createTextRendererIfNeeded):
61924        (WebCore::Style::attachTextRenderer):
61925        (WebCore::Style::updateTextRendererAfterContentChange):
61926        (WebCore::Style::attachChildren):
61927        (WebCore::Style::attachDistributedChildren):
61928        
61929            Handle InsertionPoints in one place.
61930
61931        (WebCore::Style::attachShadowRoot):
61932        (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded):
61933        (WebCore::Style::attachRenderTree):
61934        (WebCore::Style::resolveLocal):
61935        (WebCore::Style::updateTextStyle):
61936        (WebCore::Style::resolveShadowTree):
61937        (WebCore::Style::updateBeforeOrAfterPseudoElement):
61938        (WebCore::Style::resolveTree):
61939        
61940            Pass the rendering parent around to various functions instead of determining it repeatedly by calling 
61941            NodeRenderingTraversal::parent. It is always the same for all direct children being resolved and generally just
61942            the parent element.
61943
619442014-03-12  Frédéric Wang  <fred.wang@free.fr>
61945
61946        Invisible Operators should not add space.
61947        https://bugs.webkit.org/show_bug.cgi?id=115786
61948
61949        Reviewed by Chris Fleizach.
61950
61951        This change adds special handling for invisible operator to ensure they really behave as empty box. We now ignore their glyph widths and do not paint them.
61952
61953        Test: mathml/presentation/mo-invisible.html
61954
61955        * rendering/mathml/RenderMathMLOperator.cpp:
61956        (WebCore::RenderMathMLOperator::computePreferredLogicalWidths):
61957        (WebCore::RenderMathMLOperator::paint):
61958        * rendering/mathml/RenderMathMLOperator.h:
61959
619602014-03-11  Frédéric Wang  <fred.wang@free.fr>
61961
61962        Implement MathML spacing around operators .
61963        https://bugs.webkit.org/show_bug.cgi?id=115787
61964
61965        Reviewed by Chris Fleizach.
61966
61967        This makes the <mo> operators use the lspace/rspace properties to
61968        determine their spacing. The spacing is now consistent with the one
61969        of <mfenced> and as a consequence bug 118843 is fixed. This also ensures
61970        that the rendering of <mo> elements is updated when the form or
61971        attributes are changed.
61972
61973        Tests: mathml/presentation/dir-mo.html
61974               mathml/presentation/mo-form-dynamic.html
61975               mathml/presentation/mo-form-minus-plus.html
61976               mathml/presentation/mo-form.html
61977               mathml/presentation/mo-lspace-rspace-dynamic.html
61978               mathml/presentation/mo-lspace-rspace.html
61979               mathml/presentation/mo-whitespaces.html
61980
61981        * css/mathml.css:
61982        * mathml/MathMLInlineContainerElement.cpp:
61983        (WebCore::MathMLInlineContainerElement::childrenChanged):
61984        * mathml/MathMLInlineContainerElement.h:
61985        * rendering/mathml/RenderMathMLOperator.cpp:
61986        (WebCore::RenderMathMLOperator::setOperatorPropertiesFromOpDictEntry):
61987        (WebCore::RenderMathMLOperator::SetOperatorProperties):
61988        (WebCore::RenderMathMLOperator::updateFromElement):
61989        (WebCore::RenderMathMLOperator::updateOperatorProperties):
61990        (WebCore::RenderMathMLOperator::updateStyle):
61991        * rendering/mathml/RenderMathMLOperator.h:
61992        * rendering/mathml/RenderMathMLRow.cpp:
61993        (WebCore::RenderMathMLRow::updateOperatorProperties):
61994        * rendering/mathml/RenderMathMLRow.h:
61995        * rendering/mathml/RenderMathMLToken.h:
61996
619972014-03-11  Brent Fulgham  <bfulgham@apple.com>
61998
61999        Get the incomplete WebVTT Regions code to build again.
62000        https://bugs.webkit.org/show_bug.cgi?id=130094
62001
62002        Reviewed by Eric Carlson.
62003
62004        The feature is not being turned on here, so there are no new tests.
62005
62006        * DerivedSources.make: Add missing IDL files for Regions.
62007        * WebCore.xcodeproj/project.pbxproj: Add Regions-related files.
62008        * html/track/InbandWebVTTTextTrack.cpp:
62009        (WebCore::InbandWebVTTTextTrack::newRegionsParsed): Add stub implementation.
62010        * html/track/LoadableTextTrack.cpp: Add missing include file.
62011        * html/track/TextTrack.cpp:
62012        (WebCore::TextTrack::TextTrack): Correct ordering of construction
62013        to avoid compiler warning.
62014
620152014-03-11  Ryuan Choi  <ryuan.choi@samsung.com>
62016
62017        Remove unused method from BatteryController
62018        https://bugs.webkit.org/show_bug.cgi?id=130063
62019
62020        Reviewed by Darin Adler.
62021
62022        * Modules/battery/BatteryController.h: Removed client() which is not used.
62023
620242014-03-11  Krzysztof Czech  <k.czech@samsung.com>
62025
62026        [ATK] Expose aria-posinset and aria-setsize through object attributes
62027        https://bugs.webkit.org/show_bug.cgi?id=130011
62028
62029        Reviewed by Chris Fleizach.
62030
62031        Based on http://www.w3.org/TR/2014/PR-wai-aria-implementation-20140206/
62032        aria-poinset and aria-setsize can be exposed as object attributes.
62033
62034        Test: accessibility/aria-setsize-posinset.html
62035
62036        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
62037        (webkitAccessibleGetAttributes):
62038
620392014-03-10  Frédéric Wang  <fred.wang@free.fr>
62040
62041        Improve renderer classes for MathML Token elements.
62042        https://bugs.webkit.org/show_bug.cgi?id=124838
62043
62044        Reviewed by Chris Fleizach.
62045
62046        This patch continues the refactoring of token elements that has been
62047        started in bug 44208. The <mo> element now derives from the
62048        RenderMathMLToken class, which was already used for the <mi> element.
62049        The behavior of anonymous <mo> elements created by the <mfenced> element
62050        is now more consistent with the one of "standard" <mo> elements and the
62051        spacing around them is now handled in RenderMathMLOperator. This is a
62052        first step towards fixing bugs 115787 and 118843. The only visible
62053        rendering change is how <mfenced> open/close attributes handle
62054        whitespace and multiple characters and some tests are added for that.
62055        Other features are already covered by other tests. Finally, this also
62056        removes some code from AccessibilityRenderObject that was used to
62057        workaround issues with <mo> elements.
62058
62059        * accessibility/AccessibilityRenderObject.cpp:
62060        (WebCore::startOfContinuations):
62061        (WebCore::AccessibilityRenderObject::textUnderElement):
62062        (WebCore::AccessibilityRenderObject::isMathOperator):
62063        (WebCore::AccessibilityRenderObject::isIgnoredElementWithinMathTree):
62064        * mathml/MathMLTextElement.cpp:
62065        (WebCore::MathMLTextElement::didAttachRenderers):
62066        (WebCore::MathMLTextElement::childrenChanged):
62067        * rendering/mathml/RenderMathMLBlock.cpp:
62068        (WebCore::RenderMathMLBlock::RenderMathMLBlock):
62069        * rendering/mathml/RenderMathMLBlock.h:
62070        * rendering/mathml/RenderMathMLFenced.cpp:
62071        (WebCore::RenderMathMLFenced::RenderMathMLFenced):
62072        (WebCore::RenderMathMLFenced::updateFromElement):
62073        (WebCore::RenderMathMLFenced::createMathMLOperator):
62074        (WebCore::RenderMathMLFenced::makeFences):
62075        (WebCore::RenderMathMLFenced::addChild):
62076        * rendering/mathml/RenderMathMLFenced.h:
62077        * rendering/mathml/RenderMathMLOperator.cpp:
62078        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
62079        (WebCore::RenderMathMLOperator::setOperatorFlagFromAttribute):
62080        (WebCore::RenderMathMLOperator::setOperatorPropertiesFromOpDictEntry):
62081        (WebCore::RenderMathMLOperator::SetOperatorProperties):
62082        (WebCore::RenderMathMLOperator::computePreferredLogicalWidths):
62083        (WebCore::RenderMathMLOperator::rebuildTokenContent):
62084        (WebCore::RenderMathMLOperator::updateTokenContent):
62085        (WebCore::RenderMathMLOperator::updateStyle):
62086        (WebCore::RenderMathMLOperator::firstLineBaseline):
62087        (WebCore::RenderMathMLOperator::paint):
62088        (WebCore::RenderMathMLOperator::paintChildren):
62089        * rendering/mathml/RenderMathMLOperator.h:
62090        * rendering/mathml/RenderMathMLToken.cpp:
62091        (WebCore::RenderMathMLToken::createWrapperIfNeeded):
62092
620932014-03-10  James Craig  <jcraig@apple.com>
62094
62095        Web Inspector: AXI: Expose checked/disabled/expanded/pressed/readonly/selected
62096        https://bugs.webkit.org/show_bug.cgi?id=129781
62097
62098        Reviewed by Joseph Pecoraro.
62099
62100        Enabling several more properties to be exposed in the Accessibility Node Inspector.
62101
62102        Updated Tests: inspector-protocol/dom/getAccessibilityPropertiesForNode.html
62103
62104        * accessibility/AccessibilityObject.cpp:
62105        (WebCore::AccessibilityObject::supportsChecked):
62106        * accessibility/AccessibilityObject.h:
62107        * inspector/InspectorDOMAgent.cpp:
62108        (WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
62109        * inspector/protocol/DOM.json:
62110
621112014-03-10  Bem Jones-Bey  <bjonesbe@adobe.com>
62112
62113        [CSS Shapes] inset corner radii are not flipped for vertical writing modes
62114        https://bugs.webkit.org/show_bug.cgi?id=129918
62115
62116        Reviewed by Dean Jackson.
62117
62118        When creating an inset shape, convert the radii to logical coordinates
62119        as well as the box.
62120
62121        Tests: fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-different-writing-modes-left.html
62122               fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-different-writing-modes-right.html
62123
62124        * rendering/shapes/Shape.cpp:
62125        (WebCore::Shape::createShape): Convert the radii to logical
62126            coordinates.
62127
621282014-03-10  Joseph Pecoraro  <pecoraro@apple.com>
62129
62130        Web Inspector: Frontend loaded resources from cache are not hidden as expected
62131        https://bugs.webkit.org/show_bug.cgi?id=130044
62132
62133        Reviewed by Timothy Hatcher.
62134
62135        * loader/FrameLoader.cpp:
62136        (WebCore::FrameLoader::loadedResourceFromMemoryCache):
62137        Use the new request that was passed in. Assume it is filled in appropriately.
62138
62139        * loader/cache/CachedResourceLoader.h:
62140        * loader/cache/CachedResourceLoader.cpp:
62141        (WebCore::CachedResourceLoader::shouldContinueAfterNotifyingLoadedFromMemoryCache):
62142        Carry over the hidden from inspector state if the passed in request had it,
62143        and create the request that loadedResourceFromMemoryCache will use.
62144
62145        * xml/XMLHttpRequest.cpp:
62146        (WebCore::XMLHttpRequest::createRequest):
62147        Add missing ifdefs for INSPECTOR only function.
62148
621492014-03-10  Jinwoo Song  <jinwoo7.song@samsung.com>
62150
62151        Remove 'visibilitychange' attribute event listener from document
62152        https://bugs.webkit.org/show_bug.cgi?id=129794
62153
62154        Reviewed by Simon Fraser.
62155
62156        Remove the unused attribute event listener which is not defined in Page Visibility API spec.
62157        http://www.w3.org/TR/page-visibility/#sec-document-interface
62158
62159        * dom/Document.h:
62160
621612014-03-10  Benjamin Poulain  <bpoulain@apple.com>
62162
62163        [iOS][WebKit 2] Wire the unobscured rect in the WebProcess
62164        https://bugs.webkit.org/show_bug.cgi?id=130058
62165
62166        Reviewed by Simon Fraser.
62167
62168        * WebCore.exp.in:
62169        * platform/ScrollView.h:
62170        * platform/ios/ScrollViewIOS.mm:
62171        (WebCore::ScrollView::unobscuredContentRect):
62172        (WebCore::ScrollView::setUnobscuredContentRect):
62173
621742014-03-10  Benjamin Poulain  <bpoulain@apple.com>
62175
62176        makeSelectorPseudoTypeMap.py should not be copied in the WebCore bundle
62177
62178        * WebCore.xcodeproj/project.pbxproj:
62179
621802014-03-10  Mario Sanchez Prada  <mario.prada@samsung.com>
62181
62182        [GTK] Add support for Geoclue2
62183        https://bugs.webkit.org/show_bug.cgi?id=120185
62184
62185        Reviewed by Carlos Garcia Campos.
62186
62187        Patch by Anton Obzhirov <a.obzhirov@samsung.com> and Mario Sanchez Prada <mario.prada@samsung.com>
62188
62189        Implement a new geolocation provider based on Geoclue2, which will only
62190        be used if a good enough version of Geoclue2 is found  at configure time.
62191
62192        * GNUmakefile.am: Generate C-API for accessing the D-Bus API
62193        provided by Geoclue2, and place it in DerivedSources.
62194        * GNUmakefile.list.am: Add GeolocationProviderGeoclue2.cpp, and
62195        include the generated proxy files when using Geoclue2.
62196        * PlatformGTK.cmake: Likewise, for CMake based builds.
62197        * platform/geoclue/GeolocationProviderGeoclue.h: Modified to
62198        accomodate the needs both for Geoclue and Geoclue2 providers.
62199        * platform/geoclue/GeolocationProviderGeoclue1.cpp: Renamed from Source/WebCore/platform/geoclue/GeolocationProviderGeoclue.cpp.
62200        (GeolocationProviderGeoclue::getPositionCallback):
62201        (GeolocationProviderGeoclue::positionChangedCallback):
62202        (GeolocationProviderGeoclue::createGeocluePositionCallback):
62203        (GeolocationProviderGeoclue::geoclueClientSetRequirementsCallback):
62204        (GeolocationProviderGeoclue::createGeoclueClientCallback):
62205        (GeolocationProviderGeoclue::GeolocationProviderGeoclue):
62206        (GeolocationProviderGeoclue::~GeolocationProviderGeoclue):
62207        (GeolocationProviderGeoclue::startUpdating):
62208        (GeolocationProviderGeoclue::stopUpdating):
62209        (GeolocationProviderGeoclue::setEnableHighAccuracy):
62210        (GeolocationProviderGeoclue::initializeGeoclueClient):
62211        (GeolocationProviderGeoclue::initializeGeocluePosition):
62212        (GeolocationProviderGeoclue::updateClientRequirements):
62213        (GeolocationProviderGeoclue::positionChanged):
62214        (GeolocationProviderGeoclue::errorOccurred):
62215        * platform/geoclue/GeolocationProviderGeoclue2.cpp: Added.
62216        (GeolocationProviderGeoclue::GeolocationProviderGeoclue):
62217        (GeolocationProviderGeoclue::~GeolocationProviderGeoclue):
62218        (GeolocationProviderGeoclue::startUpdating):
62219        (GeolocationProviderGeoclue::stopUpdating):
62220        (GeolocationProviderGeoclue::setEnableHighAccuracy):
62221        (GeolocationProviderGeoclue::createGeoclueManagerProxyCallback):
62222        (GeolocationProviderGeoclue::getGeoclueClientCallback):
62223        (GeolocationProviderGeoclue::createGeoclueClientProxyCallback):
62224        (GeolocationProviderGeoclue::startClientCallback):
62225        (GeolocationProviderGeoclue::locationUpdatedCallback):
62226        (GeolocationProviderGeoclue::createLocationProxyCallback):
62227        (GeolocationProviderGeoclue::startGeoclueClient):
62228        (GeolocationProviderGeoclue::updateLocation):
62229        (GeolocationProviderGeoclue::errorOccurred):
62230        (GeolocationProviderGeoclue::updateClientRequirements):
62231
622322014-03-10  Brent Fulgham  <bfulgham@apple.com>
62233
62234        Unreviewed Windows Build Fix.
62235
62236        * WebCore.vcxproj/WebCore.vcxproj: Don't build cURL files for Apple Windows port.
62237        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
62238        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
62239        (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerPaintContents): Correct
62240        method signature to match base class.
62241        (WebCore::MediaPlayerPrivateQuickTimeVisualContext::loadInternal): Use proper character encoding.
62242
622432014-03-10  Simon Fraser  <simon.fraser@apple.com>
62244
62245        Fix three leaks
62246        https://bugs.webkit.org/show_bug.cgi?id=130048
62247
62248        Reviewed by Anders Carlsson.
62249
62250        The NSDictionary was leaked.
62251
62252        * page/ios/UserAgentIOS.mm:
62253        (WebCore::osMarketingVersion):
62254
622552014-03-10  Beth Dakin  <bdakin@apple.com>
62256
62257        Set background color of WK2's UIScrollView to the pageExtendedBackgroundColor
62258        https://bugs.webkit.org/show_bug.cgi?id=129919
62259
62260        Reviewed by Benjamin Poulain.
62261
62262        WK2 needs to be able to ask for the pageExtendedBackgroundColor, so this patch 
62263        adds a function to Page that will return it
62264
62265        * WebCore.exp.in:
62266        * page/Page.cpp:
62267        (WebCore::Page::pageExtendedBackgroundColor):
62268        * page/Page.h:
62269        * rendering/RenderLayerCompositor.h:
62270        (WebCore::RenderLayerCompositor::rootExtendedBackgroundColor):
62271
622722014-03-10  Benjamin Poulain  <bpoulain@apple.com>
62273
62274        Generalize unobscured rect to all ports
62275        https://bugs.webkit.org/show_bug.cgi?id=130036
62276
62277        Reviewed by Simon Fraser.
62278
62279        iOS differentiates visible content and unobscured content. This patch moves the concept to all
62280        ports to remove the #ifdefs from the call sites.
62281
62282        On everything but iOS, unobscuredRect and visibleRect are the same.
62283
62284        * WebCore.exp.in:
62285        * page/DOMWindow.cpp:
62286        (WebCore::DOMWindow::innerHeight):
62287        (WebCore::DOMWindow::innerWidth):
62288        * page/SpatialNavigation.cpp:
62289        (WebCore::canScrollInDirection):
62290        * platform/ScrollView.cpp:
62291        (WebCore::ScrollView::updateScrollbars):
62292        (WebCore::ScrollView::paint):
62293        * platform/ScrollView.h:
62294        (WebCore::ScrollView::unobscuredContentRectIncludingScrollbars):
62295        (WebCore::ScrollView::unobscuredContentRect):
62296        * rendering/RenderView.cpp:
62297        (WebCore::RenderView::viewportSize):
62298
622992014-03-10  Benjamin Poulain  <benjamin@webkit.org>
62300
62301        Start splitting CSS Selectors's pseudo types
62302        https://bugs.webkit.org/show_bug.cgi?id=130003
62303
62304        Reviewed by Andreas Kling.
62305
62306        CSS Selectors pseudo types come in 3 flavors: page, pseudo class, pseudo elements.
62307
62308        The three types are mixed together in a single enum list named PseudoType. Only some combinations
62309        of match type + pseudo type are valid, but this is implicitly defined from the code.
62310
62311        This patch is the beginning of a refactoring to add more clear boundaries between
62312        valid and invalid combinations.
62313
62314        First, the handling of page pseudo types is completely split from the other values.
62315        The parser use a different method for handling the value CSSParserSelector::parsePagePseudoSelector().
62316
62317        PagePseudo types no longer store their string in the CSSSelector either to reduce the redundancy
62318        with m_pseudoType.
62319        When we need to generate the string for those CSSSelector, we recreate the string as needed in
62320        CSSSelector::selectorText().
62321
62322        The remaining two types are not yet split in this patch but this introduce the preliminary clean up
62323        toward that goal.
62324        The list of parsed pseudo types is now generated at compile time from the source in SelectorPseudoTypeMap.in.
62325
62326        * DerivedSources.make:
62327        The mapping of strings to pseudo types is generated from SelectorPseudoTypeMap.in
62328        by the new script makeSelectorPseudoTypeMap.py.
62329
62330        * WebCore.xcodeproj/project.pbxproj:
62331        * css/CSSGrammar.y.in:
62332        Split the parsing of Pseudo Types. Pseudo page get its own method. The others will need some work.
62333
62334        * css/CSSParserValues.cpp:
62335        (WebCore::CSSParserSelector::parsePagePseudoSelector):
62336        (WebCore::CSSParserSelector::setPseudoTypeValue):
62337        * css/CSSParserValues.h:
62338        * css/CSSSelector.cpp:
62339        (WebCore::CSSSelector::specificityForPage):
62340        This is an example of invalid combination that is hidden by the current code.
62341        First, Left and Right could never appear in a pseudo class match.
62342        (WebCore::CSSSelector::pseudoId):
62343        (WebCore::CSSSelector::parsePseudoType):
62344        (WebCore::appendPseudoTypeTailIfNecessary):
62345        (WebCore::CSSSelector::selectorText):
62346        * css/CSSSelector.h:
62347        (WebCore::CSSSelector::pseudoType):
62348        (WebCore::CSSSelector::matchesPseudoElement):
62349        (WebCore::CSSSelector::setValue):
62350        (WebCore::CSSSelector::CSSSelector):
62351        * css/PageRuleCollector.cpp:
62352        (WebCore::checkPageSelectorComponents):
62353        * css/SelectorChecker.cpp:
62354        (WebCore::SelectorChecker::checkOne):
62355        * css/SelectorPseudoTypeMap.h: Added.
62356        * css/SelectorPseudoTypeMap.in: Added.
62357        * css/makeSelectorPseudoTypeMap.py: Added.
62358        (enumerablePseudoType):
62359        (expand_ifdef_condition):
62360        * cssjit/SelectorCompiler.cpp:
62361        (WebCore::SelectorCompiler::addPseudoType):
62362
623632014-03-10  Enrica Casucci  <enrica@apple.com>
62364
62365        iOS build fix after http://trac.webkit.org/changeset/165385
62366
62367        Unreviewed.
62368
62369        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
62370        (-[WebAccessibilityObjectWrapper arrayOfTextForTextMarkers:attributed:]):
62371
623722014-03-10  Daniel Bates  <dabates@apple.com>
62373
62374        REGRESSION (r159218): FrameView::layout() should destroy TemporaryChange<LayoutPhase>
62375        before destroying Ref<FrameView>
62376        https://bugs.webkit.org/show_bug.cgi?id=130034
62377        <rdar://problem/15664288>
62378
62379        Reviewed by Alexey Proskuryakov.
62380
62381        We should always destroy TemporaryChange<LayoutPhase> before destroying Ref<FrameView>
62382        in FrameView::layout() so as to ensure that the FrameView exists when we restore the
62383        original layout phase value.
62384
62385        The existing test fast/frames/crash-remove-iframe-during-object-beforeload.html covers
62386        this change. Although you must run the test with Guard Malloc enabled (i.e. run-webkit-tests -r).
62387
62388        * page/FrameView.cpp:
62389        (WebCore::FrameView::layout): Move construction of variable protect before the construction of
62390        variable layoutPhaseRestorer. Additionally, add a period to the end of the comment associated
62391        with variable protect.
62392
623932014-03-10  Zsolt Borbely  <borbezs@inf.u-szeged.hu>
62394
62395        ASSERTION FAILED: span >= 1
62396        https://bugs.webkit.org/show_bug.cgi?id=129148
62397
62398        Reviewed by Andreas Kling.
62399
62400        Set the value of span to 1 if the given number is too big or zero.
62401
62402        Test: fast/table/incorrect-colgroup-span-values.html
62403
62404        * html/HTMLTableColElement.cpp:
62405        (WebCore::HTMLTableColElement::parseAttribute):
62406
624072014-03-10  Brent Fulgham  <bfulgham@apple.com>
62408
62409        [Win] Pass environment to Pre-Build, Pre-Link, and Post-Build Stages.
62410        https://bugs.webkit.org/show_bug.cgi?id=130023.
62411
62412        Reviewed by Dean Jackson.
62413
62414        * WebCore.vcxproj/WebCore.proj: Avoid trailing slashes in path values to
62415        prevent escaping during later string substitution.
62416
624172014-03-10  Radu Stavila  <stavila@adobe.com>
62418
62419        [CSS Regions] Hit-testing is not working properly inside scrollable regions
62420        https://bugs.webkit.org/show_bug.cgi?id=130015
62421
62422        Reviewed by Antti Koivisto.
62423
62424        When hit-testing inside the flow thread's layer, the scrolled offset
62425        of the current region must be taken into consideration.
62426
62427        Test: fast/regions/scrollable-regions-hit-testing-inside.html
62428
62429        * rendering/RenderLayer.cpp:
62430        (WebCore::RenderLayer::calculateClipRects):
62431
624322014-03-10  Hans Muller  <hmuller@adobe.com>
62433
62434        [CSS Shapes] SVG Image valued shape fails if root element's size is relative
62435        https://bugs.webkit.org/show_bug.cgi?id=128983
62436
62437        Reviewed by Simon Fraser.
62438
62439        When creating a shape based on an Image, compute its dimensions using
62440        RenderBoxModelObject::calculateImageIntrinsicDimensions(), then set the
62441        ImageResource's containerSize, and then use imageForRenderer() to get the
62442        image to be drawn. The first step resolves SVG Image relative sizes, the
62443        second step creates and caches an SVGImageForContainer with the correct
62444        containerSize, and the last step retrieves the SVGImageForContainer.
62445
62446        Test: fast/shapes/shape-outside-floats/shape-outside-relative-size-svg.html
62447
62448        * rendering/RenderBoxModelObject.h: Publicized calculateImageIntrinsicDimensions() and its enum.
62449        * rendering/shapes/Shape.cpp:
62450        (WebCore::Shape::createRasterShape):
62451        * rendering/shapes/Shape.h:
62452        * rendering/shapes/ShapeInfo.cpp:
62453        (WebCore::getShapeImageAndRect):
62454        (WebCore::ShapeInfo<RenderType>::computedShape):
62455
624562014-03-10  Darin Adler  <darin@apple.com>
62457
62458        TextIterator: Use StringView and references rather than pointers
62459        https://bugs.webkit.org/show_bug.cgi?id=129975
62460
62461        Reviewed by Anders Carlsson.
62462
62463        TextIterator refinements:
62464        - Use StringView instead of deprecatedCharacters to point to characters within strings.
62465        - Added TextIteratorCopyableText, a safe way to copy the current text of a TextIterator,
62466          for use by WordAwareIterator.
62467        - Removed m_shouldStop; iterators stop by setting m_positionNode to null, and there is no
62468          need for a separate boolean to do the same thing.
62469        - Got rid of all the boolean data members set based on the text iterator behavior; instead
62470          store the behavior in a data member and check it directly.
62471        - Changed most functions to use references rather than pointers.
62472        - Small micro-optimizations, such as using fastGetAttribute rather than getAttribute.
62473        - Switched to nullptr instead of 0 where appropriate.
62474        - Removed unused functions.
62475        - Cut down on use of abbreviations instead of words.
62476        - Renamed data members and argument names for clarity.
62477        - Split up assertions that needlessly asserted more than one thing in a single expression.
62478        - Treat CDATASection just like other Text, since its text will be visible.
62479
62480        * editing/Editor.cpp:
62481        (WebCore::Editor::advanceToNextMisspelling): Pass reference rather than pointer.
62482        (WebCore::Editor::rangeOfString): Ditto.
62483        (WebCore::Editor::countMatchesForText): Ditto.
62484        * editing/TextCheckingHelper.cpp:
62485        (WebCore::TextCheckingHelper::findFirstMisspelling): Ditto.
62486
62487        * editing/TextIterator.cpp:
62488        (WebCore::depthCrossingShadowBoundaries): Take a reference rather than a pointer.
62489        (WebCore::nextInPreOrderCrossingShadowBoundaries): Ditto.
62490        (WebCore::fullyClipsContents): Ditto.
62491        (WebCore::ignoresContainerClip): Ditto.
62492        (WebCore::pushFullyClippedState): Ditto.
62493        (WebCore::setUpFullyClippedStack): Ditto.
62494        (WebCore::isRendererReplacedElement): Use references rather than pointers in the
62495        implementation. Also use fastGetAttribute instead of getAttribute.
62496        (WebCore::TextIteratorCopyableText::reset): Added.
62497        (WebCore::TextIteratorCopyableText::set): Added.
62498        (WebCore::TextIteratorCopyableText::appendToStringBuilder): Added.
62499        (WebCore::TextIterator::TextIterator): Use more initialization rather than assignment.
62500        Got rid of some local variables.
62501        (WebCore::TextIterator::advance): Removed the m_shouldStop boolean, uneeded.
62502        Many other improvements. Use isTextNode instead of nodeType.
62503        (WebCore::hasVisibleTextNode): Changed this into a file-private helper function
62504        instead of a member function.
62505        (WebCore::TextIterator::handleTextNode): Used references and cut down on type casts.
62506        Gave local variables clearer names.
62507        (WebCore::TextIterator::handleTextBox): More of the same.
62508        (WebCore::TextIterator::handleTextNodeFirstLetter): Ditto.
62509        (WebCore::TextIterator::handleReplacedElement): Ditto.
62510        (WebCore::shouldEmitTabBeforeNode): Ditto.
62511        (WebCore::hasHeaderTag): Added.
62512        (WebCore::shouldEmitNewlinesBeforeAndAfterNode): More of the same.
62513        (WebCore::shouldEmitNewlineAfterNode): Ditto.
62514        (WebCore::shouldEmitNewlineBeforeNode): Ditto.
62515        (WebCore::shouldEmitExtraNewlineForNode): Ditto.
62516        (WebCore::collapsedSpaceLength): Use StringImpl directly instead of using the
62517        deprecatedCharacters function.
62518        (WebCore::TextIterator::shouldRepresentNodeOffsetZero): More like above.
62519        (WebCore::TextIterator::shouldEmitSpaceBeforeAndAfterNode): Ditto.
62520        (WebCore::TextIterator::representNodeOffsetZero): Ditto.
62521        (WebCore::TextIterator::handleNonTextNode): Ditto.
62522        (WebCore::TextIterator::exitNode): Ditto.
62523        (WebCore::TextIterator::emitCharacter): Changed to use the new copyable text class
62524        instead of managing the single character buffer directly here.
62525        (WebCore::TextIterator::emitText): Changed to take a Text& and use the copyable text
62526        class. Added a FIXME about a mistake I noticed.
62527        (WebCore::TextIterator::range): Streamlined and simplified a bit. Updated data
62528        member names to be a bit clearer. This function never returned null before, but there
62529        was a code path that looked like it would; I removed that.
62530        (WebCore::TextIterator::node): Removed unneeded null checks; the range function will
62531        never return a range of null or one with null for a start container.
62532        (WebCore::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator): More
62533        like above.
62534        (WebCore::SimplifiedBackwardsTextIterator::advance): Reorganized a bit and removed
62535        m_shouldStop.
62536        (WebCore::SimplifiedBackwardsTextIterator::handleTextNode): More of the same.
62537        (WebCore::SimplifiedBackwardsTextIterator::handleFirstLetter): Ditto.
62538        (WebCore::SimplifiedBackwardsTextIterator::handleReplacedElement): Ditto.
62539        (WebCore::SimplifiedBackwardsTextIterator::handleNonTextNode): Ditto.
62540        (WebCore::SimplifiedBackwardsTextIterator::exitNode): Ditto.
62541        (WebCore::SimplifiedBackwardsTextIterator::emitCharacter): Ditto.
62542        (WebCore::SimplifiedBackwardsTextIterator::advanceRespectingRange): Ditto.
62543        (WebCore::SimplifiedBackwardsTextIterator::range): Ditto.
62544        (WebCore::CharacterIterator::CharacterIterator): Ditto.
62545        (WebCore::CharacterIterator::range): Ditto. No need for ASSERT_NO_EXCEPTION.
62546        (WebCore::CharacterIterator::advance): Ditto.
62547        (WebCore::BackwardsCharacterIterator::BackwardsCharacterIterator): Ditto.
62548        (WebCore::BackwardsCharacterIterator::range): Ditto.
62549        (WebCore::BackwardsCharacterIterator::advance): Ditto.
62550        (WebCore::WordAwareIterator::WordAwareIterator): Ditto.
62551        (WebCore::WordAwareIterator::advance): Use copyableText for m_previousText, fixing
62552        the FIXME that I wrote in here before.
62553        (WebCore::WordAwareIterator::text): Ditto.
62554        (WebCore::containsKanaLetters): Changed to quickly return false when the pattern
62555        is all Latin-1 rather than expanding to 16-bit just to check.
62556        (WebCore::SearchBuffer::SearchBuffer): Iterate the target using the string operator[]
62557        instead of using deprecatedCharacters.
62558        (WebCore::SearchBuffer::append): Do the folding of quote marks and hyphens one character
62559        at a time as we move characters into the buffer instead of in a separate loop.
62560        (WebCore::TextIterator::rangeLength): Updated for changes eslwehere.
62561        (WebCore::TextIterator::subrange): Ditto.
62562        (WebCore::isInsideReplacedElement): Ditto. Also streamlined and removed unneeded null check.
62563        (WebCore::TextIterator::rangeFromLocationAndLength): Updated for changes elsewhere and
62564        removed unneeded ASSERT_NO_EXCEPTION.
62565        (WebCore::plainText): Ditto.
62566        (WebCore::collapsedToBoundary): Ditto.
62567        (WebCore::findPlainText): Ditto.
62568
62569        * editing/TextIterator.h: Changed many functions to take references instead of pointers.
62570        Added TextIteratorCopyableText, to represent the current text in a TextIterator in a form
62571        that can be safely copied and used after further iteration. Reorganized member functions so
62572        they are in the same order in all the classes. Changed TextIterator to use
62573        TextIteratorCopyableText. Removed many unused functions, including:
62574        - TextIterator::length
62575        - TextIterator::deprecatedTextIteratorCharacters
62576        - TextIterator::characterAt
62577        - SimplifiedBackwardsTextIterator::length
62578        - CharacterIterator::length
62579        - CharacterIterator::string
62580        - WordAwareIterator::length
62581        - WordAwareIterator::range
62582
62583        * editing/VisibleSelection.cpp:
62584        (WebCore::VisibleSelection::appendTrailingWhitespace): Pass reference rather than pointer.
62585        Use text().length() instead of length(). Check atEnd() before using CharacterIterator, since
62586        iterator member functions don't work when at the end.
62587        * editing/VisibleUnits.cpp:
62588        (WebCore::previousBoundary): Ditto.
62589        (WebCore::nextBoundary): Ditto.
62590        * editing/htmlediting.cpp:
62591        (WebCore::visiblePositionForIndexUsingCharacterIterator): Ditto.
62592        * page/ios/FrameIOS.mm:
62593        (WebCore::Frame::indexCountOfWordPrecedingSelection): Ditto.
62594        (WebCore::Frame::wordsInCurrentParagraph): Ditto.
62595
625962014-03-10  Martin Robinson  <mrobinson@igalia.com>
62597
62598        [GTK] [CMake] Clean up library linking
62599        https://bugs.webkit.org/show_bug.cgi?id=129782
62600
62601        Reviewed by Philippe Normand.
62602
62603        * PlatformGTK.cmake: Some files are duplicated on the source list of two convenience
62604        libraries. Ensure that they are all compiled into WebCore instead of WebCorePlatformGTK.
62605        Some simply need to be moved to WebCore from WebCorePlatformGTK. Don't try to link
62606        WebCorePlatformGTK against WebCore -- convenience libraries should be able to save
62607        their symbol resolution for the final linking step.
62608
626092014-03-10  Radu Stavila  <stavila@adobe.com>
62610
62611        [CSS Regions] Scrolling regions with the mouse wheel only works properly if hovering over the region's padding
62612        https://bugs.webkit.org/show_bug.cgi?id=129485
62613
62614        Reviewed by Andrei Bucur.
62615
62616        When searching for the region under the mouse pointer (to identify which region to scroll), 
62617        the localToAbsolute method must be called on the region container, not the region itself.
62618        Also, when calling the offsetFromContainer method on a named flow fragment,
62619        it must only take into consideration the border and padding of the fragment container,
62620        not its scrolled offset.
62621
62622        Test: fast/regions/wheel-scrollable-single-region.html
62623
62624        * rendering/RenderBox.cpp:
62625        (WebCore::RenderBox::scroll):
62626        * rendering/RenderFlowThread.cpp:
62627        * rendering/RenderFlowThread.h:
62628        * rendering/RenderNamedFlowFragment.cpp:
62629        (WebCore::RenderNamedFlowFragment::offsetFromContainer):
62630        * rendering/RenderNamedFlowFragment.h:
62631        * rendering/RenderNamedFlowThread.cpp:
62632        (WebCore::RenderNamedFlowThread::fragmentFromAbsolutePointAndBox):
62633        * rendering/RenderNamedFlowThread.h:
62634
626352014-03-10  Jinwoo Song  <jinwoo7.song@samsung.com>
62636
62637        Remove unused dispatchStorageEvent() from StorageAreaSync
62638        https://bugs.webkit.org/show_bug.cgi?id=129999
62639
62640        Reviewed by Andreas Kling.
62641
62642        dispatchStorageEvent() is not used anywhere.
62643
62644        * storage/StorageAreaSync.h: Remove dispatchStorageEvent().
62645
626462014-03-09  Alexey Proskuryakov  <ap@apple.com>
62647
62648        iOS build fix.
62649
62650        * dom/KeyboardEvent.cpp: (WebCore::KeyboardEvent::KeyboardEvent):
62651
626522014-03-06  Alexey Proskuryakov  <ap@apple.com>
62653
62654        [Mac] Don't perform a round-trip through WebProcess before interpreting key events
62655        https://bugs.webkit.org/show_bug.cgi?id=129812
62656
62657        Reviewed by Darin Adler.
62658
62659        No significant behavior changes expected, except for Esc key processing, which now
62660        dispatches a keypress before executing its default action.
62661
62662        * platform/KeypressCommand.h: Added.
62663        (WebCore::KeypressCommand::KeypressCommand):
62664        * GNUmakefile.list.am:
62665        * WebCore.vcxproj/WebCore.vcxproj:
62666        * WebCore.vcxproj/WebCore.vcxproj.filters:
62667        * WebCore.xcodeproj/project.pbxproj:
62668        Moved KeypressCommand from dom/KeyboardEvent.h to its own header, as it needed
62669        in platform/ directory now.
62670
62671        * dom/KeyboardEvent.cpp:
62672        (WebCore::KeyboardEvent::KeyboardEvent):
62673        * dom/KeyboardEvent.h:
62674        (WebCore::KeyboardEvent::handledByInputMethod):
62675        (WebCore::KeyboardEvent::keypressCommands):
62676        * platform/PlatformKeyboardEvent.h:
62677        (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
62678        (WebCore::PlatformKeyboardEvent::handledByInputMethod):
62679        (WebCore::PlatformKeyboardEvent::commands):
62680        PlatformKeyboardEvent now carries results of interpreting the event by AppKit. This
62681        is logically not much different from carrying charcode, and is similar to what Gtk
62682        does for input methods.
62683        KeyboardEvent already had keypress commands, which were added to it after construction.
62684        It's still possible for WebKit1, while with WebKit2, they are provided at construction
62685        time. The event now also has a boolean for whether IM handled it already.
62686
626872014-03-09  Zalan Bujtas  <zalan@apple.com>
62688
62689        Subpixel rendering: Pass FloatSize boxsize to transform animations to support device pixel sizing.
62690        https://bugs.webkit.org/show_bug.cgi?id=129985
62691
62692        Reviewed by Simon Fraser.
62693
62694        This is in preparation to stop passing integral positioned boxes to transform animations.
62695
62696        No change in behavior.
62697
62698        * WebCore.exp.in:
62699        * platform/graphics/GraphicsLayer.h:
62700        (WebCore::GraphicsLayer::addAnimation):
62701        * platform/graphics/ca/GraphicsLayerCA.cpp:
62702        (WebCore::getTransformFunctionValue):
62703        (WebCore::GraphicsLayerCA::addAnimation):
62704        (WebCore::GraphicsLayerCA::appendToUncommittedAnimations):
62705        (WebCore::GraphicsLayerCA::createTransformAnimationsFromKeyframes):
62706        (WebCore::GraphicsLayerCA::setTransformAnimationEndpoints):
62707        (WebCore::GraphicsLayerCA::setTransformAnimationKeyframes):
62708        * platform/graphics/ca/GraphicsLayerCA.h:
62709        * rendering/RenderLayerBacking.cpp:
62710        (WebCore::RenderLayerBacking::startTransition):
62711
627122014-03-08  Simon Fraser  <simon.fraser@apple.com>
62713
62714        [iOS Wk2] Can't scroll after going back to page in page cache
62715        https://bugs.webkit.org/show_bug.cgi?id=129989
62716        <rdar://problem/16217588>
62717
62718        Reviewed by Dan Bernstein.
62719
62720        iOS has a special FrameLoader::forceLayoutWithoutRecalculatingStyle()
62721        function that is called instead of FrameView::forceLayout(). This was unimplemented
62722        for the WK2 FrameLoaderClient, so no layout was forced, with the result
62723        that the contentSize was never updated and scrolling was broken.
62724        
62725        Fix by renaming the client function to forceLayoutOnRestoreFromPageCache()
62726        and having it return a bool to say whether the default forceLayout()
62727        should be done. WK1 can then continue to have its custom behavior,
62728        and Wk2 will simply do a forceLayout().
62729        
62730        Also remove FrameLaoderClient::forceLayout(), which was never called.
62731
62732        * loader/EmptyClients.h:
62733        * loader/FrameLoader.cpp:
62734        (WebCore::FrameLoader::commitProvisionalLoad):
62735        * loader/FrameLoaderClient.h:
62736
627372014-03-08  Simon Fraser  <simon.fraser@apple.com>
62738
62739        [iOS WK2] Get position:fixed working slighlty better
62740        https://bugs.webkit.org/show_bug.cgi?id=129988
62741
62742        Reviewed by Dan Bernstein.
62743
62744        On iOS we want to use the viewport-constrained visible rect, not
62745        just the visible rect.
62746
62747        * page/scrolling/AsyncScrollingCoordinator.cpp:
62748        (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
62749
627502014-03-07  Simon Fraser  <simon.fraser@apple.com>
62751
62752        [iOS] Don't call scrollOffsetForFixedPosition a second time if we have no header and footer layers
62753        https://bugs.webkit.org/show_bug.cgi?id=129912
62754
62755        Reviewed by Tim Horton.
62756
62757        Avoid extra work if we have no header or footer layers.
62758
62759        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
62760        (WebCore::ScrollingTreeScrollingNodeIOS::setScrollLayerPosition):
62761
627622014-03-08  Zalan Bujtas  <zalan@apple.com>
62763
62764        RenderElement::valueForLength() callers misuse bool parameter.
62765        https://bugs.webkit.org/show_bug.cgi?id=129982
62766
62767        Reviewed by Andreas Kling.
62768
62769        Remove bogus RenderView* parameter.
62770
62771        * rendering/RenderBox.cpp:
62772        (WebCore::RenderBox::computePercentageLogicalHeight):
62773        * rendering/RenderElement.cpp:
62774        (WebCore::RenderElement::repaintAfterLayoutIfNeeded):
62775
627762014-03-08  Jeremy Jones  <jeremyj@apple.com>
62777
62778        Allow media element to supply the video layer after fullscreen transition has already begun.
62779        https://bugs.webkit.org/show_bug.cgi?id=129870
62780
62781        Reviewed by Eric Carlson.
62782
62783        Instead of borrowing the videolayer from the HTMLMediaElement, WebVideoFullscreen now supplies a layer to HTMLMediaElement to fill in as needed and at the appropriate time.
62784
62785        This allows fullscreen even if the video layer hasn't yet been created. And in the future it allows MediaPlayer to supply other layers such as closed captions. 
62786
62787        * WebCore.exp.in:
62788        Remove exports related to borrowing and lend the video layer.
62789        Add exports for supplying a layer to fullscreen and keepying the frame and gravity properties in sync.
62790
62791        * html/HTMLMediaElement.cpp:
62792        Remove the concept of borrowing the platform layer.
62793        Add the concept of a supplied m_videoFullscreenLayer, into which the media player can add layers.
62794        When the m_videoFullscreenFrame is supplied, don't show the video layer inline any more.
62795        Stash video layer properties in case the media player is not yet created.
62796
62797        (WebCore::HTMLMediaElement::HTMLMediaElement):
62798        Initialize gravity to the default. Remove m_platformLayerBorrowed.
62799
62800        (WebCore::HTMLMediaElement::platformLayer):
62801        When we have a m_videoFullscreenLayer, don't show video inline.
62802
62803        (WebCore::HTMLMediaElement::setVideoFullscreenLayer):
62804        Pass along the m_videoFullscreenLayer to the MediaPlayer if available or just stash it for later.
62805
62806        (WebCore::HTMLMediaElement::createMediaPlayer):
62807        Pass along video fullscreen properties that we may have accumulated before the MediaPlayer was created.
62808
62809        (WebCore::HTMLMediaElement::setVideoFullscreenGravity):
62810        Stash the gravity property, pass it along to the media player if possible.
62811
62812        * html/HTMLMediaElement.h:
62813        Remove concept of borrowing the video layer. Add properties for a supplied videoFullscreenLayer.
62814
62815        * platform/graphics/MediaPlayer.cpp:
62816        (WebCore::MediaPlayer::setVideoFullscreenLayer):
62817        Forward on to internal implementation.
62818
62819        (WebCore::MediaPlayer::setVideoFullscreenFrame):
62820        Forward on to internal implementation.
62821
62822        (WebCore::MediaPlayer::setVideoFullscreenGravity):
62823        Forward on to internal implementation.
62824
62825        * platform/graphics/MediaPlayer.h:
62826        Add methods for video fullscreen Layer, Frame and Gravity.
62827
62828        * platform/graphics/MediaPlayerPrivate.h:
62829        (WebCore::MediaPlayerPrivateInterface::setVideoFullscreenLayer):
62830        Add default implementation.
62831
62832        (WebCore::MediaPlayerPrivateInterface::setVideoFullscreenFrame):
62833        Add default implementation.
62834        
62835        (WebCore::MediaPlayerPrivateInterface::setVideoFullscreenGravity):
62836        Add default implementation.
62837        
62838        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
62839        Add support for fullscreen video layer, frame and gravity.
62840
62841        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
62842        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
62843        Init m_videoFullscreenGravity. 
62844
62845        (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer):
62846        Apply cached properties once video layer is created and add to the fullscreen layer.
62847
62848        (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenLayer):
62849        Cache the property value. Add video layer right away available.
62850
62851        (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenFrame):
62852        Cache the property value. Apply to video layer right away if available.
62853
62854        (WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenGravity):
62855        Cache the property value. Apply to video layer right away if available.
62856
62857        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
62858        Supply a fullscreen video layer to the WebVideoFullscreenModel and to the WebVideoFullscreenInterface.
62859
62860        (-[WebVideoFullscreenController enterFullscreen:]):
62861        Supply a fullscreen video layer to the WebVideoFullscreenModel and to the WebVideoFullscreenInterface.
62862
62863        (-[WebVideoFullscreenController didExitFullscreen]):
62864        Clean up the videoFullscreenLayer.
62865
62866        * platform/ios/WebVideoFullscreenInterface.h:
62867        Remove methods related to lending the video layer.
62868
62869        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
62870        Rename WebAVPlayer layer to WebAVVideoLayer to match the AVKit name.
62871        Remove functions related to lending the video layer.
62872        Supply a layer directly to enterFullscreen.
62873
62874        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
62875        (+[WebAVVideoLayer videoLayer]):
62876        Rename WebAVPlayer layer to WebAVVideoLayer to match the AVKit name.
62877
62878        (-[WebAVVideoLayer setPlayerController:]):
62879        Store the AVPlayerController to prevent AVKit's default behavior.
62880
62881        (-[WebAVVideoLayer setBounds:]):
62882        Forward this onto the WebVideoFullscreenModel
62883
62884        (-[WebAVVideoLayer setVideoLayerGravity:]):
62885        Forward this onto the WebVideoFullscreenModel
62886
62887        (-[WebAVVideoLayer videoLayerGravity]):
62888        Forward this onto the WebVideoFullscreenModel
62889
62890        (WebVideoFullscreenInterfaceAVKit::enterFullscreen):
62891        Supply a video layer directly instead of relying on one being previously loaned.
62892
62893        (WebVideoFullscreenInterfaceAVKit::exitFullscreen):
62894        Clean-up now assumes there is a video layer.
62895
62896        * platform/ios/WebVideoFullscreenModel.h:
62897        Remove methods for borrowing and returning video layers.
62898        Add methods for keeping video layer state in sync.
62899
62900        * platform/ios/WebVideoFullscreenModelMediaElement.h:
62901        Remove methods for borrowing and returning video layers.
62902        Add method for supplying a video fullscreen layer.
62903        Add methods for keeping video layer state in sync.
62904
62905        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
62906        (WebVideoFullscreenModelMediaElement::setMediaElement):
62907        Handle audio element case by setting hasVideo to false.
62908
62909        (WebVideoFullscreenModelMediaElement::setVideoFullscreenLayer):
62910        Pass along the video fullscreen layer to the media element.
62911
62912        (WebVideoFullscreenModelMediaElement::setVideoLayerFrame):
62913        Pass along the video layer frame to the media element.
62914
62915        (WebVideoFullscreenModelMediaElement::setVideoLayerGravity):
62916        Pass along the video layer gravity to the media element.
62917
629182014-03-08  Jae Hyun Park  <jaepark@webkit.org>
62919
62920        Clean up PlatformLayer.h
62921        https://bugs.webkit.org/show_bug.cgi?id=129967
62922
62923        Reviewed by Martin Robinson.
62924
62925        * platform/graphics/PlatformLayer.h:
62926        Remove duplicated declaration of PlatformLayer when using TextureMapper.
62927
629282014-03-08  Zalan Bujtas  <zalan@apple.com>
62929
62930        Subpixel rendering: Simple compositing container layer (isSimpleContainerCompositingLayer) paints to wrong position.
62931        https://bugs.webkit.org/show_bug.cgi?id=129861
62932
62933        Reviewed by Simon Fraser.
62934
62935        This patch ensures that both the simple and non-simple cases paint to the same position.
62936        Simple compositing container layer codepath needs to take the fractional device pixel offset
62937        into account when painting. Without the fractional value, the final paint rounding could push the
62938        paint offset to a different position.
62939        retina example:
62940        compositing top-left: 0px 0px.
62941        fractional offset: 0.3px 0.3px
62942        painting coords without offseting: 0px 0px
62943                           with offseting: 0.5px 0.5px
62944
62945        Tests: compositing/hidpi-simple-container-layer-on-device-pixel.html
62946
62947        * WebCore.exp.in:
62948        * platform/graphics/GraphicsLayer.h:
62949        (WebCore::GraphicsLayer::contentsRect):
62950        (WebCore::GraphicsLayer::setContentsRect):
62951        (WebCore::GraphicsLayer::contentsClippingRect):
62952        (WebCore::GraphicsLayer::setContentsClippingRect):
62953        * platform/graphics/ca/GraphicsLayerCA.cpp:
62954        (WebCore::GraphicsLayerCA::setContentsRect):
62955        (WebCore::GraphicsLayerCA::setContentsClippingRect):
62956        (WebCore::GraphicsLayerCA::updateContentsRects):
62957        * platform/graphics/ca/GraphicsLayerCA.h:
62958        * rendering/RenderLayerBacking.cpp:
62959        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
62960        (WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundColor):
62961        (WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundImage):
62962        (WebCore::RenderLayerBacking::contentOffsetInCompostingLayer):
62963        (WebCore::RenderLayerBacking::backgroundBoxForPainting):
62964        * rendering/RenderLayerBacking.h:
62965
629662014-03-08  Oliver Hunt  <oliver@apple.com>
62967
62968        SerializedScriptValue may move Identifiers between worlds
62969        https://bugs.webkit.org/show_bug.cgi?id=129979
62970
62971        Reviewed by Andreas Kling.
62972
62973        Test: fast/workers/worker-copy-shared-blob-url.html
62974
62975        Don't use Strings to store blob URLs as String's may be Identifiers
62976        and they can only exist in one world/thread at a time.
62977
62978        * Modules/indexeddb/IDBObjectStore.cpp:
62979        (WebCore::IDBObjectStore::put):
62980        * bindings/js/SerializedScriptValue.cpp:
62981        (WebCore::CloneDeserializer::deserializeString):
62982        (WebCore::SerializedScriptValue::addBlobURL):
62983        (WebCore::SerializedScriptValue::SerializedScriptValue):
62984        * bindings/js/SerializedScriptValue.h:
62985
629862014-03-07  Timothy Hatcher  <timothy@apple.com>
62987
62988        Load source maps and their resources asynchronously.
62989
62990        https://bugs.webkit.org/show_bug.cgi?id=112071
62991
62992        Reviewed by Joseph Pecoraro.
62993
62994        * inspector/InspectorPageAgent.cpp:
62995        (WebCore::InspectorPageAgent::buildObjectForFrameTree):
62996        Honor the hiddenFromInspector flag.
62997
62998        * inspector/InspectorResourceAgent.cpp:
62999        (WebCore::InspectorResourceAgent::willSendRequest):
63000        (WebCore::InspectorResourceAgent::markResourceAsCached):
63001        (WebCore::InspectorResourceAgent::didReceiveResponse):
63002        (WebCore::InspectorResourceAgent::didReceiveData):
63003        (WebCore::InspectorResourceAgent::didFinishLoading):
63004        (WebCore::InspectorResourceAgent::didFailLoading):
63005        (WebCore::InspectorResourceAgent::replayXHR):
63006        (WebCore::InspectorResourceAgent::loadResource):
63007        * inspector/InspectorResourceAgent.h:
63008        Honor the hiddenFromInspector flag by keeping track of
63009        hidden identifiers in a HashSet.
63010
63011        * inspector/protocol/Network.json:
63012        (Network.loadResource): Added.
63013
63014        * platform/network/ResourceRequestBase.h:
63015        (WebCore::ResourceRequestBase::hiddenFromInspector): Added.
63016        (WebCore::ResourceRequestBase::setHiddenFromInspector): Added.
63017        (WebCore::ResourceRequestBase::ResourceRequestBase):
63018        Add a flag to hide the request from the Inspector.
63019
63020        * xml/XMLHttpRequest.cpp:
63021        (WebCore::XMLHttpRequest::XMLHttpRequest):
63022        (WebCore::XMLHttpRequest::sendForInspector): Added.
63023        (WebCore::XMLHttpRequest::sendForInspectorXHRReplay): Renamed.
63024        (WebCore::XMLHttpRequest::createRequest):
63025        * xml/XMLHttpRequest.h:
63026        Make Inspector loads allow cross-origins and hide their request
63027        from the Inspector itself.
63028
630292014-03-07  Tim Horton  <timothy_horton@apple.com>
63030
63031        [WebKit2][iOS] PDF
63032        https://bugs.webkit.org/show_bug.cgi?id=129600
63033        <rdar://problem/15260216>
63034
63035        Reviewed by Anders Carlsson.
63036
63037        * WebCore.exp.in:
63038        * platform/MIMETypeRegistry.cpp:
63039        (WebCore::initializeSupportedImageMIMETypes):
63040        (WebCore::initializePDFMIMETypes):
63041        (WebCore::initializePostScriptMIMETypes):
63042        (WebCore::initializeMIMETypeRegistry):
63043        (WebCore::MIMETypeRegistry::getPDFMIMETypes):
63044        * platform/MIMETypeRegistry.h:
63045        Split PDF and PostScript MIME types, so WebKit2 can retrieve just the PDF ones
63046        without PostScript included.
63047
630482014-03-07  Myles C. Maxfield  <mmaxfield@apple.com>
63049
63050        Comment in RenderStyle is no longer accurate
63051        https://bugs.webkit.org/show_bug.cgi?id=129956
63052
63053        Reviewed by Simon Fraser.
63054
63055        RenderStyle::createStyleInheritingFromPseudoStyle was moved from RenderImage. Before it
63056        was moved, there was an image-specific comment in the function. However, that comment
63057        is both irrelevant to RenderStyle, and incorrect as the function is necessary for
63058        RenderQuotes as well.
63059
63060        No new tests are necessary because there is no behavior change.
63061
63062        * rendering/style/RenderStyle.cpp:
63063        (WebCore::RenderStyle::createStyleInheritingFromPseudoStyle):
63064
630652014-03-07  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
63066
63067        [WebRTC] Throw SYNTAX_ERROR when maxRetransmits and maxRetransmitTime are both set in RTCDataChannelInit
63068        https://bugs.webkit.org/show_bug.cgi?id=129894
63069
63070        Reviewed by Eric Carlson.
63071
63072        Existing test was updated.
63073
63074        * Modules/mediastream/RTCDataChannel.cpp:
63075        (WebCore::RTCDataChannel::create):
63076
630772014-03-07  Benjamin Poulain  <bpoulain@apple.com>
63078
63079        Fix the regression introduced by r165288
63080        https://bugs.webkit.org/show_bug.cgi?id=129934
63081
63082        Reviewed by Ryosuke Niwa.
63083
63084        * page/DOMWindow.cpp:
63085        (WebCore::DOMWindow::scrollX):
63086        (WebCore::DOMWindow::scrollY):
63087        We need to return the new value after layout, not the value from the dirty tree.
63088
630892014-03-07  Benjamin Poulain  <benjamin@webkit.org>
63090
63091        Traversal failure in a direct adjacent chain with tail backtracking lacks the path to clear the tail
63092        https://bugs.webkit.org/show_bug.cgi?id=129863
63093
63094        Reviewed by Gavin Barraclough.
63095
63096        Direct adjacent backtracking use the stack to push the backtracking entry point and recover from there.
63097        In case of traversal failure, their is no point in recovering from the indirect adjancent entry point and
63098        we should clear entry point from the stack (which is the purpose of the tail).
63099
63100        The adjancent tail was missing the part for clearing the stack in one case.
63101
63102        The case with adjancent backtracking inside descendant backtracing was doing everything right. This patch
63103        generalize this code and the correct tail is fully generated by generateAdjacentBacktrackingTail().
63104
63105        JumpToClearAdjacentDescendantTail becomes JumpToClearAdjacentTail, and this new backtracking state is added
63106        to the missing traversal action.
63107
63108        Test: fast/selectors/long-adjacent-backtracking.html
63109
63110        * cssjit/SelectorCompiler.cpp:
63111        (WebCore::SelectorCompiler::solveBacktrackingAction):
63112        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
63113        (WebCore::SelectorCompiler::SelectorCodeGenerator::linkFailures):
63114        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAdjacentBacktrackingTail):
63115        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateBacktrackingTailsIfNeeded):
63116
631172014-03-07  Andreas Kling  <akling@apple.com>
63118
63119        [Mac] Notify system malloc of fake memory pressure.
63120        <https://webkit.org/b/129908>
63121
63122        After fixing the leak in r165252, I was surprised to find that it didn't
63123        show up on memory test bots. It turns out that while the memory is now
63124        getting freed, the system malloc implementation doesn't actually release
63125        pages back to the OS until there is memory pressure.
63126
63127        Since we are just faking the memory pressure on bots, we have to let
63128        system malloc in on the fun, so we can get representative numbers.
63129        With this change, we should finally see the effect of not leaking the
63130        URLRequest object tree.
63131
63132        Reviewed by Anders Carlsson.
63133
63134        * platform/mac/MemoryPressureHandlerMac.mm:
63135        (WebCore::MemoryPressureHandler::install):
63136
63137            Tell system malloc that we are under fake memory pressure.
63138
631392014-03-07  Benjamin Poulain  <bpoulain@apple.com>
63140
63141        [iOS] WebKit1 scroll position is incorrect
63142        https://bugs.webkit.org/show_bug.cgi?id=129905
63143
63144        Reviewed by Simon Fraser.
63145
63146        * page/DOMWindow.cpp:
63147        (WebCore::DOMWindow::scrollX):
63148        (WebCore::DOMWindow::scrollY):
63149        A new optimization was avoiding layout if the position is zero. This was using the scrollX/Y instead
63150        of actualScrollX/Y which caused us to always bail out instead of returning the value to JavaScript.
63151
63152        * platform/ScrollView.h:
63153        (WebCore::ScrollView::actualScrollX):
63154        (WebCore::ScrollView::actualScrollY):
63155        (WebCore::ScrollView::actualScrollPosition):
63156        This was accidentally changed to the iOS compat document visible rect at some point.
63157
631582014-03-07  Adenilson Cavalcanti  <cavalcantii@gmail.com>
63159
63160        Remove unused StdDeviation from Drop shadow effect
63161        https://bugs.webkit.org/show_bug.cgi?id=129891
63162
63163        Reviewed by Dirk Schulze.
63164
63165        No new tests, no change on behavior.
63166
63167        * platform/graphics/filters/FEDropShadow.h:
63168
631692014-03-07  Brent Fulgham  <bfulgham@apple.com>
63170
63171        Correct out-of-band track selection logic.
63172        https://bugs.webkit.org/show_bug.cgi?id=129900
63173
63174        Reviewed by Jer Noble.
63175
63176        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
63177        (WebCore::MediaPlayerPrivateAVFoundationObjC::synchronizeTextTrackState): Correct test to
63178        use inequality.
63179
631802014-03-07  Bear Travis  <betravis@adobe.com>
63181
63182        [CSS Shapes] Correctly serialize ellipse positions
63183        https://bugs.webkit.org/show_bug.cgi?id=129700
63184
63185        Reviewed by Dirk Schulze.
63186
63187        Updating ellipse serialization to be in line with
63188        the CSS Shapes spec. Positions should serialize as
63189        2 or 4-value positions, converting keywords to
63190        percentages where possible. This uses the same method
63191        as circle position serialization (bug 129404).
63192
63193        Updated existing parsing tests.
63194
63195        * css/CSSBasicShapes.cpp:
63196        (WebCore::CSSBasicShapeEllipse::cssText): Use the
63197        normalization / serialization helpers for shape position.
63198
631992014-03-07  Brian Burg  <bburg@apple.com>
63200
63201        Unreviewed, rebaseline run-binding-tests results after r165242.
63202
63203        * bindings/scripts/test/JS/JSTestObj.cpp:
63204        (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
63205        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
63206        (WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
63207
632082014-03-07  Darin Adler  <darin@apple.com>
63209
63210        Remove non-working optimization that was attempted on iOS only
63211        https://bugs.webkit.org/show_bug.cgi?id=129595
63212        <rdar://problem/15798825>
63213
63214        Reviewed by Sam Weinig.
63215
63216        Code in GCController tried to optimize cases where the controller
63217        was used, but no JavaScript had been run in the current process.
63218        The code was never effective, and was iOS-only. Another way to fix
63219        the problem would be to change the code so it works, and if we do
63220        that we should do it for all platforms, not just iOS.
63221
63222        * bindings/js/GCController.cpp:
63223        (WebCore::GCController::garbageCollectNow): Remove check of
63224        JSDOMWindow::commonVMExists, since it's called just after a call
63225        to JSDOMWindow::commonVM, which will create it as a side effect.
63226        (WebCore::GCController::releaseExecutableMemory): Ditto.
63227
63228        * bindings/js/JSDOMWindowBase.cpp:
63229        (WebCore::JSDOMWindowBase::commonVM): Removed iOS-specific code
63230        that pulled the commonVM global out into another function so we
63231        can check for its existence without creating it as a side effect.
63232
63233        * bindings/js/JSDOMWindowBase.h: Ditto.
63234
632352014-03-07  Bem Jones-Bey  <bjonesbe@adobe.com>
63236
63237        [CSS Shapes] inset does not properly clamp large corner radii
63238        https://bugs.webkit.org/show_bug.cgi?id=129726
63239
63240        Reviewed by Dirk Schulze.
63241
63242        Make sure that radii that are larger than 50% of the associated shape
63243        dimension (height or width) are properly reduced the same way as
63244        border-radius radii are.
63245
63246        Test: fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-large-radius.html
63247
63248        * rendering/shapes/Shape.cpp:
63249        (WebCore::ensureRadiiDoNotOverlap): Drive by style fix.
63250        (WebCore::Shape::createShape): Scale radii the same way as border
63251            radii are scaled.
63252        * platform/graphics/FloatRoundedRect.h:
63253        (WebCore::calcBorderRadiiConstraintScaleFor): Move border radii
63254            constraint calculation function out so that it can be shared by
63255            the shape code.
63256        * rendering/style/RenderStyle.cpp:
63257        (WebCore::RenderStyle::getRoundedBorderFor): Call renamed scale function.
63258
632592014-03-07  Carlos Garcia Campos  <cgarcia@igalia.com>
63260
63261        [GST] Set name to several timeout sources
63262        https://bugs.webkit.org/show_bug.cgi?id=129878
63263
63264        Reviewed by Philippe Normand.
63265
63266        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
63267        (WebCore::MediaPlayerPrivateGStreamer::videoChanged):
63268        (WebCore::MediaPlayerPrivateGStreamer::videoCapsChanged):
63269        (WebCore::MediaPlayerPrivateGStreamer::audioChanged):
63270        (WebCore::MediaPlayerPrivateGStreamer::textChanged):
63271        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
63272        (WebCore::MediaPlayerPrivateGStreamerBase::volumeChanged):
63273        (WebCore::MediaPlayerPrivateGStreamerBase::muteChanged):
63274
632752014-03-07  Carlos Garcia Campos  <cgarcia@igalia.com>
63276
63277        [GTK] Timeout sources not correctly removed
63278        https://bugs.webkit.org/show_bug.cgi?id=129877
63279
63280        Reviewed by Philippe Normand.
63281
63282        Set source ID variables to 0 after removing the sources from the
63283        context. Also give a name to the sources.
63284
63285        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
63286        (WebCore::TrackPrivateBaseGStreamer::disconnect):
63287        (WebCore::TrackPrivateBaseGStreamer::activeChanged):
63288        (WebCore::TrackPrivateBaseGStreamer::tagsChanged):
63289        (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfActiveChanged):
63290
632912014-03-07  Gergo Balogh  <gbalogh.u-szeged@partner.samsung.com>
63292
63293        Remove FFTFrameMKL.
63294        https://bugs.webkit.org/show_bug.cgi?id=129866
63295
63296        Reviewed by Csaba Osztrogonác.
63297
63298        * platform/audio/FFTFrame.h:
63299        * platform/audio/FFTFrameStub.cpp:
63300        * platform/audio/mkl/FFTFrameMKL.cpp: Removed, it is never used.
63301
633022014-03-07  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
63303
63304        [WebRTC] Adding getConfiguration method to RTCPeerConnection
63305        https://bugs.webkit.org/show_bug.cgi?id=129845
63306
63307        Reviewed by Eric Carlson.
63308
63309        Test: fast/mediastream/RTCPeerConnection-getConfiguration.html
63310
63311        * CMakeLists.txt:
63312        * DerivedSources.make:
63313        * GNUmakefile.list.am:
63314        * Modules/mediastream/RTCConfiguration.idl: Added.
63315        * Modules/mediastream/RTCIceServer.idl: Added.
63316        * Modules/mediastream/RTCPeerConnection.cpp:
63317        (WebCore::RTCPeerConnection::RTCPeerConnection):
63318        (WebCore::RTCPeerConnection::updateIce):
63319        (WebCore::RTCPeerConnection::getConfiguration):
63320        * Modules/mediastream/RTCPeerConnection.h:
63321        * Modules/mediastream/RTCPeerConnection.idl:
63322
633232014-03-07  Jinwoo Song  <jinwoo7.song@samsung.com>
63324
63325        Optimize collectionLast() and collectionTraverseBackward() in LiveNodeList
63326        https://bugs.webkit.org/show_bug.cgi?id=129775
63327
63328        Reviewed by Ryosuke Niwa.
63329
63330        Check the LiveNodeList type if it is HTMLTagNodeListType and ClassNodeListType then
63331        apply inlined matching methods for each type.
63332
63333        * dom/LiveNodeList.cpp:
63334        (WebCore::lastMatchingElement): Added.
63335        (WebCore::previousMatchingElement): Added.
63336        (WebCore::traverseMatchingElementsBackward): Added.
63337        (WebCore::LiveNodeList::collectionLast): Apply lastMatchingElement() with LiveNodeList type.
63338        (WebCore::LiveNodeList::collectionTraverseBackward): Apply traverseMatchingElementsBackward()
63339        with LiveNodeList type.
63340
633412014-03-06  Andreas Kling  <akling@apple.com>
63342
63343        WebCoreResourceHandleAsOperationQueueDelegate over-retains NSURLRequest.
63344        <https://webkit.org/b/129862>
63345
63346        Don't retain the pointer before assigning it to a RetainPtr, since that
63347        will cause the object to leak.
63348
63349        Reviewed by Alexey Proskuryakov.
63350
63351        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
63352        (-[WebCoreResourceHandleAsOperationQueueDelegate continueWillSendRequest:]):
63353
633542014-03-06  Dan Bernstein  <mitz@apple.com>
63355
63356        Don’t copy WebInputs.json into the framework.
63357
63358        * WebCore.xcodeproj/project.pbxproj: Removed WebInputs.json from the Copy Bundle Resources
63359        build phase of the WebCore target.
63360
633612014-03-06  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
63362
63363        [WebRTC] Updating RTCPeerConnection.idl
63364        https://bugs.webkit.org/show_bug.cgi?id=129804
63365
63366        Reviewed by Eric Carlson.
63367
63368        Some methods signatures were wrong, marking some arguments as optional when they are mandatory.
63369
63370        Existing tests were updated.
63371
63372        * Modules/mediastream/RTCPeerConnection.cpp:
63373        (WebCore::RTCPeerConnection::getStats):
63374        * Modules/mediastream/RTCPeerConnection.h:
63375        * Modules/mediastream/RTCPeerConnection.idl:
63376        * Modules/mediastream/RTCStatsRequestImpl.cpp:
63377        (WebCore::RTCStatsRequestImpl::create):
63378        (WebCore::RTCStatsRequestImpl::RTCStatsRequestImpl):
63379        (WebCore::RTCStatsRequestImpl::requestFailed):
63380        * Modules/mediastream/RTCStatsRequestImpl.h:
63381        * platform/mediastream/RTCStatsRequest.h:
63382
633832014-03-06  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
63384
63385        [WebRTC] Updating RTCIceServer to match spec
63386        https://bugs.webkit.org/show_bug.cgi?id=129844
63387
63388        Reviewed by Eric Carlson.
63389
63390        Move RTCIceServer from RTCConfiguration to its own file.
63391
63392        * Modules/mediastream/RTCPeerConnection.cpp:
63393        (WebCore::validateIceServerURL):
63394        (WebCore::processIceServer):
63395        * platform/mediastream/RTCConfiguration.h:
63396        (WebCore::RTCConfiguration::iceServers):
63397        * platform/mediastream/RTCIceServer.h: Added.
63398
633992014-03-06  Hyowon Kim  <hw1008.kim@samsung.com>
63400
63401        [EFL] Move EvasGL classes from WebKit to WebCore namespace.
63402        https://bugs.webkit.org/show_bug.cgi?id=129797
63403
63404        Reviewed by Gyuyoung Kim.
63405
63406        Though EvasGLContext and EvasGLSurface files were moved from WebKit2/UIProcess/API/efl/ 
63407        to WebCore/platform/graphics/efl/, they are still in WebKit namespace.
63408        Patch for namespace changes.
63409
63410        * platform/graphics/efl/EvasGLContext.cpp:
63411        * platform/graphics/efl/EvasGLContext.h:
63412        * platform/graphics/efl/EvasGLSurface.cpp:
63413        * platform/graphics/efl/EvasGLSurface.h:
63414
634152014-03-06  Brian Burg  <bburg@apple.com>
63416
63417        CodeGeneratorJS.pm doesn't need to add spaces between consecutive closing template brackets
63418        https://bugs.webkit.org/show_bug.cgi?id=129836
63419
63420        Reviewed by Andreas Kling.
63421
63422        * bindings/scripts/CodeGeneratorJS.pm:
63423        (GenerateParametersCheck):
63424        (GetNativeVectorInnerType):
63425        (GetSVGPropertyTypes):
63426
634272014-03-06  Jinwoo Song  <jinwoo7.song@samsung.com>
63428
63429        Remove unused method from BatteryController
63430        https://bugs.webkit.org/show_bug.cgi?id=129850
63431
63432        Reviewed by Gyuyoung Kim.
63433
63434        isActive() method is never called anywhere.
63435
63436        * Modules/battery/BatteryController.cpp:
63437        * Modules/battery/BatteryController.h:
63438
634392014-03-06  Pratik Solanki  <psolanki@apple.com>
63440
63441        [iOS] Crash on launch with website restrictions enabled
63442        https://bugs.webkit.org/show_bug.cgi?id=129854
63443        <rdar://problem/16207016>
63444
63445        Reviewed by Simon Fraser.
63446
63447        * platform/mac/ContentFilterMac.mm:
63448        (WebCore::ContentFilter::ContentFilter): Initialize m_neFilterSourceQueue so that we don't
63449        crash in the dtor due to garbage value in the field.
63450
634512014-03-06  Simon Fraser  <simon.fraser@apple.com>
63452
63453        Minor optimization in ScrollingTreeScrollingNodeMac
63454        https://bugs.webkit.org/show_bug.cgi?id=129848
63455
63456        Reviewed by Dean Jackson.
63457
63458        No need to call scrollOffsetForFixedPosition() again if we don't have header
63459        and footer layers.
63460
63461        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
63462        (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
63463
634642014-03-06  Mark Lam  <mark.lam@apple.com>
63465
63466        XMLHttpRequest: status and statusText throw DOM Exception 11 when the state is UNSENT or OPENED.
63467        https://bugs.webkit.org/show_bug.cgi?id=45994
63468
63469        Not reviewed.
63470
63471        Re-landing r161051 (originally by Ryosuke Niwa, reviewed by Alexey Proskuryakov)
63472        since https://bugs.webkit.org/show_bug.cgi?id=126219 is no longer an issue.
63473
63474        * xml/XMLHttpRequest.cpp:
63475        (WebCore::XMLHttpRequest::status):
63476        (WebCore::XMLHttpRequest::statusText):
63477        * xml/XMLHttpRequest.h:
63478        * xml/XMLHttpRequest.idl:
63479
634802014-03-06  Brent Fulgham  <bfulgham@apple.com>
63481
63482        Revise Out-of-band VTT support for better integration with AVFoundation engine
63483        https://bugs.webkit.org/show_bug.cgi?id=129749
63484        <rdar://problem/16215701>
63485
63486        Reviewed by Eric Carlson.
63487
63488        Revise the platform handling of out-of-band text tracks so that we can keep AVFoundation
63489        informed of track selections we make. Use a dummy out-of-band child of the existing text
63490        track classes to avoid code duplication.
63491
63492        * WebCore.xcodeproj/project.pbxproj: Add new OutOfBandTextTrackPrivateAVF.h file.
63493        * html/HTMLMediaElement.cpp:
63494        (WebCore::HTMLMediaElement::parseAttribute): Notify player when OOB tracks change.
63495        (WebCore::HTMLMediaElement::outOfBandTrackSources): Also pass track mode to platform backend.
63496        * html/track/TextTrack.cpp:
63497        (WebCore::TextTrack::platformTextTrack): Also pass track mode to constructor.
63498        * html/track/TrackBase.cpp:
63499        (WebCore::TrackBase::TrackBase): Move ownership of track unique identifier to this base class.
63500        * html/track/TrackBase.h:
63501        (WebCore::TrackBase::uniqueId): Ditto.
63502        * platform/graphics/MediaPlayer.cpp:
63503        (WebCore::MediaPlayer::notifyTrackModeChanged): Added stub to pass message to platform player.
63504        * platform/graphics/MediaPlayer.h:
63505        * platform/graphics/MediaPlayerPrivate.h:
63506        (WebCore::MediaPlayerPrivateInterface::notifyTrackModeChanged): Stub for most platforms.
63507        * platform/graphics/PlatformTextTrack.h:
63508        (WebCore::PlatformTextTrack::create): Update for revised constructor (with 'mode' argument).
63509        (WebCore::PlatformTextTrack::createOutOfBand): Ditto.
63510        (WebCore::PlatformTextTrack::mode): Added.
63511        (WebCore::PlatformTextTrack::captionMenuOffItem): Use revised constructor arguments.
63512        (WebCore::PlatformTextTrack::captionMenuAutomaticItem): Ditto.
63513        (WebCore::PlatformTextTrack::PlatformTextTrack): Ditto.
63514        * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h: Change predicate to return enum indicating the category
63515        of track (out-of-band, legacy closed caption, or in band).
63516        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
63517        (WebCore::MediaPlayerPrivateAVFoundation::notifyTrackModeChanged): Added.
63518        * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.h: Override predicate to return category enum.
63519        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp: Revise to use new category enum.
63520        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.h: Override predicate to return category enum.
63521        that this is NOT an out-of-band track.
63522        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateLegacyAVFObjC.h: Ditto.
63523        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
63524        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
63525        (WebCore::MediaPlayerPrivateAVFoundationObjC::notifyTrackModeChanged): Added implementation.
63526        (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions): Revise to handle out-of-band
63527        track placeholders.
63528        (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTrack): Modify to inform AVFoundation about any
63529        out-of-band tracks we've selected.
63530        (WebCore::MediaPlayerPrivateAVFoundationObjC::synchronizeTextTrackState): Added.
63531        * platform/graphics/avfoundation/objc/OutOfBandTextTrackPrivateAVF.h: Added.
63532        (WebCore::OutOfBandTextTrackPrivateAVF::create):
63533        (WebCore::OutOfBandTextTrackPrivateAVF::processCue):
63534        (WebCore::OutOfBandTextTrackPrivateAVF::resetCueValues):
63535        (WebCore::OutOfBandTextTrackPrivateAVF::mediaSelectionOption):
63536        (WebCore::OutOfBandTextTrackPrivateAVF::OutOfBandTextTrackPrivateAVF):
63537        (WebCore::OutOfBandTextTrackPrivateAVF::processCueAttributes):
63538        * platform/graphics/ios/InbandTextTrackPrivateAVFIOS.h: Override predicate to indicate
63539        that this is NOT an out-of-band track.
63540        * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
63541        (WebCore::MediaPlayerPrivateIOS::setSelectedTextTrack): Correct typo in logging text.
63542
635432014-03-06  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
63544
63545        [WebRTC] Updating createOffer and createAnswer methods to match WebRTC editor's draft of 01/27/2014
63546        https://bugs.webkit.org/show_bug.cgi?id=129484
63547
63548        Reviewed by Eric Carlson.
63549
63550        According to the spec, createOffer and createAnswer will no longer have MediaConstraints as an argument,
63551        instead they will have RTCOfferOptions and RTCOfferAnswerOptions, respectively.
63552
63553        Existing tests were updated.
63554
63555        * CMakeLists.txt:
63556        * GNUmakefile.list.am:
63557        * Modules/mediastream/RTCOfferAnswerOptions.cpp: Added.
63558        * Modules/mediastream/RTCOfferAnswerOptions.h: Added.
63559        * Modules/mediastream/RTCPeerConnection.cpp:
63560        (WebCore::RTCPeerConnection::createOffer):
63561        (WebCore::RTCPeerConnection::createAnswer):
63562        * Modules/mediastream/RTCPeerConnection.h:
63563        * Modules/mediastream/RTCPeerConnection.idl:
63564        * platform/mediastream/RTCPeerConnectionHandler.h:
63565        * platform/mock/RTCPeerConnectionHandlerMock.cpp:
63566        (WebCore::RTCPeerConnectionHandlerMock::createOffer):
63567        (WebCore::RTCPeerConnectionHandlerMock::createAnswer):
63568        * platform/mock/RTCPeerConnectionHandlerMock.h:
63569
635702014-03-06  Brian Burg  <bburg@apple.com>
63571
63572        Web Replay: premature release() of PassRefPtr in InspectorReplayAgent
63573        https://bugs.webkit.org/show_bug.cgi?id=129827
63574
63575        Reviewed by Timothy Hatcher.
63576
63577        * inspector/InspectorReplayAgent.cpp:
63578        (WebCore::InspectorReplayAgent::didCreateFrontendAndBackend):
63579
635802014-03-06  Benjamin Poulain  <bpoulain@apple.com>
63581
63582        [iOS] Do not compile fake mouse event handling when iOS Touch Events are enabled
63583        https://bugs.webkit.org/show_bug.cgi?id=129725
63584
63585        Reviewed by Dan Bernstein.
63586
63587        Bug <rdar://problem/16218636>. The code is #ifdef'ed out to avoid setting up useless objects
63588        and to avoid future mistake.
63589
63590        * page/EventHandler.cpp:
63591        (WebCore::EventHandler::EventHandler):
63592        (WebCore::EventHandler::~EventHandler):
63593        (WebCore::EventHandler::clear):
63594        (WebCore::EventHandler::handleMousePressEvent):
63595        (WebCore::EventHandler::startAutoHideCursorTimer):
63596        (WebCore::EventHandler::handleMouseMoveEvent):
63597        (WebCore::EventHandler::dispatchFakeMouseMoveEventSoon):
63598        (WebCore::EventHandler::dispatchFakeMouseMoveEventSoonInQuad):
63599        * page/EventHandler.h:
63600
636012014-03-06  Pratik Solanki  <psolanki@apple.com>
63602
63603        Unreviewed. iOS build fix after r165199.
63604
63605        * rendering/RootInlineBox.cpp:
63606
636072014-03-06  Benjamin Poulain  <bpoulain@apple.com>
63608
63609        [iOS] Rename the actualVisibleXXXRect to unobscuredContentRect for consistency
63610        https://bugs.webkit.org/show_bug.cgi?id=129773
63611
63612        Reviewed by Simon Fraser.
63613
63614        * dom/TreeScope.cpp:
63615        (WebCore::nodeFromPoint):
63616        * platform/ScrollView.cpp:
63617        (WebCore::ScrollView::visibleContentRectInternal):
63618        * platform/ScrollView.h:
63619        * platform/ios/ScrollViewIOS.mm:
63620        (WebCore::ScrollView::unoscuredContentRect):
63621        * platform/ios/wak/WAKScrollView.h:
63622        * platform/ios/wak/WAKScrollView.mm:
63623        (-[WAKScrollView unoscuredContentRect]):
63624        (-[WAKScrollView description]):
63625        * rendering/RenderLayer.cpp:
63626        (WebCore::RenderLayer::scrollRectToVisible):
63627
636282014-03-05  Oliver Hunt  <oliver@apple.com>
63629
63630        Support caching of custom setters
63631        https://bugs.webkit.org/show_bug.cgi?id=129519
63632
63633        Reviewed by Filip Pizlo.
63634
63635        Add forwarding header
63636
63637        Tests: js/regress/assign-custom-setter-polymorphic.html
63638               js/regress/assign-custom-setter.html
63639
63640        * ForwardingHeaders/jit/SpillRegistersMode.h: Added.
63641
636422014-03-05  Jon Honeycutt  <jhoneycutt@apple.com>
63643
63644        Invalid cast in WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients()
63645
63646        <https://bugs.webkit.org/show_bug.cgi?id=121887>
63647        <rdar://problem/15073043>
63648
63649        Clang appears to be optimizing out a branch in RenderObject::node()
63650        when compiling RenderLayer::FilterInfo::updateReferenceFilterClients().
63651        We'll work around this by factoring out the code in question into a
63652        separate member function marked NEVER_INLINE.
63653
63654        No test possible due to <https://bugs.webkit.org/show_bug.cgi?id=129757>.
63655
63656        Reviewed by David Kilzer.
63657
63658        * rendering/RenderLayerFilterInfo.cpp:
63659        (WebCore::RenderLayer::FilterInfo::layerElement):
63660        Code moved from updateReferenceFilterClients(). Returns the Element*
63661        for m_layer.
63662        (WebCore::RenderLayer::FilterInfo::updateReferenceFilterClients):
63663        Use layerElement().
63664
63665        * rendering/RenderLayerFilterInfo.h:
63666        Declared layerElement().
63667
636682014-03-06  Joseph Pecoraro  <pecoraro@apple.com>
63669
63670        Web Inspector: Expose the console object in JSContexts to interact with Web Inspector
63671        https://bugs.webkit.org/show_bug.cgi?id=127944
63672
63673        Reviewed by Geoffrey Garen.
63674
63675        Covered by existing tests.
63676
63677        * CMakeLists.txt:
63678        * DerivedSources.cpp:
63679        * DerivedSources.make:
63680        * ForwardingHeaders/runtime/ConsoleClient.h: Added.
63681        * ForwardingHeaders/runtime/ConsoleTypes.h: Renamed from Source/WebCore/ForwardingHeaders/inspector/ConsoleTypes.h.
63682        * GNUmakefile.list.am:
63683        * PlatformGTK.cmake:
63684        * WebCore.exp.in:
63685        * WebCore.vcxproj/WebCore.vcxproj:
63686        * WebCore.vcxproj/WebCore.vcxproj.filters:
63687        * WebCore.xcodeproj/project.pbxproj:
63688        * bindings/gobject/GNUmakefile.am:
63689        Update build systems.
63690
63691        * page/Console.cpp: Removed.
63692        * page/Console.h: Removed.
63693        * page/Console.idl: Removed.
63694        * page/DOMWindow.cpp:
63695        (WebCore::DOMWindow::~DOMWindow):
63696        (WebCore::DOMWindow::resetDOMWindowProperties):
63697        * page/DOMWindow.h:
63698        (WebCore::DOMWindow::defaultStatus):
63699        * page/DOMWindow.idl:
63700        Removed the old IDL generated Console object on window.
63701
63702        * page/PageConsole.cpp:
63703        (WebCore::PageConsole::shouldPrintExceptions):
63704        (WebCore::PageConsole::setShouldPrintExceptions):
63705        (WebCore::PageConsole::mute):
63706        (WebCore::PageConsole::unmute):
63707        (WebCore::PageConsole::messageWithTypeAndLevel):
63708        (WebCore::PageConsole::count):
63709        (WebCore::PageConsole::profile):
63710        (WebCore::PageConsole::profileEnd):
63711        (WebCore::PageConsole::time):
63712        (WebCore::PageConsole::timeEnd):
63713        (WebCore::PageConsole::timeStamp):
63714        (WebCore::PageConsole::group):
63715        (WebCore::PageConsole::groupCollapsed):
63716        (WebCore::PageConsole::groupEnd):
63717        (WebCore::PageConsole::clearProfiles):
63718        * page/PageConsole.h:
63719        Move the handling of Console object into PageConsole.
63720
63721        * bindings/js/ScriptCachedFrameData.cpp:
63722        (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
63723        (WebCore::ScriptCachedFrameData::restore):
63724        * bindings/js/ScriptController.cpp:
63725        (WebCore::ScriptController::clearWindowShell):
63726        (WebCore::ScriptController::initScript):
63727        Set the PageConsole as the ConsoleClient of the JSGlobalObject
63728        so that WebCore may handle console messages directly. For instance
63729        it may pass messages on to the ChromeClient.
63730
63731        * testing/Internals.cpp:
63732        (WebCore::Internals::consoleProfiles):
63733        To access profiles, go through PageConsole now instead of Console.
63734
63735        * bindings/js/JSDOMWindowBase.cpp:
63736        * bindings/objc/WebScriptObject.mm:
63737        * css/MediaList.cpp:
63738        * dom/ScriptExecutionContext.h:
63739        * dom/UIEvent.cpp:
63740        * dom/ViewportArguments.cpp:
63741        * html/parser/XSSAuditorDelegate.cpp:
63742        * inspector/CommandLineAPIHost.h:
63743        * inspector/InspectorInstrumentation.cpp:
63744        * inspector/InspectorInstrumentation.h:
63745        * inspector/InspectorProfilerAgent.cpp:
63746        * inspector/WebConsoleAgent.cpp:
63747        * loader/FrameLoader.cpp:
63748        * loader/MixedContentChecker.cpp:
63749        * loader/appcache/ApplicationCacheGroup.cpp:
63750        * loader/cache/CachedResourceLoader.cpp:
63751        * page/ChromeClient.h:
63752        * page/ContentSecurityPolicy.cpp:
63753        * page/Page.cpp:
63754        * page/Page.h:
63755        * svg/SVGDocumentExtensions.cpp:
63756        * workers/WorkerMessagingProxy.cpp:
63757        * workers/WorkerReportingProxy.h:
63758        Update includes.
63759
637602014-03-06  Zsolt Borbely  <borbezs@inf.u-szeged.hu>
63761
63762        Fix the !ENABLE(CSS_STICKY_POSITION) build
63763        https://bugs.webkit.org/show_bug.cgi?id=129793
63764
63765        Reviewed by Simon Fraser.
63766
63767        Add missing ENABLE(CSS_STICKY_POSITION) guard to EditingStyle::convertPositionStyle().
63768
63769        * editing/EditingStyle.cpp:
63770        (WebCore::EditingStyle::convertPositionStyle):
63771
637722014-03-06  Joseph Pecoraro  <pecoraro@apple.com>
63773
63774        [Mac] Leak: dispatch_semaphore leak allocated in MediaPlayerPrivateAVFoundationObjC::waitForVideoOutputMediaDataWillChange
63775        https://bugs.webkit.org/show_bug.cgi?id=129792
63776
63777        Reviewed by Anders Carlsson.
63778
63779        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
63780        (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC):
63781
637822014-03-06  Brendan Long  <b.long@cablelabs.com>
63783
63784        Implement VideoTrackList.selectedIndex
63785        https://bugs.webkit.org/show_bug.cgi?id=129770
63786
63787        Reviewed by Eric Carlson.
63788
63789        Tests: media/track/video/video-track-mkv-theora-selected.html
63790
63791        * html/track/VideoTrackList.idl:
63792
637932014-03-06  Lorenzo Tilve  <ltilve@igalia.com>
63794
63795        [GTK][CMake] Fix the GTK+ CMake build
63796        https://bugs.webkit.org/show_bug.cgi?id=129801
63797
63798        Reviewed by Martin Robinson.
63799
63800        Include missing files for CMake build
63801
63802        * CMakeLists.txt: Add a missing references to DOMURLMediaStream
63803
638042014-03-06  Zalan Bujtas  <zalan@apple.com>
63805
63806        Subpixel rendering: Setting content to opaque on m_graphicsLayer depends on subpixel accumulation.
63807        https://bugs.webkit.org/show_bug.cgi?id=129776
63808
63809        Reviewed by Simon Fraser.
63810
63811        isEmpty() returns true when any of the dimensions is <= 0. Subpixel accumulation could happen
63812        in one direction only. Use isZero() instead().
63813
63814        * rendering/RenderLayerBacking.cpp:
63815        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
63816
638172014-03-06  Gurpreet Kaur  <k.gurpreet@samsung.com>
63818
63819        REGRESSION (r158254): Rubber-banding at Bing image search causes the toolbar to move up and away
63820        https://bugs.webkit.org/show_bug.cgi?id=128873
63821
63822        Reviewed by Antonio Gomes.
63823
63824        This regression is caused by  http://trac.webkit.org/changeset/154614 
63825        and http://trac.webkit.org/changeset/156605. So reverting the changes
63826        to make it Web compatible as earlier.
63827
63828        * dom/Element.cpp:
63829        (WebCore::Element::scrollLeft):
63830        (WebCore::Element::scrollTop):
63831        (WebCore::Element::setScrollLeft):
63832        (WebCore::Element::setScrollTop):
63833        Reverting changes as it caused regression.
63834
638352014-03-06  Zan Dobersek  <zdobersek@igalia.com>
63836
63837        Move Source/WebCore/html/canvas/ code to std::unique_ptr
63838        https://bugs.webkit.org/show_bug.cgi?id=129668
63839
63840        Reviewed by Anders Carlsson.
63841
63842        Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/html/canvas/ to std::unique_ptr.
63843
63844        * html/HTMLCanvasElement.cpp:
63845        (WebCore::HTMLCanvasElement::~HTMLCanvasElement):
63846        (WebCore::HTMLCanvasElement::getContext):
63847        * html/HTMLCanvasElement.h:
63848        * html/canvas/ANGLEInstancedArrays.cpp:
63849        * html/canvas/ANGLEInstancedArrays.h:
63850        * html/canvas/CanvasRenderingContext2D.h:
63851        * html/canvas/EXTTextureFilterAnisotropic.cpp:
63852        * html/canvas/EXTTextureFilterAnisotropic.h:
63853        * html/canvas/OESElementIndexUint.cpp:
63854        * html/canvas/OESElementIndexUint.h:
63855        * html/canvas/OESStandardDerivatives.cpp:
63856        * html/canvas/OESStandardDerivatives.h:
63857        * html/canvas/OESTextureFloat.cpp:
63858        * html/canvas/OESTextureFloat.h:
63859        * html/canvas/OESTextureFloatLinear.cpp:
63860        * html/canvas/OESTextureFloatLinear.h:
63861        * html/canvas/OESTextureHalfFloat.cpp:
63862        * html/canvas/OESTextureHalfFloat.h:
63863        * html/canvas/OESTextureHalfFloatLinear.cpp:
63864        * html/canvas/OESTextureHalfFloatLinear.h:
63865        * html/canvas/OESVertexArrayObject.cpp:
63866        * html/canvas/OESVertexArrayObject.h:
63867        * html/canvas/WebGLCompressedTextureATC.cpp:
63868        * html/canvas/WebGLCompressedTextureATC.h:
63869        * html/canvas/WebGLCompressedTexturePVRTC.cpp:
63870        * html/canvas/WebGLCompressedTexturePVRTC.h:
63871        * html/canvas/WebGLCompressedTextureS3TC.cpp:
63872        * html/canvas/WebGLCompressedTextureS3TC.h:
63873        * html/canvas/WebGLDebugRendererInfo.cpp:
63874        * html/canvas/WebGLDebugRendererInfo.h:
63875        * html/canvas/WebGLDebugShaders.cpp:
63876        * html/canvas/WebGLDebugShaders.h:
63877        * html/canvas/WebGLDepthTexture.cpp:
63878        * html/canvas/WebGLDepthTexture.h:
63879        * html/canvas/WebGLDrawBuffers.cpp:
63880        * html/canvas/WebGLDrawBuffers.h:
63881        * html/canvas/WebGLLoseContext.cpp:
63882        * html/canvas/WebGLLoseContext.h:
63883        * html/canvas/WebGLRenderingContext.cpp:
63884        (WebCore::WebGLRenderingContext::create):
63885        (WebCore::WebGLRenderingContext::getExtension):
63886        * html/canvas/WebGLRenderingContext.h:
63887
638882014-03-06  Zan Dobersek  <zdobersek@igalia.com>
63889
63890        Move Source/WebCore/editing/ code to std::unique_ptr
63891        https://bugs.webkit.org/show_bug.cgi?id=129665
63892
63893        Reviewed by Anders Carlsson.
63894
63895        Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/editing/ with std::unique_ptr.
63896
63897        * editing/EditingStyle.cpp:
63898        (WebCore::htmlElementEquivalents):
63899        (WebCore::EditingStyle::conflictsWithImplicitStyleOfElement):
63900        (WebCore::htmlAttributeEquivalents):
63901        (WebCore::EditingStyle::conflictsWithImplicitStyleOfAttributes):
63902        (WebCore::EditingStyle::extractConflictingImplicitStyleOfAttributes):
63903        (WebCore::EditingStyle::elementIsStyledSpanOrHTMLEquivalent):
63904        (WebCore::EditingStyle::mergeInlineAndImplicitStyleOfElement):
63905        * editing/Editor.cpp:
63906        (WebCore::Editor::Editor):
63907        (WebCore::Editor::clear):
63908        * editing/Editor.h:
63909        * page/Frame.cpp:
63910        (WebCore::Frame::Frame):
63911        * page/Frame.h:
63912
639132014-03-06  Zan Dobersek  <zdobersek@igalia.com>
63914
63915        Move to using std::unique_ptr for KeyboardEvent, ScriptExecutionContext::PendingException
63916        https://bugs.webkit.org/show_bug.cgi?id=129061
63917
63918        Reviewed by Eric Carlson.
63919
63920        Replace uses of OwnPtr and PassOwnPtr for KeyboardEvent and ScriptExecutionContext::PendingException
63921        classes with std::unique_ptr. ScriptExecutionContext::Task objects are still handled through OwnPtr,
63922        but this will be addressed later.
63923
63924        * dom/KeyboardEvent.cpp:
63925        (WebCore::KeyboardEvent::KeyboardEvent):
63926        * dom/KeyboardEvent.h:
63927        * dom/ScriptExecutionContext.cpp:
63928        (WebCore::ScriptExecutionContext::reportException):
63929        * dom/ScriptExecutionContext.h:
63930        * dom/ScriptRunner.h: Remove an unnecessary PassOwnPtr header inclusion.
63931
639322014-03-06  Commit Queue  <commit-queue@webkit.org>
63933
63934        Unreviewed, rolling out r165175.
63935        http://trac.webkit.org/changeset/165175
63936        https://bugs.webkit.org/show_bug.cgi?id=129788
63937
63938        Linking failures on GTK, EFL due to missing gstreamer-tag-1.0
63939        dependency (Requested by zdobersek on #webkit).
63940
63941        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
63942        (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfTagsChanged):
63943
639442014-03-05  Brendan Long  <b.long@cablelabs.com>
63945
63946        [GStreamer] human readable language code for tracks
63947        https://bugs.webkit.org/show_bug.cgi?id=124514
63948
63949        Reviewed by Philippe Normand.
63950
63951        * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp:
63952        (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfTagsChanged): Run language codes though gst_tag_get_language_code_iso_639_1() to make sure they're valid.
63953
639542014-03-05  Ryuan Choi  <ryuan.choi@samsung.com>
63955
63956        Remove unused method from Vibration
63957        https://bugs.webkit.org/show_bug.cgi?id=129732
63958
63959        Reviewed by Gyuyoung Kim.
63960
63961        * Modules/vibration/Vibration.cpp:
63962        Removed isActive(), which is never called since r152441.
63963        * Modules/vibration/Vibration.h: Ditto.
63964
639652014-03-05  Commit Queue  <commit-queue@webkit.org>
63966
63967        Unreviewed, rolling out r165141, r165157, and r165158.
63968        http://trac.webkit.org/changeset/165141
63969        http://trac.webkit.org/changeset/165157
63970        http://trac.webkit.org/changeset/165158
63971        https://bugs.webkit.org/show_bug.cgi?id=129772
63972
63973        "broke ftl" (Requested by olliej_ on #webkit).
63974
63975        * ForwardingHeaders/jit/SpillRegistersMode.h: Removed.
63976
639772014-03-05  Martin Robinson  <mrobinson@igalia.com>
63978
63979        [GTK][CMake] The GObject DOM bindings should always be built
63980        https://bugs.webkit.org/show_bug.cgi?id=127963
63981
63982        Reviewed by Ryosuke Niwa.
63983
63984        * PlatformGTK.cmake: Make compilation of the WebKitGTK+ GObject DOM bindings
63985        unconditional, instead of conditional on the WebKit2 build.
63986
639872014-03-05  Jer Noble  <jer.noble@apple.com>
63988
63989        [MSE] Crash in SourceBuffer::sourceBufferPrivateDidReceiveSample() - received samples after SourceBuffer was removed.
63990        https://bugs.webkit.org/show_bug.cgi?id=129761
63991
63992        Reviewed by Eric Carlson.
63993
63994        Guard against the possibility that SourceBufferPrivates will continue to generate samples even after
63995        a parse error. Bail out early from sourceBufferPrivateDidReceiveInitializationSegment and
63996        sourceBufferPrivateDidReceiveSample if the SourceBuffer has been removed.
63997
63998        * Modules/mediasource/SourceBuffer.cpp:
63999        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment):
64000        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
64001
640022014-03-05  Enrica Casucci  <enrica@apple.com>
64003
64004        Build fix, take 2.
64005
64006        * platform/mac/HTMLConverter.mm:
64007
640082014-03-05  Enrica Casucci  <enrica@apple.com>
64009
64010        Build fix.
64011
64012        * platform/mac/HTMLConverter.mm:
64013
640142014-03-05  Enrica Casucci  <enrica@apple.com>
64015
64016        Crash when copying content that contains <sup>.
64017        https://bugs.webkit.org/show_bug.cgi?id=129765
64018        <rdar://problem/16139498>
64019        
64020        Reviewed by Benjamin Poulain.
64021
64022        Adding static definition of NSAttributeSuperscriptName.
64023
64024        * platform/mac/HTMLConverter.mm:
64025
640262014-03-05  Gavin Barraclough  <barraclough@apple.com>
64027
64028        https://bugs.webkit.org/show_bug.cgi?id=128625
64029        Add fast mapping from StringImpl to JSString
64030
64031        Unreviewed roll-out.
64032
64033        Reverting r164347, r165054, r165066 - not clear the performance tradeoff was right.
64034
64035        * bindings/js/DOMWrapperWorld.cpp:
64036        (WebCore::DOMWrapperWorld::clearWrappers):
64037        * bindings/js/DOMWrapperWorld.h:
64038        * bindings/js/JSDOMBinding.h:
64039        (WebCore::jsStringWithCache):
64040        * bindings/js/JSDOMWindowBase.cpp:
64041        (WebCore::JSDOMWindowBase::commonVM):
64042        * bindings/scripts/StaticString.pm:
64043        (GenerateStrings):
64044
640452014-03-05  Daniel Bates  <dabates@apple.com>
64046            And Alexey Proskuryakov  <ap@apple.com>
64047
64048        ASSERT(newestManifest) fails in WebCore::ApplicationCacheGroup::didFinishLoadingManifest()
64049        https://bugs.webkit.org/show_bug.cgi?id=129753
64050        <rdar://problem/12069835>
64051
64052        Reviewed by Alexey Proskuryakov.
64053
64054        Fixes an issue where an assertion failure would occur when visiting a web site whose on-disk
64055        app cache doesn't contain a manifest resource.
64056
64057        For some reason an app cache for a web site may be partially written to disk. In particular, the
64058        app cache may only contain a CacheGroups entry. That is, the manifest resource and origin records
64059        may not be persisted to disk. From looking over the code, we're unclear how such a situation can occur
64060        and hence have been unable to create such an app cache. We were able to reproduce this issue using
64061        an app cache database file that was provided by a person that was affected by this issue.
64062
64063        No test included because it's not straightforward to write a test for this change.
64064
64065        * loader/appcache/ApplicationCacheGroup.cpp:
64066        (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete): Assert that m_cacheBeingUpdated->manifestResource()
64067        is non-null. Currently we only document this assumption in a code comment. Also separated a single assertion
64068        expression into two assertion expressions to make it straightforward to identify the failing sub-expression
64069        on failure.
64070        * loader/appcache/ApplicationCacheStorage.cpp:
64071        (WebCore::ApplicationCacheStorage::store): Modified to call ApplicationCacheStorage::deleteCacheGroupRecord()
64072        to remove a cache group and associated cache records (if applicable) before inserting a cache group entry.
64073        This replacement approach will ultimately repair incomplete app cache data for people affected by this bug.
64074        (WebCore::ApplicationCacheStorage::loadCache): Log an error and return nullptr if the cache we loaded doesn't
64075        have a manifest resource.
64076        (WebCore::ApplicationCacheStorage::deleteCacheGroupRecord): Added.
64077        (WebCore::ApplicationCacheStorage::deleteCacheGroup): Extracted deletion logic for cache group record into
64078        ApplicationCacheStorage::deleteCacheGroupRecord().
64079        * loader/appcache/ApplicationCacheStorage.h:
64080
640812014-03-05  Oliver Hunt  <oliver@apple.com>
64082
64083        Support caching of custom setters
64084        https://bugs.webkit.org/show_bug.cgi?id=129519
64085
64086        Reviewed by Filip Pizlo.
64087
64088        Add forwarding header
64089
64090        Tests: js/regress/assign-custom-setter-polymorphic.html
64091               js/regress/assign-custom-setter.html
64092
64093        * ForwardingHeaders/jit/SpillRegistersMode.h: Added.
64094
640952014-03-05  David Kilzer  <ddkilzer@apple.com>
64096
64097        Fix crash in CompositeEditCommand::cloneParagraphUnderNewElement()
64098        <http://webkit.org/b/129751>
64099        <rdar://problem/16237965>
64100
64101        Reviewed by Jon Honeycutt.
64102
64103        Merged from Blink (patch by Yuta Kitamura):
64104        https://src.chromium.org/viewvc/blink?revision=168160&view=revision
64105        http://crbug.com/345005
64106
64107            The root cause is CompositeEditCommand::moveParagraphWithClones() passing
64108            two positions |start| and |end| which do not follow the document order,
64109            i.e. in some situations |start| is located after |end| because of
64110            the difference in affinity.
64111
64112            This patch fixes this crash by normalizing |end| to |start| in such situations.
64113            It also adds an ASSERT that checks the relationship between |start| and |end|.
64114
64115        Test: editing/execCommand/format-block-crash.html
64116
64117        * editing/CompositeEditCommand.cpp:
64118        (WebCore::CompositeEditCommand::cloneParagraphUnderNewElement):
64119        (WebCore::CompositeEditCommand::moveParagraphWithClones):
64120        * editing/CompositeEditCommand.h:
64121
641222014-03-05  Radu Stavila  <stavila@adobe.com>
64123
64124        [CSS Regions] Scrollable regions
64125        https://bugs.webkit.org/show_bug.cgi?id=129301
64126
64127        Reviewed by David Hyatt.
64128
64129        Named flow fragments do not inherit the overflow property from the fragment container.
64130        When asked if the flow thread content should be clipped, the named flow fragments
64131        will respond using the overflow property of the named flow fragment container.
64132
64133        When painting the flow thread layer inside the region, the scrolled content offset of
64134        the region must be used to offset the flow thread's layer.
64135
64136        Tests: fast/regions/scrollable-last-region.html
64137               fast/regions/scrollable-single-region-bt.html
64138               fast/regions/scrollable-single-region-lr.html
64139               fast/regions/scrollable-single-region-relative-element.html
64140               fast/regions/scrollable-single-region-rl.html
64141               fast/regions/scrollable-single-region.html
64142
64143        * rendering/RenderLayer.cpp:
64144        (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
64145        (WebCore::RenderLayer::calculateClipRects):
64146        * rendering/RenderNamedFlowFragment.cpp:
64147        (WebCore::RenderNamedFlowFragment::createStyle):
64148        (WebCore::RenderNamedFlowFragment::shouldClipFlowThreadContent):
64149        * rendering/RenderNamedFlowFragment.h:
64150        * rendering/RenderNamedFlowThread.cpp:
64151        (WebCore::RenderNamedFlowThread::decorationsClipRectForBoxInNamedFlowFragment):
64152        * rendering/RenderRegion.cpp:
64153        (WebCore::RenderRegion::shouldClipFlowThreadContent):
64154        * rendering/RenderRegion.h:
64155
641562014-03-05  Zalan Bujtas  <zalan@apple.com>
64157
64158        Subpixel rendering: Device pixel round accumulated subpixel value when the RenderLayer with transform paints its content.
64159        https://bugs.webkit.org/show_bug.cgi?id=129079
64160
64161        Reviewed by Simon Fraser.
64162
64163        Snap the content to the device pixel position (as opposed to integral position) before
64164        applying the transform. Recalculate the remaining subpixels that need offsetting at painting time.
64165
64166        Test: compositing/hidpi-absolute-subpixel-positioned-transformed-elements.html
64167
64168        * platform/graphics/LayoutPoint.h:
64169        (WebCore::roundedForPainting):
64170        * rendering/RenderLayer.cpp:
64171        (WebCore::RenderLayer::paintLayerByApplyingTransform):
64172
641732014-03-05  Eric Carlson  <eric.carlson@apple.com>
64174
64175        [iOS] Show external device name/type in placeholder
64176        https://bugs.webkit.org/show_bug.cgi?id=129723
64177
64178        Reviewed by Jer Noble.
64179
64180        Make the name and type of the external device available to the JS based controls.
64181        * Modules/mediacontrols/MediaControlsHost.cpp:
64182        (WebCore::MediaControlsHost::externalDeviceDisplayName):
64183        (WebCore::MediaControlsHost::externalDeviceType):
64184        * Modules/mediacontrols/MediaControlsHost.h:
64185        * Modules/mediacontrols/MediaControlsHost.idl:
64186
64187        * Modules/mediacontrols/mediaControlsiOS.js:
64188        (ControllerIOS.prototype.updateWirelessPlaybackStatus): Display device type-specific infomation
64189            in the placeholder image.
64190
64191        * WebCore.exp.in: Export new WebKitSystemInterface functions.
64192
64193        * platform/graphics/MediaPlayer.cpp:
64194        (WebCore::MediaPlayer::wirelessPlaybackTargetName): Added.
64195        (WebCore::MediaPlayer::wirelessPlaybackTargetType): Ditto.
64196        * platform/graphics/MediaPlayer.h:
64197        * platform/graphics/MediaPlayerPrivate.h:
64198
64199        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
64200        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
64201        (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessPlaybackTargetType): Added.
64202        (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessPlaybackTargetName): Ditto.
64203
64204        * platform/ios/WebCoreSystemInterfaceIOS.mm:
64205        * platform/mac/WebCoreSystemInterface.h:
64206        * platform/mac/WebCoreSystemInterface.mm:
64207
642082014-03-05  Benjamin Poulain  <bpoulain@apple.com>
64209
64210        [iOS] Rename the various VisibleExtent variations to exposedContentRect
64211        https://bugs.webkit.org/show_bug.cgi?id=129728
64212
64213        Reviewed by Simon Fraser.
64214
64215        Rename DocumentVisibleExtent and VisibleExtentContentRect to ExposedContentRect in a desperate
64216        attempt to make things a tiny little bit less confusing.
64217
64218        The name is ExposedContentRect and not ExposedRect as that rect is exposed on ScrollView, while the
64219        rect is in document coordinates (which does not make any difference on WebKit1...).
64220
64221        * WebCore.exp.in:
64222        * platform/ScrollView.h:
64223        * platform/ios/ScrollViewIOS.mm:
64224        (WebCore::ScrollView::exposedContentRect):
64225        (WebCore::ScrollView::setExposedContentRect):
64226        * platform/ios/wak/WAKScrollView.h:
64227        * platform/ios/wak/WAKScrollView.mm:
64228        (-[WAKScrollView exposedContentRect]):
64229        * rendering/RenderLayerCompositor.cpp:
64230        (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
64231        (WebCore::RenderLayerCompositor::didChangeVisibleRect):
64232
642332014-03-05  Simon Fraser  <simon.fraser@apple.com>
64234
64235        ObjC exception when dropping files into a WKView: drag and drop uses code from WebKit.framework
64236        https://bugs.webkit.org/show_bug.cgi?id=129752
64237
64238        Reviewed by Enrica Casucci.
64239
64240        Add C functions for NSURL-related functionality required by WebKit2
64241
64242        * WebCore.exp.in:
64243        * platform/mac/WebCoreNSURLExtras.h:
64244        * platform/mac/WebCoreNSURLExtras.mm:
64245        (WebCore::URLByCanonicalizingURL):
64246        (WebCore::rangeOfURLScheme):
64247        (WebCore::looksLikeAbsoluteURL):
64248
642492014-03-05  Martin Hock  <mhock@apple.com>
64250
64251        Add support for sessions to MemoryCache.
64252        https://bugs.webkit.org/show_bug.cgi?id=127794
64253
64254        Reviewed by Sam Weinig.
64255
64256        * WebCore.exp.in:
64257        * editing/DeleteButtonController.cpp:
64258        (WebCore::DeleteButtonController::createDeletionUI): Initialize CachedImage with sessionID.
64259        * html/DOMURL.cpp:
64260        (WebCore::DOMURL::revokeObjectURL): Remove URL from MemoryCache for all sessions.
64261        * inspector/InspectorPageAgent.cpp:
64262        (WebCore::InspectorPageAgent::cachedResource): Pass sessionID to MemoryCache.
64263        * inspector/InspectorResourceAgent.cpp:
64264        (WebCore::InspectorResourceAgent::replayXHR): Ditto.
64265        * loader/DocumentLoader.cpp:
64266        (WebCore::areAllLoadersPageCacheAcceptable): Ditto.
64267        * loader/FrameLoader.cpp:
64268        (WebCore::FrameLoader::tellClientAboutPastMemoryCacheLoads): Ditto.
64269        * loader/ImageLoader.cpp:
64270        (WebCore::ImageLoader::updateFromElement): Initialize CachedImage with sessionID.
64271        * loader/archive/cf/LegacyWebArchive.cpp:
64272        (WebCore::LegacyWebArchive::create): Pass sessionID to MemoryCache.
64273        * loader/cache/CachedCSSStyleSheet.cpp:
64274        (WebCore::CachedCSSStyleSheet::CachedCSSStyleSheet): Constructor takes sessionID.
64275        * loader/cache/CachedCSSStyleSheet.h:
64276        * loader/cache/CachedFont.cpp: Ditto.
64277        (WebCore::CachedFont::CachedFont):
64278        * loader/cache/CachedFont.h:
64279        * loader/cache/CachedImage.cpp: Ditto.
64280        (WebCore::CachedImage::CachedImage):
64281        * loader/cache/CachedImage.h:
64282        * loader/cache/CachedRawResource.cpp: Ditto.
64283        (WebCore::CachedRawResource::CachedRawResource):
64284        * loader/cache/CachedRawResource.h:
64285        * loader/cache/CachedResource.cpp: Ditto.
64286        (WebCore::CachedResource::CachedResource):
64287        (WebCore::CachedResource::~CachedResource): Pass sessionID to MemoryCache.
64288        * loader/cache/CachedResource.h:
64289        (WebCore::CachedResource::sessionID):
64290        * loader/cache/CachedResourceLoader.cpp:
64291        (WebCore::createResource): Constructors take sessionID.
64292        (WebCore::CachedResourceLoader::sessionID): Retrieve sessionID from page.
64293        (WebCore::CachedResourceLoader::requestUserCSSStyleSheet): Pass sessionID to MemoryCache.
64294        (WebCore::CachedResourceLoader::requestResource): Initialize CachedCSSStyleSheet with sessionID.
64295        (WebCore::CachedResourceLoader::revalidateResource): Initialize cached resource with sessionID.
64296        (WebCore::CachedResourceLoader::loadResource): Pass sessionID to MemoryCache and initialize cached resource with sessionID.
64297        * loader/cache/CachedResourceLoader.h:
64298        * loader/cache/CachedSVGDocument.cpp: Constructor takes sessionID.
64299        (WebCore::CachedSVGDocument::CachedSVGDocument):
64300        * loader/cache/CachedSVGDocument.h:
64301        * loader/cache/CachedScript.cpp: Ditto.
64302        (WebCore::CachedScript::CachedScript):
64303        * loader/cache/CachedScript.h:
64304        * loader/cache/CachedTextTrack.cpp: Ditto.
64305        (WebCore::CachedTextTrack::CachedTextTrack):
64306        * loader/cache/CachedTextTrack.h:
64307        * loader/cache/CachedXSLStyleSheet.cpp: Ditto.
64308        (WebCore::CachedXSLStyleSheet::CachedXSLStyleSheet):
64309        * loader/cache/CachedXSLStyleSheet.h:
64310        * loader/cache/MemoryCache.cpp:
64311        (WebCore::MemoryCache::getSessionMap): Retrieve CachedResourceMap based on sessionID.
64312        (WebCore::MemoryCache::add): Use sessionID from CachedResource parameter.
64313        (WebCore::MemoryCache::revalidationSucceeded): Add sessionID parameter.
64314        (WebCore::MemoryCache::resourceForURL): Ditto.
64315        (WebCore::MemoryCache::resourceForRequest): Ditto, also move impl into impl method.
64316        (WebCore::MemoryCache::resourceForRequestImpl): Add CachedResourceMap parameter.
64317        (WebCore::MemoryCache::addImageToCache): Use default sessionID.
64318        (WebCore::MemoryCache::removeImageFromCache): Ditto.
64319        (WebCore::MemoryCache::evict): Use sessionID from CachedResource parameter.
64320        (WebCore::MemoryCache::removeResourcesWithOrigin): Iterate through all CachedResourceMaps.
64321        (WebCore::MemoryCache::getOriginsWithCache): Ditto.
64322        (WebCore::MemoryCache::removeUrlFromCache): Add sessionID parameter.
64323        (WebCore::MemoryCache::removeRequestFromCache): Ditto.
64324        (WebCore::MemoryCache::removeRequestFromSessionCaches): Remove request from all CachedResourceMaps, with multithread support.
64325        (WebCore::MemoryCache::removeRequestFromCacheImpl): Add sessionID parameter.
64326        (WebCore::MemoryCache::removeRequestFromSessionCachesImpl): Iterate through all CachedResourceMaps.
64327        (WebCore::MemoryCache::crossThreadRemoveRequestFromCache): Add sessionID parameter.
64328        (WebCore::MemoryCache::crossThreadRemoveRequestFromSessionCaches): Pass on request to removeRequestFromSessionCachesImpl.
64329        (WebCore::MemoryCache::getStatistics): Iterate through all CachedResourceMaps.
64330        (WebCore::MemoryCache::setDisabled): Ditto.
64331        * loader/cache/MemoryCache.h: Create another level for cache.
64332        * platform/CrossThreadCopier.cpp: Allow copying SessionIDs across threads.
64333        (WebCore::SessionID>::copy):
64334        * platform/CrossThreadCopier.h:
64335        * platform/network/cf/ResourceRequest.h:
64336        (WebCore::ResourceRequest::ResourceRequest): Remove trailing whitespace.
64337        * rendering/RenderSnapshottedPlugIn.cpp:
64338        (WebCore::RenderSnapshottedPlugIn::updateSnapshot): Initialize CachedImage with sessionID.
64339        * testing/Internals.cpp:
64340        (WebCore::Internals::isLoadingFromMemoryCache): Pass sessionID to MemoryCache.
64341
643422014-03-03  Martin Robinson  <mrobinson@igalia.com>
64343
64344        [GTK][CMake] Generate documentation for the DOM bindings
64345        https://bugs.webkit.org/show_bug.cgi?id=126211
64346
64347        Reviewed by Carlos Garcia Campos.
64348
64349        * PlatformGTK.cmake: Add some files to the GObjectDOMBindings build, so that the
64350        doc generation succeeds. Have the GObjectDOMBindings_INSTALLED_HEADERS variable contain
64351        all installed headers and use another variable for GIR generation. Create the configuration
64352        file for the gtkdoc generation.
64353
643542014-03-05  Zalan Bujtas  <zalan@apple.com>
64355
64356        Subpixel rendering: Wrong cliprect on absolute positioned elements.
64357        https://bugs.webkit.org/show_bug.cgi?id=129656
64358
64359        Reviewed by Simon Fraser.
64360
64361        outlineBoundsForRepaint() is expected to return the outline repaint rect. Using enclosingIntRect()
64362        to calculate the outline boundaries breaks repaint logic in RenderElement::repaintAfterLayoutIfNeeded().
64363        Since enclosingIntRect() can return bigger rect than repaint rect, the old/new bounds' dimensions could end up
64364        being different which triggers the size change repaint code path.
64365
64366        Test: fast/repaint/hidpi-absolute-positioned-element-wrong-cliprect-after-move.html
64367
64368        * rendering/RenderBox.cpp:
64369        (WebCore::RenderBox::outlineBoundsForRepaint):
64370        * rendering/RenderElement.cpp:
64371        (WebCore::RenderElement::repaintAfterLayoutIfNeeded):
64372        * rendering/svg/RenderSVGModelObject.cpp:
64373        (WebCore::RenderSVGModelObject::outlineBoundsForRepaint):
64374
643752014-03-05  Krzysztof Czech  <k.czech@samsung.com>
64376
64377        [ATK] Expose missing functionalities of AtkTableCell to AT.
64378        https://bugs.webkit.org/show_bug.cgi?id=129492
64379
64380        Reviewed by Mario Sanchez Prada.
64381
64382        Implemented missing API of AtkTableCell.
64383
64384        No new tests. Covered by existing ones.
64385
64386        * accessibility/atk/WebKitAccessibleInterfaceTableCell.cpp:
64387        (webkitAccessibleTableCellGetColumnSpan):
64388        (webkitAccessibleTableCellGetRowSpan):
64389        (webkitAccessibleTableCellGetPosition):
64390        (webkitAccessibleTableCellGetTable):
64391        (webkitAccessibleTableCellInterfaceInit):
64392
643932014-03-05  Andres Gomez  <agomez@igalia.com>
64394
64395        [GStreamer] WebSource doesn't need the "iradio-mode" property
64396        https://bugs.webkit.org/show_bug.cgi?id=129685
64397
64398        Reviewed by Philippe Normand.
64399
64400        Removed the "iradio-mode" property from the WK source element
64401        since this was only available for its modification from
64402        playbin/uridecodebin and, as discussed in GStreamer bug #725383,
64403        it was not being set and now is going to be removed.
64404
64405        It is safe just to send always the "icy-metadata" header set and
64406        deal with returning "icy" headers as we were already doing.
64407
64408        * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
64409        (webKitWebSrcSetProperty):
64410        (webKitWebSrcGetProperty):
64411        (webKitWebSrcStart):
64412
644132014-03-05  Chang Shu  <cshu@webkit.org>
64414
64415        Copying wrapping text results in multiple spaces between wrapped lines stripped.
64416        https://bugs.webkit.org/show_bug.cgi?id=129609.
64417
64418        Reviewed by Ryosuke Niwa.
64419
64420        While checking the condition of restoring the missing space, the collapsed spaces
64421        may not be exactly one.
64422
64423        editing/pasteboard/copy-text-with-wrapped-tag.html is enhanced to test this case.
64424
64425        * editing/TextIterator.cpp:
64426        (WebCore::TextIterator::handleTextBox):
64427
644282014-03-05  Ryosuke Niwa  <rniwa@webkit.org>
64429
64430        appendChild shouldn't invalidate LiveNodeLists and HTMLCollections if they don't have valid caches
64431        https://bugs.webkit.org/show_bug.cgi?id=129727
64432
64433        Reviewed by Andreas Kling.
64434
64435        Before this patch, invalidateNodeListAndCollectionCachesInAncestors invalidated node lists and HTML
64436        collections on ancestors of a node whenever we're inserting or removing a child node. This patch
64437        makes HTMLCollections and LiveNodeLists register themselves with Document only when they have valid
64438        caches.
64439
64440        Each user of CollectionIndexCache now implements willValidateIndexCache member function that gets
64441        called when CollectionIndexCache caches any state and necessitates the registration with document.
64442
64443        * dom/ChildNodeList.h: Added an empty willValidateIndexCache since child node lists are never
64444        registered with document.
64445
64446        * dom/CollectionIndexCache.h:
64447        (WebCore::CollectionIndexCache::hasValidCache): Added.
64448        (WebCore::CollectionIndexCache::nodeCount): Calls willValidateIndexCache when caching node count.
64449        (WebCore::CollectionIndexCache::nodeAfterCached): Ditto. Also assert that hasValidCache() true in
64450        the cases where we're simply updating our caches or adding more caches.
64451        (WebCore::CollectionIndexCache::nodeAt): Ditto. Also added a code to set the length cache when
64452        we've reached the end of the list. This should be a slight speed up on some cases.
64453
64454        * dom/Document.cpp:
64455        (WebCore::Document::Document): Initializes a variable used by assertions.
64456        (WebCore::Document::unregisterNodeList): Added an early exit for when m_listsInvalidatedAtDocument
64457        is empty since invalidateNodeListAndCollectionCaches swaps out the list.
64458        (WebCore::Document::registerCollection): Removed the boolean hasIdNameMap since we now explicitly
64459        call collectionCachedIdNameMap in HTMLCollection.
64460        (WebCore::Document::unregisterCollection): Ditto. Exit early if m_collectionsInvalidatedAtDocument
64461        is empty since invalidateNodeListAndCollectionCaches swaps out the list.
64462        * dom/Document.h:
64463
64464        * dom/LiveNodeList.cpp:
64465        (WebCore::LiveNodeList::invalidateCache): Unregister the node list with document if we had caches.
64466        * dom/LiveNodeList.h:
64467        (WebCore::LiveNodeList::LiveNodeList):
64468        (WebCore::LiveNodeList::~LiveNodeList): Ditto.
64469        (WebCore::LiveNodeList::invalidateCache): Pass around document. This is necessary since document()
64470        had already moved to the new document inside NodeListsNodeData::invalidateCaches.
64471        (WebCore::LiveNodeList::willValidateIndexCache): Added. Registers itself with document.
64472
64473        * dom/Node.cpp:
64474        (WebCore::Document::invalidateNodeListAndCollectionCaches): Swap the lists since invalidateCache
64475        tries to unregister node lists and HTML collections with document. Since this is the only case in
64476        which node lists and HTML collections being removed may not be in the lists in unregisterNodeList
64477        and unregisterCollection, assert this condition via m_inInvalidateNodeListAndCollectionCaches.
64478        (WebCore::NodeListsNodeData::invalidateCaches):
64479
64480        * dom/NodeRareData.h:
64481        (WebCore::NodeListsNodeData::adoptDocument): Unregister node lists and HTML collections from old
64482        document via invalidateCache. We need to explicitly pass in oldDocument here since owner node's
64483        document had already been changed to newDocument at this point. Since we're invalidating caches,
64484        there is no need to register node lists and HTML collections with newDocument.
64485
64486        * html/HTMLCollection.cpp:
64487        (WebCore::HTMLCollection::HTMLCollection):
64488        (WebCore::HTMLCollection::~HTMLCollection): Unregister the node list with document if we had caches.
64489        (WebCore::HTMLCollection::invalidateCache): Ditto.
64490        (WebCore::HTMLCollection::invalidateNamedElementCache):
64491        * html/HTMLCollection.h:
64492        (WebCore::HTMLCollection::invalidateCache): Pass around document as done in LiveNodeList.
64493        (WebCore::HTMLCollection::willValidateIndexCache): Ditto.
64494
64495        * html/HTMLFormControlsCollection.cpp:
64496        (WebCore::HTMLFormControlsCollection::invalidateCache): Ditto.
64497        * html/HTMLFormControlsCollection.h:
64498
64499        * html/HTMLSelectElement.cpp:
64500        (WebCore::HTMLSelectElement::invalidateSelectedItems): Ditto.
64501        (WebCore::HTMLSelectElement::setRecalcListItems): Ditto.
64502
645032014-03-05  Jon Lee  <jonlee@apple.com>
64504
64505        Fix linker error after r165087
64506        https://bugs.webkit.org/show_bug.cgi?id=129730
64507
64508        Reviewed by Csaba Osztrogonác.
64509
64510        * WebCore.exp.in: Remove undefined symbol __ZN7WebCore32WebVideoFullscreenChangeObserverD2Ev.
64511
645122014-03-04  Zalan Bujtas  <zalan@apple.com>
64513
64514        Enable device pixel repaint rect tracking.
64515        https://bugs.webkit.org/show_bug.cgi?id=129712
64516
64517        Reviewed by Simon Fraser.
64518
64519        Tracked repaint rects are device pixel snapped now to support hiDPI test cases.
64520
64521        Test: fast/repaint/hidpi-device-pixel-based-repaint-rect-tracking.html
64522
64523        * WebCore.exp.in:
64524        * page/FrameView.cpp:
64525        (WebCore::FrameView::addTrackedRepaintRect):
64526        (WebCore::FrameView::trackedRepaintRectsAsText): Print them as LayoutUnits to get
64527        trailing zeros cut off.
64528        * page/FrameView.h:
64529        * rendering/RenderLayer.cpp:
64530        (WebCore::RenderLayer::calculateClipRects):
64531        * rendering/RenderLayer.h:
64532        * rendering/RenderLayerBacking.cpp:
64533        (WebCore::RenderLayerBacking::setContentsNeedDisplay):
64534        (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
64535        * rendering/RenderView.cpp:
64536        (WebCore::RenderView::repaintViewRectangle):
64537
645382014-03-04  Simon Fraser  <simon.fraser@apple.com>
64539
64540        Don't clamp scrolling node offsets when the offset is changed by delegated scrolling
64541        https://bugs.webkit.org/show_bug.cgi?id=129724
64542
64543        Reviewed by Sam Weinig.
64544        
64545        Call setScrollPositionWithoutContentEdgeConstraints() from
64546        ScrollingTree::scrollPositionChangedViaDelegatedScrolling() so that
64547        layers are not clamped during rubber-banding.
64548        
64549        This requires making setScrollPositionWithoutContentEdgeConstraints()
64550        a pure virtual function on the base class.
64551
64552        * page/scrolling/ScrollingTree.cpp:
64553        (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling):
64554        * page/scrolling/ScrollingTreeScrollingNode.h:
64555        * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h:
64556        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
64557
645582014-03-04  Jeremy Jones  <jeremyj@apple.com>
64559
64560        WebVideoFullscreen, should make the hand off of the video layer explicit.
64561        https://bugs.webkit.org/show_bug.cgi?id=128844
64562
64563        Reviewed by Simon Fraser.
64564
64565        This change introduces a more explicit hand-off of the video layer.
64566        This describes the interactions between WebVideoFullscreenInterface and WebVideoFullscreenModel
64567        WebVideoFullscreenModel <-> WebVideoFullscreenInterface
64568              enterFullScreen(*) ->
64569                                <- borrowVideoLayer
64570              willLendVideoLayer ->
64571               didLendVideoLayer ->
64572                                <- didEnterFullscreen
64573                                ...
64574                                <- requestExitFullscreen
64575                  exitFullscreen ->
64576                                <- returnVideoLayer
64577                                <- didExitFullscreen
64578        (*) enterFullScreen actually comes from WebVideoFullscreenControllerAVKit.
64579
64580        * WebCore.exp.in:
64581        Export new functions in WebVideoFullscreenInterfaceAVKit, WebVideoFullscreenModelMediaElement, etc.
64582
64583        * platform/ios/WebVideoFullscreenControllerAVKit.mm:
64584        Add WebVideoFullscreenControllerChangeObserver to forward fullscreen callbacks to WebVideoFullscreenController
64585
64586        (WebVideoFullscreenControllerChangeObserver::setTarget):
64587        Sets obj-c target of fullscreen change callbacks.
64588
64589        (-[WebVideoFullscreenController init]):
64590        Point _changeObserver's target at self.
64591
64592        (-[WebVideoFullscreenController dealloc]):
64593        Clear _changeObserver's target.
64594
64595        (-[WebVideoFullscreenController enterFullscreen:]):
64596        Retain self to prevent dealloc during animation or while fullscreen.
64597        Connect _interface to _changeObserver.
64598
64599        (-[WebVideoFullscreenController exitFullscreen]):
64600        Remove use of completion move cleanup to -didExitFullscreen.
64601
64602        (-[WebVideoFullscreenController didEnterFullscreen]):
64603        Nothing to see here.
64604
64605        (-[WebVideoFullscreenController didExitFullscreen]):
64606        Move clean up code that was in a completion to here.
64607
64608        * platform/ios/WebVideoFullscreenInterface.h:
64609        Add delarations for more explicit hand-off of video layer.
64610
64611        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
64612        Add WebVideoFullscreenChangeObserver to notify when fullscreen animations complete.
64613        Add declarations for more explicit hand-off of video layer.
64614        Add WebAVPlayerLayer now always wraps the m_videoLayer to prevent default behavior
64615        of AVPlayerLayer.
64616
64617        (WebCore::WebVideoFullscreenChangeObserver::~WebVideoFullscreenChangeObserver):
64618        Add empty virtual destructor.
64619
64620        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
64621        Include AVKit headers instead of declaring everything locally.
64622        AVPlayerLayer protocol renamed to AVVideoLayer per AVKit.
64623
64624        (-[WebAVPlayerController dealloc]):
64625        Don't refer to self.
64626
64627        (-[WebAVPlayerController playerViewController:shouldDismissWithReason:]):
64628        Pause before requesting exit fullscreen.
64629
64630        (-[WebAVPlayerLayer setPlayerController:]):
64631        This is required by AVVideoLayer, but we don't need it.
64632
64633        (WebVideoFullscreenInterfaceAVKit::playerController):
64634        White space.
64635
64636        (WebVideoFullscreenInterfaceAVKit::setWebVideoFullscreenChangeObserver):
64637        Set observer to forward fullscreen changes to.
64638
64639        (WebVideoFullscreenInterfaceAVKit::enterFullscreen):
64640        Use more explicit video layer hand-off.
64641
64642        (WebVideoFullscreenInterfaceAVKit::doEnterFullscreen):
64643        Move enterFullscreen logic here.
64644        AVPlayerViewController now takes the video layer at init time.
64645        Always provide a video layer wrapped in a WebAVPlayerLayer.
64646
64647        (WebVideoFullscreenInterfaceAVKit::willLendVideoLayer):
64648        Use more explicit video layer hand-off.
64649
64650        (WebVideoFullscreenInterfaceAVKit::didLendVideoLayer):
64651        Use more explicit video layer hand-off.
64652
64653        (WebVideoFullscreenInterfaceAVKit::exitFullscreen):
64654        Use more explicit video layer hand-off.
64655
64656        * platform/ios/WebVideoFullscreenModel.h:
64657        Add functions for more explicit video layer hand-off.
64658
64659        * platform/ios/WebVideoFullscreenModelMediaElement.h:
64660        Mark virtual functions as virtual.
64661        Add changes for WebVideoFullscreenModel.
64662
64663        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
64664        Use more explicit video layer hand-off.
64665
64666        (WebVideoFullscreenModelMediaElement::setMediaElement):
64667        Don't push the video layer. Wait for a request for it.
64668
64669        (WebVideoFullscreenModelMediaElement::handleEvent):
64670        Make sure m_videoFullscreenInterface is valid.
64671
64672        (WebVideoFullscreenModelMediaElement::borrowVideoLayer):
64673        Use more explicit video layer hand-off.
64674        Lend videoLayer in request to a request to borrow the videoLayer.
64675        Make sure to retain the video layer before it is removed from the layer tree.
64676
64677        (WebVideoFullscreenModelMediaElement::returnVideoLayer):
64678        Use more explicit video layer hand-off.
64679
64680        (WebVideoFullscreenModelMediaElement::requestExitFullscreen):
64681        Don't clear the mediaElement reference until completely exited from fullscreen.
64682
646832014-03-04  Simon Fraser  <simon.fraser@apple.com>
64684
64685        Get position:fixed working slightly better on iOS
64686        https://bugs.webkit.org/show_bug.cgi?id=129714
64687
64688        Reviewed by Benjamin Poulain.
64689
64690        Send the scroll position as a FloatPoint, rather than an IntPoint.
64691
64692        * WebCore.exp.in:
64693        * page/scrolling/ScrollingTree.cpp:
64694        (WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling):
64695        * page/scrolling/ScrollingTree.h:
64696
646972014-03-04  Alex Christensen  <achristensen@webkit.org>
64698
64699        Fixed Windows build without MEDIA_CONTROLS_SCRIPT enabled.
64700        https://bugs.webkit.org/show_bug.cgi?id=129701
64701
64702        Reviewed by Jer Noble.
64703
64704        * WebCore.vcxproj/WebCore.vcxproj:
64705        * DerivedSources.cpp:
64706        Moved UserAgentScriptsData.cpp to DerivedSources.cpp to only be built if MEDIA_CONTROLS_SCRIPT is enabled.
64707        * DerivedSources.make:
64708        Only generate UserAgentScripts.cpp/h when USER_AGENT_SCRIPTS is non-empty.
64709        * rendering/RenderThemeWin.cpp:
64710        Only include UserAgentScripts.h when MEDIA_CONTROLS_SCRIPT is enabled.
64711
647122014-03-04  Simon Fraser  <simon.fraser@apple.com>
64713
64714        Allow iOS DumpRenderTree crashes to show application-specific information
64715        https://bugs.webkit.org/show_bug.cgi?id=129705
64716
64717        Reviewed by David Kilzer.
64718
64719        Make the WKSI function SetCrashReportApplicationSpecificInformation available
64720        in iOS simulator builds.
64721
64722        * WebCore.exp.in:
64723        * platform/ios/WebCoreSystemInterfaceIOS.mm:
64724        * platform/mac/WebCoreSystemInterface.h:
64725
647262014-03-04  Andreas Kling  <akling@apple.com>
64727
64728        Spam static branch prediction hints on JS bindings.
64729        <https://webkit.org/b/129703>
64730
64731        Add UNLIKELY hints to all !castedThis and exec->hadException() paths
64732        in the JS bindings since they are almost always going to get skipped.
64733
64734        Reviewed by Geoff Garen.
64735
64736        * bindings/scripts/CodeGeneratorJS.pm:
64737        (GenerateImplementation):
64738        (GenerateParametersCheck):
64739        (GenerateImplementationFunctionCall):
64740        (GenerateConstructorDefinition):
64741
647422014-03-04  Adenilson Cavalcanti  <cavalcantii@gmail.com>
64743
64744        Remove unused StdDeviation from Gaussian Blur effect
64745        https://bugs.webkit.org/show_bug.cgi?id=129693
64746
64747        Reviewed by Simon Fraser.
64748
64749        No new tests, no change on behavior.
64750
64751        * platform/graphics/filters/FEGaussianBlur.cpp:
64752        * platform/graphics/filters/FEGaussianBlur.h:
64753
647542014-03-04  Andreas Kling  <akling@apple.com>
64755
64756        Add a Document::updateStyleIfNeededForNode(Node&).
64757        <https://webkit.org/b/129689>
64758
64759        Generalize the mechanism that computed style uses to avoid doing full
64760        style updates when the node we're interested in isn't actually dirty.
64761
64762        Reviewed by Antti Koivisto.
64763
64764        * css/CSSComputedStyleDeclaration.cpp:
64765        (WebCore::ComputedStyleExtractor::propertyValue):
64766        * dom/Document.cpp:
64767        (WebCore::nodeOrItsAncestorNeedsStyleRecalc):
64768        (WebCore::Document::updateStyleIfNeededForNode):
64769        * dom/Document.h:
64770        * editing/htmlediting.cpp:
64771        (WebCore::isEditablePosition):
64772        * html/HTMLInputElement.cpp:
64773        (WebCore::HTMLInputElement::defaultEventHandler):
64774
647752014-03-04  Mark Hahnenberg  <mhahnenberg@apple.com>
64776
64777        Merge API shims and JSLock
64778        https://bugs.webkit.org/show_bug.cgi?id=129650
64779
64780        Reviewed by Mark Lam.
64781
64782        No new tests.
64783
64784        JSLock is now taking on all of APIEntryShim's responsibilities since there is never a reason 
64785        to take just the JSLock. Ditto for DropAllLocks and APICallbackShim.
64786
64787        * bindings/js/DOMRequestState.h:
64788        (WebCore::DOMRequestState::Scope::Scope):
64789        * bindings/js/JSDOMPromise.h:
64790        (WebCore::DeferredWrapper::resolve):
64791        (WebCore::DeferredWrapper::reject):
64792        (WebCore::DeferredWrapper::resolve<String>):
64793        (WebCore::DeferredWrapper::resolve<bool>):
64794        (WebCore::char>>):
64795        (WebCore::DeferredWrapper::reject<String>):
64796        * bindings/js/ScriptController.cpp:
64797        (WebCore::ScriptController::evaluateInWorld):
64798        * bindings/js/SerializedScriptValue.cpp:
64799        (WebCore::SerializedScriptValue::create):
64800        (WebCore::SerializedScriptValue::deserialize):
64801
648022014-03-04  Beth Dakin  <bdakin@apple.com>
64803
64804        REGRESSION: Overlay scrollbars that have grown are sometimes askew in the track
64805        https://bugs.webkit.org/show_bug.cgi?id=129691
64806        -and corresponding-
64807        <rdar://problem/15666846>
64808
64809        Reviewed by Simon Fraser.
64810
64811        This regression started happening after we adopted the setPresentationValue 
64812        ScrollbarPainter API which allows us to update the position of the scrollbar knob 
64813        from our secondary scrolling thread. The bug occurs when the scrollbar grows while 
64814        it still thinks it is in presentation-value mode. Whenever the scrollbar grows, it 
64815        should be in non-presentation value mode.
64816
64817        If the wheel event has ended or been cancelled, we can switch out of presentation 
64818        value mode.
64819        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
64820        (WebCore::ScrollingTreeScrollingNodeMac::handleWheelEvent):
64821
64822        Sometimes we will grow the scrollbar before we have received a wheel event with 
64823        the end or cancelled phase, and so automatically switch out of presentation-value 
64824        mode whenever we start one of these animations.
64825        * platform/mac/ScrollAnimatorMac.mm:
64826        (-[WebScrollbarPainterDelegate scrollerImp:animateUIStateTransitionWithDuration:]):
64827
648282014-03-04  Zan Dobersek  <zdobersek@igalia.com>
64829
64830        Move Source/WebCore/html/track/ code to std::unique_ptr
64831        https://bugs.webkit.org/show_bug.cgi?id=129666
64832
64833        Reviewed by Eric Carlson.
64834
64835        Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/html/track/ with std::unique_ptr.
64836
64837        * html/track/AudioTrack.h:
64838        * html/track/InbandWebVTTTextTrack.cpp:
64839        (WebCore::InbandWebVTTTextTrack::parseWebVTTCueData):
64840        * html/track/InbandWebVTTTextTrack.h:
64841        * html/track/LoadableTextTrack.cpp:
64842        (WebCore::LoadableTextTrack::loadTimerFired):
64843        (WebCore::LoadableTextTrack::newCuesAvailable):
64844        (WebCore::LoadableTextTrack::cueLoadingCompleted):
64845        (WebCore::LoadableTextTrack::newRegionsAvailable):
64846        * html/track/LoadableTextTrack.h:
64847        * html/track/TextTrack.h:
64848        * html/track/TextTrackCue.h:
64849        * html/track/TextTrackRegion.h:
64850        * html/track/VTTCue.cpp:
64851        (WebCore::VTTCue::createWebVTTNodeTree):
64852        (WebCore::VTTCue::markFutureAndPastNodes):
64853        * html/track/VTTCue.h:
64854        * html/track/VideoTrack.h:
64855        * html/track/WebVTTParser.cpp:
64856        (WebCore::WebVTTParser::WebVTTParser):
64857        * html/track/WebVTTParser.h:
64858        * html/track/WebVTTTokenizer.h:
64859        * loader/TextTrackLoader.cpp:
64860        (WebCore::TextTrackLoader::processNewCueData):
64861        * loader/TextTrackLoader.h:
64862
648632014-03-04  Zalan Bujtas  <zalan@apple.com>
64864
64865        Subpixel rendering: Make border-radius painting device pixel aware.
64866        https://bugs.webkit.org/show_bug.cgi?id=129558
64867
64868        Reviewed by Simon Fraser.
64869
64870        Snap rounded rects to device pixels right before passing them to GraphicsContext.
64871
64872        * rendering/RenderBoxModelObject.cpp:
64873        (WebCore::RenderBoxModelObject::clipRoundedInnerRect):
64874        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
64875        (WebCore::RenderBoxModelObject::paintBorder):
64876        * rendering/RenderBoxModelObject.h:
64877        * rendering/RenderReplaced.cpp:
64878        (WebCore::RenderReplaced::paint):
64879        * rendering/RenderWidget.cpp:
64880        (WebCore::RenderWidget::paint):
64881
648822014-03-04  Simon Fraser  <simon.fraser@apple.com>
64883
64884        Crashes and assertions running iOS compositing tests
64885        https://bugs.webkit.org/show_bug.cgi?id=129688
64886
64887        Reviewed by Dean Jackson.
64888        
64889        When a layer is no longer composited, we need to unregister it
64890        from the scrolling coordinator, and remove it from m_scrollCoordinatedLayers.
64891
64892        Tested by compositing tests on iOS.
64893
64894        * rendering/RenderLayerCompositor.cpp:
64895        (WebCore::RenderLayerCompositor::updateBacking):
64896
648972014-03-04  Antti Koivisto  <antti@apple.com>
64898
64899        Update bindings test results after r165046.
64900
64901        * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
64902        (webkit_dom_test_obj_set_property):
64903        (webkit_dom_test_obj_set_reflected_string_attr):
64904        (webkit_dom_test_obj_set_reflected_url_attr):
64905        (webkit_dom_test_obj_set_reflected_custom_url_attr):
64906        * bindings/scripts/test/JS/JSTestObj.cpp:
64907        (WebCore::setJSTestObjReflectedStringAttr):
64908        (WebCore::setJSTestObjReflectedURLAttr):
64909        (WebCore::setJSTestObjReflectedCustomURLAttr):
64910        * bindings/scripts/test/ObjC/DOMTestObj.mm:
64911        (-[DOMTestObj setReflectedStringAttr:]):
64912        (-[DOMTestObj setReflectedURLAttr:]):
64913        (-[DOMTestObj setReflectedCustomURLAttr:]):
64914
649152014-03-04  Martin Robinson  <mrobinson@igalia.com>
64916
64917        [GTK] Simplify the GObject DOM bindings API break check into one step
64918        https://bugs.webkit.org/show_bug.cgi?id=129571
64919
64920        Reviewed by Carlos Garcia Campos.
64921
64922        * bindings/gobject/GNUmakefile.am: We no longer generate the webkitdom.symbols file in the
64923        DerivedSources directory. All the logic is handled internally in the script now.
64924        * bindings/scripts/gobject-run-api-break-test: Removed.
64925
649262014-03-04  Zalan Bujtas  <zalan@apple.com>
64927
64928        Build fix for iOS.
64929
64930        * rendering/RenderThemeIOS.mm:
64931        (WebCore::RenderThemeIOS::addRoundedBorderClip):
64932        (WebCore::RenderThemeIOS::paintFileUploadIconDecorations):
64933
649342014-03-04  Zalan Bujtas  <zalan@apple.com>
64935
64936        Subpixel rendering: Make GraphicsLayer::fillRect FloatRoundedRect based and cleanup dependencies.
64937        https://bugs.webkit.org/show_bug.cgi?id=129557
64938
64939        Reviewed by Simon Fraser.
64940
64941        This is the preparation for snapping rounded rects to device pixel position. It enables
64942        device pixel aware border-radius painting.
64943
64944        No change in functionality.
64945
64946        * platform/efl/RenderThemeEfl.cpp:
64947        (WebCore::RenderThemeEfl::paintMediaSliderThumb):
64948        * platform/graphics/FloatRoundedRect.cpp:
64949        (WebCore::FloatRoundedRect::FloatRoundedRect):
64950        (WebCore::FloatRoundedRect::isRenderable):
64951        * platform/graphics/FloatRoundedRect.h:
64952        * platform/graphics/GraphicsContext.cpp:
64953        (WebCore::GraphicsContext::clipRoundedRect):
64954        (WebCore::GraphicsContext::clipOutRoundedRect):
64955        (WebCore::GraphicsContext::fillRoundedRect):
64956        (WebCore::GraphicsContext::fillRectWithRoundedHole):
64957        * platform/graphics/GraphicsContext.h:
64958        * platform/graphics/Path.cpp:
64959        (WebCore::Path::addRoundedRect):
64960        * platform/graphics/Path.h:
64961        * platform/graphics/RoundedRect.cpp:
64962        (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting):
64963        * platform/graphics/RoundedRect.h:
64964        * platform/graphics/ShadowBlur.cpp:
64965        (WebCore::ShadowBlur::drawRectShadow):
64966        (WebCore::ShadowBlur::drawInsetShadow):
64967        (WebCore::ShadowBlur::drawRectShadowWithoutTiling):
64968        (WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
64969        (WebCore::ShadowBlur::drawInsetShadowWithTiling):
64970        (WebCore::ShadowBlur::drawRectShadowWithTiling):
64971        * platform/graphics/ShadowBlur.h:
64972        * platform/graphics/cairo/GraphicsContextCairo.cpp:
64973        (WebCore::GraphicsContext::fillRect):
64974        (WebCore::GraphicsContext::platformFillRoundedRect):
64975        (WebCore::GraphicsContext::fillRectWithRoundedHole):
64976        * platform/graphics/cg/GraphicsContextCG.cpp:
64977        (WebCore::GraphicsContext::fillRect):
64978        (WebCore::GraphicsContext::platformFillRoundedRect):
64979        (WebCore::GraphicsContext::fillRectWithRoundedHole):
64980        * platform/graphics/wince/GraphicsContextWinCE.cpp:
64981        (WebCore::GraphicsContext::fillRoundedRect):
64982        * platform/gtk/RenderThemeGtk.cpp:
64983        (WebCore::borderRadiiFromStyle):
64984        (WebCore::RenderThemeGtk::paintMediaSliderTrack):
64985        (WebCore::RenderThemeGtk::paintMediaSliderThumb):
64986        (WebCore::RenderThemeGtk::paintMediaVolumeSliderTrack):
64987        * platform/win/DragImageWin.cpp:
64988        (WebCore::createDragImageForLink):
64989        * rendering/RenderBox.cpp:
64990        (WebCore::RenderBox::paintBoxDecorations):
64991        (WebCore::RenderBox::pushContentsClip):
64992        * rendering/RenderBoxModelObject.cpp:
64993        (WebCore::RenderBoxModelObject::clipRoundedInnerRect):
64994        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
64995        (WebCore::RenderBoxModelObject::paintBorder):
64996        (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
64997        (WebCore::RenderBoxModelObject::clipBorderSideForComplexInnerPath):
64998        (WebCore::RenderBoxModelObject::paintBoxShadow):
64999        * rendering/RenderLayer.cpp:
65000        (WebCore::RenderLayer::clipToRect):
65001        * rendering/RenderThemeIOS.mm:
65002        (WebCore::RenderThemeIOS::paintRadioDecorations):
65003        (WebCore::RenderThemeIOS::paintTextFieldDecorations):
65004        (WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
65005        (WebCore::RenderThemeIOS::paintSliderTrack):
65006        (WebCore::RenderThemeIOS::paintProgressBar):
65007        (WebCore::RenderThemeIOS::paintFileUploadIconDecorations):
65008        * rendering/RenderThemeMac.mm:
65009        (WebCore::RenderThemeMac::paintMenuListButtonGradients):
65010        (WebCore::RenderThemeMac::paintSliderTrack):
65011        * rendering/RenderThemeSafari.cpp:
65012        (WebCore::RenderThemeSafari::paintMenuListButtonGradients):
65013        (WebCore::RenderThemeSafari::paintSliderTrack):
65014        * rendering/shapes/BoxShape.cpp:
65015        (WebCore::BoxShape::buildDisplayPaths):
65016        * rendering/style/BasicShapes.cpp:
65017        (WebCore::BasicShapeInset::path):
65018
650192014-03-04  Andreas Kling  <akling@apple.com>
65020
65021        Micro-optimize Strings in JS bindings.
65022        <https://webkit.org/b/129673>
65023
65024        Tweaked for new jsStringWithWeakOwner signature. This patch removes
65025        36 bytes of code from every wrapper getter that returns a DOMString.
65026
65027        Reviewed by Ryosuke Niwa.
65028
65029        * bindings/js/JSDOMBinding.h:
65030        (WebCore::jsStringWithCache):
65031
650322014-03-03  David Kilzer  <ddkilzer@apple.com>
65033
65034        SVGPropertyTearOffs should detachChildren before deleting its value.
65035        <http://webkit.org/b/129618>
65036        <rdar://problem/15661617>
65037
65038        Reviewed by Maciej Stachowiak.
65039
65040        Merged from Blink (patch by kouhei@chromium.org):
65041        https://src.chromium.org/viewvc/blink?revision=158563&view=revision
65042        http://crbug.com/296276
65043
65044        Test: svg/transforms/svg-matrix-tearoff-crash.html
65045
65046        NOTE: The test does not reproduce a crash on WebKit using
65047        JavaScriptCore.
65048
65049        * svg/properties/SVGPropertyTearOff.h:
65050        (WebCore::SVGPropertyTearOff::setValue):
65051        (WebCore::SVGPropertyTearOff::~SVGPropertyTearOff):
65052        - Call detachChildren() if m_value is a copy.  The original
65053          Blink patch did not modify the destructor code path, although
65054          that seems obvious via code inspection.
65055
650562014-03-04  Zalan Bujtas  <zalan@apple.com>
65057
65058        Subpixel rendering: Incorrect repaint rect cuts off content's right edge after move.
65059        https://bugs.webkit.org/show_bug.cgi?id=129652
65060
65061        Reviewed by Simon Fraser.
65062
65063        When repaint rect is adjusted in order to take the distance from renderer into account,
65064        the accumulated fraction value need to be added too. This is always a positive value.
65065
65066        Test: fast/borders/hidpi-border-clipping-right-after-move.html
65067
65068        * rendering/RenderLayerBacking.cpp:
65069        (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
65070
650712014-03-04  Ryuan Choi  <ryuan.choi@samsung.com>
65072
65073        Remove unused member variable of NetworkInfoController
65074        https://bugs.webkit.org/show_bug.cgi?id=129674
65075
65076        Reviewed by Gyuyoung Kim.
65077
65078        * Modules/networkinfo/NetworkInfoController.cpp:
65079        (WebCore::NetworkInfoController::NetworkInfoController):
65080        (WebCore::NetworkInfoController::create):
65081        (WebCore::provideNetworkInfoTo):
65082        * Modules/networkinfo/NetworkInfoController.h: Removed m_page which is not really used.
65083
650842014-02-07  Sergio Villar Senin  <svillar@igalia.com>
65085
65086        [CSS Grid Layout] Percentages of indefinite sizes should compute to auto
65087        https://bugs.webkit.org/show_bug.cgi?id=128173
65088
65089        Reviewed by Darin Adler.
65090
65091        We should treat percentages of indefinite sizes as auto as
65092        mandated by the spec. Otherwise we would end up calculating a
65093        percentage of -1, the value we use to represent infinite.
65094
65095        Added some test cases to the current tests.
65096
65097        * rendering/RenderGrid.cpp:
65098        (WebCore::RenderGrid::gridTrackSize):
65099        * rendering/style/GridTrackSize.h:
65100        (WebCore::GridTrackSize::isPercentage):
65101
651022014-03-04  Ryosuke Niwa  <rniwa@webkit.org>
65103
65104        Don't synchronize attributes in reflect setters when we don't need to
65105        https://bugs.webkit.org/show_bug.cgi?id=129662
65106
65107        Reviewed by Andreas Kling.
65108
65109        The vast majority of attributes don't need synchronization. Avoid calling synchronizeAttribute in setters
65110        for those content attributes generated by "Reflect" keyword in IDL.
65111
65112        * bindings/scripts/CodeGenerator.pm:
65113        (SetterExpression):
65114        * dom/Element.cpp:
65115        (WebCore::Element::setAttributeWithoutSynchronization): Added.
65116        * dom/Element.h:
65117
651182014-03-04  Andreas Kling  <akling@apple.com>
65119
65120        Remove Document::idAttributeName().
65121        <https://webkit.org/b/129663>
65122
65123        Reviewed by Ryosuke "DYEB" Niwa.
65124
65125        This abstraction is not actually used and causes unnecessary indirection
65126        in some pretty hot code paths.
65127
65128        Replace it with hard-coded HTMLNames::idAttr instead which is a compile
65129        time constant pointer. We can revisit this in the future if we wish to
65130        implement support for custom id attributes.
65131
65132        * dom/Attr.cpp:
65133        (WebCore::Attr::isId):
65134        * dom/Document.cpp:
65135        (WebCore::Document::Document):
65136        * dom/Document.h:
65137        * dom/Element.cpp:
65138        (WebCore::Element::attributeChanged):
65139        (WebCore::Element::willModifyAttribute):
65140        * dom/Element.h:
65141        (WebCore::Element::getIdAttribute):
65142        (WebCore::Element::getNameAttribute):
65143        (WebCore::Element::setIdAttribute):
65144        * html/HTMLElement.cpp:
65145        (WebCore::HTMLElement::parseAttribute):
65146        * html/HTMLFrameElementBase.cpp:
65147        (WebCore::HTMLFrameElementBase::parseAttribute):
65148        * html/HTMLMapElement.cpp:
65149        (WebCore::HTMLMapElement::parseAttribute):
65150        * svg/SVGElement.cpp:
65151        (WebCore::SVGElement::attributeChanged):
65152        (WebCore::SVGElement::isKnownAttribute):
65153        (WebCore::SVGElement::svgAttributeChanged):
65154
651552014-03-04  Ryosuke Niwa  <rniwa@webkit.org>
65156
65157        REGRESSION(r164856): Use after free in WebCore::QualifiedName::operator== / WebCore::StyledElement::attributeChanged
65158        https://bugs.webkit.org/show_bug.cgi?id=129550
65159
65160        Reviewed by Andreas Kling.
65161
65162        We can't store a reference to QualifiedName here because ensureUniqueElementData could delete QualifiedName inside Attribute.
65163
65164        Test: fast/dom/uniquing-attributes-via-setAttribute.html
65165
65166        * dom/Element.cpp:
65167        (WebCore::Element::setAttributeInternal):
65168
651692014-03-04  Hyowon Kim  <hw1008.kim@samsung.com>
65170
65171        Move EvasGLContext and EvasGLSurface files into the efl common directory.
65172        https://bugs.webkit.org/show_bug.cgi?id=129603
65173
65174        Reviewed by Gyuyoung Kim.
65175
65176        EFL port will use EvasGLContext and EvasGLSurface files in both WK1 and WK2.
65177
65178        No new tests, just refactorings.
65179
65180        * PlatformEfl.cmake:
65181        * platform/graphics/efl/EvasGLContext.cpp: Renamed from Source/WebKit2/UIProcess/API/efl/EvasGLContext.cpp.
65182        (WebKit::EvasGLContext::EvasGLContext):
65183        (WebKit::EvasGLContext::~EvasGLContext):
65184        * platform/graphics/efl/EvasGLContext.h: Renamed from Source/WebKit2/UIProcess/API/efl/EvasGLContext.h.
65185        (WebKit::EvasGLContext::create):
65186        (WebKit::EvasGLContext::context):
65187        * platform/graphics/efl/EvasGLSurface.cpp: Renamed from Source/WebKit2/UIProcess/API/efl/EvasGLSurface.cpp.
65188        (WebKit::EvasGLSurface::EvasGLSurface):
65189        (WebKit::EvasGLSurface::~EvasGLSurface):
65190        * platform/graphics/efl/EvasGLSurface.h: Renamed from Source/WebKit2/UIProcess/API/efl/EvasGLSurface.h.
65191        (WebKit::EvasGLSurface::create):
65192        (WebKit::EvasGLSurface::surface):
65193
651942014-03-03  Martin Robinson  <mrobinson@igalia.com>
65195
65196        Fix the GTK+ CMake build
65197
65198        * PlatformGTK.cmake: Add a missing file to the source list.
65199
652002014-03-03  Sanghyup Lee  <sh53.lee@samsung.com>
65201
65202        :active style is not cleared when its display property is set to none before mouse released.
65203        https://bugs.webkit.org/show_bug.cgi?id=129465
65204
65205        Reviewed by Antonio Gomes.
65206
65207        Source/WebCore:
65208
65209        We currently clearing the :active style when element has a renderer.
65210        This patch makes elements clear its active style regardless of renderer. 
65211
65212        * dom/Document.cpp:
65213        (WebCore::Document::updateHoverActiveState):
65214
65215        LayoutTests:
65216
65217        * fast/css/active-display-none-expected.txt: Added.
65218        * fast/css/active-display-none.html: Added.
65219
65220
652212014-03-03  Andreas Kling  <akling@apple.com>
65222
65223        Remove 2 unnecessary includes from JSDOMBinding.h
65224        <https://webkit.org/b/129619>
65225
65226        Reviewed by Antti Koivisto.
65227
65228        * bindings/js/JSDOMBinding.h:
65229
652302014-03-03  Myles C. Maxfield  <mmaxfield@apple.com>
65231
65232        GraphicsContext::drawLineForText needs to be exported from WebCore.dylib for iOS builds
65233        https://bugs.webkit.org/show_bug.cgi?id=129647
65234
65235        Reviewed by NOBODY (This is a build fix).
65236
65237        Fixing after r165025 and r165016.
65238
65239        No new tests as this is a build fix.
65240
65241        * WebCore.exp.in:
65242
652432014-03-03  Jer Noble  <jer.noble@apple.com>
65244
65245        [iOS] Start playback button misplaced
65246        https://bugs.webkit.org/show_bug.cgi?id=129628
65247
65248        Reviewed by Simon Fraser.
65249
65250        On YouTube embeds, while the video is loading it is placed into the DOM with a 0x0 size.
65251        This causes the start playback button to be visible in the upper-left corner of the embed
65252        area. The button wasn't visible previously (in plugin mode) because the plugin clipped its
65253        drawing to its bounds, and so the <video> shadow should do the same.
65254
65255        * Modules/mediacontrols/mediaControlsiOS.css:
65256        (::-webkit-media-controls):
65257
652582014-03-03  Enrica Casucci  <enrica@apple.com>
65259
65260        Build fix for iOS simulator.
65261
65262        * WebCore.exp.in:
65263
652642014-03-03  Jeremy Jones  <jeremyj@apple.com>
65265
65266        Forward application suspend resume notifications to the web process.
65267        https://bugs.webkit.org/show_bug.cgi?id=129356
65268
65269        Reviewed by Eric Carlson.
65270
65271        * platform/audio/ios/MediaSessionManagerIOS.mm:
65272        (-[WebMediaSessionHelper initWithCallback:]):
65273        Observe UIApplicationDidBecomeActiveNotification,
65274        WebUIApplicationDidBecomeActiveNotification,
65275        WebUIApplicationWillEnterForegroundNotification, and
65276        WebUIApplicationWillResignActiveNotification
65277        
65278        (-[WebMediaSessionHelper applicationDidBecomeActive:]):
65279        Resume session.
65280
652812014-03-03  Commit Queue  <commit-queue@webkit.org>
65282
65283        Unreviewed, rolling out r165013.
65284        http://trac.webkit.org/changeset/165013
65285        https://bugs.webkit.org/show_bug.cgi?id=129646
65286
65287        New code is not thread safe, asserting on a worker test
65288        (Requested by ap on #webkit).
65289
65290        * WebCore.exp.in:
65291        * editing/DeleteButtonController.cpp:
65292        (WebCore::DeleteButtonController::createDeletionUI):
65293        * html/DOMURL.cpp:
65294        (WebCore::DOMURL::revokeObjectURL):
65295        * inspector/InspectorPageAgent.cpp:
65296        (WebCore::InspectorPageAgent::cachedResource):
65297        * inspector/InspectorResourceAgent.cpp:
65298        (WebCore::InspectorResourceAgent::replayXHR):
65299        * loader/DocumentLoader.cpp:
65300        (WebCore::areAllLoadersPageCacheAcceptable):
65301        * loader/FrameLoader.cpp:
65302        (WebCore::FrameLoader::tellClientAboutPastMemoryCacheLoads):
65303        * loader/ImageLoader.cpp:
65304        (WebCore::ImageLoader::updateFromElement):
65305        * loader/archive/cf/LegacyWebArchive.cpp:
65306        (WebCore::LegacyWebArchive::create):
65307        * loader/cache/CachedCSSStyleSheet.cpp:
65308        (WebCore::CachedCSSStyleSheet::CachedCSSStyleSheet):
65309        * loader/cache/CachedCSSStyleSheet.h:
65310        * loader/cache/CachedFont.cpp:
65311        (WebCore::CachedFont::CachedFont):
65312        * loader/cache/CachedFont.h:
65313        * loader/cache/CachedImage.cpp:
65314        (WebCore::CachedImage::CachedImage):
65315        * loader/cache/CachedImage.h:
65316        * loader/cache/CachedRawResource.cpp:
65317        (WebCore::CachedRawResource::CachedRawResource):
65318        * loader/cache/CachedRawResource.h:
65319        * loader/cache/CachedResource.cpp:
65320        (WebCore::CachedResource::CachedResource):
65321        (WebCore::CachedResource::~CachedResource):
65322        * loader/cache/CachedResource.h:
65323        * loader/cache/CachedResourceLoader.cpp:
65324        (WebCore::createResource):
65325        (WebCore::CachedResourceLoader::requestUserCSSStyleSheet):
65326        (WebCore::CachedResourceLoader::requestResource):
65327        (WebCore::CachedResourceLoader::revalidateResource):
65328        (WebCore::CachedResourceLoader::loadResource):
65329        * loader/cache/CachedResourceLoader.h:
65330        * loader/cache/CachedSVGDocument.cpp:
65331        (WebCore::CachedSVGDocument::CachedSVGDocument):
65332        * loader/cache/CachedSVGDocument.h:
65333        * loader/cache/CachedScript.cpp:
65334        (WebCore::CachedScript::CachedScript):
65335        * loader/cache/CachedScript.h:
65336        * loader/cache/CachedTextTrack.cpp:
65337        (WebCore::CachedTextTrack::CachedTextTrack):
65338        * loader/cache/CachedTextTrack.h:
65339        * loader/cache/CachedXSLStyleSheet.cpp:
65340        (WebCore::CachedXSLStyleSheet::CachedXSLStyleSheet):
65341        * loader/cache/CachedXSLStyleSheet.h:
65342        * loader/cache/MemoryCache.cpp:
65343        (WebCore::MemoryCache::add):
65344        (WebCore::MemoryCache::revalidationSucceeded):
65345        (WebCore::MemoryCache::resourceForURL):
65346        (WebCore::MemoryCache::resourceForRequest):
65347        (WebCore::MemoryCache::addImageToCache):
65348        (WebCore::MemoryCache::removeImageFromCache):
65349        (WebCore::MemoryCache::evict):
65350        (WebCore::MemoryCache::removeResourcesWithOrigin):
65351        (WebCore::MemoryCache::getOriginsWithCache):
65352        (WebCore::MemoryCache::removeUrlFromCache):
65353        (WebCore::MemoryCache::removeRequestFromCache):
65354        (WebCore::MemoryCache::removeRequestFromCacheImpl):
65355        (WebCore::MemoryCache::crossThreadRemoveRequestFromCache):
65356        (WebCore::MemoryCache::getStatistics):
65357        (WebCore::MemoryCache::setDisabled):
65358        * loader/cache/MemoryCache.h:
65359        * platform/CrossThreadCopier.cpp:
65360        * platform/CrossThreadCopier.h:
65361        * platform/network/cf/ResourceRequest.h:
65362        (WebCore::ResourceRequest::ResourceRequest):
65363        * rendering/RenderSnapshottedPlugIn.cpp:
65364        (WebCore::RenderSnapshottedPlugIn::updateSnapshot):
65365        * testing/Internals.cpp:
65366        (WebCore::Internals::isLoadingFromMemoryCache):
65367
653682014-03-03  Sam Weinig  <sam@webkit.org>
65369
65370        Fix the iOS Simulator build.
65371
65372        * WebCore.exp.in:
65373
653742014-03-03  Myles C. Maxfield  <mmaxfield@apple.com>
65375
65376        Space between double underlines does not scale with font size
65377        https://bugs.webkit.org/show_bug.cgi?id=129521
65378
65379        Reviewed by Simon Fraser.
65380
65381        This patch moves the logic about how far to draw the second underline (when text-decoration-style: double
65382        is specified) from InlineTextBox to GraphicsContext, because GraphicsContext is the authoritative source
65383        about how thick underlines should be. The space between the two underlines is set to the thickness of
65384        each of the underlines.
65385
65386        This patch also deletes some unused code in InlineTextBox that was never getting triggered, in addition
65387        to unifying drawLineForText with drawLinesForText. This didn't have any performance impact in my testing.
65388
65389        Test: fast/css3-text/css3-text-decoration/text-decoration-style-double-space-scales.html
65390
65391        * platform/graphics/GraphicsContext.h: drawLineForText takes a boolean for if we should draw double
65392        underlines.
65393        * platform/graphics/cg/GraphicsContextCG.cpp:
65394        (WebCore::GraphicsContext::drawLineForText):
65395        (WebCore::GraphicsContext::drawLinesForText):
65396        * platform/graphics/cairo/GraphicsContextCairo.cpp:
65397        (WebCore::GraphicsContext::drawLineForText):
65398        * platform/graphics/wince/GraphicsContextWinCE.cpp:
65399        (WebCore::GraphicsContext::drawLineForText):
65400        * rendering/InlineTextBox.cpp: Use new boolean argument
65401        (WebCore::drawSkipInkUnderline):
65402        (WebCore::InlineTextBox::paintDecoration):
65403
654042014-02-28  Chris Fleizach  <cfleizach@apple.com>
65405
65406        AX: Support IOS Accessibility in WK2
65407        https://bugs.webkit.org/show_bug.cgi?id=129527
65408
65409        Reviewed by Sam Weinig.
65410
65411        Update the iOS wrapper so that it can convert points to screen space in WebKit2.
65412
65413        * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
65414        (-[WebAccessibilityObjectWrapper convertPointToScreenSpace:]):
65415        (-[WebAccessibilityObjectWrapper convertRectToScreenSpace:]):
65416
654172014-03-03  Martin Hock  <mhock@apple.com>
65418
65419        Add support for sessions to MemoryCache.
65420        https://bugs.webkit.org/show_bug.cgi?id=127794
65421
65422        Reviewed by Sam Weinig.
65423
65424        * WebCore.exp.in:
65425        * editing/DeleteButtonController.cpp:
65426        (WebCore::DeleteButtonController::createDeletionUI): Initialize CachedImage with sessionID.
65427        * html/DOMURL.cpp:
65428        (WebCore::DOMURL::revokeObjectURL): Remove URL from MemoryCache for all sessions.
65429        * inspector/InspectorPageAgent.cpp:
65430        (WebCore::InspectorPageAgent::cachedResource): Pass sessionID to MemoryCache.
65431        * inspector/InspectorResourceAgent.cpp:
65432        (WebCore::InspectorResourceAgent::replayXHR): Ditto.
65433        * loader/DocumentLoader.cpp:
65434        (WebCore::areAllLoadersPageCacheAcceptable): Ditto.
65435        * loader/FrameLoader.cpp:
65436        (WebCore::FrameLoader::tellClientAboutPastMemoryCacheLoads): Ditto.
65437        * loader/ImageLoader.cpp:
65438        (WebCore::ImageLoader::updateFromElement): Initialize CachedImage with sessionID.
65439        * loader/archive/cf/LegacyWebArchive.cpp:
65440        (WebCore::LegacyWebArchive::create): Pass sessionID to MemoryCache.
65441        * loader/cache/CachedCSSStyleSheet.cpp:
65442        (WebCore::CachedCSSStyleSheet::CachedCSSStyleSheet): Constructor takes sessionID.
65443        * loader/cache/CachedCSSStyleSheet.h:
65444        * loader/cache/CachedFont.cpp: Ditto.
65445        (WebCore::CachedFont::CachedFont):
65446        * loader/cache/CachedFont.h:
65447        * loader/cache/CachedImage.cpp: Ditto.
65448        (WebCore::CachedImage::CachedImage):
65449        * loader/cache/CachedImage.h:
65450        * loader/cache/CachedRawResource.cpp: Ditto.
65451        (WebCore::CachedRawResource::CachedRawResource):
65452        * loader/cache/CachedRawResource.h:
65453        * loader/cache/CachedResource.cpp: Ditto.
65454        (WebCore::CachedResource::CachedResource):
65455        (WebCore::CachedResource::~CachedResource): Pass sessionID to MemoryCache.
65456        * loader/cache/CachedResource.h:
65457        (WebCore::CachedResource::sessionID):
65458        * loader/cache/CachedResourceLoader.cpp:
65459        (WebCore::createResource): Constructors take sessionID.
65460        (WebCore::CachedResourceLoader::sessionID): Retrieve sessionID from page.
65461        (WebCore::CachedResourceLoader::requestUserCSSStyleSheet): Pass sessionID to MemoryCache.
65462        (WebCore::CachedResourceLoader::requestResource): Initialize CachedCSSStyleSheet with sessionID.
65463        (WebCore::CachedResourceLoader::revalidateResource): Initialize cached resource with sessionID.
65464        (WebCore::CachedResourceLoader::loadResource): Pass sessionID to MemoryCache and initialize cached resource with sessionID.
65465        * loader/cache/CachedResourceLoader.h:
65466        * loader/cache/CachedSVGDocument.cpp: Constructor takes sessionID.
65467        (WebCore::CachedSVGDocument::CachedSVGDocument):
65468        * loader/cache/CachedSVGDocument.h:
65469        * loader/cache/CachedScript.cpp: Ditto.
65470        (WebCore::CachedScript::CachedScript):
65471        * loader/cache/CachedScript.h:
65472        * loader/cache/CachedTextTrack.cpp: Ditto.
65473        (WebCore::CachedTextTrack::CachedTextTrack):
65474        * loader/cache/CachedTextTrack.h:
65475        * loader/cache/CachedXSLStyleSheet.cpp: Ditto.
65476        (WebCore::CachedXSLStyleSheet::CachedXSLStyleSheet):
65477        * loader/cache/CachedXSLStyleSheet.h:
65478        * loader/cache/MemoryCache.cpp:
65479        (WebCore::MemoryCache::getSessionMap): Retrieve CachedResourceMap based on sessionID.
65480        (WebCore::MemoryCache::add): Use sessionID from CachedResource parameter.
65481        (WebCore::MemoryCache::revalidationSucceeded): Add sessionID parameter.
65482        (WebCore::MemoryCache::resourceForURL): Ditto.
65483        (WebCore::MemoryCache::resourceForRequest): Ditto, also move impl into impl method.
65484        (WebCore::MemoryCache::resourceForRequestImpl): Add CachedResourceMap parameter.
65485        (WebCore::MemoryCache::addImageToCache): Use default sessionID.
65486        (WebCore::MemoryCache::removeImageFromCache): Ditto.
65487        (WebCore::MemoryCache::evict): Use sessionID from CachedResource parameter.
65488        (WebCore::MemoryCache::removeResourcesWithOrigin): Iterate through all CachedResourceMaps.
65489        (WebCore::MemoryCache::getOriginsWithCache): Ditto.
65490        (WebCore::MemoryCache::removeUrlFromCache): Add sessionID parameter.
65491        (WebCore::MemoryCache::removeRequestFromCache): Ditto.
65492        (WebCore::MemoryCache::removeRequestFromCacheImpl): Ditto.
65493        (WebCore::MemoryCache::removeRequestFromSessionCaches): Iterate through all CachedResourceMaps.
65494        (WebCore::MemoryCache::crossThreadRemoveRequestFromCache): Add sessionID parameter.
65495        (WebCore::MemoryCache::getStatistics): Iterate through all CachedResourceMaps.
65496        (WebCore::MemoryCache::setDisabled): Ditto.
65497        * loader/cache/MemoryCache.h: Create another level for cache.
65498        * platform/CrossThreadCopier.cpp: Allow copying SessionIDs across threads.
65499        (WebCore::SessionID>::copy):
65500        * platform/CrossThreadCopier.h:
65501        * platform/network/cf/ResourceRequest.h:
65502        (WebCore::ResourceRequest::ResourceRequest): Remove trailing whitespace.
65503        * rendering/RenderSnapshottedPlugIn.cpp:
65504        (WebCore::RenderSnapshottedPlugIn::updateSnapshot): Initialize CachedImage with sessionID.
65505        * testing/Internals.cpp:
65506        (WebCore::Internals::isLoadingFromMemoryCache): Pass sessionID to MemoryCache.
65507
655082014-03-03  Andreas Kling  <akling@apple.com>
65509
65510        Remove unused DataView code from JSDOMBinding.h
65511        <https://webkit.org/b/129616>
65512
65513        Reviewed by Antti Koivisto.
65514
65515        * bindings/js/JSDOMBinding.h:
65516
655172014-03-03  Simon Fraser  <simon.fraser@apple.com>
65518
65519        Allow overflow-scroll to be one-finger scrolled until we hook up UIScrollViews
65520        https://bugs.webkit.org/show_bug.cgi?id=129621
65521
65522        Reviewed by Benjamin Poulain.
65523
65524        Temporary change to allow overflow:scroll to be scrolled in iOS WK2.
65525
65526        * rendering/RenderLayer.cpp:
65527        (WebCore::RenderLayer::hasAcceleratedTouchScrolling):
65528
655292014-03-03  Antti Koivisto  <antti@apple.com>
65530
65531        Find results on simple lines are not marked correctly
65532        https://bugs.webkit.org/show_bug.cgi?id=129586
65533
65534        Reviewed by Andreas Kling.
65535
65536        Tests: editing/text-iterator/count-mark-lineboxes.html
65537               editing/text-iterator/count-mark-simple-lines.html
65538               
65539        TextIterator operating on simple lines failed to take the end of the range into account.
65540        This also causes performance issues on long documents as range traversals would miss the end
65541        node and end up going through the entire document.
65542
65543        * editing/TextIterator.cpp:
65544        (WebCore::TextIterator::handleTextNode):
65545        
65546            Stop when hitting the range end on simple text nodes.
65547
65548        (WebCore::SimplifiedBackwardsTextIterator::handleTextNode):
65549        
65550            Use hasRenderedText test instead of linebox-only firstTextBox.
65551
65552        * testing/Internals.cpp:
65553        (WebCore::Internals::countMatchesForText):
65554        * testing/Internals.h:
65555        * testing/Internals.idl:
65556        
65557            Add testing interface for counting and marking matches.
65558
655592014-03-03  Benjamin Poulain  <benjamin@webkit.org>
65560
65561        SelectorQuery failing RightMostWithIdMatch are compiling their selectors for each execution
65562        https://bugs.webkit.org/show_bug.cgi?id=129601
65563
65564        Reviewed by Andreas Kling.
65565
65566        This caused a regression after r164924 for documents in quirks mode. Since those always fail
65567        selectorForIdLookup(), they ended up compiling the selector every time they were called.
65568
65569        * dom/SelectorQuery.cpp:
65570        (WebCore::SelectorDataList::execute):
65571
655722014-03-01  Jer Noble  <jer.noble@apple.com>
65573
65574        [Mac] Crash in MediaPlayer::rateChanged()
65575        https://bugs.webkit.org/show_bug.cgi?id=129548
65576
65577        Reviewed by Darin Adler.
65578
65579        WTF::bind will automatically ref the parameters added to it. But MediaPlayerPrivate-
65580        AVFoundation and -MediaSOurceAVFObjC are not RefCounted, so by the time the bound
65581        function is called, the underlying objects may have been freed.
65582
65583        Replace or augment callOnMainThread arguments with lambdas and weakPtrs so that
65584        if the argument has been destroyed, its methods will not be called.
65585
65586        Make the MediaPlayerPrivateAVFoundation::Notification function type a std::function:
65587        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
65588        (WebCore::MediaPlayerPrivateAVFoundation::Notification::Notification):
65589        (WebCore::MediaPlayerPrivateAVFoundation::Notification::function):
65590
65591        Make createWeakPtr() public so that it can be called from non-class methods:
65592        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
65593        (WebCore::MediaPlayerPrivateAVFoundationObjC::createWeakPtr): 
65594        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
65595        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::createWeakPtr): 
65596
65597        Use a weakPtr to abort callOnMainThread() if the object has been destroyed:
65598        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
65599        (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]):
65600        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
65601        (WebCore::CMTimebaseEffectiveRateChangedCallback):
65602        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::play):
65603        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::pause):
65604        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekWithTolerance):
65605
656062014-02-28  Jer Noble  <jer.noble@apple.com>
65607
65608        [MSE] YouTube videos fail to play
65609        https://bugs.webkit.org/show_bug.cgi?id=129525
65610
65611        Reviewed by Darin Adler.
65612
65613        Test: media/media-source/media-source-fudge-factor.html
65614
65615        Add a very simple playability metric to SourceBuffer. Track the number of seconds buffered
65616        and use that metric to determine whether the MediaSource has buffered enough data to play
65617        through.
65618
65619        * Modules/mediasource/MediaSource.cpp:
65620        (WebCore::MediaSource::currentTime): Added simple accessor.
65621        (WebCore::MediaSource::monitorSourceBuffers): Replace the functor-based iterators with lambdas.
65622        (WebCore::MediaSource::addSourceBuffer): Drive-by fix; only add new source buffers to the
65623            activeSourceBuffers list if those buffers are actually active.
65624        * Modules/mediasource/MediaSource.h:
65625        * Modules/mediasource/SourceBuffer.cpp:
65626        (WebCore::SourceBuffer::SourceBuffer): Initialize new ivars.
65627        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Measure the number of seconds buffered.
65628        (WebCore::SourceBuffer::monitorBufferingRate): Use a simple Exponential moving average to
65629            track the buffering rate.
65630        (WebCore::SourceBuffer::hasCurrentTime): Return true if the current time is within 1/24 s
65631            of a buffered range.
65632        (WebCore::SourceBuffer::hasFutureTime): Moved from MediaSource.
65633        (WebCore::SourceBuffer::canPlayThrough): Return true if the buffering rate is > 1s per
65634            second, or if the rate is sufficient to keep up over the remaining time.
65635        * Modules/mediasource/SourceBuffer.h:
65636
656372014-03-03  Bear Travis  <betravis@adobe.com>
65638
65639        [CSS Shapes] Serialize circle positions
65640        https://bugs.webkit.org/show_bug.cgi?id=129404
65641
65642        Reviewed by Dirk Schulze.
65643
65644        Circle positions should always be present when serialized, and should
65645        only have the 2 or 4-valued form. Keywords are converted to percentages
65646        and simplified where possible. This patch adds some additional processing
65647        that converts the parsed position into the serialized format, before
65648        converting it to text. See http://dev.w3.org/csswg/css-shapes/#basic-shape-serialization.
65649
65650        Updated existing parsing tests.
65651
65652        * css/CSSBasicShapes.cpp:
65653        (WebCore::serializePositionOffset): Convert a position offset to a serialized string.
65654        The offset must be a pair, as generated by buildSerializablePositionOffset.
65655        (WebCore::buildSerializablePositionOffset): Generates a keyword + offset pair for each
65656        position offset. The keywords may later be dropped during serialization.
65657        (WebCore::CSSBasicShapeCircle::cssText): Use the new serialization methods.
65658
656592014-03-03  Lorenzo Tilve  <ltilve@igalia.com>
65660
65661        Optimize StylePropertiesSet::findPropertyIndex() to improve CSS properties performance
65662        https://bugs.webkit.org/show_bug.cgi?id=129605
65663
65664        Reviewed by Andreas Kling.
65665
65666        Merged from Blink (patch by Mikhail Pozdnyakov):
65667        https://src.chromium.org/viewvc/blink?view=revision&revision=167325
65668
65669        Avoid checking whether 'StylePropertiesSet' is mutable and accesing directly to its
65670        data members to achieve performance improvements
65671
65672        Before the optimization applied:
65673            mean: 3064.8337171934063 runs/s
65674            median: 3097.5899379343855 runs/s
65675            stdev: 66.89274074044187 runs/s
65676            min: 2891.7479324362585 runs/s
65677            max: 3113.288683440125 runs/s
65678
65679        After the optimization applied:
65680            mean: 3343.8356114138105 runs/s
65681            median: 3356.25682957446 runs/s
65682            stdev: 36.297533087489036 runs/s
65683            min: 3238.5468032264243 runs/s
65684            max: 3368.664837531425 runs/s
65685
65686        Performance gain for the average value is approx. 9.1%, in the
65687        range of the 10% - 8.2% for the min and max measured
65688        values (Linux desktop x64).
65689
65690        * css/StyleProperties.cpp:
65691        (WebCore::ImmutableStyleProperties::findPropertyIndex):
65692        (WebCore::MutableStyleProperties::findPropertyIndex):
65693        * css/StyleProperties.h:
65694        (WebCore::toMutableStyleProperties):
65695        (WebCore::toImmutableStyleProperties):
65696        (WebCore::StyleProperties::findPropertyIndex):
65697
656982014-03-03  Brian Burg  <bburg@apple.com>
65699
65700        Unreviewed build fix for Windows after r164986.
65701
65702        * WebCore.vcxproj/build-generated-files.sh: Export WebReplayScripts
65703        so that the build system knows how to find CodeGeneratorReplayInputs.py.
65704
657052014-03-03  Andrei Bucur  <abucur@adobe.com>
65706
65707        [CSS Regions] Overset computation is incorrect in some cases
65708        https://bugs.webkit.org/show_bug.cgi?id=129032
65709
65710        Reviewed by Mihnea Ovidenie.
65711
65712        This patch reworks the way overset is computed for regions and named flows.
65713
65714        1. Regions overflow no longer trigger an overset changed event. This is because
65715        the overflow of a box is contained within the region range of the box. The content
65716        edge should be considered the logical bottom position of the content inside the
65717        flow thread.
65718
65719        2. The regions events logic was moved from RenderFlowThread to RenderNamedFlowThread
65720        and from RenderRegion to RenderNamedFlowFragment (including the regionOverset property).
65721
65722        3. The overset value of the named flow is no longer stored in the named flow. It is
65723        extracted from the overset of the last region in the chain.
65724
65725        4. The regions overset is not computed every time the flow thread is laid out which
65726        should improve performance for flows with many regions. With the patch, each region
65727        computes the overset value during its layout when the flow thread is in the overflow
65728        or the final layout phase.
65729
65730        5. The overset changed event is dispatched only at the end of the layout of the named flows,
65731        after all the region overset changes have been considered. This means that the overset
65732        event can't be dispatched in the middle of the auto-height processing algorithm that
65733        requires multiple layout passes for the flow threads.
65734
65735        However, the region layout update event dispatch timing was not changed, it is dispatched
65736        every time the flow thread has a layout. This preserves the current behavior of the event.
65737
65738        Tests: The old tests were modified to take into account the change.
65739
65740        * dom/Element.cpp:
65741        (WebCore::Element::webkitRegionOverset):
65742        * dom/WebKitNamedFlow.cpp:
65743        (WebCore::WebKitNamedFlow::overset):
65744        * inspector/InspectorCSSAgent.cpp:
65745        (WebCore::InspectorCSSAgent::buildArrayForRegions):
65746        * rendering/FlowThreadController.cpp:
65747        (WebCore::FlowThreadController::updateFlowThreadsIntoMeasureContentPhase):
65748        * rendering/RenderBlock.cpp:
65749        (WebCore::RenderBlock::computeOverflow):
65750        * rendering/RenderFlowThread.cpp:
65751        (WebCore::RenderFlowThread::RenderFlowThread):
65752        (WebCore::RenderFlowThread::layout):
65753        * rendering/RenderFlowThread.h:
65754        * rendering/RenderNamedFlowFragment.cpp:
65755        (WebCore::RenderNamedFlowFragment::layoutBlock):
65756        (WebCore::RenderNamedFlowFragment::setRegionOversetState):
65757        (WebCore::RenderNamedFlowFragment::regionOversetState):
65758        (WebCore::RenderNamedFlowFragment::updateOversetState):
65759        * rendering/RenderNamedFlowFragment.h:
65760        * rendering/RenderNamedFlowThread.cpp:
65761        (WebCore::RenderNamedFlowThread::RenderNamedFlowThread):
65762        (WebCore::RenderNamedFlowThread::computeOverflow):
65763        (WebCore::RenderNamedFlowThread::layout):
65764        (WebCore::RenderNamedFlowThread::dispatchNamedFlowEvents):
65765        (WebCore::RenderNamedFlowThread::dispatchRegionLayoutUpdateEventIfNeeded):
65766        (WebCore::RenderNamedFlowThread::dispatchRegionOversetChangeEventIfNeeded):
65767        * rendering/RenderNamedFlowThread.h:
65768        There's a new field called m_flowContentBottom that tracks the content bottom of the flow thread
65769        after layout. This value is used to compute the overset value of the regions because it's not
65770        affected by relative positioning or visual overflow such as shadows.
65771        * rendering/RenderRegion.cpp:
65772        * rendering/RenderRegion.h:
65773
657742014-03-03  Tomas Popela  <tpopela@redhat.com>
65775
65776        [GTK] CodeGeneratorGObject.pm remove usage of undefined variable
65777        https://bugs.webkit.org/show_bug.cgi?id=129602
65778
65779        Reviewed by Martin Robinson.
65780
65781        Remove usage of undefined variable hdrPropIncludes in CodeGeneratorGObject.pm
65782
65783        * bindings/scripts/CodeGeneratorGObject.pm:
65784        (WriteData):
65785
657862014-03-03  Brian Burg  <bburg@apple.com>
65787
65788        Web Replay: upstream input storage, capture/replay machinery, and inspector domain
65789        https://bugs.webkit.org/show_bug.cgi?id=128782
65790
65791        Reviewed by Timothy Hatcher, Joseph Pecoraro, and Andreas Kling.
65792
65793        No new tests yet, as they rely on infrastructure tracked in https://webkit.org/b/129190.
65794
65795        Replayable executions are organized into ReplaySessions, which can
65796        contain several ReplaySessionSegments that divide overall execution
65797        at main frame navigation boundaries. NondeterministicInput subclasses
65798        are stored in SegmentedInputStorage according to the input's InputQueue.
65799
65800        Capture and playback are controlled at the page granularity by the Page's
65801        ReplayController. The controller knows how to create new segments, replay to
65802        arbitrary positions in the ReplaySession, and track the active InputCursor.
65803
65804        The capturing and replaying input cursor subclasses encapsulate state for
65805        storing new inputs and loading/dispatching saved inputs, respectively.
65806
65807        The ReplayAgent and associated inspector protocol domain is the friendly
65808        public API for programmatically capturing and replaying sessions.
65809
65810        * DerivedSources.make: Add replay inputs code generation target. Add the
65811        replay domain specification to the list of inspector domains.
65812
65813        * ForwardingHeaders/replay/EncodedValue.h: Added.
65814        * WebCore.xcodeproj/project.pbxproj: Add many files, and export
65815        `WebReplayScripts` environment variable to DerivedSources.make.
65816
65817        * inspector/InspectorController.cpp: Add the replay agent.
65818        (WebCore::InspectorController::InspectorController):
65819
65820        * inspector/InspectorInstrumentation.cpp:
65821        Add events for segment lifecycle events, and loading/unloading of sessions
65822        and segments, and capture/replay progress events. The replay controller
65823        also needs to know about detached and committed frames.
65824
65825        (WebCore::InspectorInstrumentation::frameDetachedFromParentImpl):
65826        (WebCore::InspectorInstrumentation::didCommitLoadImpl):
65827        (WebCore::InspectorInstrumentation::sessionCreatedImpl):
65828        (WebCore::InspectorInstrumentation::sessionLoadedImpl):
65829        (WebCore::InspectorInstrumentation::sessionModifiedImpl):
65830        (WebCore::InspectorInstrumentation::segmentCreatedImpl):
65831        (WebCore::InspectorInstrumentation::segmentCompletedImpl):
65832        (WebCore::InspectorInstrumentation::segmentLoadedImpl):
65833        (WebCore::InspectorInstrumentation::segmentUnloadedImpl):
65834        (WebCore::InspectorInstrumentation::captureStartedImpl):
65835        (WebCore::InspectorInstrumentation::captureStoppedImpl):
65836        (WebCore::InspectorInstrumentation::playbackStartedImpl):
65837        (WebCore::InspectorInstrumentation::playbackPausedImpl):
65838        (WebCore::InspectorInstrumentation::playbackHitPositionImpl):
65839        (WebCore::InspectorInstrumentation::replayAgentEnabled):
65840        * inspector/InspectorInstrumentation.h:
65841        (WebCore::InspectorInstrumentation::replayAgentEnabled):
65842        (WebCore::InspectorInstrumentation::sessionCreated):
65843        (WebCore::InspectorInstrumentation::sessionLoaded):
65844        (WebCore::InspectorInstrumentation::sessionModified):
65845        (WebCore::InspectorInstrumentation::segmentCreated):
65846        (WebCore::InspectorInstrumentation::segmentCompleted):
65847        (WebCore::InspectorInstrumentation::segmentLoaded):
65848        (WebCore::InspectorInstrumentation::segmentUnloaded):
65849        (WebCore::InspectorInstrumentation::captureStarted):
65850        (WebCore::InspectorInstrumentation::captureStopped):
65851        (WebCore::InspectorInstrumentation::playbackStarted):
65852        (WebCore::InspectorInstrumentation::playbackPaused):
65853        (WebCore::InspectorInstrumentation::playbackHitPosition):
65854
65855        * inspector/InspectorReplayAgent.cpp: Added.
65856        (WebCore::buildInspectorObjectForPosition):
65857        (WebCore::buildInspectorObjectForInput):
65858        (WebCore::buildInspectorObjectForSession):
65859        (WebCore::SerializeInputToJSONFunctor::SerializeInputToJSONFunctor):
65860        (WebCore::SerializeInputToJSONFunctor::~SerializeInputToJSONFunctor):
65861        (WebCore::SerializeInputToJSONFunctor::operator()):
65862        (WebCore::SerializeInputToJSONFunctor::returnValue):
65863        (WebCore::buildInspectorObjectForSegment):
65864        (WebCore::InspectorReplayAgent::InspectorReplayAgent):
65865        (WebCore::InspectorReplayAgent::~InspectorReplayAgent):
65866        (WebCore::InspectorReplayAgent::sessionState):
65867        (WebCore::InspectorReplayAgent::didCreateFrontendAndBackend):
65868        (WebCore::InspectorReplayAgent::willDestroyFrontendAndBackend):
65869        (WebCore::InspectorReplayAgent::frameNavigated):
65870        (WebCore::InspectorReplayAgent::frameDetached):
65871        (WebCore::InspectorReplayAgent::sessionCreated):
65872        (WebCore::InspectorReplayAgent::sessionModified):
65873        (WebCore::InspectorReplayAgent::sessionLoaded):
65874        (WebCore::InspectorReplayAgent::segmentCreated):
65875        (WebCore::InspectorReplayAgent::segmentCompleted):
65876        (WebCore::InspectorReplayAgent::segmentLoaded):
65877        (WebCore::InspectorReplayAgent::segmentUnloaded):
65878        (WebCore::InspectorReplayAgent::captureStarted):
65879        (WebCore::InspectorReplayAgent::captureStopped):
65880        (WebCore::InspectorReplayAgent::playbackStarted):
65881        (WebCore::InspectorReplayAgent::playbackPaused):
65882        (WebCore::InspectorReplayAgent::playbackHitPosition):
65883        (WebCore::InspectorReplayAgent::startCapturing):
65884        (WebCore::InspectorReplayAgent::stopCapturing):
65885        (WebCore::InspectorReplayAgent::replayToPosition):
65886        (WebCore::InspectorReplayAgent::replayToCompletion):
65887        (WebCore::InspectorReplayAgent::pausePlayback):
65888        (WebCore::InspectorReplayAgent::cancelPlayback):
65889        (WebCore::InspectorReplayAgent::switchSession):
65890        (WebCore::InspectorReplayAgent::insertSessionSegment):
65891        (WebCore::InspectorReplayAgent::removeSessionSegment):
65892        Provide a public API for modifying sessions. This is the backend support
65893        for user editing of replay sessions to add/remove specific segments.
65894
65895        (WebCore::InspectorReplayAgent::findSession):
65896        (WebCore::InspectorReplayAgent::findSegment):
65897        (WebCore::InspectorReplayAgent::getAvailableSessions):
65898        (WebCore::InspectorReplayAgent::getSerializedSession):
65899        (WebCore::InspectorReplayAgent::getSerializedSegment):
65900        Most of the replay protocol domain speaks in terms of sesssion and
65901        segment identifiers. These functions return the actual data associated
65902        with these identifiers.
65903
65904        * inspector/InspectorReplayAgent.h: Added.
65905        * inspector/InstrumentingAgents.cpp:
65906        (WebCore::InstrumentingAgents::InstrumentingAgents):
65907        (WebCore::InstrumentingAgents::reset):
65908        * inspector/InstrumentingAgents.h:
65909        (WebCore::InstrumentingAgents::inspectorReplayAgent): Added.
65910        (WebCore::InstrumentingAgents::setInspectorReplayAgent): Added.
65911        * inspector/protocol/Replay.json: Added.
65912
65913        * page/Page.cpp:
65914        (WebCore::Page::Page):
65915        * page/Page.h:
65916        (WebCore::Page::replayController): Added.
65917        * platform/Logging.h: Add WebReplay logging channel.
65918        * replay/AllReplayInputs.h: Added. Simplifies importing all input definitions.
65919
65920        * replay/CapturingInputCursor.cpp: Added.
65921        (WebCore::CapturingInputCursor::CapturingInputCursor):
65922        (WebCore::CapturingInputCursor::~CapturingInputCursor):
65923        (WebCore::CapturingInputCursor::create):
65924        (WebCore::CapturingInputCursor::storeInput):
65925        (WebCore::CapturingInputCursor::loadInput):
65926        (WebCore::CapturingInputCursor::uncheckedLoadInput):
65927        * replay/CapturingInputCursor.h: Added.
65928
65929        * replay/EventLoopInput.h:
65930        (WebCore::EventLoopInputBase::EventLoopInputBase):
65931        (WebCore::EventLoopInputBase::timestamp):
65932        (WebCore::EventLoopInputBase::setTimestamp): Support deserialization.
65933
65934        * replay/EventLoopInputDispatcher.cpp: Added. This class encapsulates the timers
65935        and measurements used to dispatch event loop inputs during replay.
65936
65937        (WebCore::EventLoopInputDispatcher::EventLoopInputDispatcher):
65938        (WebCore::EventLoopInputDispatcher::run):
65939        (WebCore::EventLoopInputDispatcher::pause):
65940        (WebCore::EventLoopInputDispatcher::timerFired):
65941        (WebCore::EventLoopInputDispatcher::dispatchInputSoon):
65942        (WebCore::EventLoopInputDispatcher::dispatchInput):
65943        * replay/EventLoopInputDispatcher.h: Added.
65944        (WebCore::EventLoopInputDispatcherClient::EventLoopInputDispatcherClient):
65945        (WebCore::EventLoopInputDispatcherClient::~EventLoopInputDispatcherClient):
65946
65947        * replay/FunctorInputCursor.h: Added.
65948        (WebCore::FunctorInputCursor::~FunctorInputCursor):
65949        (WebCore::FunctorInputCursor::forEachInputInQueue):
65950        (WebCore::FunctorInputCursor::FunctorInputCursor):
65951        (WebCore::FunctorInputCursor::storeInput):
65952        (WebCore::FunctorInputCursor::loadInput):
65953        (WebCore::FunctorInputCursor::uncheckedLoadInput):
65954
65955        * replay/ReplayController.cpp: Added.
65956        (WebCore::ReplayController::ReplayController):
65957        (WebCore::ReplayController::switchSession):
65958        (WebCore::ReplayController::createSegment):
65959        (WebCore::ReplayController::completeSegment):
65960        (WebCore::ReplayController::loadSegment):
65961        (WebCore::ReplayController::unloadSegment):
65962        (WebCore::ReplayController::startCapturing):
65963        (WebCore::ReplayController::stopCapturing):
65964        (WebCore::ReplayController::startPlayback):
65965        (WebCore::ReplayController::pausePlayback):
65966        (WebCore::ReplayController::cancelPlayback):
65967        (WebCore::ReplayController::replayToPosition):
65968        (WebCore::ReplayController::frameDetached):
65969        (WebCore::ReplayController::frameNavigated):
65970        (WebCore::ReplayController::loadedSession):
65971        (WebCore::ReplayController::loadedSegment):
65972        (WebCore::ReplayController::activeInputCursor):
65973        (WebCore::ReplayController::dispatcher):
65974        (WebCore::ReplayController::willDispatchInput):
65975        (WebCore::ReplayController::didDispatchInput):
65976        (WebCore::ReplayController::didDispatchFinalInput):
65977        * replay/ReplayController.h: Added.
65978        (WebCore::ReplayPosition::ReplayPosition):
65979        (WebCore::ReplayPosition::operator<):
65980        (WebCore::ReplayPosition::operator==):
65981
65982        * replay/ReplayInputCreationMethods.cpp: Added.
65983        Static factory implementations for inputs belong here.
65984        (WebCore::InitialNavigation::createFromPage):
65985
65986        * replay/ReplayInputDispatchMethods.cpp: Added.
65987        All dispatch() implementations for generated replay inputs belong here.
65988        (WebCore::BeginSegmentSentinel::dispatch):
65989        (WebCore::EndSegmentSentinel::dispatch):
65990        (WebCore::InitialNavigation::dispatch):
65991
65992        * replay/ReplayInputTypes.cpp:
65993        (WebCore::ReplayInputTypes::ReplayInputTypes):
65994        * replay/ReplayInputTypes.h: Define strings for WebCore inputs.
65995
65996        * replay/ReplaySession.cpp: Added.
65997        (WebCore::ReplaySession::create):
65998        (WebCore::ReplaySession::ReplaySession):
65999        (WebCore::ReplaySession::~ReplaySession):
66000        (WebCore::ReplaySession::appendSegment):
66001        (WebCore::ReplaySession::insertSegment):
66002        (WebCore::ReplaySession::removeSegment):
66003        * replay/ReplaySession.h: Added.
66004        (WebCore::ReplaySession::identifier):
66005        (WebCore::ReplaySession::timestamp):
66006        (WebCore::ReplaySession::size):
66007        (WebCore::ReplaySession::at):
66008        (WebCore::ReplaySession::begin):
66009        (WebCore::ReplaySession::end):
66010
66011        * replay/ReplaySessionSegment.cpp: Added.
66012        (WebCore::ReplaySessionSegment::create):
66013        (WebCore::ReplaySessionSegment::ReplaySessionSegment):
66014        (WebCore::ReplaySessionSegment::~ReplaySessionSegment):
66015        (WebCore::ReplaySessionSegment::createCapturingCursor):
66016        (WebCore::ReplaySessionSegment::createReplayingCursor):
66017        (WebCore::ReplaySessionSegment::createFunctorCursor):
66018        * replay/ReplaySessionSegment.h: Added.
66019        (WebCore::ReplaySessionSegment::identifier):
66020        (WebCore::ReplaySessionSegment::timestamp):
66021
66022        * replay/ReplayingInputCursor.cpp: Added.
66023        (WebCore::ReplayingInputCursor::ReplayingInputCursor):
66024        (WebCore::ReplayingInputCursor::~ReplayingInputCursor):
66025        (WebCore::ReplayingInputCursor::create):
66026        (WebCore::ReplayingInputCursor::storeInput):
66027        (WebCore::ReplayingInputCursor::loadInput):
66028        (WebCore::ReplayingInputCursor::uncheckedLoadInput):
66029        * replay/ReplayingInputCursor.h: Added.
66030
66031        * replay/SegmentedInputStorage.cpp: Added.
66032        (WebCore::queueTypeToLogPrefix):
66033        (WebCore::jsonStringForInput):
66034        (WebCore::offsetForInputQueue):
66035        (WebCore::SegmentedInputStorage::SegmentedInputStorage):
66036        (WebCore::SegmentedInputStorage::~SegmentedInputStorage):
66037        (WebCore::SegmentedInputStorage::load):
66038        (WebCore::SegmentedInputStorage::store):
66039        (WebCore::SegmentedInputStorage::queueSize):
66040        * replay/SegmentedInputStorage.h: Added.
66041
66042        * replay/SerializationMethods.cpp: Added.
66043        Specializations of EncodingTraits for WebCore types belong here.
66044
66045        (JSC::EncodingTraits<NondeterministicInputBase>::encodeValue):
66046        (JSC::EncodingTraits<NondeterministicInputBase>::decodeValue):
66047        (JSC::EncodingTraits<SecurityOrigin>::encodeValue):
66048        (JSC::EncodingTraits<SecurityOrigin>::decodeValue):
66049        (JSC::EncodingTraits<URL>::encodeValue):
66050        (JSC::EncodingTraits<URL>::decodeValue):
66051        * replay/SerializationMethods.h: Added.
66052        * replay/WebInputs.json: Added.
66053        In this inital patch, we define BeginSegmentSentinel,
66054        EndSegmentSentinel, and InitialNavigation inputs.
66055
660562014-03-03  Antoine Quint  <graouts@webkit.org>
66057
66058        Respect SVG fragment identifiers in <img> src attribute
66059        https://bugs.webkit.org/show_bug.cgi?id=129387
66060
66061        Reviewed by Dirk Schulze.
66062
66063        Following Dirk Schulze's suggestion, we set the URL on the SVGImage itself and handle the URL's
66064        fragment identifier at draw time in the SVGImage itself, which will provide a sounder base for
66065        handling of fragment identifier in SVG resource URLs in CSS properties, and should also deal
66066        with the crasher reported in http://webkit.org/b/129498 since there is a guaranteed Frame at the
66067        time we call SVGImage::draw().
66068
66069        * svg/graphics/SVGImage.cpp:
66070        (WebCore::SVGImage::draw):
66071        * svg/graphics/SVGImage.h:
66072        * svg/graphics/SVGImageForContainer.cpp:
66073        * svg/graphics/SVGImageForContainer.h:
66074
660752014-03-03  Laszlo Vidacs  <lvidacs.u-szeged@partner.samsung.com>
66076
66077        Move function calls outside loop in dom
66078        https://bugs.webkit.org/show_bug.cgi?id=126525
66079
66080        Reviewed by Csaba Osztrogonác.
66081
66082        Store the result of length() in a local variable and use it in each iteration.
66083
66084        * dom/DOMImplementation.cpp:
66085        (WebCore::DOMImplementation::isXMLMIMEType):
66086        * dom/ElementData.cpp:
66087        (WebCore::UniqueElementData::UniqueElementData):
66088        * dom/EventContext.cpp:
66089        (WebCore::TouchEventContext::checkReachability):
66090
660912014-03-03  Tomas Popela  <tpopela@redhat.com>
66092
66093        [GTK] webkit_dom_range_compare_boundary_points fails when 0 is passed as how parameter
66094        https://bugs.webkit.org/show_bug.cgi?id=129145
66095
66096        Reviewed by Carlos Garcia Campos.
66097
66098        While generating GObject DOM API the generator should skip non pointer
66099        types while generating the g_return_val_if_fail macro.
66100        This will avoid the situation when Range.START_TO_START is defined as 0,
66101        thus the webkit_dom_range_compare_boundary_points function will fail
66102        everytime it is called with 0 as how value.
66103
66104        * bindings/scripts/CodeGeneratorGObject.pm:
66105        (GenerateFunction):
66106
661072014-03-03  Jozsef Berta  <jberta.u-szeged@partner.samsung.com>
66108
66109        [cmake] *Names.cpp file should be regenerated after touching StaticString.pm
66110        https://bugs.webkit.org/show_bug.cgi?id=129031
66111
66112        Reviewed by Csaba Osztrogonác.
66113
66114        * CMakeLists.txt: Added make_names.pl dependencies: bindings/scripts/Hasher.pm and bindings/scripts/StaticString.pm
66115
661162014-03-03  Xabier Rodriguez Calvar  <calvaris@igalia.com>
66117
66118        [GTK] Multimedia controls captions icon needs its own metaphor
66119        https://bugs.webkit.org/show_bug.cgi?id=129091
66120
66121        Reviewed by Martin Robinson.
66122
66123        As we got the new icon created, we used it with a fallback to the
66124        old icon to keep run-time compatibility.
66125
66126        No new tests, current ones suffice.
66127
66128        * platform/gtk/RenderThemeGtk.cpp:
66129        (WebCore::RenderThemeGtk::paintMediaToggleClosedCaptionsButton):
66130        Replicated RenderThemeGtk::paintMediaButton to check for the
66131        necessary icon first and do the fallback to the old and stock
66132        icons.
66133        * platform/gtk/RenderThemeGtk2.cpp:
66134        (WebCore::getStockIconForWidgetType): Added ASSERT for non-empty
66135        icon name.
66136        (WebCore::getStockSymbolicIconForWidgetType): Check for non empty
66137        icon name before calling getStockIconForWidgetType. Fixed coding
66138        style.
66139        * platform/gtk/RenderThemeGtk3.cpp:
66140        (WebCore::getStockIconForWidgetType): Added ASSERT for non-empty
66141        icon name.
66142        (WebCore::getStockSymbolicIconForWidgetType): Check for non empty
66143        icon name before calling getStockIconForWidgetType. Fixed coding
66144        style.
66145
661462014-03-02  Benjamin Poulain  <benjamin@webkit.org>
66147
66148        Add a fallback path for compiling the remaining attribute checkers
66149        https://bugs.webkit.org/show_bug.cgi?id=129580
66150
66151        Reviewed by Darin Adler.
66152
66153        The remaining attribute checkers appear to be less common than the simple value match.
66154        This patch adds them to SelectorCompiler for completeness but no attempt is made at optimizing them,
66155        they all default to function calls.
66156
66157        If the assumption that those selectors are not common turn out to be incorrect, we should see
66158        the function calls in profiles and optimize them as needed.
66159
66160        * css/SelectorChecker.cpp:
66161        (WebCore::attributeValueMatches):
66162        If we get anything but attribute match here, something has gone horribly wrong. Update the code
66163        to fail if that were to happen.
66164
66165        * cssjit/SelectorCompiler.cpp:
66166        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
66167        Add the missing match type to the selector fragment.
66168
66169        Begin, End, Contain cannot match an empty value per specification. We can test that at compile time
66170        and fail immediately. See http://www.w3.org/TR/css3-selectors/#attribute-substrings
66171
66172        List has the extra requirement that a value containing a space does not match anything. It also cannot
66173        match with an empty string. See http://www.w3.org/TR/css3-selectors/#attribute-representation
66174
66175        (WebCore::SelectorCompiler::attributeValueBeginsWith):
66176        (WebCore::SelectorCompiler::attributeValueContains):
66177        (WebCore::SelectorCompiler::attributeValueEndsWith):
66178        (WebCore::SelectorCompiler::attributeValueMatchHyphenRule):
66179        (WebCore::SelectorCompiler::attributeValueSpaceSeparetedListContains):
66180        The slow fallbacks.
66181
66182        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueMatching):
66183        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeFunctionCallValueMatching):
66184        A generic code generator making function call to match an attribute value.
66185
661862014-02-25  Andreas Kling  <akling@apple.com>
66187
66188        JSDOMWindow::commonVM() should return a reference.
66189        <https://webkit.org/b/129293>
66190
66191        Since this function always returns a VM and never null, make it
66192        return a reference instead. There are more VM getters that never
66193        return null, but I tried to keep the patch from snowballing.
66194
66195        Reviewed by Geoff Garen.
66196
661972014-03-02  Timothy Hatcher  <timothy@apple.com>
66198
66199        Remove ASSERT in ~IDBRequest since it is firing during legitimate uses in Web Inspector.
66200
66201        Adding the ASSERT back is tracked by https://webkit.org/b/129593.
66202
66203        https://bugs.webkit.org/show_bug.cgi?id=129328
66204
66205        Reviewed by Sam Weinig.
66206
66207        * Modules/indexeddb/IDBRequest.cpp:
66208        (WebCore::IDBRequest::~IDBRequest):
66209
662102014-03-02  Commit Queue  <commit-queue@webkit.org>
66211
66212        Unreviewed, rolling out r164961.
66213        http://trac.webkit.org/changeset/164961
66214        https://bugs.webkit.org/show_bug.cgi?id=129596
66215
66216        Caused many assertion failures (Requested by ap on #webkit).
66217
66218        * css/SelectorChecker.cpp:
66219        (WebCore::attributeValueMatches):
66220        * cssjit/SelectorCompiler.cpp:
66221        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
66222        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueMatching):
66223
662242014-03-02  Darin Adler  <darin@apple.com>
66225
66226        Streamline use of TextIterator, cutting down includes and use of soon-to-be-deleted functions
66227        https://bugs.webkit.org/show_bug.cgi?id=129592
66228
66229        Reviewed by Sam Weinig.
66230
66231        * WebCore.exp.in: Re-sorted this file. Not sure how it got unsorted.
66232
66233        * accessibility/AccessibilityObject.cpp:
66234        (WebCore::AccessibilityObject::stringForVisiblePositionRange): Call TextIterator::text
66235        instead of TextIterator::length. Also removed unneeded special case for empty string
66236        and exception code.
66237        (WebCore::AccessibilityObject::lengthForVisiblePositionRange): Ditto.
66238
66239        * accessibility/AccessibilityObject.h: Include TextIteratorBehavior.h instead of
66240        TextIterator.h.
66241
66242        * accessibility/AccessibilityRenderObject.cpp: Include TextIterator.h.
66243
66244        * accessibility/mac/WebAccessibilityObjectWrapperBase.mm: Removed unneeded
66245        TextIterator.h include.
66246
66247        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
66248        (-[WebAccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:]): Call
66249        TextIterator::text instead of TextIterator::length.
66250
66251        * dom/Element.cpp: Include TextIterator.h.
66252
66253        * dom/Node.cpp: Include Range.h.
66254
66255        * dom/Position.cpp:
66256        (WebCore::Position::isCandidate): Cast to RenderBlockFlow since that's what the
66257        type check above does. Use a return statement instead of an else for better flow.
66258        (WebCore::Position::leadingWhitespacePosition): Call
66259        deprecatedIsCollapsibleWhitespace by its new name (newly deprecated).
66260        (WebCore::Position::trailingWhitespacePosition): Ditto.
66261
66262        * dom/Range.cpp:
66263        (WebCore::Range::firstNode): Added a FIXME about code that clearly does not
66264        belong. This is something we really need to fix.
66265
66266        * editing/AlternativeTextController.cpp: Include TextIterator.h.
66267        * editing/ApplyStyleCommand.cpp: Ditto.
66268
66269        * editing/CompositeEditCommand.cpp:
66270        (WebCore::CompositeEditCommand::prepareWhitespaceAtPositionForSplit): Call
66271        deprecatedIsCollapsibleWhitespace by its new name (newly deprecated).
66272
66273        * editing/Editor.h: Include TextIteratorBehavior.h instead of TextIterator.h.
66274
66275        * editing/HTMLInterchange.cpp:
66276        (WebCore::convertHTMLTextToInterchangeFormat): Call
66277        deprecatedIsCollapsibleWhitespace by its new name (newly deprecated).
66278
66279        * editing/SpellingCorrectionCommand.cpp: Include TextIterator.h.
66280
66281        * editing/TextIterator.h: Moved isCollapsibleWhitespace from here into
66282        htmlediting.h and renamed it deprecatedIsCollapsibleWhitespace.
66283
66284        * editing/TextIterator.cpp: Call
66285        deprecatedIsCollapsibleWhitespace by its new name (newly deprecated).
66286
66287        * editing/TypingCommand.cpp: Include TextIterator.h.
66288
66289        * editing/VisibleUnits.cpp:
66290        (WebCore::previousBoundary): Call TextIterator::text instead of
66291        TextIterator::length.
66292        (WebCore::nextBoundary): Ditto.
66293
66294        * editing/htmlediting.cpp: Include TextIterator.h.
66295
66296        * editing/htmlediting.h: Removed non-helpful section comments.
66297        Added FIXME about isWhitespace. Added deprecatedIsCollapsibleWhitespace,
66298        formerly not deprecated and in TextIterator.h.
66299
66300        * editing/markup.cpp: Include TextIterator.h.
66301
66302        * html/HTMLTextAreaElement.cpp: Include TextIterator.h.
66303
66304        * page/ContextMenuController.cpp:
66305        (WebCore::selectionContainsPossibleWord): Call TextIterator::text
66306        instead of TextIterator::length and TextIterator::characterAt.
66307
66308        * page/EventHandler.cpp: Sorted conditional includes alphabetically by condition.
66309
66310        * platform/mac/HTMLConverter.mm:
66311        (+[WebHTMLConverter editingAttributedStringFromRange:]): Call TextIterator::text
66312        instead of TextIterator::length.
66313
663142014-03-02  Benjamin Poulain  <benjamin@webkit.org>
66315
66316        Add a fallback path for compiling the remaining attribute checkers
66317        https://bugs.webkit.org/show_bug.cgi?id=129580
66318
66319        Reviewed by Darin Adler.
66320
66321        The remaining attribute checkers appear to be less common than the simple value match.
66322        This patch adds them to SelectorCompiler for completeness but no attempt is made at optimizing them,
66323        they all default to function calls.
66324
66325        If the assumption that those selectors are not common turn out to be incorrect, we should see
66326        the function calls in profiles and optimize them as needed.
66327
66328        * css/SelectorChecker.cpp:
66329        (WebCore::attributeValueMatches):
66330        If we get anything but attribute match here, something has gone horribly wrong. Update the code
66331        to fail if that were to happen.
66332
66333        * cssjit/SelectorCompiler.cpp:
66334        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
66335        Add the missing match type to the selector fragment.
66336
66337        Begin, End, Contain cannot match an empty value per specification. We can test that at compile time
66338        and fail immediately. See http://www.w3.org/TR/css3-selectors/#attribute-substrings
66339
66340        List has the extra requirement that a value containing a space does not match anything. It also cannot
66341        match with an empty string. See http://www.w3.org/TR/css3-selectors/#attribute-representation
66342
66343        (WebCore::SelectorCompiler::attributeValueBeginsWith):
66344        (WebCore::SelectorCompiler::attributeValueContains):
66345        (WebCore::SelectorCompiler::attributeValueEndsWith):
66346        (WebCore::SelectorCompiler::attributeValueMatchHyphenRule):
66347        (WebCore::SelectorCompiler::attributeValueSpaceSeparetedListContains):
66348        The slow fallbacks.
66349
66350        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueMatching):
66351        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeFunctionCallValueMatching):
66352        A generic code generator making function call to match an attribute value.
66353
663542014-03-02  Darin Adler  <darin@apple.com>
66355
66356        Fix build for case-sensitive file systems.
66357
66358        * platform/UserActivity.h: Runloop -> RunLoop.
66359
663602014-03-02  Gavin Barraclough  <barraclough@apple.com>
66361
66362        HysteresisTimer should use WebCore::Timer
66363        https://bugs.webkit.org/show_bug.cgi?id=129587
66364
66365        Reviewed by Sam Weinig.
66366
66367        * platform/HysteresisActivity.h:
66368        (WebCore::HysteresisActivity::HysteresisActivity):
66369        (WebCore::HysteresisActivity::hysteresisTimerFired):
66370            - RunLoop::Timer -> WebCore::Timer.
66371        * platform/UserActivity.h:
66372
663732014-03-02  Darin Adler  <darin@apple.com>
66374
66375        Split TextIteratorBehavior into a separate header
66376        https://bugs.webkit.org/show_bug.cgi?id=129578
66377
66378        Reviewed by Sam Weinig.
66379
66380        This is in preparation to greatly cut down on includes of TextIterator.h.
66381
66382        * GNUmakefile.list.am: Added new header.
66383        * WebCore.vcxproj/WebCore.vcxproj: Ditto.
66384        * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
66385        * WebCore.xcodeproj/project.pbxproj: Ditto.
66386
66387         * editing/FindOptions.h: Changed typedef to unsigned char;
66388        there is no reason to store these in a 32-bit integer.
66389
66390         * editing/TextIterator.h: Added include of TextIteratorBehavior.h
66391        and moved comments about the meanings of flag bits to their definition.
66392
66393        * editing/TextIteratorBehavior.h: Added.
66394
66395        * WebCore.exp.in: Updated for type changes.
66396
663972014-03-02  Enrica Casucci  <enrica@apple.com>
66398
66399        [iOS WebKit2] Form controls handling
66400        https://bugs.webkit.org/show_bug.cgi?id=129344
66401        <rdar://problem/16053643>
66402
66403        Reviewed by Simon Fraser.
66404
66405        Updates localizable strings and adds some exports.
66406
66407        * English.lproj/Localizable.strings:
66408        * WebCore.exp.in:
66409        * WebCore.xcodeproj/project.pbxproj:
66410
664112014-03-02  Benjamin Poulain  <bpoulain@apple.com>
66412
66413        [iOS][WK2] Pages using tiled compositing layers allocate too many tiles on zoom
66414        https://bugs.webkit.org/show_bug.cgi?id=129471
66415
66416        Reviewed by Simon Fraser.
66417
66418        A few issues with TileController were causing sublayers of the root layers
66419        to tile incorrect surfaces on zoom.
66420
66421        First, the exposedRect API was not updating the sublayers. The layers go correctly
66422        into tiling mode, but the tiles cover the full document instead of the visible area.
66423
66424        The other major issue was the margins being applied to the coverage size in document
66425        coordinates. Since each margin is 512px, the total coverage size after zoom was
66426        gigantic.
66427
66428        To solve this, this patch switch from the exposedRect API to the generic concept
66429        of VisibleExtentContentRect introduced for iOS WebKit1.
66430
66431        * WebCore.exp.in:
66432        * platform/ScrollView.h:
66433        Define a VisibleExtentContentRect on the scrollview itself when there is no
66434        platformWidget().
66435        The case with inside frame is untested due to stability issues :(.
66436        (see <rdar://problem/16199219>)
66437
66438        * platform/graphics/ca/mac/TileController.mm:
66439        (WebCore::TileController::computeTileCoverageRect):
66440        Remove the margin from the tile coverage.
66441
66442        On iOS, m_tileCoverage is always zero at the moment. Previously, the tile coverage
66443        was artificially extended by the margins. With the margins removed, I temporarily added
66444        a factor of 1.5.
66445        ViewUpdateDispatcher has all the information to compute a great tile coverage, I will need
66446        a follow up patch to fix that.
66447
66448        * platform/ios/ScrollViewIOS.mm:
66449        (WebCore::ScrollView::visibleExtentContentRect):
66450        (WebCore::ScrollView::setVisibleExtentContentRect):
66451
664522014-03-02  Darin Adler  <darin@apple.com>
66453
66454        Sort Mac platform export files so they merge better
66455        https://bugs.webkit.org/show_bug.cgi?id=129581
66456
66457        Reviewed by Sam Weinig.
66458
66459        * WebCore.exp.in: Ran the new sort-export-file on this.
66460
664612014-03-02  Dean Jackson  <dino@apple.com>
66462
66463        Add protected casting to FilterOperation classes.
66464        https://bugs.webkit.org/show_bug.cgi?id=124062
66465
66466        Reviewed by Sam Weinig.
66467
66468        Use the type cast macro generators to produce some toFilterOperation-style
66469        functions, and then use them in our PlatformCA filter code.
66470
66471        Test: css3/filters/animation-from-initial-values-with-color-matrix.html
66472
66473        * platform/graphics/ca/mac/PlatformCAFiltersMac.mm: Use the toFilterOperation methods, in
66474        some cases removing the unnecessary double cast.
66475        (PlatformCAFilters::filterValueForOperation):
66476        (PlatformCAFilters::colorMatrixValueForFilter):
66477        * platform/graphics/filters/FilterOperation.cpp:
66478        (WebCore::BasicColorMatrixFilterOperation::blend):
66479        (WebCore::BasicColorMatrixFilterOperation::operator==): Move this to the .cpp file so it can use the casting methods.
66480        (WebCore::BasicComponentTransferFilterOperation::blend):
66481        (WebCore::BasicComponentTransferFilterOperation::operator==): Ditto.
66482        * platform/graphics/filters/FilterOperation.h: Add the casting macros.
66483
664842014-03-02  Yoav Weiss  <yoav@yoav.ws>
66485
66486        Fix srcset related bugs
66487        https://bugs.webkit.org/show_bug.cgi?id=129539
66488
66489        Fixed a bug reported against Blink's srcset implementation at https://code.google.com/p/chromium/issues/detail?id=347998
66490        When both src and srcset had only 1x descriptors and the DPR was higher than 1, the src's resource was picked.
66491
66492        Also fixed the invalid descriptor handling, which wasn't aligned with the spec, and therefore was not as forward compatible as it should be.
66493        Invalid descriptors caused the entire resource to be ignored, rather than just the descriptors themselves.
66494
66495        Reviewed by Andreas Kling.
66496
66497        Tests: fast/hidpi/image-srcset-invalid-descriptor.html
66498               fast/hidpi/image-srcset-src-selection-1x-both.html
66499
66500        * html/parser/HTMLParserIdioms.cpp:
66501        (WebCore::parseDescriptors):
66502        (WebCore::parseImagesWithScaleFromSrcsetAttribute):
66503        (WebCore::bestFitSourceForImageAttributes):
66504
665052014-03-01  Gavin Barraclough  <barraclough@apple.com>
66506
66507        Split UserActivity, simplify PageThrottler
66508        https://bugs.webkit.org/show_bug.cgi?id=129551
66509
66510        Reviewed by Darin Adler.
66511
66512        The class UserActivity currently implements two things – a hysteresis mechanism, and
66513        an abstraction of NSActivity controlled by that mechanism. PageThrottler implements
66514        its own hysteresis mechanism, which directly controls DOM timer throttling and also
66515        controls a couple of UserActivities, giving a total of 3 separate hysteresis mechanisms,
66516        layered two deep.
66517
66518        Split UserActivity into three, with HysteresisActivity implementing an abstract hysteresis
66519        mechanism, UserActivity::Impl controlling the NSActivity, and then UserActivity combining
66520        these two back together. The interface to UserActivity is unchanged.
66521
66522        Remove PageThrottler's bespoke hysteresis, replacing it with a use of HysteresisActivity.
66523        Replace the two UserActivities with a single UserActivity::Impl, so there are no longer
66524        layered hysteresis mechanisms.
66525
66526        * WebCore.exp.in:
66527            - exports changed.
66528        * WebCore.xcodeproj/project.pbxproj:
66529            - added HysteresisActivity.h.
66530        * page/PageThrottler.cpp:
66531        (WebCore::PageThrottler::PageThrottler):
66532            - if the page starts visible, begin activity. If it starts hidden throttle DOM timers.
66533        (WebCore::PageThrottler::hiddenPageDOMTimerThrottlingStateChanged):
66534            - when the DOM timer throttling setting changes, make sure we update.
66535        (WebCore::PageThrottler::incrementActivityCount):
66536        (WebCore::PageThrottler::decrementActivityCount):
66537            - when m_activityCount changes update the hysteresis state.
66538        (WebCore::PageThrottler::updateHysteresis):
66539        (WebCore::PageThrottler::setViewState):
66540            - when IsVisuallyIdle changes update the hysteresis state.
66541        (WebCore::PageThrottler::started):
66542        (WebCore::PageThrottler::stopped):
66543            - callbacks from HysteresisActivity, these control m_activity and DOM timer throttling.
66544        * page/PageThrottler.h:
66545        (WebCore::PageThrottler::didReceiveUserInput):
66546        (WebCore::PageThrottler::pluginDidEvaluate):
66547            - call impulse to temporarily enable the activity.
66548        * platform/HysteresisActivity.h: Copied from Source/WebCore/platform/UserActivity.h.
66549        (WebCore::HysteresisActivity::HysteresisActivity):
66550            - constructor takes a delegate optionally a timeout.
66551        (WebCore::HysteresisActivity::start):
66552            - start activity immediately. If stopped, call started method on delegate. If in timeout period, cancel the timer.
66553        (WebCore::HysteresisActivity::stop):
66554            - stop activity after hysteresis. If started, initiate timeout period.
66555        (WebCore::HysteresisActivity::impulse):
66556            - ensure activity for at least the timeout period.
66557        (WebCore::HysteresisActivity::hysteresisTimerFired):
66558            - delayed stop - when the timer fires call stopped on the delegate.
66559        * platform/UserActivity.cpp:
66560        (WebCore::UserActivity::Impl::Impl):
66561        (WebCore::UserActivity::Impl::beginActivity):
66562        (WebCore::UserActivity::Impl::endActivity):
66563            - nop implementation.
66564        (WebCore::UserActivity::UserActivity):
66565            - UserActivity maintains existing interface with hysteresis.
66566        (WebCore::UserActivity::started):
66567        (WebCore::UserActivity::stopped):
66568            - callbacks from HysteresisTimer; forward to Impl.
66569        * platform/UserActivity.h:
66570        * platform/mac/UserActivityMac.mm:
66571        (WebCore::UserActivity::Impl::Impl):
66572            - UserActivity::Impl, abstraction for NSActivity without added hysteresis.
66573        (WebCore::UserActivity::Impl::beginActivity):
66574            - allocate NSActivity.
66575        (WebCore::UserActivity::Impl::endActivity):
66576            - release NSActivity.
66577
665782014-03-02  Brian Burg  <bburg@apple.com>
66579
66580        DocumentLoader should keep maps of ResourceLoaders instead of sets
66581        https://bugs.webkit.org/show_bug.cgi?id=129388
66582
66583        Reviewed by Darin Adler.
66584
66585        For web replay, we need to be able to pull a ResourceLoader instance by
66586        identifier from the DocumentLoader. This is easy to do if we convert
66587        ResourceLoaderSet to ResourceLoaderMap, keyed by the loader's identifier.
66588
66589        Added assertions whenever adding or removing from the map to ensure
66590        that we don't try to add duplicates or resources with zero identifiers.
66591
66592        No new tests required. No functionality was added.
66593
66594        * loader/DocumentLoader.cpp:
66595        (WebCore::cancelAll):
66596        (WebCore::setAllDefersLoading):
66597        (WebCore::areAllLoadersPageCacheAcceptable):
66598        (WebCore::DocumentLoader::addSubresourceLoader):
66599        (WebCore::DocumentLoader::removeSubresourceLoader):
66600        (WebCore::DocumentLoader::addPlugInStreamLoader):
66601        (WebCore::DocumentLoader::removePlugInStreamLoader):
66602        (WebCore::DocumentLoader::subresourceLoaderFinishedLoadingOnePart):
66603        * loader/DocumentLoader.h:
66604        * loader/NetscapePlugInStreamLoader.cpp:
66605        (WebCore::NetscapePlugInStreamLoader::create): Only add the loader
66606        to the document loader's map if it initialized successfully.
66607        The old code was probably leaking resource loaders that failed to
66608        initialize.
66609
66610        * loader/mac/DocumentLoaderMac.cpp:
66611        (WebCore::scheduleAll):
66612        (WebCore::unscheduleAll):
66613
666142014-03-02  Dirkjan Ochtman  <d.ochtman@activevideo.com>
66615
66616        Support ENABLE_ENCRYPTED_MEDIA in cmake builds
66617        https://bugs.webkit.org/show_bug.cgi?id=129575
66618
66619        Reviewed by Philippe Normand.
66620
66621        No new tests, only fixes the build.
66622
66623        * CMakeLists.txt:
66624        Add support for ENABLE_ENCRYPTED_MEDIA.
66625        * Modules/encryptedmedia/MediaKeySession.cpp:
66626        (WebCore::MediaKeySession::close):
66627        Assign nullptr instead of 0 to OwnPtr to appease gcc-4.7.
66628
666292014-03-01  Tim Horton  <timothy_horton@apple.com>
66630
66631        WebKit2 View Gestures (Smart Magnification): Support for iOS
66632        https://bugs.webkit.org/show_bug.cgi?id=129146
66633        <rdar://problem/16032668>
66634
66635        Reviewed by Benjamin Poulain.
66636
66637        * WebCore.exp.in:
66638        Add an export.
66639
666402014-03-01  Commit Queue  <commit-queue@webkit.org>
66641
66642        Unreviewed, rolling out r164929 and r164934.
66643        http://trac.webkit.org/changeset/164929
66644        http://trac.webkit.org/changeset/164934
66645        https://bugs.webkit.org/show_bug.cgi?id=129570
66646
66647        Caused assertions on two srcset tests (Requested by ap on
66648        #webkit).
66649
66650        * html/parser/HTMLParserIdioms.cpp:
66651        (WebCore::isHTMLSpaceOrComma):
66652        (WebCore::parseImagesWithScaleFromSrcsetAttribute):
66653        (WebCore::bestFitSourceForImageAttributes):
66654
666552014-03-01  Dan Bernstein  <mitz@apple.com>
66656
66657        Build fix.
66658
66659        * html/parser/HTMLParserIdioms.cpp: Removed an unused function.
66660
666612014-03-01  David Kilzer  <ddkilzer@apple.com>
66662
66663        Ensure keySplines is valid in SMIL animations
66664        <http://webkit.org/b/129547>
66665        <rdar://problem/15676128>
66666
66667        Reviewed by Darin Adler.
66668
66669        Merged from Blink (patch by Philip Rogers):
66670        https://src.chromium.org/viewvc/blink?revision=156452&view=revision
66671        http://crbug.com/276111
66672
66673            This patch fixes a crash in SMIL animations when keySplines are not
66674            specified. The SMIL spec is clear on this:
66675            http://www.w3.org/TR/2001/REC-smil-animation-20010904/#AnimFuncCalcMode
66676            "If there are any errors in the keyTimes specification (bad values,
66677            too many or too few values), the animation will have no effect."
66678
66679            This patch simply checks that keyTimes is not empty. Previously,
66680            splinesCount was set to be m_keySplines.size() + 1 in
66681            SVGAnimationElement.cpp; this patch changes splinesCount to be equal
66682            to m_keySplines.size() to make the logic easier to follow and to
66683            match other checks in SVGAnimationElement::startedActiveInterval.
66684
66685        Test: svg/animations/animate-keysplines-crash.html
66686
66687        * svg/SVGAnimationElement.cpp:
66688        (WebCore::SVGAnimationElement::startedActiveInterval):
66689
666902014-03-01  Benjamin Poulain  <benjamin@webkit.org>
66691
66692        Tighten minimumRegisterRequirements()
66693        https://bugs.webkit.org/show_bug.cgi?id=129538
66694
66695        Reviewed by Andreas Kling.
66696
66697        Fix small things that made minimumRegisterRequirements() a little optimistic
66698        when dealing with attributes.
66699
66700        Test: fast/selectors/adjacent-descendant-tail-register-requirement.html
66701
66702        * cssjit/SelectorCompiler.cpp:
66703        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
66704        Attribute Set does not do value matching, the case sensitive value matching is irrelevant
66705        The problem is that flag is also used by minimumRegisterRequirements()
66706        to find if one more register is needed.
66707
66708        Set the flag to case sensitive to avoid reserving one extra register.
66709
66710        (WebCore::SelectorCompiler::minimumRegisterRequirements):
66711        Use a new backtrackingFlag to know if there is a descendant tail, thus a backtracking register
66712        reserved.
66713        This is better than using the backtracking action because the backtracking chain could be
66714        an adjacent chain inside a descendant chain.
66715
66716        The flags are designed for that, just set one for minimumRegisterRequirements().
66717
66718        The 2 extra registers for the attribute count and address become limited to all attributes
66719        except the last one. We don't keep a copy for the last matching, those registers were not needed.
66720
66721        (WebCore::SelectorCompiler::SelectorCodeGenerator::computeBacktrackingInformation):
66722
667232014-03-01  Pratik Solanki  <psolanki@apple.com>
66724
66725        [iOS] selectionImageForcingBlackText should return autoreleased object
66726        https://bugs.webkit.org/show_bug.cgi?id=129437
66727        <rdar://problem/15810384>
66728
66729        Reviewed by Darin Adler.
66730
66731        * bindings/objc/DOM.mm:
66732        (-[DOMRange renderedImageForcingBlackText:renderedImageForcingBlackText:]):
66733
667342014-03-01  Yoav Weiss  <yoav@yoav.ws>
66735
66736        Fix srcset related bugs
66737        https://bugs.webkit.org/show_bug.cgi?id=129539
66738
66739        Fixed a bug reported against Blink's srcset implementation at https://code.google.com/p/chromium/issues/detail?id=347998
66740        When both src and srcset had only 1x descriptors and the DPR was higher than 1, the src's resource was picked.
66741
66742        Also fixed the invalid descriptor handling, which wasn't aligned with the spec, and therefore was not as forward compatible as it should be.
66743        Invalid descriptors caused the entire resource to be ignored, rather than just the descriptors themselves.
66744
66745        Reviewed by Andreas Kling.
66746
66747        Tests: fast/hidpi/image-srcset-invalid-descriptor.html
66748               fast/hidpi/image-srcset-src-selection-1x-both.html
66749
66750        * html/parser/HTMLParserIdioms.cpp:
66751        (WebCore::parseDescriptors):
66752        (WebCore::parseImagesWithScaleFromSrcsetAttribute):
66753        (WebCore::bestFitSourceForImageAttributes):
66754
667552014-03-01  Darin Adler  <darin@apple.com>
66756
66757        Improve "bad parent" and "bad child list" assertions in line boxes
66758        https://bugs.webkit.org/show_bug.cgi?id=125656
66759
66760        Reviewed by Sam Weinig.
66761
66762        My previous fix for this problem was incomplete. This continuation of that fix addresses
66763        the flaw in the original and adds additional lifetime checking so problems can be seen in
66764        debug builds without a memory debugger.
66765
66766        * rendering/InlineBox.cpp:
66767        (WebCore::InlineBox::assertNotDeleted): Added. Poor man's memory debugging helper.
66768        (WebCore::InlineBox::~InlineBox): Refactored body into a new function named
66769        invalidateParentChildList. Added code to update the deletion sentinel to record
66770        that this object is deleted.
66771        (WebCore::InlineBox::setHasBadParent): Moved here from header since this debug-only
66772        feature does not need to be inlined. Added a call to assertNotDeleted.
66773        (WebCore::InlineBox::invalidateParentChildList): Added. Refactored from the destructor,
66774        this is used by RenderTextLineBoxes.
66775
66776        * rendering/InlineBox.h: Added the deletion sentinel, and called it in the parent
66777        function. Also changed the expansion/setExpansion functions to use the type name "int",
66778        since we don't use the type name "signed" in the WebKit coding style.
66779
66780        * rendering/InlineFlowBox.cpp:
66781        (WebCore::InlineFlowBox::~InlineFlowBox): Call setHasBadChildList rather than doing the
66782        setHasBadParent work on children directly, to avoid code duplication.
66783        (WebCore::InlineFlowBox::setHasBadChildList): Moved here from header. Added code to set
66784        "has bad parent" on all children, something we previously did only on destruction. Also
66785        added assertNotDeleted.
66786        (WebCore::InlineFlowBox::checkConsistency): Added call to assertNotDeleted. Also tweaked
66787        code style and variable names a little bit.
66788
66789        * rendering/InlineFlowBox.h: Moved setHasBadChildList out of the header when it's on.
66790        The empty version for ASSERT_WITH_SECURITY_IMPLICATION_DISABLED is still in the header.
66791
66792        * rendering/RenderTextLineBoxes.cpp:
66793        (WebCore::RenderTextLineBoxes::invalidateParentChildLists): Call the new
66794        InlineBox::invalidateParentChildList function instead of calling setHasBadChildList directly.
66795        The new function checks m_hasBadParent, something we couldn't do here.
66796
667972014-03-01  Benjamin Poulain  <benjamin@webkit.org>
66798
66799        Optimized querySelector(All) when selector contains #id
66800        https://bugs.webkit.org/show_bug.cgi?id=116502
66801
66802        Reviewed by Andreas Kling.
66803
66804        Test: fast/selectors/querySelector-id-filtering.html
66805
66806        The idea of this patch is to perform querySelector on a subtree
66807        rooted at the last element with #id matching. For example, if we have the selector
66808        "#foobar div a", we start by looking for the element with ID foobar in the TreeScope
66809        cache, and start matching the children from there.
66810
66811        The idea comes from Rune for
66812        https://chromium.googlesource.com/chromium/blink/+/1cd83d3588973a02ab15d94b1b05a28620853624
66813        but the code as diverged too much so it had to be reimplemented specifically for WebKit.
66814
66815        * css/CSSSelectorList.cpp:
66816        (WebCore::CSSSelectorList::CSSSelectorList):
66817        (WebCore::CSSSelectorList::operator=):
66818        * css/CSSSelectorList.h:
66819        (WebCore::CSSSelectorList::~CSSSelectorList):
66820        * css/StyleRule.h:
66821        (WebCore::StyleRule::wrapperAdoptSelectorList):
66822        (WebCore::StyleRulePage::wrapperAdoptSelectorList):
66823        * dom/SelectorQuery.cpp:
66824        (WebCore::isSingleTagNameSelector):
66825        (WebCore::isSingleClassNameSelector):
66826        (WebCore::findIdMatchingType):
66827        (WebCore::SelectorDataList::SelectorDataList):
66828        (WebCore::filterRootById):
66829        (WebCore::SelectorDataList::executeCompiledSimpleSelectorChecker):
66830        (WebCore::SelectorDataList::execute):
66831        (WebCore::SelectorQuery::SelectorQuery):
66832        (WebCore::SelectorQueryCache::add):
66833        * dom/SelectorQuery.h:
66834        (WebCore::SelectorDataList::SelectorData::SelectorData):
66835
668362014-02-28  Alexey Proskuryakov  <ap@apple.com>
66837
66838        Node::compareDocumentPosition leaks memory structure
66839        https://bugs.webkit.org/show_bug.cgi?id=120244
66840
66841        Reviewed by Ryosuke Niwa.
66842
66843        * dom/Node.cpp: (WebCore::Node::compareDocumentPosition): Don't do it.
66844
668452014-03-01  David Kilzer  <ddkilzer@apple.com>
66846
66847        Fix lifetime handling of SVGPropertyTearOffs
66848        <http://webkit.org/b/129211>
66849        <rdar://problem/15696025>
66850
66851        Reviewed by Maciej Stachowiak.
66852
66853        Merged from Blink (patch by Ojan Vafai):
66854        https://src.chromium.org/viewvc/blink?revision=157801&view=revision
66855        http://crbug.com/288771
66856
66857            -Replace SVGStaticPropertyWithParentTearOff with SVGMatrixTearOff
66858            since it's only used in that one place. This means we can get rid
66859            of the templatizing and the method pointer.
66860            -Change SVGPropertyTearOff to keep track of it's child tearoffs
66861            and call detachWrapper on its child tearoffs when it's destroyed
66862            or when it's wrapper is detached.
66863            -Have SVGPropertyTearOff hold WeakPtrs to the child tearoffs
66864            to avoid having a cycle.
66865
66866        Test: svg/transforms/svg-matrix-tearoff-crash.html
66867
66868        * GNUmakefile.list.am:
66869        * WebCore.vcxproj/WebCore.vcxproj:
66870        * WebCore.vcxproj/WebCore.vcxproj.filters:
66871        * WebCore.xcodeproj/project.pbxproj:
66872        * bindings/scripts/CodeGeneratorJS.pm:
66873        (NativeToJSValue):
66874        * svg/properties/SVGMatrixTearOff.h: Renamed from Source/WebCore/svg/properties/SVGStaticPropertyWithParentTearOff.h.
66875        (WebCore::SVGMatrixTearOff::create):
66876        (WebCore::SVGMatrixTearOff::commitChange):
66877        (WebCore::SVGMatrixTearOff::SVGMatrixTearOff):
66878        * svg/properties/SVGPropertyTearOff.h:
66879        (WebCore::SVGPropertyTearOff::addChild):
66880        (WebCore::SVGPropertyTearOff::detachChildren):
66881
668822014-03-01  Zan Dobersek  <zdobersek@igalia.com>
66883
66884        Unreviewed build fix after r164913.
66885
66886        * platform/CountedUserActivity.h: Some ports don't (yet) support forwarding headers for WebCore,
66887        so UserActivity.h should be included as non-forwarding.
66888
668892014-03-01  Gavin Barraclough  <barraclough@apple.com>
66890
66891        Change PageActivityAssertionToken to use a WeakPtr
66892        https://bugs.webkit.org/show_bug.cgi?id=129526
66893
66894        Reviewed by Sam Weinig.
66895
66896        PageThrottler effectively implements a bespoke weak pointer mechanism; remove this & just use WeakPtr.
66897
66898        * page/PageActivityAssertionToken.cpp:
66899        (WebCore::PageActivityAssertionToken::PageActivityAssertionToken):
66900        (WebCore::PageActivityAssertionToken::~PageActivityAssertionToken):
66901            - addActivityToken->incrementActivityCount, removeActivityToken->decrementActivityCount
66902        * page/PageActivityAssertionToken.h:
66903            - removed invalidate, made m_throttler a WeakPtr
66904        * page/PageThrottler.cpp:
66905        (WebCore::PageThrottler::PageThrottler):
66906            - initialize m_weakPtrFactory, m_activityCount.
66907        (WebCore::PageThrottler::~PageThrottler):
66908            - removed called to invalidate.
66909        (WebCore::PageThrottler::startThrottleHysteresisTimer):
66910            - m_activityTokens.size()->m_activityCount
66911        (WebCore::PageThrottler::throttleHysteresisTimerFired):
66912            - m_activityTokens.size()->m_activityCount
66913        (WebCore::PageThrottler::incrementActivityCount):
66914            - m_activityTokens.add->++
66915        (WebCore::PageThrottler::decrementActivityCount):
66916            - m_activityTokens.remove->--
66917        * page/PageThrottler.h:
66918        (WebCore::PageThrottler::weakPtr):
66919            - replaced HashSet with WeakPtrFactory & count.
66920
669212014-03-01  Gavin Barraclough  <barraclough@apple.com>
66922
66923        Split UserActivity/CountedUserActivity
66924        https://bugs.webkit.org/show_bug.cgi?id=129520
66925
66926        Reviewed by Sam Weinig.
66927
66928        UserActivity currently provides an interface allowing counted, nested calls to enable/disable.
66929        In some cases it would be easier to use if it were a simpler boolean enabled/disabled interface.
66930
66931        * WebCore.exp.in:
66932            - beginActivity->start, endActivity->stop.
66933        * WebCore.xcodeproj/project.pbxproj:
66934        * page/PageThrottler.cpp:
66935        (WebCore::PageThrottler::PageThrottler):
66936        (WebCore::PageThrottler::~PageThrottler):
66937        (WebCore::PageThrottler::throttlePage):
66938        (WebCore::PageThrottler::unthrottlePage):
66939        (WebCore::PageThrottler::setIsVisuallyIdle):
66940            - beginActivity->increment, endActivity->decrement.
66941        * page/PageThrottler.h:
66942            - UserActivity->CountedUserActivity for m_pageActivity
66943        * platform/CountedUserActivity.h: Copied from Source/WebCore/platform/UserActivity.h.
66944        (WebCore::CountedUserActivity::CountedUserActivity):
66945        (WebCore::CountedUserActivity::increment):
66946        (WebCore::CountedUserActivity::decrement):
66947            - Added, provides counted interface to UserActivity.
66948        * platform/UserActivity.cpp:
66949        (WebCore::UserActivity::UserActivity):
66950            - m_count removed
66951        (WebCore::UserActivity::start):
66952        (WebCore::UserActivity::stop):
66953            - beginActivity->start, endActivity->stop, implentation now empty.
66954        * platform/UserActivity.h:
66955            - beginActivity->start, endActivity->stop, m_count moved to HAVE(NS_ACTIVITY)
66956        * platform/mac/UserActivityMac.mm:
66957        (WebCore::UserActivity::UserActivity):
66958            - m_count->m_started
66959        (WebCore::UserActivity::isValid):
66960            - m_count->m_started
66961        (WebCore::UserActivity::start):
66962        (WebCore::UserActivity::stop):
66963            - beginActivity->start, endActivity->stop, no longer nest
66964
66965
669662014-02-28  Benjamin Poulain  <benjamin@webkit.org>
66967
66968        Caller saved registers can be accidentally discarded when clearing the local stack
66969        https://bugs.webkit.org/show_bug.cgi?id=129532
66970
66971        Reviewed by Andreas Kling.
66972
66973        Tests: fast/selectors/tree-modifying-case-insensitive-selectors.html
66974               fast/selectors/tree-modifying-selectors.html
66975
66976        StackAllocator::discard() no longer make sense now that we can use caller saved regsiter.
66977        We should instead discard everything up to the beginning of the local stack.
66978
66979        * cssjit/SelectorCompiler.cpp:
66980        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
66981        * cssjit/StackAllocator.h:
66982        (WebCore::StackAllocator::popAndDiscardUpTo):
66983
669842014-02-28  Andy Estes  <aestes@apple.com>
66985
66986        [iOS] FrameLoader has a NULL m_progressTracker when initialized with initForSynthesizedDocument()
66987        https://bugs.webkit.org/show_bug.cgi?id=129534
66988
66989        Reviewed by Simon Fraser.
66990
66991        No new tests because TestWebKitAPI does not yet support iOS. See <http://webkit.org/b/129535>.
66992
66993        * loader/FrameLoader.cpp:
66994        (WebCore::FrameLoader::initForSynthesizedDocument): Create a FrameProgressTracker.
66995
669962014-02-28  Sam Weinig  <sam@webkit.org>
66997
66998        ASSERT(isMainThread()) hit under platformUserPreferredLanguages() with WebKit1 and WebKit2 in the same process
66999        https://bugs.webkit.org/show_bug.cgi?id=129528
67000
67001        Reviewed by Andreas Kling.
67002
67003        * platform/mac/Language.mm:
67004        (WebCore::preferredLanguagesMutex):
67005        (WebCore::preferredLanguages):
67006        (+[WebLanguageChangeObserver languagePreferencesDidChange:]):
67007        (WebCore::httpStyleLanguageCode):
67008        (WebCore::platformUserPreferredLanguages):
67009        Add a mutex and do an isolated copy of the strings to allow this function to be called from multiple threads.
67010
670112014-02-28  Dean Jackson  <dino@apple.com>
67012
67013        Crash at ebay.com when viewing auction items at com.apple.WebCore: WebCore::GraphicsContext3D::getExtensions + 10
67014        https://bugs.webkit.org/show_bug.cgi?id=129523
67015
67016        Reviewed by Simon Fraser.
67017
67018        * html/canvas/WebGLRenderingContext.cpp:
67019        (WebCore::WebGLRenderingContext::getSupportedExtensions): Early return if the
67020        context is pending policy resolution.
67021
670222014-02-28  Andreas Kling  <akling@apple.com>
67023
67024        Micro-optimize JSNodeOwner::isReachableFromOpaqueRoots().
67025        <https://webkit.org/b/129518>
67026
67027        Only do image and audio element specific checks for element nodes.
67028        Time spent in here goes from 0.8% to 0.5% on DYEB.
67029
67030        Reviewed by Benjamin Poulain.
67031
67032        * bindings/js/JSNodeCustom.cpp:
67033        (WebCore::isReachableFromDOM):
67034
670352014-02-28  Geoffrey Garen  <ggaren@apple.com>
67036
67037        JSC Assertion failure every time I start Safari (r164846)
67038        https://bugs.webkit.org/show_bug.cgi?id=129510
67039
67040        Reviewed by Mark Hahnenberg.
67041
67042        Take the lock before allocating objects because afterward is too late.
67043
67044        * bindings/js/ScriptController.cpp:
67045        (WebCore::ScriptController::evaluateInWorld):
67046        (WebCore::ScriptController::windowScriptNPObject):
67047        (WebCore::ScriptController::jsObjectForPluginElement):
67048
670492014-02-28  Joseph Pecoraro  <pecoraro@apple.com>
67050
67051        Web Inspector: ASSERT in WebCore::JSDOMWindowBase::supportsRichSourceInfo inspecting iOS
67052        https://bugs.webkit.org/show_bug.cgi?id=129512
67053
67054        Reviewed by Simon Fraser.
67055
67056        * page/PageDebuggable.cpp:
67057        (WebCore::PageDebuggable::connect):
67058        (WebCore::PageDebuggable::disconnect):
67059
670602014-02-28  Anders Carlsson  <andersca@apple.com>
67061
67062        VisitedLinkStore should be able to invalidate link styles for associated pages
67063        https://bugs.webkit.org/show_bug.cgi?id=129515
67064
67065        Reviewed by Dan Bernstein.
67066
67067        * page/Page.cpp:
67068        (WebCore::Page::Page):
67069        Add the VisitedLinkStore if we have one.
67070
67071        (WebCore::Page::~Page):
67072        Remove the VisitedLinkStore if we have one.
67073
67074        * page/VisitedLinkStore.cpp:
67075        (WebCore::VisitedLinkStore::~VisitedLinkStore):
67076        Assert that we don't have any pages.
67077
67078        (WebCore::VisitedLinkStore::addPage):
67079        Add the page to the set.
67080
67081        (WebCore::VisitedLinkStore::removePage):
67082        Remove the page from the set.
67083
67084        (WebCore::VisitedLinkStore::invalidateStylesForAllLinks):
67085        Traverse all the pages and invalidate the style for all links.
67086
67087        (WebCore::VisitedLinkStore::invalidateStylesForLink):
67088        Traverse all the pages and invalidate the style for a given link.
67089
67090        * page/VisitedLinkStore.h:
67091        Add new members.
67092
670932014-02-28  Benjamin Poulain  <bpoulain@apple.com>
67094
67095        [iOS][WK2] highlight rects should never big bigger than the view
67096        https://bugs.webkit.org/show_bug.cgi?id=129472
67097
67098        Reviewed by Enrica Casucci.
67099
67100        * WebCore.exp.in:
67101
671022014-02-28  Beth Dakin  <bdakin@apple.com>
67103
67104        Turn off margin tiles on iOS
67105        https://bugs.webkit.org/show_bug.cgi?id=129509
67106        -and corresponding-
67107        <rdar://problem/16200383>
67108
67109        Reviewed by Simon Fraser.
67110
67111        * page/FrameView.cpp:
67112        (WebCore::FrameView::needsExtendedBackgroundRectForPainting):
67113
671142014-02-28  Zalan Bujtas  <zalan@apple.com>
67115
67116        Subpixel rendering: Add subpixel support to border type of double, groove, ridge, inset and outset.
67117        https://bugs.webkit.org/show_bug.cgi?id=129226
67118
67119        Reviewed by Simon Fraser.
67120
67121        This is the conversion of double, inset, outset, groove and ridge border type
67122        painting to support device pixel precision width/height.
67123
67124        Regression is covered by existing tests.
67125
67126        * rendering/RenderObject.cpp:
67127        (WebCore::RenderObject::drawLineForBoxSide):
67128        * rendering/RenderObject.h:
67129
671302014-02-28  Adenilson Cavalcanti  <cavalcantii@gmail.com>
67131
67132        Filters should test for area instead of single dimension
67133        https://bugs.webkit.org/show_bug.cgi?id=123716
67134
67135        Reviewed by Dirk Schulze.
67136
67137        A filtered SVG element with a sigle dimension bigger than 5000
67138        (counting the margin/border) will fail to render. So an element
67139        with 4000x4000 will render fine, while another with 5000x10
67140        won't. This patch instead tests against the total element area,
67141        which fixes such cases.
67142
67143        It also fixes some layer violations where FilterEffectRenderer and
67144        RenderSVGResourceFilter were directly accessing the maximum filter
67145        size in FilterEffect. Since before a somewhat bigger filter would
67146        be aborted, it required to change the maximum kernel size
67147        for blur filter (some filters are slower to run than others for
67148        bigger SVGs).
67149
67150        Tests: svg/filters/big-height-filter-expected.svg
67151               svg/filters/big-height-filter.svg
67152               svg/filters/big-width-filter-expected.svg
67153               svg/filters/big-width-filter.svg
67154
67155        * platform/graphics/filters/FEGaussianBlur.cpp:
67156        * platform/graphics/filters/FilterEffect.cpp:
67157        (WebCore::FilterEffect::maxFilterArea): New function, returns the
67158        maximum allowed element area (currently is 4096 x 4096).
67159        (WebCore::FilterEffect::isFilterSizeValid): Now it tests for
67160        element area instead of a single dimension. This code is reused by
67161        FilterEffectRenderer.
67162        * platform/graphics/filters/FilterEffect.h:
67163        * rendering/FilterEffectRenderer.cpp:
67164        (WebCore::FilterEffectRenderer::updateBackingStoreRect): Uses the
67165        new function in FilterEffect to test for valid sizes.
67166        (WebCore::FilterEffectRendererHelper::beginFilterEffect): Same case.
67167        * rendering/svg/RenderSVGResourceFilter.cpp:
67168        (WebCore::RenderSVGResourceFilter::fitsInMaximumImageSize): Test
67169        for maximum area and properly changes the scale of transformed
67170        element to fit.
67171
671722014-02-28  Brent Fulgham  <bfulgham@apple.com>
67173
67174        [Mac, iOS] Incorrect ordering of construction arguments for out-of-band text elements
67175        https://bugs.webkit.org/show_bug.cgi?id=129501
67176        <rdar://problem/16198587>
67177
67178        Reviewed by Eric Carlson.
67179
67180        * html/HTMLMediaElement.cpp:
67181        (WebCore::HTMLMediaElement::parseAttribute): Correct order of arguments
67182        to PlatformTextTrack.
67183
671842014-02-28  Bem Jones-Bey  <bjonesbe@adobe.com>
67185
67186        Properly clear m_logicallyLastRun to remove use-after-free possibility
67187        https://bugs.webkit.org/show_bug.cgi?id=129489
67188
67189        Reviewed by David Hyatt.
67190
67191        A use-after-free issue was caught in Blink because m_logicallyLastRun
67192        is not cleared when the item it points to is deleted. Clearing it
67193        turns the use-after-free into a segfault, and prevents any future
67194        use-after-frees from happening.
67195
67196        * platform/text/BidiRunList.h:
67197        (WebCore::BidiRunList<Run>::deleteRuns):
67198
671992014-02-28  Jer Noble  <jer.noble@apple.com>
67200
67201        [Mac] Disambiguate calls to [[window contentView] layer] and [... setLayer:]
67202        https://bugs.webkit.org/show_bug.cgi?id=129491
67203
67204        Reviewed by Alexey Proskuryakov.
67205
67206        -[NSWindow contentView] returns a bare id, leading to ambiguity when calling
67207        certain methods, including -layer and -setLayer:. Resolve the ambiguity by
67208        explicitly casting the -contentView call to a NSView*.
67209
67210        * platform/mac/WebVideoFullscreenController.mm:
67211        (-[WebVideoFullscreenController setupVideoOverlay:]):
67212        (-[WebVideoFullscreenController windowDidLoad]):
67213        (-[WebVideoFullscreenController windowDidExitFullscreen]):
67214
672152014-02-28  Andreas Kling  <akling@apple.com>
67216
67217        MouseEvent.offsetX/Y should just return 0,0 for simulated clicks.
67218        <https://webkit.org/b/129477>
67219
67220        There's no need to compute the exact target-relative coordinates for
67221        simulated mouse events, e.g those fired by HTMLElement.click().
67222
67223        The offsetX/Y properties are not supported by Firefox.
67224
67225        Test: fast/events/relative-offset-of-simulated-click.html
67226
67227        Reviewed by Alexey Proskuryakov.
67228
67229        * dom/MouseRelatedEvent.cpp:
67230        (WebCore::MouseRelatedEvent::offsetX):
67231        (WebCore::MouseRelatedEvent::offsetY):
67232
672332014-02-27  Sergio Villar Senin  <svillar@igalia.com>
67234
67235        [CSS Grid Layout] Fix positioning grid items using named grid lines/areas
67236        https://bugs.webkit.org/show_bug.cgi?id=129372
67237
67238        Reviewed by Darin Adler.
67239
67240        Our code was assuming that a <custom-ident> in
67241        -webkit-grid-{column|row}-{start|end} and
67242        -webkit-grid-{column|row} was always a grid area name. That's
67243        wrong because the <custom-ident> could be also a explicitly named
67244        grid line or the an implicitly named grid line created by a grid
67245        area definition.
67246
67247        The style resolution code was not correct either. This patch fixes
67248        it so it now matches the spec, which means that:
67249        - first we try to match any existing grid area.
67250        - then if there is a named grid line with the name
67251        <custom-ident>-{start|end} for -webkit-grid-{column|row}-{start|end}
67252        defined before the grid area then we use it instead of the grid
67253        area.
67254        - otherwise if there is a named grid line we resolve to the first such line.
67255        - otherwise we treat it as 'auto'.
67256
67257        Fixing this uncovered a bug in GridPosition, we were not using the
67258        name of the stored grid area to check if two GridPositions were
67259        the same.
67260
67261        Tests: fast/css-grid-layout/grid-item-position-changed-dynamic.html
67262               fast/css-grid-layout/named-grid-lines-with-named-grid-areas-resolution.html
67263
67264        * css/StyleResolver.cpp:
67265        (WebCore::gridLineDefinedBeforeGridArea): New function to check if
67266        a given named grid line was defined before an implicit named grid
67267        line created by a grid area definition.
67268        (WebCore::StyleResolver::adjustNamedGridItemPosition): New
67269        function that adjusts the position of a GridPosition parsed as a
67270        grid area.
67271        (WebCore::StyleResolver::adjustGridItemPosition): Use the new
67272        function adjustNamedGridItemPosition to adjust the positions of
67273        named grid lines.
67274        * css/StyleResolver.h:
67275        * rendering/RenderGrid.cpp:
67276        (WebCore::RenderGrid::resolveNamedGridLinePositionFromStyle): Use GridPosition:: namespace.
67277        (WebCore::RenderGrid::resolveGridPositionFromStyle): Ditto.
67278        (WebCore::RenderGrid::resolveRowEndColumnEndNamedGridLinePositionAgainstOppositePosition): Ditto.
67279        * rendering/RenderGrid.h:
67280        * rendering/style/GridPosition.h:
67281        (WebCore::GridPosition::adjustGridPositionForRowEndColumnEndSide): Moved from RenderGrid.cpp.
67282        (WebCore::GridPosition::adjustGridPositionForSide): Ditto.
67283        (WebCore::GridPosition::operator==): Use the named grid line to check equality.
67284
672852014-02-28  Zoltan Horvath  <zoltan@webkit.org>
67286
67287        [CSS Shapes] Update line segments for ShapeInside only if the new line is wide enough
67288        https://bugs.webkit.org/show_bug.cgi?id=129461
67289
67290        Reviewed by David Hyatt.
67291
67292        Shape-inside can make a line only narrower than the original line width, thus we don't need
67293        to update the line/shape segments in fitBelowFloats for every single line inside shape-inside.
67294        This patch adds a helper function, which updates the line segments, furthermore it updates the
67295        line segments only when the content would fit without the shape.
67296
67297        No new tests, no behavior change.
67298
67299        * rendering/line/BreakingContextInlineHeaders.h: Use new helper.
67300        (WebCore::updateSegmentsForShapes):
67301        * rendering/line/LineWidth.cpp: Use new helper.
67302        (WebCore::LineWidth::updateLineSegment): Add new helper.
67303        (WebCore::LineWidth::fitBelowFloats):
67304
673052014-02-28  Mario Sanchez Prada  <mario.prada@samsung.com>
67306
67307        paragraphs with different directionality in textarea with unicode-bidi: plaintext are aligned the same
67308        https://bugs.webkit.org/show_bug.cgi?id=71194
67309
67310        Reviewed by David Hyatt.
67311
67312        Merged from Blink r157263 by <igor.o@sisa.samsung.com>
67313        <https://src.chromium.org/viewvc/blink?revision=157263&view=revision>
67314
67315        In the css3-text spec (http://www.w3.org/TR/css3-text/#bidi-linebox):
67316
67317        The start and end edges of a line box are determined by the inline
67318        base direction of the line box. In most cases, this is given by
67319        its containing block's computed ‘direction’. However if its
67320        containing block has ‘unicode-bidi: plaintext’, the inline base
67321        direction the line box must be determined by the base direction of
67322        the bidi paragraph to which it belongs: that is, the bidi
67323        paragraph for which the line box holds content.
67324
67325        This patch just implements the behavior described above modifying
67326        updateLogicalWidthForAlignment and setting the bidi level of the
67327        RootInlineBox.
67328
67329        * rendering/RenderBlockFlow.h:
67330        * rendering/RenderBlockLineLayout.cpp:
67331        (WebCore::RenderBlockFlow::updateLogicalWidthForAlignment):
67332        (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForSegment):
67333        (WebCore::RenderBlockFlow::createLineBoxesFromBidiRuns):
67334        (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
67335        (WebCore::RenderBlockFlow::deleteEllipsisLineBoxes):
67336        (WebCore::RenderBlockFlow::checkLinesForTextOverflow):
67337        (WebCore::RenderBlockFlow::startAlignedOffsetForLine):
67338
673392014-02-28  Jochen Eisinger  <jochen@chromium.org>
67340
67341        Update meta-referrer behavior for invalid policies
67342        https://bugs.webkit.org/show_bug.cgi?id=129475
67343
67344        This patch aligns the behavior with the CSP 1.1 referrer directive,
67345        where the fallback for an invalid value is the "never" policy.
67346
67347        Original patch from Mike West: https://src.chromium.org/viewvc/blink?view=rev&revision=165627
67348
67349        Reviewed by Alexey Proskuryakov.
67350
67351        Test: http/tests/security/referrer-policy-invalid.html
67352
67353        * dom/Document.cpp:
67354        (WebCore::Document::processReferrerPolicy):
67355
673562014-02-28  Daniel Bates  <dabates@apple.com>
67357
67358        SubresourceLoader::didFinishLoading() should not assert when a decode error occurs
67359        https://bugs.webkit.org/show_bug.cgi?id=127029
67360
67361        Reviewed by Darin Adler.
67362
67363        SubresourceLoader::didFinishLoading() can be called for a resource (e.g. an image) that
67364        failed to be decoded or, in the case of an image, whose estimated decoded size exceeds
67365        the maximum decoded size (Settings::maximumDecodedImageSize()).
67366
67367        Test: fast/images/decoded-size-exceeds-max-decoded-size.html
67368
67369        * loader/SubresourceLoader.cpp:
67370        (WebCore::SubresourceLoader::didFinishLoading):
67371
673722014-02-28  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
67373
67374        ASSERTION FAILED: roundedIntPoint(rendererMappedResult) == roundedIntPoint(result) in WebCore::RenderGeometryMap::mapToContainer
67375        https://bugs.webkit.org/show_bug.cgi?id=119626
67376
67377        SVGRenderSupport::mapLocalToContainer() was trying to apply transforms
67378        in the incorrect order. Specifically, it would attempt to apply its
67379        localToParentTransform before its localToBorderBoxTransform. This
67380        was causing an ASSERT to fail when the computed transforms didn't
67381        match up to those computed by RenderGeometryMap.
67382
67383        Backported from Blink: https://codereview.chromium.org/143363004
67384
67385        Reviewed by Simon Fraser.
67386
67387        Test: svg/transforms/svg-geometry-crash.html
67388
67389        * rendering/svg/SVGRenderSupport.cpp:
67390        (WebCore::SVGRenderSupport::mapLocalToContainer):
67391
673922014-02-28  Mihnea Ovidenie  <mihnea@adobe.com>
67393
67394        [CSSRegions] ASSERTION FAILED: !m_regionsInvalidated in RenderFlowThread::regionAtBlockOffset
67395        https://bugs.webkit.org/show_bug.cgi?id=129371
67396
67397        Reviewed by Andrei Bucur.
67398
67399        regionAtBlockOffset method is meant to be used after the flow thread validated
67400        its region chain, otherwise we cannot rely on regionAtBlockOffset to determine correctly
67401        the target region based on the offset in flow thread coordinates.
67402
67403        When the video element is collected in a named flow and displayed in a region, we ensure
67404        that the region's decorations are taken into account to properly position the video.
67405        However, we have to do that only if the named flow regions are validated.
67406
67407        I changed the method cachedRegionForCompositedLayer to check only the "cached" region
67408        for a layer and not update the layer to region mappings before returning the region.
67409        Because method cachedRegionForCompositedLayer does not update the region - layer mappings,
67410        the code does not call regionAtBlockOffset in situations where the region chain is not validated yet.
67411
67412        Test: compositing/regions/video-in-overflow-region.html
67413
67414        * rendering/RenderFlowThread.cpp:
67415        (WebCore::RenderFlowThread::getLayerListForRegion): Make it a getter that relies on
67416        cached information and refrain from updating the mappings. Make it const too.
67417        (WebCore::RenderFlowThread::cachedRegionForCompositedLayer):
67418        * rendering/RenderFlowThread.h:
67419
674202014-02-28  Xabier Rodriguez Calvar  <calvaris@igalia.com>
67421
67422        [GTK] Finetune captions menu as per design team
67423        https://bugs.webkit.org/show_bug.cgi?id=129432
67424
67425        Reviewed by Eric Carlson.
67426
67427        Some design fine tuning of the captions dialog was required.
67428        
67429        No new tests, current suffice.
67430
67431        * Modules/mediacontrols/mediaControlsApple.js:
67432        Added out class.
67433        * Modules/mediacontrols/mediaControlsGtk.js:
67434        (ControllerGtk.prototype.buildCaptionMenu): Setting out class when
67435        menu is going to show overlap the panel right border.
67436        * css/mediaControlsGtk.css:
67437        (video::-webkit-media-controls-closed-captions-container.out):
67438        Setting all borders to 5px;
67439        (video::-webkit-media-controls-closed-captions-container h3):
67440        Reduced font size and increasing top padding.
67441        (video::-webkit-media-controls-closed-captions-container ul):
67442        Increased top padding.
67443
674442014-02-27  Ryosuke Niwa  <rniwa@webkit.org>
67445
67446        Element::attributeChanged shouldn't do any work when attribute value didn't change
67447        https://bugs.webkit.org/show_bug.cgi?id=129467
67448
67449        Reviewed by Geoffrey Garen.
67450
67451        Exit early in childrenChanged when the attribute value didn't change.
67452
67453        * dom/Attr.cpp:
67454        (WebCore::Attr::setValue):
67455        (WebCore::Attr::childrenChanged):
67456        * dom/Element.cpp:
67457        (WebCore::Element::setAttributeInternal):
67458        (WebCore::Element::attributeChanged):
67459        (WebCore::Element::parserSetAttributes):
67460        (WebCore::Element::removeAttributeInternal):
67461        (WebCore::Element::didAddAttribute):
67462        (WebCore::Element::didModifyAttribute):
67463        (WebCore::Element::didRemoveAttribute):
67464        (WebCore::Element::cloneAttributesFromElement):
67465        * dom/Element.h:
67466        * dom/StyledElement.cpp:
67467        (WebCore::StyledElement::attributeChanged):
67468        * dom/StyledElement.h:
67469        * html/HTMLInputElement.cpp:
67470        (WebCore::HTMLInputElement::updateType):
67471        * mathml/MathMLElement.cpp:
67472        (WebCore::MathMLElement::attributeChanged):
67473        * mathml/MathMLElement.h:
67474        * mathml/MathMLSelectElement.cpp:
67475        (WebCore::MathMLSelectElement::attributeChanged):
67476        * mathml/MathMLSelectElement.h:
67477        * svg/SVGElement.cpp:
67478        (WebCore::SVGElement::attributeChanged):
67479        * svg/SVGElement.h:
67480
674812014-02-27  Jinwoo Song  <jinwoo7.song@samsung.com>
67482
67483        [EFL] Remove duplicated keyboard string key from keyMap
67484        https://bugs.webkit.org/show_bug.cgi?id=129469
67485
67486        Reviewed by Gyuyoung Kim.
67487
67488        "Down" key is duplicated in keyMap().
67489
67490        * platform/efl/EflKeyboardUtilities.cpp:
67491        (WebCore::createKeyMap):
67492
674932014-02-27  Benjamin Poulain  <benjamin@webkit.org>
67494
67495        Unify the three call sites of SelectorQueryCache
67496        https://bugs.webkit.org/show_bug.cgi?id=129249
67497
67498        Reviewed by Andreas Kling.
67499
67500        The three call sites of SelectorQueryCache were doing the exact same thing.
67501        That code is mvoed to a new function Document::selectorQueryForString().
67502
67503        Also use String instead of AtomicString for querySelector() and querySelectorAll().
67504        This prevent the call sites from creating AtomicString just for the time of the call.
67505        This causes a tiny slow down on microbenchmarks that continuously query the same string
67506        but has no negative impact on realistic/good test cases (and the bindings are simplified).
67507
67508        * dom/ContainerNode.cpp:
67509        (WebCore::ContainerNode::querySelector):
67510        (WebCore::ContainerNode::querySelectorAll):
67511        * dom/ContainerNode.h:
67512        * dom/Document.cpp:
67513        (WebCore::Document::selectorQueryForString):
67514        * dom/Document.h:
67515        * dom/Element.cpp:
67516        (WebCore::Element::webkitMatchesSelector):
67517        * dom/SelectorQuery.cpp:
67518        (WebCore::SelectorQueryCache::add):
67519        * dom/SelectorQuery.h:
67520
675212014-02-27  Ryosuke Niwa  <rniwa@webkit.org>
67522
67523        JSC ignores the extra memory cost of HTMLCollection after a major GC
67524        https://bugs.webkit.org/show_bug.cgi?id=129450
67525
67526        Reviewed by Andreas Kling.
67527
67528        Report the extra memory cost of HTMLCollection to JSC.
67529
67530        Unfortunately, the existing mechanism to report the extra memory cost in toJS is insufficient for
67531        HTMLCollection since collection caches are populated later when HTMLCollection is accessed. Also,
67532        the extra memory cost reported by Heap::reportExtraMemoryCost will be thrown away after a major GC.
67533
67534        To work around this limitation, added a visitor.reportExtraMemoryUsage call inside visitChildren
67535        for interfaces with a newly added ReportExtraMemoryCost IDL extension flag to report the extra cost.
67536
67537        Since we may need to generate visitChildren when this flag is set, we can't automatically detect
67538        and generate calls using C++ template as done in r148648.
67539
67540        * CMakeLists.txt:
67541        * GNUmakefile.list.am:
67542        * Modules/webaudio/AudioBuffer.idl:
67543        * WebCore.vcxproj/WebCore.vcxproj:
67544        * WebCore.xcodeproj/project.pbxproj:
67545        * bindings/js/JSDOMBinding.h:
67546        * bindings/scripts/CodeGeneratorJS.pm:
67547        (InstanceNeedsVisitChildren):
67548        (GenerateHeader):
67549        (GenerateImplementation):
67550        * bindings/scripts/IDLAttributes.txt:
67551        * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
67552        (WebCore::toJS):
67553        * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
67554        (WebCore::toJS):
67555        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
67556        (WebCore::toJS):
67557        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
67558        (WebCore::toJS):
67559        * bindings/scripts/test/JS/JSTestException.cpp:
67560        (WebCore::toJS):
67561        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
67562        (WebCore::toJS):
67563        * bindings/scripts/test/JS/JSTestInterface.cpp:
67564        (WebCore::toJS):
67565        * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
67566        (WebCore::toJS):
67567        * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
67568        (WebCore::toJS):
67569        * bindings/scripts/test/JS/JSTestObj.cpp:
67570        (WebCore::toJS):
67571        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
67572        (WebCore::toJS):
67573        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
67574        (WebCore::toJS):
67575        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
67576        (WebCore::toJS):
67577        * bindings/scripts/test/JS/JSattribute.cpp:
67578        (WebCore::toJS):
67579        * bindings/scripts/test/JS/JSreadonly.cpp:
67580        (WebCore::toJS):
67581        * dom/ChildNodeList.h:
67582        * dom/CollectionIndexCache.cpp: Added.
67583        (WebCore::reportExtraMemoryCostForCollectionIndexCache):
67584        * dom/CollectionIndexCache.h:
67585        (WebCore::CollectionIndexCache::memoryCost):
67586        (WebCore::NodeType>::CollectionIndexCache):
67587        (WebCore::NodeType>::nodeCount):
67588        (WebCore::NodeType>::computeNodeCountUpdatingListCache):
67589        (WebCore::NodeType>::nodeAt):
67590        (WebCore::NodeType>::invalidate):
67591        * dom/DOMAllInOne.cpp:
67592        * dom/LiveNodeList.cpp:
67593        (WebCore::LiveNodeList::memoryCost):
67594        * dom/LiveNodeList.h:
67595        * dom/NodeList.h:
67596        (WebCore::NodeList::memoryCost):
67597        * dom/NodeList.idl:
67598        * html/HTMLCollection.cpp:
67599        (WebCore::HTMLCollection::updateNamedElementCache):
67600        * html/HTMLCollection.h:
67601        (WebCore::CollectionNamedElementCache::didPopulate):
67602        (WebCore::CollectionNamedElementCache::memoryCost):
67603        (WebCore::CollectionNamedElementCache::find):
67604        (WebCore::HTMLCollection::memoryCost):
67605        * html/HTMLCollection.idl:
67606        * html/HTMLFormControlsCollection.cpp:
67607        (WebCore::HTMLFormControlsCollection::updateNamedElementCache):
67608
676092014-02-27  Benjamin Poulain  <benjamin@webkit.org>
67610
67611        Compile attribute value matching
67612        https://bugs.webkit.org/show_bug.cgi?id=129228
67613
67614        Reviewed by Geoffrey Garen.
67615
67616        Add support for compiling value matching when matching attributes in Selector.
67617        This patch only adds exact matching, the other cases will follow.
67618
67619        There is a little infrastructure changes since FunctionCall now needs to support
67620        calls taking 2 arguments. The fun begins when the arguments are not in the right
67621        registers and need to be moved to the right place. Otherwise the code is straightforward.
67622
67623        In SelectorCompiler, it is necessary to handle two different cases of matching: case sensitive
67624        and case insensitive. The choice is done in part at compilation time by asking HTMLDocument
67625        if the name filter can include case insensitive attribute. The other part is done at runtime
67626        by querying the element for its type and document.
67627
67628        Test: fast/selectors/case-insensitive-value-matching.html
67629
67630        * css/SelectorChecker.cpp:
67631        (WebCore::attributeValueMatches): Null values matching should never happen, when an attribute
67632        has no value, its value is empty.
67633
67634        * cssjit/FunctionCall.h:
67635        (WebCore::FunctionCall::FunctionCall):
67636        Add support for calls with two arguments.
67637        (WebCore::FunctionCall::setOneArgument):
67638        (WebCore::FunctionCall::setTwoArguments):
67639        (WebCore::FunctionCall::swapArguments):
67640        Here we need to swap two registers, but we cannot allocate a new register (because the context
67641        of the function call may have taken all the available registers already).
67642
67643        On x86, the solution is simple, we can swap the two registers without side effects.
67644
67645        On other platforms, it is a little more complex. If there is any available register, we can just
67646        use it as a temporary to make the swap.
67647        If there are no available registers, we know that all the registers are taken. Since swapArguments()
67648        was called after pushing all the arguments on the stack, we can safely trash the value of any of those.
67649        We take the first available register that is not a function argument and use it as a temporary.
67650
67651        (WebCore::FunctionCall::prepareAndCall):
67652        This is the fun part, we have two registers where the values must go before the function call. The values
67653        can be in any combination of the allocated registers. The code here needs to move the two values to
67654        their target register while avoiding conflicts.
67655
67656        * cssjit/SelectorCompiler.cpp:
67657        (WebCore::SelectorCompiler::AttributeMatchingInfo::AttributeMatchingInfo):
67658        (WebCore::SelectorCompiler::AttributeMatchingInfo::canDefaultToCaseSensitiveValueMatch):
67659        (WebCore::SelectorCompiler::AttributeMatchingInfo::selector):
67660        The value of HTMLDocument::isCaseSensitiveAttribute is needed at compilation time to compute the number
67661        of required registers. As a result, we need to keep it along in the selector fragment.
67662
67663        (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
67664        (WebCore::SelectorCompiler::attributeNameTestingRequiresNamespaceRegister):
67665        (WebCore::SelectorCompiler::attributeValueTestingRequiresExtraRegister):
67666        (WebCore::SelectorCompiler::minimumRegisterRequirements):
67667        (WebCore::SelectorCompiler::SelectorCodeGenerator::markParentElementIfResolvingStyle):
67668        (WebCore::SelectorCompiler::canMatchStyleAttribute):
67669        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSynchronizeStyleAttribute):
67670        (WebCore::SelectorCompiler::canMatchAnimatableSVGAttribute):
67671        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSynchronizeAllAnimatedSVGAttribute):
67672        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeMatching):
67673        The matching code is moved in a local scope. This is done to recover the register of qualifiedNameImpl
67674        before doing any value matching. That register can then be used to store the expected value when matching
67675        an attribute value.
67676        It is unfortunate there is so much register pressure in this part.
67677
67678        Value matching is done outside the loop. The idea is to keep the loop really small since in the vast majority
67679        of cases, name matching fails.
67680        If the value matching fails, we jump back into the tight loop.
67681
67682        This is not ideal in all situation. For example trivial name matching with trivial value matching should
67683        be done in loop. There is a FIXME to improve those cases later.
67684
67685        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueMatching):
67686        (WebCore::SelectorCompiler::testIsHTMLClassOnDocument):
67687        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementAttributeValueExactMatching):
67688        In the case sensitive branch, things are really simple. We have to AtomicStringImpl pointers, if they
67689        don't match, it is a failure.
67690
67691        The case sensitive branch start by comparing the pointers in case the values are equal. This is a common
67692        case and it simplifies the cases for SVG, XHTML, etc.
67693        If the two values are not equal, we must first find if the context requires case insensitive comparison
67694        (HTMLElement in HTMLDocument). If the conditions require case insensitive matching, we then fall back
67695        to a function call.
67696
67697        (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementFunctionCallTest):
67698        * dom/Attribute.h:
67699        (WebCore::Attribute::valueMemoryOffset):
67700        * dom/Document.h:
67701        (WebCore::Document::documentClassesMemoryOffset):
67702        (WebCore::Document::isHTMLDocumentClassFlag):
67703        * dom/Node.h:
67704        (WebCore::Node::treeScopeMemoryOffset):
67705        * dom/TreeScope.h:
67706        (WebCore::TreeScope::documentScopeMemoryOffset):
67707
677082014-02-27  Ryuan Choi  <ryuan.choi@samsung.com>
67709
67710        Build break when disabled CSS_GRID_LAYOUT
67711        https://bugs.webkit.org/show_bug.cgi?id=129459
67712
67713        Reviewed by Gyuyoung Kim.
67714
67715        * css/CSSValue.h: Added guards of CSS_GRID_LAYOUT for GridTemplateAreasClass.
67716
677172014-02-17  Myles C. Maxfield  <mmaxfield@apple.com>
67718
67719        text-decoration-skip: ink does not skip over SVG fonts
67720        https://bugs.webkit.org/show_bug.cgi?id=128936
67721
67722        Reviewed by Darin Adler.
67723
67724        When drawing glyphs in an SVG font, the glyphs are converted to paths and then filled. This patch moves
67725        the glyph -> path conversion into a helper class, GlyphToPathTranslator, and creates an implementation
67726        for the SVG drawing code. Once this helper class is created, it can be used to trace paths in order
67727        to make underlines skip over SVG glyphs. This helper class also has an implementation for non-SVG glyphs,
67728        which allows for the glyph tracing code to be paramaterized over the implementation of the helper class
67729        rather than if the FontData itself is SVG or not.
67730
67731        Tests: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-ink-svg.html
67732
67733        * platform/graphics/Font.h:
67734        (WebCore::GlyphToPathTranslator::~GlyphToPathTranslator): Virtual implementation of helper class
67735        * platform/graphics/cg/PathCG.cpp:
67736        (WebCore::Path::Path): Created constructor that takes a RefPtr<CGMutablePathRef>
67737        * platform/graphics/Path.h:
67738        * platform/graphics/TextRun.h: Give RenderingContext a factory function to create the helper class
67739        instance
67740        * platform/graphics/mac/FontMac.mm: Implementation of helper class used for skipping underlines on
67741        regular (CoreText) glyphs
67742        (WebCore::MacGlyphToPathTranslator::MacGlyphToPathTranslator):
67743        (WebCore::MacGlyphToPathTranslator::moveToNextValidGlyph):
67744        (WebCore::MacGlyphToPathTranslator::incrementIndex):
67745        (WebCore::Font::dashesForIntersectionsWithRect): Call the relevant factory function, and use it
67746        to successively generate Paths
67747        * rendering/svg/SVGTextRunRenderingContext.cpp: Implementation of helper class used for SVG fonts
67748        (WebCore::SVGGlyphToPathTranslator::SVGGlyphToPathTranslator):
67749        (WebCore::SVGGlyphToPathTranslator::moveToNextValidGlyph):
67750        (WebCore::SVGGlyphToPathTranslator::incrementIndex):
67751        (WebCore::SVGTextRunRenderingContext::createGlyphToPathTranslator):
67752        (WebCore::SVGTextRunRenderingContext::drawSVGGlyphs): Use the above implementation
67753        * rendering/svg/SVGTextRunRenderingContext.h: Factory function declaration
67754
677552014-02-27  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
67756
67757        [WebRTC] Removing MediaConstraints argument from RTCPeerConnection addStream, updateIce methods and constructor
67758        https://bugs.webkit.org/show_bug.cgi?id=129449
67759
67760        Reviewed by Eric Carlson.
67761
67762        According to WebRTC editor's draft, MediaConstraints will no longer be an argument of those methods and
67763        constructor.
67764
67765        Existing tests were updated.
67766
67767        * Modules/mediastream/RTCPeerConnection.cpp:
67768        (WebCore::RTCPeerConnection::create):
67769        (WebCore::RTCPeerConnection::RTCPeerConnection):
67770        (WebCore::RTCPeerConnection::updateIce):
67771        (WebCore::RTCPeerConnection::addStream):
67772        * Modules/mediastream/RTCPeerConnection.h:
67773        * Modules/mediastream/RTCPeerConnection.idl:
67774        * bindings/js/JSRTCPeerConnectionCustom.cpp:
67775        (WebCore::JSRTCPeerConnectionConstructor::constructJSRTCPeerConnection):
67776        * platform/mediastream/RTCPeerConnectionHandler.h:
67777        * platform/mock/RTCPeerConnectionHandlerMock.cpp:
67778        (WebCore::RTCPeerConnectionHandlerMock::initialize):
67779        (WebCore::RTCPeerConnectionHandlerMock::updateIce):
67780        (WebCore::RTCPeerConnectionHandlerMock::addStream):
67781        * platform/mock/RTCPeerConnectionHandlerMock.h:
67782
677832014-02-27  Radu Stavila  <stavila@adobe.com>
67784
67785        [CSS Regions] Move named-flow specific method decorationsClipRectForBoxInRegion to RenderNamedFlowThread
67786        https://bugs.webkit.org/show_bug.cgi?id=129428
67787
67788        Reviewed by Andreas Kling.
67789
67790        Since the decorationsClipRectForBoxInRegion method is a named flow specific method, it makes
67791        sense to be in the named flow specific class, RenderNamedFlowThread, instead of the more
67792        generic RenderFlowThread.
67793
67794        No new tests required. No new functionality.
67795
67796        * rendering/RenderBlock.cpp:
67797        (WebCore::RenderBlock::paintObject):
67798        * rendering/RenderFlowThread.cpp:
67799        * rendering/RenderFlowThread.h:
67800        * rendering/RenderNamedFlowThread.cpp:
67801        (WebCore::RenderNamedFlowThread::decorationsClipRectForBoxInNamedFlowFragment):
67802        * rendering/RenderNamedFlowThread.h:
67803
678042014-02-27  Zoltan Horvath  <zoltan@webkit.org>
67805
67806        Avoid calling logicalLeftOffsetForLine 2 times in LineWidth::fitBelowFloats
67807        https://bugs.webkit.org/show_bug.cgi?id=129433
67808
67809        Reviewed by Darin Adler.
67810
67811        This change updates fitBelowFloats and its helpers to call RenderBlock::logicalLeftOffsetForLine only once.
67812
67813        No new tests, no behavior change.
67814
67815        * rendering/line/LineWidth.cpp:
67816        (WebCore::availableWidthAtOffset):
67817        (WebCore::LineWidth::updateLineDimension):
67818        (WebCore::LineWidth::wrapNextToShapeOutside):
67819        (WebCore::LineWidth::fitBelowFloats):
67820        * rendering/line/LineWidth.h:
67821
678222014-02-27  Andreas Kling  <akling@apple.com>
67823
67824        Micro-optimize elementAffectsDirectionality().
67825        <https://webkit.org/b/129444>
67826
67827        Tweak this function to skip an unnecessary bit check and use
67828        fastHasAttribute() instead of hasAttribute() for looking up dirAttr.
67829
67830        ~1% speedup on DYEB/AngularJS.
67831
67832        Reviewed by Ryosuke Niwa.
67833
67834        * html/HTMLElement.cpp:
67835        (WebCore::elementAffectsDirectionality):
67836
678372014-02-27  Brian Burg  <bburg@apple.com>
67838
67839        Web Inspector: model tests should use a special Test.html inspector page
67840        https://bugs.webkit.org/show_bug.cgi?id=129190
67841
67842        Reviewed by Timothy Hatcher.
67843
67844        Convert InspectorController::isUnderTest() into a flag, and expose an
67845        Internals method so it can be set by the test before opening the inspector.
67846
67847        Test: inspector/test-harness-trivially-works.html
67848
67849        * inspector/InspectorController.cpp:
67850        (WebCore::InspectorController::evaluateForTestInFrontend):
67851        * inspector/InspectorController.h:
67852        * testing/Internals.cpp:
67853        (WebCore::Internals::setInspectorIsUnderTest): Added.
67854        * testing/Internals.h:
67855        * testing/Internals.idl:
67856
678572014-02-27  Joseph Pecoraro  <pecoraro@apple.com>
67858
67859        Unreviewed build fix after r164824.
67860
67861        Accidentally re-added some code that was removed.
67862
67863        * page/ContentSecurityPolicy.cpp:
67864
678652014-02-26  Alex Christensen  <achristensen@webkit.org>
67866
67867        Compile fix when not using TEXTURE_MAPPER_GL.
67868        https://bugs.webkit.org/show_bug.cgi?id=129417
67869
67870        Reviewed by Darin Adler.
67871
67872        * platform/graphics/texmap/TextureMapperGL.cpp:
67873        Protect platformCreateAccelerated with USE(TEXTURE_MAPPER_GL).
67874
678752014-02-27  Joseph Pecoraro  <pecoraro@apple.com>
67876
67877        Web Inspector: JSContext inspection should report exceptions in the console
67878        https://bugs.webkit.org/show_bug.cgi?id=128776
67879
67880        Reviewed by Timothy Hatcher.
67881
67882        Include some clean up of ConsoleMessage and ScriptCallStack construction.
67883
67884        Covered by existing tests.
67885
67886        * bindings/js/JSDOMBinding.cpp:
67887        (WebCore::reportException):
67888        Simplify code now that createStackTraceFromException handles it.
67889
67890        * page/ContentSecurityPolicy.cpp:
67891        (WebCore::gatherSecurityPolicyViolationEventData):
67892        (WebCore::ContentSecurityPolicy::reportViolation):
67893        ScriptCallStack can give us the first non-native callframe.
67894
67895        * inspector/InspectorResourceAgent.cpp:
67896        (WebCore::InspectorResourceAgent::buildInitiatorObject):
67897        * inspector/PageDebuggerAgent.cpp:
67898        (WebCore::PageDebuggerAgent::breakpointActionLog):
67899        * inspector/TimelineRecordFactory.cpp:
67900        (WebCore::TimelineRecordFactory::createGenericRecord):
67901        * page/Console.cpp:
67902        (WebCore::internalAddMessage):
67903        (WebCore::Console::profile):
67904        (WebCore::Console::profileEnd):
67905        (WebCore::Console::timeEnd):
67906        * page/ContentSecurityPolicy.cpp:
67907        (WebCore::gatherSecurityPolicyViolationEventData):
67908        (WebCore::ContentSecurityPolicy::reportViolation):
67909        * page/DOMWindow.cpp:
67910        (WebCore::DOMWindow::postMessage):
67911
679122014-02-27  Andreas Kling  <akling@apple.com>
67913
67914        Remove FeatureObserver.
67915        <https://webkit.org/b/129439>
67916
67917        This code was only used by the Chromium port and nobody else is
67918        making use of it.
67919
67920        Reviewed by Anders Carlsson.
67921
67922        * CMakeLists.txt:
67923        * GNUmakefile.list.am:
67924        * WebCore.vcxproj/WebCore.vcxproj:
67925        * WebCore.vcxproj/WebCore.vcxproj.filters:
67926        * WebCore.xcodeproj/project.pbxproj:
67927        * dom/EventTarget.cpp:
67928        (WebCore::EventTarget::fireEventListeners):
67929        * dom/EventTarget.h:
67930        * html/ColorInputType.cpp:
67931        * html/ColorInputType.h:
67932        * html/DateInputType.cpp:
67933        * html/DateInputType.h:
67934        * html/DateTimeInputType.cpp:
67935        * html/DateTimeInputType.h:
67936        * html/DateTimeLocalInputType.cpp:
67937        * html/DateTimeLocalInputType.h:
67938        * html/EmailInputType.cpp:
67939        * html/EmailInputType.h:
67940        * html/HTMLDataListElement.cpp:
67941        (WebCore::HTMLDataListElement::create):
67942        * html/HTMLFormControlElement.cpp:
67943        (WebCore::HTMLFormControlElement::parseAttribute):
67944        * html/HTMLInputElement.cpp:
67945        (WebCore::HTMLInputElement::parseAttribute):
67946        * html/HTMLTextFormControlElement.cpp:
67947        (WebCore::HTMLTextFormControlElement::parseAttribute):
67948        * html/InputType.cpp:
67949        * html/InputType.h:
67950        * html/MonthInputType.cpp:
67951        * html/MonthInputType.h:
67952        * html/NumberInputType.cpp:
67953        * html/NumberInputType.h:
67954        * html/RangeInputType.cpp:
67955        * html/RangeInputType.h:
67956        * html/SearchInputType.cpp:
67957        * html/SearchInputType.h:
67958        * html/TelephoneInputType.cpp:
67959        * html/TelephoneInputType.h:
67960        * html/TextInputType.cpp:
67961        * html/TextInputType.h:
67962        * html/TimeInputType.cpp:
67963        * html/TimeInputType.h:
67964        * html/URLInputType.cpp:
67965        * html/URLInputType.h:
67966        * html/WeekInputType.cpp:
67967        * html/WeekInputType.h:
67968        * loader/DocumentLoader.cpp:
67969        (WebCore::DocumentLoader::responseReceived):
67970        * loader/FrameLoader.cpp:
67971        (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
67972        (WebCore::FrameLoader::dispatchDidCommitLoad):
67973        * page/ContentSecurityPolicy.cpp:
67974        (WebCore::ContentSecurityPolicy::didReceiveHeader):
67975        * page/EventHandler.cpp:
67976        (WebCore::EventHandler::selectCursor):
67977        * page/FeatureObserver.cpp: Removed.
67978        * page/FeatureObserver.h: Removed.
67979        * page/Page.h:
67980        * rendering/RenderDeprecatedFlexibleBox.cpp:
67981        (WebCore::RenderDeprecatedFlexibleBox::RenderDeprecatedFlexibleBox):
67982        * rendering/RenderLayer.cpp:
67983        (WebCore::RenderLayer::calculateClipRects):
67984        * workers/SharedWorker.cpp:
67985        (WebCore::SharedWorker::create):
67986        * workers/Worker.cpp:
67987        (WebCore::Worker::create):
67988
679892014-02-27  Chris Fleizach  <cfleizach@apple.com>
67990
67991        speechSynthesis.speak of a zero length utterance kills future speech
67992        https://bugs.webkit.org/show_bug.cgi?id=129403
67993
67994        Reviewed by Mario Sanchez Prada.
67995
67996        Empty length strings may choke a synthesizer and result in didFinishSpeaking not being called. 
67997        The WebKit code should be proactive about screening out empty length strings.
67998
67999        Test: platform/mac/fast/speechsynthesis/speech-synthesis-speak-empty-string.html
68000
68001        * Modules/speech/SpeechSynthesis.cpp:
68002        (WebCore::SpeechSynthesis::startSpeakingImmediately):
68003
680042014-02-27  Commit Queue  <commit-queue@webkit.org>
68005
68006        Unreviewed, rolling out r164783.
68007        http://trac.webkit.org/changeset/164783
68008        https://bugs.webkit.org/show_bug.cgi?id=129425
68009
68010        Broke number of multicol tests (Requested by anttik on
68011        #webkit).
68012
68013        * rendering/RenderBlock.cpp:
68014        (WebCore::RenderBlock::containingColumnsBlock):
68015
680162014-02-27  Antoine Quint  <graouts@webkit.org>
68017
68018        Respect SVG fragment identifiers in <img> src attribute
68019        https://bugs.webkit.org/show_bug.cgi?id=129387
68020
68021        Reviewed by Antti Koivisto.
68022
68023        Test: svg/css/svg-resource-fragment-identifier-img-src.html
68024
68025        When providing an SVG image for a given renderer, check that the URL used to load
68026        that image is taken into account in case it featured a fragment identifier, ensuring
68027        that the CSS :target pseudo-class is correctly handled for SVG resources. This patch
68028        is specific to <img> elements, specific support will also need to be added for various
68029        CSS properties that support SVG images.
68030
68031        * svg/graphics/SVGImageCache.cpp:
68032        (WebCore::SVGImageCache::imageForRenderer):
68033        Check if the provided renderer is attached to an <img> element and, if so, pass the
68034        resolved <img> source URL, taking into account srcset, to the SVGImageForContainer.
68035
68036        * svg/graphics/SVGImageForContainer.cpp:
68037        (WebCore::SVGImageForContainer::setURL):
68038        Trigger the FrameView machinery to ensure that the :target pseudo-class is respected
68039        should the provided URL feature a fragment identifier.
68040
68041        * svg/graphics/SVGImageForContainer.h:
68042        Declare the new setURL() method.
68043
680442014-02-27  Krzysztof Czech  <k.czech@samsung.com>
68045
68046        [ATK] Fix style errors in enum members
68047        https://bugs.webkit.org/show_bug.cgi?id=129421
68048
68049        Reviewed by Mario Sanchez Prada.
68050
68051        No new tests. No new functionality.
68052
68053        Enum members should use InterCaps with an initial capital letter.
68054
68055        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
68056        (getInterfaceMaskFromObject):
68057
680582014-02-27  Mihai Tica  <mitica@adobe.com>
68059
68060        [CSS Blending] Parse and implement the -webkit-isolation CSS property.
68061
68062        https://bugs.webkit.org/show_bug.cgi?id=128958
68063
68064        Reviewed by Dirk Schulze.
68065
68066        Parse and implement -webkit-isolation, part of the CSS Blending and Compositing spec.
68067        This patch adds functionality for HTML and SVG.
68068        -webkit-isolation: isolate restricts any child elements from blending with any of the content outside the isolated parent element.
68069
68070        Tests: css3/compositing/isolation-isolate-blended-child.html
68071               css3/compositing/isolation-parsing.html
68072               css3/compositing/svg-isolation-default.html
68073               css3/compositing/svg-isolation-isolated-group.html
68074               css3/compositing/svg-isolation-simple.html
68075
68076        * css/CSSComputedStyleDeclaration.cpp:
68077        (WebCore::ComputedStyleExtractor::propertyValue):
68078        * css/CSSParser.cpp:
68079        (WebCore::isValidKeywordPropertyAndValue):
68080        (WebCore::isKeywordPropertyID):
68081        (WebCore::CSSParser::parseValue):
68082        * css/CSSPrimitiveValueMappings.h:
68083        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
68084        (WebCore::CSSPrimitiveValue::operator Isolation):
68085        * css/CSSPropertyNames.in: Add -webkit-isolation.
68086        * css/CSSValueKeywords.in: Add the isolate value.
68087        * css/DeprecatedStyleBuilder.cpp:
68088        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
68089        * css/StyleResolver.cpp:
68090        (WebCore::StyleResolver::adjustRenderStyle): Explicitly set isolation:isolate to create a stacking context.
68091        * rendering/style/RenderStyle.cpp:
68092        (WebCore::RenderStyle::changeRequiresLayerRepaint): Changing isolation should trigger a repaint.
68093        * rendering/style/RenderStyle.h: Setters and getters for isolation.
68094        * rendering/style/RenderStyleConstants.h: Add Isolation enum.
68095        * rendering/style/StyleRareNonInheritedData.cpp: Add m_isolation.
68096        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
68097        (WebCore::StyleRareNonInheritedData::operator==):
68098        * rendering/style/StyleRareNonInheritedData.h:
68099        * rendering/svg/SVGRenderingContext.cpp:
68100        (WebCore::SVGRenderingContext::prepareToRenderSVGContent): If isolated, paint in a transparency layer.
68101
681022014-02-27  Krzysztof Czech  <k.czech@samsung.com>
68103
68104        [ATK] Utilize AtkTableCell to expose directly AccessibilityTableCell to AT
68105        https://bugs.webkit.org/show_bug.cgi?id=129250
68106
68107        Reviewed by Mario Sanchez Prada.
68108
68109        Test: accessibility/table-scope.html
68110
68111        Exposing AtkTableCell to AT. Implementing possibility to get column headers and row headers
68112        as an array of cells.
68113
68114        * GNUmakefile.list.am:
68115        * PlatformEfl.cmake:
68116        * accessibility/atk/WebKitAccessibleInterfaceTableCell.cpp: Added.
68117        (convertToGPtrArray):
68118        (core):
68119        (webkitAccessibleTableCellGetColumnHeaderCells):
68120        (webkitAccessibleTableCellGetRowHeaderCells):
68121        (webkitAccessibleTableCellInterfaceInit):
68122        * accessibility/atk/WebKitAccessibleInterfaceTableCell.h: Added.
68123        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
68124        (getInterfaceMaskFromObject):
68125
681262014-02-27  Renata Hodovan  <rhodovan.u-szeged@partner.samsung.com>
68127
68128        Improving containing column block determination
68129        https://bugs.webkit.org/show_bug.cgi?id=125449
68130
68131        Reviewed by Darin Adler.
68132
68133        Making sure that the containing column block of any elements
68134        can not be oneself.
68135
68136        Test: fast/css/crash-on-column-splitting.html
68137
68138        * rendering/RenderBlock.cpp:
68139        (WebCore::RenderBlock::containingColumnsBlock):
68140        (WebCore::RenderBlock::splitFlow):
68141
681422014-02-27  Xabier Rodriguez Calvar  <calvaris@igalia.com>
68143
68144        [GTK] Improve JavaScript multimedia controls
68145        https://bugs.webkit.org/show_bug.cgi?id=129044
68146
68147        Reviewed by Jer Noble.
68148
68149        After webkit.org/b/123097 a follow up was needed to improve
68150        accessibily and some other cosmetic problems, like cleaner CSS and
68151        new missing baselines.
68152
68153        No new tests because of no new functionality.
68154
68155        * Modules/mediacontrols/mediaControlsApple.js:
68156        Added hiding class name.
68157        * Modules/mediacontrols/mediaControlsGtk.js:
68158        (ControllerGtk.prototype.createControls): Set remaining time as
68159        hidden by default and turned volumebox hidden into hiding.
68160        (ControllerGtk.prototype.updateTime): Simplified the hiding and
68161        showing by removing the show class and using hidden only.
68162        (ControllerGtk.prototype.handleMuteButtonMouseOver):
68163        (ControllerGtk.prototype.handleVolumeBoxMouseOut): Turned hidden
68164        into hiding.
68165        (ControllerGtk.prototype.updateReadyState): Changed coding style
68166        and added down class for the panel too.
68167        (ControllerGtk.prototype.updatePlaying): Change for coding style
68168        coherence.
68169        (ControllerGtk.prototype.handleCaptionButtonClicked): Call
68170        handleCaptionButtonShowMenu.
68171        (ControllerGtk.prototype.handleCaptionButtonMouseOver): Call
68172        handleCaptionButtonShowMenu.
68173        (ControllerGtk.prototype.handleCaptionButtonShowMenu): Created
68174        with the former behavior of handleCaptionButtonMouseOver.
68175        * css/mediaControlsGtk.css:
68176        (.hidden): Set display none for all objects with hidden class.
68177        (audio::-webkit-media-controls-panel *:focus):
68178        (audio::-webkit-media-controls-panel.down *:focus): Added gradient
68179        for the active and focus status.
68180        (audio::-webkit-media-controls-time-remaining-display)
68181        (video::-webkit-media-controls-time-remaining-display): Set
68182        display block.
68183        (audio::-webkit-media-controls-volume-slider-container)
68184        (video::-webkit-media-controls-volume-slider-container): Set
68185        display flex.
68186        (video::-webkit-media-controls-volume-slider-container.hiding):
68187        Changed from hidden.
68188        (video::-webkit-media-controls-panel .hiding.down): Changed from
68189        hidden.
68190        * platform/gtk/RenderThemeGtk.cpp:
68191        (WebCore::RenderThemeGtk::paintMediaButton): Returning true to
68192        allow CSS painting the gradient.
68193
681942014-02-27  Zan Dobersek  <zdobersek@igalia.com>
68195
68196        Unreviewed. Fixing the GTK build fix after r164757.
68197
68198        * platform/network/NetworkStateNotifier.cpp: r164757 introduced a layering violation by including
68199        the Settings.h header. The use of that class is guarded by PLATFORM(IOS), so the header inclusion
68200        should be guarded as well.
68201
682022014-02-26  Ryosuke Niwa  <rniwa@webkit.org>
68203
68204        Extract named items caches in HTMLCollection as a class
68205        https://bugs.webkit.org/show_bug.cgi?id=129365
68206
68207        Reviewed by Antti Koivisto.
68208
68209        Extracted CollectionNamedElementCache, like CollectionIndexCache, out of HTMLCollection.
68210        We can move more named item related functions into this class in the future.
68211
68212        HTMLCollection's member variables m_isNameCacheValid, m_idCache, and m_nameCache were replaced by
68213        a single unique_ptr that holds an instance of CollectionNamedElementCache since this object rarely
68214        exists in most HTMLCollections.
68215
68216        Also removed m_isItemRefElementsCacheValid since it was only used by Microdata API removed in r153772
68217        and renamed a whole bunch of member functions and variables for consistency.
68218
68219        * dom/Document.cpp:
68220        (WebCore::Document::collectionCachedIdNameMap):
68221        (WebCore::Document::collectionWillClearIdNameMap):
68222        * dom/Document.h:
68223        * dom/NodeRareData.h:
68224        (WebCore::NodeListsNodeData::adoptDocument):
68225        * html/HTMLAllCollection.cpp:
68226        (WebCore::HTMLAllCollection::namedItemWithIndex):
68227        * html/HTMLCollection.cpp:
68228        (WebCore::HTMLCollection::HTMLCollection):
68229        (WebCore::HTMLCollection::~HTMLCollection):
68230        (WebCore::HTMLCollection::invalidateCache):
68231        (WebCore::HTMLCollection::invalidateNamedElementCache): Renamed from invalidateIdNameCacheMaps.
68232        (WebCore::HTMLCollection::namedItem):
68233        (WebCore::HTMLCollection::updateNamedElementCache): Renamed from updateNameCache.
68234        (WebCore::HTMLCollection::namedItems):
68235
68236        * html/HTMLCollection.h:
68237        (WebCore::CollectionNamedElementCache::findElementsWithId): Renamed from HTMLCollection::idCache.
68238        (WebCore::CollectionNamedElementCache::findElementsWithName): Renamed from HTMLCollection::nameCache.
68239        (WebCore::CollectionNamedElementCache::appendIdCache): Moved from HTMLCollection.
68240        (WebCore::CollectionNamedElementCache::appendNameCache): Ditto.
68241        (WebCore::CollectionNamedElementCache::find): Ditto.
68242        (WebCore::CollectionNamedElementCache::append): Ditto.
68243
68244        (WebCore::HTMLCollection::invalidateCache):
68245        (WebCore::HTMLCollection::hasNamedElementCache): Renamed from hasIdNameCache.
68246        (WebCore::HTMLCollection::createNameItemCache): Added.
68247        (WebCore::HTMLCollection::namedItemCaches): Added.
68248
68249        * html/HTMLFormControlsCollection.cpp:
68250        (WebCore::HTMLFormControlsCollection::updateNamedElementCache):
68251        * html/HTMLFormControlsCollection.h:
68252
682532014-02-26  Ryosuke Niwa  <rniwa@webkit.org>
68254
68255        Indenting an indented image element resulted in an extra indentation
68256        https://bugs.webkit.org/show_bug.cgi?id=129201
68257
68258        Reviewed by Enrica Casucci.
68259
68260        The bug was caused by endOfParagraph returning a position at the beginning of a block when the position
68261        passed into the function was at the beginning of the block. Consider the following DOM:
68262        <blockquote><img></blockquote>
68263
68264        When endOfParagraph is called on (blockquote, 0), the condition r->isBR() || isBlock(n) in endOfParagraph
68265        matches immediately on startNode and it returns (blockquote, 0) again.
68266
68267        This resulted in moveParagraphWithClones invoked by indentIntoBlockquote to erroneously clone the inner
68268        blockquote. Worked around this bug in ApplyBlockElementCommand::formatSelection by checking this specific
68269        condition and moving the position to the end of the block. Unfortunately, a lot of existing code depends
68270        on the current behavior of endOfParagraph so fixing the function itself was not possible.
68271
68272        There was another bug in indentIntoBlockquote to incorrectly insert a new blockquote into the existing
68273        blockquote due to the code introduced in r99594 to avoid inserting before the root editable element.
68274        Since this happens only if outerBlock is the root editable element, which is nodeToSplitTo or an ancestor
68275        of nodeToSplitTo, explicitly look for this condition.
68276
68277        Test: editing/execCommand/indent-img-twice.html
68278
68279        * editing/ApplyBlockElementCommand.cpp:
68280        (WebCore::ApplyBlockElementCommand::formatSelection):
68281        (WebCore::isNewLineAtPosition):
68282        * editing/IndentOutdentCommand.cpp:
68283        (WebCore::IndentOutdentCommand::indentIntoBlockquote):
68284        * editing/VisibleUnits.cpp:
68285        (WebCore::endOfParagraph): Added a FIXME.
68286
682872014-02-26  Simon Fraser  <simon.fraser@apple.com>
68288
68289        Fix two assertions/crashes in compositing code
68290        https://bugs.webkit.org/show_bug.cgi?id=129414
68291
68292        Reviewed by Dean Jackson.
68293
68294        Fix two issues introduced in r164759.
68295
68296        * rendering/RenderLayerCompositor.cpp:
68297        (WebCore::RenderLayerCompositor::removeFromScrollCoordinatedLayers): Don't call
68298        ourselves recursively!
68299        (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer): We call this
68300        function unconditionally on layer teardown, so this assertion is bogus.
68301
683022014-02-26  Simon Fraser  <simon.fraser@apple.com>
68303
68304        Fix the build with some compiler configurations.
68305
68306        * platform/mac/ScrollAnimatorMac.mm:
68307        (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
68308        (WebCore::ScrollAnimatorMac::didAddVerticalScrollbar):
68309        (WebCore::ScrollAnimatorMac::didAddHorizontalScrollbar):
68310
683112014-02-26  Myles C. Maxfield  <mmaxfield@apple.com>
68312
68313        Ranges given to createMarkupInternal might not be canonicalized
68314        https://bugs.webkit.org/show_bug.cgi?id=129408
68315
68316        Reviewed by Ryosuke Niwa.
68317
68318        When WebKit clients (such as Mail) call WKWebArchiveCreateFromRange() with a range,
68319        that range is not necessarily canonicalized. Therefore, comparing it for equality
68320        with a canonicalized range might return a false negative. Instead, we should compare
68321        canonicalized ranges.
68322
68323        No new tests because this codepath will only be reached via SPI.
68324
68325        * editing/markup.cpp:
68326        (WebCore::createMarkupInternal):
68327
683282014-02-26  Enrica Casucci  <enrica@apple.com>
68329
68330        [iOS WebKit2] Form controls handling: implement date and time controls.
68331        https://bugs.webkit.org/show_bug.cgi?id=129344
68332
68333        Reviewed by Simon Fraser and Joseph Pecoraro.
68334
68335        Adding one localizable string.
68336
68337        * English.lproj/Localizable.strings:
68338
683392014-02-26  Simon Fraser  <simon.fraser@apple.com>
68340
68341        Prepare for overflow scrolling nodes in the scrolling tree
68342        https://bugs.webkit.org/show_bug.cgi?id=129398
68343
68344        Reviewed by Tim Horton.
68345
68346        Lay some groundwork for overflow:scrolling nodes in the scrolling tree.
68347        Change terminology to refer to "scroll-coordinatored" layers now, not just viewport-constrained
68348        layers.
68349        
68350        A given layer can be both viewport-constrained and overflow-scrolling (e.g. position:fixed,
68351        overflow:scroll), so handle that in RenderLayerBacking, and use some "reason" flags
68352        in RenderLayerCompositor.
68353
68354        * page/FrameView.cpp:
68355        (WebCore::FrameView::scrollLayerID): Rename
68356        * page/scrolling/ScrollingStateTree.cpp:
68357        (WebCore::ScrollingStateTree::attachNode): Remove invalid assertion.
68358        * rendering/RenderLayerBacking.cpp:
68359        (WebCore::RenderLayerBacking::RenderLayerBacking):
68360        (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
68361        (WebCore::RenderLayerBacking::updateScrollingLayers): Simplify the logic with
68362        an early return.
68363        (WebCore::RenderLayerBacking::detachFromScrollingCoordinator):
68364        Allow a layer to play both viewport-constrained and scrolling roles
68365        in the scrolling tree.
68366        * rendering/RenderLayerBacking.h:
68367        (WebCore::RenderLayerBacking::viewportConstrainedNodeID):
68368        (WebCore::RenderLayerBacking::setViewportConstrainedNodeID):
68369        (WebCore::RenderLayerBacking::scrollingNodeID):
68370        (WebCore::RenderLayerBacking::setScrollingNodeID):
68371        (WebCore::RenderLayerBacking::scrollingNodeIDForChildren):
68372        * rendering/RenderLayerCompositor.cpp:
68373        (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
68374        (WebCore::RenderLayerCompositor::didFlushChangesForLayer):
68375        (WebCore::RenderLayerCompositor::updateBacking):
68376        (WebCore::RenderLayerCompositor::layerWillBeRemoved):
68377        (WebCore::RenderLayerCompositor::fixedRootBackgroundLayerChanged):
68378        (WebCore::RenderLayerCompositor::clearBackingForLayerIncludingDescendants):
68379        (WebCore::RenderLayerCompositor::requiresCompositingLayer):
68380        (WebCore::RenderLayerCompositor::requiresOwnBackingStore):
68381        (WebCore::RenderLayerCompositor::reasonsForCompositing):
68382        (WebCore::RenderLayerCompositor::requiresCompositingForScrolling):
68383        (WebCore::isViewportConstrainedFixedOrStickyLayer):
68384        (WebCore::isMainFrameScrollingOrOverflowScrolling):
68385        (WebCore::RenderLayerCompositor::rootLayerAttachmentChanged):
68386        (WebCore::RenderLayerCompositor::updateScrollCoordinatedStatus):
68387        (WebCore::RenderLayerCompositor::removeFromScrollCoordinatedLayers):
68388        (WebCore::nearestScrollCoordinatedAncestor):
68389        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
68390        (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer):
68391        (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
68392        (WebCore::RenderLayerCompositor::willRemoveScrollingLayer):
68393        (WebCore::RenderLayerCompositor::didAddScrollingLayer):
68394        * rendering/RenderLayerCompositor.h:
68395
683962014-02-26  Andy Estes  <aestes@apple.com>
68397
68398        [iOS] Support network state notification using CPNetworkObserver
68399        https://bugs.webkit.org/show_bug.cgi?id=129358
68400
68401        Reviewed by Dan Bernstein.
68402
68403        Add iOS support for navigator.onLine and online/offline events. Since
68404        it can be expensive to query CPNetworkObserver, wait to do so until
68405        someone calls NetworkStateObserver::onLine() or
68406        NetworkStateObserver::addNetworkStateChangeListener(). For clients that
68407        don't wish to observe network reachability at all, add a global opt-out.
68408        These clients will only pay the cost of CPNetworkObserver if they load
68409        a page that explicitly accesses navigator.onLine.
68410
68411        No new tests. Covered by existing tests.
68412
68413        * WebCore.exp.in: Stopped exporting NetworkStateNotifier::setIsOnLine()
68414        and started exporting Settings::gShouldOptOutOfNetworkStateObservation.
68415        * WebCore.xcodeproj/project.pbxproj: Renamed NetworkStateNotifierIOS.cpp
68416        to NetworkStateNotifierIOS.mm.
68417        * page/Settings.cpp: Defaulted gShouldOptOutOfNetworkStateObservation
68418        to false.
68419        * page/Settings.h:
68420        (WebCore::Settings::setShouldOptOutOfNetworkStateObservation):
68421        (WebCore::Settings::shouldOptOutOfNetworkStateObservation):
68422        * platform/network/NetworkStateNotifier.cpp:
68423        (WebCore::NetworkStateNotifier::addNetworkStateChangeListener): Ignored
68424        the listener if Settings::shouldOptOutOfNetworkStateObservation().
68425        Called registerObserverIfNecessary() and added the listener otherwise.
68426        (WebCore::NetworkStateNotifier::notifyNetworkStateChange): Const qualified.
68427        * platform/network/NetworkStateNotifier.h
68428        (NetworkStateNotifier::onLine):
68429        * platform/network/ios/NetworkStateNotifierIOS.cpp: Removed.
68430        * platform/network/ios/NetworkStateNotifierIOS.mm: Added.
68431        (-[NetworkStateObserver initWithNotifier:WebCore::]): Registered self
68432        as a network reachable observer on CPNetworkObserver.
68433        (-[NetworkStateObserver dealloc]): Removed self as a network reachable
68434        observer.
68435        (-[NetworkStateObserver networkStateChanged:]): Called setOnLine() on
68436        the web thread, passing the reachability value from the notification.
68437        (WebCore::NetworkStateNotifier::NetworkStateNotifier):
68438        (WebCore::NetworkStateNotifier::~NetworkStateNotifier): Cleared
68439        m_observer's pointer back to us.
68440        (WebCore::NetworkStateNotifier::registerObserverIfNecessary): Initialized
68441        m_observer if necessary.
68442        (WebCore::NetworkStateNotifier::onLine): Called
68443        registerObserverIfNecessary() and set an initial value for m_isOnLine
68444        if m_isOnLineInitialized is false. Returned m_isOnLine.
68445        (WebCore::setOnLine): Set m_isOnLine and called
68446        notifyNetworkStateChange() if needed. Unconditionally set
68447        m_isOnLineInitialized to true.
68448
684492014-02-26  Brian Burg  <bburg@apple.com>
68450
68451        Unreviewed build fix for !ENABLE(CONTEXT_MENUS).
68452
68453        I forgot to add guards to handleContextMenuEvent().
68454
68455        * replay/UserInputBridge.cpp:
68456        * replay/UserInputBridge.h:
68457
684582014-02-26  Dean Jackson  <dino@apple.com>
68459
68460        [WebGL] Only skip context error retrieval if a pending context
68461        https://bugs.webkit.org/show_bug.cgi?id=129397
68462
68463        Reviewed by Tim Horton.
68464
68465        A lost context should still ask the GC3D what the error is. Only
68466        a pending context should return early.
68467
68468        * html/canvas/WebGLRenderingContext.cpp:
68469        (WebCore::WebGLRenderingContext::getError):
68470
684712014-02-26  Brian Burg  <bburg@apple.com>
68472
68473        Web Replay: route through UserInputBridge when delivering user inputs to WebCore
68474        https://bugs.webkit.org/show_bug.cgi?id=128150
68475
68476        Reviewed by Timothy Hatcher.
68477
68478        Add an UserInputBridge instance to each Page. WebKit2 routes a page's user inputs through
68479        the WebCore page's user input bridge so that the inputs can be selectively captured, filtered,
68480        and replayed using instrumentation inside the UserInputBridge.
68481
68482        For now, the routing methods of UserInputBridge have no replay-specific code paths, and just
68483        put the input delivery code inside WebCore rather than its external clients. Replay-specific
68484        code paths will be added once https://bugs.webkit.org/show_bug.cgi?id=128782 is fixed. However,
68485        once complete the code will work as follows:
68486
68487        - When neither capturing or replaying, behavior is unchanged.
68488
68489        - When capturing user inputs, each external input is saved into a replay log as it crosses
68490        the bridge from outside WebCore.
68491
68492        - When replaying, the bridge closes and user inputs from WebKit2 are not accepted. Instead,
68493        the saved inputs from the replay log are re-dispatched as if they had crossed the bridge.
68494
68495        * CMakeLists.txt:
68496        * GNUmakefile.am:
68497        * GNUmakefile.list.am:
68498        * WebCore.exp.in: Add symbols for input routing methods.
68499        * WebCore.vcxproj/WebCore.vcxproj:
68500        * WebCore.vcxproj/WebCore.vcxproj.filters:
68501        * WebCore.xcodeproj/project.pbxproj:
68502        * page/Page.cpp:
68503        (WebCore::Page::Page): Initialize the owned UserInputBridge in the Page constructor.
68504        * page/Page.h:
68505        (WebCore::Page::inputBridge): Added a by-reference getter.
68506        * replay/UserInputBridge.cpp: Added.
68507        (WebCore::UserInputBridge::UserInputBridge):
68508        (WebCore::UserInputBridge::~UserInputBridge):
68509        (WebCore::UserInputBridge::handleContextMenuEvent):
68510        (WebCore::UserInputBridge::handleMousePressEvent):
68511        (WebCore::UserInputBridge::handleMouseReleaseEvent):
68512        (WebCore::UserInputBridge::handleMouseMoveEvent):
68513        (WebCore::UserInputBridge::handleMouseMoveOnScrollbarEvent):
68514        (WebCore::UserInputBridge::handleKeyEvent):
68515        (WebCore::UserInputBridge::handleAccessKeyEvent):
68516        (WebCore::UserInputBridge::handleWheelEvent):
68517        (WebCore::UserInputBridge::focusSetActive):
68518        (WebCore::UserInputBridge::focusSetFocused):
68519        (WebCore::UserInputBridge::scrollRecursively):
68520        (WebCore::UserInputBridge::logicalScrollRecursively):
68521        (WebCore::UserInputBridge::loadRequest):
68522        (WebCore::UserInputBridge::reloadFrame):
68523        (WebCore::UserInputBridge::stopLoadingFrame):
68524        (WebCore::UserInputBridge::tryClosePage):
68525        * replay/UserInputBridge.h: Added.
68526
685272014-02-26  Dean Jackson  <dino@apple.com>
68528
68529        [WebGL] Protect more WebGL entry points for pending contexts
68530        https://bugs.webkit.org/show_bug.cgi?id=129386
68531
68532        Reviewed by Tim Horton.
68533
68534        There are entry points into a WebGLRenderingContext that don't
68535        come from the web-exposed API directly, such as drawImage with
68536        the WebGL canvas. Protect these by returning early if we're
68537        a pending context.
68538
68539        Also a bunch of drive-by 0 -> nullptr changes.
68540
68541        * html/canvas/WebGLRenderingContext.cpp:
68542        (WebCore::WebGLRenderingContext::markLayerComposited):
68543        (WebCore::WebGLRenderingContext::paintRenderingResultsToCanvas):
68544        (WebCore::WebGLRenderingContext::paintRenderingResultsToImageData):
68545        (WebCore::WebGLRenderingContext::reshape):
68546        (WebCore::WebGLRenderingContext::createBuffer):
68547        (WebCore::WebGLRenderingContext::createFramebuffer):
68548        (WebCore::WebGLRenderingContext::createTexture):
68549        (WebCore::WebGLRenderingContext::createProgram):
68550        (WebCore::WebGLRenderingContext::createRenderbuffer):
68551        (WebCore::WebGLRenderingContext::createShader):
68552        (WebCore::WebGLRenderingContext::getActiveAttrib):
68553        (WebCore::WebGLRenderingContext::getActiveUniform):
68554        (WebCore::WebGLRenderingContext::getContextAttributes):
68555        (WebCore::WebGLRenderingContext::getError):
68556        (WebCore::WebGLRenderingContext::getExtension):
68557        (WebCore::WebGLRenderingContext::getShaderPrecisionFormat):
68558        (WebCore::WebGLRenderingContext::getUniformLocation):
68559        (WebCore::WebGLRenderingContext::drawImageIntoBuffer):
68560        (WebCore::WebGLRenderingContext::videoFrameToImage):
68561        (WebCore::WebGLRenderingContext::validateBufferDataParameters):
68562        (WebCore::WebGLRenderingContext::LRUImageBufferCache::imageBuffer):
68563
685642014-02-26  Bem Jones-Bey  <bjonesbe@adobe.com>
68565
68566        [CSS Shapes] inset and inset-rectangle trigger assert with replaced element and large percentage dimension
68567        https://bugs.webkit.org/show_bug.cgi?id=129060
68568
68569        Reviewed by Simon Fraser.
68570
68571        A bounds check was omitted when computing the width and height for inset
68572        rectangles, making it possible for the width or height to end up being
68573        negative. This patch adds in that check for both. It seems that only
68574        replaced elements like iframe and img trigger this problem.
68575
68576        Tests: fast/shapes/shape-outside-floats/shape-outside-floats-img-inset-negative-width-crash.html
68577               fast/shapes/shape-outside-floats/shape-outside-floats-img-inset-rectangle-negative-width-crash.html
68578
68579        * rendering/shapes/Shape.cpp:
68580        (WebCore::Shape::createShape):
68581
685822014-02-26  Myles C. Maxfield  <mmaxfield@apple.com>
68583
68584        Underlines are too thick when zoomed in
68585        https://bugs.webkit.org/show_bug.cgi?id=129352
68586
68587        Reviewed by Dean Jackson.
68588
68589        The input to the underline drawing code is in user-space, not device-space.
68590        The underlines were getting scaled twice, once in InlineTextBox and the other
68591        in GraphicsContext.
68592
68593        Test: fast/css3-text/css3-text-decoration/text-decoration-scaled.html
68594
68595        * rendering/InlineTextBox.cpp:
68596        (WebCore::InlineTextBox::paintDecoration):
68597
685982014-02-26  Andreas Kling  <akling@apple.com>
68599
68600        Remove unused InspectorCounters.
68601        <https://webkit.org/b/129367>
68602
68603        The InspectorCounters code was only used to implement two layout test
68604        APIs (window.internals.numberOfLive{Nodes,Documents}) yet it had hooks
68605        in crazy places like Node construction and destruction.
68606
68607        Rewrote the internals APIs to iterate over all live Documents instead,
68608        totaling up their referencing Node count. Added a process-global
68609        Document::allDocuments() HashSet to make this whole thing possible.
68610
68611        Reviewed by Sam Weinig.
68612
68613        * CMakeLists.txt:
68614        * GNUmakefile.list.am:
68615        * WebCore.exp.in:
68616        * WebCore.vcxproj/WebCore.vcxproj:
68617        * WebCore.vcxproj/WebCore.vcxproj.filters:
68618        * WebCore.xcodeproj/project.pbxproj:
68619        * bindings/js/JSEventListener.cpp:
68620        * dom/Document.cpp:
68621        (WebCore::Document::allDocuments):
68622        (WebCore::Document::Document):
68623        (WebCore::Document::~Document):
68624        * dom/Document.h:
68625        (WebCore::Node::Node):
68626        * dom/Node.cpp:
68627        (WebCore::Node::~Node):
68628        * inspector/InspectorAllInOne.cpp:
68629        * inspector/InspectorCounters.cpp: Removed.
68630        * inspector/InspectorCounters.h: Removed.
68631        * inspector/InspectorTimelineAgent.cpp:
68632        (WebCore::InspectorTimelineAgent::start):
68633        (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline):
68634        (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
68635        * inspector/InspectorTimelineAgent.h:
68636        * inspector/protocol/Timeline.json:
68637        * platform/ThreadGlobalData.cpp:
68638        * testing/Internals.cpp:
68639        (WebCore::Internals::numberOfLiveNodes):
68640        (WebCore::Internals::numberOfLiveDocuments):
68641        * testing/Internals.h:
68642        * testing/Internals.idl:
68643
686442014-02-26  Joseph Pecoraro  <pecoraro@apple.com>
68645
68646        Web Inspector: Remove console.profiles from window.console API
68647        https://bugs.webkit.org/show_bug.cgi?id=116883
68648
68649        Reviewed by Timothy Hatcher.
68650
68651        console.profiles has been removed or never implemented by other
68652        browsers. We should remove it as well. However, since tests
68653        rely on it, keep it as window.internals.consoleProfiles.
68654
68655        * WebCore.exp.in:
68656        * page/Console.idl:
68657        * testing/Internals.cpp:
68658        (WebCore::Internals::consoleProfiles):
68659        * testing/Internals.h:
68660        * testing/Internals.idl:
68661
686622014-02-26  Martin Hock  <mhock@apple.com>
68663
68664        Create SessionID value-style class for session IDs.
68665        https://bugs.webkit.org/show_bug.cgi?id=129141
68666
68667        Reviewed by Sam Weinig.
68668
68669        * GNUmakefile.list.am:
68670        * WebCore.exp.in:
68671        * WebCore.xcodeproj/project.pbxproj:
68672        * page/Page.cpp: Add SessionID member.
68673        (WebCore::Page::Page):
68674        (WebCore::Page::sessionID): Retrieve sessionID or use settings if not set.
68675        * page/Page.h:
68676        (WebCore::Page::isSessionIDSet):
68677        (WebCore::Page::setSessionID):
68678        * page/SessionID.h: Session ID class consisting solely of its uint64_t session ID.
68679        (WebCore::SessionID::SessionID):
68680        (WebCore::SessionID::isValid): Not empty.
68681        (WebCore::SessionID::isEphemeral):
68682        (WebCore::SessionID::sessionID):
68683        (WebCore::SessionID::operator==): Value-based equality.
68684        (WebCore::SessionID::operator!=):
68685        (WebCore::SessionID::emptySessionID): Zero value also used for HashTraits emptyValue.
68686        (WebCore::SessionID::defaultSessionID):
68687        (WebCore::SessionID::legacyPrivateSessionID):
68688        * page/SessionIDHash.h:
68689        (WTF::SessionIDHash::hash): Just the casted session ID (low order bytes)
68690        (WTF::SessionIDHash::equal):
68691        (WTF::HashTraits<WebCore::SessionID>::emptyValue): Equal to emptySessionID.
68692        (WTF::HashTraits<WebCore::SessionID>::constructDeletedValue): -1 value.
68693        (WTF::HashTraits<WebCore::SessionID>::isDeletedValue):
68694
686952014-02-26  Eric Carlson  <eric.carlson@apple.com>
68696
68697        Fix builds that don't define IMAGE_CONTROLS.
68698
68699        * page/ContextMenuContext.cpp:
68700        (WebCore::ContextMenuContext::ContextMenuContext):
68701
687022014-02-26  Eric Carlson  <eric.carlson@apple.com>
68703
68704        Build fix for OS X after r164720.
68705
68706        * page/ContextMenuContext.cpp:
68707
687082014-02-26  Brady Eidson  <beidson@apple.com>
68709
68710        Pipe experimental image controls menu up to WebKit2
68711        https://bugs.webkit.org/show_bug.cgi?id=129339
68712
68713        Reviewed by Simon Fraser.
68714
68715        Handle events for the image control, starting down the context menu code path if appropriate:
68716        * html/shadow/mac/ImageControlsRootElementMac.cpp:
68717        (WebCore::ImageControlsRootElementMac::defaultEventHandler):
68718        * html/shadow/mac/ImageControlsRootElementMac.h:
68719
68720        Add a class to hold a HitTestResult and addition info about the current ContextMenu invocation:
68721        * page/ContextMenuContext.cpp: Added.
68722        (WebCore::ContextMenuContext::ContextMenuContext):
68723        * page/ContextMenuContext.h: Added.
68724        (WebCore::ContextMenuContext::hitTestResult):
68725        (WebCore::ContextMenuContext::isImageControl):
68726
68727        Update ContextMenuController to work with ContextMenuContext instead of HitTestResult directly:
68728        * page/ContextMenuController.cpp:
68729        (WebCore::ContextMenuController::showContextMenu):
68730        (WebCore::ContextMenuController::createContextMenu):
68731        (WebCore::ContextMenuController::contextMenuItemSelected):
68732        (WebCore::ContextMenuController::populate):
68733        (WebCore::ContextMenuController::addInspectElementItem):
68734        (WebCore::ContextMenuController::checkOrEnableIfNeeded):
68735        (WebCore::ContextMenuController::showImageControlsMenu):
68736        * page/ContextMenuController.h:
68737        (WebCore::ContextMenuController::contextMenu):
68738        (WebCore::ContextMenuController::setContextMenuContext):
68739        (WebCore::ContextMenuController::context):
68740        (WebCore::ContextMenuController::hitTestResult):
68741
68742        * CMakeLists.txt:
68743        * GNUmakefile.list.am:
68744        * WebCore.vcxproj/WebCore.vcxproj:
68745        * WebCore.xcodeproj/project.pbxproj:
68746
687472014-02-26  Zan Dobersek  <zdobersek@igalia.com>
68748
68749        REGRESSION(r162947): Document::topDocument() returns an incorrect reference for cached Documents
68750        https://bugs.webkit.org/show_bug.cgi?id=128175
68751
68752        Reviewed by Antti Koivisto.
68753
68754        * dom/Document.cpp:
68755        (WebCore::Document::topDocument): Fall back to pre-r162947 way of determining the top document
68756        when the Document is in page cache or is in the middle of having its render tree destroyed.
68757        In the first case, the determined top document is actually the document currently loaded in the
68758        Frame to which the cached document is still connected, which is obviously not desired. In the
68759        second case the top document is similarly incorrectly deduced, leading to non-deletion of the
68760        proper top document's AXObjectCache. Because of this AccessibilityRenderObjects are not detached
68761        which results in assertions in RenderObject destructor where the objects are found to be still
68762        flagged as in use by the AX cache.
68763
687642014-02-26  Mihnea Ovidenie  <mihnea@adobe.com>
68765
68766        [CSSRegions] Remove unused method RenderFlowThread::updateLayerToRegionMappings()
68767        https://bugs.webkit.org/show_bug.cgi?id=129368
68768
68769        Reviewed by Andrei Bucur.
68770
68771        Remove unused code, no new tests.
68772
68773        * rendering/RenderFlowThread.h:
68774
687752014-02-26  Xabier Rodriguez Calvar  <calvaris@igalia.com>
68776
68777        [GTK] Regression when showing the captions menu
68778        https://bugs.webkit.org/show_bug.cgi?id=129106
68779
68780        Reviewed by Martin Robinson.
68781
68782        In some cases, when clicking the captions button the menu was not
68783        shown.
68784
68785        Updated test: media/video-controls-captions-trackmenu.html
68786
68787        * Modules/mediacontrols/mediaControlsGtk.js:
68788        (ControllerGtk.prototype.buildCaptionMenu):
68789        (ControllerGtk.prototype.showCaptionMenu): Specify sizes in
68790        pixels.
68791
687922014-02-26  Ryosuke Niwa  <rniwa@webkit.org>
68793
68794        Avoid unnecessary HTML Collection invalidations for id and name attribute changes
68795        https://bugs.webkit.org/show_bug.cgi?id=129361
68796
68797        Reviewed by Benjamin Poulain.
68798
68799        Before this patch, setting id and name attributes resulted in traversing all the ancestors to invalidate
68800        HTML collections on those nodes whenever we had more than one HTMLCollection alive.
68801
68802        Avoid the traversal when HTMLCollections don't have any valid id and name map caches by making each
68803        HTMLCollection explicitly call collectionCachedIdNameMap and collectionWillClearIdNameMap when it caches
68804        or clears the id and name map.
68805
68806        Inspired by https://chromium.googlesource.com/chromium/blink/+/5b06b91b79098f7d42e480f85be32198315d2440
68807
68808        * dom/Document.cpp:
68809        (WebCore::Document::registerCollection): Takes a boolean to indicate whether collection has a valid cache
68810        for the id and name map.
68811        (WebCore::Document::unregisterCollection): Ditto.
68812        (WebCore::Document::collectionCachedIdNameMap): Added.
68813        (WebCore::Document::collectionWillClearIdNameMap): Added.
68814        * dom/Document.h:
68815
68816        * dom/NodeRareData.h:
68817        (WebCore::NodeListsNodeData::adoptDocument): Call invalidateCache on HTML collections after, not before,
68818        calling unregisterCollection and registerCollection since collections' owner nodes have already been
68819        moved to the new document here and invalidateCache uses owner node's document to call
68820        collectionWillClearIdNameMap. So calling invalidateCache before calling unregister/registerCollection
68821        would result in collectionWillClearIdNameMap getting called on a wrong document.
68822
68823        * html/HTMLCollection.cpp:
68824        (WebCore::HTMLCollection::HTMLCollection):
68825        (WebCore::HTMLCollection::~HTMLCollection):
68826        (WebCore::HTMLCollection::invalidateCache):
68827        (WebCore::HTMLCollection::invalidateIdNameCacheMaps): Added the code to uncount itself from the number
68828        of live node lists and HTML collections that need to be invalidated upon id and name attribute changes.
68829        (WebCore::HTMLCollection::updateNameCache):
68830
68831        * html/HTMLCollection.h:
68832        (WebCore::HTMLCollection::invalidateCache):
68833        (WebCore::HTMLCollection::hasIdNameCache): Renamed from hasNameCache.
68834        (WebCore::HTMLCollection::setHasIdNameCache): Renamed from setHasIdNameCache.
68835
68836        * html/HTMLFormControlsCollection.cpp:
68837        (WebCore::HTMLFormControlsCollection::updateNameCache):
68838
688392014-02-25  Frédéric Wang  <fred.wang@free.fr>
68840
68841        Add support for minsize/maxsize attributes.
68842        https://bugs.webkit.org/show_bug.cgi?id=122567
68843
68844        Reviewed by Chris Fleizach.
68845
68846        This change implements the minsize/maxsize attributes of the mo element.
68847        We also switch stretch sizes from int to LayoutUnit to improve accuracy.
68848
68849        Tests: mathml/presentation/stretchy-minsize-maxsize-dynamic.html
68850               mathml/presentation/stretchy-minsize-maxsize.html
68851
68852        * rendering/mathml/RenderMathMLOperator.cpp:
68853        (WebCore::RenderMathMLOperator::SetOperatorProperties):
68854        (WebCore::RenderMathMLOperator::stretchTo):
68855        * rendering/mathml/RenderMathMLOperator.h:
68856        * rendering/mathml/RenderMathMLRow.cpp:
68857        (WebCore::RenderMathMLRow::layout):
68858
688592014-02-25  Mihnea Ovidenie  <mihnea@adobe.com>
68860
68861        [CSSRegions] Small clean-up of flow threads accelerated compositing code
68862        https://bugs.webkit.org/show_bug.cgi?id=129312
68863
68864        Reviewed by Andrei Bucur.
68865
68866        Some clean-up for the code used for regions in accelerated compositing functionality:
68867        1. Rename updateRenderFlowThreadLayersIfNeeded -> updateFlowThreadsLayerToRegionMappingsIfNeeded
68868        as the function updates the mapping between the flow threads layers and their corresponding regions
68869        2. Remove RenderLayerCompositor::updateRenderFlowThreadLayersIfNeeded and move the code in place
68870        at call site since the function body does not require a dedicated function.
68871
68872        No new functionality, no new tests.
68873
68874        * rendering/FlowThreadController.cpp:
68875        (WebCore::FlowThreadController::updateFlowThreadsLayerToRegionMappingsIfNeeded):
68876        Now that the regions are always layers, we do not need to iterate backwards.
68877        * rendering/FlowThreadController.h:
68878        * rendering/RenderLayerCompositor.cpp:
68879        (WebCore::RenderLayerCompositor::updateCompositingLayers):
68880        * rendering/RenderLayerCompositor.h:
68881
688822014-02-25  Zalan Bujtas  <zalan@apple.com>
68883
68884        Subpixel rendering: Ensure consistent border painting width.
68885        https://bugs.webkit.org/show_bug.cgi?id=129259
68886
68887        Reviewed by Simon Fraser.
68888
68889        Border edges are painted as (semi)independent rectangles. When snapping an edge rectangle
68890        to device pixels, its painted dimensions depend on its size and its fractional position.
68891        Specific combination of position and border width can result in painting edges sized differently.
68892        Using device snapped border width to calculate inner/outer rectangles helps to maintain
68893        uniform border width.
68894
68895        Currently not testable.
68896
68897        * rendering/RenderBoxModelObject.cpp:
68898        (WebCore::BorderEdge::BorderEdge):
68899        (WebCore::BorderEdge::shouldRender):
68900        (WebCore::BorderEdge::presentButInvisible):
68901        (WebCore::BorderEdge::widthForPainting):
68902        (WebCore::BorderEdge::getDoubleBorderStripeWidths):
68903        (WebCore::RenderBoxModelObject::paintOneBorderSide):
68904        (WebCore::calculateSideRect):
68905        (WebCore::RenderBoxModelObject::paintBorderSides):
68906        (WebCore::RenderBoxModelObject::paintBorder):
68907        (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
68908        (WebCore::calculateSideRectIncludingInner):
68909
689102014-02-25  Zalan Bujtas  <zalan@apple.com>
68911
68912        Subpixel layout: Remove explicit static_cast<LayoutUnit> conversions.
68913        https://bugs.webkit.org/show_bug.cgi?id=129359
68914
68915        Reviewed by Simon Fraser.
68916
68917        No testable change in behavior.
68918
68919        * css/LengthFunctions.cpp:
68920        (WebCore::minimumValueForLength):
68921        * page/FrameView.cpp:
68922        (WebCore::FrameView::forceLayoutForPagination):
68923        * rendering/InlineFlowBox.cpp:
68924        (WebCore::InlineFlowBox::paintFillLayer):
68925        * rendering/InlineFlowBox.h:
68926        (WebCore::InlineFlowBox::logicalLeftVisualOverflow):
68927        (WebCore::InlineFlowBox::logicalRightVisualOverflow):
68928        * rendering/InlineTextBox.cpp:
68929        (WebCore::InlineTextBox::isSelected):
68930        * rendering/RenderBlock.cpp:
68931        (WebCore::RenderBlock::computeColumnCountAndWidth):
68932        (WebCore::getBPMWidth):
68933        * rendering/RenderBlockFlow.cpp:
68934        (WebCore::RenderBlockFlow::adjustForBorderFit):
68935        * rendering/RenderDeprecatedFlexibleBox.cpp:
68936        (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):
68937        * rendering/RenderFieldset.cpp:
68938        (WebCore::RenderFieldset::paintBoxDecorations):
68939        * rendering/RenderTable.h:
68940        (WebCore::RenderTable::borderSpacingInRowDirection):
68941        * rendering/RenderTextControlMultiLine.cpp:
68942        (WebCore::RenderTextControlMultiLine::preferredContentLogicalWidth):
68943        * rendering/RenderTextControlSingleLine.cpp:
68944        (WebCore::RenderTextControlSingleLine::preferredContentLogicalWidth):
68945        * rendering/RootInlineBox.cpp:
68946        (WebCore::RootInlineBox::beforeAnnotationsAdjustment):
68947        (WebCore::RootInlineBox::ascentAndDescentForBox):
68948        * rendering/svg/RenderSVGRoot.cpp:
68949        (WebCore::resolveLengthAttributeForSVG):
68950
689512014-02-25  Anders Carlsson  <andersca@apple.com>
68952
68953        Build fixes.
68954
68955        * CMakeLists.txt:
68956        * GNUmakefile.list.am:
68957        * WebCore.vcxproj/WebCore.vcxproj:
68958        * WebCore.vcxproj/WebCore.vcxproj.filters:
68959
689602014-02-25  Benjamin Poulain  <bpoulain@apple.com>
68961
68962        Build fix for OS X after r164690
68963
68964        * WebCore.exp.in:
68965
689662014-02-25  Anders Carlsson  <andersca@apple.com>
68967
68968        Rename WebCore::VisitedLinkProvider to WebCore::VisitedLinkStore
68969        https://bugs.webkit.org/show_bug.cgi?id=129357
68970
68971        Reviewed by Sam Weinig.
68972
68973        * WebCore.exp.in:
68974        * WebCore.xcodeproj/project.pbxproj:
68975        * dom/VisitedLinkState.cpp:
68976        (WebCore::VisitedLinkState::determineLinkStateSlowCase):
68977        * loader/HistoryController.cpp:
68978        (WebCore::addVisitedLink):
68979        * page/DefaultVisitedLinkStore.cpp: Renamed from Source/WebCore/page/DefaultVisitedLinkProvider.cpp.
68980        (WebCore::DefaultVisitedLinkStore::create):
68981        (WebCore::DefaultVisitedLinkStore::DefaultVisitedLinkStore):
68982        (WebCore::DefaultVisitedLinkStore::~DefaultVisitedLinkStore):
68983        (WebCore::DefaultVisitedLinkStore::isLinkVisited):
68984        (WebCore::DefaultVisitedLinkStore::addVisitedLink):
68985        * page/DefaultVisitedLinkStore.h: Renamed from Source/WebCore/page/DefaultVisitedLinkProvider.h.
68986        * page/Page.cpp:
68987        (WebCore::Page::Page):
68988        (WebCore::Page::visitedLinkStore):
68989        * page/Page.h:
68990        * page/PageGroup.cpp:
68991        (WebCore::PageGroup::visitedLinkStore):
68992        * page/PageGroup.h:
68993        * page/VisitedLinkStore.cpp: Renamed from Source/WebCore/page/VisitedLinkProvider.cpp.
68994        (WebCore::VisitedLinkStore::VisitedLinkStore):
68995        (WebCore::VisitedLinkStore::~VisitedLinkStore):
68996        * page/VisitedLinkStore.h: Renamed from Source/WebCore/page/VisitedLinkProvider.h.
68997
689982014-02-25  Enrica Casucci  <enrica@apple.com>
68999
69000        [WebKit2] Form controls handling.
69001        https://bugs.webkit.org/show_bug.cgi?id=129344
69002        <rdar://problem/16053643>
69003
69004        Reviewed by Simon Fraser and Joseph Pecoraro.
69005
69006        Adding some exports.
69007        
69008        * WebCore.exp.in:
69009
690102014-02-25  Samuel White  <samuel_white@apple.com>
69011
69012        Add accessibility search predicate support for AXOutlines
69013        https://bugs.webkit.org/show_bug.cgi?id=123748
69014
69015        Reviewed by Chris Fleizach.
69016
69017        Added new AXOutlineSearchKey to support finding elements with aria role=tree.
69018
69019        No new tests, updated existing search-predicate.html test to cover AXOutlineSearchKey.
69020
69021        * accessibility/AccessibilityObject.cpp:
69022        (WebCore::AccessibilityObject::isAccessibilityObjectSearchMatchAtIndex):
69023        * accessibility/AccessibilityObject.h:
69024        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
69025        (createAccessibilitySearchKeyMap):
69026
690272014-02-25  Mark Lam  <mark.lam@apple.com>
69028
69029        Need to initialize VM stack data even when the VM is on an exclusive thread.
69030        <https://webkit.org/b/129265>
69031
69032        Not reviewed.
69033
69034        No new tests.
69035
69036        Relanding r164627 now that <https://webkit.org/b/129341> is fixed.
69037
69038        * bindings/js/JSDOMBinding.cpp:
69039        (WebCore::reportException):
69040        * bindings/js/JSDOMWindowBase.cpp:
69041        (WebCore::JSDOMWindowBase::commonVM):
69042
690432014-02-25  Mark Lam  <mark.lam@apple.com>
69044
69045        JSDOMPromise methods should acquire VM lock before calling into JS.
69046        <https://webkit.org/b/129341>
69047
69048        Reviewed by Geoffrey Garen.
69049
69050        No new tests.
69051
69052        * bindings/js/JSDOMPromise.h:
69053        (WebCore::DeferredWrapper::resolve):
69054        (WebCore::DeferredWrapper::reject):
69055        (WebCore::DeferredWrapper::resolve<String>):
69056        (WebCore::DeferredWrapper::resolve<bool>):
69057        (WebCore::char>>):
69058        (WebCore::DeferredWrapper::reject<String>):
69059
690602014-02-25  Anders Carlsson  <andersca@apple.com>
69061
69062        Simplify visited link style invalidation
69063        https://bugs.webkit.org/show_bug.cgi?id=129340
69064
69065        Reviewed by Dan Bernstein.
69066
69067        Get rid of the static Page::allVisitedStateChanged and Page::visitedStateChanged
69068        member functions and add functions to invalidate all styles on a single page or the style
69069        for a single link hash on a single page.
69070
69071        * WebCore.exp.in:
69072        * page/Page.cpp:
69073        (WebCore::Page::invalidateStylesForAllLinks):
69074        (WebCore::Page::invalidateStylesForLink):
69075        * page/Page.h:
69076        * page/PageGroup.cpp:
69077        (WebCore::PageGroup::addVisitedLink):
69078        (WebCore::PageGroup::removeVisitedLink):
69079        (WebCore::PageGroup::removeVisitedLinks):
69080
690812014-02-25  Andreas Kling  <akling@apple.com>
69082
69083        Remove unused ThreadSpecificInspectorCounters.
69084        <https://webkit.org/b/129337>
69085
69086        We were keeping count of all the JS event listeners in every thread
69087        to support an old Chromium feature that's no longer relevant.
69088
69089        Removing this gets rid of expensive thread-local storage lookups.
69090
69091        Reviewed by Anders Carlsson.
69092
69093        * bindings/js/JSEventListener.cpp:
69094        (WebCore::JSEventListener::JSEventListener):
69095        (WebCore::JSEventListener::~JSEventListener):
69096        * inspector/InspectorCounters.cpp:
69097        * inspector/InspectorCounters.h:
69098        * inspector/InspectorTimelineAgent.cpp:
69099        (WebCore::InspectorTimelineAgent::setDOMCounters):
69100        * inspector/protocol/Timeline.json:
69101        * platform/ThreadGlobalData.cpp:
69102        (WebCore::ThreadGlobalData::ThreadGlobalData):
69103        (WebCore::ThreadGlobalData::destroy):
69104        * platform/ThreadGlobalData.h:
69105
691062014-02-25  Laszlo Vidacs  <lvidacs.u-szeged@partner.samsung.com>
69107
69108        display:table with padding and/or borders in border-box calculates height incorrectly
69109        https://bugs.webkit.org/show_bug.cgi?id=126576
69110
69111        Reviewed by David Hyatt.
69112
69113        Based on blink issue https://codereview.chromium.org/25206002/
69114
69115        Tests: fast/box-sizing/css-table-collapse.html
69116               fast/box-sizing/css-table-no-collapse.html
69117               fast/box-sizing/table-collapse.html
69118               fast/box-sizing/table-no-collapse.html
69119
69120        * rendering/RenderBox.cpp:
69121        (WebCore::RenderBox::computePositionedLogicalHeightUsing):
69122
691232014-02-25  Anders Carlsson  <andersca@apple.com>
69124
69125        Get rid of VisitedLinkStrategy
69126        https://bugs.webkit.org/show_bug.cgi?id=129324
69127
69128        Reviewed by Dan Bernstein.
69129
69130        * GNUmakefile.list.am:
69131        * WebCore.vcxproj/WebCore.vcxproj:
69132        * WebCore.vcxproj/WebCore.vcxproj.filters:
69133        * WebCore.xcodeproj/project.pbxproj:
69134        * platform/PlatformStrategies.h:
69135        (WebCore::PlatformStrategies::PlatformStrategies):
69136        * platform/VisitedLinkStrategy.h: Removed.
69137
691382014-02-25  Alexey Proskuryakov  <ap@apple.com>
69139
69140        Rolling out http://trac.webkit.org/changeset/164611, because it broke
69141        WebKit2.PrivateBrowsingPushStateNoHistoryCallback API test
69142
69143        The change was for:
69144
69145        https://bugs.webkit.org/show_bug.cgi?id=129141
69146        Create SessionID class
69147
691482014-02-25  Commit Queue  <commit-queue@webkit.org>
69149
69150        Unreviewed, rolling out r164627.
69151        http://trac.webkit.org/changeset/164627
69152        https://bugs.webkit.org/show_bug.cgi?id=129325
69153
69154        Broke SubtleCrypto tests (Requested by ap on #webkit).
69155
69156        * bindings/js/JSDOMBinding.cpp:
69157        (WebCore::reportException):
69158        * bindings/js/JSDOMWindowBase.cpp:
69159        (WebCore::JSDOMWindowBase::commonVM):
69160
691612014-02-25  Anders Carlsson  <andersca@apple.com>
69162
69163        DefaultVisitedLinkProvider can just call into the page group directly
69164        https://bugs.webkit.org/show_bug.cgi?id=129320
69165
69166        Reviewed by Andreas Kling.
69167
69168        * page/DefaultVisitedLinkProvider.cpp:
69169        (WebCore::DefaultVisitedLinkProvider::isLinkVisited):
69170        (WebCore::DefaultVisitedLinkProvider::addVisitedLink):
69171
691722014-02-25  Commit Queue  <commit-queue@webkit.org>
69173
69174        Unreviewed, rolling out r164638.
69175        http://trac.webkit.org/changeset/164638
69176        https://bugs.webkit.org/show_bug.cgi?id=129321
69177
69178        Broke Windows build. (Requested by bfulgham on #webkit).
69179
69180        * dom/ContainerNode.h:
69181        (WebCore::ChildNodesLazySnapshot::takeSnapshot):
69182        (WebCore::ChildNodesLazySnapshot::hasSnapshot):
69183        * dom/Element.cpp:
69184        (WebCore::ensureAttrNodeListForElement):
69185        (WebCore::Element::attributes):
69186        * dom/ElementIteratorAssertions.h:
69187        (WebCore::ElementIteratorAssertions::ElementIteratorAssertions):
69188        * dom/ElementRareData.h:
69189        (WebCore::ElementRareData::create):
69190        (WebCore::ElementRareData::setAttributeMap):
69191        * dom/MutationObserverRegistration.cpp:
69192        (WebCore::MutationObserverRegistration::create):
69193        (WebCore::MutationObserverRegistration::observedSubtreeNodeWillDetach):
69194        (WebCore::MutationObserverRegistration::clearTransientRegistrations):
69195        (WebCore::MutationObserverRegistration::addRegistrationNodesToSet):
69196        * dom/MutationObserverRegistration.h:
69197        * dom/NamedNodeMap.h:
69198        (WebCore::NamedNodeMap::create):
69199        (WebCore::NamedNodeMap::NamedNodeMap):
69200        * dom/Node.cpp:
69201        (WebCore::Node::ensureRareData):
69202        (WebCore::Node::didMoveToNewDocument):
69203        (WebCore::Node::ensureEventTargetData):
69204        (WebCore::Node::mutationObserverRegistry):
69205        (WebCore::Node::registerMutationObserver):
69206        (WebCore::Node::unregisterMutationObserver):
69207        (WebCore::Node::notifyMutationObserversNodeWillDetach):
69208        * dom/Node.h:
69209        * dom/NodeRareData.h:
69210        (WebCore::NodeListsNodeData::create):
69211        (WebCore::NodeListsNodeData::NodeListsNodeData):
69212        (WebCore::NodeMutationObserverData::create):
69213        (WebCore::NodeMutationObserverData::NodeMutationObserverData):
69214        (WebCore::NodeRareData::create):
69215        (WebCore::NodeRareData::clearNodeLists):
69216        (WebCore::NodeRareData::ensureNodeLists):
69217        (WebCore::NodeRareData::ensureMutationObserverData):
69218        (WebCore::NodeRareData::NodeRareData):
69219        * dom/StyledElement.cpp:
69220        (WebCore::StyledElement::rebuildPresentationAttributeStyle):
69221
692222014-02-25  Eric Carlson  <eric.carlson@apple.com>
69223
69224        [iOS] Show status image when playing video to external device
69225        https://bugs.webkit.org/show_bug.cgi?id=129277
69226
69227        Reviewed by Jer Noble.
69228
69229        * Modules/mediacontrols/mediaControlsApple.js:
69230        (Controller.prototype.handleEvent): Restructure the code so it is possible to handle events
69231            that target the video element which aren't in the HandledVideoEvents array.
69232
69233        * Modules/mediacontrols/mediaControlsiOS.js:
69234        (ControllerIOS.prototype.currentPlaybackTargetIsWireless): webkitCurrentPlaybackTargetIsWireless
69235            is an attribute, not a function.
69236        (ControllerIOS.prototype.updateWirelessPlaybackStatus): Fix style.
69237        (ControllerIOS.prototype.updateWirelessTargetAvailable): Ditto.
69238        (ControllerIOS.prototype.updateProgress): Ditto.
69239        (ControllerIOS.prototype.handleWrapperTouchStart): Show the controls if the wireless status
69240            display is touched.
69241        (ControllerIOS.prototype.handleFullscreenButtonClicked): Fix style
69242        (ControllerIOS.prototype.handleWirelessPlaybackChange): Ditto.
69243        (ControllerIOS.prototype.handleWirelessTargetAvailableChange):
69244        (ControllerIOS.prototype.handleWirelessPickerButtonClicked): Ditto. Stop even propagation.
69245
69246        Move "playback target" logic into HTMLMediaSession.
69247        * html/HTMLMediaElement.cpp:
69248        (WebCore::HTMLMediaElement::~HTMLMediaElement): Call media session.
69249        (WebCore::HTMLMediaElement::loadResource): Tell media session to apply media player
69250            restrictions now that it has a url.
69251        (WebCore::HTMLMediaElement::invalidateCachedTime): Only log when cached time is not 
69252            already invalie.
69253        (WebCore::HTMLMediaElement::webkitShowPlaybackTargetPicker): Call media session.
69254        (WebCore::HTMLMediaElement::webkitCurrentPlaybackTargetIsWireless): Ditto.
69255        (WebCore::HTMLMediaElement::mediaPlayerCurrentPlaybackTargetIsWirelessChanged): Ditto.
69256        (WebCore::HTMLMediaElement::addEventListener): Ditto.
69257        (WebCore::HTMLMediaElement::removeEventListen): Ditto.
69258        (WebCore::HTMLMediaElement::enqueuePlaybackTargetAvailabilityChangedEvent): Ditto.
69259        (WebCore::HTMLMediaElement::createMediaPlayer): Ditto.
69260
69261        * html/HTMLMediaSession.cpp:
69262        (WebCore::restrictionName): Log new WirelessVideoPlaybackDisabled restriction.
69263        (WebCore::HTMLMediaSession::showingPlaybackTargetPickerPermitted): Return false if there
69264            is no page, or if wireless playback is disabled.
69265        (WebCore::HTMLMediaSession::currentPlaybackTargetIsWireless): New, logic from HTMLMediaElement.
69266        (WebCore::HTMLMediaSession::showPlaybackTargetPicker): Ditto.
69267        (WebCore::HTMLMediaSession::hasWirelessPlaybackTargets): Ditto.
69268        (WebCore::HTMLMediaSession::wirelessVideoPlaybackDisabled): Ditto.
69269        (WebCore::HTMLMediaSession::setWirelessVideoPlaybackDisabled): Ditto.
69270        (WebCore::HTMLMediaSession::setHasPlaybackTargetAvailabilityListeners): Ditto.
69271        (WebCore::HTMLMediaSession::applyMediaPlayerRestrictions): New, apply media player specific
69272            restriction.
69273        * html/HTMLMediaSession.h:
69274
69275        Move "playback target" logic into HTMLMediaSession.
69276        * html/HTMLVideoElement.cpp:
69277        (WebCore::HTMLVideoElement::parseAttribute): Call media session.
69278        (WebCore::HTMLVideoElement::webkitWirelessVideoPlaybackDisabled): Call media session.
69279
69280        * platform/audio/MediaSessionManager.h:
69281        (WebCore::MediaSessionManager::showPlaybackTargetPicker): New method, does nothing in base class.
69282
69283        * platform/audio/ios/MediaSessionManagerIOS.h:
69284        * platform/audio/ios/MediaSessionManagerIOS.mm:
69285        (WebCore::MediaSessionManageriOS::showPlaybackTargetPicker): Add non-functional stub.
69286
69287        Implement wireless playback control and status API.
69288        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
69289        (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification): Dispatch TargetIsWirelessChanged.
69290        (WebCore::MediaPlayerPrivateAVFoundation::playbackTargetIsWirelessChanged): Pass through to
69291            media element.
69292        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
69293
69294        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
69295        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
69296        (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize
69297            m_allowsWirelessVideoPlayback.
69298        (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad): Remove "externalPlaybackActive" observer.
69299        (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoLayer): Fix broken logging.
69300        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Add "externalPlaybackActive" observer,
69301            set initial wireless playback.
69302        (WebCore::MediaPlayerPrivateAVFoundationObjC::createPixelBuffer):  Fix broken logging.
69303        (WebCore::MediaPlayerPrivateAVFoundationObjC::languageOfPrimaryAudioTrack): Ditto.
69304        (WebCore::MediaPlayerPrivateAVFoundationObjC::isCurrentPlaybackTargetWireless): New.
69305        (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessVideoPlaybackDisabled): New.
69306        (WebCore::MediaPlayerPrivateAVFoundationObjC::setWirelessVideoPlaybackDisabled): New.
69307        (WebCore::MediaPlayerPrivateAVFoundationObjC::playbackTargetIsWirelessDidChange): New.
69308        (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]): Deal with 
69309            externalPlaybackActive.
69310
693112014-02-24  Brent Fulgham  <bfulgham@apple.com>
69312
69313        [Win] Gracefully recover from missing 'naturalSize' parameter for media
69314        https://bugs.webkit.org/show_bug.cgi?id=129278
69315
69316        Reviewed by Eric Carlson.
69317
69318        * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h: Add declaration for
69319        missing function call.
69320        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
69321        (WebCore::MediaPlayerPrivateAVFoundationCF::assetStatus): Don't treat missing 'naturalSize'
69322        as a fatal error.
69323        (WebCore::MediaPlayerPrivateAVFoundationCF::tracksChanged): Handle case of asset track
69324        not being available yet. 
69325        (WebCore::MediaPlayerPrivateAVFoundationCF::sizeChanged): If the 'naturalSize' is empty,
69326        use the Player Item's 'presentationSize' instead.
69327        (WebCore::AVFWrapper::processNotification): Add missing handler for duration changed.
69328
693292014-02-25  Sergio Villar Senin  <svillar@igalia.com>
69330
69331        [CSS Grid Layout] Add ENABLE flag
69332        https://bugs.webkit.org/show_bug.cgi?id=129153
69333
69334        Reviewed by Simon Fraser.
69335
69336        Added ENABLE_CSS_GRID_LAYOUT feature flag.
69337
69338        * Configurations/FeatureDefines.xcconfig:
69339        * css/CSSComputedStyleDeclaration.cpp:
69340        (WebCore::isLayoutDependent):
69341        (WebCore::ComputedStyleExtractor::propertyValue):
69342        * css/CSSGridTemplateAreasValue.cpp:
69343        * css/CSSGridTemplateAreasValue.h:
69344        * css/CSSParser.cpp:
69345        (WebCore::CSSParserContext::CSSParserContext):
69346        (WebCore::operator==):
69347        (WebCore::isValidKeywordPropertyAndValue):
69348        (WebCore::isKeywordPropertyID):
69349        (WebCore::CSSParser::parseValue):
69350        * css/CSSParser.h:
69351        * css/CSSParserMode.h:
69352        * css/CSSPrimitiveValueMappings.h:
69353        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
69354        * css/CSSPropertyNames.in:
69355        * css/CSSValue.cpp:
69356        (WebCore::CSSValue::equals):
69357        (WebCore::CSSValue::cssText):
69358        (WebCore::CSSValue::destroy):
69359        * css/DeprecatedStyleBuilder.cpp:
69360        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
69361        * css/StyleProperties.cpp:
69362        (WebCore::StyleProperties::getPropertyValue):
69363        * css/StylePropertyShorthand.cpp:
69364        (WebCore::shorthandForProperty):
69365        (WebCore::matchingShorthandsForLonghand):
69366        * css/StyleResolver.cpp:
69367        (WebCore::equivalentBlockDisplay):
69368        (WebCore::StyleResolver::adjustRenderStyle):
69369        (WebCore::StyleResolver::applyProperty):
69370        * css/StyleResolver.h:
69371        * dom/Document.cpp:
69372        * dom/Document.h:
69373        * rendering/RenderElement.cpp:
69374        (WebCore::RenderElement::createFor):
69375        * rendering/RenderGrid.cpp:
69376        * rendering/RenderGrid.h:
69377        * rendering/style/GridCoordinate.h:
69378        * rendering/style/GridLength.h:
69379        * rendering/style/GridPosition.h:
69380        * rendering/style/GridTrackSize.h:
69381        * rendering/style/RenderStyle.cpp:
69382        (WebCore::RenderStyle::changeRequiresLayout):
69383        * rendering/style/RenderStyle.h:
69384        * rendering/style/RenderStyleConstants.h:
69385        * rendering/style/StyleAllInOne.cpp:
69386        * rendering/style/StyleGridData.cpp:
69387        * rendering/style/StyleGridData.h:
69388        * rendering/style/StyleGridItemData.cpp:
69389        * rendering/style/StyleGridItemData.h:
69390        * rendering/style/StyleRareNonInheritedData.cpp:
69391        (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
69392        (WebCore::StyleRareNonInheritedData::operator==):
69393        * rendering/style/StyleRareNonInheritedData.h:
69394
693952014-02-25  Jer Noble  <jer.noble@apple.com>
69396
69397        [EME][Mac] Fix a few issues in CDMSessionMediaSourceAVFObjC.
69398        https://bugs.webkit.org/show_bug.cgi?id=129310
69399
69400        Reviewed by Eric Carlson.
69401
69402        Only send a 'keyerror' event if an actual error code was returned, not just
69403        when no key was added:
69404        * Modules/encryptedmedia/MediaKeySession.cpp:
69405        (WebCore::MediaKeySession::addKeyTimerFired):
69406
69407        The 'length' parameter to a typed ArrayBufferView is the number of entries
69408        in the array, not the byte length:
69409        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
69410        (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest):
69411
69412        The return value of streamingContentKeyRequestDataForApp:contentIdentifier:trackId:options:error
69413        is autoreleased; do not wrap it in an adoptNS:
69414        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
69415        (WebCore::CDMSessionMediaSourceAVFObjC::update):
69416
694172014-02-25  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
69418
69419        [MediaStream] Adding mock implementation of UserMediaClient
69420        https://bugs.webkit.org/show_bug.cgi?id=129274
69421
69422        Reviewed by Eric Carlson.
69423
69424        * platform/mock/UserMediaClientMock.h: Added.
69425        (WebCore::UserMediaClientRequestNotifier::UserMediaClientRequestNotifier):
69426        * testing/Internals.cpp:
69427        (WebCore::Internals::Internals):
69428
694292014-02-25  Ryosuke Niwa  <rniwa@webkit.org>
69430
69431        Tighten bitfields in live NodeLists and HTMLCollections
69432        https://bugs.webkit.org/show_bug.cgi?id=129300
69433
69434        Reviewed by Geoffrey Garen.
69435
69436        Reduce the number of bits used for m_rootType and m_type in LiveNodeList.
69437        Also use enum class for LiveNodeList types. We keep "Type" suffix not to
69438        confuse old-ish compilers.
69439
69440        * dom/ClassNodeList.cpp:
69441        (WebCore::ClassNodeList::ClassNodeList):
69442        * dom/ContainerNode.cpp:
69443        (WebCore::ContainerNode::getElementsByTagName):
69444        (WebCore::ContainerNode::getElementsByName):
69445        (WebCore::ContainerNode::getElementsByClassName):
69446        (WebCore::ContainerNode::radioNodeList):
69447        * dom/LiveNodeList.cpp:
69448        (WebCore::LiveNodeList::collectionFirst):
69449        (WebCore::LiveNodeList::collectionTraverseForward):
69450        * dom/LiveNodeList.h:
69451        (WebCore::LiveNodeList::LiveNodeList):
69452        * dom/NameNodeList.cpp:
69453        (WebCore::NameNodeList::NameNodeList):
69454        * dom/NameNodeList.h:
69455        (WebCore::NameNodeList::create):
69456        * dom/NodeRareData.h:
69457        (WebCore::NodeListsNodeData::namedNodeListKey):
69458        * dom/TagNodeList.cpp:
69459        (WebCore::HTMLTagNodeList::HTMLTagNodeList):
69460        * dom/TagNodeList.h:
69461        (WebCore::TagNodeList::create):
69462        (WebCore::HTMLTagNodeList::create):
69463        * html/HTMLCollection.h:
69464        * html/LabelableElement.cpp:
69465        (WebCore::LabelableElement::labels):
69466        * html/LabelsNodeList.cpp:
69467        (WebCore::LabelsNodeList::LabelsNodeList):
69468        * html/LabelsNodeList.h:
69469        * html/RadioNodeList.cpp:
69470        (WebCore::RadioNodeList::RadioNodeList):
69471        * html/RadioNodeList.h:
69472        (WebCore::RadioNodeList::create):
69473
694742014-02-24  Anders Carlsson  <andersca@apple.com>
69475
69476        Make it possible to set the visited link provider on a per page basis
69477        https://bugs.webkit.org/show_bug.cgi?id=129288
69478
69479        Reviewed by Andreas Kling.
69480
69481        * WebCore.exp.in:
69482        Export symbols needed by WebKit2.
69483
69484        * WebCore.xcodeproj/project.pbxproj:
69485        Make VisitedLinkProvider a private header.
69486
69487        * page/Page.cpp:
69488        (WebCore::Page::Page):
69489        Take the visited link provider from the PageClients object.
69490
69491        (WebCore::Page::visitedLinkProvider):
69492        If the page has a visited link provider set, return it.
69493
69494        * page/Page.h:
69495        Add VisitedLinkProvider to Page and PageClients.
69496
694972014-02-25  Morten Stenshorne  <mstensho@opera.com>
69498
69499        [New Multicolumn] -webkit-column-break-inside:avoid doesn't work
69500        https://bugs.webkit.org/show_bug.cgi?id=129299
69501
69502        Reviewed by Andrei Bucur.
69503
69504        adjustForUnsplittableChild() simply forgot to check whether we
69505        were inside flow thread based multicol.
69506
69507        Test: fast/multicol/newmulticol/avoid-column-break-inside.html
69508
69509        * rendering/RenderBlockFlow.cpp:
69510        (WebCore::RenderBlockFlow::adjustForUnsplittableChild):
69511
695122014-02-25  Mihnea Ovidenie  <mihnea@adobe.com>
69513
69514        [CSSRegions] Remove unused function RenderFlowThread::regionForCompositedLayer
69515        https://bugs.webkit.org/show_bug.cgi?id=129303
69516
69517        Reviewed by Andrei Bucur.
69518
69519        Cleanup, no funtionality change, no new tests.
69520
69521        * rendering/RenderFlowThread.h:
69522
695232014-02-25  Mihai Tica  <mitica@adobe.com>
69524
69525        [CSS Blending] -webkit-mix-blend-mode should force transform-style: flat.
69526        https://bugs.webkit.org/show_bug.cgi?id=126158
69527
69528        Reviewed by Mihnea Ovidenie.
69529
69530        As stated in the http://www.w3.org/TR/css3-transforms/#propdef-transform-style, an element with blending
69531        should force transform-style: flat.
69532
69533        Test: css3/compositing/blend-mode-transform-style.html
69534
69535        * css/StyleResolver.cpp:
69536        (WebCore::StyleResolver::adjustRenderStyle): If blending is detected, set transform-style to flat.
69537
695382014-02-25  Zan Dobersek  <zdobersek@igalia.com>
69539
69540        Move to using std::unique_ptr for Element, Node and related classes
69541        https://bugs.webkit.org/show_bug.cgi?id=129058
69542
69543        Reviewed by Anders Carlsson.
69544
69545        Replace uses of OwnPtr and PassOwnPtr in Element, Node and the related
69546        classes with std::unique_ptr and move semantics.
69547
69548        * dom/ContainerNode.h:
69549        (WebCore::ChildNodesLazySnapshot::takeSnapshot):
69550        (WebCore::ChildNodesLazySnapshot::hasSnapshot):
69551        * dom/Element.cpp:
69552        (WebCore::ensureAttrNodeListForElement):
69553        (WebCore::Element::attributes):
69554        * dom/ElementIteratorAssertions.h:
69555        (WebCore::ElementIteratorAssertions::ElementIteratorAssertions):
69556        * dom/ElementRareData.h:
69557        (WebCore::ElementRareData::setAttributeMap):
69558        * dom/MutationObserverRegistration.cpp:
69559        (WebCore::MutationObserverRegistration::observedSubtreeNodeWillDetach):
69560        (WebCore::MutationObserverRegistration::clearTransientRegistrations):
69561        (WebCore::MutationObserverRegistration::addRegistrationNodesToSet):
69562        * dom/MutationObserverRegistration.h:
69563        * dom/NamedNodeMap.h:
69564        (WebCore::NamedNodeMap::NamedNodeMap):
69565        * dom/Node.cpp:
69566        (WebCore::Node::ensureRareData):
69567        (WebCore::Node::didMoveToNewDocument):
69568        (WebCore::Node::ensureEventTargetData):
69569        (WebCore::Node::mutationObserverRegistry):
69570        (WebCore::Node::registerMutationObserver):
69571        (WebCore::Node::unregisterMutationObserver):
69572        (WebCore::Node::notifyMutationObserversNodeWillDetach):
69573        * dom/Node.h:
69574        * dom/NodeRareData.h:
69575        (WebCore::NodeListsNodeData::NodeListsNodeData):
69576        (WebCore::NodeRareData::NodeRareData):
69577        (WebCore::NodeRareData::clearNodeLists):
69578        (WebCore::NodeRareData::ensureNodeLists):
69579        (WebCore::NodeRareData::ensureMutationObserverData):
69580        * dom/StyledElement.cpp:
69581        (WebCore::StyledElement::rebuildPresentationAttributeStyle):
69582
695832014-02-25  Andreas Kling  <akling@apple.com>
69584
69585        Prune dead code for Web Inspector memory instrumentation.
69586        <https://webkit.org/b/129286>
69587
69588        This was leftover code from Chromium's inspector. It's not used by
69589        today's WebKit inspector.
69590
69591        Reviewed by Sam Weinig.
69592
69593        * CMakeLists.txt:
69594        * DerivedSources.make:
69595        * GNUmakefile.am:
69596        * GNUmakefile.list.am:
69597        * WebCore.vcxproj/WebCore.vcxproj:
69598        * WebCore.vcxproj/WebCore.vcxproj.filters:
69599        * WebCore.xcodeproj/project.pbxproj:
69600        * inspector/InspectorAllInOne.cpp:
69601        * inspector/InspectorController.cpp:
69602        (WebCore::InspectorController::InspectorController):
69603        * inspector/InspectorController.h:
69604        * inspector/InspectorMemoryAgent.cpp: Removed.
69605        * inspector/InspectorMemoryAgent.h: Removed.
69606        * inspector/InspectorTimelineAgent.cpp:
69607        (WebCore::InspectorTimelineAgent::InspectorTimelineAgent):
69608        * inspector/InspectorTimelineAgent.h:
69609        * inspector/WorkerInspectorController.cpp:
69610        (WebCore::WorkerInspectorController::WorkerInspectorController):
69611        * inspector/protocol/Memory.json: Removed.
69612
696132014-02-24  Chris Fleizach  <cfleizach@apple.com>
69614
69615        AX: Support abbr, acronym
69616        https://bugs.webkit.org/show_bug.cgi?id=128860
69617
69618        Reviewed by Mario Sanchez Prada.
69619
69620        Expose the data in <abbr>, <acronym> and <th abbr=""> as an 
69621        alternateTextValue() parameter.
69622
69623        Test: platform/mac/accessibility/abbr-acronym-tags.html
69624
69625        * accessibility/AccessibilityObject.cpp:
69626        (WebCore::AccessibilityObject::hasTagName):
69627        * accessibility/AccessibilityObject.h:
69628        (WebCore::AccessibilityObject::alternateTextValue):
69629        (WebCore::AccessibilityObject::supportsAlternateTextValue):
69630        * accessibility/AccessibilityRenderObject.cpp:
69631        (WebCore::AccessibilityRenderObject::alternateTextValue):
69632        (WebCore::AccessibilityRenderObject::supportsAlternateTextValue):
69633        * accessibility/AccessibilityRenderObject.h:
69634        * accessibility/AccessibilityTableCell.cpp:
69635        (WebCore::AccessibilityTableCell::alternateTextValue):
69636        (WebCore::AccessibilityTableCell::supportsAlternateTextValue):
69637        * accessibility/AccessibilityTableCell.h:
69638        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
69639        (AXAttributeStringSetAlternateTextValue):
69640        (AXAttributedStringAppendText):
69641        (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
69642        (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
69643
696442014-02-24  Martin Robinson  <mrobinson@igalia.com>
69645
69646        [GTK] generate-gtkdoc should not generate documentation for source files for unbuilt source files
69647        https://bugs.webkit.org/show_bug.cgi?id=128417
69648
69649        Reviewed by Carlos Garcia Campos.
69650
69651        * bindings/gobject/GNUmakefile.am: Generate a config file for webkitdom documentation generation.
69652
696532014-02-24  Mark Lam  <mark.lam@apple.com>
69654
69655        Need to initialize VM stack data even when the VM is on an exclusive thread.
69656        <https://webkit.org/b/129265>
69657
69658        Reviewed by Geoffrey Garen.
69659
69660        No new tests.
69661
69662        * bindings/js/JSDOMBinding.cpp:
69663        (WebCore::reportException):
69664        - Added an assertion to ensure that we are holding the JSLock.
69665        * bindings/js/JSDOMWindowBase.cpp:
69666        (WebCore::JSDOMWindowBase::commonVM):
69667        - Updated to use the new VM::setExclusiveThread().
69668
696692014-02-24  Anders Carlsson  <andersca@apple.com>
69670
69671        Add a DefaultVisitedLinkProvider and route visited link actions through it
69672        https://bugs.webkit.org/show_bug.cgi?id=129285
69673
69674        Reviewed by Dan Bernstein.
69675
69676        DefaultVisitedLinkProvider currently just forwards everything to the visited link strategy,
69677        but will soon take over the responsibilities of visited link handling from PageGroup.
69678        
69679        * CMakeLists.txt:
69680        * GNUmakefile.list.am:
69681        * WebCore.vcxproj/WebCore.vcxproj:
69682        * WebCore.vcxproj/WebCore.vcxproj.filters:
69683        * WebCore.xcodeproj/project.pbxproj:
69684        * dom/VisitedLinkState.cpp:
69685        (WebCore::VisitedLinkState::determineLinkStateSlowCase):
69686        * loader/HistoryController.cpp:
69687        (WebCore::addVisitedLink):
69688        (WebCore::HistoryController::updateForStandardLoad):
69689        (WebCore::HistoryController::updateForRedirectWithLockedBackForwardList):
69690        (WebCore::HistoryController::updateForClientRedirect):
69691        (WebCore::HistoryController::updateForSameDocumentNavigation):
69692        (WebCore::HistoryController::pushState):
69693        (WebCore::HistoryController::replaceState):
69694        * page/DefaultVisitedLinkProvider.cpp: Copied from Source/WebCore/page/VisitedLinkProvider.h.
69695        (WebCore::DefaultVisitedLinkProvider::create):
69696        (WebCore::DefaultVisitedLinkProvider::DefaultVisitedLinkProvider):
69697        (WebCore::DefaultVisitedLinkProvider::~DefaultVisitedLinkProvider):
69698        (WebCore::DefaultVisitedLinkProvider::isLinkVisited):
69699        (WebCore::DefaultVisitedLinkProvider::addVisitedLink):
69700        * page/DefaultVisitedLinkProvider.h: Copied from Source/WebCore/page/VisitedLinkProvider.h.
69701        * page/Page.cpp:
69702        (WebCore::Page::visitedLinkProvider):
69703        * page/Page.h:
69704        * page/PageGroup.cpp:
69705        (WebCore::PageGroup::PageGroup):
69706        (WebCore::PageGroup::visitedLinkProvider):
69707        * page/PageGroup.h:
69708        * page/VisitedLinkProvider.h:
69709
697102014-02-24  Jeremy Jones  <jeremyj@apple.com>
69711
69712        WK2 AVKit fullscreen doesn't display video.
69713        https://bugs.webkit.org/show_bug.cgi?id=128564
69714
69715        Reviewed by Simon Fraser.
69716
69717        * WebCore.exp.in:
69718        Export WebCore::PlatformCALayer::platformCALayer()
69719
69720        * platform/ios/WebVideoFullscreenInterface.h:
69721        * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
69722        Remove SetVideoLayerID(). 
69723
69724        * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
69725        (WebVideoFullscreenInterfaceAVKit::setVideoLayer):
69726        Wrap make video layer look like an AVAVPlayerLayer with WebAVPlayerLayer
69727
69728        * platform/ios/WebVideoFullscreenModelMediaElement.mm:
69729        (WebVideoFullscreenModelMediaElement::setMediaElement):
69730        Pass along the videoLayer before borrowing it so the interface will be ready to
69731        catch the transaction that removes it.
69732
697332014-02-24  Samuel White  <samuel_white@apple.com>
69734
69735        AX: AccessibilityObject::findMatchingObjects should never include 'this' in results.
69736        https://bugs.webkit.org/show_bug.cgi?id=129243
69737
69738        Reviewed by Chris Fleizach.
69739
69740        Fix removes the container object from the search results when searching backwards. This
69741        makes backwards & forwards search results consistent with each other.
69742
69743        Test: platform/mac/accessibility/search-predicate-container-not-included.html
69744
69745        * accessibility/AccessibilityObject.cpp:
69746        (WebCore::AccessibilityObject::findMatchingObjects):
69747
697482014-02-24  Samuel White  <samuel_white@apple.com>
69749
69750        AX: findMatchingObjects backwards start position inconsistent with forwards start position when startObject == nullptr.
69751        https://bugs.webkit.org/show_bug.cgi?id=129266
69752
69753        Reviewed by Chris Fleizach.
69754
69755        When searching forward with no start object, the first thing considered is the first child of
69756        the container. However, when searching backwards with no start object nothing in the container
69757        is considered; this basically negates the search. This patch makes backwards searching without
69758        a start object start from the last child of the container to match forward search expectations.
69759
69760        Test: platform/mac/accessibility/search-predicate-start-not-specified.html
69761
69762        * accessibility/AccessibilityObject.cpp:
69763        (WebCore::AccessibilityObject::findMatchingObjects):
69764
697652014-02-24  Andreas Kling  <akling@apple.com>
69766
69767        Prune dead code for Web Inspector canvas instrumentation.
69768        <https://webkit.org/b/129269>
69769
69770        This was leftover code from Chromium's inspector. It's not used by
69771        today's WebKit inspector.
69772
69773        Reviewed by Timothy Hatcher.
69774
69775        * CMakeLists.txt:
69776        * DerivedSources.make:
69777        * GNUmakefile.am:
69778        * GNUmakefile.list.am:
69779        * WebCore.vcxproj/WebCore.vcxproj:
69780        * WebCore.vcxproj/WebCore.vcxproj.filters:
69781        * WebCore.xcodeproj/project.pbxproj:
69782        * bindings/js/JSHTMLCanvasElementCustom.cpp:
69783        (WebCore::JSHTMLCanvasElement::getContext):
69784        * inspector/InjectedScriptCanvasModule.cpp: Removed.
69785        * inspector/InjectedScriptCanvasModule.h: Removed.
69786        * inspector/InspectorAllInOne.cpp:
69787        * inspector/InspectorCanvasAgent.cpp: Removed.
69788        * inspector/InspectorCanvasAgent.h: Removed.
69789        * inspector/InspectorCanvasInstrumentation.h: Removed.
69790        * inspector/InspectorController.cpp:
69791        (WebCore::InspectorController::InspectorController):
69792        (WebCore::InspectorController::didBeginFrame):
69793        * inspector/InspectorInstrumentation.cpp:
69794        (WebCore::InspectorInstrumentation::frameDetachedFromParentImpl):
69795        (WebCore::InspectorInstrumentation::didCommitLoadImpl):
69796        * inspector/InspectorInstrumentation.h:
69797        * inspector/InstrumentingAgents.cpp:
69798        (WebCore::InstrumentingAgents::InstrumentingAgents):
69799        (WebCore::InstrumentingAgents::reset):
69800        * inspector/InstrumentingAgents.h:
69801
698022014-02-24  Zoltan Horvath  <zoltan@webkit.org>
69803
69804        [CSS Shapes] Adjust lineTop position to the next available wrapping location at shape-outsides
69805        https://bugs.webkit.org/show_bug.cgi?id=128693
69806
69807        Reviewed by David Hyatt.
69808
69809        When we don't have space next to the floating container, but we have space inside the floating-container next
69810        to the defined shape-outside, we should wrap around the shape-outside. This patch fixes the behavior both for
69811        cases when there is no space to fit at the first line, and for the additional lines cases.
69812
69813        Test: fast/shapes/shape-outside-floats/shape-outside-floats-linetop-adjustment.html
69814
69815        * rendering/line/BreakingContextInlineHeaders.h:
69816        (WebCore::BreakingContext::handleText):
69817        (WebCore::BreakingContext::commitAndUpdateLineBreakIfNeeded):
69818        * rendering/line/LineWidth.cpp:
69819        (WebCore::availableWidthAtOffset):
69820        (WebCore::LineWidth::updateLineDimension): Added new helper.
69821        (WebCore::isWholeLineFit): Added new helper.
69822        (WebCore::LineWidth::wrapNextToShapeOutside): Added new helper.
69823        (WebCore::LineWidth::fitBelowFloats): Add optional parameter for the function.
69824        * rendering/line/LineWidth.h:
69825
698262014-02-24  Martin Hock  <mhock@apple.com>
69827
69828        Create SessionID value-style class for session IDs.
69829        https://bugs.webkit.org/show_bug.cgi?id=129141
69830
69831        Reviewed by Brady Eidson.
69832
69833        * GNUmakefile.list.am:
69834        * WebCore.exp.in:
69835        * WebCore.xcodeproj/project.pbxproj:
69836        * page/Page.cpp: Add SessionID member.
69837        (WebCore::Page::Page):
69838        (WebCore::Page::sessionID): Retrieve sessionID or use settings if not set.
69839        * page/Page.h:
69840        (WebCore::Page::setSessionID):
69841        * page/SessionID.h: Session ID class consisting solely of its uint64_t session ID.
69842        (WebCore::SessionID::SessionID):
69843        (WebCore::SessionID::isValid): Not empty.
69844        (WebCore::SessionID::isEphemeral):
69845        (WebCore::SessionID::sessionID):
69846        (WebCore::SessionID::operator==): Value-based equality.
69847        (WebCore::SessionID::operator!=):
69848        (WebCore::SessionID::emptySessionID): Zero value also used for HashTraits emptyValue.
69849        (WebCore::SessionID::defaultSessionID):
69850        (WebCore::SessionID::legacyPrivateSessionID):
69851        * page/SessionIDHash.h:
69852        (WTF::SessionIDHash::hash): Just the casted session ID (low order bytes)
69853        (WTF::SessionIDHash::equal):
69854        (WTF::HashTraits<WebCore::SessionID>::emptyValue): Equal to emptySessionID.
69855        (WTF::HashTraits<WebCore::SessionID>::constructDeletedValue): -1 value.
69856        (WTF::HashTraits<WebCore::SessionID>::isDeletedValue):
69857
698582014-02-24  Javier Fernandez  <jfernandez@igalia.com>
69859
69860        [CSS Grid Layout] handle undefined RemainingSpace in computeUsedBreadthOfGridTracks algorithm
69861        https://bugs.webkit.org/show_bug.cgi?id=128372
69862
69863        Reviewed by David Hyatt.
69864
69865        From Blink r165692 by <svillar@igalia.com>
69866
69867        The spec defines a different code path for the computeUsedBreadthOfGridTracks algorithm
69868        http://dev.w3.org/csswg/css-grid/#function-ComputeUsedBreadthOfGridTracks.
69869
69870        Basically the track breadth is different when the available size is undefined and thus,
69871        cannot be taken into account during the computations.
69872        The available size is undefined whenever the height is auto or the grid element has a
69873        shrink-to-fit behavior.
69874
69875        It was also renamed the function to match the specs so the function name starts with
69876        'compute' instead of 'computed'.
69877
69878        No new tests, but added new cases to some of them.
69879
69880        * rendering/RenderGrid.cpp:
69881        (WebCore::RenderGrid::computeIntrinsicLogicalWidths):
69882        (WebCore::RenderGrid::computeUsedBreadthOfGridTracks):
69883        (WebCore::gridElementIsShrinkToFit):
69884        (WebCore::RenderGrid::computeNormalizedFractionBreadth):
69885        (WebCore::RenderGrid::layoutGridItems):
69886        * rendering/RenderGrid.h:
69887
698882014-02-24  Roger Fong  <roger_fong@apple.com>
69889
69890        [Windows] Unreviewed pre-emptive build fix.
69891
69892        * WebCore.vcxproj/WebCoreCommon.props: Add replay directory to include path.
69893
698942014-02-24  Brady Eidson  <beidson@apple.com>
69895
69896        Break out ImageControls style into an external stylesheet
69897        https://bugs.webkit.org/show_bug.cgi?id=129273
69898
69899        Reviewed by Jer Noble.
69900
69901        * DerivedSources.make:
69902        * WebCore.xcodeproj/project.pbxproj:
69903
69904        * css/CSSDefaultStyleSheets.cpp:
69905        (WebCore::CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement):
69906        * css/CSSDefaultStyleSheets.h:
69907
69908        * html/shadow/mac/ImageControlsRootElementMac.cpp:
69909        (WebCore::ImageControlsRootElementMac::maybeCreate):
69910
69911        * html/shadow/mac/imageControlsMac.css:
69912        (.x-webkit-imagemenu):
69913        (.x-webkit-imagemenu:hover):
69914
69915        * rendering/RenderTheme.h:
69916        (WebCore::RenderTheme::mediaControlsScript):
69917        (WebCore::RenderTheme::imageControlsStyleSheet):
69918        * rendering/RenderThemeMac.h:
69919        * rendering/RenderThemeMac.mm:
69920        (WebCore::RenderThemeMac::imageControlsStyleSheet):
69921
699222014-02-24  Thiago de Barros Lacerda  <thiago.lacerda@openbossa.org>
69923
69924        [WebRTC] Validating RTCConfiguration according to the spec
69925        https://bugs.webkit.org/show_bug.cgi?id=129182
69926
69927        Reviewed by Eric Carlson.
69928
69929        Spec states that:
69930            - iceServers should not be an empty list
69931            - the entry in the configuration dictionary is "urls", instead of "url"
69932            - urls can be either a list or a string
69933        Fixing all that in RTCConfiguration validation when creating a RTCPeerConnection
69934
69935        Existing tests were updated.
69936
69937        * Modules/mediastream/RTCPeerConnection.cpp:
69938        (WebCore::appendIceServer): Added.
69939        (WebCore::processIceServer): Added.
69940        (WebCore::RTCPeerConnection::parseConfiguration):
69941
699422014-02-24  Radu Stavila  <stavila@adobe.com>
69943
69944        [CSS Regions] Relative positioned elements overflowing the region do not get painted into the next tile
69945        https://bugs.webkit.org/show_bug.cgi?id=129254
69946
69947        Reviewed by Antti Koivisto.
69948
69949        The painting of the region's layer should not be aborted so early if the region's fragment shouldn't be painted
69950        because that would prevent all the layer's children from being painted.
69951
69952        Another problem this patch addresses is that clipping should also be performed when the clip rect is empty,
69953        which is what happens when painting in a tile in which the flowed element would normally be painted
69954        if it wasn't clipped by the region.
69955
69956        Test: fast/regions/content-relative-next-tile.html
69957
69958        * rendering/RenderLayer.cpp:
69959        (WebCore::RenderLayer::paintFlowThreadIfRegionForFragments):
69960
699612014-02-24  Renata Hodovan  <rhodovan.u-szeged@partner.samsung.com>
69962        
69963        Get rid of the unused 'immediate' parameters from repaint related functions
69964        https://bugs.webkit.org/show_bug.cgi?id=129111
69965
69966        Reviewed by Simon Fraser.
69967
69968        Removing the 'immediate' parameters from repaint related functions - accoring
69969        to the FIXME in RenderView::repaintViewRectangle() - since they have no effect.
69970
69971        No new tests are necessary because there is no behavior change
69972
69973        * dom/Element.cpp:
69974        (WebCore::Element::setActive):
69975        * loader/EmptyClients.h:
69976        * page/Chrome.cpp:
69977        (WebCore::Chrome::invalidateRootView):
69978        (WebCore::Chrome::invalidateContentsAndRootView):
69979        (WebCore::Chrome::invalidateContentsForSlowScroll):
69980        * page/Chrome.h:
69981        * page/ChromeClient.h:
69982        * page/Frame.cpp:
69983        (WebCore::Frame::tiledBackingStorePaintEnd):
69984        * page/FrameView.cpp:
69985        (WebCore::FrameView::invalidateRect):
69986        (WebCore::FrameView::scrollContentsFastPath):
69987        (WebCore::FrameView::repaintContentRectangle):
69988        (WebCore::FrameView::shouldUpdate):
69989        * page/FrameView.h:
69990        * platform/HostWindow.h:
69991        * platform/ScrollView.cpp:
69992        (WebCore::ScrollView::scrollContents):
69993        (WebCore::ScrollView::scrollContentsSlowPath):
69994        (WebCore::ScrollView::repaintContentRectangle):
69995        (WebCore::ScrollView::updateOverhangAreas):
69996        (WebCore::ScrollView::addPanScrollIcon):
69997        (WebCore::ScrollView::removePanScrollIcon):
69998        (WebCore::ScrollView::platformRepaintContentRectangle):
69999        * platform/ScrollView.h:
70000        * rendering/RenderBox.cpp:
70001        (WebCore::RenderBox::repaintLayerRectsForImage):
70002        * rendering/RenderFlowThread.cpp:
70003        (WebCore::RenderFlowThread::repaintRectangleInRegions):
70004        * rendering/RenderFlowThread.h:
70005        * rendering/RenderLayer.cpp:
70006        (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
70007        * rendering/RenderLayer.h:
70008        * rendering/RenderMultiColumnSet.cpp:
70009        (WebCore::RenderMultiColumnSet::repaintFlowThreadContent):
70010        * rendering/RenderMultiColumnSet.h:
70011        * rendering/RenderObject.cpp:
70012        (WebCore::RenderObject::repaintUsingContainer):
70013        (WebCore::RenderObject::repaint):
70014        (WebCore::RenderObject::repaintRectangle):
70015        (WebCore::RenderObject::repaintSlowRepaintObject):
70016        * rendering/RenderObject.h:
70017        * rendering/RenderRegion.cpp:
70018        (WebCore::RenderRegion::repaintFlowThreadContent):
70019        (WebCore::RenderRegion::repaintFlowThreadContentRectangle):
70020        * rendering/RenderRegion.h:
70021        * rendering/RenderView.cpp:
70022        (WebCore::RenderView::repaintViewRectangle):
70023        (WebCore::RenderView::flushAccumulatedRepaintRegion):
70024        (WebCore::RenderView::repaintRectangleInViewAndCompositedLayers):
70025        * rendering/RenderView.h:
70026        * svg/graphics/SVGImageChromeClient.h:
70027
700282014-02-24  Tamas Gergely  <tgergely.u-szeged@partner.samsung.com>
70029
70030        Code cleanup: remove leftover ENABLE(WORKERS) macros and support.
70031        https://bugs.webkit.org/show_bug.cgi?id=129255
70032
70033        Reviewed by Csaba Osztrogonác.
70034
70035        ENABLE_WORKERS macro was removed in r159679, but r161589 added back some occurrences.
70036        Support is now also removed from xcconfig files.
70037
70038        No new tests needed.
70039
70040        * Configurations/FeatureDefines.xcconfig:
70041        * platform/ThreadGlobalData.cpp:
70042        * platform/ThreadGlobalData.h:
70043        * platform/Timer.h:
70044        (WebCore::TimerBase::isActive):
70045        * platform/ios/wak/WebCoreThread.mm:
70046        (RunWebThread):
70047        (StartWebThread):
70048
700492014-02-24  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
70050
70051        [CMake] Get rid of "FIXME: The Blackberry port ..." from WebCore/CmakeLists.txt
70052        https://bugs.webkit.org/show_bug.cgi?id=129152
70053
70054        Reviewed by Gyuyoung Kim.
70055
70056        * CMakeLists.txt:
70057
700582014-02-24  David Kilzer  <ddkilzer@apple.com>
70059
70060        Remove redundant setting in FeatureDefines.xcconfig
70061
70062        * Configurations/FeatureDefines.xcconfig:
70063
700642014-02-24  Mihai Tica  <mitica@adobe.com>
70065
70066        [CSS Blending] An element having -webkit-mix-blend-mode should only blend with the contents of the parent stacking context
70067        https://bugs.webkit.org/show_bug.cgi?id=129154
70068
70069        Reviewed by Dean Jackson.
70070
70071        The blending operation of an element having -webkit-mix-blend-mode should be restricted to the parent stacking context.
70072        This change isolates blending, preventing it from blending with other underlying elements besides the parent stacking context.
70073
70074        Tests: css3/compositing/blend-mode-isolated-group-1.html
70075               css3/compositing/blend-mode-isolated-group-2.html
70076               css3/compositing/blend-mode-isolated-group-3.html
70077
70078        * rendering/RenderLayer.cpp:
70079        (WebCore::RenderLayer::RenderLayer): Initialize added members to false.
70080        (WebCore::RenderLayer::updateBlendMode): Check if a blend mode was set or unset. If so, set the m_updateParentStackingContextShouldIsolateBlendingDirty to true.
70081        (WebCore::RenderLayer::updateParentStackingContextShouldIsolateBlending): Traverse to the parent stacking context and update the
70082        m_isolatesBlending member accordingly.
70083        * rendering/RenderLayer.h:
70084        - Add isolatesBlending() as a condition for creating a transparency layer in the paintsWithTransparency method.
70085        - Add m_updateParentStackingContextShouldIsolateBlendingDirty member.
70086        - Add m_isolatesBlending member and getter.
70087        * rendering/RenderLayerCompositor.cpp:
70088        (WebCore::RenderLayerCompositor::computeCompositingRequirements): Call updateParentStackingContextShouldIsolateBlending. 
70089
700902014-02-24  Krzysztof Czech  <k.czech@samsung.com>
70091
70092        [ATK] Wrong selected element at a given index in a list box.
70093        https://bugs.webkit.org/show_bug.cgi?id=129039
70094
70095        Reviewed by Chris Fleizach.
70096
70097        Test: accessibility/select-element-at-index.html
70098
70099        The selected element at a given index was wrong. One should be considered among the
70100        all children of a list box, not only selected ones.
70101
70102        * accessibility/atk/WebKitAccessibleInterfaceSelection.cpp:
70103        (core):
70104        (listObjectForSelection):
70105        (optionFromList):
70106        (optionFromSelection):
70107        (webkitAccessibleSelectionRefSelection):
70108
701092014-02-23  Dean Jackson  <dino@apple.com>
70110
70111        [WebGL] Allow ANGLE to initialize unused varyings
70112        https://bugs.webkit.org/show_bug.cgi?id=129240
70113        <rdar://problem/15203342>
70114
70115        Reviewed by Sam Weinig.
70116
70117        Covered by: conformance/glsl/misc/shaders-with-varyings.html
70118
70119        * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
70120        (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE):
70121        Add SH_INIT_VARYINGS_WITHOUT_STATIC_USE to compiler flags.
70122
701232014-02-23  Sam Weinig  <sam@webkit.org>
70124
70125        Update FeatureDefines.xcconfig
70126
70127        Rubber-stamped by Anders Carlsson.
70128
70129        * Configurations/FeatureDefines.xcconfig:
70130
701312014-02-23  Dean Jackson  <dino@apple.com>
70132
70133        Sort the project file with sort-Xcode-project-file.
70134
70135        Rubber-stamped by Sam Weinig.
70136
70137        * WebCore.xcodeproj/project.pbxproj:
70138
701392014-02-23  Sam Weinig  <sam@webkit.org>
70140
70141        Fix incorrectly commented out code.
70142
70143        * platform/TelephoneNumberDetector.h:
70144
701452014-02-23  Sam Weinig  <sam@webkit.org>
70146
70147        Extract platform specific parts of telephone number detection 
70148        https://bugs.webkit.org/show_bug.cgi?id=129238
70149
70150        Reviewed by Dean Jackson.
70151
70152        * WebCore.xcodeproj/project.pbxproj:
70153        Add new files.
70154
70155        * html/parser/HTMLTreeBuilder.cpp:
70156        (WebCore::HTMLTreeBuilder::linkifyPhoneNumbers):
70157        (WebCore::HTMLTreeBuilder::processCharacterBufferForInBody):
70158        * platform/TelephoneNumberDetector.h: Added.
70159        * platform/cocoa/TelephoneNumberDetectorCocoa.cpp: Added.
70160        (WebCore::TelephoneNumberDetector::phoneNumbersScanner):
70161        (WebCore::TelephoneNumberDetector::isSupported):
70162        (WebCore::TelephoneNumberDetector::find):
70163        Move code to TelephoneNumberDetector.
70164
701652014-02-23  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
70166
70167        Change a url parameter type with URL in NavigatorContentUtils
70168        https://bugs.webkit.org/show_bug.cgi?id=129202
70169
70170        Reviewed by Sam Weinig.
70171
70172        It would be good if we use *URL* for url parameters instead of using String.
70173
70174        Merge from blink. https://src.chromium.org/viewvc/blink?view=rev&revision=165458.
70175
70176        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
70177        (WebCore::verifyCustomHandlerURL):
70178        (WebCore::NavigatorContentUtils::registerProtocolHandler):
70179        (WebCore::NavigatorContentUtils::isProtocolHandlerRegistered):
70180        (WebCore::NavigatorContentUtils::unregisterProtocolHandler):
70181        * Modules/navigatorcontentutils/NavigatorContentUtilsClient.h:
70182
701832014-02-23  Dean Jackson  <dino@apple.com>
70184
70185        Update ANGLE to 836bd2176e5607b14846cf1fbc5932dbc91318f4
70186        https://bugs.webkit.org/show_bug.cgi?id=129232
70187
70188        Reviewed by Brent Fulgham.
70189
70190        New files added, derived sources compiled directly, and generated
70191        steps removed for both EFL and GTK, with much-needed help from
70192        Sergio Correia.
70193
70194        * CMakeLists.txt:
70195        * GNUMakefile.am:
70196
701972014-02-23  Sam Weinig  <sam@webkit.org>
70198
70199        Move RenderMathMLMenclose.h/cpp to the right place in the Xcode project and sort.
70200
70201        Rubber-stamped by Anders Carlsson.
70202
70203        * WebCore.xcodeproj/project.pbxproj:
70204
702052014-02-23  Sam Weinig  <sam@webkit.org>
70206
70207        Move telephone number detection behind its own ENABLE macro
70208        https://bugs.webkit.org/show_bug.cgi?id=129236
70209
70210        Reviewed by Dean Jackson.
70211
70212        * Configurations/FeatureDefines.xcconfig:
70213        Add ENABLE_TELEPHONE_NUMBER_DETECTION.
70214
70215        * dom/Document.cpp:
70216        (WebCore::Document::Document):
70217        * dom/Document.h:
70218        * html/parser/HTMLConstructionSite.h:
70219        * html/parser/HTMLTreeBuilder.cpp:
70220        (WebCore::HTMLTreeBuilder::processCharacterBufferForInBody):
70221        * html/parser/HTMLTreeBuilder.h:
70222        Use ENABLE(TELEPHONE_NUMBER_DETECTION).
70223
70224        * platform/mac/SoftLinking.h:
70225        Remove PLATOFORM(IOS) from SOFT_LINK_PRIVATE_FRAMEWORK_OPTIONAL, it is not iOS specific.
70226
702272014-02-23  Zalan Bujtas  <zalan@apple.com>
70228
70229        Subpixel rendering: Fix bleed avoidance subpixel calculation.
70230        https://bugs.webkit.org/show_bug.cgi?id=129225
70231
70232        Reviewed by Simon Fraser.
70233        
70234        static_cast<LayoutUnit>(int value) only produces the desired result when subpixel is off.
70235
70236        Currently not testable.
70237
70238        * rendering/RenderBoxModelObject.cpp:
70239        (WebCore::RenderBoxModelObject::getBackgroundRoundedRect):
70240        (WebCore::shrinkRectByOneDevicePixel):
70241        (WebCore::RenderBoxModelObject::borderInnerRectAdjustedForBleedAvoidance):
70242        (WebCore::RenderBoxModelObject::backgroundRoundedRectAdjustedForBleedAvoidance):
70243        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
70244        * rendering/RenderBoxModelObject.h:
70245
702462014-02-23  Zalan Bujtas  <zalan@apple.com>
70247
70248        Subpixel rendering: Add devicepixel based computation to BorderEdge class.
70249        https://bugs.webkit.org/show_bug.cgi?id=129224
70250
70251        Reviewed by Simon Fraser.
70252
70253        To produce correct width (and type) results, BorderEdge class needs to take device pixel ratio into account.
70254
70255        Currently not testable.
70256
70257        * rendering/RenderBoxModelObject.cpp:
70258        (WebCore::BorderEdge::BorderEdge):
70259        (WebCore::BorderEdge::obscuresBackgroundEdge):
70260        (WebCore::BorderEdge::getDoubleBorderStripeWidths): this does not always produce the same
70261        result as before, but the sum of inner and outer is not different.
70262        (WebCore::BorderEdge::borderWidthInDevicePixel):
70263        (WebCore::RenderBoxModelObject::getBorderEdgeInfo):
70264
702652014-02-22  Dan Bernstein  <mitz@apple.com>
70266
70267        REGRESSION (r164507): Crash beneath JSGlobalObjectInspectorController::reportAPIException at facebook.com, twitter.com, youtube.com
70268        https://bugs.webkit.org/show_bug.cgi?id=129227
70269
70270        Reviewed by Eric Carlson.
70271
70272        Reverted r164507.
70273
70274        * bindings/js/JSDOMBinding.cpp:
70275        (WebCore::reportException):
70276        * inspector/InspectorResourceAgent.cpp:
70277        (WebCore::InspectorResourceAgent::buildInitiatorObject):
70278        * inspector/PageDebuggerAgent.cpp:
70279        (WebCore::PageDebuggerAgent::breakpointActionLog):
70280        * inspector/TimelineRecordFactory.cpp:
70281        (WebCore::TimelineRecordFactory::createGenericRecord):
70282        * page/Console.cpp:
70283        (WebCore::internalAddMessage):
70284        (WebCore::Console::profile):
70285        (WebCore::Console::profileEnd):
70286        (WebCore::Console::timeEnd):
70287        * page/ContentSecurityPolicy.cpp:
70288        (WebCore::gatherSecurityPolicyViolationEventData):
70289        (WebCore::ContentSecurityPolicy::reportViolation):
70290        * page/DOMWindow.cpp:
70291        (WebCore::DOMWindow::postMessage):
70292
702932014-02-22  Joseph Pecoraro  <pecoraro@apple.com>
70294
70295        Remove some unreachable code (-Wunreachable-code)
70296        https://bugs.webkit.org/show_bug.cgi?id=129220
70297
70298        Reviewed by Eric Carlson.
70299
70300        * html/parser/HTMLTreeBuilder.cpp:
70301        (WebCore::HTMLTreeBuilder::processCharacterBuffer):
70302        (WebCore::HTMLTreeBuilder::processEndTag):
70303        The only tricky case. Here there was a break inside the
70304        #if, but not the #else, and a break after the #endif.
70305        Remove the break inside the #if, and always use the
70306        break after the #endif.
70307
70308        * Modules/indexeddb/IDBTransaction.cpp:
70309        (WebCore::IDBTransaction::modeToString):
70310        * bindings/js/JSTrackCustom.cpp:
70311        (WebCore::toJS):
70312        * bindings/js/JSWebGLRenderingContextCustom.cpp:
70313        (WebCore::functionForUniform):
70314        * css/SelectorChecker.cpp:
70315        (WebCore::SelectorChecker::checkOne):
70316        * html/HTMLMediaElement.cpp:
70317        (WebCore::HTMLMediaElement::parseAttribute):
70318        * page/CaptionUserPreferencesMediaAF.cpp:
70319        (WebCore::CaptionUserPreferencesMediaAF::captionDisplayMode):
70320
703212014-02-22  Dean Jackson  <dino@apple.com>
70322
70323        Letterpress effect disabled for synthetic italic
70324        https://bugs.webkit.org/show_bug.cgi?id=129218
70325        <rdar://problem/15997846>
70326
70327        Reviewed by Dan Bernstein.
70328
70329        There was no need to guard against synthetic italics and letterpress.
70330
70331        * platform/graphics/mac/FontMac.mm:
70332        (WebCore::Font::drawGlyphs): Remove !useLetterpressEffect from conditional.
70333
703342014-02-21  Sam Weinig  <sam@webkit.org>
70335
70336        Expose phase and momentum phase as SPI on DOMWheelEvent
70337        <rdar://problem/16110871>
70338        https://bugs.webkit.org/show_bug.cgi?id=129184
70339
70340        Reviewed by Anders Carlsson.
70341
70342        * WebCore.exp.in:
70343        Export core(DOMWheelEvent).
70344
70345        * WebCore.xcodeproj/project.pbxproj:
70346        Make DOMWheelEventInternal.h available in WebKit.
70347
70348        * dom/Element.cpp:
70349        (WebCore::Element::dispatchWheelEvent):
70350        * dom/WheelEvent.cpp:
70351        (WebCore::determineDeltaMode):
70352        (WebCore::WheelEvent::WheelEvent):
70353        (WebCore::WheelEvent::initWheelEvent):
70354        (WebCore::WheelEvent::initWebKitWheelEvent):
70355        Move PlatformWheelEvent -> DOMWheelEvent conversion to DOMWheelEvent.
70356
70357        * dom/WheelEvent.h:
70358        (WebCore::WheelEvent::create):
70359        (WebCore::WheelEvent::phase):
70360        (WebCore::WheelEvent::momentumPhase):
70361        Store phase and momentumPhase on the WheelEvent.
70362
703632014-02-22  Alexey Proskuryakov  <ap@apple.com>
70364
70365        Rename JWK key_ops values from wrap/unwrap to wrapKey/unwrapKey
70366        https://bugs.webkit.org/show_bug.cgi?id=129121
70367
70368        Reviewed by Sam Weinig.
70369
70370        * bindings/js/JSCryptoKeySerializationJWK.cpp:
70371        (WebCore::JSCryptoKeySerializationJWK::reconcileUsages): Updated to newer names.
70372        (WebCore::addUsagesToJSON): Ditto.
70373        (WebCore::JSCryptoKeySerializationJWK::serialize): rsa-oaep-key-manipulation test
70374        started ot fail, because RSA-OAEP with 2048 bit key and sha-1 can only encrypt
70375        214 bytes, and the new longer names made JSON serialization slightly longer.
70376        Compensate by not doing any indentation in JSON.
70377
703782014-02-22  Frédéric Wang  <fred.wang@free.fr>
70379
70380        Only skip stretchy operators when determining the stretch height.
70381        https://bugs.webkit.org/show_bug.cgi?id=126842
70382
70383        Reviewed by Chris Fleizach.
70384
70385        The MathML code only takes into account non-mo children for the computation of the stretch size. This change includes non-stretchy mo in that computation. A new test is added into mathml/presentation/stretchy-depth-height.html.
70386
70387        * rendering/mathml/RenderMathMLRow.cpp:
70388        (WebCore::RenderMathMLRow::layout):
70389
703902014-02-22  Frédéric Wang  <fred.wang@free.fr>
70391
70392        Implement asymmetric/symmetric stretching of vertical operators.
70393        https://bugs.webkit.org/show_bug.cgi?id=124827.
70394
70395        Reviewed by Chris Fleizach.
70396
70397        The MathML code stretches vertical operators asymmetrically by default. This patch takes into account the symmetric attribute or the symmetric property of the operator dictionary to stretch operators symmetrically.
70398
70399        Test: mathml/presentation/stretchy-depth-height-symmetric.html
70400
70401        * rendering/mathml/RenderMathMLOperator.cpp:
70402        (WebCore::RenderMathMLOperator::stretchTo):
70403        (WebCore::RenderMathMLOperator::updateFromElement):
70404        (WebCore::RenderMathMLOperator::updateStyle):
70405
704062014-02-22  Frédéric Wang  <fred.wang@free.fr>
70407
70408        Bug 119043 - Large stretch size error for MathML operators.
70409        https://bugs.webkit.org/show_bug.cgi?id=119043
70410
70411        Reviewed by Chris Fleizach.
70412
70413        The MathML code used some arbitrary gOperatorExpansion factor for the
70414        stretch size and 2/3 1/2 constants for the baseline. This change tries
70415        to consider height/depth of siblings of the stretchy operator so that
70416        the stretchy operator now matches its target.
70417
70418        Test: mathml/presentation/stretchy-depth-height.html
70419
70420        * rendering/RenderObject.h:
70421        (WebCore::RenderObject::isRenderMathMLTable):
70422        * rendering/mathml/RenderMathMLBlock.h:
70423        * rendering/mathml/RenderMathMLOperator.cpp:
70424        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
70425        (WebCore::RenderMathMLOperator::stretchTo):
70426        (WebCore::RenderMathMLOperator::findAcceptableStretchyCharacter):
70427        (WebCore::RenderMathMLOperator::updateStyle):
70428        (WebCore::RenderMathMLOperator::firstLineBaseline):
70429        (WebCore::RenderMathMLOperator::computeLogicalHeight):
70430        * rendering/mathml/RenderMathMLOperator.h:
70431        * rendering/mathml/RenderMathMLRow.cpp:
70432        (WebCore::RenderMathMLRow::layout):
70433
704342014-02-22  Frédéric Wang  <fred.wang@free.fr>
70435
70436        Unreviewed, rolling out r164534.
70437        http://trac.webkit.org/changeset/164534
70438        https://bugs.webkit.org/show_bug.cgi?id=119043
70439
70440        missing tests
70441
70442        * rendering/RenderObject.h:
70443        * rendering/mathml/RenderMathMLBlock.h:
70444        * rendering/mathml/RenderMathMLOperator.cpp:
70445        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
70446        (WebCore::RenderMathMLOperator::expandedStretchHeight):
70447        (WebCore::RenderMathMLOperator::stretchToHeight):
70448        (WebCore::RenderMathMLOperator::findAcceptableStretchyCharacter):
70449        (WebCore::RenderMathMLOperator::updateStyle):
70450        (WebCore::RenderMathMLOperator::firstLineBaseline):
70451        (WebCore::RenderMathMLOperator::computeLogicalHeight):
70452        * rendering/mathml/RenderMathMLOperator.h:
70453        * rendering/mathml/RenderMathMLRow.cpp:
70454        (WebCore::RenderMathMLRow::layout):
70455
704562014-02-22  Frédéric Wang  <fred.wang@free.fr>
70457
70458        Bug 119043 - Large stretch size error for MathML operators.
70459        https://bugs.webkit.org/show_bug.cgi?id=119043
70460
70461        Reviewed by Chris Fleizach.
70462
70463        The MathML code used some arbitrary gOperatorExpansion factor for the
70464        stretch size and 2/3 1/2 constants for the baseline. This change tries
70465        to consider height/depth of siblings of the stretchy operator so that
70466        the stretchy operator now matches its target.
70467
70468        Test: mathml/presentation/stretchy-depth-height.html
70469
70470        * rendering/RenderObject.h:
70471        (WebCore::RenderObject::isRenderMathMLTable):
70472        * rendering/mathml/RenderMathMLBlock.h:
70473        * rendering/mathml/RenderMathMLOperator.cpp:
70474        (WebCore::RenderMathMLOperator::RenderMathMLOperator):
70475        (WebCore::RenderMathMLOperator::stretchTo):
70476        (WebCore::RenderMathMLOperator::findAcceptableStretchyCharacter):
70477        (WebCore::RenderMathMLOperator::updateStyle):
70478        (WebCore::RenderMathMLOperator::firstLineBaseline):
70479        (WebCore::RenderMathMLOperator::computeLogicalHeight):
70480        * rendering/mathml/RenderMathMLOperator.h:
70481        * rendering/mathml/RenderMathMLRow.cpp:
70482        (WebCore::RenderMathMLRow::layout):
70483
704842014-02-21  Zalan Bujtas  <zalan@apple.com>
70485
70486        REGRESSION(r164412): Pixel cracks when zooming in to any web content.
70487        https://bugs.webkit.org/show_bug.cgi?id=129195
70488
70489        Reviewed by Simon Fraser.
70490
70491        Integral clipping of the repaint rect was prematurely removed in RenderLayerBacking::paintContents().
70492        Repaint rects needs a uniform, device pixel precise clipping across the painting flow including RenderLayer,
70493        RenderView and TileController.
70494
70495        * rendering/RenderLayerBacking.cpp:
70496        (WebCore::RenderLayerBacking::paintContents):
70497        (WebCore::RenderLayerBacking::compositedBoundsIncludingMargin):
70498
704992014-02-21  Jer Noble  <jer.noble@apple.com>
70500
70501        Unreviewed Mac build fix after r164529.
70502
70503        Replace the string-to-array algorithm with a archictecture-independant
70504        one.
70505
70506        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
70507        (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest):
70508
705092014-02-21  Jer Noble  <jer.noble@apple.com>
70510
70511        [EME] Add a CDMSession for MediaPlayerPrivateMediaSourceAVFObjC
70512        https://bugs.webkit.org/show_bug.cgi?id=129166
70513
70514        Reviewed by Eric Carlson.
70515
70516        Add a new CDMSession, cerated by MediaPlayerPrivateMediaSourceAVFObjC allowing
70517        media-source-backed media elements to play protected content.
70518
70519        Add a new CDMSessionMediaSourceAVFObjC class:
70520        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.h: Added.
70521        (WebCore::CDMSessionMediaSourceAVFObjC::~CDMSessionMediaSourceAVFObjC):
70522        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm: Added.
70523        (WebCore::CDMSessionMediaSourceAVFObjC::CDMSessionMediaSourceAVFObjC):
70524        (WebCore::CDMSessionMediaSourceAVFObjC::generateKeyRequest): Do not actually generate a
70525            key request until the certificate data has been added via update();
70526        (WebCore::CDMSessionMediaSourceAVFObjC::releaseKeys): No-op.
70527        (WebCore::CDMSessionMediaSourceAVFObjC::update): If no certificate data has yet been
70528            added, assume the incoming message contains it.
70529
70530        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
70531        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
70532        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::registerMediaEngine): Add supportsKeySystem.
70533        (WebCore::keySystemIsSupported): Use "com.apple.fps.2_0" to distinguish from the not-media-source scheme.
70534        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsType): Check the keySystem type.
70535        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsKeySystem): Added.
70536        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::createSession): Added, pass through to MediaSourcePrivate.
70537        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
70538        * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
70539        (WebCore::MediaSourcePrivateAVFObjC::createSession): Added.
70540        (WebCore::MediaSourcePrivateAVFObjC::sourceBufferKeyNeeded): Pass through to MediaPlayer.
70541        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
70542        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
70543        (-[WebAVStreamDataParserListener streamDataParser:didProvideContentKeyRequestInitializationData:forTrackID:]):
70544            Added, pass through to SourceBufferPrivate.
70545        (WebCore::SourceBufferPrivateAVFObjC::SourceBufferPrivateAVFObjC):
70546        (WebCore::SourceBufferPrivateAVFObjC::didProvideContentKeyRequestInitializationDataForTrackID): Remember
70547            which track is requesting the key, and pass the request to MediaSourcePrivate.
70548
70549        Add new files to the project.
70550        * WebCore.xcodeproj/project.pbxproj:
70551
705522014-02-21  Alexey Proskuryakov  <ap@apple.com>
70553
70554        CryptoAlgorithmRSASSA_PKCS1_v1_5::platformVerify contains seemingly accidental unreachable code
70555        https://bugs.webkit.org/show_bug.cgi?id=129193
70556
70557        Reviewed by Joseph Pecoraro.
70558
70559        * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp:
70560        (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformVerify): Fix the accidental code.
70561
705622014-02-21  Brent Fulgham  <bfulgham@apple.com>
70563
70564        Extend media support for WebVTT sources
70565        https://bugs.webkit.org/show_bug.cgi?id=129156
70566
70567        Reviewed by Eric Carlson.
70568
70569        * Configurations/FeatureDefines.xcconfig: Add new feature define for AVF_CAPTIONS
70570        * html/HTMLMediaElement.cpp:
70571        (WebCore::HTMLMediaElement::outOfBandTrackSources): Added.
70572        * html/HTMLMediaElement.h:
70573        * platform/graphics/MediaPlayer.cpp:
70574        (WebCore::MediaPlayer::outOfBandTrackSources): Added.
70575        * platform/graphics/MediaPlayer.h:
70576        (WebCore::MediaPlayerClient::outOfBandTrackSources): Added.
70577        * platform/graphics/PlatformTextTrack.h:
70578        (WebCore::PlatformTextTrack::create): Update for new constructor signature.
70579        (WebCore::PlatformTextTrack::createOutOfBand): Added.
70580        (WebCore::PlatformTextTrack::url): Added.
70581        (WebCore::PlatformTextTrack::isDefault): Added.
70582        (WebCore::PlatformTextTrack::PlatformTextTrack): Revised to take new URL and
70583        'isDefault' arguments.
70584        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
70585        (WebCore::mediaDescriptionForKind): Added.
70586        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Tell AVFoundation about any
70587        WebVTT tracks supplied by the web page.
70588        (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions): Filter out any out-of-band
70589        WebVTT tracks returned by the media engine to avoid double-counting tracks.
70590
705912014-02-21  Ryosuke Niwa  <rniwa@webkit.org>
70592
70593        Inner text element should not use -webkit-user-modify
70594        https://bugs.webkit.org/show_bug.cgi?id=129035
70595
70596        Reviewed by Andreas Kling.
70597
70598        To eliminate the internal use of -webkit-user-modify, use contenteditable attribute in the inner text elements
70599        instead of manually inspecting disabled-ness and readonly-ness in RenderTextControl.
70600
70601        Unfortunately, we still have to manually set UserModify value in RenderTextControl::adjustInnerTextStyle since
70602        RenderTextControl::styleDidChange creates RenderStyle for its inner text from scratch via createInnerTextStyle.    
70603
70604        * html/HTMLFieldSetElement.cpp:
70605        (WebCore::HTMLFieldSetElement::disabledStateChanged): Don't use childrenOfType iterator which asserts that DOM
70606        isn't mutated during the traversal since we now set contenteditable attribute inside disabledStateChanged via
70607        updateFromControlElementsAncestorDisabledStateUnder.
70608
70609        * html/HTMLFormControlElement.cpp:
70610        (WebCore::HTMLFormControlElement::parseAttribute): Extracted readOnlyAttributeChanged out of this function so
70611        that HTMLTextFormControl could override it to call updateInnerTextElementEditability.
70612        (WebCore::HTMLFormControlElement::readOnlyAttributeChanged): Ditto.
70613        * html/HTMLFormControlElement.h:
70614
70615        * html/HTMLInputElement.cpp:
70616        (WebCore::HTMLInputElement::didAddUserAgentShadowRoot): Call updateInnerTextElementEditability after creating
70617        shadow DOM for the current input type.
70618        (WebCore::HTMLInputElement::updateType): Ditto.
70619        (WebCore::HTMLInputElement::parseAttribute): Ditto.
70620
70621        * html/HTMLTextAreaElement.cpp:
70622        (WebCore::HTMLTextAreaElement::didAddUserAgentShadowRoot): Call updateInnerTextElementEditability.
70623
70624        * html/HTMLTextFormControlElement.cpp:
70625        (WebCore::HTMLTextFormControlElement::disabledStateChanged): Added to update contenteditable attribute since
70626        the editability of the inner text element depends on disabled-ness of the element.
70627        (WebCore::HTMLTextFormControlElement::readOnlyAttributeChanged): Ditto for the readonly-ness of the element.
70628        (WebCore::HTMLTextFormControlElement::updateInnerTextElementEditability): Added.
70629        * html/HTMLTextFormControlElement.h:
70630
70631        * rendering/RenderTextControl.cpp:
70632        (WebCore::RenderTextControl::adjustInnerTextStyle): Use the inner text element's presentationAttributeStyle() to
70633        compute the appropriate EUserModify value instead of hard-coding it here.
70634        * rendering/RenderTextControl.h:
70635
706362014-02-21  ChangSeok Oh  <changseok.oh@collabora.com>
70637
70638        [GTK] Support WEBGL_draw_buffers extension.
70639        https://bugs.webkit.org/show_bug.cgi?id=129143
70640
70641        Reviewed by Dean Jackson.
70642
70643        Support the WEBGL_draw_buffers WebGL extension for gtk port. Relevant opengl APIs
70644        are exposed for WebGLRenderingContext to access them properly.
70645
70646        Covered by fast/canvas/webgl/webgl-draw-buffers.html
70647
70648        * platform/graphics/OpenGLShims.cpp:
70649        (WebCore::initializeOpenGLShims):
70650        * platform/graphics/OpenGLShims.h:
70651        * platform/graphics/opengl/Extensions3DOpenGL.cpp:
70652        (WebCore::Extensions3DOpenGL::supportsExtension):
70653        (WebCore::Extensions3DOpenGL::drawBuffersEXT):
70654
706552014-02-21  ChangSeok Oh  <changseok.oh@collabora.com>
70656
70657        Mac port uses ANGLE_instanced_arrays related apis through those in GraphicsContext3DCommon.cpp
70658        https://bugs.webkit.org/show_bug.cgi?id=128803
70659
70660        Reviewed by Dean Jackson.
70661
70662        Merge mac port implementation of ANGLE_instanced_arrays into common code.
70663
70664        No new tests, no functionality changed.
70665
70666        * platform/graphics/mac/GraphicsContext3DMac.mm:
70667        * platform/graphics/opengl/Extensions3DOpenGL.cpp:
70668        (WebCore::Extensions3DOpenGL::drawArraysInstanced):
70669        (WebCore::Extensions3DOpenGL::drawElementsInstanced):
70670        (WebCore::Extensions3DOpenGL::vertexAttribDivisor):
70671        * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
70672        (WebCore::GraphicsContext3D::vertexAttribDivisor):
70673
706742014-02-21  Myles C. Maxfield  <mmaxfield@apple.com>
70675
70676        After copy and paste, cursor may appear to be above the bottom of content
70677        https://bugs.webkit.org/show_bug.cgi?id=129167
70678
70679        Reviewed by Ryosuke Niwa.
70680
70681        Adding a clear:both to the end of content.
70682
70683        I can't handle the case of the cursor appearing above the bottom of
70684        absolutely positioned divs (of the case of floats inside absolutely
70685        positioned divs) because you can't know where the bottom of a div
70686        will end up being rendered (it is affected by things like browser
70687        window width and text size settings). Therefore, the only case I
70688        can handle is the case where there is a floating div in the same
70689        level as the document itself.
70690
70691        Test: editing/pasteboard/copy-paste-inserts-clearing-div.html
70692
70693        * editing/EditingStyle.cpp:
70694        (WebCore::EditingStyle::isFloating):
70695        * editing/EditingStyle.h:
70696        * editing/markup.cpp:
70697        (WebCore::StyledMarkupAccumulator::StyledMarkupAccumulator):
70698        (WebCore::StyledMarkupAccumulator::appendElement):
70699        (WebCore::createMarkupInternal):
70700
707012014-02-21  Dean Jackson  <dino@apple.com>
70702
70703        [iOS Media] Wireless target UI
70704        https://bugs.webkit.org/show_bug.cgi?id=129189
70705        <rdar://problem/15349928>
70706        <rdar://problem/16100060>
70707
70708        Reviewed by Eric Carlson.
70709
70710        Implement a prototype UI for wireless playback targets. The UI
70711        doesn't currently work, but can be simulated via a class variable
70712        in ControllerIOS.
70713
70714        * Modules/mediacontrols/mediaControlsiOS.css:
70715        (audio::-webkit-media-controls-panel button): Reset the default style of
70716        button elements, to avoid getting a border.
70717        (audio::-webkit-media-controls-wireless-playback-status): Holds the UI showing
70718        the user that the media is playing on another target.
70719        (audio::-webkit-media-controls-wireless-playback-status.hidden):
70720        (audio::-webkit-media-controls-wireless-playback-picker-button): The button to
70721        trigger selection of targets.
70722        (audio::-webkit-media-controls-wireless-playback-picker-button.active):
70723        (audio::-webkit-media-controls-panel): This needs to be position absolute for
70724        the wireless playback status to fill the viewport.
70725        * Modules/mediacontrols/mediaControlsiOS.js:
70726        (ControllerIOS): Check for targets.
70727        (ControllerIOS.prototype.addVideoListeners):
70728        (ControllerIOS.prototype.removeVideoListeners):
70729        (ControllerIOS.prototype.UIString): New method to return localized strings (with
70730        a FIXME).
70731        (ControllerIOS.prototype.shouldHaveAnyUI): Needs to display if there is a wireless
70732        target.
70733        (ControllerIOS.prototype.currentPlaybackTargetIsWireless):
70734        (ControllerIOS.prototype.updateWirelessPlaybackStatus): Create the status content,
70735        replacing the device name if it is available.
70736        (ControllerIOS.prototype.updateWirelessTargetAvailable):
70737        (ControllerIOS.prototype.createControls):
70738        (ControllerIOS.prototype.configureInlineControls):
70739        (ControllerIOS.prototype.handleWirelessPlaybackChange):
70740        (ControllerIOS.prototype.handleWirelessTargetAvailableChange):
70741        (ControllerIOS.prototype.handleWirelessPickerButtonClicked):
70742
707432014-02-21  Jer Noble  <jer.noble@apple.com>
70744
70745        Make a generic CDMPrivateMediaPlayer and move its CDMSession into platform/.
70746        https://bugs.webkit.org/show_bug.cgi?id=129164
70747
70748        Reviewed by Eric Carlson.
70749
70750        Move the session created by CDMPrivateAVFoundation into platform, and rename
70751        CDMPrivateAVFoundation to CDMPrivateMediaPlayer. Future media engines who want
70752        to support a keysystem from within the media engine can create their own
70753        CDMSession as part of the MediaPlayerPrivate interface.
70754
70755        * Modules/encryptedmedia/CDM.cpp:
70756        (WebCore::installedCDMFactories):
70757        (WebCore::CDM::createSession):
70758        * Modules/encryptedmedia/CDM.h:
70759        * Modules/encryptedmedia/CDMPrivate.h:
70760        * Modules/encryptedmedia/MediaKeySession.cpp:
70761        * Modules/encryptedmedia/MediaKeySession.h:
70762        * Modules/encryptedmedia/CDMPrivateAVFoundation.mm: Removed.
70763        * Modules/encryptedmedia/CDMPrivateMediaPlayer.cpp: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.cpp.
70764        (WebCore::CDMPrivateMediaPlayer::supportsKeySystem):
70765        (WebCore::CDMPrivateMediaPlayer::supportsKeySystemAndMimeType):
70766        (WebCore::CDMPrivateMediaPlayer::supportsMIMEType):
70767        (WebCore::CDMPrivateMediaPlayer::createSession):
70768        * Modules/encryptedmedia/CDMPrivateMediaPlayer.h: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.h.
70769        (WebCore::CDMPrivateMediaPlayer::create):
70770        (WebCore::CDMPrivateMediaPlayer::~CDMPrivateMediaPlayer):
70771        (WebCore::CDMPrivateMediaPlayer::cdm):
70772        (WebCore::CDMPrivateMediaPlayer::CDMPrivateMediaPlayer):
70773        * WebCore.xcodeproj/project.pbxproj:
70774        * platform/graphics/CDMSession.h: Extracted from CDMPrivateAVFoundation.h.
70775        (WebCore::CDMSessionClient::~CDMSessionClient):
70776        (WebCore::CDMSession::CDMSession):
70777        (WebCore::CDMSession::~CDMSession):
70778        * platform/graphics/MediaPlayer.cpp:
70779        (WebCore::MediaPlayer::createSession):
70780        * platform/graphics/MediaPlayer.h:
70781        * platform/graphics/MediaPlayerPrivate.h:
70782        (WebCore::MediaPlayerPrivateInterface::createSession):
70783        * platform/graphics/avfoundation/objc/CDMSessionAVFoundationObjC.h: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.h.
70784        (WebCore::CDMSessionAVFoundationObjC::~CDMSessionAVFoundationObjC):
70785        * platform/graphics/avfoundation/objc/CDMSessionAVFoundationObjC.mm: Renamed from Source/WebCore/Modules/encryptedmedia/CDMPrivateAVFoundation.mm.
70786        (WebCore::CDMSessionAVFoundationObjC::CDMSessionAVFoundationObjC):
70787        (WebCore::CDMSessionAVFoundationObjC::generateKeyRequest):
70788        (WebCore::CDMSessionAVFoundationObjC::releaseKeys):
70789        (WebCore::CDMSessionAVFoundationObjC::update):
70790        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
70791        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
70792        (WebCore::MediaPlayerPrivateAVFoundationObjC::createSession):
70793        * testing/MockCDM.cpp:
70794        (WebCore::MockCDMSession::setClient):
70795        (WebCore::MockCDM::createSession):
70796        * testing/MockCDM.h:
70797
707982014-02-21  Jer Noble  <jer.noble@apple.com>
70799
70800        Add a supportsKeySystem media engine factory parameter.
70801        https://bugs.webkit.org/show_bug.cgi?id=129161
70802
70803        Reviewed by Eric Carlson.
70804
70805        Add a new parameter to the MediaPlayerFactory to allow registered media
70806        engines to be queried for keySystem support:
70807        * platform/graphics/MediaPlayer.cpp:
70808        (WebCore::MediaPlayerFactory::MediaPlayerFactory):
70809        (WebCore::MediaPlayer::supportsKeySystem):
70810        * platform/graphics/MediaPlayer.h:
70811
70812        Support this new field in MediaPlayerPrivateAVFoundationObjC:
70813        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
70814        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
70815        (WebCore::MediaPlayerPrivateAVFoundationObjC::registerMediaEngine):
70816        (WebCore::keySystemIsSupported):
70817        (WebCore::MediaPlayerPrivateAVFoundationObjC::supportsKeySystem):
70818        (WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource):
70819
70820        Add an empty field for SupportsKeySystem to the remaining media engines:
70821        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
70822        (WebCore::MediaPlayerPrivateAVFoundationCF::registerMediaEngine):
70823        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
70824        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::registerMediaEngine):
70825        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
70826        (WebCore::MediaPlayerPrivateGStreamer::registerMediaEngine):
70827        * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
70828        (WebCore::MediaPlayerPrivateIOS::registerMediaEngine):
70829        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
70830        (WebCore::MediaPlayerPrivateQTKit::registerMediaEngine):
70831        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
70832        (WebCore::MediaPlayerPrivateQuickTimeVisualContext::registerMediaEngine):
70833        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
70834        (WebCore::MockMediaPlayerMediaSource::registerMediaEngine):
70835
708362014-02-21  Benjamin Poulain  <bpoulain@apple.com>
70837
70838        Fix WebCore's internals after r164505
70839
70840        * testing/Internals.cpp:
70841        (WebCore::Internals::findEditingDeleteButton): The call became ambiguous after r164505.
70842
708432014-02-21  Joseph Pecoraro  <pecoraro@apple.com>
70844
70845        Web Inspector: JSContext inspection should report exceptions in the console
70846        https://bugs.webkit.org/show_bug.cgi?id=128776
70847
70848        Reviewed by Timothy Hatcher.
70849
70850        Include some clean up of ConsoleMessage and ScriptCallStack construction.
70851
70852        Covered by existing tests.
70853
70854        * bindings/js/JSDOMBinding.cpp:
70855        (WebCore::reportException):
70856        Simplify code now that createStackTraceFromException handles it.
70857
70858        * page/ContentSecurityPolicy.cpp:
70859        (WebCore::gatherSecurityPolicyViolationEventData):
70860        (WebCore::ContentSecurityPolicy::reportViolation):
70861        ScriptCallStack can give us the first non-native callframe.
70862
70863        * inspector/InspectorResourceAgent.cpp:
70864        (WebCore::InspectorResourceAgent::buildInitiatorObject):
70865        * inspector/PageDebuggerAgent.cpp:
70866        (WebCore::PageDebuggerAgent::breakpointActionLog):
70867        * inspector/TimelineRecordFactory.cpp:
70868        (WebCore::TimelineRecordFactory::createGenericRecord):
70869        * page/Console.cpp:
70870        (WebCore::internalAddMessage):
70871        (WebCore::Console::profile):
70872        (WebCore::Console::profileEnd):
70873        (WebCore::Console::timeEnd):
70874        * page/ContentSecurityPolicy.cpp:
70875        (WebCore::gatherSecurityPolicyViolationEventData):
70876        (WebCore::ContentSecurityPolicy::reportViolation):
70877        * page/DOMWindow.cpp:
70878        (WebCore::DOMWindow::postMessage):
70879
708802014-02-21  Benjamin Poulain  <benjamin@webkit.org>
70881
70882        jsDocumentPrototypeFunctionGetElementById should not create an AtomicString for the function argument
70883        https://bugs.webkit.org/show_bug.cgi?id=128893
70884
70885        Reviewed by Darin Adler.
70886
70887        The declaration of TreeScope::getElementById() was taking an AtomicString as the parameter.
70888        Because of this, all the call sites manipulating String were creating and keeping alive an AtomicString
70889        to make the call.
70890
70891        This had two negative consequences:
70892        -The call sites were ref-ing the ID's atomic string for no reason.
70893        -When there is no ID associated with the input string, an atomic string was created for the sole
70894         purpose of failing the query. Since IDs are stored as AtomicString, if there is not an existing
70895         AtomicString for the input, there is no reason to query anything.
70896
70897        * WebCore.exp.in:
70898        * bindings/js/JSDOMBinding.cpp:
70899        (WebCore::findAtomicString): Update this after the rename.
70900
70901        * bindings/scripts/CodeGeneratorObjC.pm:
70902        (GenerateImplementation):
70903        * bindings/scripts/IDLAttributes.txt:
70904        Now that there are two overloads for TreeScope::getElementById(), the conversion from NSString*
70905        is ambiguous. I add the keyword ObjCExplicitAtomicString to force an explicit conversion to AtomicString.
70906
70907        * dom/Document.idl:
70908        * dom/TreeScope.cpp:
70909        (WebCore::TreeScope::getElementById):
70910        When getting an AtomicString, the case of a empty string is not important, use isNull() instead.
70911        When getting a String, get the corresponding AtomicString if any and use that for getting the element.
70912
70913        * dom/TreeScope.h:
70914        * html/FTPDirectoryDocument.cpp:
70915        (WebCore::FTPDirectoryDocumentParser::loadDocumentTemplate):
70916        Solve the ambiguous call.
70917
70918        * svg/SVGAElement.cpp:
70919        (WebCore::SVGAElement::defaultEventHandler):
70920        This is a wonderful candidate for substringSharingImpl. The substring does not survive the call since
70921        the new getElementById never create any AtomicString.
70922
70923        * svg/SVGSVGElement.cpp:
70924        (WebCore::SVGSVGElement::getElementById):
70925        It looks like there are opportunities to get faster here, Ryosuke should have a look.
70926
70927        * svg/SVGSVGElement.h:
70928        * xml/XMLTreeViewer.cpp:
70929        (WebCore::XMLTreeViewer::transformDocumentToTreeView):
70930        Unrelated cleanup: noStyleMessage was useless.
70931
709322014-02-21  Daniel Bates  <dabates@apple.com>
70933
70934        COL element in table has 0 for offsetWidth
70935        https://bugs.webkit.org/show_bug.cgi?id=15277
70936
70937        Reviewed by David Hyatt.
70938
70939        Implements offset{Left, Top, Width, Height} for table columns and column groups
70940        per section Extensions to the HTMLElement Interface of the CSSOM View spec,
70941        <http://www.w3.org/TR/cssom-view/#extensions-to-the-htmlelement-interface> (Draft 17 December 2013).
70942
70943        For now, we fail almost all of the offset{Height, Top} sub-tests in the included test
70944        for the separate border model as we need to fix <https://bugs.webkit.org/show_bug.cgi?id=128988>.
70945
70946        Test: fast/table/col-and-colgroup-offsets.html
70947
70948        * rendering/RenderTable.cpp:
70949        (WebCore::RenderTable::RenderTable): Initialize cached column offset top and offset height.
70950        We cache these offsets since they are the same for all columns in the table.
70951        (WebCore::RenderTable::invalidateCachedColumns): Clear cached effective column index map.
70952        (WebCore::RenderTable::invalidateCachedColumnOffsets): Added.
70953        (WebCore::RenderTable::layout): Invalidate cached column offsets as the location or height
70954        of one or more sections may have changed.
70955        (WebCore::RenderTable::updateColumnCache): Modified to build effective column index map.
70956        (WebCore::RenderTable::effectiveIndexOfColumn): Added.
70957        (WebCore::RenderTable::offsetTopForColumn): Added.
70958        (WebCore::RenderTable::offsetLeftForColumn): Added.
70959        (WebCore::RenderTable::offsetWidthForColumn): Added.
70960        (WebCore::RenderTable::offsetHeightForColumn): Added.
70961        * rendering/RenderTable.h: Make isTableColumnGroupWithColumnChildren() const.
70962        * rendering/RenderTableCol.cpp:
70963        (WebCore::RenderTableCol::offsetLeft): Added; turns around and calls RenderTable::offsetLeftForColumn().
70964        (WebCore::RenderTableCol::offsetTop): Added; turns around and calls RenderTable::offsetTopForColumn().
70965        (WebCore::RenderTableCol::offsetWidth): Added; turns around and calls RenderTable::offsetWidthForColumn().
70966        (WebCore::RenderTableCol::offsetHeight): Added; turns around and calls RenderTable::offsetHeightForColumn().
70967        * rendering/RenderTableCol.h:
70968
709692014-02-21  Enrica Casucci  <enrica@apple.com>
70970
70971        Build fix for iOS after r164498.
70972
70973        Unreviewed.
70974
70975        * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
70976        (WebCore::MediaPlayerPrivateIOS::buffered):
70977
709782014-02-21  Ryosuke Niwa  <rniwa@webkit.org>
70979
70980        Disallow the use of -webkit-user-modify on shadow pseudo elements
70981        https://bugs.webkit.org/show_bug.cgi?id=129144
70982
70983        Reviewed by Geoffrey Garen.
70984
70985        Completely disallow -webkit-user-modify on user agent (builtin) pseudo elements.
70986
70987        We've already had rules to do this in html.css but just hard code it into the engine
70988        in order to eliminate the all uses of -webkit-user-modify in html.css.
70989
70990        * css/StyleResolver.cpp:
70991        (WebCore::StyleResolver::adjustRenderStyle):
70992        * css/html.css:
70993        (input::-webkit-textfield-decoration-container):
70994        (input::-webkit-clear-button):
70995        (input[type="search"]::-webkit-search-cancel-button):
70996        (input[type="search"]::-webkit-search-decoration):
70997        (input[type="search"]::-webkit-search-results-decoration):
70998        (input[type="search"]::-webkit-search-results-button):
70999        (input::-webkit-inner-spin-button):
71000        (input::-webkit-input-speech-button):
71001        (input::-webkit-input-placeholder, isindex::-webkit-input-placeholder):
71002        (input[type="file"]::-webkit-file-upload-button):
71003        (input[type="range"]::-webkit-slider-container, input[type="range"]::-webkit-media-slider-container):
71004        (input[type="range"]::-webkit-slider-runnable-track):
71005        (input[type="range"]::-webkit-slider-thumb, input[type="range"]::-webkit-media-slider-thumb):
71006        (input[type="color"]::-webkit-color-swatch-wrapper):
71007        (input[type="color"]::-webkit-color-swatch):
71008        (::-webkit-validation-bubble):
71009        (::-webkit-validation-bubble-message):
71010        (::-webkit-validation-bubble-text-block):
71011        (::-webkit-validation-bubble-heading):
71012        (::-webkit-validation-bubble-arrow):
71013        (::-webkit-validation-bubble-arrow-clipper):
71014        (meter::-webkit-meter-inner-element):
71015        (meter::-webkit-meter-bar):
71016        (meter::-webkit-meter-optimum-value):
71017        (meter::-webkit-meter-suboptimum-value):
71018        (meter::-webkit-meter-even-less-good-value):
71019        (progress::-webkit-progress-inner-element):
71020        (progress::-webkit-progress-bar):
71021        (progress::-webkit-progress-value):
71022
710232014-02-21  Eric Carlson  <eric.carlson@apple.com>
71024
71025        Fix TimeRanges layering violations
71026        https://bugs.webkit.org/show_bug.cgi?id=128717
71027
71028        Reviewed by Jer Noble.
71029
71030        No new tests, no functionality changed.
71031
71032        * CMakeLists.txt:
71033        * GNUmakefile.list.am: Add PlatformTimeRanges.
71034
71035        * Modules/mediasource/MediaSource.cpp:
71036        (WebCore::MediaSource::buffered): TimeRanges -> PlatformTimeRanges.
71037        * Modules/mediasource/MediaSource.h:
71038
71039        * Modules/mediasource/SourceBuffer.cpp:
71040        (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): TimeRanges* -> TimeRanges&.
71041
71042        * WebCore.exp.in: Update for signature changes.
71043
71044        * WebCore.vcxproj/WebCore.vcxproj:
71045        * WebCore.vcxproj/WebCore.vcxproj.filters:
71046        * WebCore.xcodeproj/project.pbxproj: Add PlatformTimeRanges.
71047
71048        * html/HTMLMediaElement.cpp:
71049        (WebCore::HTMLMediaElement::percentLoaded): Create TimeRanges from PlatformTimeRanges.
71050        (WebCore::HTMLMediaElement::buffered): Ditto.
71051        (WebCore::HTMLMediaElement::seekable): Ditto.
71052
71053        * html/MediaController.cpp:
71054        (MediaController::buffered): TimeRanges* -> TimeRanges&.
71055        (MediaController::seekable): Ditto.
71056        (MediaController::played): Ditto.
71057
71058        Move all of the logic into PlatformTimeRanges. Change API to take TimeRanges& instead of TimeRanges*.
71059        * html/TimeRanges.cpp:
71060        (WebCore::TimeRanges::create): Move to .cpp from .h.
71061        (WebCore::TimeRanges::TimeRanges): Initialize the PlatformTimeRanges member variable.
71062        (WebCore::TimeRanges::start): Passthrough to PlatformTimeRanges.
71063        (WebCore::TimeRanges::end): Ditto.
71064        (WebCore::TimeRanges::invert): Ditto.
71065        (WebCore::TimeRanges::copy): Ditto.
71066        (WebCore::TimeRanges::intersectWith): Ditto.
71067        (WebCore::TimeRanges::unionWith): Ditto.
71068        (WebCore::TimeRanges::length): Ditto.
71069        (WebCore::TimeRanges::add): Ditto.
71070        (WebCore::TimeRanges::contain): Ditto.
71071        (WebCore::TimeRanges::find): Ditto.
71072        (WebCore::TimeRanges::nearest): Ditto.
71073        (WebCore::TimeRanges::totalDuration): Ditto.
71074        * html/TimeRanges.h:
71075
71076        * platform/graphics/MediaPlayer.cpp:
71077        (WebCore::NullMediaPlayerPrivate::buffered): TimeRanges -> PlatformTimeRanges.
71078        (WebCore::MediaPlayer::buffered): Ditto.
71079        (WebCore::MediaPlayer::seekable): Ditto.
71080        * platform/graphics/MediaPlayer.h:
71081        * platform/graphics/MediaPlayerPrivate.h:
71082
71083        * platform/graphics/MediaSourcePrivateClient.h:
71084
71085        * platform/graphics/PlatformTimeRanges.cpp: Added.
71086        * platform/graphics/PlatformTimeRanges.h: Added.
71087
71088        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
71089        (WebCore::MediaPlayerPrivateAVFoundation::buffered): TimeRanges -> PlatformTimeRanges.
71090        (WebCore::MediaPlayerPrivateAVFoundation::loadedTimeRangesChanged): Drive-by fix to log
71091            FunctionType notifications. ASSERT when passed an unknown notification.
71092
71093        * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
71094        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
71095        (WebCore::MediaPlayerPrivateAVFoundationCF::platformBufferedTimeRanges):  TimeRanges -> PlatformTimeRanges.
71096        * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
71097        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
71098        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
71099        (WebCore::MediaPlayerPrivateAVFoundationObjC::currentTime): Ditto.
71100        (WebCore::MediaPlayerPrivateAVFoundationObjC::platformBufferedTimeRanges): Ditto.
71101
71102        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:
71103        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
71104        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekable): Ditto.
71105        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered): Ditto.
71106
71107        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
71108        (WebCore::MediaPlayerPrivateGStreamer::buffered): Ditto.
71109        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
71110
71111        * platform/graphics/ios/MediaPlayerPrivateIOS.h:
71112        * platform/graphics/ios/MediaPlayerPrivateIOS.mm:
71113        (WebCore::MediaPlayerPrivateIOS::buffered): Ditto.
71114
71115        * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
71116        * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
71117        (WebCore::MediaPlayerPrivateQTKit::buffered): Ditto.
71118
71119        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
71120        (WebCore::MediaPlayerPrivateQuickTimeVisualContext::buffered): Ditto.
71121        * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
71122
71123        * platform/graphics/wince/MediaPlayerPrivateWinCE.h:
71124
71125        * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:
71126        (WebCore::MockMediaPlayerMediaSource::buffered): Ditto.
71127        (WebCore::MockMediaPlayerMediaSource::advanceCurrentTime): Ditto.
71128        * platform/mock/mediasource/MockMediaPlayerMediaSource.h:
71129
711302014-02-21  Enrica Casucci  <enrica@apple.com>
71131
71132        Support WebSelections in WK2 on iOS.
71133        https://bugs.webkit.org/show_bug.cgi?id=127015
71134        <rdar://problem/15211964>
71135
71136        Reviewed by Benjamin Poulain.
71137
71138        Adding some exports.
71139
71140        * WebCore.exp.in:
71141
711422014-02-21  Benjamin Poulain  <bpoulain@apple.com>
71143
71144        'mouseenter' mouse compat event not fired when listeners for touch events
71145        https://bugs.webkit.org/show_bug.cgi?id=128534
71146
71147        Reviewed by Andreas Kling.
71148
71149        The code dispatching mouseenter and mouseleave events was making the assumption that
71150        only mouse move would cause Document::updateHoverActiveState.
71151
71152        This is not true in some cases. In the case of this bug, the first touch handler sets
71153        the hover state. From there, the code handling enter/leave is in an inconsistent state.
71154
71155        This patch changes the delivery of mouse enter/leave events to be done through the regular
71156        processing of mouse events. The update is done with the mouseover and mouseout events.
71157
71158        * dom/Document.cpp:
71159        (WebCore::Document::prepareMouseEvent):
71160        (WebCore::Document::updateHoverActiveState):
71161        * dom/Document.h:
71162        * page/EventHandler.cpp:
71163        (WebCore::nearestCommonHoverAncestor):
71164        (WebCore::hierarchyHasCapturingEventListeners):
71165        (WebCore::EventHandler::updateMouseEventTargetNode):
71166
711672014-02-21  Jon Honeycutt  <jhoneycutt@apple.com>
71168
71169        Crash reloading page with position: fixed content
71170        https://bugs.webkit.org/show_bug.cgi?id=129119
71171        <rdar://problem/16127090>
71172
71173        Reviewed by Brent Fulgham.
71174
71175        Test: platform/mac-wk2/tiled-drawing/crash-reloading-with-position-fixed-content.html
71176
71177        * page/scrolling/ScrollingTree.cpp:
71178        (WebCore::ScrollingTree::removeDestroyedNodes):
71179        Check the node's ID against the latched node's ID before the node is
71180        removed from the tree.
71181
711822014-02-21  Joseph Pecoraro  <pecoraro@apple.com>
71183
71184        Revert r164486, causing a number of test failures.
71185
71186        Unreviewed rollout.
71187
711882014-02-21  David Kilzer  <ddkilzer@apple.com>
71189
71190        StyleResolver::loadPendingImage() should take a reference to StylePendingImage
71191        <http://webkit.org/b/129021>
71192
71193        Reviewed by Brent Fulgham.
71194
71195        * css/StyleResolver.cpp:
71196        (WebCore::StyleResolver::loadPendingImage): Change pendingImage
71197        parameter to a reference.
71198        (WebCore::StyleResolver::loadPendingShapeImage): Update to use
71199        references.
71200        (WebCore::StyleResolver::loadPendingImages): Ditto.
71201        * css/StyleResolver.h:
71202        (WebCore::StyleResolver::loadPendingImage): Change pendingImage
71203        parameter to a reference.
71204
712052014-02-21  Joseph Pecoraro  <pecoraro@apple.com>
71206
71207        Web Inspector: JSContext inspection should report exceptions in the console
71208        https://bugs.webkit.org/show_bug.cgi?id=128776
71209
71210        Reviewed by Timothy Hatcher.
71211
71212        Include some clean up of ConsoleMessage and ScriptCallStack construction.
71213
71214        Covered by existing tests.
71215
71216        * bindings/js/JSDOMBinding.cpp:
71217        (WebCore::reportException):
71218        Simplify code now that createStackTraceFromException handles it.
71219
71220        * page/ContentSecurityPolicy.cpp:
71221        (WebCore::gatherSecurityPolicyViolationEventData):
71222        (WebCore::ContentSecurityPolicy::reportViolation):
71223        ScriptCallStack can give us the first non-native callframe.
71224
71225        * inspector/InspectorResourceAgent.cpp:
71226        (WebCore::InspectorResourceAgent::buildInitiatorObject):
71227        * inspector/PageDebuggerAgent.cpp:
71228        (WebCore::PageDebuggerAgent::breakpointActionLog):
71229        * inspector/TimelineRecordFactory.cpp:
71230        (WebCore::TimelineRecordFactory::createGenericRecord):
71231        * page/Console.cpp:
71232        (WebCore::internalAddMessage):
71233        (WebCore::Console::profile):
71234        (WebCore::Console::profileEnd):
71235        (WebCore::Console::timeEnd):
71236        * page/ContentSecurityPolicy.cpp:
71237        (WebCore::gatherSecurityPolicyViolationEventData):
71238        (WebCore::ContentSecurityPolicy::reportViolation):
71239        * page/DOMWindow.cpp:
71240        (WebCore::DOMWindow::postMessage):
71241
712422014-02-21  Martin Hodovan  <mhodovan@inf.u-szeged.hu>
71243
71244        Fixing the !ENABLE(SVG_FONTS) build
71245        https://bugs.webkit.org/show_bug.cgi?id=129150
71246
71247        Reviewed by Anders Carlsson.
71248
71249        No new tests required.
71250
71251        * svg/SVGAltGlyphElement.cpp:
71252        * svg/SVGAltGlyphElement.h:
71253        * svg/svgtags.in:
71254
712552014-02-21  Radu Stavila  <stavila@adobe.com>
71256
71257        [CSS Regions] Use the named-flow-specific object RenderNamedFlowFragment instead of the generic RenderRegion whenever possible
71258        https://bugs.webkit.org/show_bug.cgi?id=128599
71259
71260        Reviewed by Andrei Bucur.
71261
71262        Use the named flow specific RenderNamedFlowFragment instead of the generic RenderRegion, whenever possible.
71263        Move named flow specific methods from RenderRegion to RenderNamedFlowFragment.
71264
71265        No new tests required.
71266
71267        * dom/Element.cpp:
71268        (WebCore::Element::renderNamedFlowFragment):
71269        (WebCore::Element::webkitRegionOverset):
71270        (WebCore::Element::webkitGetRegionFlowRanges):
71271        * dom/Element.h:
71272        * inspector/InspectorCSSAgent.cpp:
71273        (WebCore::InspectorCSSAgent::buildArrayForRegions):
71274        * rendering/PaintInfo.h:
71275        (WebCore::PaintInfo::PaintInfo):
71276        * rendering/RenderBlock.cpp:
71277        (WebCore::RenderBlock::paint):
71278        (WebCore::RenderBlock::paintObject):
71279        * rendering/RenderBox.cpp:
71280        (WebCore::RenderBox::paintBoxDecorations):
71281        (WebCore::RenderBox::pushContentsClip):
71282        (WebCore::RenderBox::layoutOverflowRectForPropagation):
71283        * rendering/RenderBox.h:
71284        * rendering/RenderBoxModelObject.cpp:
71285        (WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
71286        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
71287        * rendering/RenderBoxModelObject.h:
71288        * rendering/RenderInline.h:
71289        * rendering/RenderLayer.cpp:
71290        (WebCore::RenderLayer::paint):
71291        (WebCore::RenderLayer::paintLayer):
71292        (WebCore::RenderLayer::paintLayerContents):
71293        (WebCore::RenderLayer::paintLayerByApplyingTransform):
71294        (WebCore::RenderLayer::updatePaintingInfoForFragments):
71295        (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
71296        (WebCore::RenderLayer::paintBackgroundForFragments):
71297        (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
71298        (WebCore::RenderLayer::paintOutlineForFragments):
71299        (WebCore::RenderLayer::paintMaskForFragments):
71300        (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
71301        (WebCore::RenderLayer::calculateClipRects):
71302        * rendering/RenderLayer.h:
71303        * rendering/RenderNamedFlowFragment.cpp:
71304        (WebCore::RenderNamedFlowFragment::getRanges):
71305        * rendering/RenderNamedFlowFragment.h:
71306        * rendering/RenderNamedFlowThread.cpp:
71307        (WebCore::RenderNamedFlowThread::updateWritingMode):
71308        (WebCore::compareRenderNamedFlowFragments):
71309        (WebCore::addFragmentToList):
71310        (WebCore::RenderNamedFlowThread::addFragmentToNamedFlowThread):
71311        (WebCore::RenderNamedFlowThread::addRegionToThread):
71312        (WebCore::RenderNamedFlowThread::removeRegionFromThread):
71313        (WebCore::RenderNamedFlowThread::computeOversetStateForRegions):
71314        (WebCore::RenderNamedFlowThread::checkInvalidRegions):
71315        (WebCore::RenderNamedFlowThread::getRanges):
71316        (WebCore::RenderNamedFlowThread::checkRegionsWithStyling):
71317        (WebCore::RenderNamedFlowThread::clearRenderObjectCustomStyle):
71318        * rendering/RenderNamedFlowThread.h:
71319        * rendering/RenderRegion.cpp:
71320        * rendering/RenderRegion.h:
71321        * rendering/RenderReplaced.cpp:
71322        (WebCore::RenderReplaced::shouldPaint):
71323        * rendering/RenderReplica.cpp:
71324        (WebCore::RenderReplica::paint):
71325        * rendering/RootInlineBox.cpp:
71326        (WebCore::RootInlineBox::paint):
71327        * rendering/svg/RenderSVGRoot.cpp:
71328        (WebCore::RenderSVGRoot::paintReplaced):
71329
713302014-02-21  Andrei Bucur  <abucur@adobe.com>
71331
71332        [CSS Regions] Regions don't paint correctly in new-multicol elements
71333        https://bugs.webkit.org/show_bug.cgi?id=120711
71334
71335        Reviewed by David Hyatt.
71336
71337        This patch implements basic support for regions inside multi-column elements.
71338        Currently, the painting and hit-testing logic of CSS Regions is not aware of
71339        enclosing multi-column elements. The change is integrated at a layer level by
71340        making use of the pre-computed layer fragments during the painting and hit-testing
71341        phases for regions.
71342
71343        There are limitations such that self painting layers found inside the named flow
71344        thread layer will not be correctly processed because they don't go through the
71345        layer fragment collection step. This is not trivial to implement because the enclosing
71346        pagination layer provided by the multi-column element is not visibile from inside
71347        the named flow thread layer and they reside in different coordinate systems.
71348
71349        A side effect of this patch is the fix of regions incorrect clipping in certain
71350        cases (when both a region and its container clip their overflow, the region's
71351        content is visible outside the container).
71352
71353        Tests: fast/regions/region-clipping.html
71354               fast/regions/regions-in-multicol-bt.html
71355               fast/regions/regions-in-multicol-hover-overflow.html
71356               fast/regions/regions-in-multicol-hover.html
71357               fast/regions/regions-in-multicol-lr.html
71358               fast/regions/regions-in-multicol-rl.html
71359               fast/regions/regions-in-multicol.html
71360
71361        * rendering/RenderLayer.cpp:
71362        (WebCore::RenderLayer::paintLayerContents):
71363        (WebCore::RenderLayer::hitTestLayer):
71364        (WebCore::RenderLayer::paintFlowThreadIfRegionForFragments):
71365        (WebCore::RenderLayer::hitTestFlowThreadIfRegionForFragments):
71366        * rendering/RenderLayer.h:
71367
713682014-02-21  Mihai Tica  <mitica@adobe.com>
71369
71370        [CSS Blending] Refactor -webkit-blend-mode to -webkit-mix-blend-mode
71371        https://bugs.webkit.org/show_bug.cgi?id=128805
71372
71373        Reviewed by Dean Jackson.
71374
71375        The spec defines the mix-blend-mode property. This means that the
71376        prefixed version should be -webkit-mix-blend-mode, instead of
71377        -webkit-blend-mode.
71378
71379        * css/CSSComputedStyleDeclaration.cpp:
71380        (WebCore::ComputedStyleExtractor::propertyValue):
71381        * css/CSSParser.cpp:
71382        (WebCore::isValidKeywordPropertyAndValue):
71383        (WebCore::isKeywordPropertyID):
71384        (WebCore::CSSParser::parseValue):
71385        * css/CSSPropertyNames.in:
71386        * css/DeprecatedStyleBuilder.cpp:
71387        (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder):
71388
713892014-02-21  Ryosuke Niwa  <rniwa@webkit.org>
71390
71391        Bindings tests rebaseline after r164473.
71392
71393        * bindings/scripts/test/ObjC/DOMTestObj.mm:
71394        (-[DOMTestObj mutablePoint]):
71395        (-[DOMTestObj immutablePoint]):
71396        (-[DOMTestObj mutablePointFunction]):
71397        (-[DOMTestObj immutablePointFunction]):
71398        * bindings/scripts/test/ObjC/DOMTestTypedefs.mm:
71399        (-[DOMTestTypedefs immutablePointFunction]):
71400
714012014-02-21  Tim Horton  <timothy_horton@apple.com>
71402
71403        Remove removed symbol from exports list.
71404
71405        * WebCore.exp.in:
71406
714072014-02-20  ChangSeok Oh  <changseok.oh@collabora.com>
71408
71409        Rename EXT_draw_buffers to WEBGL_draw_buffers
71410        https://bugs.webkit.org/show_bug.cgi?id=128894
71411
71412        Reviewed by Dean Jackson.
71413
71414        I noticed the related spec has changed. Accordingly chromium also changed its implementation
71415        to meet the spec. So here I'd like to apply it to webkit as well.
71416
71417        Merged from Blink (patch by bajones):
71418        https://src.chromium.org/viewvc/blink?revision=152065&view=revision
71419
71420        Test: fast/canvas/webgl/webgl-draw-buffers.html
71421
71422        * CMakeLists.txt:
71423        * DerivedSources.cpp:
71424        * DerivedSources.make:
71425        * GNUmakefile.list.am:
71426        * WebCore.vcxproj/WebCore.vcxproj:
71427        * WebCore.vcxproj/WebCore.vcxproj.filters:
71428        * WebCore.xcodeproj/project.pbxproj:
71429        * bindings/js/JSWebGLRenderingContextCustom.cpp:
71430        (WebCore::toJS):
71431        * html/canvas/EXTDrawBuffers.idl: Removed.
71432        * html/canvas/WebGLDrawBuffers.cpp: Renamed from Source/WebCore/html/canvas/EXTDrawBuffers.cpp.
71433        (WebCore::WebGLDrawBuffers::WebGLDrawBuffers):
71434        (WebCore::WebGLDrawBuffers::~WebGLDrawBuffers):
71435        (WebCore::WebGLDrawBuffers::getName):
71436        (WebCore::WebGLDrawBuffers::create):
71437        (WebCore::WebGLDrawBuffers::supported):
71438        (WebCore::WebGLDrawBuffers::drawBuffersWEBGL):
71439        (WebCore::WebGLDrawBuffers::satisfiesWebGLRequirements):
71440        * html/canvas/WebGLDrawBuffers.h: Renamed from Source/WebCore/html/canvas/EXTDrawBuffers.h.
71441        * html/canvas/WebGLDrawBuffers.idl: Added.
71442        * html/canvas/WebGLExtension.h:
71443        * html/canvas/WebGLFramebuffer.cpp:
71444        (WebCore::WebGLFramebuffer::drawBuffersIfNecessary):
71445        * html/canvas/WebGLRenderingContext.cpp:
71446        (WebCore::WebGLRenderingContext::getExtension):
71447        (WebCore::WebGLRenderingContext::getParameter):
71448        (WebCore::WebGLRenderingContext::getSupportedExtensions):
71449        (WebCore::WebGLRenderingContext::validateFramebufferFuncParameters):
71450        (WebCore::WebGLRenderingContext::supportsDrawBuffers):
71451        * html/canvas/WebGLRenderingContext.h:
71452
714532014-02-20  Ryosuke Niwa  <rniwa@webkit.org>
71454
71455        m_ancestorDisabledState should never be unknown
71456        https://bugs.webkit.org/show_bug.cgi?id=129084
71457
71458        Reviewed by Benjamin Poulain.
71459
71460        In order to resolve the bug 129035, a text form control elements needs to synchronously change
71461        its inner text element's editability by setting or unsetting contenteditable content attribute.
71462        Before this patch, we could not do this because editability of a text form control dependent on
71463        its disabled-ness which was only computed lazily via updateAncestorDisabledState().
71464
71465        This patch makes HTMLFieldSetElement and HTMLFormControlElement update this state synchronously.
71466        To avoid O(k) DOM traversal, where k is the depth of the tree, in insertedInto and removedFrom of
71467        HTMLFormControlElement on most pages, a new document-level flag, m_disabledFieldsetElementsCount,
71468        has been added to indicate whether the document contains any disabled fieldset or not.
71469
71470        Also renamed the misleadingly named disabledAttributeChanged to disabledStateChanged, and added
71471        new function of the same name (disabledAttributeChanged) to be used by HTMLFieldSetElement
71472        for keeping the document-level flag up-to-date upon disabled attribute changes.
71473
71474        Tests: fast/forms/fieldset/fieldset-disabled-2.html
71475
71476        * dom/Document.cpp:
71477        (WebCore::Document::Document): Initializes newly added m_disabledFieldsetElementsCount.
71478        (WebCore::Document::~Document): Assert that we've done house keeping right.
71479        * dom/Document.h:
71480        (WebCore::Document::hasDisabledFieldsetElement): Added.
71481        (WebCore::Document::addDisabledFieldsetElement): Added.
71482        (WebCore::Document::removeDisabledFieldsetElement): Added.
71483
71484        * html/HTMLFieldSetElement.cpp:
71485        (WebCore::HTMLFieldSetElement::~HTMLFieldSetElement): Removes itself from the owner document.
71486
71487        (WebCore::updateFromControlElementsAncestorDisabledStateUnder): Added. Updates startNode and
71488        its descendants' ancestor disabled flag. We don't update controls under another disabled
71489        fieldset element since disabled-ness of those controls aren't affected by startNode.
71490
71491        (WebCore::HTMLFieldSetElement::disabledAttributeChanged): Call addDisabledFieldsetElement and
71492        removeDisabledFieldsetElement to update the owner document's flag.
71493
71494        (WebCore::HTMLFieldSetElement::disabledStateChanged): Renamed from disabledAttributeChanged. 
71495        Enable form control elements under the first legend element and disable or enable other
71496        descendent form controls in accordance with the presence of disabled content attribute.
71497
71498        (WebCore::HTMLFieldSetElement::childrenChanged): Update disabled-ness of form controls under
71499        child legend elements because controls aren't disabled in the first legend element, and adding
71500        or removing child elements may have changed the first legend element.
71501
71502        (WebCore::HTMLFieldSetElement::didMoveToNewDocument): Update the flag on the owner document.
71503        * html/HTMLFieldSetElement.h:
71504
71505        * html/HTMLFormControlElement.cpp:
71506        (WebCore::HTMLFormControlElement::HTMLFormControlElement):
71507        (WebCore::HTMLFormControlElement::computeIsDisabledByFieldsetAncestor): Returns boolean instead of
71508        updating m_ancestorDisabledState internally. Also renamed from updateAncestorDisabledState.
71509
71510        (WebCore::HTMLFormControlElement::setAncestorDisabled): Replaced ancestorDisabledStateWasChanged.
71511        This function updates m_disabledByAncestorFieldset and calls disabledAttributeChanged as needed.
71512
71513        (WebCore::HTMLFormControlElement::disabledAttributeChanged): Added. Calls disabledStateChanged.
71514        (WebCore::HTMLFormControlElement::disabledStateChanged): Renamed from disabledAttributeChanged.
71515
71516        (WebCore::HTMLFormControlElement::insertedInto): Update m_disabledByAncestorFieldset if there is
71517        a possibility (i.e. the document contains any disabled fieldset element) that this form control
71518        is inserted under a disabled fieldset element.
71519
71520        (WebCore::HTMLFormControlElement::removedFrom): If this form control element is not disabled by
71521        a fieldset ancestor, then there is nothing to do. If it is, then check to see if the element is
71522        still disabled now that we've lost some ancestors.
71523
71524        (WebCore::HTMLFormControlElement::isDisabledFormControl): No longer updates m_ancestorDisabledState
71525        lazily since m_disabledByAncestorFieldset is never ambiguous now.
71526
71527        * html/HTMLFormControlElement.h:
71528        (WebCore::HTMLFormControlElement::disabledByAncestorFieldset): Added.
71529
715302014-02-20  Zalan Bujtas  <zalan@apple.com>
71531
71532        Remove redundant deviceScaleFactor() functions and make callers use Document::deviceScaleFactor() when accessible.
71533        https://bugs.webkit.org/show_bug.cgi?id=129137
71534
71535        Reviewed by Simon Fraser.
71536
71537        No change in behavior.
71538
71539        * editing/DeleteButtonController.cpp:
71540        (WebCore::DeleteButtonController::createDeletionUI):
71541        * page/Page.cpp:
71542        * page/Page.h:
71543        * platform/graphics/GraphicsContext.cpp:
71544        (WebCore::GraphicsContext::GraphicsContext):
71545        * platform/graphics/GraphicsContext.h:
71546        * platform/graphics/cg/GraphicsContextCG.cpp:
71547        (WebCore::GraphicsContext::platformInit):
71548        * rendering/RenderBoxModelObject.cpp:
71549        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
71550        (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
71551        * rendering/RenderImage.cpp:
71552        (WebCore::RenderImage::imageSizeForError):
71553        (WebCore::RenderImage::paintReplaced):
71554        * rendering/RenderLayer.cpp:
71555        (WebCore::RenderLayer::drawPlatformResizerImage):
71556        * rendering/RenderObject.cpp:
71557        (WebCore::RenderObject::drawLineForBoxSide):
71558        * rendering/RenderThemeMac.mm:
71559        (WebCore::RenderThemeMac::paintProgressBar):
71560        * rendering/svg/SVGRenderingContext.cpp:
71561        (WebCore::SVGRenderingContext::calculateTransformationToOutermostCoordinateSystem):
71562
715632014-02-20  David Kilzer  <ddkilzer@apple.com>
71564
71565        Stop generating Objective-C bindings for the SVG DOM
71566        <http://webkit.org/b/129107>
71567
71568        Reviewed by Timothy Hatcher.
71569
71570        Bug 114076 stopped compiling the Objective-C bindings for the
71571        SVG DOM, but we continued to generate the header and source
71572        files after that landed in r147822.  This patch also stops
71573        generating the unused header and source files.
71574
71575        * DerivedSources.make:
71576        - Split BINDING_IDLS into NON_SVG_BINDING_IDLS and
71577          SVG_BINDING_IDLS so that they may operated on separately.
71578        - Define BINDING_IDLS again as the full list of IDL files.
71579        - Rename DOM_CLASSES to JS_DOM_CLASSES so that JavaScript
71580          bindings are still generated for all IDL files.
71581        - Add OBJC_DOM_CLASSES so that Objective-C bindings are only
71582          generated for non-SVG IDL files.
71583
71584        * bindings/scripts/CodeGeneratorObjC.pm:
71585        (GetBaseClass):
71586        (GetPropertyAttributes):
71587        (AddIncludesForType):
71588        (GenerateHeader):
71589        (GenerateImplementation):
71590        - Remove support for SVG classes.
71591
715922014-02-20  Simon Fraser  <simon.fraser@apple.com>
71593
71594        RenderBox::updateShapeOutsideInfoAfterStyleChange shows up on profiles
71595        https://bugs.webkit.org/show_bug.cgi?id=129075
71596
71597        Reviewed by Dean Jackson.
71598
71599        updateShapeOutsideInfoAfterStyleChange() showed up on profiles in content
71600        with no shapes. Avoid calling this if no style has shapeOutside().
71601
71602        * rendering/RenderBox.cpp:
71603        (WebCore::RenderBox::styleDidChange):
71604
716052014-02-20  ChangSeok Oh  <changseok.oh@collabora.com>
71606
71607        Remove unused chromium stuff in Extensions3D
71608        https://bugs.webkit.org/show_bug.cgi?id=129086
71609
71610        Reviewed by Anders Carlsson.
71611
71612        Remove GL_CHROMIUM_copy_texture and GL_CHROMIUM_flipy interfaces since they are used nowhere.
71613
71614        No new tests since no functionality changed.
71615
71616        * platform/graphics/Extensions3D.h:
71617        * platform/graphics/opengl/Extensions3DOpenGL.cpp:
71618        * platform/graphics/opengl/Extensions3DOpenGL.h:
71619        * platform/graphics/opengl/Extensions3DOpenGLES.cpp:
71620        * platform/graphics/opengl/Extensions3DOpenGLES.h:
71621
716222014-02-20  Joseph Pecoraro  <pecoraro@apple.com>
71623
71624        [iOS] Assert / crash trying to draw empty checked input
71625        https://bugs.webkit.org/show_bug.cgi?id=129138
71626
71627        Reviewed by Simon Fraser.
71628
71629        Test: fast/forms/checkbox-empty-size.html
71630
71631        * rendering/RenderThemeIOS.mm:
71632        (WebCore::shortened):
71633        Avoid a divide by 0, but checking for the condition upfront.
71634
716352014-02-20  Benjamin Poulain  <bpoulain@apple.com>
71636
71637        Start fixing the view states driven by the WKScrollView
71638        https://bugs.webkit.org/show_bug.cgi?id=129140
71639
71640        Reviewed by Tim Horton and Simon Fraser.
71641
71642        * platform/graphics/ca/mac/TileController.mm:
71643        (WebCore::TileController::scaledExposedRect):
71644        That comment was more confusing than helping. FrameView-relative coordinates should not need
71645        scaling.
71646
716472014-02-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
71648
71649        Start to use std::unique_ptr for DragImageLoader
71650        https://bugs.webkit.org/show_bug.cgi?id=129078
71651
71652        Reviewed by Ryosuke Niwa.
71653
71654        As a step to use std::unique_ptr, this patch replace uses of OwnPtr and PassOwnPtr
71655        in the DragImageLoader class with std::unique_ptr. Besides DragImageLoader is set to
71656        non-copyable class.
71657
71658        * dom/Clipboard.cpp:
71659        (WebCore::Clipboard::setDragImage):
71660        * dom/Clipboard.h:
71661
716622014-02-20  Brady Eidson  <beidson@apple.com>
71663
71664        Move the image controls setting to Settings.in
71665        https://bugs.webkit.org/show_bug.cgi?id=129126
71666
71667        Reviewed by Tim Horton.
71668
71669        * page/Settings.cpp:
71670        (WebCore::Settings::Settings):
71671        * page/Settings.h:
71672        * page/Settings.in:
71673
716742014-02-20  Brady Eidson  <beidson@apple.com>
71675
71676        Add very basic image control rendering
71677        https://bugs.webkit.org/show_bug.cgi?id=129080
71678
71679        Reviewed by Tim Horton.
71680
71681        Test: fast/images/image-controls-basic.html
71682
71683        This patch is groundwork that adds a very basic image control that can render on top of images.
71684
71685        * dom/Node.h:
71686        (WebCore::Node:: isImageControlsRootElement): Returns false, unless you are an ImageControls object.
71687        * html/HTMLAttributeNames.in:
71688
71689        Teach HTMLImageElement how to understand an experimental attribute to install controls,
71690        how to actually build the DOM to attach to the shadow root, how to tear that DOM down,
71691        and how to make sure that Renderers are created for that DOM:
71692        * html/HTMLImageElement.cpp:
71693        (WebCore::HTMLImageElement::HTMLImageElement):
71694        (WebCore::HTMLImageElement::parseAttribute):
71695        (WebCore::HTMLImageElement::didAttachRenderers):
71696        (WebCore::HTMLImageElement::updateImageControls):
71697        (WebCore::HTMLImageElement::createImageControls):
71698        (WebCore::HTMLImageElement::destroyImageControls):
71699        (WebCore::HTMLImageElement::hasImageControls):
71700        (WebCore::HTMLImageElement::childShouldCreateRenderer):
71701        * html/HTMLImageElement.h:
71702        (WebCore::HTMLImageElement::hasShadowControls): For RenderImage to query when it is constructed. 
71703
71704        Add a generic, platform independent ImageControls root element that does nothing:
71705        * html/shadow/ImageControlsRootElement.cpp: Added.
71706        (WebCore::ImageControlsRootElement::maybeCreate):
71707        (WebCore::ImageControlsRootElement::ImageControlsRootElement):
71708        (WebCore::ImageControlsRootElement::~ImageControlsRootElement):
71709        * html/shadow/ImageControlsRootElement.h: Added.
71710
71711        Add a Mac-specific ImageControls root element that renders a 20x20 red box (for now):
71712        * html/shadow/mac/ImageControlsRootElementMac.cpp: Added.
71713        (WebCore::ImageControlsRootElementMac::ImageControlsRootElementMac):
71714        (WebCore::ImageControlsRootElementMac::~ImageControlsRootElementMac):
71715        (WebCore::ImageControlsRootElement::maybeCreate):
71716        (WebCore::ImageControlsRootElementMac::maybeCreate):
71717        * html/shadow/mac/ImageControlsRootElementMac.h: Added.
71718
71719        Since much of the RenderMedia::layout() method is now required for RenderImage as well,
71720        move the logic to RenderImage. The extra work is controlled by a bool flag that will always
71721        be set for RenderMedias but will only be set for certain RenderImages:
71722        * rendering/RenderImage.cpp:
71723        (WebCore::RenderImage::RenderImage):
71724        (WebCore::RenderImage::canHaveChildren):
71725        (WebCore::RenderImage::layout):
71726        (WebCore::RenderImage::layoutShadowControls):
71727        * rendering/RenderImage.h:
71728        (WebCore::RenderImage::setHasShadowControls):
71729        (WebCore::RenderImage::shadowControlsNeedCustomLayoutMetrics):
71730
71731        * rendering/RenderMedia.cpp:
71732        (WebCore::RenderMedia::RenderMedia):
71733        * rendering/RenderMedia.h:
71734        (WebCore::RenderMedia::shadowControlsNeedCustomLayoutMetrics):
71735
71736        * WebCore.xcodeproj/project.pbxproj:
71737
71738== Rolled over to ChangeLog-2014-02-20 ==
71739