URLs in srcset attributes are not made absolute upon copy and paste
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2014-07-30  Myles C. Maxfield  <mmaxfield@apple.com>
2
3         URLs in srcset attributes are not made absolute upon copy and paste
4         https://bugs.webkit.org/show_bug.cgi?id=135448
5
6         Reviewed by Ryosuke Niwa.
7
8         When pasting, canonicalize URLs in srcset the same way we do with src.
9
10         Test: editing/pasteboard/img-srcset-copy-paste-canonicalization.html
11
12         * dom/Element.cpp:
13         (WebCore::Element::completeURLsInAttributeValue): Initial implemention, moved from markup.cpp.
14         * dom/Element.h:
15         (WebCore::Element::attributeContainsURL): New function for completeURLs to call.
16         (WebCore::Element::completeURLsInAttributeValue): Only called if attributeContainsURL returns
17         true. Default implementation simply calls isURLAttribute().
18         * editing/markup.cpp:
19         (WebCore::completeURLs): Call attributeContainsURL() and completeURLsInAttributeValue() to
20         complete the URL, so nodes can perform their own behavior.
21         * html/HTMLImageElement.cpp:
22         (WebCore::HTMLImageElement::attributeContainsURL): Return true for srcset.
23         (WebCore::HTMLImageElement::completeUrlAttributeValue): Use our existing srcset parser to
24         parse the srcset attribute, then use its output to canonicalize URLs, and build it back up
25         into a string.
26         * html/HTMLImageElement.h:
27         (WebCore::HTMLImageElement::attributeContainsURL):
28         (WebCore::HTMLImageElement::completeUrlAttributeValue):
29         * html/parser/HTMLSrcsetParser.cpp: Make parseImageCandidatesFromSrcsetAttribute() public
30         and change its signature to return its result.
31         (WebCore::parseImageCandidatesFromSrcsetAttribute):
32         * html/parser/HTMLSrcsetParser.h: Ditto.
33
34 2014-07-31  Andreas Kling  <akling@apple.com>
35
36         Remove the JSC::OverridesVisitChildren flag.
37         <https://webkit.org/b/135489>
38
39         Tweak the bindings code generator to stop spitting out the flag.
40
41         Reviewed by Geoffrey Garen.
42
43         * bindings/js/JSDOMBinding.h:
44         * bindings/js/JSDOMGlobalObject.cpp:
45         (WebCore::JSDOMGlobalObject::visitChildren):
46         * bindings/scripts/CodeGeneratorJS.pm:
47         (GenerateHeader):
48         (GenerateImplementation):
49
50 2014-08-01  Jer Noble  <jer.noble@apple.com>
51
52         [MSE][Mac] Volume is not remembered between items in a YouTube playlist
53         https://bugs.webkit.org/show_bug.cgi?id=135479
54
55         Reviewed by Eric Carlson.
56
57         When an AVSampleBufferAudioRenderer is added to the player, set its -volume and -muted
58         properties with the current values from the HTMLMediaElement. 
59
60         * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
61         (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::addAudioRenderer):
62
63 2014-08-01  Tim Horton  <timothy_horton@apple.com>
64
65         Fix the iOS build after r171891
66
67         * platform/ios/ScrollViewIOS.mm:
68         (WebCore::ScrollView::platformTopContentInset):
69         (WebCore::ScrollView::platformSetTopContentInset):
70
71 2014-08-01  Pratik Solanki  <psolanki@apple.com>
72
73         Remove EventNames.h include from header files
74         https://bugs.webkit.org/show_bug.cgi?id=135486
75
76         Reviewed by Alexey Proskuryakov.
77
78         No new tests because no functional changes.
79
80         * Modules/airplay/WebKitPlaybackTargetAvailabilityEvent.h:
81         * Modules/gamepad/GamepadEvent.h:
82         * Modules/indexeddb/IDBRequest.h:
83         * Modules/indexeddb/IDBTransaction.h:
84         * Modules/mediastream/RTCStatsResponse.h:
85         * Modules/websockets/WebSocket.h:
86         * css/FontLoader.h:
87         * dom/SecurityPolicyViolationEvent.h:
88         * loader/appcache/DOMApplicationCache.h:
89         * workers/AbstractWorker.h:
90         * workers/Worker.h:
91         * workers/WorkerGlobalScope.h:
92         * xml/XMLHttpRequest.h:
93         * xml/XMLHttpRequestProgressEvent.h:
94
95 2014-08-01  Simon Fraser  <simon.fraser@apple.com>
96
97         nullptr goodness in RenderLayer
98         https://bugs.webkit.org/show_bug.cgi?id=135512
99
100         Reviewed by Brent Fulgham.
101
102         Use nullptr in RenderLayer.
103
104         * rendering/RenderLayer.cpp:
105         (WebCore::RenderLayer::RenderLayer):
106         (WebCore::RenderLayer::updateDescendantDependentFlags):
107         (WebCore::accumulateOffsetTowardsAncestor):
108         (WebCore::RenderLayer::scrollRectToVisible):
109         (WebCore::RenderLayer::destroyScrollbar):
110         (WebCore::RenderLayer::paintLayerContents):
111         (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
112         (WebCore::RenderLayer::hitTestLayer):
113         (WebCore::RenderLayer::hitTestList):
114         (WebCore::RenderLayer::calculateClipRects):
115
116 2014-08-01  Tim Horton  <timothy_horton@apple.com>
117
118         Build fix for iOS
119
120         * bindings/objc/DOM.mm:
121         (-[DOMRange renderedImageForcingBlackText:renderedImageForcingBlackText:]):
122         We use CGImageRef instead of NSImage here on iOS.
123
124 2014-08-01  Renato Nagy  <nagy.renato@stud.u-szeged.hu>
125
126         ASSERTION FAILED: listNode in WebCore::RenderListItem::updateListMarkerNumbers
127         https://bugs.webkit.org/show_bug.cgi?id=134970
128
129         Reviewed by Zalan Bujtas.
130
131         Removed an unnecessary assert, because the null return value of enclosingList() is
132         handled properly after this assert.
133
134         * rendering/RenderListItem.cpp:
135         (WebCore::RenderListItem::updateListMarkerNumbers):
136
137 2014-08-01  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
138
139         Replace DEPRECATED_DEFINE_STATIC_LOCAL with NeverDestroyed<T> in NavigatorContentUtils
140         https://bugs.webkit.org/show_bug.cgi?id=135494
141
142         Reviewed by Andrei Bucur.
143
144         Use static NeverDestroyed<T> variables instead of the DEPRECATED_DEFINE_STATIC_LOCAL macro.
145
146         No new tests, no behavior changes.
147
148         * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
149         (WebCore::customHandlersStateString):
150         (WebCore::NavigatorContentUtils::isProtocolHandlerRegistered):
151
152 2014-07-31  Benjamin Poulain  <bpoulain@apple.com>
153
154         Remove shadowPseudoId() override from the shadow media controls
155         https://bugs.webkit.org/show_bug.cgi?id=135474
156
157         Reviewed by Eric Carlson.
158
159         Small cleanup.
160
161         * html/shadow/MediaControlElementTypes.h:
162         * html/shadow/MediaControlElements.cpp:
163         (WebCore::MediaControlPanelElement::MediaControlPanelElement):
164         (WebCore::MediaControlPanelEnclosureElement::MediaControlPanelEnclosureElement):
165         (WebCore::MediaControlOverlayEnclosureElement::MediaControlOverlayEnclosureElement):
166         (WebCore::MediaControlTimelineContainerElement::MediaControlTimelineContainerElement):
167         (WebCore::MediaControlVolumeSliderContainerElement::MediaControlVolumeSliderContainerElement):
168         (WebCore::MediaControlStatusDisplayElement::MediaControlStatusDisplayElement):
169         (WebCore::MediaControlPanelMuteButtonElement::MediaControlPanelMuteButtonElement):
170         (WebCore::MediaControlVolumeSliderMuteButtonElement::MediaControlVolumeSliderMuteButtonElement):
171         (WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement):
172         (WebCore::MediaControlOverlayPlayButtonElement::MediaControlOverlayPlayButtonElement):
173         (WebCore::MediaControlSeekForwardButtonElement::MediaControlSeekForwardButtonElement):
174         (WebCore::MediaControlSeekBackButtonElement::MediaControlSeekBackButtonElement):
175         (WebCore::MediaControlRewindButtonElement::MediaControlRewindButtonElement):
176         (WebCore::MediaControlReturnToRealtimeButtonElement::MediaControlReturnToRealtimeButtonElement):
177         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
178         (WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement):
179         (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement):
180         (WebCore::MediaControlTimelineElement::MediaControlTimelineElement):
181         (WebCore::MediaControlPanelVolumeSliderElement::MediaControlPanelVolumeSliderElement):
182         (WebCore::MediaControlFullscreenVolumeSliderElement::MediaControlFullscreenVolumeSliderElement):
183         (WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement):
184         (WebCore::MediaControlFullscreenVolumeMinButtonElement::MediaControlFullscreenVolumeMinButtonElement):
185         (WebCore::MediaControlFullscreenVolumeMaxButtonElement::MediaControlFullscreenVolumeMaxButtonElement):
186         (WebCore::MediaControlTimeRemainingDisplayElement::MediaControlTimeRemainingDisplayElement):
187         (WebCore::MediaControlCurrentTimeDisplayElement::MediaControlCurrentTimeDisplayElement):
188         (WebCore::MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement):
189         (WebCore::MediaControlPanelElement::shadowPseudoId): Deleted.
190         (WebCore::MediaControlPanelEnclosureElement::shadowPseudoId): Deleted.
191         (WebCore::MediaControlOverlayEnclosureElement::shadowPseudoId): Deleted.
192         (WebCore::MediaControlTimelineContainerElement::shadowPseudoId): Deleted.
193         (WebCore::MediaControlVolumeSliderContainerElement::shadowPseudoId): Deleted.
194         (WebCore::MediaControlStatusDisplayElement::shadowPseudoId): Deleted.
195         (WebCore::MediaControlPanelMuteButtonElement::shadowPseudoId): Deleted.
196         (WebCore::MediaControlVolumeSliderMuteButtonElement::shadowPseudoId): Deleted.
197         (WebCore::MediaControlPlayButtonElement::shadowPseudoId): Deleted.
198         (WebCore::MediaControlOverlayPlayButtonElement::shadowPseudoId): Deleted.
199         (WebCore::MediaControlSeekForwardButtonElement::shadowPseudoId): Deleted.
200         (WebCore::MediaControlSeekBackButtonElement::shadowPseudoId): Deleted.
201         (WebCore::MediaControlRewindButtonElement::shadowPseudoId): Deleted.
202         (WebCore::MediaControlReturnToRealtimeButtonElement::shadowPseudoId): Deleted.
203         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId): Deleted.
204         (WebCore::MediaControlClosedCaptionsContainerElement::shadowPseudoId): Deleted.
205         (WebCore::MediaControlClosedCaptionsTrackListElement::shadowPseudoId): Deleted.
206         (WebCore::MediaControlTimelineElement::shadowPseudoId): Deleted.
207         (WebCore::MediaControlPanelVolumeSliderElement::shadowPseudoId): Deleted.
208         (WebCore::MediaControlFullscreenVolumeSliderElement::shadowPseudoId): Deleted.
209         (WebCore::MediaControlFullscreenButtonElement::shadowPseudoId): Deleted.
210         (WebCore::MediaControlFullscreenVolumeMinButtonElement::shadowPseudoId): Deleted.
211         (WebCore::MediaControlFullscreenVolumeMaxButtonElement::shadowPseudoId): Deleted.
212         (WebCore::MediaControlTimeRemainingDisplayElement::shadowPseudoId): Deleted.
213         (WebCore::MediaControlCurrentTimeDisplayElement::shadowPseudoId): Deleted.
214         (WebCore::MediaControlTextTrackContainerElement::textTrackContainerElementShadowPseudoId): Deleted.
215         (WebCore::MediaControlTextTrackContainerElement::shadowPseudoId): Deleted.
216         * html/shadow/MediaControlElements.h:
217         * html/shadow/MediaControls.cpp:
218         (WebCore::MediaControls::MediaControls):
219         (WebCore::MediaControls::shadowPseudoId): Deleted.
220         * html/shadow/MediaControls.h:
221
222 2014-07-31  Timothy Horton  <timothy_horton@apple.com>
223
224         Build fix for platforms where we should have automaticallyAdjustsContentInsets but it isn't public yet
225
226         * platform/mac/ScrollViewMac.mm:
227
228 2014-07-31  Carlos Alberto Lopez Perez  <clopez@igalia.com>
229
230         [EFL] Add support for building with Geoclue2.
231         https://bugs.webkit.org/show_bug.cgi?id=135455
232
233         Reviewed by Gyuyoung Kim.
234
235         No new tests required, no new functionality.
236
237         * PlatformEfl.cmake: Generate derived sources for Geoclue2Interface
238         and include gio-unix path.
239
240 2014-07-31  Zalan Bujtas  <zalan@apple.com>
241
242         Subpixel rendering: Region painting needs to take subpixel accumulation into account.
243         https://bugs.webkit.org/show_bug.cgi?id=135469
244
245         Similar to non-region painting, when the context is translated, we need to propagate
246         the subpixel difference so that renderers get snapped to the same position as if they
247         were not part of a region.
248
249         Reviewed by Simon Fraser.
250
251         Covered by existing tests/not testable (webkit.org/b/135470)
252
253         * html/shadow/MediaControlElements.cpp:
254         (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
255         * page/FrameView.cpp:
256         (WebCore::FrameView::paintContents):
257         * rendering/RenderLayer.cpp:
258         (WebCore::RenderLayer::paint):
259         (WebCore::RenderLayer::calculateClipRects):
260         * rendering/RenderLayer.h:
261
262 2014-07-31  Jer Noble  <jer.noble@apple.com>
263
264         [iOS] Video in an <embed> has a bad aspect ratio when in fullscreen mode.
265         https://bugs.webkit.org/show_bug.cgi?id=135481
266
267         Reviewed by Simon Fraser.
268
269         Do not change the gravity of our AVPlayerLayer when in full screen mode; its gravity
270         is controlled by setVideoFullscreenGravity(), and should not be affected by style changes.
271
272         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
273         (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoLayerGravity):
274
275 2014-07-31  Beth Dakin  <bdakin@apple.com>
276
277         Hit-testing broken in WebKit 1 views with AppKit's contentInsets
278         https://bugs.webkit.org/show_bug.cgi?id=135434
279         -and corresponding-
280         <rdar://problem/17850323>
281
282         Reviewed by Benjamin Poulain.
283
284         AppKit's contentInsets are factored into scroll positions and mouse positions, but
285         in WebCore, we generally want all of those things to be factored out so that, for
286         example, the scroll position of a document pinned to the top is the same whether
287         or not there is a contentInset. So to fix hit-testing in WebKit 1 views with
288         contentInsets, this patch factors the inset out or into of all coordinate
289         conversion methods just like we do for the WebKit2 contentInset.
290         
291         This patch also adds the ability to test WK1 platformContentInsets with
292         window.internals, and it re-names convertFromRenderer to 
293         convertFromRendererToContainingView and also re-names convertToRenderer to
294         convertFromContainingViewToRenderer.
295
296         ScrollView::topContentInset() takes an optional parameter indicating whether the
297         caller wants the WebCore::Page contentInset or the platform content inset. It’s
298         necessary to distinguish between these cases because there is a lot of code that
299         only wants the WebCore::Page contentInset since that feature is actually
300         implemented in WebCore as opposed to being implemented at the platform level.
301         * WebCore.exp.in:
302         * page/FrameView.cpp:
303         (WebCore::FrameView::topContentInset):
304
305         For layout test purposes, set the platforTopContentInset here if there is a 
306         platformWidget().
307         (WebCore::FrameView::topContentInsetDidChange):
308
309         Re-named functions, also all coordinate conversion functions call 
310         topContentInset(ManualOrPlatformContentInset)
311         (WebCore::FrameView::convertFromContainingViewToRenderer):
312         (WebCore::FrameView::convertToContainingView):
313         (WebCore::FrameView::convertFromContainingView):
314         (WebCore::FrameView::convertFromRenderer): Deleted.
315         (WebCore::FrameView::convertToRenderer): Deleted.
316         * page/FrameView.h:
317         * page/Page.cpp:
318         (WebCore::Page::setTopContentInset):
319         * platform/ScrollView.cpp:
320         (WebCore::ScrollView::documentScrollOffsetRelativeToViewOrigin):
321         (WebCore::ScrollView::documentScrollPositionRelativeToViewOrigin):
322         (WebCore::ScrollView::contentsToRootView):
323         (WebCore::ScrollView::rootViewToTotalContents):
324         (WebCore::ScrollView::contentsToWindow):
325         (WebCore::ScrollView::platformTopContentInset):
326         (WebCore::ScrollView::platformSetTopContentInset):
327         * platform/ScrollView.h:
328         (WebCore::ScrollView::topContentInset):
329         * platform/ios/ScrollViewIOS.mm:
330         (WebCore::ScrollView::platformTopContentInset):
331         (WebCore::ScrollView::platformSetTopContentInset):
332
333         Implement new platform inset-related functions using AppKit's implementation.
334         * platform/mac/ScrollViewMac.mm:
335         (WebCore::ScrollView::platformTopContentInset):
336         (WebCore::ScrollView::platformSetTopContentInset):
337         
338         When we set the scroll position for the documentView, we have to factor the inset
339         back into the WebCore scroll position.
340         (WebCore::ScrollView::platformSetScrollPosition):
341         
342         Re-named functions.
343         * rendering/RenderLayer.cpp:
344         (WebCore::RenderLayer::convertFromScrollbarToContainingView):
345         (WebCore::RenderLayer::convertFromContainingViewToScrollbar):
346         * rendering/RenderListBox.cpp:
347         (WebCore::RenderListBox::convertFromScrollbarToContainingView):
348         (WebCore::RenderListBox::convertFromContainingViewToScrollbar):
349
350 2014-07-31  Dean Jackson  <dino@apple.com>
351
352         Default buttons do not pulse in OS X 10.10
353         https://bugs.webkit.org/show_bug.cgi?id=135447
354         <rdar://problem/17875896>
355
356         Reviewed by Dan Bernstein.
357
358         OS X Yosemite does not have the animated pulsing default
359         buttons seen in previous releases. We don't need to have
360         a timer in RenderButton constantly triggering repaints.
361
362         * platform/mac/ThemeMac.mm:
363         (WebCore::paintButton): No need to advance the animation.
364         * rendering/RenderButton.cpp:
365         (WebCore::RenderButton::styleDidChange): Ask the theme if it
366         should advance the animation.
367         * rendering/RenderTheme.h:
368         (WebCore::RenderTheme::defaultButtonHasAnimation): Virtual function
369         indicating if the button needs to repaint.
370         * rendering/RenderThemeMac.h:
371         * rendering/RenderThemeMac.mm:
372         (WebCore::RenderThemeMac::defaultButtonHasAnimation): Provide platform
373         specific result on Yosemite and above.
374
375 2014-07-31  Tim Horton  <timothy_horton@apple.com>
376
377         DOM::renderedImageForcingBlackText returns an image with the wrong logical size on 2x displays
378         https://bugs.webkit.org/show_bug.cgi?id=135442
379         <rdar://problem/17614632>
380
381         Reviewed by Simon Fraser.
382
383         * bindings/objc/DOM.mm:
384         (-[DOMRange renderedImageForcingBlackText:renderedImageForcingBlackText:]):
385         Scale the NSImage size by the device scale factor,
386         similar to what we did for drag images in r167403.
387         Ideally this scaling would happen in the code that
388         generates the images, but this is a much larger change
389         with much more regression potential.
390
391 2014-07-31  Bear Travis  <betravis@adobe.com>
392
393         [CSS Font Loading] Rename document.fontloader to document.fonts
394         https://bugs.webkit.org/show_bug.cgi?id=135393
395
396         Reviewed by Bem Jones-Bey.
397
398         The most recent version of the specification has renamed
399         document.fontloader to document.fonts. This change updates the
400         names in WebCore and LayoutTests.
401
402         Fixed up existing tests under LayoutTests/fast/css/fontloader-*
403         and LayoutTests/http/webfont/fontloader-*
404
405         * css/CSSFontFace.cpp:
406         (WebCore::CSSFontFace::notifyFontLoader):
407         (WebCore::CSSFontFace::notifyLoadingDone):
408         * dom/Document.cpp:
409         (WebCore::Document::fonts):
410         (WebCore::Document::fontloader): Deleted.
411         * dom/Document.h:
412         * dom/Document.idl:
413         * page/FrameView.cpp:
414         (WebCore::FrameView::performPostLayoutTasks):
415
416 2014-07-31  Andrei Bucur  <abucur@adobe.com>
417
418         REGRESSION: Search highlight is broken in RTL multicolumn content
419         https://bugs.webkit.org/show_bug.cgi?id=135452
420
421         Reviewed by Simon Fraser.
422
423         The offsets for elements inside RTL multi-column elements are incorrectly computed because
424         the columns don't calculate their left position according to the writing direction.
425
426         The patch extracts the column position computation in two helper functions (for top and left)
427         so they can be used when needed in different parts of the code. In our case, the |columnLogicalLeft|
428         function should be used inside |columnTranslationForOffset|.
429
430         Test: fast/multicol/content-bounding-box-rtl.html
431
432         * rendering/RenderMultiColumnSet.cpp:
433         (WebCore::RenderMultiColumnSet::columnLogicalLeft): Return the logical left of a column relative to the set.
434         (WebCore::RenderMultiColumnSet::columnLogicalTop): Return the logical top of a column relative to the set.
435         (WebCore::RenderMultiColumnSet::columnRectAt): Split the code between columnLogicalLeft and columnLogicalTop.
436         (WebCore::RenderMultiColumnSet::collectLayerFragments): Make code clearer by adding a new line.
437         (WebCore::RenderMultiColumnSet::columnTranslationForOffset): Use columnLogicalLeft instead of duplicating logic.
438         * rendering/RenderMultiColumnSet.h:
439
440 2014-07-31  Martin Hodovan  <mhodovan.u-szeged@partner.samsung.com>
441
442         Eliminate "FractionConversion" from CSSPrimitiveValue::convertToLength
443         https://bugs.webkit.org/show_bug.cgi?id=135377
444
445         Reviewed by Darin Adler.
446
447         The FractionConversion argument in CSSPrimitiveValue::convertToLength
448         doesn't seem to actually have a purpose. It is for converting numbers
449         into Length(x * 100, Percent), but this case shouldn't be reachable.
450         The original patch introducing it doesn't shed any light either:
451         [https://bugs.webkit.org/show_bug.cgi?id=74913
452
453         This patch removes the now unused FractionConversion argument. Note
454         that we can probably also merge the two Fixed conversions, as the
455         two only differ in clamping large numbers (probably unintended).
456
457         Patch by Timothy Loh, backported from Blink: https://codereview.chromium.org/71253002
458
459         No new tests.
460
461         * css/CSSCalculationValue.cpp:
462         (WebCore::determineCategory):
463         * css/CSSParser.cpp:
464         (WebCore::parseTransformTranslateArguments):
465         (WebCore::parseTranslateTransformValue):
466         (WebCore::parseTransformArguments): Deleted.
467         * css/CSSPrimitiveValueMappings.h:
468         (WebCore::CSSPrimitiveValue::convertToLength):
469         * css/DeprecatedStyleBuilder.cpp:
470         (WebCore::ApplyPropertyClip::convertToLength):
471         * css/StyleResolver.cpp:
472         (WebCore::StyleResolver::convertToIntLength):
473         (WebCore::StyleResolver::convertToFloatLength):
474         * css/TransformFunctions.cpp:
475         (WebCore::convertToFloatLength):
476
477 2014-07-31  Joseph Pecoraro  <pecoraro@apple.com>
478
479         Web Inspector: console.profile missing profile information
480         https://bugs.webkit.org/show_bug.cgi?id=135432
481
482         Reviewed by Timothy Hatcher.
483
484         By switching console.profile to start/stop the timeline we would
485         not have a chance to recompile JS functions with profiling information.
486         This used to work because whenever the inspector was open we would
487         have profiling information enabled. Go back to that behavior.
488
489         * inspector/InspectorController.cpp:
490         (WebCore::InspectorController::profilerEnabled):
491         Instead of checking if the timeline agent has started, check if the
492         timeline agent has been created. Going back to the normal behavior
493         of always having profiling information when the inspector is open.
494
495         * inspector/InspectorTimelineAgent.h:
496         * inspector/InspectorTimelineAgent.cpp:
497         (WebCore::InspectorTimelineAgent::didCreateFrontendAndBackend):
498         Recompile initializing the timeline agent to include profiling information.
499
500         (WebCore::InspectorTimelineAgent::willDestroyFrontendAndBackend):
501         Recompile destrying the timeline agent, only if needed.
502
503         (WebCore::InspectorTimelineAgent::willCallFunction):
504         (WebCore::InspectorTimelineAgent::didCallFunction):
505         (WebCore::InspectorTimelineAgent::willEvaluateScript):
506         (WebCore::InspectorTimelineAgent::didEvaluateScript):
507         Using a boolean to track nested calls would not give expected
508         behavior when un-nesting. Switch to a counter to ensure that
509         as we start profiling in the outermost level we then stop
510         profiling at that same level and not inside an inner nesting.
511
512 2014-07-31  Wenson Hsieh  <wenson_hsieh@apple.com>
513
514         Refactor EventHandler to call ScrollAnimator::handleWheelEvent for overflow scrolling
515         https://bugs.webkit.org/show_bug.cgi?id=135195
516
517         Reviewed by Beth Dakin.
518
519         ScrollableArea::handleWheelEvent is not currently being used to handle wheel events for overflow scrolling; it instead directly invokes ScrollableArea::scroll.
520         In order to expose wheel phases on Mac, the PlatformWheelEvent itself should propagate down to ScrollableArea, not just the scroll granularity, direction and
521         multiplier required by ScrollableArea::scroll. With this patch, PlatformWheelEvent will be "shipped" along with the WheelEvent.
522
523         No new tests, since behavior should not have changed.
524
525         * page/EventHandler.cpp:
526         (WebCore::didScrollInScrollableAreaForSingleAxis): Calls ScrollableArea::scroll directly using WheelEvent's data. Used to handle programmatic WheelEvents, e.g. from JavaScript.
527         (WebCore::handleWheelEventInAppropriateEnclosingBoxForSingleAxis): Finds the correct ScrollableArea and attempts to scroll it using the information contained in the WheelEvent via ScrollableArea::handleWheelEvent
528         (WebCore::EventHandler::defaultWheelEventHandler): Updated to use handleWheelEventInAppropriateEnclosingBoxForSingleAxis instead of scrollNode.
529         (WebCore::scrollNode): Deleted.
530         * rendering/RenderListBox.h: Made RenderListBox::scroll public so it can be invoked from EventHandler::handleWheelEventInAppropriateEnclosingBoxForSingleAxis.
531         * rendering/RenderNamedFlowThread.cpp: Refactored to let EventHandler update nextScrollBlock in the case of isRenderNamedFlowThread().
532         (WebCore::RenderNamedFlowThread::fragmentFromRenderBoxAsRenderBlock): 
533         * rendering/RenderNamedFlowThread.h:
534
535 2014-07-31  Dan Bernstein  <mitz@apple.com>
536
537         WebCore part of: Server trust authentication challenges aren’t sent to the navigation delegate
538         https://bugs.webkit.org/show_bug.cgi?id=135327
539
540         Reviewed by Alexey Proskuryakov.
541
542         * platform/network/cf/ResourceHandleCFNet.cpp:
543         (WebCore::ResourceHandle::receivedCredential): Don’t try to change the persistence of
544         credentials used for server trust, because the platform doesn’t support persistence values
545         other than Session for server trust.
546         * platform/network/mac/ResourceHandleMac.mm:
547         (WebCore::ResourceHandle::receivedCredential): Ditto.
548
549 2014-07-31  Dan Bernstein  <mitz@apple.com>
550
551         Tried to fix building with the OS X 10.9 SDK while targeting OS X 10.8.
552
553         * platform/network/cocoa/CredentialCocoa.mm:
554         (WebCore::toCredentialPersistence):
555
556 2014-07-31  Dan Bernstein  <mitz@apple.com>
557
558         Reverted r171854, because it broke building with the OS X 10.8 SDK.
559
560         * platform/network/cocoa/CredentialCocoa.mm:
561         (WebCore::toCredentialPersistence):
562
563 2014-07-31  Dan Bernstein  <mitz@apple.com>
564
565         Tried to fix building with the OS X 10.9 SDK while targeting OS X 10.8.
566
567         * platform/network/cocoa/CredentialCocoa.mm:
568         (WebCore::toCredentialPersistence):
569
570 2014-07-31  Jer Noble  <jer.noble@apple.com>
571
572         REGRESSION(??): [iOS] Disabling MediaPlaybackRequiresUserGesture does not remove user gesture requirement for entering full screen.
573         https://bugs.webkit.org/show_bug.cgi?id=135443
574
575         Reviewed by Dean Jackson.
576
577         Allow full screen mode to be entered without a user gesture if the gesture requirement for media playback
578         has been unset.
579
580         * html/HTMLMediaElement.cpp:
581         (WebCore::HTMLMediaElement::HTMLMediaElement):
582
583 2014-07-31  Andrei Bucur  <abucur@adobe.com>
584
585         [CSS Multicolumn] Clear the lines when switching to multi-column layout
586         https://bugs.webkit.org/show_bug.cgi?id=135127
587
588         Reviewed by Alexandru Chiculita.
589
590         When switching an element to multi-column layout it becomes a container of block
591         children. When this happens the existing line boxes must be deleted in addition
592         to clearing the hasInlineChildren flag.
593
594         Tests: fast/multicol/inline-container-to-multicol.html
595                fast/multicol/inline-container-to-multicol-float.html
596                fast/multicol/inline-container-to-multicol-positioned.html
597
598         * rendering/RenderBlockFlow.cpp:
599         (WebCore::RenderBlockFlow::createMultiColumnFlowThread):
600
601 2014-07-30  Andreas Kling  <akling@apple.com>
602
603         PropertyName's internal string is always atomic.
604         <https://webkit.org/b/135451>
605
606         Use PropertyName::publicName() directly instead of taking the slow route
607         through AtomicString::findStringWithHash().
608
609         These strings are always atomic, and findStringWithHash() would trudge
610         through a full hash lookup just to discover that indeed, they are!
611
612         Reviewed by Benjamin Poulain.
613
614         * bindings/js/JSDOMBinding.cpp:
615         (WebCore::findAtomicString): Deleted.
616         * bindings/js/JSDOMBinding.h:
617         * bindings/js/JSDOMWindowCustom.cpp:
618         (WebCore::namedItemGetter):
619         (WebCore::JSDOMWindow::getOwnPropertySlot):
620         (WebCore::JSDOMWindow::getOwnPropertySlotByIndex):
621         * bindings/js/JSHTMLDocumentCustom.cpp:
622         (WebCore::JSHTMLDocument::canGetItemsForName):
623         (WebCore::JSHTMLDocument::nameGetter):
624
625 2014-07-30  Benjamin Poulain  <benjamin@webkit.org>
626
627         ElementRuleCollector: group the shadow tree code
628         https://bugs.webkit.org/show_bug.cgi?id=135410
629
630         Reviewed by Andreas Kling.
631
632         * css/ElementRuleCollector.cpp:
633         (WebCore::ElementRuleCollector::collectMatchingRules):
634         Little cleanup: group the shadow tree rule collection in the same block.
635
636 2014-07-30  Benjamin Poulain  <benjamin@webkit.org>
637
638         Cleanup DetailsMarkerControl
639         https://bugs.webkit.org/show_bug.cgi?id=135429
640
641         Reviewed by Andreas Kling.
642
643         Remove the override of shadowPseudoId(). This is a simple type of shadowId,
644         it should use the generic pseudo() path.
645
646         Move DetailsMarkerControl::create() out-of-line. One could justify inlining the constructor,
647         inlining the ::create() function has little value.
648
649         * html/shadow/DetailsMarkerControl.cpp:
650         (WebCore::DetailsMarkerControl::create):
651         (WebCore::DetailsMarkerControl::DetailsMarkerControl):
652         (WebCore::DetailsMarkerControl::rendererIsNeeded):
653         (WebCore::DetailsMarkerControl::shadowPseudoId): Deleted.
654         (WebCore::DetailsMarkerControl::summaryElement): Deleted.
655         * html/shadow/DetailsMarkerControl.h:
656         (WebCore::DetailsMarkerControl::create): Deleted.
657
658 2014-07-30  Benjamin Poulain  <bpoulain@apple.com>
659
660         Remove UploadButtonElement::shadowPseudoId()
661         https://bugs.webkit.org/show_bug.cgi?id=135435
662
663         Reviewed by Andreas Kling.
664
665         Use the generic pseudo() path instead of a custom shadowPseudoId().
666
667         * html/FileInputType.cpp:
668         (WebCore::UploadButtonElement::create):
669         (WebCore::UploadButtonElement::createForMultiple):
670         (WebCore::UploadButtonElement::UploadButtonElement):
671         Set the type in the common constructor instead of the call sites.
672         (WebCore::UploadButtonElement::shadowPseudoId): Deleted.
673         * html/FileInputType.h:
674
675 2014-07-30  Benjamin Poulain  <bpoulain@apple.com>
676
677         Remove SpinButtonElement::shadowPseudoId
678         https://bugs.webkit.org/show_bug.cgi?id=135436
679
680         Reviewed by Andreas Kling.
681
682         Use the generic pseudo.
683
684         * html/shadow/SpinButtonElement.cpp:
685         (WebCore::SpinButtonElement::SpinButtonElement):
686         (WebCore::SpinButtonElement::shadowPseudoId): Deleted.
687         * html/shadow/SpinButtonElement.h:
688
689 2014-07-30  Benjamin Poulain  <bpoulain@apple.com>
690
691         Clean up YouTubeEmbedShadowElement
692         https://bugs.webkit.org/show_bug.cgi?id=135437
693
694         Reviewed by Andreas Kling.
695
696         * html/shadow/YouTubeEmbedShadowElement.cpp:
697         (WebCore::YouTubeEmbedShadowElement::YouTubeEmbedShadowElement):
698         (WebCore::YouTubeEmbedShadowElement::pluginElement): Deleted.
699         This is unused in WebCore.
700
701         (WebCore::YouTubeEmbedShadowElement::shadowPseudoId): Deleted.
702         Use the generic pseudo path instead of a custom shadowPseudoId.
703         * html/shadow/YouTubeEmbedShadowElement.h:
704
705 2014-07-30  Benjamin Poulain  <bpoulain@apple.com>
706
707         Remove shadowPseudoId() from InputFieldSpeechButtonElement and SearchFieldCancelButtonElement
708         https://bugs.webkit.org/show_bug.cgi?id=135438
709
710         Reviewed by Andreas Kling.
711
712         Use the generic path.
713
714         * html/shadow/TextControlInnerElements.cpp:
715         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
716         (WebCore::InputFieldSpeechButtonElement::InputFieldSpeechButtonElement):
717         (WebCore::SearchFieldCancelButtonElement::shadowPseudoId): Deleted.
718         (WebCore::InputFieldSpeechButtonElement::shadowPseudoId): Deleted.
719         * html/shadow/TextControlInnerElements.h:
720
721 2014-07-30  Andy Estes  <aestes@apple.com>
722
723         USE(CONTENT_FILTERING) should be ENABLE(CONTENT_FILTERING)
724         https://bugs.webkit.org/show_bug.cgi?id=135439
725
726         Reviewed by Tim Horton.
727
728         We now support two different platform content filters, and will soon support a mock content filter (as part of
729         webkit.org/b/128858). This makes content filtering a feature of WebKit, not just an adoption of a third-party
730         library. ENABLE() is the correct macro to use for such a feature.
731
732         * Configurations/FeatureDefines.xcconfig:
733         * WebCore.exp.in:
734         * loader/DocumentLoader.cpp:
735         (WebCore::DocumentLoader::finishedLoading):
736         (WebCore::DocumentLoader::responseReceived):
737         (WebCore::DocumentLoader::commitData):
738         (WebCore::DocumentLoader::dataReceived):
739         * loader/DocumentLoader.h:
740         * loader/FrameLoaderClient.h:
741         * platform/ContentFilter.h:
742         * platform/ios/ContentFilterIOS.mm:
743         * platform/mac/ContentFilterMac.mm:
744
745 2014-07-30  Andreas Kling  <akling@apple.com>
746
747         Static hash tables no longer need to be coupled with a VM.
748         <https://webkit.org/b/135421>
749
750         Update for JSC::ClassInfo changes.
751         
752         Remove the JSNoStaticTables mode for IDL code generation, which was used to
753         ensure that each VM had its own unique copy of certain static tables.
754         This was used for interfaces that could be used in workers, and now there's
755         no need to manually annotate these things anymore.
756
757         Also remove the DOMObjectHashTableMap class that was only used for this.
758
759         Reviewed by Geoffrey Garen.
760
761         * Modules/indexeddb/IDBAny.idl:
762         * Modules/indexeddb/IDBCursor.idl:
763         * Modules/indexeddb/IDBCursorWithValue.idl:
764         * Modules/indexeddb/IDBDatabase.idl:
765         * Modules/indexeddb/IDBFactory.idl:
766         * Modules/indexeddb/IDBIndex.idl:
767         * Modules/indexeddb/IDBKeyRange.idl:
768         * Modules/indexeddb/IDBObjectStore.idl:
769         * Modules/indexeddb/IDBOpenDBRequest.idl:
770         * Modules/indexeddb/IDBRequest.idl:
771         * Modules/indexeddb/IDBTransaction.idl:
772         * Modules/indexeddb/IDBVersionChangeEvent.idl:
773         * Modules/webdatabase/Database.idl:
774         * Modules/webdatabase/DatabaseSync.idl:
775         * Modules/webdatabase/SQLError.idl:
776         * Modules/webdatabase/SQLException.idl:
777         * Modules/webdatabase/SQLResultSet.idl:
778         * Modules/webdatabase/SQLResultSetRowList.idl:
779         * Modules/webdatabase/SQLTransaction.idl:
780         * Modules/webdatabase/SQLTransactionSync.idl:
781         * Modules/websockets/CloseEvent.idl:
782         * Modules/websockets/WebSocket.idl:
783         * WebCore.xcodeproj/project.pbxproj:
784         * bindings/js/DOMObjectHashTableMap.cpp: Removed.
785         * bindings/js/DOMObjectHashTableMap.h: Removed.
786         * bindings/js/JSDOMBinding.cpp:
787         (WebCore::getHashTableForGlobalData): Deleted.
788         * bindings/js/JSDOMBinding.h:
789         (WebCore::getStaticValueSlotEntryWithoutCaching):
790         * bindings/js/JSDOMGlobalObject.cpp:
791         * bindings/js/JSDOMWindowBase.cpp:
792         * bindings/js/JSDOMWindowCustom.cpp:
793         (WebCore::JSDOMWindow::getOwnPropertySlot):
794         (WebCore::JSDOMWindow::put):
795         * bindings/js/JSDOMWindowShell.cpp:
796         * bindings/js/JSImageConstructor.cpp:
797         * bindings/js/JSLocationCustom.cpp:
798         (WebCore::JSLocation::putDelegate):
799         * bindings/js/JSStorageCustom.cpp:
800         (WebCore::JSStorage::deleteProperty):
801         (WebCore::JSStorage::putDelegate):
802         * bindings/js/JSWorkerGlobalScopeBase.cpp:
803         * bindings/js/WebCoreJSClientData.h:
804         * bindings/scripts/CodeGeneratorJS.pm:
805         (GenerateGetOwnPropertySlotBody):
806         (GenerateImplementation):
807         (GenerateConstructorHelperMethods):
808         (hashTableAccessor): Deleted.
809         (prototypeHashTableAccessor): Deleted.
810         (constructorHashTableAccessor): Deleted.
811         * bindings/scripts/IDLAttributes.txt:
812         * bridge/c/CRuntimeObject.cpp:
813         * bridge/c/c_instance.cpp:
814         * bridge/objc/ObjCRuntimeObject.mm:
815         * bridge/objc/objc_instance.mm:
816         * bridge/objc/objc_runtime.mm:
817         * bridge/runtime_array.cpp:
818         * bridge/runtime_method.cpp:
819         * bridge/runtime_object.cpp:
820         * crypto/CryptoKey.idl:
821         * css/CSSFontFaceLoadEvent.idl:
822         * dom/DOMCoreException.idl:
823         * dom/DOMStringList.idl:
824         * dom/ErrorEvent.idl:
825         * dom/Event.idl:
826         * dom/EventException.idl:
827         * dom/EventListener.idl:
828         * dom/MessageChannel.idl:
829         * dom/MessageEvent.idl:
830         * dom/MessagePort.idl:
831         * dom/ProgressEvent.idl:
832         * fileapi/Blob.idl:
833         * fileapi/File.idl:
834         * fileapi/FileError.idl:
835         * fileapi/FileException.idl:
836         * fileapi/FileList.idl:
837         * fileapi/FileReader.idl:
838         * fileapi/FileReaderSync.idl:
839         * html/DOMURL.idl:
840         * page/EventSource.idl:
841         * page/WorkerNavigator.idl:
842         * workers/DedicatedWorkerGlobalScope.idl:
843         * workers/SharedWorkerGlobalScope.idl:
844         * workers/WorkerGlobalScope.idl:
845         * workers/WorkerLocation.idl:
846         * xml/XMLHttpRequest.idl:
847         * xml/XMLHttpRequestException.idl:
848         * xml/XMLHttpRequestProgressEvent.idl:
849         * xml/XMLHttpRequestUpload.idl:
850
851 2014-07-30  Dan Bernstein  <mitz@apple.com>
852
853         <rdar://problem/17199364> [Mac] Popup button arrows appear on the left, underlapping text, when the UI layout direction is right-to-left
854         https://bugs.webkit.org/show_bug.cgi?id=135426
855
856         Reviewed by Dean Jackson.
857
858         No test, because the UI layout direction in the test harness is always left-to-right.
859
860         * rendering/RenderThemeMac.mm:
861         (WebCore::RenderThemeMac::popupButton): Forced the user interface layout direction of the
862         NSPopUpButtonCell to left-to-right. Added a FIXME about how we could make this vary based on
863         the direction of the <select>, though that would require additional changes elsewhere.
864
865 2014-07-30  Dan Bernstein  <mitz@apple.com>
866
867         Made Credential hold onto an NSURLCredential when needed.
868         Work towards fixing https://bugs.webkit.org/show_bug.cgi?id=135327
869
870         Reviewed by Alexey Proskuryakov.
871
872         No change in functionality.
873
874         * WebCore.exp.in: Updated.
875
876         * platform/network/Credential.h: Removed definition of CERTIFICATE_CREDENTIALS_SUPPORTED,
877         which is not used anymore.
878
879         * platform/network/CredentialBase.h:
880         (WebCore::CredentialBase::encodingRequiresPlatformData): Added a base implementation that
881         returns false.
882
883         * platform/network/cf/AuthenticationCF.cpp:
884         Changed to use the Credential constructor that takes an CFURLCredential, and the new
885         cfCredential member function. Made the createCF and core functions Windows-only and
886         therefore removed the CERTIFICATE_CREDENTIALS_SUPPORTED code from them.
887         * platform/network/cf/AuthenticationCF.h:
888
889         * platform/network/cf/CredentialStorageCFNet.cpp:
890         (WebCore::CredentialStorage::getFromPersistentStorage): Changed to construct a Credential
891         from a CFURLCredential.
892         (WebCore::CredentialStorage::saveToPersistentStorage): Changed to use the new cfCredential
893         member function.
894
895         * platform/network/cf/ResourceHandleCFNet.cpp:
896         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Ditto to both.
897         (WebCore::ResourceHandle::receivedCredential): Ditto.
898
899         * platform/network/cocoa/CredentialCocoa.h:
900         Replaced the m_identity, m_certificates and m_type member variables with an m_nsCredential
901         one holding onto an NSURLCredential. Declared constructors from and getters for
902         NSURLCredential and CFURLCredentialRef.
903         (WebCore::Credential::encodingRequiresPlatformData): Override that checks the
904         NSURLCredential if necessary.
905
906         * platform/network/cocoa/CredentialCocoa.mm:
907         (WebCore::toNSURLCredentialPersistence): New helper function.
908         (WebCore::toCredentialPersistence): Ditto.
909         (WebCore::Credential::Credential): Defined constructors to create or take an
910         NSURLCredential.
911         (WebCore::Credential::cfCredential): Added.
912         (WebCore::Credential::nsCredential): Added. Returns nil for the empty credential.
913         (WebCore::Credential::isEmpty): Changed to check m_nsCredential.
914         (WebCore::Credential::platformCompare): Changed to compare m_nsCredential if needed.
915         (WebCore::Credential::encodingRequiresPlatformData): Returns true if the credential is not
916         a user and a password.
917
918         * platform/network/mac/AuthenticationMac.h: Removed mac and core functions for Credential.
919         * platform/network/mac/AuthenticationMac.mm:
920         (-[WebCoreAuthenticationClientAsChallengeSender useCredential:forAuthenticationChallenge:]):
921         Changed to use Credential constructor that takes an NSURLCredential.
922         (WebCore::AuthenticationChallenge::AuthenticationChallenge): Ditto. Also use the
923         nsCredential getter.
924
925         * platform/network/mac/CredentialStorageMac.mm:
926         (WebCore::CredentialStorage::getFromPersistentStorage): Use new Credential constructor.
927
928         * platform/network/mac/ResourceHandleMac.mm:
929         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Ditto. Also use the
930         nsCredential getter.
931         (WebCore::ResourceHandle::receivedCredential): Ditto.
932
933 2014-07-30  Sergio Villar Senin  <svillar@igalia.com>
934
935         [GTK] Build depends on OpenGL ES
936         https://bugs.webkit.org/show_bug.cgi?id=135289
937
938         Reviewed by Martin Robinson.
939
940         Guard the OpenGL ES code with USE(OPENGL_ES_2).
941
942         * platform/graphics/opengl/Extensions3DOpenGLES.cpp:
943         * platform/graphics/opengl/Extensions3DOpenGLES.h:
944
945 2014-07-30  Radu Stavila  <stavila@adobe.com>
946
947         Member name collision in RenderView and SelectionSubtreeRoot
948         https://bugs.webkit.org/show_bug.cgi?id=135233
949
950         Reviewed by Mihnea Ovidenie.
951
952         The selectionStart/End members in RenderView have been renamed to fix confusion caused by the fact that
953         RenderView inherits SelectionSubtreeRoot, which also has the same selectionStart/End members.
954
955         No new tests required, no new functionality.
956
957         * rendering/RenderBlock.cpp:
958         (WebCore::RenderBlock::isSelectionRoot):
959         * rendering/RenderView.cpp:
960         (WebCore::RenderView::RenderView):
961         (WebCore::RenderView::setSelection):
962         (WebCore::RenderView::getSelection):
963         * rendering/RenderView.h:
964
965 2014-07-30  Zan Dobersek  <zdobersek@igalia.com>
966
967         [TexMap] Move TextureMapperLayer::textureMapper() definition into the header
968         https://bugs.webkit.org/show_bug.cgi?id=135384
969
970         Reviewed by Martin Robinson.
971
972         Move the definitions of TextureMapperLayer::textureMapper() and TextureMapperLayer::rootLayer()
973         into the TextureMapperLayer header. This makes both functions inline-able, removing unnecessary
974         calling overhead in GraphicsLayerTextureMapper::flushCompositingState() and
975         GraphicsLayerTextureMapper::updateBackingStoreIfNeeded().
976
977         TextureMapperLayer::rootLayer() now also returns a reference.
978
979         * platform/graphics/texmap/TextureMapperLayer.cpp:
980         (WebCore::TextureMapperLayer::~TextureMapperLayer):
981         (WebCore::TextureMapperLayer::rootLayer): Deleted.
982         (WebCore::TextureMapperLayer::textureMapper): Deleted.
983         * platform/graphics/texmap/TextureMapperLayer.h:
984         (WebCore::TextureMapperLayer::textureMapper):
985         (WebCore::TextureMapperLayer::rootLayer):
986
987 2014-07-29  Andreas Kling  <akling@apple.com>
988
989         Crash when using 'em' units to specify font-size inside animation keyframe.
990         <https://webkit.org/b/135395>
991         <rdar://problem/17851910>
992
993         We'd forgotten to initialize the "parent style" when resolving keyframe
994         styles, and this led to a crash in length conversion where the code
995         assumes a parent style will be present.
996
997         To keep this fix minimal, simply make the "parent style" a clone of the
998         base element style.
999
1000         Reviewed by Simon Fraser.
1001
1002         Test: fast/animation/keyframe-with-font-size-in-em-units.html
1003
1004         * css/StyleResolver.cpp:
1005         (WebCore::StyleResolver::styleForKeyframe):
1006
1007 2014-07-29  Pratik Solanki  <psolanki@apple.com>
1008
1009         [iOS] REGRESSION(r171526): PDF documents fail to load in WebKit1 with disk image caching enabled
1010         https://bugs.webkit.org/show_bug.cgi?id=135359
1011         <rdar://problem/17824645>
1012
1013         Reviewed by Darin Adler.
1014
1015         r171526 broke the case where we have a memory mapped file from the DiskImageCache in the
1016         SharedBuffer. In such a case, m_buffer is empty and createCFData() returned an
1017         WebCoreSharedBufferData with an empty buffer.
1018
1019         Fix this by taking the easy route of bringing back the old code for the disk image cache
1020         file backed case. In the long run we probably want to remove the iOS specific disk image
1021         cache anyway.
1022
1023         Review also uncovered another bug in r171526 where we were balancing an Objective-C alloc
1024         with a CFRelease which is incorrect when running under GC. Fix that by using adoptNS along
1025         with adoptCF which is what the code did before.
1026
1027         No new tests because the bug only occurs on device and we can't run tests on device yet.
1028
1029         * platform/mac/SharedBufferMac.mm:
1030         (-[WebCoreSharedBufferData initWithDiskImageSharedBuffer:]):
1031         (-[WebCoreSharedBufferData length]):
1032         (-[WebCoreSharedBufferData bytes]):
1033         (WebCore::SharedBuffer::createCFData):
1034
1035 2014-07-29  Benjamin Poulain  <bpoulain@apple.com>
1036
1037         VisitedLinkState::determineLinkState should take a reference
1038         https://bugs.webkit.org/show_bug.cgi?id=135375
1039
1040         Reviewed by Sam Weinig.
1041
1042         * css/StyleResolver.cpp:
1043         (WebCore::StyleResolver::State::initElement):
1044         * dom/VisitedLinkState.h:
1045         (WebCore::VisitedLinkState::determineLinkState):
1046
1047 2014-07-29  Brady Eidson  <beidson@apple.com>
1048
1049         Make WKOriginDataManager actually operate on IndexedDatabases.
1050         https://bugs.webkit.org/show_bug.cgi?id=135346
1051
1052         Reviewed by Sam Weinig (and David Kilzer and Alex Christensen)
1053
1054         * WebCore.exp.in:
1055
1056 2014-07-29  Dan Bernstein  <mitz@apple.com>
1057
1058         Moved the Cocoa-specific parts of CredentialBase into a Cocoa-specific Credential class.
1059         Work towards fixing https://bugs.webkit.org/show_bug.cgi?id=135327
1060
1061         Reviewed by Alexey Proskuryakov.
1062
1063         No change in functionality.
1064
1065         * WebCore.exp.in: Updated for functions moved in the class hierarchy.
1066
1067         * WebCore.xcodeproj/project.pbxproj: Added CredentialCocoa.{h,mm}.
1068
1069         * platform/network/Credential.h: For Cocoa, include CredentialCocoa.h instead of the generic
1070         class.
1071         (WebCore::Credential::Credential): Removed #if CERTIFICATE_CREDENTIALS_SUPPORTED code.
1072
1073         * platform/network/CredentialBase.cpp:
1074         (WebCore::CredentialBase::CredentialBase): Changed to use emptyString instead of "", removed
1075         #if CERTIFICATE_CREDENTIALS_SUPPORTED code.
1076         (WebCore::CredentialBase::isEmpty): Ditto.
1077         (WebCore::CredentialBase::compare): Renamed operator== to this, removed
1078         #if CERTIFICATE_CREDENTIALS_SUPPORTED code, but changed the end to call platformCompare.
1079         (WebCore::CredentialBase::identity): Deleted.
1080         (WebCore::CredentialBase::certificates): Deleted.
1081         (WebCore::CredentialBase::type): Deleted.
1082         * platform/network/CredentialBase.h: Removed #if CERTIFICATE_CREDENTIALS_SUPPORTED members.
1083         (WebCore::CredentialBase::platformCompare): Added a base implementation that returns true.
1084         (WebCore::operator==): Changed to use CredentialBase::compare.
1085
1086         * platform/network/cocoa/CredentialCocoa.h: Added.
1087         (WebCore::Credential::Credential):
1088         * platform/network/cocoa/CredentialCocoa.mm: Added.
1089         (WebCore::Credential::Credential): Moved the constructor that takes an identity and
1090         certificates here.
1091         (WebCore::Credential::isEmpty): Moved here.
1092         (WebCore::Credential::identity): Ditto.
1093         (WebCore::Credential::certificates): Ditto.
1094         (WebCore::Credential::type): Ditto.
1095         (WebCore::Credential::platformCompare): Moved the code that compares client-certificate
1096         credentials here.
1097
1098         * platform/network/mac/AuthenticationMac.mm:
1099         (WebCore::mac): Removed #if CERTIFICATE_CREDENTIALS_SUPPORTED guards in this Cocoa-only
1100         file.
1101         (WebCore::core): Ditto.
1102
1103 2014-07-29  Daniel Bates  <dabates@apple.com>
1104
1105         Use WTF::move() instead of std::move() to help ensure move semantics
1106         https://bugs.webkit.org/show_bug.cgi?id=135351
1107
1108         Reviewed by Alexey Proskuryakov.
1109
1110         * page/CaptionUserPreferences.cpp:
1111         (WebCore::CaptionUserPreferences::updateCaptionStyleSheetOveride):
1112
1113 2014-07-29  Mihnea Ovidenie  <mihnea@adobe.com>
1114
1115         [CSSRegions] Assertion failure hit testing a region-based multicolumn in a region
1116         https://bugs.webkit.org/show_bug.cgi?id=135385
1117
1118         Reviewed by Andrei Bucur.
1119
1120         When a region-based multicolumn element is displayed and hit tested in a region,
1121         we have to disable the named flow region information not only for painting,
1122         but also for hit-testing. This is a follow-up for https://bugs.webkit.org/show_bug.cgi?id=132121,
1123         which provided the fix for painting.
1124
1125         Test: fast/regions/assert-hit-test-multicol-in-region.html
1126
1127         * rendering/RenderLayer.cpp:
1128         (WebCore::RenderLayer::hitTestLayer):
1129
1130 2014-07-29  Zalan Bujtas  <zalan@apple.com>
1131
1132         Cleanup RenderSelectionInfoBase/RenderSelectionInfo/RenderBlockSelectionInfo.
1133         https://bugs.webkit.org/show_bug.cgi?id=135326
1134
1135         Reviewed by Darin Adler.
1136
1137         1. Move implementation to RenderSelectInfo.cpp
1138         2. RenderSelectionInfoBase/RenderSelectionInfo/RenderBlockSelectionInfo take Render* reference.
1139         3. Remove unused functions.
1140         4. Add RenderSelectionInfoBase::repaintRectangle()
1141
1142         No change in behavior.
1143
1144         * WebCore.xcodeproj/project.pbxproj:
1145         * rendering/RenderSelectionInfo.cpp: Added.
1146         (WebCore::RenderSelectionInfoBase::RenderSelectionInfoBase):
1147         (WebCore::RenderSelectionInfoBase::repaintRectangle):
1148         (WebCore::RenderSelectionInfo::RenderSelectionInfo):
1149         (WebCore::RenderSelectionInfo::repaint):
1150         (WebCore::RenderBlockSelectionInfo::RenderBlockSelectionInfo):
1151         (WebCore::RenderBlockSelectionInfo::repaint):
1152         * rendering/RenderSelectionInfo.h:
1153         (WebCore::RenderSelectionInfo::collectedSelectionRects):
1154         (WebCore::RenderSelectionInfoBase::RenderSelectionInfoBase): Deleted.
1155         (WebCore::RenderSelectionInfoBase::object): Deleted.
1156         (WebCore::RenderSelectionInfo::RenderSelectionInfo): Deleted.
1157         (WebCore::RenderSelectionInfo::repaint): Deleted.
1158         (WebCore::RenderSelectionInfo::rects): Deleted.
1159         (WebCore::RenderBlockSelectionInfo::RenderBlockSelectionInfo): Deleted.
1160         (WebCore::RenderBlockSelectionInfo::repaint): Deleted.
1161         (WebCore::RenderBlockSelectionInfo::block): Deleted.
1162         * rendering/RenderView.cpp:
1163         (WebCore::RenderView::subtreeSelectionBounds):
1164         (WebCore::RenderView::repaintSubtreeSelection):
1165         (WebCore::RenderView::clearSubtreeSelection):
1166         (WebCore::RenderView::applySubtreeSelection):
1167
1168 2014-07-28  Pratik Solanki  <psolanki@apple.com>
1169
1170         Get SharedBuffer.h out of ResourceBuffer.h (and a few other places)
1171         https://bugs.webkit.org/show_bug.cgi?id=131782
1172
1173         Original patch by Tim Horton.
1174         Reviewed by Darin Adler.
1175
1176         No new tests because no functional changes.
1177
1178         * Modules/indexeddb/IDBCallbacks.h:
1179         * Modules/indexeddb/IDBCursorBackend.h:
1180         * loader/ios/DiskImageCacheIOS.h:
1181         Forward declare SharedBuffer in headers.
1182
1183         * Modules/indexeddb/IDBRequest.cpp:
1184         * loader/cache/CachedImage.cpp:
1185         * loader/icon/IconLoader.cpp:
1186         * loader/ios/DiskImageCacheIOS.mm:
1187         * loader/cache/MemoryCache.cpp:
1188         * loader/mac/ResourceBuffer.mm:
1189         Include SharedBuffer.h in implementation files.
1190
1191         * Modules/notifications/Notification.h:
1192         * loader/appcache/ApplicationCacheGroup.h:
1193         Remove unnecessary includes.
1194
1195         * loader/ResourceBuffer.cpp:
1196         (WebCore::ResourceBuffer::adoptSharedBuffer):
1197         * loader/ResourceBuffer.h:
1198         Out-of-line adoptSharedBuffer so that the PassRefPtr doesn't require including SharedBuffer.h.
1199
1200         * platform/graphics/opentype/OpenTypeMathData.cpp:
1201         * platform/graphics/opentype/OpenTypeMathData.h:
1202         Out-of-line destructor to avoid requiring SharedBuffer.h for the RefPtr.
1203         Forward-declare SharedBuffer in the header, include in implementation.
1204
1205 2014-07-29  Zan Dobersek  <zdobersek@igalia.com>
1206
1207         [TexMap] GraphicsLayerTextureMapper::addAnimation() box size parameter should be FloatSize
1208         https://bugs.webkit.org/show_bug.cgi?id=135237
1209
1210         Reviewed by Martin Robinson.
1211
1212         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
1213         (WebCore::GraphicsLayerTextureMapper::addAnimation):
1214         * platform/graphics/texmap/GraphicsLayerTextureMapper.h: The boxSize parameter of the
1215         addAnimation() method must be of the same type as the parameter in the base class
1216         declaration -- a const FloatSize reference. Only then is the base virtual method
1217         actually overriden.
1218
1219 2014-07-28  Dan Bernstein  <mitz@apple.com>
1220
1221         iOS build fix.
1222
1223         * WebCore.exp.in:
1224
1225 2014-07-28  Dan Bernstein  <mitz@apple.com>
1226
1227         Introduced CredentialBase and made Credential derive from it
1228         Work towards fixing https://bugs.webkit.org/show_bug.cgi?id=135327
1229
1230         Reviewed by Darin Adler.
1231
1232         No change in functionality.
1233
1234         * CMakeLists.txt: Updated for source file rename.
1235
1236         * WebCore.exp.in: Changed to export CredentialBase symbols.
1237
1238         * WebCore.vcxproj/WebCore.vcxproj: Updated for source file rename and new header.
1239         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
1240
1241         * WebCore.xcodeproj/project.pbxproj: Ditto.
1242
1243         * platform/network/Credential.cpp: Renamed to CredentialBase.cpp.
1244
1245         * platform/network/Credential.h: Defined Credential to derive from CredentialBase.
1246
1247         * platform/network/CredentialBase.cpp: Renamed Credential.cpp to this. Updated for the new
1248         name.
1249
1250         * platform/network/CredentialBase.h: Copied from Credential.h, renamed the class to
1251         CredentialBase, and made the constructors protected.
1252
1253 2014-07-28  Zalan Bujtas  <zalan@apple.com>
1254
1255         REGRESSION(r164133): Selection disappears after scrolling on nytimes.com
1256         https://bugs.webkit.org/show_bug.cgi?id=135361
1257
1258         Reviewed by Ryosuke Niwa.
1259
1260         Ensure that when a RenderElement, part of the current selection is removed,
1261         we recalculate and update the selection soon after layout.
1262
1263         Test: fast/dynamic/selection-gets-cleared-when-part-of-it-gets-removed.html
1264
1265         * editing/FrameSelection.cpp:
1266         (WebCore::FrameSelection::setNeedsSelectionUpdate):
1267         (WebCore::FrameSelection::didLayout): didLayout name reflects its functionality better.
1268         (WebCore::FrameSelection::layoutDidChange): Deleted.
1269         * editing/FrameSelection.h: : move some functions to private.
1270         * page/FrameView.cpp:
1271         (WebCore::FrameView::performPostLayoutTasks):
1272         * rendering/RenderBlockFlow.cpp:
1273         (WebCore::RenderBlockFlow::willBeDestroyed):
1274         * rendering/RenderElement.cpp:
1275         (WebCore::RenderElement::removeChildInternal):
1276         * rendering/RenderInline.cpp:
1277         (WebCore::RenderInline::willBeDestroyed):
1278
1279 2014-07-28  Dean Jackson  <dino@apple.com>
1280
1281         [Media iOS] Touching play button feels unresponsive
1282         https://bugs.webkit.org/show_bug.cgi?id=135370
1283         <rdar://problem/17756281>
1284
1285         Reviewed by Simon Fraser.
1286
1287         Add an :active rule that shows a slightly darker button when touched.
1288
1289         * Modules/mediacontrols/mediaControlsiOS.css:
1290         (audio::-webkit-media-controls-start-playback-button:active):
1291
1292 2014-07-28  Brady Eidson  <beidson@apple.com>
1293
1294         REGRESSION(168376): Standalone images pasted to Outlook 2011 don't display
1295         <rdar://problem/17768371> and https://bugs.webkit.org/show_bug.cgi?id=135363
1296
1297         Reviewed by Tim Horton.
1298
1299         Outlook isn’t prepared to handle the resource load callbacks when sent synchronously.
1300
1301         r168376 was an optimization that we no longer need, so the simplest fix is to roll it out.
1302
1303         * editing/mac/EditorMac.mm:
1304         (WebCore::Editor::WebContentReader::readImage):
1305
1306         * loader/archive/ArchiveResource.cpp:
1307         (WebCore::ArchiveResource::ArchiveResource):
1308         * loader/archive/ArchiveResource.h:
1309         (WebCore::ArchiveResource::setShouldLoadImmediately): Deleted.
1310         (WebCore::ArchiveResource::shouldLoadImmediately): Deleted.
1311
1312         * loader/cache/CachedResourceLoader.cpp:
1313         (WebCore::CachedResourceLoader::requestResource):
1314
1315 2014-07-28  Mark Hahnenberg  <mhahnenberg@apple.com>
1316
1317         ASSERTION FAILED: m_heap->vm()->currentThreadIsHoldingAPILock()
1318         https://bugs.webkit.org/show_bug.cgi?id=135352
1319
1320         Reviewed by Oliver Hunt.
1321
1322         * Modules/plugins/QuickTimePluginReplacement.mm:
1323         (WebCore::QuickTimePluginReplacement::ensureReplacementScriptInjected): This should be taking a 
1324         JSLock like its sibling methods do (e.g. installReplacement).
1325
1326 2014-07-28  Antti Koivisto  <antti@apple.com>
1327
1328         <embed> videos flashes constantly while playing inline on iPad, making it unwatchable
1329         https://bugs.webkit.org/show_bug.cgi?id=135356
1330         <rdar://problem/16828238>
1331
1332         Reviewed by Simon Fraser.
1333         
1334         The shadow tree for media controls is scheduling style recalc. The general silliness of
1335         HTMLPlugInImageElement::willRecalcStyle/willDetachRenderers is turning those into render
1336         tree reconstructions causing flicker.
1337
1338         * html/HTMLPlugInImageElement.cpp:
1339         (WebCore::HTMLPlugInImageElement::willRecalcStyle):
1340         
1341             Don't do the forced renderer reconstruction if there is no style change for the element
1342             or its ancestors. This way recalcs scheduled by the shadow tree don't trigger the widget
1343             update code path.
1344
1345 2014-07-27  Brent Fulgham  <bfulgham@apple.com>
1346
1347         [Mac, iOS] Paint-on closed captions get out-of-order in Safari
1348         https://bugs.webkit.org/show_bug.cgi?id=135332
1349         <rdar://problem/15317278>
1350
1351         Reviewed by Jer Noble.
1352
1353         * html/shadow/MediaControlElements.cpp:
1354         (WebCore::MediaControlTextTrackContainerElement::updateDisplay): If the
1355         number of active cues is greater than the current set of CSS boxes representing
1356         the cues, throw away the CSS boxes and re-layout all the cues.
1357         * html/track/InbandGenericTextTrack.cpp:
1358         (WebCore::InbandGenericTextTrack::addGenericCue): Add some logging.
1359         (WebCore::InbandGenericTextTrack::removeGenericCue): Ditto.
1360         * html/track/TextTrackCueGeneric.cpp:
1361         (WebCore::TextTrackCueGeneric::isOrderedBefore): Revise ordering rules so that we put
1362         newer cues earlier in the layout order so they are drawn towards the bottom
1363         of the screen. Only do this for Generic captions.
1364         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
1365         (WebCore::InbandTextTrackPrivateAVF::processAttributedStrings): Adjust logging
1366         messages.
1367         (WebCore::InbandTextTrackPrivateAVF::removeCompletedCues): Add logging.
1368
1369 2014-07-28  Andreas Kling  <akling@apple.com>
1370
1371         REGRESSION (r160806): CSS zoom property doesn't work on anything inside anchors.
1372         <https://webkit.org/b/135344>
1373         <rdar://problem/17759577>
1374
1375         When DeprecatedStyleBuilder applies the CSS zoom property (ApplyPropertyZoom)
1376         it first resets the "effective zoom" by calling RenderStyle::setEffectiveZoom().
1377
1378         This mechanism was not resistent to being called multiple times, due to the
1379         optimization in RenderStyle::setZoom() to avoid copy-on-writing the shared data
1380         when setting some property to the already-set value.
1381
1382         The bug would happen in this sequence:
1383
1384         ApplyPropertyZoom:
1385             - setEffectiveZoom(1);
1386             - setZoom(2); // this updates the effective zoom
1387         ApplyPropertyZoom:
1388             - setEffectiveZoom(1);
1389             - setZoom(2); // this doesn't update the effective zoom
1390
1391         When we run the second setZoom(2); call, the RenderStyle's zoom value is 2
1392         already and we'll early return without updating the effective zoom.
1393
1394         This change moves the updating of the effective zoom in setZoom() to take place
1395         before the early return due to overwriting with the same value.
1396
1397         Note: the fact that we're apply the zoom property twice is an inefficiency that
1398         we should figure out a way to avoid in the future.
1399
1400         Reviewed by Simon Fraser.
1401
1402         Test: fast/css/zoom-inside-link.html
1403
1404         * rendering/style/RenderStyle.h:
1405         (WebCore::RenderStyle::setZoom):
1406
1407 2014-07-28  Bear Travis  <betravis@adobe.com>
1408
1409         [CSS Font Loading] Update Font Loading Code
1410         https://bugs.webkit.org/show_bug.cgi?id=135340
1411
1412         Reviewed by Antti Koivisto.
1413
1414         Update the Font Loading code to build again, as trunk has evolved
1415         since the feature was originally written. Mostly, this requires
1416         updating the code to work with the new Font representation.
1417
1418         The original tests were enabled only for the Chromium port.
1419         They will need to be updated when the feature is enabled by default.
1420
1421         * WebCore.xcodeproj/project.pbxproj: Add missing files.
1422         * css/FontLoader.cpp: Update to new Font representation.
1423         (WebCore::LoadFontCallback::createFromParams):
1424         (WebCore::LoadFontCallback::~LoadFontCallback):
1425         (WebCore::FontLoader::loadFont):
1426         (WebCore::FontLoader::checkFont):
1427         (WebCore::applyPropertyToCurrentStyle):
1428         (WebCore::FontLoader::resolveFontStyle):
1429
1430 2014-07-28  Wenson Hsieh  <wenson_hsieh@apple.com>
1431
1432         Let WheelEvent wrap a PlatformWheelEvent
1433         https://bugs.webkit.org/show_bug.cgi?id=135244
1434
1435         WheelEvent now wraps a PlatformWheelEvent. m_directionInvertedFromDevice, as well as m_phase and m_momentumPhase
1436         have been removed, since the information is redundant in PlatformWheelEvent. Note that deltaX and deltaY have
1437         NOT been replaced, since we need double precision instead of float precision.
1438
1439         Reviewed by Beth Dakin.
1440
1441         No new tests, since behavior should not have changed.
1442
1443         * dom/WheelEvent.cpp:
1444         (WebCore::WheelEvent::WheelEvent):
1445         (WebCore::WheelEvent::initWheelEvent):
1446         * dom/WheelEvent.h:
1447         (WebCore::WheelEvent::wheelEvent): Returns a non-null pointer to the PlatformWheelEvent iff WheelEvent was initialized by PlatformWheelEvent.
1448         (WebCore::WheelEvent::webkitDirectionInvertedFromDevice): Updated to use PlatformWheelEvent.
1449         (WebCore::WheelEvent::phase): Updated to use PlatformWheelEvent.
1450         (WebCore::WheelEvent::momentumPhase): Updated to use PlatformWheelEvent.
1451
1452 2014-07-28  Brent Fulgham  <bfulgham@apple.com>
1453
1454         Unreviewed 'merge' fix.
1455
1456         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
1457         Correct line endings to allow EWS merges again.
1458
1459 2014-07-28  Zoltan Horvath  <zoltan@webkit.org>
1460
1461         [CSS3-Text] Adjust text-justify implementation to the latest spec
1462         https://bugs.webkit.org/show_bug.cgi?id=135317
1463
1464         Reviewed by Darin Adler.
1465
1466         Text-justify no longer accepts the following values: Inter-ideograph, inter-
1467         cluster, and kashida. This patch removes them and updates the tests as well.
1468
1469         [1] http://dev.w3.org/csswg/css-text-3/#propdef-text-justify
1470
1471         Updated existing tests.
1472
1473         * css/CSSParser.cpp:
1474         (WebCore::isValidKeywordPropertyAndValue):
1475         * css/CSSPrimitiveValueMappings.h:
1476         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1477         (WebCore::CSSPrimitiveValue::operator TextJustify):
1478         * css/CSSValueKeywords.in:
1479         * rendering/style/RenderStyle.cpp:
1480         (WebCore::RenderStyle::changeRequiresLayout):
1481         * rendering/style/RenderStyleConstants.h:
1482         * rendering/style/StyleRareInheritedData.h:
1483
1484 2014-07-28  Radu Stavila  <stavila@adobe.com>
1485
1486         REGRESSION (r169105): Crash in selection
1487         https://bugs.webkit.org/show_bug.cgi?id=134303
1488
1489         Reviewed by Mihnea Ovidenie.
1490
1491         When splitting the selection between different subtrees, all subtrees must have their selection cleared before
1492         starting to apply the new selection. Otherwise, when selecting objects in a named flow thread and going up
1493         its containing block chain, we can end up in the view's selection root, which has not yet been updated and so
1494         we get inconsistent data.
1495
1496         To achieve this goal, the selection update was split into a "clear" and an "apply" method. The updateSelectionForSubtrees
1497         method first iterates through all subtrees and performs the "clear" method and then starts all over again
1498         and performs the "apply" method.
1499
1500         Test: fast/regions/selection/crash-deselect.html
1501
1502         * WebCore.xcodeproj/project.pbxproj:
1503         * rendering/RenderSelectionInfo.h:
1504         * rendering/RenderView.cpp:
1505         (WebCore::RenderView::setSelection):
1506         (WebCore::RenderView::splitSelectionBetweenSubtrees):
1507         (WebCore::RenderView::updateSelectionForSubtrees): Added, clears and re-applies selection for all selection subtrees.
1508         (WebCore::RenderView::clearSubtreeSelection): Added, clears selection and returns previously selected information.
1509         (WebCore::RenderView::applySubtreeSelection): Added, updates the selection status of all objects inside the selection tree, compares old and new data and repaints accordingly.
1510         (WebCore::RenderView::setSubtreeSelection): Deleted.
1511         * rendering/RenderView.h:
1512         * rendering/SelectionSubtreeRoot.cpp:
1513         (WebCore::SelectionSubtreeRoot::SelectionSubtreeRoot):
1514         * rendering/SelectionSubtreeRoot.h:
1515         (WebCore::SelectionSubtreeRoot::OldSelectionData::OldSelectionData):
1516
1517 2014-07-28  Yusuke Suzuki  <utatane.tea@gmail.com>
1518
1519         CSS: Fix :visited behavior for SubSelectors
1520         https://bugs.webkit.org/show_bug.cgi?id=135324
1521
1522         Reviewed by Benjamin Poulain.
1523
1524         Disable :visited match for the selectors that has SubSelectors.
1525
1526         Tests: fast/history/nested-visited-test-complex.html
1527                fast/history/sibling-visited-test-complex.html
1528
1529         * css/SelectorChecker.cpp:
1530         (WebCore::SelectorChecker::matchRecursively):
1531
1532 2014-07-27  Ryuan Choi  <ryuan.choi@samsung.com>
1533
1534         Remove GraphicsSurfaceGLX.cpp
1535         https://bugs.webkit.org/show_bug.cgi?id=135279
1536
1537         Reviewed by Darin Adler.
1538
1539         GraphicsSurfaceGLX.cpp is not used since Qt dropped and Efl port changed at r146458
1540
1541         * platform/graphics/surfaces/glx/GraphicsSurfaceGLX.cpp: Removed.
1542
1543 2014-07-27  Bruno de Oliveira Abinader  <bruno.d@partner.samsung.com>
1544
1545         Support for :enabled selector on Anchor & Area elements
1546         https://bugs.webkit.org/show_bug.cgi?id=134826
1547
1548         Reviewed by Darin Adler.
1549
1550         Updates the PseudoClassEnabled selector checker to check for Anchor & Area
1551         elements with a 'href' attribute.
1552
1553         Spec: http://html.spec.whatwg.org/#selector-enabled
1554
1555         Test: fast/css/css-selector-enabled-links.html
1556
1557         * css/SelectorCheckerTestFunctions.h:
1558         (WebCore::isEnabled): Added check for anchor & area elements.
1559
1560 2014-07-27  Daniel Bates  <dabates@apple.com>
1561
1562         [WK2] Crash when accessing window.localStorage after calling window.close()
1563         https://bugs.webkit.org/show_bug.cgi?id=135328
1564         <rdar://problem/17315237>
1565
1566         Reviewed by Sam Weinig.
1567
1568         Fixes an issue where accessing local storage for the first time after calling window.close()
1569         causes a crash.
1570
1571         For now, we should disallow accessing local storage after calling window.close() regardless of
1572         whether it's the first access to local storage as this seems like a bad idiom to support. Note,
1573         this represents a change in behavior from WebKit1. If such usage of window.localStorage turns
1574         out to be reasonable then we can visit this decision again in <https://bugs.webkit.org/show_bug.cgi?id=135330>.
1575
1576         Tests: storage/domstorage/localstorage/access-storage-after-window-close.html
1577                storage/domstorage/localstorage/access-storage-then-set-value-in-storage-after-window-close.html
1578                storage/domstorage/localstorage/set-value-in-storage-after-window-close.html
1579
1580         * page/DOMWindow.cpp:
1581         (WebCore::DOMWindow::localStorage): Modified to only return the cached local storage or
1582         create a new local storage so long as the page isn't being closed. Also, substitute nullptr
1583         for 0.
1584         (WebCore::DOMWindow::close): Call Page::setIsClosing() to mark that the page is closing.
1585         * page/Page.cpp:
1586         (WebCore::Page::Page): Initialize m_isClosing to false.
1587         * page/Page.h:
1588         (WebCore::Page::setIsClosing): Added.
1589         (WebCore::Page::isClosing): Added.
1590
1591 2014-07-27  Filip Pizlo  <fpizlo@apple.com>
1592
1593         Merge r170090, r170092, r170129, r170141, r170161, r170215, r170275, r170375, r170376, r170382, r170383, r170399, r170436, r170489, r170490, r170556 from ftlopt.
1594         
1595         This fixes the previous mismerge and adds test coverage for the thing that went wrong.
1596         Also, this adds some helpers for making it easier to inspect JavaScript values.
1597
1598         * testing/Internals.cpp:
1599         (WebCore::Internals::description):
1600         * testing/Internals.h:
1601         * testing/Internals.idl:
1602
1603     2014-07-25  Mark Lam  <mark.lam@apple.com>
1604     
1605             [ftlopt] Renamed DebuggerActivation to DebuggerScope.
1606             <https://webkit.org/b/134273>
1607     
1608             Reviewed by Michael Saboff.
1609     
1610             No new tests.
1611     
1612             * ForwardingHeaders/debugger/DebuggerActivation.h: Removed.
1613             - Removed because this is not used.
1614     
1615 2014-07-26  Brian J. Burg  <burg@cs.washington.edu>
1616
1617         Web Replay: log and enforce session/segment state machine transitions
1618         https://bugs.webkit.org/show_bug.cgi?id=135224
1619
1620         Reviewed by Timothy Hatcher.
1621
1622         For debugging purposes, log session and segment state transitions.
1623         Assert that segment state transitions are valid.
1624
1625         No new tests. No behavior was changed.
1626
1627         * replay/ReplayController.cpp:
1628         (WebCore::logDispatchedDOMEvent):
1629         (WebCore::sessionStateToString):
1630         (WebCore::segmentStateToString):
1631         (WebCore::ReplayController::setSessionState):
1632         (WebCore::ReplayController::setSegmentState):
1633         (WebCore::ReplayController::createSegment):
1634         (WebCore::ReplayController::completeSegment): Remove a wrong state transition.
1635         (WebCore::ReplayController::loadSegmentAtIndex):
1636         (WebCore::ReplayController::unloadSegment): Fix a now-erroneous assertion.
1637         (WebCore::ReplayController::startPlayback):
1638         (WebCore::ReplayController::pausePlayback):
1639         (WebCore::ReplayController::willDispatchEvent):
1640         (WebCore::ReplayController::cancelPlayback):
1641         * replay/ReplayController.h:
1642
1643 2014-07-26  Filip Pizlo  <fpizlo@apple.com>
1644
1645         Unreviewed, roll out r171641-r171644. It broke some tests; will investigate and
1646         reland later.
1647
1648         * ForwardingHeaders/debugger/DebuggerActivation.h: Added.
1649
1650 2014-07-26  Timothy Horton  <timothy_horton@apple.com>
1651
1652         Crash in Web Content Process under ~PDFDocument under clearTouchEventListeners at topDocument()
1653         https://bugs.webkit.org/show_bug.cgi?id=135319
1654         <rdar://problem/17315168>
1655
1656         Reviewed by Darin Adler and Antti Koivisto.
1657
1658         * dom/Document.h:
1659         * dom/Document.cpp:
1660         (WebCore::Document::Document):
1661         (WebCore::Document::prepareForDestruction):
1662         Add a flag on Document, m_hasPreparedForDestruction, which ensures
1663         that each Document only goes through prepareForDestruction() once.
1664         prepareForDestruction() can be called a number of times during teardown,
1665         but it's only necessary to actually execute it once.
1666         
1667         This was previously achieved by virtue of all callers of prepareForDestruction()
1668         first checking hasLivingRenderTree, and prepareForDestruction() tearing down
1669         the render tree, but that meant that prepareForDestruction() was not called
1670         for Documents who never had a render tree in the first place.
1671
1672         The only part of prepareForDestruction() that is now predicated on hasLivingRenderTree()
1673         is the call to destroyRenderTree(); the rest of the function has the potential to be relevant
1674         for non-rendered placeholder documents and can safely deal with them in other ways.
1675
1676         It is important to call prepareForDestruction() on non-rendered placeholder documents
1677         because some of the cleanup (like disconnectFromFrame()) is critical to safe destruction.
1678
1679         * loader/FrameLoader.cpp:
1680         (WebCore::FrameLoader::clear):
1681         Call prepareForDestruction() even if we don't have a living render tree.
1682         For the sake of minimizing change, removeFocusedNodeOfSubtree still
1683         depends on having a living render tree before calling prepareForDestruction().
1684
1685         * page/Frame.cpp:
1686         (WebCore::Frame::setView):
1687         (WebCore::Frame::setDocument):
1688         Call prepareForDestruction() even if we don't have a living render tree.
1689
1690 2014-07-25  Filip Pizlo  <fpizlo@apple.com>
1691
1692         Merge r170090, r170092, r170129, r170141, r170161, r170215, r170275, r170375, r170376, r170382, r170383, r170399, r170436, r170489, r170490, r170556 from ftlopt.
1693
1694     2014-07-25  Mark Lam  <mark.lam@apple.com>
1695     
1696             [ftlopt] Renamed DebuggerActivation to DebuggerScope.
1697             <https://webkit.org/b/134273>
1698     
1699             Reviewed by Michael Saboff.
1700     
1701             No new tests.
1702     
1703             * ForwardingHeaders/debugger/DebuggerActivation.h: Removed.
1704             - Removed because this is not used.
1705     
1706 2014-07-25  Zalan Bujtas  <zalan@apple.com>
1707
1708         Subpixel rendering: Rounded rect gets non-renderable at certain subpixel size.
1709         https://bugs.webkit.org/show_bug.cgi?id=135314
1710         <rdar://problem/17812921>
1711
1712         Reviewed by Tim Horton.
1713
1714         While calculating the rounded rect for painting, the radius is adjusted to compensate
1715         for the pixel snapped size. However while scaling the radius, certain values overflow
1716         (float) mantissa and it produces a non-renderable rounded rect where the radius becomes bigger
1717         than the rectangle dimensions. In such cases, we need to shrink the radius to make it
1718         renderable again.
1719
1720         Test: transitions/rounded-rect-becomes-non-renderable-while-transitioning.html
1721
1722         * platform/graphics/RoundedRect.cpp:
1723         (WebCore::RoundedRect::pixelSnappedRoundedRectForPainting): shrink the radius by
1724         one device pixel. It is as good as any other small value.
1725
1726 2014-07-25  Jer Noble  <jer.noble@apple.com>
1727
1728         [EME][Mac] CDM error messages not piped through to MediaKeySession correctly; clients don't receive error events
1729         https://bugs.webkit.org/show_bug.cgi?id=135312
1730         <rdar://problem/17817223>
1731
1732         Reviewed by Brent Fulgham.
1733
1734         Set (and clear) the client interface so that errors can be piped from the CDMSession up to the MediaKeySession.
1735
1736         * Modules/encryptedmedia/MediaKeySession.cpp:
1737         (WebCore::MediaKeySession::MediaKeySession):
1738         (WebCore::MediaKeySession::close):
1739
1740 2014-07-25  Jer Noble  <jer.noble@apple.com>
1741
1742         [MSE] Playback stalls & readyState drops to HAVE_CURRENT_DATA at end of stream with unbalanced buffered SourceBuffers
1743         https://bugs.webkit.org/show_bug.cgi?id=135291
1744         <rdar://problem/17715503>
1745
1746         Reviewed by Sam Weinig.
1747
1748         Test: media/media-source/media-source-end-of-stream-buffered.html
1749
1750         When determining the correct ReadyState for the MediaSource in monitorSourceBuffers(), use the same
1751         definition of "buffered" as is used in the calculation of HTMLMediaElement.buffered and in the
1752         Stream Ended algorithm. Namely, when the stream has ended, treat each SourceBuffer as if its last
1753         buffered range extends to the duration of the stream. This allows playback to continue through to
1754         the duration without stalling due to monitorSourceBuffers().
1755
1756         * Modules/mediasource/SourceBuffer.cpp:
1757         (WebCore::SourceBuffer::bufferedAccountingForEndOfStream): Added; extends the last range in buffered
1758             to MediaSource::duration() if the MediaSource is ended.
1759         (WebCore::SourceBuffer::hasCurrentTime): Uses bufferedAccountingForEndOfStream().
1760         (WebCore::SourceBuffer::hasFutureTime): Ditto.
1761         (WebCore::SourceBuffer::canPlayThrough): Ditto.
1762         * Modules/mediasource/SourceBuffer.h:
1763
1764         Add a convenience method for determining whether the MediaSource has ended:
1765         * Modules/mediasource/MediaSource.cpp:
1766         (WebCore::MediaSource::isEnded):
1767         * Modules/mediasource/MediaSource.h:
1768
1769         Add start() and end() methods that don't take a (usually ignored) isValid inout parameter. Add duration()
1770         and maximumBufferedTime() convenience methods:
1771         * platform/graphics/PlatformTimeRanges.cpp:
1772         (WebCore::PlatformTimeRanges::start):
1773         (WebCore::PlatformTimeRanges::end):
1774         (WebCore::PlatformTimeRanges::duration):
1775         (WebCore::PlatformTimeRanges::maximumBufferedTime):
1776         * platform/graphics/PlatformTimeRanges.h:
1777
1778 2014-07-25  Pratik Solanki  <psolanki@apple.com>
1779
1780         [iOS] REGRESSION(r171526): Images fail to load sometimes
1781         https://bugs.webkit.org/show_bug.cgi?id=135304
1782         <rdar://problem/17811922>
1783
1784         Reviewed by Alexey Proskuryakov.
1785
1786         SharedBuffer::createCFData() calls data() as a way to coalesce the data array elements and
1787         segments into m_buffer. However, data() has an optimization where if we had a single element
1788         in the data array, it would just return that and not do coalescing. So when we passed
1789         m_buffer to WebCoreSharedData, we passed a buffer with no data in it.
1790
1791         Fix this by bringing the optimization to createCFData() and return the CFDataRef from the
1792         data array if we just have a single element.
1793
1794         No new tests. Should be covered by existing tests.
1795
1796         * platform/mac/SharedBufferMac.mm:
1797         (WebCore::SharedBuffer::createCFData):
1798
1799 2014-07-25  Jer Noble  <jer.noble@apple.com>
1800
1801         [MSE] High CPU usage in SampleMap::findSamplesWithinPresentationRange() with a large number of buffered samples.
1802         https://bugs.webkit.org/show_bug.cgi?id=135247
1803
1804         Reviewed by Geoffrey Garen.
1805
1806         Anchor our search for overlapping frames to the end of the search range when the overlap range is sufficiently
1807         close to the end of the search range. The common case for this search is when a sample is about to be appended
1808         to the end of the sample queue, so this should turn most searches into no-ops.
1809
1810         * Modules/mediasource/SampleMap.cpp:
1811         (WebCore::PresentationOrderSampleMap::findSamplesWithinPresentationRangeFromEnd):
1812         * Modules/mediasource/SampleMap.h:
1813         * Modules/mediasource/SourceBuffer.cpp:
1814         (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample):
1815
1816 2014-07-25  Gavin Barraclough  <baraclough@apple.com>
1817
1818         Yosemite version number is 101000
1819         https://bugs.webkit.org/show_bug.cgi?id=135301
1820
1821         Reviewed by Sam Weinig.
1822
1823         * WebCore.exp.in:
1824         * platform/ContentFilter.h:
1825         * platform/mac/ScrollViewMac.mm:
1826         (WebCore::ScrollView::platformVisibleContentRect):
1827         * platform/mac/ThemeMac.mm:
1828         (WebCore::updateStates):
1829         (WebCore::paintToggleButton):
1830         * platform/network/cf/CookieJarCFNet.cpp:
1831         (WebCore::copyCookiesForURLWithFirstPartyURL):
1832         * platform/network/cf/ResourceRequest.h:
1833         (WebCore::ResourceRequest::resourcePrioritiesEnabled):
1834         * rendering/RenderThemeMac.mm:
1835         (WebCore::RenderThemeMac::search):
1836
1837 2014-07-25  David Hyatt  <hyatt@apple.com>
1838
1839         [New Multicolumn] RenderViews paginated as RL or LR don't handle percentage widths correctly.
1840         REGRESSION: Images don’t scale to fit in page in vertical text books
1841
1842         https://bugs.webkit.org/show_bug.cgi?id=135204
1843         <rdar://problem/17043792>
1844         
1845         Reviewed by Simon Fraser.
1846
1847         Added fast/multicol/pagination/RightToLeft-max-width.html
1848
1849         * rendering/RenderView.cpp:
1850         (WebCore::RenderView::availableLogicalHeight):
1851         Put back in the same code that used to exist for the old columns (but ported to the new
1852         columns).
1853     
1854 2014-07-25  Dan Bernstein  <mitz@apple.com>
1855
1856         [Mac] Unneeded MobileMe workaround in ResourceHandle::receivedCredential
1857         https://bugs.webkit.org/show_bug.cgi?id=135297
1858
1859         Reviewed by Alexey Proskuryakov.
1860
1861         * platform/network/mac/ResourceHandleMac.mm:
1862         (WebCore::ResourceHandle::receivedCredential): Removed the site-specific behavior for
1863         gallery.me.com.
1864
1865 2014-07-25  Commit Queue  <commit-queue@webkit.org>
1866
1867         Unreviewed, rolling out r171480.
1868         https://bugs.webkit.org/show_bug.cgi?id=135300
1869
1870         it broke replaced elements in pagination (Requested by dhyatt_
1871         on #webkit).
1872
1873         Reverted changeset:
1874
1875         "Ensure we compute the min and max height of replaced elements
1876         to 'none' or 0 when appropriate."
1877         https://bugs.webkit.org/show_bug.cgi?id=135181
1878         http://trac.webkit.org/changeset/171480
1879
1880 2014-07-25  Commit Queue  <commit-queue@webkit.org>
1881
1882         Unreviewed, rolling out r171587.
1883         https://bugs.webkit.org/show_bug.cgi?id=135294
1884
1885         Made fast/dom/HTMLObjectElement/beforeload-set-text-
1886         crash.xhtml crash again (Requested by ap on #webkit).
1887
1888         Reverted changeset:
1889
1890         "REGRESSION (r169105): Crash in selection"
1891         https://bugs.webkit.org/show_bug.cgi?id=134303
1892         http://trac.webkit.org/changeset/171587
1893
1894 2014-07-25  Dan Bernstein  <mitz@apple.com>
1895
1896         ResourceErrorBase::compare doesn’t call the right platformCompare override
1897         https://bugs.webkit.org/show_bug.cgi?id=135240
1898
1899         Reviewed by Alexey Proskuryakov.
1900
1901         * platform/network/ResourceErrorBase.cpp:
1902         (WebCore::ResourceErrorBase::compare): Changed to call ResourceError::platformCompare.
1903         * platform/network/cf/ResourceError.h: Made platformCompare public.
1904         * platform/network/soup/ResourceError.h: Ditto.
1905
1906 2014-07-25  Dan Bernstein  <mitz@apple.com>
1907
1908         [Cocoa] WebProtectionSpace::receivesCredentialSecurely incorrectly returns false in some cases
1909         https://bugs.webkit.org/show_bug.cgi?id=135241
1910
1911         Reviewed by Alexey Proskuryakov.
1912
1913         * WebCore.exp.in: Export ProtectionSpace::receivesCredentialSecurely.
1914
1915         * platform/network/cocoa/ProtectionSpaceCocoa.h: Declare override of receivesCredentialSecurely.
1916         * platform/network/cocoa/ProtectionSpaceCocoa.mm:
1917         (WebCore::ProtectionSpace::receivesCredentialSecurely): Use -[NSURLProtectionSpace receivesCredentialSecurely].
1918
1919 2014-07-25  Zalan Bujtas  <zalan@apple.com>
1920
1921         Subpixel rendering: iOS video playback controls look blurry.
1922         https://bugs.webkit.org/show_bug.cgi?id=135245
1923         <rdar://problem/16878037>
1924
1925         Reviewed by Simon Fraser.
1926
1927         This patch introduces a compositing parent of the overlay control panel so that
1928         the transformed overlay panel becomes sharp. This is a workaround for webkit.org/b/135246.
1929
1930         Can't find a way to test it yet.
1931
1932         * Modules/mediacontrols/mediaControlsApple.css:
1933         (video::-webkit-media-controls-panel-composited-parent):
1934         * Modules/mediacontrols/mediaControlsApple.js:
1935         (Controller.prototype.createControls):
1936         (Controller.prototype.addControls):
1937         * Modules/mediacontrols/mediaControlsiOS.css:
1938         (video::-webkit-media-controls-panel-composited-parent):
1939         * Modules/mediacontrols/mediaControlsiOS.js: This is a workaround for webkit.org/b/135248
1940         It pushes the overlay panel down to close the gap with the video element. Since the
1941         panel's size in css pixels is scale dependent, the gap needs to be scale dependent too.
1942         (ControllerIOS.prototype.set pageScaleFactor):
1943
1944 2014-07-24  Dirk Schulze  <krit@webkit.org>
1945
1946         Turn x/y to presentation attributes
1947         https://bugs.webkit.org/show_bug.cgi?id=135215
1948
1949         Reviewed by Dean Jackson.
1950
1951         This follows the patch for width and height presentation attributes and
1952         turns x and y to presentation attributes as well:
1953
1954         http://trac.webkit.org/changeset/171341
1955
1956         Tests: svg/css/parse-length.html
1957                transitions/svg-layout-transition.html
1958
1959         Added copyright where I forgot it in previous patch.
1960
1961         * css/CSSComputedStyleDeclaration.cpp: Computed style of x and y.
1962         (WebCore::ComputedStyleExtractor::propertyValue):
1963         * css/CSSParser.cpp:
1964         (WebCore::isSimpleLengthPropertyID): Add x and y to list.
1965         * css/DeprecatedStyleBuilder.cpp:
1966         (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder): Resolve x and y.
1967         * css/SVGCSSParser.cpp:
1968         (WebCore::CSSParser::parseSVGValue): Parse x and y property.
1969         * css/SVGCSSPropertyNames.in: Add x and y to list of names.
1970         * css/StyleResolver.h:
1971         * page/animation/CSSPropertyAnimation.cpp: Animate x and y as Length.
1972         (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
1973         * rendering/style/RenderStyle.h: Add x and y setters and getters.
1974         * rendering/style/SVGRenderStyle.cpp: Add x and y setters for StyleLayoutData.
1975         (WebCore::SVGRenderStyle::SVGRenderStyle):
1976         (WebCore::SVGRenderStyle::operator==):
1977         (WebCore::SVGRenderStyle::copyNonInheritedFrom):
1978         (WebCore::SVGRenderStyle::diff):
1979         * rendering/style/SVGRenderStyle.h:
1980         (WebCore::SVGRenderStyle::setX):
1981         (WebCore::SVGRenderStyle::setY):
1982         (WebCore::SVGRenderStyle::x):
1983         (WebCore::SVGRenderStyle::y):
1984         * rendering/style/SVGRenderStyleDefs.cpp: Add StyleLayoutData for style storing.
1985         (WebCore::StyleLayoutData::StyleLayoutData):
1986         (WebCore::StyleLayoutData::copy):
1987         (WebCore::StyleLayoutData::operator==):
1988         * rendering/style/SVGRenderStyleDefs.h:
1989         (WebCore::StyleLayoutData::create):
1990         (WebCore::StyleLayoutData::operator!=):
1991         * rendering/svg/RenderSVGRect.cpp:
1992         (WebCore::RenderSVGRect::updateShapeFromElement):
1993         * rendering/svg/SVGPathData.cpp: Use RenderStyle values rather than attribute values.
1994         (WebCore::updatePathFromRectElement):
1995         * svg/SVGAnimationElement.cpp:
1996         (WebCore::SVGAnimationElement::isTargetAttributeCSSProperty): Fix text detection.
1997         * svg/SVGElement.cpp: Add x and y to the relevant property lists.
1998         (WebCore::populateAttributeNameToCSSPropertyIDMap):
1999         (WebCore::populateCSSPropertyWithSVGDOMNameToAnimatedPropertyTypeMap):
2000         * svg/SVGFilterElement.cpp: Style update on change of x and y.
2001         (WebCore::SVGFilterElement::svgAttributeChanged):
2002         * svg/SVGMaskElement.cpp: Ditto.
2003         (WebCore::SVGMaskElement::svgAttributeChanged):
2004         * svg/SVGPatternElement.cpp: Ditto.
2005         (WebCore::SVGPatternElement::svgAttributeChanged):
2006         * svg/SVGRectElement.cpp: Ditto.
2007         (WebCore::SVGRectElement::svgAttributeChanged):
2008         * svg/SVGTextPositioningElement.cpp: Exclude x and y of text elements since they
2009             are lists instead of individual values. Solution about to be discussed
2010             in the WG. Keep current behavior for now.
2011         (WebCore::SVGTextPositioningElement::collectStyleForPresentationAttribute):
2012         (WebCore::SVGTextPositioningElement::isPresentationAttribute):
2013         * svg/SVGTextPositioningElement.h:
2014
2015 2014-07-24  Yusuke Suzuki  <utatane.tea@gmail.com>
2016
2017         CSS JIT: Implement Pseudo Element
2018         https://bugs.webkit.org/show_bug.cgi?id=134835
2019
2020         Reviewed by Benjamin Poulain.
2021
2022         Implement Pseudo Element handling for CSS JIT SelectorCompiler.
2023         At first, we start with the simple implementation. We handle limited number of pseudo element,
2024         before, after, first-line, first-letter.
2025
2026         Tests: fast/selectors/pseudo-element-inside-any.html
2027                fast/selectors/querySelector-pseudo-element-inside-functional-pseudo-class-any.html
2028                fast/selectors/querySelector-pseudo-element-inside-functional-pseudo-class-not.html
2029                fast/selectors/querySelector-pseudo-element.html
2030
2031         * css/ElementRuleCollector.cpp:
2032         (WebCore::ElementRuleCollector::ruleMatches):
2033         * css/SelectorChecker.cpp:
2034         (WebCore::SelectorChecker::matchRecursively):
2035         * cssjit/SelectorCompiler.cpp:
2036         (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
2037         (WebCore::SelectorCompiler::constructFragments):
2038         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateSelectorChecker):
2039         (WebCore::SelectorCompiler::SelectorCodeGenerator::loadCheckingContext):
2040         (WebCore::SelectorCompiler::SelectorCodeGenerator::branchOnResolvingModeWithCheckingContext):
2041         (WebCore::SelectorCompiler::SelectorCodeGenerator::branchOnResolvingMode):
2042         (WebCore::SelectorCompiler::SelectorCodeGenerator::jumpIfNotResolvingStyle):
2043         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
2044         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsActive):
2045         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsHovered):
2046         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementHasPseudoElement):
2047         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateRequestedPseudoElementEqualsToSelectorPseudoElement):
2048         (WebCore::SelectorCompiler::SelectorCodeGenerator::generateMarkPseudoStyleForPseudoElement):
2049         * cssjit/SelectorCompiler.h:
2050         * rendering/style/RenderStyle.h:
2051         * rendering/style/RenderStyleConstants.h:
2052
2053 2014-07-24  Radu Stavila  <stavila@adobe.com>
2054
2055         REGRESSION (r169105): Crash in selection
2056         https://bugs.webkit.org/show_bug.cgi?id=134303
2057
2058         Patch by Radu Stavila <stavila@adobe.com> on 2014-07-24
2059         Reviewed by David Hyatt.
2060
2061         When splitting the selection between different subtrees, all subtrees must have their selection cleared before
2062         starting to apply the new selection. Otherwise, when selecting objects in a named flow thread and going up
2063         its containing block chain, we can end up in the view's selection root, which has not yet been updated and so
2064         we get inconsistent data.
2065
2066         To achieve this goal, the selection update was split into a "clear" and an "apply" method. The updateSelectionForSubtrees
2067         method first iterates through all subtrees and performs the "clear" method and then starts all over again
2068         and performs the "apply" method.
2069
2070         Test: fast/regions/selection/crash-deselect.html
2071
2072         * WebCore.xcodeproj/project.pbxproj:
2073         * rendering/RenderSelectionInfo.h:
2074         * rendering/RenderView.cpp:
2075         (WebCore::RenderView::setSelection):
2076         (WebCore::RenderView::splitSelectionBetweenSubtrees):
2077         (WebCore::RenderView::updateSelectionForSubtrees): Added, clears and re-applies selection for all selection subtrees.
2078         (WebCore::RenderView::clearSubtreeSelection): Added, clears selection and returns previously selected information.
2079         (WebCore::RenderView::applySubtreeSelection): Added, updates the selection status of all objects inside the selection tree, compares old and new data and repaints accordingly.
2080         (WebCore::RenderView::setSubtreeSelection): Deleted.
2081         * rendering/RenderView.h:
2082         * rendering/SelectionSubtreeRoot.cpp:
2083         (WebCore::SelectionSubtreeRoot::SelectionSubtreeRoot):
2084         * rendering/SelectionSubtreeRoot.h:
2085         (WebCore::SelectionSubtreeRoot::OldSelectionData::OldSelectionData):
2086
2087 2014-07-24  Ryosuke Niwa  <rniwa@webkit.org>
2088
2089         REGRESSION(r164401): Placing a caret doesn't bring up autocorrection panel
2090         https://bugs.webkit.org/show_bug.cgi?id=135278
2091
2092         Reviewed by Tim Horton.
2093
2094         The bug was caused by editorUIUpdateTimerFired calling respondToChangedSelection only if the selection was
2095         triggered by dictation instead of only if it was NOT triggered by dictation.
2096
2097         Prior to r164401, AlternativeTextController::respondToMarkerAtEndOfWord exited early when SetSelectionOptions
2098         had DictationTriggered set. r164401 intended to move this check to editorUIUpdateTimerFired to avoid passing
2099         options around but the boolean condition was erroneously flipped.
2100
2101         Fixed the bug by negating the condition in editorUIUpdateTimerFired.
2102
2103         No new tests for now since autocorrection panel cannot be tested automatically. (We should really automate this!)
2104
2105         * editing/Editor.cpp:
2106         (WebCore::Editor::editorUIUpdateTimerFired):
2107
2108 2014-07-24  Pratik Solanki  <psolanki@apple.com>
2109
2110         REGRESSION(r171526): [GTK] Massive crashes.
2111         https://bugs.webkit.org/show_bug.cgi?id=135283
2112
2113         Unreviewed. GTK build fix after r171526. Initialize m_buffer in SharedBuffer constructor.
2114
2115         * platform/soup/SharedBufferSoup.cpp:
2116         (WebCore::SharedBuffer::SharedBuffer):
2117
2118 2014-07-24  Tim Horton  <timothy_horton@apple.com>
2119
2120         Crashes under scanSelectionForTelephoneNumbers in Range::text() on some sites
2121         https://bugs.webkit.org/show_bug.cgi?id=135281
2122         <rdar://problem/17803347>
2123
2124         Reviewed by Ryosuke Niwa.
2125
2126         * editing/Editor.cpp:
2127         (WebCore::Editor::scanSelectionForTelephoneNumbers):
2128         toNormalizedRange is not guaranteed to return a non-null range.
2129         If it returns null, pass the empty markedRanges down to the client as our new set.
2130
2131 2014-07-24  Dan Bernstein  <mitz@apple.com>
2132
2133         WebCore part of <rdar://problem/17593701> Assertion failure in WebPage::reload (!m_pendingNavigationID) when reloading after a same-document back navigation
2134         https://bugs.webkit.org/show_bug.cgi?id=135129
2135
2136         Reviewed by Darin Adler.
2137
2138         * WebCore.exp.in: Exported equalIgnoringFragmentIdentifier(const URL&, const URL&).
2139
2140 2014-07-24  Simon Fraser  <simon.fraser@apple.com>
2141
2142         [iOS WK1] CSS viewport units use the wrong viewport size in WebKit1
2143         https://bugs.webkit.org/show_bug.cgi?id=135254
2144         <rdar://problem/17781423>
2145
2146         Reviewed by Tim Horton.
2147
2148         Test: fast/css/viewport-units-dynamic.html
2149         
2150         In WebKit1 on iOS, we want to resolve viewport units against the visible
2151         viewport, not the legacy WK1 notion of the "viewport" which is the entire document.
2152         
2153         Fixes rendering of medium.com articles in WK1 views on iPad.
2154
2155         * page/FrameView.cpp:
2156         (WebCore::FrameView::viewportSizeForCSSViewportUnits):
2157
2158 2014-07-24  Myles C. Maxfield  <mmaxfield@apple.com>
2159
2160         Crash when measuring a glyphs from a fallback SVG font
2161         https://bugs.webkit.org/show_bug.cgi?id=135264
2162
2163         Reviewed by Simon Fraser.
2164
2165         We can't realize font data for all fallback fonts ahead
2166         of time, but we don't have all the necessary context to
2167         realize SVG fallback data when it's needed. For now, we
2168         can just bail; however, a larger, more invasive fix is
2169         in order.
2170
2171         Test: svg/text/svg-fallback-font-crash.html
2172
2173         * platform/graphics/WidthIterator.cpp:
2174         (WebCore::applyFontTransforms):
2175
2176 2014-07-24  Daniel Bates  <dabates@apple.com>
2177             And Alexey Proskuryakov  <ap@apple.com>
2178
2179         [iOS] REGRESSION (WebKit2): Can't login to Wordpress.com, facebook.com when always allowing cookies
2180         https://bugs.webkit.org/show_bug.cgi?id=135273
2181         <rdar://problem/17598815>
2182
2183         Reviewed by Alexey Proskuryakov.
2184
2185         Fixes an issue where cookies may be created in the wrong cookie store.
2186
2187         Currently, when we update the CFURLRequest object associated with a ResourceRequest object
2188         we explicitly set a cookie storage, cookie accept policy, and SSL properties based on the
2189         corresponding values in the old CFURLRequest object (if we have one). This ultimately leads
2190         to CFNetwork associating the cookies for the request with a different cookie store when we
2191         handle the request in the NetworkProcess. Instead, we shouldn't set these properties
2192         explicitly as we already copy them implicitly earlier (via CFURLRequestCreateMutableCopy()).
2193
2194         * platform/network/cf/ResourceRequestCFNet.cpp:
2195         (WebCore::ResourceRequest::doUpdatePlatformRequest):
2196
2197 2014-07-24  Peyton Randolph  <prandolph@apple.com>
2198
2199         Rename feature flag for long-press gesture on Mac.                                                                   
2200         https://bugs.webkit.org/show_bug.cgi?id=135259                                                                  
2201
2202         Reviewed by Beth Dakin.
2203
2204         * Configurations/FeatureDefines.xcconfig:
2205         Rename LINK_LONG_PRESS to MAC_LONG_PRESS.
2206
2207 2014-07-24  Dan Bernstein  <mitz@apple.com>
2208
2209         Fixed Windows build fix.
2210
2211         * platform/network/cf/AuthenticationCF.cpp:
2212
2213 2014-07-24  Dan Bernstein  <mitz@apple.com>
2214
2215         Attempted Windows build fix.
2216
2217         * platform/network/cf/AuthenticationCF.cpp:
2218         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
2219         * platform/network/cf/CredentialStorageCFNet.cpp:
2220         (WebCore::CredentialStorage::getFromPersistentStorage):
2221         * platform/network/cf/ProtectionSpaceCFNet.cpp:
2222         (WebCore::ProtectionSpace::receivesCredentialSecurely):
2223         (WebCore::ProtectionSpaceBase::receivesCredentialSecurely): Deleted.
2224
2225 2014-07-24  Dan Bernstein  <mitz@apple.com>
2226
2227         <rdar://problem/17766348> [Cocoa] WebCore::ProtectionSpace doesn’t preserve all NSURLProtectionSpace properties, such as the distinguishedNames array
2228         https://bugs.webkit.org/show_bug.cgi?id=135229
2229
2230         Reviewed by Alexey Proskuryakov.
2231
2232         * CMakeLists.txt: Updated for rename of a source file.
2233
2234         * WebCore.exp.in: Updated.
2235
2236         * WebCore.vcxproj/WebCore.vcxproj: Updated for rename of source files, added
2237         ProtectionSpaceCFNet.{cpp,h}.
2238         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
2239
2240         * WebCore.xcodeproj/project.pbxproj: Updated for rename of source files, added
2241         ProtectionSpaceCococa.{h.mm}.
2242
2243         * platform/network/ProtectionSpace.cpp: Renamed to ProtectionSpaceBase.cpp.
2244         * platform/network/ProtectionSpace.h: This file was renamed to ProtectionSpaceBase.h, and
2245         in its place added a generic ProtectionSpace class that just derives from
2246         ProtectionSpaceBase. For Cocoa and CFNetwork, ProtectionSpace{Cocoa,CFNet}.h is included
2247         instead of the generic class.
2248
2249         * platform/network/ProtectionSpaceBase.cpp: Renamed ProtectionSpace.cpp to this.
2250         (WebCore::ProtectionSpaceBase::ProtectionSpaceBase): Updated for rename.
2251         (WebCore::ProtectionSpaceBase::host): Ditto.
2252         (WebCore::ProtectionSpaceBase::port): Ditto.
2253         (WebCore::ProtectionSpaceBase::serverType): Ditto.
2254         (WebCore::ProtectionSpaceBase::isProxy): Ditto.
2255         (WebCore::ProtectionSpaceBase::realm): Ditto.
2256         (WebCore::ProtectionSpaceBase::authenticationScheme): Ditto.
2257         (WebCore::ProtectionSpaceBase::receivesCredentialSecurely): Removed CFNetwork-specific part,
2258         which is now implemented in ProtectionSpaceCFNet.cpp.
2259         (WebCore::ProtectionSpaceBase::compare): Replaced operator== with this, and made it call
2260         ProtectionSpace::platformCompare at the end if needed.
2261
2262         * platform/network/ProtectionSpaceBase.h: Renamed ProtectionSpace.h to this.
2263         (WebCore::ProtectionSpaceBase::encodingRequiresPlatformData): Added with a default
2264         implementation that returns false, for ProtectionSpace implementations to override.
2265         (WebCore::ProtectionSpaceBase::platformCompare): Added with a default implementation that
2266         returns true, for ProtectionSpace implementations to override.
2267         (WebCore::operator==): Changed to call compare.
2268
2269         * platform/network/cf/AuthenticationCF.cpp:
2270         (WebCore::AuthenticationChallenge::AuthenticationChallenge): Changed to use the
2271         ProtectionSpace constructor that takes a CFURLProtectionSpaceRef.
2272         (WebCore::createCF): Changed to use ProtectionSpace::cfSpace.
2273
2274         * platform/network/cf/AuthenticationCF.h: Guarded a couple of functiosn that aren’t used in
2275         Cocoa with #if PLATFORM(WIN).
2276
2277         * platform/network/cf/CredentialStorageCFNet.cpp:
2278         (WebCore::CredentialStorage::getFromPersistentStorage): Changed to use
2279         ProtectionSpace::cfSpace.
2280         (WebCore::CredentialStorage::saveToPersistentStorage): Ditto.
2281
2282         * platform/network/cf/ProtectionSpaceCFNet.cpp: Added.
2283         (WebCore::ProtectionSpaceBase::receivesCredentialSecurely): Override with the
2284         CFNetwork-specific test that was previously in ProtectionSpace.cpp.
2285
2286         * platform/network/cf/ProtectionSpaceCFNet.h: Copied from Source/WebCore/platform/network/ProtectionSpace.h.
2287         Declare ProtectionSpace and override receivesCredentialSecurely.
2288
2289         * platform/network/mac/AuthenticationMac.h: Deleted the ProtectionSpace core() and mac().
2290         * platform/network/mac/AuthenticationMac.mm:
2291         (WebCore::AuthenticationChallenge::AuthenticationChallenge): Changed to use the
2292         ProtectionSpace constructor that takes an NSURLProtectionSpace.
2293         (WebCore::mac): Changed to use ProtectionSpace::nsSpace.
2294
2295         * platform/network/mac/CredentialStorageMac.mm:
2296         (WebCore::CredentialStorage::getFromPersistentStorage): Ditto.
2297
2298         * platform/network/mac/ResourceHandleMac.mm:
2299         (WebCore::ResourceHandle::receivedCredential): Changed to use the ProtectionSpace
2300         constructor that takes an NSURLProtectionSpace.
2301
2302         * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
2303         (-[WebCoreResourceHandleAsDelegate connection:canAuthenticateAgainstProtectionSpace:]):
2304         Ditto.
2305
2306         * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
2307         (-[WebCoreResourceHandleAsOperationQueueDelegate connection:canAuthenticateAgainstProtectionSpace:]):
2308         Ditto.
2309
2310 2014-07-24  Benjamin Poulain  <benjamin@webkit.org>
2311
2312         [WK2] Fixed/Sticky layers can get mispositioned when the layer tree commit change their position or size
2313         https://bugs.webkit.org/show_bug.cgi?id=135227
2314         <rdar://problem/17279500>
2315
2316         Reviewed by Simon Fraser.
2317
2318         Keep track of the creation/destruction of Fixed and Sticky nodes in the ScrollingTree.
2319
2320         * page/scrolling/ScrollingTree.cpp:
2321         (WebCore::ScrollingTree::ScrollingTree):
2322         * page/scrolling/ScrollingTree.h:
2323         (WebCore::ScrollingTree::hasFixedOrSticky):
2324         (WebCore::ScrollingTree::fixedOrStickyNodeAdded):
2325         (WebCore::ScrollingTree::fixedOrStickyNodeRemoved):
2326         * page/scrolling/mac/ScrollingTreeFixedNode.mm:
2327         (WebCore::ScrollingTreeFixedNode::ScrollingTreeFixedNode):
2328         (WebCore::ScrollingTreeFixedNode::~ScrollingTreeFixedNode):
2329         * page/scrolling/mac/ScrollingTreeStickyNode.mm:
2330         (WebCore::ScrollingTreeStickyNode::ScrollingTreeStickyNode):
2331         (WebCore::ScrollingTreeStickyNode::~ScrollingTreeStickyNode):
2332
2333 2014-07-24  Wenson Hsieh  <wenson_hsieh@apple.com>
2334
2335         Let WheelEvent wrap a PlatformWheelEvent
2336         https://bugs.webkit.org/show_bug.cgi?id=135244
2337
2338         When WheelEvent is initialized with a PlatformWheelEvent, store that PlatformWheelEvent for future use.
2339
2340         Reviewed by Beth Dakin.
2341
2342         No new tests because behavior should not have changed.
2343
2344         * dom/WheelEvent.cpp: Added method to access the PlatformWheelEvent.
2345         (WebCore::WheelEvent::WheelEvent):
2346         * dom/WheelEvent.h: Added field to store PlatformWheelEvent, if initialized via PlatformWheelEvent.
2347         (WebCore::WheelEvent::wheelEvent):
2348
2349 2014-07-24  Brian J. Burg  <burg@cs.washington.edu>
2350
2351         Web Replay: don't encode/decode primitive types that lack explicit sizes
2352         https://bugs.webkit.org/show_bug.cgi?id=133430
2353
2354         Reviewed by Anders Carlsson.
2355
2356         Remove uses of unsigned long in encode/decode methods because the type lacks an
2357         explicit size. Move frame index serialization away from using unsigned long.
2358
2359         * replay/ReplayController.cpp:
2360         (WebCore::logDispatchedDOMEvent): Fix the format string.
2361         * replay/SerializationMethods.cpp:
2362         (WebCore::frameIndexFromDocument):
2363         (WebCore::frameIndexFromFrame):
2364         (WebCore::documentFromFrameIndex):
2365         (WebCore::frameFromFrameIndex):
2366         (JSC::EncodingTraits<PluginData>::encodeValue):
2367         (JSC::EncodingTraits<PluginData>::decodeValue):
2368         * replay/SerializationMethods.h:
2369         * replay/WebInputs.json: Remove primitive types without explicit sizes.
2370
2371 2014-07-24  Pratik Solanki  <psolanki@apple.com>
2372
2373         Sharing SharedBuffer between WebCore and ImageIO is racy and crash prone
2374         https://bugs.webkit.org/show_bug.cgi?id=135069
2375         <rdar://problem/17470655>
2376
2377         Reviewed by Simon Fraser.
2378
2379         When passing image data to ImageIO for decoding, we pass an NSData subclass that is a wraper
2380         around SharedBuffer. This can be a problem when ImageIO tries to access the data on the CA
2381         thread. End result is data corruption on large image loads and potential crashes. The fix is
2382         to have SharedBuffer create a copy of its data if the data has been passed to ImageIO and
2383         might be accessed concurrently.
2384
2385         Since Vector is not refcounted, we do this by having a new refcounted object in SharedBuffer
2386         that contains the buffer and we pass that in our NSData subclass WebCoreSharedBufferData.
2387         Code that would result in the Vector memory moving e.g. append(), resize(), now checks to
2388         see if the buffer was shared and if so, will create a new copy of the vector. This ensures
2389         that the main thread does not end up invalidating the vector memory that we have passed it
2390         to ImageIO.
2391
2392         No new tests because no functional changes.
2393
2394         * loader/cache/CachedResource.cpp:
2395         (WebCore::CachedResource::makePurgeable):
2396             Remove early return - createPurgeableMemory() has the correct check now.
2397         * platform/SharedBuffer.cpp:
2398         (WebCore::SharedBuffer::SharedBuffer):
2399         (WebCore::SharedBuffer::adoptVector):
2400         (WebCore::SharedBuffer::createPurgeableBuffer):
2401             Don't create purgeable buffer if we are sharing the buffer.
2402         (WebCore::SharedBuffer::append):
2403         (WebCore::SharedBuffer::clear):
2404         (WebCore::SharedBuffer::copy):
2405         (WebCore::SharedBuffer::duplicateDataBufferIfNecessary): Added.
2406             Create a new copy of the data if we have shared the buffer and if appending to it would
2407             exceed the capacity of the vector resulting in memmove.
2408         (WebCore::SharedBuffer::appendToInternalBuffer): Added.
2409         (WebCore::SharedBuffer::clearInternalBuffer): Added.
2410         (WebCore::SharedBuffer::buffer):
2411             Create a new copy of the buffer if we have shared it.
2412         (WebCore::SharedBuffer::getSomeData):
2413         * platform/SharedBuffer.h:
2414         * platform/cf/SharedBufferCF.cpp:
2415         (WebCore::SharedBuffer::SharedBuffer):
2416         (WebCore::SharedBuffer::singleDataArrayBuffer):
2417         (WebCore::SharedBuffer::maybeAppendDataArray):
2418         * platform/mac/SharedBufferMac.mm:
2419             Pass the InternalBuffer object to WebCoreSharedBufferData
2420         (-[WebCoreSharedBufferData dealloc]):
2421         (-[WebCoreSharedBufferData initWithSharedBufferInternalBuffer:]):
2422         (-[WebCoreSharedBufferData length]):
2423         (-[WebCoreSharedBufferData bytes]):
2424         (WebCore::SharedBuffer::createNSData):
2425             Call createCFData() instead of duplicating code.
2426         (WebCore::SharedBuffer::createCFData):
2427             If the data is in purgeable memory, make a copy of it since m_buffer was cleared when
2428             creating the purgeable buffer.
2429         (-[WebCoreSharedBufferData initWithSharedBuffer:]): Deleted.
2430
2431 2014-07-24  peavo@outlook.com  <peavo@outlook.com>
2432
2433         [Curl] Enable file logging.
2434         https://bugs.webkit.org/show_bug.cgi?id=135202
2435
2436         Reviewed by Alex Christensen.
2437
2438         The Curl api offers the possibility to write log messages to file. Enable this for debugging purposes.
2439
2440         * platform/network/curl/ResourceHandleManager.cpp:
2441         (WebCore::ResourceHandleManager::ResourceHandleManager):
2442         (WebCore::ResourceHandleManager::~ResourceHandleManager):
2443         (WebCore::ResourceHandleManager::initializeHandle):
2444         * platform/network/curl/ResourceHandleManager.h:
2445
2446 2014-07-24  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
2447
2448         Sort WebCore.exp.in after r171252
2449         https://bugs.webkit.org/show_bug.cgi?id=135239
2450
2451         Reviewed by Csaba Osztrogonác.
2452
2453         * WebCore.exp.in:
2454
2455 2014-07-24  Mihnea Ovidenie  <mihnea@adobe.com>
2456
2457         [New Multicolumn] Assertion failure when an input element has multicolumn style
2458         https://bugs.webkit.org/show_bug.cgi?id=135234
2459
2460         Reviewed by Andrei Bucur.
2461
2462         Restrict the assertion in RenderBlock::canComputeRegionRangeForBox
2463         only to RenderNamedFlowThread objects since for RenderMultiColumnFlowThread
2464         objects we can compute a range of regions during their parent block layout.   
2465
2466         Test: fast/multicol/newmulticol/input-as-multicol.html
2467
2468         * rendering/RenderBlock.cpp:
2469         (WebCore::canComputeRegionRangeForBox):
2470
2471 2014-07-23  Jeremy Jones  <jeremyj@apple.com>
2472
2473         Transparent fullscreen background when video is not present.
2474         https://bugs.webkit.org/show_bug.cgi?id=135226
2475
2476         Reviewed by Simon Fraser.
2477
2478         Set background to black just before beginning the animation to fullscreen.
2479
2480         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
2481         (WebVideoFullscreenInterfaceAVKit::enterFullscreen): set background color black.
2482
2483 2014-07-23  Joseph Pecoraro  <pecoraro@apple.com>
2484
2485         ScriptController::updateDocument ASSERT mutating map while iterating map
2486         https://bugs.webkit.org/show_bug.cgi?id=135211
2487
2488         Reviewed by Oliver Hunt.
2489
2490         Avoid iterating over m_windowShells in more places. This prevents
2491         the possibility of a collection during JSC allocation which might
2492         cause a mutation to m_windowShells (HTMLMediaElement destruction).
2493
2494         Have ScriptController defriend ScriptCachedFrameData by providing
2495         a getter for the list of window shells.
2496
2497         * bindings/js/ScriptCachedFrameData.cpp:
2498         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
2499         (WebCore::ScriptCachedFrameData::restore):
2500         * bindings/js/ScriptController.cpp:
2501         (WebCore::ScriptController::windowShells):
2502         (WebCore::ScriptController::clearWindowShell):
2503         (WebCore::ScriptController::attachDebugger):
2504         (WebCore::ScriptController::updateDocument):
2505         * bindings/js/ScriptController.h:
2506
2507 2014-07-23  Commit Queue  <commit-queue@webkit.org>
2508
2509         Unreviewed, rolling out r171498.
2510         https://bugs.webkit.org/show_bug.cgi?id=135223
2511
2512         It will regress some scroll position restoration on navigation
2513         (r167916). (Requested by smfr on #webkit).
2514
2515         Reverted changeset:
2516
2517         "[iOS WK2] Header bar on nytimes articles lands in the wrong
2518         place after rubberbanding"
2519         https://bugs.webkit.org/show_bug.cgi?id=135221
2520         http://trac.webkit.org/changeset/171498
2521
2522 2014-07-23  Tim Horton  <timothy_horton@apple.com>
2523
2524         REGRESSION (r171376): Sometimes we detect less than the whole phone number
2525         https://bugs.webkit.org/show_bug.cgi?id=135220
2526         <rdar://problem/17783423>
2527
2528         Reviewed by Brady Eidson.
2529
2530         * editing/Editor.cpp:
2531         (WebCore::Editor::scanSelectionForTelephoneNumbers):
2532         Use the visible selection's start and end instead of base and extent, because they'll
2533         always be in the right order in the case of a directional selection (base can be *after* extent
2534         if you select from right to left). This fixes the code that expands the selection.
2535
2536         Pass the *entire* expanded selection to DataDetectors, instead of using TextIterator.
2537         This way, we will find each number only once, and will never get part of a phone number once
2538         and then the whole phone number later.
2539
2540 2014-07-23  Simon Fraser  <simon.fraser@apple.com>
2541
2542         [iOS WK2] Header bar on nytimes articles lands in the wrong place after rubberbanding
2543         https://bugs.webkit.org/show_bug.cgi?id=135221
2544
2545         Reviewed by Tim Horton.
2546
2547         Add a function on GraphicsLayer to force a flush of the layer position
2548         to the underlying graphics system, so that when layers cease being
2549         scroll-coordinated, we can ensure that their layers are repositioned
2550         in the correct location.
2551
2552         * WebCore.exp.in:
2553         * platform/graphics/GraphicsLayer.h:
2554         (WebCore::GraphicsLayer::forcePositionUpdate):
2555         * platform/graphics/ca/GraphicsLayerCA.cpp:
2556         (WebCore::GraphicsLayerCA::forcePositionUpdate):
2557         * platform/graphics/ca/GraphicsLayerCA.h:
2558         * rendering/RenderLayerCompositor.cpp:
2559         (WebCore::RenderLayerCompositor::detachScrollCoordinatedLayer):
2560
2561 2014-07-23  Pratik Solanki  <psolanki@apple.com>
2562
2563         Get rid of SharedBuffer::NSDataRetainPtrWithoutImplicitConversionOperator
2564         https://bugs.webkit.org/show_bug.cgi?id=135219
2565
2566         Reviewed by Anders Carlsson.
2567
2568         No new tests because no functional changes.
2569
2570         * loader/ResourceBuffer.h:
2571         * loader/mac/ResourceBuffer.mm:
2572         (WebCore::ResourceBuffer::createNSData):
2573         * platform/SharedBuffer.h:
2574         (WebCore::SharedBuffer::NSDataRetainPtrWithoutImplicitConversionOperator::NSDataRetainPtrWithoutImplicitConversionOperator): Deleted.
2575         * platform/mac/SharedBufferMac.mm:
2576         (WebCore::SharedBuffer::createNSData):
2577
2578 2014-07-23  Zalan Bujtas  <zalan@apple.com>
2579
2580         Subpixel rendering: Cleanup RenderLayerCompositor::deviceScaleFactor()
2581         https://bugs.webkit.org/show_bug.cgi?id=135208
2582
2583         Reviewed by Simon Fraser.
2584
2585         Use m_renderView.document() to retrieve device scale factor value. m_renderView.document()
2586         is always available while this->page() is not.
2587
2588         No change in behavior.
2589
2590         * rendering/RenderLayerBacking.cpp:
2591         (WebCore::RenderLayerBacking::updateTransform):
2592         (WebCore::RenderLayerBacking::computeTransformOriginForPainting):
2593         * rendering/RenderLayerCompositor.cpp:
2594         (WebCore::RenderLayerCompositor::deviceScaleFactor):
2595
2596 2014-07-23  peavo@outlook.com  <peavo@outlook.com>
2597
2598         [WinCairo] Gstreamer rendering is not working.
2599         https://bugs.webkit.org/show_bug.cgi?id=135201
2600
2601         Reviewed by Alex Christensen.
2602
2603         WinCairo does not support accelerated rendering yet.
2604
2605         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
2606         (WebCore::MediaPlayerPrivateGStreamerBase::supportsAcceleratedRendering):
2607
2608 2014-07-23  Commit Queue  <commit-queue@webkit.org>
2609
2610         Unreviewed, rolling out r171455.
2611         https://bugs.webkit.org/show_bug.cgi?id=135209
2612
2613         completely broke selection highlight invalidation (Requested
2614         by thorton on #webkit).
2615
2616         Reverted changeset:
2617
2618         "REGRESSION (r169105): Crash in selection"
2619         https://bugs.webkit.org/show_bug.cgi?id=134303
2620         http://trac.webkit.org/changeset/171455
2621
2622 2014-07-23  Alex Christensen  <achristensen@webkit.org>
2623
2624         Compile window-inactive and fullscreen pseudoclasses in css selectors.
2625         https://bugs.webkit.org/show_bug.cgi?id=135200
2626
2627         Reviewed by Benjamin Poulain.
2628
2629         * css/SelectorChecker.cpp:
2630         (WebCore::SelectorChecker::checkOne):
2631         Removed the check of context.hasSelectionPseudo for a window-inactive pseudoclass.
2632         Moved logic to SelectorCheckerTestFunctions.h to share with the selector compiler.
2633         * css/SelectorCheckerTestFunctions.h:
2634         (WebCore::isWindowInactive):
2635         (WebCore::matchesFullScreenAnimatingFullScreenTransitionPseudoClass):
2636         (WebCore::matchesFullScreenAncestorPseudoClass):
2637         (WebCore::matchesFullScreenDocumentPseudoClass):
2638         Added from SelectorChecker.cpp.
2639         * cssjit/SelectorCompiler.cpp:
2640         (WebCore::SelectorCompiler::addPseudoClassType):
2641         Added unoptimized pseudoclass cases for window-inactive and fullscreen pseudoclasses.
2642         Explicitly listed uncompiled pseudoclasses for future work instead of using a default.
2643
2644 2014-07-23  Brent Fulgham  <bfulgham@apple.com>
2645
2646         [Win] Use NO_RETURN_DUE_TO_CRASH on Windows.
2647         https://bugs.webkit.org/show_bug.cgi?id=13519
2648
2649         Reviewed by Mark Lam.
2650
2651         * svg/SVGZoomAndPan.h: Add NO_RETURN_DUE_TO_CRASH to
2652         header so function declarations match implementation.
2653
2654 2014-07-23  Joseph Pecoraro  <pecoraro@apple.com>
2655
2656         JSDOMWindowShell leaks on pages with media elements
2657         https://bugs.webkit.org/show_bug.cgi?id=135178
2658
2659         Reviewed by Oliver Hunt.
2660
2661         The DOMWindowWorld for HTMLMediaElements with MEDIA_CONTROLS_SCRIPT
2662         was not getting cleared and removed.
2663
2664         * bindings/js/ScriptController.cpp:
2665         (WebCore::ScriptController::clearWindowShell):
2666         Iterate over a copy of the values. A sweep / garbage collection caused by
2667         any JSC allocation during iteration could trigger a mutation of the m_windowShells
2668         table that was being iterating. So instead iterate a list that won't mutate.
2669
2670         * html/HTMLMediaElement.cpp:
2671         (WebCore::HTMLMediaElement::~HTMLMediaElement):
2672         If we had an isolated world, release as much memory as possible.
2673
2674 2014-07-23  Bem Jones-Bey  <bjonesbe@adobe.com>
2675
2676         Ensure we compute the min and max height of replaced elements to 'none' or 0 when appropriate.
2677         https://bugs.webkit.org/show_bug.cgi?id=135181
2678
2679         Reviewed by David Hyatt.
2680
2681         If a replaced element has a percentage min or max height specified then that height value should
2682         compute to 'none' for max-height and 0 for min-height when its containing block
2683         does not have a height 'specified explicitly'.
2684
2685         This is based on a Blink patch by Robert Hogan.
2686
2687         Tests: css2.1/20110323/max-height-percentage-003.html
2688                fast/replaced/max-height-percentage-quirks.html
2689                fast/replaced/min-height-percentage-quirks.html
2690                fast/replaced/min-height-percentage.html
2691
2692         * rendering/RenderBox.cpp:
2693         (WebCore::RenderBox::logicalHeightComputesAsNone):
2694         (WebCore::RenderBox::computeReplacedLogicalHeightRespectingMinMaxHeight):
2695         * rendering/RenderBox.h:
2696
2697 2014-07-23  Bem Jones-Bey  <bjonesbe@adobe.com>
2698
2699         Remove CSS_EXCLUSIONS compile flag and leftover code
2700         https://bugs.webkit.org/show_bug.cgi?id=135175
2701
2702         Reviewed by Zoltan Horvath.
2703
2704         At this point, the CSS_EXCLUSIONS flag guards nothing but some useless
2705         stubs. This removes the flag and the useless code.
2706
2707         No new tests, just removing code.
2708
2709         * Configurations/FeatureDefines.xcconfig:
2710         * bindings/generic/RuntimeEnabledFeatures.cpp:
2711         (WebCore::RuntimeEnabledFeatures::RuntimeEnabledFeatures):
2712         * bindings/generic/RuntimeEnabledFeatures.h:
2713         (WebCore::RuntimeEnabledFeatures::setCSSExclusionsEnabled): Deleted.
2714         (WebCore::RuntimeEnabledFeatures::cssExclusionsEnabled): Deleted.
2715         * testing/InternalSettings.cpp:
2716         (WebCore::InternalSettings::Backup::Backup):
2717         (WebCore::InternalSettings::Backup::restoreTo):
2718         (WebCore::InternalSettings::setCSSExclusionsEnabled): Deleted.
2719         * testing/InternalSettings.h:
2720         * testing/InternalSettings.idl:
2721
2722 2014-07-23  Jer Noble  <jer.noble@apple.com>
2723
2724         [MSE][Mac] Support abort() in SourceBufferPrivateAVFObjC.
2725         https://bugs.webkit.org/show_bug.cgi?id=135163
2726
2727         Reviewed by Brent Fulgham.
2728
2729         Recreate the parser when asked to abort().
2730
2731         * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
2732         (WebCore::SourceBufferPrivateAVFObjC::abort):
2733
2734 2014-07-23  Myles C. Maxfield  <mmaxfield@apple.com>
2735
2736         Migrate accessibility/ to using nullptr instead of 0
2737         https://bugs.webkit.org/show_bug.cgi?id=135185
2738
2739         Reviewed by Simon Fraser.
2740
2741         No new tests because there is no behavior change.
2742
2743         * accessibility/AXObjectCache.cpp:
2744         (WebCore::AXObjectCache::focusedImageMapUIElement):
2745         (WebCore::AXObjectCache::focusedUIElementForPage):
2746         (WebCore::AXObjectCache::get):
2747         (WebCore::AXObjectCache::getOrCreate):
2748         (WebCore::AXObjectCache::rootObject):
2749         (WebCore::AXObjectCache::rootObjectForFrame):
2750         * accessibility/AXObjectCache.h:
2751         (WebCore::AXObjectCache::focusedUIElementForPage):
2752         (WebCore::AXObjectCache::get):
2753         (WebCore::AXObjectCache::getOrCreate):
2754         (WebCore::AXObjectCache::rootObject):
2755         (WebCore::AXObjectCache::rootObjectForFrame):
2756         (WebCore::AXObjectCache::rootAXEditableElement):
2757         * accessibility/AccessibilityARIAGridRow.cpp:
2758         (WebCore::AccessibilityARIAGridRow::disclosedByRow):
2759         * accessibility/AccessibilityImageMapLink.cpp:
2760         (WebCore::AccessibilityImageMapLink::AccessibilityImageMapLink):
2761         (WebCore::AccessibilityImageMapLink::parentObject):
2762         * accessibility/AccessibilityListBox.cpp:
2763         (WebCore::AccessibilityListBox::listBoxOptionAccessibilityObject):
2764         (WebCore::AccessibilityListBox::elementAccessibilityHitTest):
2765         * accessibility/AccessibilityListBoxOption.cpp:
2766         (WebCore::AccessibilityListBoxOption::AccessibilityListBoxOption):
2767         (WebCore::AccessibilityListBoxOption::parentObject):
2768         (WebCore::AccessibilityListBoxOption::listBoxOptionParentNode):
2769         * accessibility/AccessibilityMenuListPopup.cpp:
2770         (WebCore::AccessibilityMenuListPopup::menuListOptionAccessibilityObject):
2771         * accessibility/AccessibilityMockObject.cpp:
2772         (WebCore::AccessibilityMockObject::AccessibilityMockObject):
2773         * accessibility/AccessibilityMockObject.h:
2774         * accessibility/AccessibilityNodeObject.cpp:
2775         (WebCore::AccessibilityNodeObject::detach):
2776         (WebCore::AccessibilityNodeObject::firstChild):
2777         (WebCore::AccessibilityNodeObject::lastChild):
2778         (WebCore::AccessibilityNodeObject::previousSibling):
2779         (WebCore::AccessibilityNodeObject::nextSibling):
2780         (WebCore::AccessibilityNodeObject::parentObject):
2781         (WebCore::AccessibilityNodeObject::document):
2782         (WebCore::AccessibilityNodeObject::anchorElement):
2783         (WebCore::nativeActionElement):
2784         (WebCore::AccessibilityNodeObject::actionElement):
2785         (WebCore::AccessibilityNodeObject::mouseButtonListener):
2786         (WebCore::AccessibilityNodeObject::labelForElement):
2787         (WebCore::AccessibilityNodeObject::menuItemElementForMenu):
2788         (WebCore::AccessibilityNodeObject::menuButtonForMenu):
2789         * accessibility/AccessibilityObject.cpp:
2790         (WebCore::AccessibilityObject::AccessibilityObject):
2791         (WebCore::AccessibilityObject::detach):
2792         (WebCore::AccessibilityObject::firstAccessibleObjectFromNode):
2793         (WebCore::AccessibilityObject::findMatchingObjects):
2794         (WebCore::renderListItemContainerForNode):
2795         (WebCore::AccessibilityObject::accessibilityObjectForPosition):
2796         (WebCore::AccessibilityObject::document):
2797         (WebCore::AccessibilityObject::page):
2798         (WebCore::AccessibilityObject::documentFrameView):
2799         (WebCore::AccessibilityObject::anchorElementForNode):
2800         (WebCore::AccessibilityObject::headingElementForNode):
2801         (WebCore::AccessibilityObject::firstAnonymousBlockChild):
2802         (WebCore::AccessibilityObject::element):
2803         (WebCore::AccessibilityObject::focusedUIElement):
2804         (WebCore::AccessibilityObject::scrollToMakeVisibleWithSubFocus):
2805         * accessibility/AccessibilityObject.h:
2806         (WebCore::AccessibilityObject::node):
2807         (WebCore::AccessibilityObject::renderer):
2808         (WebCore::AccessibilityObject::selectedRadioButton):
2809         (WebCore::AccessibilityObject::selectedTabItem):
2810         (WebCore::AccessibilityObject::accessibilityHitTest):
2811         (WebCore::AccessibilityObject::firstChild):
2812         (WebCore::AccessibilityObject::lastChild):
2813         (WebCore::AccessibilityObject::previousSibling):
2814         (WebCore::AccessibilityObject::nextSibling):
2815         (WebCore::AccessibilityObject::parentObjectIfExists):
2816         (WebCore::AccessibilityObject::observableObject):
2817         (WebCore::AccessibilityObject::titleUIElement):
2818         (WebCore::AccessibilityObject::correspondingLabelForControlElement):
2819         (WebCore::AccessibilityObject::correspondingControlForLabelElement):
2820         (WebCore::AccessibilityObject::scrollBar):
2821         (WebCore::AccessibilityObject::anchorElement):
2822         (WebCore::AccessibilityObject::actionElement):
2823         (WebCore::AccessibilityObject::widget):
2824         (WebCore::AccessibilityObject::widgetForAttachmentView):
2825         (WebCore::AccessibilityObject::activeDescendant):
2826         (WebCore::AccessibilityObject::mathRadicandObject):
2827         (WebCore::AccessibilityObject::mathRootIndexObject):
2828         (WebCore::AccessibilityObject::mathUnderObject):
2829         (WebCore::AccessibilityObject::mathOverObject):
2830         (WebCore::AccessibilityObject::mathNumeratorObject):
2831         (WebCore::AccessibilityObject::mathDenominatorObject):
2832         (WebCore::AccessibilityObject::mathBaseObject):
2833         (WebCore::AccessibilityObject::mathSubscriptObject):
2834         (WebCore::AccessibilityObject::mathSuperscriptObject):
2835         (WebCore::AccessibilityObject::getScrollableAreaIfScrollable):
2836         * accessibility/AccessibilityProgressIndicator.cpp:
2837         (WebCore::AccessibilityProgressIndicator::progressElement):
2838         (WebCore::AccessibilityProgressIndicator::meterElement):
2839         * accessibility/AccessibilityRenderObject.cpp:
2840         (WebCore::AccessibilityRenderObject::detach):
2841         (WebCore::AccessibilityRenderObject::renderBoxModelObject):
2842         (WebCore::AccessibilityRenderObject::firstChild):
2843         (WebCore::AccessibilityRenderObject::lastChild):
2844         (WebCore::startOfContinuations):
2845         (WebCore::childBeforeConsideringContinuations):
2846         (WebCore::AccessibilityRenderObject::previousSibling):
2847         (WebCore::AccessibilityRenderObject::nextSibling):
2848         (WebCore::nextContinuation):
2849         (WebCore::AccessibilityRenderObject::renderParentObject):
2850         (WebCore::AccessibilityRenderObject::parentObject):
2851         (WebCore::AccessibilityRenderObject::anchorElement):
2852         (WebCore::AccessibilityRenderObject::textUnderElement):
2853         (WebCore::AccessibilityRenderObject::node):
2854         (WebCore::AccessibilityRenderObject::labelElementContainer):
2855         (WebCore::AccessibilityRenderObject::internalLinkElement):
2856         (WebCore::AccessibilityRenderObject::titleUIElement):
2857         (WebCore::AccessibilityRenderObject::setFocused):
2858         (WebCore::AccessibilityRenderObject::topRenderer):
2859         (WebCore::AccessibilityRenderObject::document):
2860         (WebCore::AccessibilityRenderObject::widget):
2861         (WebCore::AccessibilityRenderObject::accessibilityParentForImageMap):
2862         (WebCore::AccessibilityRenderObject::documentFrameView):
2863         (WebCore::AccessibilityRenderObject::widgetForAttachmentView):
2864         (WebCore::AccessibilityRenderObject::rootEditableElementForPosition):
2865         (WebCore::AccessibilityRenderObject::visiblePositionForPoint):
2866         (WebCore::AccessibilityRenderObject::accessibilityImageMapHitTest):
2867         (WebCore::AccessibilityRenderObject::remoteSVGElementHitTest):
2868         (WebCore::AccessibilityRenderObject::accessibilityHitTest):
2869         (WebCore::AccessibilityRenderObject::correspondingControlForLabelElement):
2870         (WebCore::AccessibilityRenderObject::correspondingLabelForControlElement):
2871         (WebCore::AccessibilityRenderObject::observableObject):
2872         (WebCore::AccessibilityRenderObject::inheritsPresentationalRole):
2873         (WebCore::AccessibilityRenderObject::detachRemoteSVGRoot):
2874         (WebCore::AccessibilityRenderObject::addHiddenChildren):
2875         (WebCore::AccessibilityRenderObject::setAccessibleName):
2876         (WebCore::AccessibilityRenderObject::getScrollableAreaIfScrollable):
2877         (WebCore::AccessibilityRenderObject::mathRadicandObject):
2878         (WebCore::AccessibilityRenderObject::mathRootIndexObject):
2879         (WebCore::AccessibilityRenderObject::mathNumeratorObject):
2880         (WebCore::AccessibilityRenderObject::mathDenominatorObject):
2881         (WebCore::AccessibilityRenderObject::mathUnderObject):
2882         (WebCore::AccessibilityRenderObject::mathOverObject):
2883         (WebCore::AccessibilityRenderObject::mathBaseObject):
2884         (WebCore::AccessibilityRenderObject::mathSubscriptObject):
2885         (WebCore::AccessibilityRenderObject::mathSuperscriptObject):
2886         * accessibility/AccessibilitySVGRoot.cpp:
2887         (WebCore::AccessibilitySVGRoot::AccessibilitySVGRoot):
2888         * accessibility/AccessibilityScrollView.cpp:
2889         (WebCore::AccessibilityScrollView::detach):
2890         (WebCore::AccessibilityScrollView::scrollBar):
2891         (WebCore::AccessibilityScrollView::updateScrollbars):
2892         (WebCore::AccessibilityScrollView::addChildScrollbar):
2893         (WebCore::AccessibilityScrollView::clearChildren):
2894         (WebCore::AccessibilityScrollView::webAreaObject):
2895         (WebCore::AccessibilityScrollView::accessibilityHitTest):
2896         (WebCore::AccessibilityScrollView::documentFrameView):
2897         (WebCore::AccessibilityScrollView::parentObject):
2898         (WebCore::AccessibilityScrollView::parentObjectIfExists):
2899         * accessibility/AccessibilityScrollbar.cpp:
2900         (WebCore::AccessibilityScrollbar::document):
2901         * accessibility/AccessibilitySpinButton.cpp:
2902         (WebCore::AccessibilitySpinButton::AccessibilitySpinButton):
2903         * accessibility/AccessibilityTable.cpp:
2904         (WebCore::AccessibilityTable::AccessibilityTable):
2905         (WebCore::AccessibilityTable::clearChildren):
2906         (WebCore::AccessibilityTable::cellForColumnAndRow):
2907         * accessibility/AccessibilityTableCell.cpp:
2908         (WebCore::AccessibilityTableCell::parentTable):
2909         (WebCore::AccessibilityTableCell::titleUIElement):
2910         * accessibility/AccessibilityTableColumn.cpp:
2911         (WebCore::AccessibilityTableColumn::headerObject):
2912         (WebCore::AccessibilityTableColumn::headerObjectForSection):
2913         * accessibility/AccessibilityTableRow.cpp:
2914         (WebCore::AccessibilityTableRow::parentTable):
2915         (WebCore::AccessibilityTableRow::headerObject):
2916         * accessibility/ios/AXObjectCacheIOS.mm:
2917         (WebCore::AXObjectCache::detachWrapper):
2918         * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
2919         (-[WebAccessibilityObjectWrapper detach]):
2920         (-[WebAccessibilityObjectWrapper tableCellParent]):
2921         (-[WebAccessibilityObjectWrapper tableParent]):
2922         (-[WebAccessibilityObjectWrapper convertPointToScreenSpace:]):
2923         (-[WebAccessibilityObjectWrapper convertRectToScreenSpace:]):
2924         (rendererForView):
2925         (-[WebAccessibilityObjectWrapper _convertToDOMRange:]):
2926         * accessibility/mac/AXObjectCacheMac.mm:
2927         (WebCore::AXObjectCache::detachWrapper):
2928         * accessibility/mac/AccessibilityObjectMac.mm:
2929         (WebCore::AccessibilityObject::detachFromParent):
2930         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
2931         * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
2932         (-[WebAccessibilityObjectWrapperBase detach]):
2933         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2934         (CreateCGColorIfDifferent):
2935         (-[WebAccessibilityObjectWrapper convertPointToScreenSpace:]):
2936         (rendererForView):
2937         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
2938         * accessibility/win/AccessibilityObjectWrapperWin.h:
2939         (WebCore::AccessibilityObjectWrapper::AccessibilityObjectWrapper):
2940
2941 2014-07-23  Mihnea Ovidenie  <mihnea@adobe.com>
2942
2943         ASSERTION FAILED: generatingElement() in WebCore::RenderNamedFlowFragment::regionOversetState
2944         https://bugs.webkit.org/show_bug.cgi?id=135153
2945
2946         Reviewed by David Hyatt.
2947
2948         Even though the CSSRegions spec defines the behaviour of a multicolumn region,
2949         we currently do not support this functionality. This patch ensures that a multicolumn
2950         element does not become a region. In the future, when we will implement the multicolumn
2951         as region functionality, http://dev.w3.org/csswg/css-regions/#multi-column-regions, we
2952         will remove this restriction.
2953
2954         Test: fast/regions/multicol-as-region-prevented.html
2955
2956         * rendering/RenderBlockFlow.cpp:
2957         (WebCore::RenderBlockFlow::createRenderNamedFlowFragmentIfNeeded):
2958
2959 2014-07-23  Zan Dobersek  <zdobersek@igalia.com>
2960
2961         [CMake] Avoid building WebCore with ANGLE's OpenGL/EGL headers
2962         https://bugs.webkit.org/show_bug.cgi?id=135167
2963
2964         Reviewed by Martin Robinson.
2965
2966         * CMakeLists.txt: Don't add ANGLE/include to the WebCore_INCLUDE_DIRECTORIES list
2967         as this results in ANGLE's OpenGL and EGL headers being included, instead of the
2968         headers that are provided by the system. Only the ANGLESupport library should be built
2969         with that specific header inclusion path.
2970
2971 2014-07-10  Radu Stavila  <stavila@adobe.com>
2972
2973         REGRESSION (r169105): Crash in selection
2974         https://bugs.webkit.org/show_bug.cgi?id=134303
2975
2976         Reviewed by David Hyatt.
2977
2978         When splitting the selection between different subtrees, all subtrees must have their selection cleared before
2979         starting to apply the new selection. Otherwise, when selecting objects in a named flow thread and going up
2980         its containing block chain, we can end up in the view's selection root, which has not yet been updated and so
2981         we get inconsistent data.
2982
2983         To achieve this goal, the selection update was split into a "clear" and an "apply" method. The updateSelectionForSubtrees
2984         method first iterates through all subtrees and performs the "clear" method and then starts all over again
2985         and performs the "apply" method.
2986
2987         Also, the selectionStart/End members in RenderView have been renamed to fix problems caused by the fact that
2988         RenderView inherits SelectionSubtreeRoot, which also has the same selectionStart/End members.
2989
2990         Test: fast/regions/selection/crash-deselect.html
2991
2992         * WebCore.xcodeproj/project.pbxproj:
2993         * rendering/RenderBlock.cpp:
2994         (WebCore::RenderBlock::isSelectionRoot):
2995         * rendering/RenderSelectionInfo.h:
2996         * rendering/RenderView.cpp:
2997         (WebCore::RenderView::RenderView):
2998         (WebCore::RenderView::setSelection): Renamed m_selectionStart/End to m_unsplitSelectionStart/End
2999         (WebCore::RenderView::splitSelectionBetweenSubtrees):
3000         (WebCore::RenderView::updateSelectionForSubtrees): Added, clears and re-applies selection for all selection subtrees.
3001         (WebCore::RenderView::clearSubtreeSelection): Added, clears selection and returns previously selected information.
3002         (WebCore::RenderView::applySubtreeSelection): Added, updates the selection status of all objects inside the selection tree, compares old and new data and repaints accordingly.
3003         (WebCore::RenderView::getSelection): Renamed m_selectionStart/End to m_unsplitSelectionStart/End
3004         (WebCore::RenderView::setSubtreeSelection): Deleted.
3005         * rendering/RenderView.h:
3006         * rendering/SelectionSubtreeRoot.cpp:
3007         (WebCore::SelectionSubtreeRoot::SelectionSubtreeRoot):
3008         * rendering/SelectionSubtreeRoot.h:
3009         (WebCore::SelectionSubtreeRoot::OldSelectionData::OldSelectionData):
3010
3011 2014-07-22  Brent Fulgham  <bfulgham@apple.com>
3012
3013         [Win] Build fix for bot.
3014
3015         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3016         (WebCore::createLegibleOutputSubtypes): Declare 'wvtt' locally, rather
3017         than relying on potentially unavailable declaration.
3018
3019 2014-07-22  Brent Fulgham  <bfulgham@apple.com>
3020
3021         [Win] Build fix for Windows bots
3022
3023         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp: Provide missing
3024         structure definition when needed by bot.
3025
3026 2014-07-22  Brent Fulgham  <bfulgham@apple.com>
3027
3028         [Win] Build fix for EWS bots.
3029
3030         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp: Forward declare
3031         structure definition.
3032
3033 2014-07-22  Brent Fulgham  <bfulgham@apple.com>
3034
3035         [Win] Fix Crash when handling Legible Output callbacks
3036         https://bugs.webkit.org/show_bug.cgi?id=134946
3037
3038         Reviewed by Dean Jackson.
3039
3040         Relanding after adding fixes to support build bots.
3041
3042         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
3043         (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): Remove
3044         Windows-specific 'ASSERT_NOT_REACHED' code path.
3045         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3046         (WebCore::createLegibleOutputSubtypes): Added.
3047         (WebCore::AVFWrapper::createPlayerItem): Updated to request native
3048         samples from AVFoundationCF.
3049
3050 2014-07-16  Myles C. Maxfield  <mmaxfield@apple.com>
3051
3052         Copying and pasting trivial H2 content causes a crash in firstPositionInNode
3053         https://bugs.webkit.org/show_bug.cgi?id=134897
3054
3055         Reviewed by Ryosuke Niwa.
3056
3057         ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder() attempts
3058         to move pasted headings out of existed headings, with out regard to if the existing
3059         heading is the contenteditable root.
3060
3061         Test: editing/pasteboard/heading-crash.html
3062
3063         * editing/ReplaceSelectionCommand.cpp:
3064         (WebCore::ReplaceSelectionCommand::makeInsertedContentRoundTrippableWithHTMLTreeBuilder):
3065
3066 2014-07-22  Ryuan Choi  <ryuan.choi@samsung.com>
3067
3068         Remove dead APIs from TiledBackingStore
3069         https://bugs.webkit.org/show_bug.cgi?id=135158
3070
3071         Reviewed by Gyuyoung Kim.
3072
3073         setContentsFrozen and related code of TiledBackingStore are not used since Qt port is removed.
3074
3075         * platform/graphics/TiledBackingStore.cpp:
3076         (WebCore::TiledBackingStore::TiledBackingStore):
3077         (WebCore::TiledBackingStore::updateTileBuffers):
3078         (WebCore::TiledBackingStore::setContentsScale):
3079         (WebCore::TiledBackingStore::createTiles):
3080         (WebCore::TiledBackingStore::startTileBufferUpdateTimer):
3081         (WebCore::TiledBackingStore::startBackingStoreUpdateTimer):
3082         (WebCore::TiledBackingStore::commitScaleChange): Deleted.
3083         (WebCore::TiledBackingStore::isBackingStoreUpdatesSuspended): Deleted.
3084         (WebCore::TiledBackingStore::isTileBufferUpdatesSuspended): Deleted.
3085         (WebCore::TiledBackingStore::setContentsFrozen): Deleted.
3086         * platform/graphics/TiledBackingStore.h:
3087         (WebCore::TiledBackingStore::contentsFrozen): Deleted.
3088
3089 2014-07-22  Alex Christensen  <achristensen@webkit.org>
3090
3091         Fix window-inactive css selectors when using querySelector.
3092         https://bugs.webkit.org/show_bug.cgi?id=135149
3093
3094         Reviewed by Tim Horton.
3095
3096         Test: fast/selectors/querySelector-window-inactive.html
3097
3098         * css/SelectorChecker.cpp:
3099         (WebCore::SelectorChecker::checkOne):
3100         Removed default and implemented case PseudoClassWindowInactive.
3101
3102 2014-07-22  Tim Horton  <timothy_horton@apple.com>
3103
3104         REGRESSION (r171016): Reproducible infinite spin selecting phone number
3105         https://bugs.webkit.org/show_bug.cgi?id=135183
3106         <rdar://problem/17727342>
3107
3108         Reviewed by Ryosuke Niwa.
3109
3110         * editing/Editor.cpp:
3111         (WebCore::Editor::scanRangeForTelephoneNumbers):
3112         Make use of TextIterator::subrange, which knows how to make a subrange from character positions,
3113         instead of assuming that our character positions translate directly to positions in the incoming range.
3114         Make use of DocumentMarkerController::addMarker, which takes a range and applies the marker to
3115         all text nodes inside the range as appropriate.
3116         Fix naming of the shadowed 'length' local.
3117         Fix a typo in the comment.
3118
3119 2014-07-22  Myles C. Maxfield  <mmaxfield@apple.com>
3120
3121         [iOS] [OSX] Don't transcode WOFF on platforms that support it natively
3122         https://bugs.webkit.org/show_bug.cgi?id=134904
3123
3124         Reviewed by Andreas Kling.
3125
3126         No new tests because there is no behavior change.
3127
3128         * loader/cache/CachedFont.cpp:
3129         (WebCore::CachedFont::ensureCustomFontData):
3130
3131 2014-07-22  peavo@outlook.com  <peavo@outlook.com>
3132
3133         [Win] Crash after plugin is unloaded.
3134         https://bugs.webkit.org/show_bug.cgi?id=119044
3135
3136         Reviewed by Darin Adler.
3137
3138         We need to invalidate all runtime objects when a plugin view is destroyed, in case the plugin is unloaded,
3139         and one of these runtime objects accesses the plugin function table upon destruction afterwards, which will cause a crash.
3140         If we use the weak pointer to the runtime object when invalidating, it will be null if it's in the WeakImpl::Dead state.
3141         This means the runtime object will not be invalidated, possibly causing a crash if the plugin is unloaded.
3142         It should be safe to use the raw pointer to the runtime object when invalidating, since finalized runtime objects
3143         will be removed from the set of runtime objects in the method RootObject::finalize().
3144
3145         * bridge/runtime_root.cpp:
3146         (JSC::Bindings::RootObject::invalidate): Make sure all runtime objects are invalidated by getting the raw runtime object pointer from the hash key.
3147
3148 2014-07-22  Enrica Casucci  <enrica@apple.com>
3149
3150         REGRESSION (WebKit2): Selection inside accelerated overflow:scroll doesn't track scrolling.
3151         https://bugs.webkit.org/show_bug.cgi?id=135180
3152         <rdar://problem/16721055>
3153
3154         Reviewed by Simon Fraser.
3155
3156         AsyncScrollingCoordinator will force a selection update on iOS
3157         when scrolling terminates in an overflow scroll.
3158
3159         * loader/EmptyClients.h:
3160         * page/EditorClient.h:
3161         * page/scrolling/AsyncScrollingCoordinator.cpp:
3162         (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
3163         * page/scrolling/ScrollingTree.h:
3164         (WebCore::ScrollingTree::scrollingTreeNodeWillStartScroll):
3165         (WebCore::ScrollingTree::scrollingTreeNodeDidEndScroll):
3166
3167 2014-07-22  Myles C. Maxfield  <mmaxfield@apple.com>
3168
3169         [Mac] Cocoa throws exception when the return type of NSAccessibilityLinkedUIElementsAttribute is not an array
3170         https://bugs.webkit.org/show_bug.cgi?id=135165
3171
3172         Reviewed by Simon Fraser.
3173
3174         Return an empty array instead of nil.
3175
3176         Updated tests.
3177
3178         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
3179         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
3180
3181 2014-07-22  Commit Queue  <commit-queue@webkit.org>
3182
3183         Unreviewed, rolling out r171357.
3184         https://bugs.webkit.org/show_bug.cgi?id=135173
3185
3186         broke Windows build. (Requested by bfulgham on #webkit).
3187
3188         Reverted changeset:
3189
3190         "[Win] Fix Crash when handling Legible Output callbacks"
3191         https://bugs.webkit.org/show_bug.cgi?id=134946
3192         http://trac.webkit.org/changeset/171357
3193
3194 2014-07-22  Brent Fulgham  <bfulgham@apple.com>
3195
3196         [Win] Fix Crash when handling Legible Output callbacks
3197         https://bugs.webkit.org/show_bug.cgi?id=134946
3198
3199         Reviewed by Dean Jackson.
3200
3201         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
3202         (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): Remove
3203         Windows-specific 'ASSERT_NOT_REACHED' code path.
3204         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3205         (WebCore::createLegibleOutputSubtypes): Added.
3206         (WebCore::AVFWrapper::createPlayerItem): Updated to request native
3207         samples from AVFoundationCF.
3208
3209 2014-07-21  Sam Weinig  <sam@webkit.org>
3210
3211         [Cocoa] WKScriptMessageHandlers don't seem to function properly after navigating
3212         https://bugs.webkit.org/show_bug.cgi?id=135148
3213
3214         Reviewed by Geoffrey Garen.
3215
3216         The "webkit" property on the window was not getting installed for subsequent
3217         loads due to intricate dance playing setting the JSDOMWindow where the DOMWindow
3218         object is not yet in a Frame when the JSDOMWindow is created. Since we were
3219         adding the "webkit" property on construction, the property was returning null
3220         thinking it had no Frame and was in a bad state. We can fix this by making the
3221         "webkit" property behave like all the other window properties moving its getting
3222         to JSDOMWindow::getOwnPropertySlot.
3223
3224         Added API test (WebKit2Cocoa/UserContentController).
3225
3226         * bindings/js/JSDOMWindowBase.cpp:
3227         (WebCore::JSDOMWindowBase::finishCreation):
3228         * bindings/js/JSDOMWindowCustom.cpp:
3229         (WebCore::jsDOMWindowWebKit):
3230         (WebCore::JSDOMWindow::getOwnPropertySlot):
3231
3232 2014-07-22  Brent Fulgham  <bfulgham@apple.com>
3233
3234         [Win] Fix Leak in WebCore::createGlobalImageFileDescriptor 
3235         https://bugs.webkit.org/show_bug.cgi?id=134423
3236         <rdar://problem/17492758>
3237
3238         Reviewed by Geoffrey Garen.
3239
3240         * platform/win/PasteboardWin.cpp:
3241         (WebCore::createGlobalImageFileDescriptor): Unlock and release the
3242         HGLOBAL when exiting early.
3243
3244 2014-07-21  Myles C. Maxfield  <mmaxfield@apple.com>
3245
3246         Clicking on links while accessibility is enabled sometimes crashes
3247         https://bugs.webkit.org/show_bug.cgi?id=135074
3248
3249         Reviewed by Chris Fleizach.
3250
3251         When an accessibility request comes in from the system, we call updateBackingStore() on the
3252         relevant AccessibilityObject, which triggers a relayout of the entire document. This relayout
3253         might delete that accessibility node and its parent, which would cause the node to be deleted.
3254         After the stack unwinds, we then call a member function on the node without checking for this
3255         condition.
3256
3257         Test: accessibility/parent-delete.html
3258
3259         * accessibility/AccessibilityObject.cpp:
3260         (WebCore::AccessibilityObject::updateBackingStore): Retain the node for the duration of the
3261         function.
3262
3263 2014-07-22  Jeremy Jones  <jeremyj@apple.com>
3264
3265         Don't create new UIWindow for video fullscreen.
3266         https://bugs.webkit.org/show_bug.cgi?id=135038
3267
3268         Reviewed by Darin Adler.
3269
3270         * WebCore.exp.in:
3271         * platform/ios/WebVideoFullscreenControllerAVKit.h: use UIView instead of UIScreen.
3272         * platform/ios/WebVideoFullscreenControllerAVKit.mm:
3273         (-[WebVideoFullscreenController enterFullscreen:]): provide parent UIView.
3274         * platform/ios/WebVideoFullscreenInterfaceAVKit.h: remove UIWindow.
3275         * platform/ios/WebVideoFullscreenInterfaceAVKit.mm: 
3276         (WebVideoFullscreenInterfaceAVKit::setupFullscreen): ditto 
3277         (WebVideoFullscreenInterfaceAVKit::cleanupFullscreen): ditto
3278         (WebVideoFullscreenInterfaceAVKit::invalidate): ditto
3279         (WebVideoFullscreenInterfaceAVKit::requestHideAndExitFullscreen): ditto
3280
3281 2014-07-22  Carlos Alberto Lopez Perez  <clopez@igalia.com>
3282
3283         [GTK] Rollout r170529 due to ~10% performance regression on the
3284         perf test Animation/balls.
3285         https://bugs.webkit.org/show_bug.cgi?id=134972
3286
3287         Reviewed by Martin Robinson.
3288
3289         Reverted changeset:
3290         "Increase priority on SharedTimer source."
3291         https://trac.webkit.org/r170529
3292
3293 2014-07-18  Dirk Schulze  <krit@webkit.org>
3294
3295         Turn width/height to presentation attributes
3296         https://bugs.webkit.org/show_bug.cgi?id=135046
3297
3298         Reviewed by Dean Jackson.
3299
3300         The elements <svg>, <image>, <pattern>, <mask> and <foreignObject> have the
3301         'width' and 'height' attributes. So far they can just be set by SVG DOM or
3302         setAttribute. Furthermore, animations just work with SVG Animation - No support
3303         for CSS Animations and CSS Transitions. We started to turn the width and height
3304         attributes on SVG roots to presentation attributes already. A presentation
3305         attribute is a CSS property that can also be set by DOM (or now by SVG DOM).
3306
3307         This patch turns all width and height attributes to presentation attributes. It
3308         basically allows authors to style width and height with CSS as well. Width and
3309         height can now be set with CSS style sheets and can be animated with CSS.
3310
3311         To some degree it made it possible to remove code duplication. However, since
3312         SVG DOM requires us to use SVGLength types and since we did not turn all
3313         SVG attributes to the CSS length values (and our internal Length struct) yet,
3314         we still need a hybrid - a bridge between SVGLength (for SVG DOM) and Length (for
3315         RenderStyle). Once we move all attributes to use the Length struct, we can make SVGLength
3316         a wrapper for Length and can move more code to the render tree.
3317
3318         The current challenge is to synchronize SVG DOM, normal DOM and RenderStyle.
3319         With this patch we handle most part in RenderStyle. SVG DOM changes are
3320         synchronized to DOM and RenderStyle will call needsStyleRecalc. Furthermore,
3321         SVG Animations will continue to animate the SVG DOM (and synchronize the changes
3322         back to RenderStyle) if the element has a JS property for the currently animated
3323         attribute.
3324
3325         Short example:
3326
3327             <rect>
3328                 <animate attributeName="width">
3329             </rect>
3330
3331         The <rect> element has the SVG DOM property 'width'. Therefore, we animate the SVG DOM
3332         property and synchronize RenderStyle.
3333
3334             <ellipse>
3335                 <animate attributeName="width">
3336             </ellipse>
3337
3338         The <ellipse> element does NOT have the SVG DOM property 'width'. Therefore, we
3339         animate the CSS property directly. With synchronizing RenderStyle in all cases, we
3340         make sure that the CSS cascade works even on animating on multiple SVG hierarchy
3341         levels (animation of 'width' on <g> and inheriting the property value on a child
3342         <rect>).
3343
3344         With using presentation attributes, we also inherit the CSS property parsing for
3345         SVG attributes. <rect width="  100px  "> is possible now. (Note the trailing whitespaces.)
3346         This follows a recent resolution of the SVG WG.
3347
3348         Since we turned width and height to presentation attributes, the layout optimization
3349         selfHasRelativeLengths() in the DOM can't be used anymore. selfHasRelativeLengths() was
3350         intended to solve a problem where we did not layout relatively position/sized elements
3351         when the parent changes its size. However, as a side effect it did not call layout
3352         for absolutely positioned/sized elements since the layout does not change. I run
3353         all performance tests that we have and even wrote a test with hundreds of elements
3354         that would be affected by this optimization. The differences were inside the sigma
3355         of a normal test run. (Means I couldn't measure a performance difference.)
3356         Therefore, it is not worth it to keep the "optimization" around and I will probably
3357         remove it entirely for all basic shapes but <path> and <polygon> in future patches.
3358
3359         Tests: svg/css/parse-height.html
3360                svg/css/parse-width.html
3361                svg/css/width-height-presentation-attribute-expected.svg
3362                svg/css/width-height-presentation-attribute.svg
3363
3364         * css/CSSComputedStyleDeclaration.cpp:
3365         (WebCore::ComputedStyleExtractor::propertyValue): We never calculated the computed
3366             value of width/height for SVG elements and returned auto instead. This is based
3367             on a rule of CSS 2 and needs to be fixed in CSS3.
3368         * css/DeprecatedStyleBuilder.cpp:
3369         (WebCore::ApplyPropertyLength::applyValue): Length always incorporates the zoom level.
3370             In SVG we still apply the zoom after all operations by scaling the context. We need
3371             to take this in account for Length and don't apply zoom on SVG inline elements.
3372         * css/StyleResolver.cpp:
3373         (WebCore::StyleResolver::useSVGZoomRulesForLength):
3374             See above.
3375         * css/StyleResolver.h:
3376         * rendering/svg/RenderSVGRect.cpp:
3377         (WebCore::RenderSVGRect::updateShapeFromElement): Do not call width() and height() on
3378             SVG DOM but use the values of RenderStyle instead.
3379         * rendering/svg/SVGPathData.cpp:
3380         (WebCore::updatePathFromRectElement): Ditto.
3381         * svg/SVGAnimateElement.cpp:
3382         (WebCore::SVGAnimateElement::resetAnimatedType): We need to differ between CSS properties
3383             with and without SVG DOM on the current element. In the later case we animate the 
3384             SVG DOM and need to synch RenderStyle.
3385         (WebCore::SVGAnimateElement::clearAnimatedType): Ditto.
3386         (WebCore::SVGAnimateElement::applyResultsToTarget): Ditto.
3387         * svg/SVGAnimationElement.cpp:
3388         (WebCore::SVGAnimationElement::isTargetAttributeCSSProperty): This checks if the CSS property
3389             has to be synched with SVG DOM.
3390         (WebCore::SVGAnimationElement::shouldApplyAnimation): Ditto.
3391         * svg/SVGAnimationElement.h:
3392         * svg/SVGElement.cpp:
3393         (WebCore::populateAttributeNameToCSSPropertyIDMap): Add width and heigth to the CSS property
3394             list for presentation attributes.
3395         (WebCore::populateCSSPropertyWithSVGDOMNameToAnimatedPropertyTypeMap): CSS properties with
3396             SVG DOM synchronization need to be treated differently. Collect them in a separate map.
3397         (WebCore::cssPropertyWithSVGDOMNameToAnimatedPropertyTypeMap): Caller for the map.
3398         (WebCore::SVGElement::animatedPropertyTypeForAttribute): We need to check both maps here:
3399             CSS properties and CSS properties with SVG DOM synch.
3400         (WebCore::SVGElement::isAnimatableCSSProperty): Ditto.
3401         (WebCore::SVGElement::isPresentationAttributeWithSVGDOM): Just return true if the property name
3402             is in the map of properties with SVG DOM for the current element.
3403         * svg/SVGElement.h:
3404         (WebCore::SVGElement::invalidateSVGPresentationAttributeStyle): Call needsStyleRecalc.
3405         * svg/SVGFilterElement.cpp: Make width/height presentation attribute.
3406         (WebCore::SVGFilterElement::svgAttributeChanged):
3407         (WebCore::SVGFilterElement::selfHasRelativeLengths): Deleted.
3408         * svg/SVGFilterElement.h: Ditto.
3409         * svg/SVGForeignObjectElement.cpp:
3410         (WebCore::SVGForeignObjectElement::svgAttributeChanged):
3411         (WebCore::SVGForeignObjectElement::selfHasRelativeLengths): Deleted.
3412         * svg/SVGForeignObjectElement.h:
3413         * svg/SVGImageElement.cpp: Ditto.
3414         (WebCore::SVGImageElement::svgAttributeChanged):
3415         (WebCore::SVGImageElement::isPresentationAttribute): Deleted.
3416         (WebCore::SVGImageElement::collectStyleForPresentationAttribute): Deleted.
3417         (WebCore::SVGImageElement::selfHasRelativeLengths): Deleted.
3418         * svg/SVGImageElement.h:
3419         * svg/SVGLength.h: Transform an Length value to an absolute value by taking the SVG viewport
3420             into account. (An SVG viewport is not the same as the CSS viewport.)
3421         * svg/SVGLengthContext.cpp: Ditto.
3422         (WebCore::SVGLengthContext::valueForLength):
3423         * svg/SVGLengthContext.h: