1 2014-05-20 Beth Dakin <bdakin@apple.com>
3 REGRESSION: All non-mainframe scrollbars don't paint after r169065
4 https://bugs.webkit.org/show_bug.cgi?id=133132
6 <rdar://problem/16968850>
8 Reviewed by Geoff Garen.
10 We should not universally return true here. This feature will only work for
11 scrollbars with layers.
12 * platform/ScrollableArea.h:
13 * platform/Scrollbar.cpp:
14 (WebCore::Scrollbar::supportsUpdateOnSecondaryThread):
16 2014-05-20 Daniel Bates <dabates@apple.com>
18 Element within flattened frame may update its scroll state during the layout phase of the wrong RenderView
19 https://bugs.webkit.org/show_bug.cgi?id=133013
20 <rdar://problem/16760154>
22 Reviewed by David Hyatt.
24 Fixes an issue where the scroll state of an element may be updated during the layout of the wrong
25 RenderView. In particular, the scroll state of an element inside a CSS flex box in a flattened
26 frame f is updated during the layout of the RenderView associated with the parent frame of f instead
27 of during the layout of the RenderView associated with f.
29 The layout machinery assumes that the scroll state of each scrollable element is updated before the
30 completion of layout for its associated RenderView. Currently we have logic to defer updating the scroll
31 state of a scrollable element until completion of recursive layout. For a page with a flattened frame, we
32 defer such updates until completion of layout for all RenderViews along the ancestor frame hierarchy of
33 each flattened frame regardless of the RenderView associated with the element that originated the
34 deferred scroll state request. Instead, only the RenderView associated with the element that deferred its
35 scroll state update should dispatch the scroll state update.
37 Tests: fast/frames/flattening/scrollable-flexbox-inside-iframe-with-zero-height-and-needs-full-repaint-crash.html
38 fast/frames/flattening/scrollable-flexbox-inside-iframe-with-zero-height-assertion-failure.html
40 * rendering/RenderBlock.cpp: Removed WTF::-prefix in typedef definition for ContinuationOutlineTableMap.
41 (WebCore::UpdateScrollInfoAfterLayoutTransaction::UpdateScrollInfoAfterLayoutTransaction): Added; a struct
42 that represents a RenderView v, nested transaction count, and a list of RenderBlocks in v that will need
43 to have their scroll state updated.
44 (WebCore::updateScrollInfoAfterLayoutTransactionStack): Added; returns the global stack of transactions.
45 (WebCore::RenderBlock::willBeDestroyed): Call removeFromUpdateScrollInfoAfterLayoutTransaction(), which
46 was formerly named as removeFromDelayedUpdateScrollInfoSet.
47 (WebCore::currentUpdateScrollInfoAfterLayoutTransaction): Added; returns the top-most transaction in the
49 (WebCore::RenderBlock::beginUpdateScrollInfoAfterLayoutTransaction): Modified as appropriate to make use
50 of the global stack of transactions; formerly named startDelayUpdateScrollInfo.
51 (WebCore::RenderBlock::endAndCommitUpdateScrollInfoAfterLayoutTransaction): Modified as appropriate to
52 make use of the global stack of transactions; formerly named finishDelayUpdateScrollInfo.
53 (WebCore::RenderBlock::removeFromUpdateScrollInfoAfterLayoutTransaction): Modified as appropriate to make
54 use of the global stack of transactions; formerly named removeFromDelayedUpdateScrollInfoSet.
55 (WebCore::RenderBlock::updateScrollInfoAfterLayout): Modified as appropriate to make use of the global
56 stack of transactions.
57 (WebCore::RenderBlock::layout): Ditto.
58 (WebCore::RenderBlock::startDelayUpdateScrollInfo): Deleted.
59 (WebCore::RenderBlock::finishDelayUpdateScrollInfo): Deleted.
60 (WebCore::RenderBlock::removeFromDelayedUpdateScrollInfoSet): Deleted.
61 * rendering/RenderBlock.h:
62 * rendering/RenderBlockFlow.cpp:
63 (WebCore::RenderBlockFlow::willBeDestroyed): Call removeFromUpdateScrollInfoAfterLayoutTransaction(), which
64 was formerly named removeFromDelayedUpdateScrollInfoSet.
65 * rendering/RenderDeprecatedFlexibleBox.cpp:
66 (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox): Call {begin, end}UpdateScrollInfoAfterLayoutTransaction(),
67 which was formerly named {start, end}DelayUpdateScrollInfo.
68 (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox): Ditto.
69 * rendering/RenderFlexibleBox.cpp:
70 (WebCore::RenderFlexibleBox::layoutBlock): Ditto.
72 2014-05-20 Beth Dakin <bdakin@apple.com>
74 REGRESSION (r169065): Mountain Lion run-api-tests failures: ASSERTION FAILED:
75 Uncaught exception - -[NSRegularLegacyScrollerImp setPresentationValue:]:
76 unrecognized selector sent to instance 0x7ff51aa38000
77 https://bugs.webkit.org/show_bug.cgi?id=133121
79 Reviewed by Tim Horton.
81 * platform/mac/ScrollbarThemeMac.mm:
82 (WebCore::ScrollbarThemeMac::setPaintCharacteristicsForScrollbar):
84 2014-05-19 Simon Fraser <simon.fraser@apple.com>
86 REGRESSION (r169063) Fixed and sticky nodes misplaced on scrolling sometimes
87 https://bugs.webkit.org/show_bug.cgi?id=133106
88 <rdar://problem/16967648>
90 Reviewed by Sam Weinig.
92 Fix regression from r169063. That commit removed scrolledContentsLayers from
93 frame scrolling nodes, but they do actually use them.
95 So put them back; not in the base class, because they have a somewhat different
96 meaning for overflow scrolling and frame scrolling.
99 * page/scrolling/AsyncScrollingCoordinator.cpp:
100 (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
101 (WebCore::AsyncScrollingCoordinator::updateFrameScrollingNode):
102 * page/scrolling/AsyncScrollingCoordinator.h:
103 * page/scrolling/ScrollingCoordinator.h:
104 (WebCore::ScrollingCoordinator::updateFrameScrollingNode):
105 * page/scrolling/ScrollingStateFrameScrollingNode.cpp:
106 (WebCore::ScrollingStateFrameScrollingNode::ScrollingStateFrameScrollingNode):
107 (WebCore::ScrollingStateFrameScrollingNode::setScrolledContentsLayer):
108 * page/scrolling/ScrollingStateFrameScrollingNode.h:
109 * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
110 (WebCore::ScrollingTreeFrameScrollingNodeMac::updateBeforeChildren):
111 * rendering/RenderLayerCompositor.cpp:
112 (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
114 2014-05-20 Radu Stavila <stavila@adobe.com>
116 REGRESSION: [CSS Regions] Content flowed directly into the flow thread that ends up in the second region is not properly repainted
117 https://bugs.webkit.org/show_bug.cgi?id=133111
119 Reviewed by David Hyatt.
121 When computing the repaint rect of an element flowed into a flow thread, if the element is flowed directly into
122 the flow thread (meaning its containing block is the flow thread itself), the region's position within the flow
123 must no longer be taken into consideration, because its already included in the element's |topLeft|.
125 Test: fast/regions/hover-element-flowed-second-region.html
127 * rendering/RenderBox.cpp:
128 (WebCore::RenderBox::computeRectForRepaint):
130 2014-05-20 Alex Christensen <achristensen@webkit.org>
132 Fix web timing assertion failure.
133 https://bugs.webkit.org/show_bug.cgi?id=133094
134 <rdar://problem/16966032>
136 Reviewed by Alexey Proskuryakov.
138 * platform/network/mac/ResourceHandleMac.mm:
139 (WebCore::ResourceHandle::getConnectionTimingData):
140 Set requestStart and responseStart to 0 instead of -1 to match the
141 ResourceLoadTiming constructor and prevent the assertion failure in
142 PerformanceTiming::responseStart.
144 2014-05-20 Prashant Hiremath <hiremathprashants@gmail.com>
146 Only set title on SVG documents
147 https://bugs.webkit.org/show_bug.cgi?id=133068
149 Reviewed by Dirk Schulze.
151 Test: svg/custom/html_document_set_title.html
153 * svg/SVGTitleElement.cpp:
154 (WebCore::SVGTitleElement::insertedInto):
155 (WebCore::SVGTitleElement::removedFrom):
156 (WebCore::SVGTitleElement::childrenChanged):
158 2014-05-20 peavo@outlook.com <peavo@outlook.com>
160 [Curl] Invalid content in cache file, causes broken rendering.
161 https://bugs.webkit.org/show_bug.cgi?id=133069
163 Reviewed by Brent Fulgham.
165 When data for a url is received as multiple parts, the cache file for the url is truncated when opened for writing,
166 and will only contain the last part of data received.
167 This is fixed by only opening the file once, and close it after all data has been received.
169 * platform/network/curl/CurlCacheEntry.cpp:
170 (WebCore::CurlCacheEntry::CurlCacheEntry): Initialize cache file handle member.
171 (WebCore::CurlCacheEntry::~CurlCacheEntry): Close cache file.
172 (WebCore::CurlCacheEntry::saveCachedData): Only open cache file once to avoid truncating.
173 (WebCore::CurlCacheEntry::didFail): Close cache file.
174 (WebCore::CurlCacheEntry::didFinishLoading): Ditto.
175 (WebCore::CurlCacheEntry::openContentFile): Added method to open cache file.
176 (WebCore::CurlCacheEntry::closeContentFile): Added method to close cache file.
177 * platform/network/curl/CurlCacheEntry.h: Added file handle member, and methods to open and close cache file.
179 2014-05-20 Radu Stavila <stavila@adobe.com>
181 [CSS Regions] Block incorrectly sized when containing an unsplittable box
182 https://bugs.webkit.org/show_bug.cgi?id=132601
184 Reviewed by Antti Koivisto.
186 When laying out elements in a region, when an inline element is encountered
187 the size of its parent must not be increased beyond the bottom of the current region,
188 unless if its the last region. This will ensure that the next sibling of the
189 inline element is correctly laid out at the top of the next region, instead
190 of leaving an empty space equal to the height of the overflow, as it did until now.
192 Tests: fast/regions/inline-block-inside-anonymous-overflow.html
193 fast/regions/inline-block-overflow.html
195 * rendering/RenderBlockFlow.cpp:
196 (WebCore::RenderBlockFlow::adjustLinePositionForPagination):
197 (WebCore::RenderBlockFlow::hasNextPage):
198 * rendering/RenderBlockFlow.h:
199 * rendering/RenderBlockLineLayout.cpp:
200 (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
201 (WebCore::RenderBlockFlow::linkToEndLineIfNeeded):
202 (WebCore::RenderBlockFlow::determineStartPosition):
203 (WebCore::RenderBlockFlow::checkPaginationAndFloatsAtEndLine):
205 2014-05-20 Mihnea Ovidenie <mihnea@adobe.com>
207 [CSS Regions] Crash while painting block selection gaps in regions
208 https://bugs.webkit.org/show_bug.cgi?id=132720
210 Reviewed by David Hyatt.
212 The fix for WebKit bug https://bugs.webkit.org/show_bug.cgi?id=131511
213 allowed selection highlight to match the DOM selection when the start
214 and end point of the selection were in different flow threads. In order
215 to enable that, the selection was performed separately on view and
216 render flow threads, considered selection subtrees.
218 However, the start and end points for each selection subtree were computed
219 by means of Range class but it is not always possible to construct a valid
220 Range from two pairs of RenderObjects and offsets.
222 This patch keeps the substrees approach but instead of storing the endpoints
223 for each subtree in a Range and continuously extending the Range, it stores them
224 using the already available SelectionSubtreeRoot class. After the end points are
225 computed for each subtree and before processing the subtree selection, the end points
226 are adjusted in a similar fashion as the one used in FrameSelection::updateAppearance(),
227 to make sure we are passing the same expected information to the method implementing
228 the visible selection processing.
230 Test: fast/regions/selection-gaps-paint-crash.html
232 * rendering/RenderView.cpp:
233 (WebCore::RenderView::splitSelectionBetweenSubtrees):
234 * rendering/SelectionSubtreeRoot.cpp:
235 (WebCore::SelectionSubtreeRoot::adjustForVisibleSelection):
236 * rendering/SelectionSubtreeRoot.h:
237 (WebCore::SelectionSubtreeRoot::selectionClear):
239 2014-05-19 Simon Fraser <simon.fraser@apple.com>
241 Scrolling pages with large TiledBacking content layers creates way too many tiles
242 https://bugs.webkit.org/show_bug.cgi?id=133101
244 Reviewed by Tim Horton.
246 Fix the GraphicsLayerCA::adjustTiledLayerVisibleRect() logic to avoid making giant rects if the old
247 and new visible rects don't overlap.
249 * platform/graphics/TiledBacking.h:
250 * platform/graphics/ca/GraphicsLayerCA.cpp:
251 (WebCore::GraphicsLayerCA::adjustTiledLayerVisibleRect):
252 * platform/graphics/ca/mac/TileController.h:
254 2014-05-19 Simon Fraser <simon.fraser@apple.com>
256 Correctly maintain the "isInWindow" state for all TiledBackings
257 https://bugs.webkit.org/show_bug.cgi?id=133095
259 Reviewed by Tim Horton.
261 We never updated the "isInWindow" state for TiledBacking that wasn't the RenderView's
262 backing. Fix it by having RenderLayerCompositor::setIsInWindow() recurse through all
263 layers (if necessary), updating their state. Also set the state on newly created
266 * rendering/RenderLayerCompositor.cpp:
267 (WebCore::RenderLayerCompositor::layerTiledBackingUsageChanged):
268 (WebCore::RenderLayerCompositor::setIsInWindowForLayerIncludingDescendants):
269 (WebCore::RenderLayerCompositor::setIsInWindow):
270 (WebCore::RenderLayerCompositor::pageTiledBacking): Deleted.
271 * rendering/RenderLayerCompositor.h:
273 2014-05-19 Dean Jackson <dino@apple.com>
275 [iOS] Use status display for live streams
276 https://bugs.webkit.org/show_bug.cgi?id=133097
278 Reviewed by Sam Weinig.
280 Follow-on from https://bugs.webkit.org/show_bug.cgi?id=131390
281 Allow the iOS controls to use the status display field.
283 * Modules/mediacontrols/mediaControlsiOS.js:
284 (ControllerIOS.prototype.configureInlineControls): Live streams should
285 not have a timeline or rewind button.
287 2014-05-19 Myles C. Maxfield <litherum@gmail.com>
289 Text decorations do not contribute to visual overflow
290 https://bugs.webkit.org/show_bug.cgi?id=132773
292 Reviewed by Antti Koivisto.
294 This patch creates a function, visualOverflowForDecorations, which computes
295 how much visual overflow to add around a text box due to text decorations. Most of the time,
296 text decorations are fully contained within the text box, so the result is usually 0.
298 This function exists within style/InlineTextBoxStyle.cpp, which is an added file. This is
299 so that it can be called from setLogicalWidthForTextRun() inside RenderBlockLineLayout.cpp
300 and from RenderStyle::changeAffectsVisualOverflow(). The former case passes in the full
301 InlineTextBox and the latter case just passes in a RenderStyle (because the InlineTextBox
304 This patch also modifies RenderTableSection::spannedColumns() to fix an off-by-one error
305 that was causing table borders to not be drawn when they existed right on the edge of
308 Tests: fast/css3-text/css3-text-decoration/repaint/underline-outside-of-layout-rect.html
309 Tests: fast/repaint/border-collapse-table-off-by-one-expected.html
311 * WebCore.vcxproj/WebCore.vcxproj: Adding reference to new InlineTextBoxStyle.cpp file
312 * WebCore.vcxproj/WebCore.vcxproj.filters: Adding reference to new InlineTextBoxStyle files
313 * WebCore.xcodeproj/project.pbxproj: Adding reference to new InlineTextBoxStyle files
314 * rendering/InlineTextBox.cpp:
315 (WebCore::computeUnderlineOffset): Moved to InlineTextBox.cpp
316 (WebCore::getWavyStrokeParameters): Moved to InlineTextBox.cpp
317 (WebCore::InlineTextBox::paintDecoration): Update to use newly refactored functions
318 * rendering/RenderBlockLineLayout.cpp:
319 (WebCore::setLogicalWidthForTextRun): Call visualOverflowForDecorations()
320 * rendering/RenderTableSection.cpp:
321 * rendering/RenderTableSelection.cpp: Fix off-by-one error when the boundary of a repaint
322 rect lies exactly on top of a table column position
323 * rendering/style/RenderStyle.cpp:
324 (WebCore::RenderStyle::changeAffectsVisualOverflow): Inspects shadows and text decorations
325 (WebCore::RenderStyle::changeRequiresLayout): Calls changeAffectsVisualOverflow()
326 (WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline): Moved code from here
327 to changeAffectsVisualOverflow().
328 * rendering/style/RenderStyle.h: Function signature
329 * style/InlineTextBoxStyle.cpp: Added.
330 (WebCore::computeUnderlineOffset): Moved from InlineTextBox.cpp
331 (WebCore::getWavyStrokeParameters): Moved from InlineTextBox.cpp
332 (WebCore::extendIntToFloat): Convenience function for dealing with the fact that
333 underline bounding boxes use floats and GlyphOverflow uses ints
334 (WebCore::visualOverflowForDecorations): Given
335 vertical overflow bounds, possibly extend those to include location of
337 * style/InlineTextBoxStyle.h: Added. Function signatures.
338 (WebCore::textDecorationStrokeThickness): Refactored from InlineTextBox.cpp
339 (WebCore::wavyOffsetFromDecoration): Refactored from InlineTextBox.cpp
340 * platform/graphics/Font.h:
341 (WebCore::GlyphOverflow::isEmpty): Convenience function
342 (WebCore::GlyphOverflow::extendTo): Convenience function
344 2014-05-19 Alex Christensen <achristensen@webkit.org>
346 Unreviewed build fix after r169082
348 * platform/network/ResourceHandle.h:
349 Added NSDictionary declaration.
351 2014-05-19 Beth Dakin <bdakin@apple.com>
353 REGRESSION: Standalone images need to take topContentInset into account
354 https://bugs.webkit.org/show_bug.cgi?id=133092
356 <rdar://problem/16945791>
358 Reviewed by Darin Adler.
360 The FrameView’s size is accurate in terms of the NSWindow size, but that is not
361 really what the ImageDocument code is looking for here. The ImageDocument wants to
362 know the size of the unobscured viewport area. We should use visibleSize() for
364 * html/ImageDocument.cpp:
365 (WebCore::ImageDocument::scale):
366 (WebCore::ImageDocument::imageFitsInWindow):
367 (WebCore::ImageDocument::imageClicked):
369 2014-05-19 Alex Christensen <achristensen@webkit.org>
371 Collect web timing data on iOS.
372 https://bugs.webkit.org/show_bug.cgi?id=133075
374 Reviewed by Sam Weinig.
376 * platform/network/ResourceHandle.h:
377 Added setCollectsTimingData wrapper and getConnectionTimingData declarations.
378 getConnectionTimingData with a dictionary parameter is a private helper function.
379 * platform/network/cf/ResourceHandleCFNet.cpp:
380 (WebCore::ResourceHandle::start):
381 Call setCollectsTimingData wrapper when creating a connection to ensure that timing data is collected.
382 * platform/network/cf/ResourceHandleCFURLConnectionDelegate.cpp:
383 (WebCore::ResourceHandleCFURLConnectionDelegate::didReceiveResponseCallback):
384 * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h:
385 * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp:
386 (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse):
387 * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.h:
388 * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp:
389 (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveResponse):
390 * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h:
391 Pass the CFURLConnectionRef to didReceiveResponse to get timing data from.
392 * platform/network/mac/ResourceHandleMac.mm:
393 (WebCore::ResourceHandle::getConnectionTimingData):
394 Moved from getTimingData to compile regardless of using CFNetwork and added wrapper with CFDictionaryRef.
395 (WebCore::ResourceHandle::setCollectsTimingData):
396 Added wrapper to call objc function from c++.
397 (WebCore::ResourceHandle::getTimingData):
398 Renamed to getConnectionTimingData.
399 * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
400 (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
401 * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
402 (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
403 Updated function name from getTimingData to getConnectionTimingData.
405 2014-05-19 Chris Fleizach <cfleizach@apple.com>
407 AX: VoiceOver sees the WebArea out of order when topContentInset is used
408 https://bugs.webkit.org/show_bug.cgi?id=133091
410 Reviewed by Simon Fraser.
412 Modify the scroll view's frame so that it recognizes the content inset.
413 This is needed so that when VoiceOver sorts elements to create an ordering,
414 the web area is not ordered at the top of the screen.
416 Test: platform/mac-wk2/accessibility/content-inset-scrollview-frame.html
418 * accessibility/AccessibilityScrollView.cpp:
419 (WebCore::AccessibilityScrollView::elementRect):
421 2014-05-19 Beth Dakin <bdakin@apple.com>
423 Scrollbars display incorrectly after switching between fast and slow scrolling
424 mode, affects Find and real sites
425 https://bugs.webkit.org/show_bug.cgi?id=133077
427 <rdar://problem/16888608>
429 Reviewed by Tim Horton.
431 We should always return true here when updating on the secondary thread is
432 supported. It does not need to be gated on whether we are actively taking
433 advantage of that support at this moment.
434 * platform/Scrollbar.cpp:
435 (WebCore::Scrollbar::supportsUpdateOnSecondaryThread):
437 Always update the presentationValue whenever we update the doubleValue just to
439 * platform/mac/ScrollbarThemeMac.mm:
440 (WebCore::ScrollbarThemeMac::setPaintCharacteristicsForScrollbar):
442 2014-05-19 Simon Fraser <simon.fraser@apple.com>
444 Split scrolling tree ScrollingNodes into FrameScrollingNodes and OverflowScrollingNodes
445 https://bugs.webkit.org/show_bug.cgi?id=133022
447 Reviewed by Sam Weinig.
449 In both the scrolling state tree and the scrolling tree, split the "scrolling nodes"
450 into FrameScrolling and OverflowScrolling nodes.
452 Move what was the "viewportSize" property onto the base class for the scrolling
453 nodes, calling it "scrollableAreaSize".
455 Make minimum/maximumScrollPosition() virtual so we can share more code (and there
456 is more code sharing to be done in future).
458 * Configurations/WebCore.xcconfig: Remove ScrollingStateScrollingNodeMac.mm and ScrollingTreeScrollingNodeMac.mm
459 from the list, using #ifdefs in the file instead.
460 * WebCore.exp.in: Lots of exports.
461 * WebCore.xcodeproj/project.pbxproj: New files.
462 * page/scrolling/AsyncScrollingCoordinator.cpp:
463 (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
464 (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
465 (WebCore::AsyncScrollingCoordinator::updateFrameScrollingNode):
466 (WebCore::AsyncScrollingCoordinator::updateOverflowScrollingNode):
467 (WebCore::AsyncScrollingCoordinator::recomputeWheelEventHandlerCountForFrameView):
468 (WebCore::AsyncScrollingCoordinator::updateScrollingNode): Deleted.
469 (WebCore::AsyncScrollingCoordinator::setScrollbarPaintersFromScrollbarsForNode): Deleted.
470 This tiny function didn't need to exist.
471 * page/scrolling/AsyncScrollingCoordinator.h:
472 * page/scrolling/ScrollingCoordinator.h:
473 (WebCore::ScrollingCoordinator::updateFrameScrollingNode):
474 (WebCore::ScrollingCoordinator::updateOverflowScrollingNode):
475 (WebCore::ScrollingCoordinator::updateScrollingNode): Deleted.
476 * page/scrolling/ScrollingStateFrameScrollingNode.cpp: Copied from Source/WebCore/page/scrolling/ScrollingStateScrollingNode.cpp.
477 (WebCore::ScrollingStateFrameScrollingNode::create):
478 (WebCore::ScrollingStateFrameScrollingNode::ScrollingStateFrameScrollingNode):
479 (WebCore::ScrollingStateFrameScrollingNode::~ScrollingStateFrameScrollingNode):
480 (WebCore::ScrollingStateFrameScrollingNode::clone):
481 (WebCore::ScrollingStateFrameScrollingNode::setFrameScaleFactor):
482 (WebCore::ScrollingStateFrameScrollingNode::setNonFastScrollableRegion):
483 (WebCore::ScrollingStateFrameScrollingNode::setWheelEventHandlerCount):
484 (WebCore::ScrollingStateFrameScrollingNode::setSynchronousScrollingReasons):
485 (WebCore::ScrollingStateFrameScrollingNode::setScrollBehaviorForFixedElements):
486 (WebCore::ScrollingStateFrameScrollingNode::setHeaderHeight):
487 (WebCore::ScrollingStateFrameScrollingNode::setFooterHeight):
488 (WebCore::ScrollingStateFrameScrollingNode::setTopContentInset):
489 (WebCore::ScrollingStateFrameScrollingNode::setCounterScrollingLayer):
490 (WebCore::ScrollingStateFrameScrollingNode::setInsetClipLayer):
491 (WebCore::ScrollingStateFrameScrollingNode::setContentShadowLayer):
492 (WebCore::ScrollingStateFrameScrollingNode::setHeaderLayer):
493 (WebCore::ScrollingStateFrameScrollingNode::setFooterLayer):
494 (WebCore::ScrollingStateFrameScrollingNode::setScrollbarPaintersFromScrollbars):
495 (WebCore::ScrollingStateFrameScrollingNode::dumpProperties):
496 * page/scrolling/ScrollingStateFrameScrollingNode.h: Copied from Source/WebCore/page/scrolling/ScrollingStateScrollingNode.h.
497 * page/scrolling/ScrollingStateNode.h:
498 (WebCore::LayerRepresentation::layerID):
499 (WebCore::ScrollingStateNode::isFrameScrollingNode):
500 (WebCore::ScrollingStateNode::isOverflowScrollingNode):
501 * page/scrolling/ScrollingStateOverflowScrollingNode.cpp: Added.
502 (WebCore::ScrollingStateOverflowScrollingNode::create):
503 (WebCore::ScrollingStateOverflowScrollingNode::ScrollingStateOverflowScrollingNode):
504 (WebCore::ScrollingStateOverflowScrollingNode::~ScrollingStateOverflowScrollingNode):
505 (WebCore::ScrollingStateOverflowScrollingNode::clone):
506 (WebCore::ScrollingStateOverflowScrollingNode::setScrolledContentsLayer):
507 (WebCore::ScrollingStateOverflowScrollingNode::dumpProperties):
508 * page/scrolling/ScrollingStateOverflowScrollingNode.h: Copied from Source/WebCore/page/scrolling/mac/ScrollingStateScrollingNodeMac.mm.
509 (WebCore::ScrollingStateOverflowScrollingNode::scrolledContentsLayer):
510 * page/scrolling/ScrollingStateScrollingNode.cpp:
511 (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
512 (WebCore::ScrollingStateScrollingNode::setScrollableAreaSize):
513 (WebCore::ScrollingStateScrollingNode::setTotalContentsSize):
514 (WebCore::ScrollingStateScrollingNode::dumpProperties):
515 (WebCore::ScrollingStateScrollingNode::create): Deleted.
516 (WebCore::ScrollingStateScrollingNode::clone): Deleted.
517 (WebCore::ScrollingStateScrollingNode::setViewportSize): Deleted.
518 (WebCore::ScrollingStateScrollingNode::setFrameScaleFactor): Deleted.
519 (WebCore::ScrollingStateScrollingNode::setNonFastScrollableRegion): Deleted.
520 (WebCore::ScrollingStateScrollingNode::setWheelEventHandlerCount): Deleted.
521 (WebCore::ScrollingStateScrollingNode::setSynchronousScrollingReasons): Deleted.
522 (WebCore::ScrollingStateScrollingNode::setScrollBehaviorForFixedElements): Deleted.
523 (WebCore::ScrollingStateScrollingNode::setHeaderHeight): Deleted.
524 (WebCore::ScrollingStateScrollingNode::setFooterHeight): Deleted.
525 (WebCore::ScrollingStateScrollingNode::setTopContentInset): Deleted.
526 (WebCore::ScrollingStateScrollingNode::setScrolledContentsLayer): Deleted.
527 (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayer): Deleted.
528 (WebCore::ScrollingStateScrollingNode::setInsetClipLayer): Deleted.
529 (WebCore::ScrollingStateScrollingNode::setContentShadowLayer): Deleted.
530 (WebCore::ScrollingStateScrollingNode::setHeaderLayer): Deleted.
531 (WebCore::ScrollingStateScrollingNode::setFooterLayer): Deleted.
532 (WebCore::ScrollingStateScrollingNode::setScrollbarPaintersFromScrollbars): Deleted.
533 * page/scrolling/ScrollingStateScrollingNode.h:
534 (WebCore::ScrollingStateScrollingNode::scrollableAreaSize):
535 (WebCore::ScrollingStateScrollingNode::totalContentsSize):
536 * page/scrolling/ScrollingStateTree.cpp:
537 (WebCore::ScrollingStateTree::attachNode):
538 (WebCore::ScrollingStateTree::commit):
539 * page/scrolling/ScrollingStateTree.h:
540 (WebCore::ScrollingStateTree::rootStateNode):
541 (WebCore::ScrollingStateTree::setRootStateNode):
542 * page/scrolling/ScrollingTree.cpp:
543 (WebCore::ScrollingTree::commitNewTreeState):
544 * page/scrolling/ScrollingTreeFrameScrollingNode.cpp: Added.
545 (WebCore::ScrollingTreeFrameScrollingNode::ScrollingTreeFrameScrollingNode):
546 (WebCore::ScrollingTreeFrameScrollingNode::~ScrollingTreeFrameScrollingNode):
547 (WebCore::ScrollingTreeFrameScrollingNode::updateBeforeChildren):
548 * page/scrolling/ScrollingTreeFrameScrollingNode.h: Copied from Source/WebCore/page/scrolling/ScrollingTreeScrollingNode.h.
549 (WebCore::ScrollingTreeFrameScrollingNode::updateLayersAfterDelegatedScroll):
550 (WebCore::ScrollingTreeFrameScrollingNode::synchronousScrollingReasons):
551 (WebCore::ScrollingTreeFrameScrollingNode::shouldUpdateScrollLayerPositionSynchronously):
552 (WebCore::ScrollingTreeFrameScrollingNode::frameScaleFactor):
553 (WebCore::ScrollingTreeFrameScrollingNode::headerHeight):
554 (WebCore::ScrollingTreeFrameScrollingNode::footerHeight):
555 (WebCore::ScrollingTreeFrameScrollingNode::topContentInset):
556 (WebCore::ScrollingTreeFrameScrollingNode::scrollBehaviorForFixedElements):
557 * page/scrolling/ScrollingTreeNode.h:
558 (WebCore::ScrollingTreeNode::isFrameScrollingNode):
559 (WebCore::ScrollingTreeNode::isOverflowScrollingNode):
560 * page/scrolling/ScrollingTreeOverflowScrollingNode.cpp: Copied from Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h.
561 (WebCore::ScrollingTreeOverflowScrollingNode::ScrollingTreeOverflowScrollingNode):
562 (WebCore::ScrollingTreeOverflowScrollingNode::~ScrollingTreeOverflowScrollingNode):
563 * page/scrolling/ScrollingTreeOverflowScrollingNode.h: Copied from Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h.
564 * page/scrolling/ScrollingTreeScrollingNode.cpp:
565 (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
566 (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
567 (WebCore::ScrollingTreeScrollingNode::updateAfterChildren):
568 (WebCore::ScrollingTreeScrollingNode::setScrollPosition):
569 (WebCore::ScrollingTreeScrollingNode::setScrollPositionWithoutContentEdgeConstraints):
570 (WebCore::ScrollingTreeScrollingNode::minimumScrollPosition):
571 (WebCore::ScrollingTreeScrollingNode::maximumScrollPosition):
572 * page/scrolling/ScrollingTreeScrollingNode.h:
573 (WebCore::ScrollingTreeScrollingNode::scrollableAreaSize):
574 (WebCore::ScrollingTreeScrollingNode::totalContentsSize):
575 (WebCore::ScrollingTreeScrollingNode::totalContentsSizeForRubberBand):
576 (WebCore::ScrollingTreeScrollingNode::setTotalContentsSizeForRubberBand):
577 (WebCore::ScrollingTreeScrollingNode::synchronousScrollingReasons): Deleted.
578 (WebCore::ScrollingTreeScrollingNode::shouldUpdateScrollLayerPositionSynchronously): Deleted.
579 (WebCore::ScrollingTreeScrollingNode::viewportSize): Deleted.
580 (WebCore::ScrollingTreeScrollingNode::frameScaleFactor): Deleted.
581 (WebCore::ScrollingTreeScrollingNode::headerHeight): Deleted.
582 (WebCore::ScrollingTreeScrollingNode::footerHeight): Deleted.
583 (WebCore::ScrollingTreeScrollingNode::scrollBehaviorForFixedElements): Deleted.
584 (WebCore::ScrollingTreeScrollingNode::topContentInset): Deleted.
585 * page/scrolling/ios/ScrollingCoordinatorIOS.mm:
586 (WebCore::ScrollingCoordinatorIOS::createScrollingTreeNode):
587 * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.h: Renamed from Source/WebCore/page/scrolling/ios/ScrollingTreeScrollingNodeIOS.h.
588 (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollLayer):
589 * page/scrolling/ios/ScrollingTreeFrameScrollingNodeIOS.mm: Renamed from Source/WebCore/page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm.
590 (WebCore::ScrollingTreeFrameScrollingNodeIOS::create):
591 (WebCore::ScrollingTreeFrameScrollingNodeIOS::ScrollingTreeFrameScrollingNodeIOS):
592 (WebCore::ScrollingTreeFrameScrollingNodeIOS::~ScrollingTreeFrameScrollingNodeIOS):
593 (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateBeforeChildren):
594 (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateAfterChildren):
595 (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollPosition):
596 (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollPosition):
597 (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollPositionWithoutContentEdgeConstraints):
598 (WebCore::ScrollingTreeFrameScrollingNodeIOS::setScrollLayerPosition):
599 (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateLayersAfterViewportChange):
600 (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateLayersAfterDelegatedScroll):
601 (WebCore::ScrollingTreeFrameScrollingNodeIOS::updateChildNodesAfterScroll):
602 (WebCore::ScrollingTreeFrameScrollingNodeIOS::minimumScrollPosition):
603 (WebCore::ScrollingTreeFrameScrollingNodeIOS::maximumScrollPosition):
604 (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollBy):
605 (WebCore::ScrollingTreeFrameScrollingNodeIOS::scrollByWithoutContentEdgeConstraints):
606 * page/scrolling/mac/ScrollingCoordinatorMac.mm:
607 (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode):
608 * page/scrolling/mac/ScrollingStateFrameScrollingNodeMac.mm: Renamed from Source/WebCore/page/scrolling/mac/ScrollingStateScrollingNodeMac.mm.
609 (WebCore::ScrollingStateFrameScrollingNode::setScrollbarPaintersFromScrollbars):
610 * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.h: Renamed from Source/WebCore/page/scrolling/mac/ScrollingTreeScrollingNodeMac.h.
611 * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm: Renamed from Source/WebCore/page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm.
612 (WebCore::ScrollingTreeFrameScrollingNodeMac::create):
613 (WebCore::ScrollingTreeFrameScrollingNodeMac::ScrollingTreeFrameScrollingNodeMac):
614 (WebCore::ScrollingTreeFrameScrollingNodeMac::~ScrollingTreeFrameScrollingNodeMac):
615 (WebCore::ScrollingTreeFrameScrollingNodeMac::updateBeforeChildren):
616 (WebCore::ScrollingTreeFrameScrollingNodeMac::updateAfterChildren):
617 (WebCore::ScrollingTreeFrameScrollingNodeMac::handleWheelEvent):
618 (WebCore::ScrollingTreeFrameScrollingNodeMac::allowsHorizontalStretching):
619 (WebCore::ScrollingTreeFrameScrollingNodeMac::allowsVerticalStretching):
620 (WebCore::ScrollingTreeFrameScrollingNodeMac::stretchAmount):
621 (WebCore::ScrollingTreeFrameScrollingNodeMac::pinnedInDirection):
622 (WebCore::ScrollingTreeFrameScrollingNodeMac::canScrollHorizontally):
623 (WebCore::ScrollingTreeFrameScrollingNodeMac::canScrollVertically):
624 (WebCore::ScrollingTreeFrameScrollingNodeMac::shouldRubberBandInDirection):
625 (WebCore::ScrollingTreeFrameScrollingNodeMac::absoluteScrollPosition):
626 (WebCore::ScrollingTreeFrameScrollingNodeMac::immediateScrollBy):
627 (WebCore::ScrollingTreeFrameScrollingNodeMac::immediateScrollByWithoutContentEdgeConstraints):
628 (WebCore::ScrollingTreeFrameScrollingNodeMac::startSnapRubberbandTimer):
629 (WebCore::ScrollingTreeFrameScrollingNodeMac::stopSnapRubberbandTimer):
630 (WebCore::ScrollingTreeFrameScrollingNodeMac::adjustScrollPositionToBoundsIfNecessary):
631 (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollPosition):
632 (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPosition):
633 (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollPositionWithoutContentEdgeConstraints):
634 (WebCore::ScrollingTreeFrameScrollingNodeMac::setScrollLayerPosition):
635 (WebCore::ScrollingTreeFrameScrollingNodeMac::updateLayersAfterViewportChange):
636 (WebCore::ScrollingTreeFrameScrollingNodeMac::minimumScrollPosition):
637 (WebCore::ScrollingTreeFrameScrollingNodeMac::maximumScrollPosition):
638 (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollBy):
639 (WebCore::ScrollingTreeFrameScrollingNodeMac::scrollByWithoutContentEdgeConstraints):
640 (WebCore::ScrollingTreeFrameScrollingNodeMac::updateMainFramePinState):
641 (WebCore::ScrollingTreeFrameScrollingNodeMac::logExposedUnfilledArea):
642 (WebCore::logThreadedScrollingMode):
643 (WebCore::logWheelEventHandlerCountChanged):
644 * rendering/RenderLayerCompositor.cpp:
645 (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
647 2014-05-19 Simon Fraser <simon.fraser@apple.com>
649 Images missing sometimes with composited clipping layers
650 https://bugs.webkit.org/show_bug.cgi?id=133065
651 <rdar://problem/15224559>
653 Reviewed by Beth Dakin.
655 When support for solid colors on layers was added, a layer was considered a candidate
656 for the solid color optimization without regard to whether it had descendent layers
657 with "paintsIntoCompositedAncestor" requirements.
659 Fix hasVisibleNonCompositingDescendantLayers(), renaming it to isPaintDestinationForDescendentLayers()
660 and having it take into account whether descendent layers need to paint into an
663 Also, this test has to happen after those descendent layers have had their
664 compositing state updated, so move the isSimpleContainerCompositingLayer() to
665 a new updateAfterDescendents() function which is called from the various
666 places we do compositing-udpate-tree-walks.
668 Test: compositing/backing/solid-color-with-paints-into-ancestor.html
670 * rendering/RenderLayerBacking.cpp:
671 (WebCore::RenderLayerBacking::updateGeometry):
672 (WebCore::RenderLayerBacking::updateAfterDescendents):
673 (WebCore::RenderLayerBacking::paintsChildren):
674 (WebCore::compositedWithOwnBackingStore):
675 (WebCore::descendentLayerPaintsIntoAncestor):
676 (WebCore::RenderLayerBacking::isPaintDestinationForDescendentLayers):
677 (WebCore::hasVisibleNonCompositingDescendant): Deleted.
678 (WebCore::RenderLayerBacking::hasVisibleNonCompositingDescendantLayers): Deleted.
679 * rendering/RenderLayerBacking.h:
680 * rendering/RenderLayerCompositor.cpp:
681 (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
682 (WebCore::RenderLayerCompositor::updateLayerTreeGeometry):
683 (WebCore::RenderLayerCompositor::updateCompositingDescendantGeometry):
685 2014-05-19 Zalan Bujtas <zalan@apple.com>
687 REGRESSION (r133351, sub-pixel layout): Right-to-left block with text-overflow: ellipsis truncates prematurely (breaks facebook.com Hebrew UI)
688 https://bugs.webkit.org/show_bug.cgi?id=112227
690 Reviewed by Maciej Stachowiak.
692 This patch removes unnecessary integral snapping of inlines at layout time.
694 The general rule of thumb of using round/floor/ceil at layout time is to not use them.
696 When some computed values (x, y, width, height) get snapped during layout, while others don't,
697 intersecting/measuring mismatches could occur and they could end up producing visual artifacts such as truncations.
698 This patch also enables iframe content to be positioned on odd device pixel positions on retina displays.
700 Tests: fast/frames/hidpi-position-iframe-on-device-pixel.html
701 fast/inline/hidpi-rtl-text-does-not-fit-line-and-gets-cut-off.html
703 * rendering/RenderBlock.h:
704 (WebCore::RenderBlock::logicalLeftOffsetForLine):
705 (WebCore::RenderBlock::pixelSnappedLogicalLeftOffsetForLine): Deleted.
706 (WebCore::RenderBlock::pixelSnappedLogicalRightOffsetForLine): Deleted.
707 * rendering/RenderBlockLineLayout.cpp:
708 (WebCore::updateLogicalInlinePositions):
709 (WebCore::RenderBlockFlow::deleteEllipsisLineBoxes):
710 (WebCore::RenderBlockFlow::checkLinesForTextOverflow):
712 2014-05-18 Chris Fleizach <cfleizach@apple.com>
714 AX: iOS: using AXAttributeCacheEnabler is too slow for every accessibilityElementAtIndex:
715 https://bugs.webkit.org/show_bug.cgi?id=133043
717 Reviewed by Mario Sanchez Prada.
719 iOS Accessibility code tries to improve performance by caching attributes when accessing
720 elements through the platform API. However, those API calls can be used very frequently when
721 iterating elements. Creating the AXAttributeCacheEnabler object and tearing it down is proving
722 to be the hottest code path in samples for accessibility access.
724 We need to move the logic for enabling/disabling the attribute cache to a level that can make
725 a more informed decision about when to enable/disable.
727 * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
728 (-[WebAccessibilityObjectWrapper enableAttributeCaching]):
729 (-[WebAccessibilityObjectWrapper disableAttributeCaching]):
730 (-[WebAccessibilityObjectWrapper accessibilityElementCount]):
731 (-[WebAccessibilityObjectWrapper accessibilityElementAtIndex:]):
732 (-[WebAccessibilityObjectWrapper indexOfAccessibilityElement:]):
734 2014-05-18 Simon Fraser <simon.fraser@apple.com>
736 Use RenderStyle& in more places in RenderLayerBacking
737 https://bugs.webkit.org/show_bug.cgi?id=133061
739 Reviewed by Andreas Kling.
741 Convert several member functions to use references to RenderStyle rather
742 than pointers. Move canCreateTiledImage() higher in the file (no code
743 changes). Other minor cleanup.
745 * rendering/RenderLayerBacking.cpp:
746 (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
747 (WebCore::RenderLayerBacking::updateOpacity):
748 (WebCore::RenderLayerBacking::updateTransform):
749 (WebCore::RenderLayerBacking::updateFilters):
750 (WebCore::RenderLayerBacking::updateBlendMode):
751 (WebCore::RenderLayerBacking::updateGeometry):
752 (WebCore::hasBoxDecorations):
753 (WebCore::canCreateTiledImage):
754 (WebCore::hasBoxDecorationsOrBackgroundImage):
755 (WebCore::hasPerspectiveOrPreserves3D):
756 (WebCore::supportsDirectBoxDecorationsComposition):
757 (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
758 (WebCore::RenderLayerBacking::contentChanged):
759 (WebCore::RenderLayerBacking::startTransition):
760 * rendering/RenderLayerBacking.h:
762 2014-05-17 Simon Fraser <simon.fraser@apple.com>
764 Rename some RenderLayerBacking member functions
765 https://bugs.webkit.org/show_bug.cgi?id=133030
767 Reviewed by Sam Weinig.
769 Remove "GraphicsLayer" from some member function names on RenderLayerBacking.
773 * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
774 (WebCore::AVFWrapper::createAVCFVideoLayer):
775 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
776 (WebCore::MediaPlayerPrivateQTKit::createQTMovieLayer):
777 * rendering/RenderLayer.cpp:
778 (WebCore::RenderLayer::calculateClipRects):
779 * rendering/RenderLayerBacking.cpp:
780 (WebCore::RenderLayerBacking::updateAfterLayout):
781 (WebCore::RenderLayerBacking::updateConfiguration):
782 (WebCore::RenderLayerBacking::updateGeometry):
783 (WebCore::RenderLayerBacking::contentChanged):
784 (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
785 (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration): Deleted.
786 (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): Deleted.
787 * rendering/RenderLayerBacking.h:
788 * rendering/RenderLayerCompositor.cpp:
789 (WebCore::RenderLayerCompositor::updateLayerCompositingState):
790 (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
791 (WebCore::RenderLayerCompositor::updateLayerTreeGeometry):
792 (WebCore::RenderLayerCompositor::updateCompositingDescendantGeometry):
793 (WebCore::RenderLayerCompositor::attachRootLayer):
795 2014-05-19 Antti Koivisto <antti@apple.com>
797 Fix assertion failure with simple line layout debug borders enabled.
799 Rubber-stamped by Andreas Kling.
801 * rendering/SimpleLineLayoutFunctions.cpp:
802 (WebCore::SimpleLineLayout::paintDebugBorders): We shoudn't try to paint empty rects.
804 2014-05-18 Andreas Kling <akling@apple.com>
806 Reduce constructor copypasta in RenderText and RenderElement.
807 <https://webkit.org/b/133056>
809 Use delegating constructors to remove duplicated initializer lists
810 from the constructors of RenderText and RenderElement.
812 Reviewed by Anders Carlsson.
814 * rendering/RenderElement.cpp:
815 (WebCore::RenderElement::RenderElement):
816 * rendering/RenderElement.h:
817 * rendering/RenderText.cpp:
818 (WebCore::RenderText::RenderText):
819 * rendering/RenderText.h:
821 2014-05-18 Brent Fulgham <bfulgham@apple.com>
823 Crash during scroll when latched
824 https://bugs.webkit.org/show_bug.cgi?id=133064
826 Reviewed by Simon Fraser.
828 * page/mac/EventHandlerMac.mm:
829 (WebCore::EventHandler::platformPrepareForWheelEvents): Prevent dereference of NULL
830 wheelEventTarget argument.
832 2014-05-18 Svetlana Redchenko <redchenko@yandex-team.ru>
834 Input ::selection pseudo class does not work leading to hidden selection
835 https://bugs.webkit.org/show_bug.cgi?id=38943
837 Reviewed by Darin Adler.
839 Test: fast/selectors/input-with-selection-pseudo-element.html
841 When text is selected inside input element, it should change the
842 color and background color according to the ::selection pseudo element.
844 * rendering/RenderObject.cpp:
845 (WebCore::RenderObject::selectionBackgroundColor):
846 (WebCore::RenderObject::selectionColor):
847 (WebCore::RenderObject::selectionPseudoStyle):
848 * rendering/RenderObject.h:
850 2014-05-18 Sam Weinig <sam@webkit.org>
852 [WebKit2] Implement ScriptMessageHandlers
853 https://bugs.webkit.org/show_bug.cgi?id=133053
855 Reviewed by Anders Carlsson.
857 * DerivedSources.make:
859 * WebCore.xcodeproj/project.pbxproj:
860 * bindings/js/JSDOMWindowBase.cpp:
861 (WebCore::JSDOMWindowBase::finishCreation):
862 * bindings/js/JSUserMessageHandlersNamespaceCustom.cpp: Added.
863 (WebCore::JSUserMessageHandlersNamespace::getOwnPropertySlotDelegate):
864 * page/DOMWindow.cpp:
865 (WebCore::DOMWindow::shouldHaveWebKitNamespaceForWorld):
866 (WebCore::DOMWindow::webkitNamespace):
868 * page/UserContentController.cpp:
869 (WebCore::UserContentController::addUserMessageHandlerDescriptor):
870 (WebCore::UserContentController::removeUserMessageHandlerDescriptor):
871 * page/UserContentController.h:
872 (WebCore::UserContentController::userMessageHandlerDescriptors):
873 * page/UserMessageHandler.cpp: Added.
874 (WebCore::UserMessageHandler::UserMessageHandler):
875 (WebCore::UserMessageHandler::~UserMessageHandler):
876 (WebCore::UserMessageHandler::postMessage):
877 (WebCore::UserMessageHandler::name):
878 (WebCore::UserMessageHandler::world):
879 * page/UserMessageHandler.h: Added.
880 (WebCore::UserMessageHandler::create):
881 * page/UserMessageHandler.idl: Added.
882 * page/UserMessageHandlerDescriptor.cpp: Added.
883 (WebCore::UserMessageHandlerDescriptor::UserMessageHandlerDescriptor):
884 (WebCore::UserMessageHandlerDescriptor::~UserMessageHandlerDescriptor):
885 (WebCore::UserMessageHandlerDescriptor::name):
886 (WebCore::UserMessageHandlerDescriptor::world):
887 * page/UserMessageHandlerDescriptor.h: Added.
888 (WebCore::UserMessageHandlerDescriptor::Client::~Client):
889 (WebCore::UserMessageHandlerDescriptor::create):
890 (WebCore::UserMessageHandlerDescriptor::client):
891 * page/UserMessageHandlerDescriptorTypes.h: Added.
892 * page/UserMessageHandlersNamespace.cpp: Added.
893 (WebCore::UserMessageHandlersNamespace::UserMessageHandlersNamespace):
894 (WebCore::UserMessageHandlersNamespace::~UserMessageHandlersNamespace):
895 (WebCore::UserMessageHandlersNamespace::handler):
896 * page/UserMessageHandlersNamespace.h: Added.
897 (WebCore::UserMessageHandlersNamespace::create):
898 * page/UserMessageHandlersNamespace.idl: Added.
899 * page/WebKitNamespace.cpp: Added.
900 (WebCore::WebKitNamespace::WebKitNamespace):
901 (WebCore::WebKitNamespace::~WebKitNamespace):
902 (WebCore::WebKitNamespace::messageHandlers):
903 * page/WebKitNamespace.h: Added.
904 (WebCore::WebKitNamespace::create):
905 * page/WebKitNamespace.idl: Added.
907 2014-05-18 Maciej Stachowiak <mjs@apple.com>
909 REGRESSION (r156546): Default media controls are laid out incorrectly when media element is styled with direction:rtl
910 https://bugs.webkit.org/show_bug.cgi?id=132531
911 <rdar://problem/16806267>
913 Reviewed by Mark Rowe.
915 This was already tested by the media/video-rtl.htm reftest, now unskipped.
917 * Modules/mediacontrols/mediaControlsApple.css:
918 (audio::-webkit-media-controls-panel): Add missing direction: ltr
920 2014-05-18 Rik Cabanier <cabanier@adobe.com>
922 support for navigator.hardwareConcurrency
923 https://bugs.webkit.org/show_bug.cgi?id=132588
925 Reviewed by Filip Pizlo.
927 Added a new API that returns the number of CPU cores up to 8.
929 Test: fast/dom/navigator-hardwareConcurrency.html
931 * Configurations/FeatureDefines.xcconfig:
932 * page/Navigator.cpp:
933 (WebCore::Navigator::hardwareConcurrency):
935 * page/Navigator.idl:
937 2014-05-18 Anders Carlsson <andersca@apple.com>
942 Move UserContentController symbols to the right place.
944 2014-05-18 Jon Lee <jonlee@apple.com>
946 Build fix for r169006.
950 * loader/ResourceLoader.h: Return didCreateQuickLookHandle() to public.
952 2014-05-18 Antti Koivisto <antti@apple.com>
954 REGRESSION (r160259): text-combine glyphs are not rendered
955 https://bugs.webkit.org/show_bug.cgi?id=127324
957 Reviewed by Andreas Kling.
959 The original text gets overwritten by a change that is supposed to affect rendered text only.
960 Fixed by giving the text update functions well-defined purposes.
962 Test: fast/text/text-combine-rendering.html
964 * rendering/RenderCombineText.cpp:
965 (WebCore::RenderCombineText::styleDidChange):
966 (WebCore::RenderCombineText::setRenderedText):
967 (WebCore::RenderCombineText::combineText):
968 (WebCore::RenderCombineText::setTextInternal): Deleted.
969 * rendering/RenderCombineText.h:
970 * rendering/RenderCounter.cpp:
971 (WebCore::RenderCounter::computePreferredLogicalWidths):
972 * rendering/RenderText.cpp:
973 (WebCore::RenderText::setRenderedText):
975 This function now updates the rendered text but does not change the original.
976 Get the original text by calling originalText().
978 (WebCore::RenderText::setText):
980 This the only place original text now changes.
982 (WebCore::RenderText::setTextInternal): Deleted.
984 Renamed to setRenderedText.
986 * rendering/RenderText.h:
987 * rendering/svg/RenderSVGInlineText.cpp:
988 (WebCore::RenderSVGInlineText::setRenderedText):
989 (WebCore::RenderSVGInlineText::setTextInternal): Deleted.
990 * rendering/svg/RenderSVGInlineText.h:
992 2014-05-17 Maciej Stachowiak <mjs@apple.com>
994 Don't attempt to update id or name for nodes that are already removed
995 https://bugs.webkit.org/show_bug.cgi?id=133041
997 Reviewed by Sam Weinig.
999 Tests: fast/dom/remove-element-with-id-that-was-inserted-on-DOMNodeRemoved.html
1000 fast/dom/remove-element-with-name-that-was-inserted-on-DOMNodeRemoved.html
1003 (WebCore::Element::removedFrom): Skip updating ids and names for an element not
1004 in a treescope, as we already do for elements not in a document.
1006 2014-05-17 Alexey Proskuryakov <ap@apple.com>
1008 REGRESSION (NetworkProcess): Trying to use appcache fallback crashes in ApplicationCacheHost::scheduleLoadFallbackResourceFromApplicationCache
1009 https://bugs.webkit.org/show_bug.cgi?id=133007
1010 <rdar://problem/13702706>
1012 appcache tests often fail on the Mac WebKit2 bot
1013 https://bugs.webkit.org/show_bug.cgi?id=82061
1015 Reviewed by Maciej Stachowiak.
1017 Covered by existing tests, which this patch enables.
1019 * WebCore.exp.in: Export ResourceLoader::cancel(const ResourceError&). It used
1020 to be virtual, but marking subclasses final has resulted in the compiler calling
1021 it directly from WebKitLegacy framework. Seeing that no subclass overrides it,
1022 I then made it non-virtual.
1023 Also export ApplicationCacheHost functions that are now used from WebKit2.
1025 * loader/ResourceLoader.h: Made the class abstract (as I didn't realize at first
1026 that it's always either a SubresourceLoader or a NetscapePlugInStreamLoader).
1027 Made ResourceHandleClient functions private, as they should never be called other
1028 than via a ResourceHandleClient pointer.
1030 * loader/NetscapePlugInStreamLoader.h:
1031 * loader/SubresourceLoader.h:
1034 * loader/ResourceLoader.cpp: (WebCore::ResourceLoader::willSwitchToSubstituteResource):
1035 Added a function to be called when switching to a substitute resource. We still
1036 need a ResourceLoader at this point, as substitute resource will be delivered through
1037 it, but we don't want it to continue its current load.
1039 * loader/appcache/ApplicationCacheHost.cpp:
1040 (WebCore::ApplicationCacheHost::scheduleLoadFallbackResourceFromApplicationCache):
1041 Call the ResourceLoader function instead of using handle, which is null when
1042 using out of process networking.
1044 2014-05-17 Andreas Kling <akling@apple.com>
1046 We shouldn't make a ScrollingThread on iOS.
1047 <https://webkit.org/b/133038>
1048 <rdar://problem/16947589>
1050 Don't call ScrollingThred::dispatch() from the pressure relief
1051 code on iOS since that will end up instantiating a scrolling thread
1052 which we'd otherwise never have.
1054 Reviewed by Sam Weinig.
1056 * platform/MemoryPressureHandler.cpp:
1057 (WebCore::MemoryPressureHandler::releaseMemory):
1059 2014-05-17 Piotr Grad <p.grad@samsung.com>
1061 Setting playback rate on video with media controller is not ignored.
1062 https://bugs.webkit.org/show_bug.cgi?id=129048
1064 Reviewed by Jer Noble.
1066 Replaced queries for m_playbackRate with effectivePlaybackRate()
1067 which includes media controller playback rate.
1069 Test: media/video-controller-child-rate.html
1071 * html/HTMLMediaElement.cpp:
1072 (WebCore::HTMLMediaElement::parseAttribute):
1073 * html/HTMLMediaElement.h:
1075 2014-05-16 Anders Carlsson <andersca@apple.com>
1077 Expose WKUserScript as API
1078 https://bugs.webkit.org/show_bug.cgi?id=133017
1079 <rdar://problem/16948059>
1081 Reviewed by Sam Weinig.
1086 * WebCore.xcodeproj/project.pbxproj:
1087 Change UserContentController.h to be a private header.
1090 (WebCore::Page::Page):
1091 Set m_userContentController from the page configuration and add it if it's not null.
1094 Add UserContentController to PageClients.
1096 * page/PageGroup.cpp:
1097 (WebCore::PageGroup::addPage):
1098 Only try to add a user content controller if the page doesn't already have one.
1100 (WebCore::PageGroup::removePage):
1101 Only try to remove the user content controller if it's the group one.
1103 2014-05-17 Andreas Kling <akling@apple.com>
1105 REGRESSION (r166422): All RenderBox objects grew 104 bytes from adding repaint timers.
1106 <https://webkit.org/b/133027>
1107 <rdar://problem/16867410>
1109 Instead of storing a rarely-used repaint timer on every RenderBox, store one
1110 on the RenderView, and keep a hash set of renderers needing repaint.
1112 Renderers get a flag tracking whether they have a pending lazy repaint.
1113 This way we can avoid hash lookups in the common case.
1115 Also added a static assertion to catch RenderBox growing in the future.
1117 Reviewed by Antti Koivisto.
1119 * rendering/RenderBox.cpp:
1120 (WebCore::SameSizeAsRenderBox::~SameSizeAsRenderBox):
1121 (WebCore::RenderBox::RenderBox):
1122 (WebCore::RenderBox::~RenderBox):
1123 (WebCore::RenderBox::paintBoxDecorations):
1124 (WebCore::RenderBox::layoutOverflowRectForPropagation):
1125 * rendering/RenderBox.h:
1126 * rendering/RenderElement.cpp:
1127 (WebCore::RenderElement::RenderElement):
1128 * rendering/RenderElement.h:
1129 (WebCore::RenderElement::setRenderBoxNeedsLazyRepaint):
1130 (WebCore::RenderElement::renderBoxNeedsLazyRepaint):
1131 * rendering/RenderView.cpp:
1132 (WebCore::RenderView::RenderView):
1133 (WebCore::RenderView::scheduleLazyRepaint):
1134 (WebCore::RenderView::unscheduleLazyRepaint):
1135 (WebCore::RenderView::lazyRepaintTimerFired):
1136 * rendering/RenderView.h:
1138 2014-05-16 Jer Noble <jer.noble@apple.com>
1140 [Mac][MSE] setCurrentTime() goes down fastSeek path in MediaPlayerPrivateMediaSourceAVFObjC.
1141 https://bugs.webkit.org/show_bug.cgi?id=133023
1143 Reviewed by Eric Carlson.
1145 When seeking a MSE video, do not go down the fastSeekForMediaTime() path if the
1146 seek resulted from a setCurrentTime() call. The logic can lead to attempted seeks
1147 before buffered ranges.
1149 * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1150 (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
1151 * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h:
1152 * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
1153 (WebCore::MediaSourcePrivateAVFObjC::seekToTime):
1155 2014-05-16 Benjamin Poulain <bpoulain@apple.com>
1157 [iOS] ScrollView::visibleContentRectInternal is bypassing the iOS code for unobscuredContentRect
1158 https://bugs.webkit.org/show_bug.cgi?id=133008
1160 Reviewed by Simon Fraser.
1162 * platform/ScrollView.cpp:
1163 (WebCore::ScrollView::visibleContentRectInternal):
1164 ScrollView::visibleContentRectInternal() was calling the internal implementation of visibleContentRect().
1165 That was skipping the iOS implementation and getting the framerect directly. That size is invalid on iOS
1166 when the exposed rect and unobscured rect are not the same.
1168 2014-05-16 Jer Noble <jer.noble@apple.com>
1170 [Mac] naturalSize not updated when preload=metadata
1171 https://bugs.webkit.org/show_bug.cgi?id=132994
1173 Reviewed by Eric Carlson.
1175 Test: media/video-load-preload-metadata-naturalsize.html
1177 When preload=metadata, we never create an AVPlayerItem, and therefore never receive a
1178 presentationSize KVO. When an AVAsset informs us that its tracks have changed, and there
1179 is no AVPlayerItem, recalculate presentation size based on the first video track's natural
1182 * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1183 (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged):
1184 * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
1185 (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal):
1187 2014-05-16 Simon Fraser <simon.fraser@apple.com>
1189 Remove "region-based columns" prefs
1190 https://bugs.webkit.org/show_bug.cgi?id=133006
1191 <rdar://problem/16945824>
1193 Reviewed by Dave Hyatt.
1195 Remove "region-based columns" prefs and related code, since this is only
1196 way to render columns now.
1200 2014-05-16 Antti Koivisto <antti@apple.com>
1202 Link search area for touch events is too large in some cases
1203 https://bugs.webkit.org/show_bug.cgi?id=132988
1204 <rdar://problem/16917843>
1206 Reviewed by Simon Fraser.
1208 * page/ios/FrameIOS.mm:
1209 (WebCore::Frame::qualifyingNodeAtViewportLocation):
1211 - Adjust the search area to screen ppi.
1212 - Remove cut-off at scale 1. This made us pick physically far-away elements when zoomed in.
1214 * platform/PlatformScreen.h:
1215 * platform/ios/PlatformScreenIOS.mm:
1216 (WebCore::mobileGestaltFloatValue):
1217 (WebCore::screenPPIFactor):
1219 Figure out screens physical PPI relative to a base.
1221 2014-05-16 Jer Noble <jer.noble@apple.com>
1223 [MSE] Crash at WebCore::SourceBuffer::~SourceBuffer + 110
1224 https://bugs.webkit.org/show_bug.cgi?id=132973
1226 Reviewed by Eric Carlson.
1228 Change SourceBuffer::m_private into a Ref<>, and add an assertion to
1229 SourceBufferPrivateAVFObjC's destructor if its client has not been cleared.
1231 Eliminate unnecessary churn in MediaSourcePrivateAVFObjC by having the predicate
1232 functor take bare pointers, rather than a PassRefPtr.
1234 The underlying problem seems to be in WebAVStreamDataParserListener. RefPtrs were
1235 being created off the main thread to a non-thread safe ref counted class. In some
1236 situations, this would result in double decrementing the ref, which would cause an
1237 early destruction of the underlying object. Instead replace these RefPtr strong
1238 pointers with explicit weak ones. Ensure the parser and its delegate are not freed
1239 before the append operation completes by passing strong pointers into the async
1240 append operation lambda.
1242 There were a few places where we weren't null checking m_mediaSource before using it,
1243 and at least one place where we weren't clearing m_mediaSource.
1245 * Modules/mediasource/SourceBuffer.cpp:
1246 (WebCore::SourceBuffer::SourceBuffer): Use Ref instead of RefPtr.
1247 (WebCore::SourceBuffer::appendBufferTimerFired): Ditto.
1248 * Modules/mediasource/SourceBuffer.h:
1249 * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
1250 (WebCore::MediaSourcePrivateAVFObjCHasAudio): Take a bare pointer, instead of a PassRefPtr.
1251 (WebCore::MediaSourcePrivateAVFObjCHasVideo): Ditto.
1252 * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm:
1253 (WebCore::MediaSourcePrivateAVFObjC::removeSourceBuffer): Clear the back pointer when removing a buffer.
1254 * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h:
1255 * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
1256 (-[WebAVStreamDataParserListener initWithParser:parent:WebCore::]): Use WeakPtr instead of RefPtr.
1257 (-[WebAVStreamDataParserListener invalidate]): Ditto.
1258 (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:]): Ditto.
1259 (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:withDiscontinuity:]): Ditto.
1260 (-[WebAVStreamDataParserListener streamDataParser:didFailToParseStreamDataWithError:]): Ditto.
1261 (-[WebAVStreamDataParserListener streamDataParser:didProvideMediaData:forTrackID:mediaType:flags:]): Ditto.
1262 (-[WebAVStreamDataParserListener streamDataParser:didReachEndOfTrackWithTrackID:mediaType:]): Ditto.
1263 (-[WebAVStreamDataParserListener streamDataParser:didProvideContentKeyRequestInitializationData:forTrackID:]): Ditto.
1264 (WebCore::SourceBufferPrivateAVFObjC::~SourceBufferPrivateAVFObjC):
1265 (WebCore::SourceBufferPrivateAVFObjC::append): Ditto.
1267 2014-05-16 Zalan Bujtas <zalan@apple.com>
1269 Subpixel rendering: Push named flows in region to device pixel when painting.
1270 https://bugs.webkit.org/show_bug.cgi?id=132986
1272 Reviewed by Simon Fraser.
1274 Remove integral rounding when named flow sets the painting offset on the graphics context.
1275 Use device pixel snapping instead to ensure that we can paint on odd device pixel positions on retina displays.
1277 Test: fast/regions/hidpi-region-with-auto-margin-on-subpixel-position.html
1279 * rendering/RenderLayer.cpp:
1280 (WebCore::RenderLayer::calculateClipRects):
1282 2014-05-16 Radu Stavila <stavila@adobe.com>
1284 [CSS Regions] Add ASSERT to make sure using the flowThread cache does not return incorrect results
1285 https://bugs.webkit.org/show_bug.cgi?id=132906
1287 Reviewed by Simon Fraser.
1289 If flowThreadContainingBlock() is called on an object which is in a different
1290 flow thread than the one currently being laid out, this method will return an incorrect
1291 result. I added an assertion for that to make sure we catch and treat any such scenarios.
1292 For the moment, this assertion is only validated for regions, as multicol still has some issues.
1294 No new tests required.
1296 * rendering/RenderObject.cpp:
1297 (WebCore::RenderObject::locateFlowThreadContainingBlockNoCache):
1298 (WebCore::RenderObject::locateFlowThreadContainingBlock):
1299 * rendering/RenderObject.h:
1301 2014-05-16 Martin Hock <mhock@apple.com>
1303 MemoryCache::addImageToCache should return the result of add().
1304 https://bugs.webkit.org/show_bug.cgi?id=132928
1305 <rdar://problem/16651547>
1307 Reviewed by Alexey Proskuryakov.
1309 API test: WebKit1.MemoryCacheADdImageToCache (MemoryCacheAddImageToCacheIOS.mm)
1311 * loader/cache/MemoryCache.cpp:
1312 (WebCore::MemoryCache::addImageToCache):
1314 2014-05-16 Andrei Bucur <abucur@adobe.com>
1316 [CSS Regions] Reduce the RenderRegion invasiveness in rendering code
1317 https://bugs.webkit.org/show_bug.cgi?id=132121
1319 Reviewed by Antti Koivisto.
1321 Remove the RenderRegion / RenderNamedFlowFragment parameters and fields from
1322 the painting / hit testing data structures and use a stateful approach to
1323 correctly handle regions.
1325 When painting or hit testing, the current flow thread is saved along the current
1326 region. They are accessed through the |currentRenderNamedFlowFragment| helper
1327 method on RenderObject or RenderLayer.
1329 The patch also changes a bunch of 0s to nullptrs.
1331 Tests: No new tests, no functional change.
1333 * html/shadow/MediaControlElements.cpp:
1334 (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
1335 * rendering/HitTestLocation.cpp:
1336 (WebCore::HitTestLocation::HitTestLocation):
1337 (WebCore::HitTestLocation::operator=):
1338 * rendering/HitTestLocation.h:
1339 (WebCore::HitTestLocation::region): Deleted.
1340 * rendering/HitTestResult.h:
1341 * rendering/PaintInfo.h:
1342 (WebCore::PaintInfo::PaintInfo):
1343 * rendering/RenderBlock.cpp:
1344 (WebCore::RenderBlock::paint):
1345 (WebCore::RenderBlock::paintObject):
1346 (WebCore::RenderBlock::selectionGaps):
1347 (WebCore::RenderBlock::nodeAtPoint):
1348 * rendering/RenderBox.cpp:
1349 (WebCore::RenderBox::nodeAtPoint):
1350 (WebCore::RenderBox::paintBoxDecorations):
1351 (WebCore::RenderBox::pushContentsClip):
1352 * rendering/RenderBoxModelObject.cpp:
1353 (WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
1354 (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1355 * rendering/RenderBoxModelObject.h:
1356 * rendering/RenderLayer.cpp:
1357 (WebCore::RenderLayer::paint):
1358 (WebCore::RenderLayer::paintLayer):
1359 (WebCore::RenderLayer::paintLayerContents):
1360 (WebCore::RenderLayer::paintLayerByApplyingTransform):
1361 (WebCore::RenderLayer::collectFragments):
1362 (WebCore::RenderLayer::updatePaintingInfoForFragments):
1363 (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
1364 (WebCore::RenderLayer::paintBackgroundForFragments):
1365 (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
1366 (WebCore::RenderLayer::paintOutlineForFragments):
1367 (WebCore::RenderLayer::paintMaskForFragments):
1368 (WebCore::RenderLayer::hitTest):
1369 (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
1370 (WebCore::RenderLayer::hitTestLayer):
1371 (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
1372 (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
1373 (WebCore::RenderLayer::calculateClipRects):
1374 * rendering/RenderLayer.h:
1375 * rendering/RenderLayerBacking.cpp:
1376 (WebCore::RenderLayerBacking::updateCompositedBounds):
1377 (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1378 * rendering/RenderLayerCompositor.cpp:
1379 (WebCore::RenderLayerCompositor::addToOverlapMap):
1380 (WebCore::RenderLayerCompositor::clippedByAncestor):
1381 * rendering/RenderObject.cpp:
1382 (WebCore::RenderObject::currentRenderNamedFlowFragment):
1383 * rendering/RenderObject.h:
1384 * rendering/RenderReplaced.cpp:
1385 (WebCore::RenderReplaced::shouldPaint):
1386 * rendering/RenderReplica.cpp:
1387 (WebCore::RenderReplica::paint):
1388 * rendering/RenderTable.cpp:
1389 (WebCore::RenderTable::nodeAtPoint):
1390 * rendering/RenderTableSection.cpp:
1391 (WebCore::RenderTableSection::nodeAtPoint):
1392 * rendering/RenderTreeAsText.cpp:
1393 (WebCore::writeLayers):
1394 * rendering/RootInlineBox.cpp:
1395 (WebCore::RootInlineBox::paint):
1396 * rendering/svg/RenderSVGRoot.cpp:
1397 (WebCore::RenderSVGRoot::paintReplaced):
1399 2014-05-16 Kiran <kiran.guduru@samsung.com>
1401 RTCDtmfSender default values need to be updated.
1402 https://bugs.webkit.org/show_bug.cgi?id=132952
1404 Reviewed by Eric Carlson.
1406 The default ToneDuration and ToneGap values are modified in the updated spec.
1407 So these values need to be updated.
1409 Test: fast/mediastream/RTCPeerConnection-dtmf.html.
1411 * Modules/mediastream/RTCDTMFSender.cpp:
1413 2014-05-15 Daniel Bates <dabates@apple.com>
1415 Attempt to fix the Apple Mavericks Release, Apple MountainLion Release,
1416 Apple MountainLion Release (32-bit Build), EFL, and GTK builds following
1417 <http://trac.webkit.org/changeset/168921> (https://bugs.webkit.org/show_bug.cgi?id=132669)
1419 * dom/ContainerNode.cpp: Include SVGElement.h for the definition of Node::hasTagName(const SVGQualifiedName&).
1421 2014-05-15 Daniel Bates <dabates@apple.com>
1423 ASSERT_NOT_REACHED() in DocumentOrderedMap::get() when removing SVG subtree
1424 https://bugs.webkit.org/show_bug.cgi?id=132669
1425 <rdar://problem/14931432>
1427 Reviewed by Brent Fulgham and Ryosuke Niwa.
1429 Fixes an assertion failure when removing an SVG element with a duplicate id.
1431 When removing an SVG element with id A we synchronously instruct each element that references A
1432 to find the first element with id A, call this N, from the document root and register itself to
1433 either receive subsequent notifications from N (say, there is another element with id A) or as
1434 waiting for an element with id A (say, N = nullptr; => we removed the last element with id A from
1435 the document). Because the elements that reference A perform this operation synchronously when
1436 removing an element they consult an transient state of the DocumentOrderedMap when querying for the
1439 Without loss of generality, let E, E_1, E_2, and E_3 be elements, where E_1, E_2, E_3 are children
1440 of E in that order and E_1.id = E_2.id = A and E_3.href = #A (that is, it references an element
1441 with id A). Suppose we remove E then we remove E_1, update DocumentOrderedMap to decrement its count
1442 for id A, and notify E_3 to look for an element with id A. This leads to an assertion failure since
1443 DocumentOrderedMap expects to find an element with id A, E_2, but cannot find such an element when
1444 traversing from the document root because E was unlinked from the document root (i.e. E_2 is in a
1447 Tests: svg/custom/change-id-of-use-during-removal.html
1448 svg/custom/remove-subtree-including-path-with-duplicate-id-referenced-by-later-textpath.html
1449 svg/custom/remove-subtree-including-text-with-duplicate-id-referenced-by-later-tref.html
1450 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-earlier-use.html
1451 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-animate.html
1452 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-feimage.html
1453 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-mpath.html
1454 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-use.html
1455 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-later-use2.html
1456 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-use-in-different-subtree.html
1457 svg/custom/remove-subtree-including-use-with-duplicate-id-referenced-by-use-with-duplicate-id-in-different-subtree.html
1458 svg/custom/remove-use-with-duplicate-id-referenced-by-later-use.html
1460 * dom/ContainerNode.cpp:
1461 (WebCore::ContainerNode::removeChild): Call SVGDocumentExtensions::rebuildElements() after we remove
1462 a DOM subtree so that applicable SVG elements can update their referenced element when the DocumentOrderedMap
1463 is in a stable-state.
1464 (WebCore::ContainerNode::removeChildren): Ditto.
1465 * svg/SVGDocumentExtensions.cpp:
1466 (WebCore::SVGDocumentExtensions::rebuildElements): Added; notifies SVG elements that their href attribute
1467 changed so that they query the DocumentOrderedMap for the element they reference by id in their href attribute.
1468 (WebCore::SVGDocumentExtensions::clearTargetDependencies): Added; Called from removing
1469 an SVG element S from the DOM. Appends all elements that reference the id of S to the end of a Vector of
1470 elements to be rebuilt (when SVGDocumentExtensions::rebuildElements() is called) and notifies these elements
1471 that have been marked to be rebuilt so that they can invalidate their state (e.g. stop animating).
1472 (WebCore::SVGDocumentExtensions::rebuildAllElementReferencesForTarget): Changed to take its argument by reference
1473 (since it's always non-null) and simplified logic to synchronously notify SVG updates that their referenced element
1474 may have changed. Calling SVGElement::svgAttributeChanged() on an element E should at most remove the dependencies
1476 * svg/SVGDocumentExtensions.h:
1477 * svg/SVGElement.cpp:
1478 (WebCore::SVGElement::~SVGElement): Substitute "*this" for "this" as SVGDocumentExtensions::rebuildAllElementReferencesForTarget()
1479 now takes a reference instead of a pointer.
1480 (WebCore::SVGElement::removedFrom): Modified to call SVGDocumentExtensions::clearTargetDependencies().
1481 (WebCore::SVGElement::attributeChanged): Substitute "*this" for "this" as SVGDocumentExtensions::rebuildAllElementReferencesForTarget()
1482 now takes a reference instead of a pointer.
1484 (WebCore::SVGElement::callClearTarget): Added; calls through to private virtual SVGElement::clearTarget().
1485 (WebCore::SVGElement::clearTarget): Added.
1486 * svg/SVGTRefElement.cpp:
1487 (WebCore::SVGTRefElement::clearTarget): Added.
1488 * svg/SVGTRefElement.h:
1489 * svg/animation/SVGSMILElement.cpp:
1490 (WebCore::SVGSMILElement::clearTarget): Added.
1491 * svg/animation/SVGSMILElement.h:
1493 2014-05-15 Simon Fraser <simon.fraser@apple.com>
1495 [iOS WK2] When zoomed, fixed elements jump at the start of a scroll, and jump back at the end.
1496 https://bugs.webkit.org/show_bug.cgi?id=132978
1497 <rdar://problem/16894428>
1499 Reviewed by Benjamin Poulain.
1501 This was the actual cause of the bug; r168560 changed the rect passed in here
1502 to be the customFixedPositionRect rather than the unobscured rect, but we
1503 used it to call FrameView::rectForViewportConstrainedObjects() which gave back
1504 another bogus rect. So just use the rect passed in.
1506 * page/scrolling/ios/ScrollingTreeScrollingNodeIOS.mm:
1507 (WebCore::ScrollingTreeScrollingNodeIOS::updateLayersAfterViewportChange):
1509 2014-05-15 Daniel Bates <dabates@apple.com>
1511 SVG element may reference arbitrary DOM element before running its insertion logic
1512 https://bugs.webkit.org/show_bug.cgi?id=132757
1513 <rdar://problem/15703817>
1515 Reviewed by Ryosuke Niwa.
1517 Fixes an issue where an SVG element may reference an arbitrary DOM element e before e finished being
1518 inserted in the tree.
1520 Currently when an SVG element A is inserted into a document we use document.getElementById() to find the
1521 element B it references (if any). If A is inserted before B and B has the same id as a later element in
1522 the document then A can find B before B is notified that its been inserted into the document (i.e. before
1523 Element::insertedFrom() is called on B). Instead, A should call document.getElementById() only after
1524 cessation of the insertion operation that inserted it to ensure that all inserted nodes (including B)
1525 processed their insertion-specific logic.
1527 Tests: svg/custom/reparent-animate-element.html
1528 svg/custom/reparent-feimage-element.html
1529 svg/custom/reparent-mpath-element.html
1530 svg/custom/reparent-textpath-element.html
1531 svg/custom/reparent-tref-element.html
1532 svg/custom/reparent-use-element.html
1534 * svg/SVGFEImageElement.cpp:
1535 (WebCore::SVGFEImageElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
1536 we are called back to resolve our target element (i.e. call SVGFEImageElement::buildPendingResources())
1537 after the subtree we're in is inserted.
1538 (WebCore::SVGFEImageElement::didNotifySubtreeInsertions): Added; turns around and calls SVGFEImageElement::buildPendingResources().
1539 * svg/SVGFEImageElement.h:
1540 * svg/SVGMPathElement.cpp:
1541 (WebCore::SVGMPathElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
1542 we are called back to resolve our target element (i.e. call SVGMPathElement::buildPendingResources())
1543 after the subtree we're in is inserted.
1544 (WebCore::SVGMPathElement::didNotifySubtreeInsertions): Added; turns around and calls SVGMPathElement::buildPendingResources().
1545 * svg/SVGMPathElement.h:
1546 * svg/SVGTRefElement.cpp:
1547 (WebCore::SVGTRefElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
1548 we are called back to resolve our target element (i.e. call SVGTRefElement::buildPendingResources())
1549 after the subtree we're in is inserted.
1550 (WebCore::SVGTRefElement::didNotifySubtreeInsertions): Added; turns around and calls SVGTRefElement::buildPendingResources().
1551 * svg/SVGTRefElement.h:
1552 * svg/SVGTextPathElement.cpp:
1553 (WebCore::SVGTextPathElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
1554 we are called back to resolve our target element (i.e. call SVGTextPathElement::buildPendingResources())
1555 after the subtree we're in is inserted.
1556 (WebCore::SVGTextPathElement::didNotifySubtreeInsertions): Added; turns around and calls SVGTextPathElement::buildPendingResources().
1557 * svg/SVGTextPathElement.h:
1558 * svg/SVGUseElement.cpp:
1559 (WebCore::SVGUseElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
1560 we are called back to resolve our target element (i.e. call SVGUseElement::buildPendingResources()) after its subtree is
1562 (WebCore::SVGUseElement::didNotifySubtreeInsertions): Added; turns around and calls SVGUseElement::buildPendingResources().
1563 * svg/SVGUseElement.h:
1564 * svg/animation/SVGSMILElement.cpp:
1565 (WebCore::SVGSMILElement::insertedInto): Return InsertionShouldCallDidNotifySubtreeInsertions so that
1566 we are called back to resolve our target element (i.e. call SVGSMILElement::buildPendingResources())
1567 after the subtree we're in is inserted.
1568 (WebCore::SVGSMILElement::didNotifySubtreeInsertions): Added; turns around and calls SVGSMILElement::buildPendingResources().
1569 * svg/animation/SVGSMILElement.h:
1571 2014-05-15 Mark Hahnenberg <mhahnenberg@apple.com>
1573 JSDOMWindow should not claim HasImpureGetOwnPropertySlot
1574 https://bugs.webkit.org/show_bug.cgi?id=132918
1576 Reviewed by Geoffrey Garen.
1578 Tests: js/cached-window-properties.html
1579 js/cached-window-prototype-properties.html
1581 We now correctly handle the impurity of JSDOMWindow's custom getOwnPropertySlot without needing the
1582 blanket HasImpureGetOwnPropertySlot. We do this through the use of watchpoints and by explicitly forbidding
1583 any caching beyond a certain point using PropertySlot::disableCaching. Getting rid of this flag will allow
1584 us to cache many properties/methods on both the JSDOMWindow and its prototype, which are very commonly used
1587 * bindings/js/JSDOMWindowCustom.cpp:
1588 (WebCore::JSDOMWindow::getOwnPropertySlot):
1589 * bindings/scripts/CodeGeneratorJS.pm:
1590 (HasComplexGetOwnProperty):
1591 (InterfaceRequiresAttributesOnInstance):
1592 (InstanceOverridesGetOwnPropertySlot):
1595 2014-05-15 Alexey Proskuryakov <ap@apple.com>
1597 NetworkProcess crashes at ResourceHandle::continueDidReceiveResponse
1598 https://bugs.webkit.org/show_bug.cgi?id=132966
1599 <rdar://problem/16373694>
1601 Reviewed by Brady Eidson.
1603 Covered by many fast/files tests.
1605 * platform/network/BlobResourceHandle.cpp: (WebCore::BlobResourceHandle::continueDidReceiveResponse):
1606 * platform/network/BlobResourceHandle.h:
1607 * platform/network/ResourceHandle.h:
1608 Don't call delegate's continueDidReceiveResponse when loading a blob:// URL,
1609 the delegate is null. On the Mac, we used to lazily create it, which was also wrong,
1610 but at least not observable.
1612 2014-05-15 Commit Queue <commit-queue@webkit.org>
1614 Unreviewed, rolling out r168899.
1615 https://bugs.webkit.org/show_bug.cgi?id=132965
1617 Broke some compositing regions tests on Mavericks (Requested
1618 by mihnea___ on #webkit).
1622 "[CSS Regions] Reduce the RenderRegion invasiveness in
1624 https://bugs.webkit.org/show_bug.cgi?id=132121
1625 http://trac.webkit.org/changeset/168899
1627 2014-05-15 Alex Christensen <achristensen@webkit.org>
1629 Add pointer lock to features without enabling it.
1630 https://bugs.webkit.org/show_bug.cgi?id=132961
1632 Reviewed by Sam Weinig.
1634 * Configurations/FeatureDefines.xcconfig:
1635 Added ENABLE_POINTER_LOCK to list of features.
1637 Added linker symbols which differ with pointer lock enabled.
1638 * WebCore.xcodeproj/project.pbxproj:
1639 Added PointerLockController.cpp to build.
1641 2014-05-15 Mark Hahnenberg <mhahnenberg@apple.com>
1643 Move subframe name getter lookup later in JSDOMWindow::getOwnPropertySlot
1644 https://bugs.webkit.org/show_bug.cgi?id=132922
1646 Reviewed by Geoffrey Garen.
1650 In JSDOMWindow::getOwnPropertySlot, we currently look for the property on the JSDOMWindow,
1651 then we search the window's subframes for name getters, then we look in the window's prototype
1652 chain. Apparently we were doing the lookup in this order to be compatible with Mozilla, but
1653 Mozilla no longer implements this behavior. Instead, they do the lookup on the prototype before
1654 looking for subframe name getters. We should change this to match Mozilla. This has the convenient
1655 side effect of allowing us to cache lookups in the window's prototype chain.
1657 * bindings/js/JSDOMWindowCustom.cpp:
1658 (WebCore::JSDOMWindow::getOwnPropertySlot):
1660 2014-05-15 Simon Fraser <simon.fraser@apple.com>
1662 [UI-side compositing] Fix copying animations between layers, and pausing them
1663 https://bugs.webkit.org/show_bug.cgi?id=132943
1664 <rdar://problem/16906369&16906541>
1666 Reviewed by Tim Horton.
1668 Pass the animation key back to animationStarted(), though this isn't used
1669 when animations are running in-process.
1671 * platform/graphics/ca/PlatformCALayer.h:
1672 * platform/graphics/ca/mac/PlatformCALayerMac.h:
1673 * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1674 (-[WebAnimationDelegate animationDidStart:]):
1675 (PlatformCALayerMac::animationStarted):
1676 * platform/graphics/ca/win/PlatformCALayerWin.cpp:
1677 (PlatformCALayerWin::animationStarted):
1678 * platform/graphics/ca/win/PlatformCALayerWin.h:
1680 2014-05-15 Andrei Bucur <abucur@adobe.com>
1682 [CSS Regions] Reduce the RenderRegion invasiveness in rendering code
1683 https://bugs.webkit.org/show_bug.cgi?id=132121
1685 Reviewed by Antti Koivisto.
1687 Remove the RenderRegion / RenderNamedFlowFragment parameters and fields from
1688 the painting / hit testing data structures and use a stateful approach to
1689 correctly handle regions.
1691 When painting or hit testing, the current flow thread is saved along the current
1692 region. They are accessed through the |currentRenderNamedFlowFragment| helper
1693 method on RenderObject or RenderLayer.
1695 The patch also changes a bunch of 0s to nullptrs.
1697 Tests: No new tests, no functional change.
1699 * html/shadow/MediaControlElements.cpp:
1700 (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
1701 * rendering/HitTestLocation.cpp:
1702 (WebCore::HitTestLocation::HitTestLocation):
1703 (WebCore::HitTestLocation::operator=):
1704 * rendering/HitTestLocation.h:
1705 (WebCore::HitTestLocation::region): Deleted.
1706 * rendering/HitTestResult.h:
1707 * rendering/PaintInfo.h:
1708 (WebCore::PaintInfo::PaintInfo):
1709 * rendering/RenderBlock.cpp:
1710 (WebCore::RenderBlock::paint):
1711 (WebCore::RenderBlock::paintObject):
1712 (WebCore::RenderBlock::selectionGaps):
1713 (WebCore::RenderBlock::nodeAtPoint):
1714 * rendering/RenderBox.cpp:
1715 (WebCore::RenderBox::nodeAtPoint):
1716 (WebCore::RenderBox::paintBoxDecorations):
1717 (WebCore::RenderBox::pushContentsClip):
1718 * rendering/RenderBoxModelObject.cpp:
1719 (WebCore::RenderBoxModelObject::paintMaskForTextFillBox):
1720 (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1721 * rendering/RenderBoxModelObject.h:
1722 * rendering/RenderLayer.cpp:
1723 (WebCore::RenderLayer::paint):
1724 (WebCore::RenderLayer::paintLayer):
1725 (WebCore::RenderLayer::paintLayerContents):
1726 (WebCore::RenderLayer::paintLayerByApplyingTransform):
1727 (WebCore::RenderLayer::collectFragments):
1728 (WebCore::RenderLayer::updatePaintingInfoForFragments):
1729 (WebCore::RenderLayer::paintTransformedLayerIntoFragments):
1730 (WebCore::RenderLayer::paintBackgroundForFragments):
1731 (WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
1732 (WebCore::RenderLayer::paintOutlineForFragments):
1733 (WebCore::RenderLayer::paintMaskForFragments):
1734 (WebCore::RenderLayer::hitTest):
1735 (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
1736 (WebCore::RenderLayer::hitTestLayer):
1737 (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
1738 (WebCore::RenderLayer::mapLayerClipRectsToFragmentationLayer):
1739 (WebCore::RenderLayer::calculateClipRects):
1740 * rendering/RenderLayer.h:
1741 * rendering/RenderLayerBacking.cpp:
1742 (WebCore::RenderLayerBacking::updateCompositedBounds):
1743 (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1744 * rendering/RenderLayerCompositor.cpp:
1745 (WebCore::RenderLayerCompositor::addToOverlapMap):
1746 (WebCore::RenderLayerCompositor::clippedByAncestor):
1747 * rendering/RenderObject.cpp:
1748 (WebCore::RenderObject::currentRenderNamedFlowFragment):
1749 * rendering/RenderObject.h:
1750 * rendering/RenderReplaced.cpp:
1751 (WebCore::RenderReplaced::shouldPaint):
1752 * rendering/RenderReplica.cpp:
1753 (WebCore::RenderReplica::paint):
1754 * rendering/RenderTable.cpp:
1755 (WebCore::RenderTable::nodeAtPoint):
1756 * rendering/RenderTableSection.cpp:
1757 (WebCore::RenderTableSection::nodeAtPoint):
1758 * rendering/RenderTreeAsText.cpp:
1759 (WebCore::writeLayers):
1760 * rendering/RootInlineBox.cpp:
1761 (WebCore::RootInlineBox::paint):
1762 * rendering/svg/RenderSVGRoot.cpp:
1763 (WebCore::RenderSVGRoot::paintReplaced):
1765 2014-05-14 Simon Fraser <simon.fraser@apple.com>
1767 Clean up "has non-zero begin time" terminology in animations
1768 https://bugs.webkit.org/show_bug.cgi?id=132942
1770 Reviewed by Tim Horton.
1772 Change the "non-zero beginTime" terminology in the platform CA animations
1773 code to "explicit beginTime": this flag really means that we explicitly set
1774 the beginTime of the animation, rather than let CA set the beginTime when
1775 committing the animation. This flag is used for animations with negative
1776 delay, and when pausing.
1778 The WKNonZeroBeginTimeFlag key was spread across PlatformCALayerMac and PlatformCAAnimationMac,
1779 so hide it behind getter/setter functions.
1781 Remove lots of m_layer.get() in PlatformCAAnimationMac.
1783 * platform/graphics/ca/mac/PlatformCAAnimationMac.h:
1784 * platform/graphics/ca/mac/PlatformCAAnimationMac.mm:
1785 (WebCore::hasExplicitBeginTime):
1786 (WebCore::setHasExplicitBeginTime):
1787 (PlatformCAAnimationMac::copy):
1788 (PlatformCAAnimationMac::keyPath):
1789 (PlatformCAAnimationMac::beginTime):
1790 (PlatformCAAnimationMac::setBeginTime):
1791 (PlatformCAAnimationMac::duration):
1792 (PlatformCAAnimationMac::setDuration):
1793 (PlatformCAAnimationMac::speed):
1794 (PlatformCAAnimationMac::setSpeed):
1795 (PlatformCAAnimationMac::timeOffset):
1796 (PlatformCAAnimationMac::setTimeOffset):
1797 (PlatformCAAnimationMac::repeatCount):
1798 (PlatformCAAnimationMac::setRepeatCount):
1799 (PlatformCAAnimationMac::autoreverses):
1800 (PlatformCAAnimationMac::setAutoreverses):
1801 (PlatformCAAnimationMac::fillMode):
1802 (PlatformCAAnimationMac::setFillMode):
1803 (PlatformCAAnimationMac::setTimingFunction):
1804 (PlatformCAAnimationMac::copyTimingFunctionFrom):
1805 (PlatformCAAnimationMac::isRemovedOnCompletion):
1806 (PlatformCAAnimationMac::setRemovedOnCompletion):
1807 (PlatformCAAnimationMac::isAdditive):
1808 (PlatformCAAnimationMac::setAdditive):
1809 (PlatformCAAnimationMac::valueFunction):
1810 (PlatformCAAnimationMac::setValueFunction):
1811 (hasNonZeroBeginTimeFlag): Deleted.
1812 (setNonZeroBeginTimeFlag): Deleted.
1813 * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1814 (-[WebAnimationDelegate animationDidStart:]):
1816 2014-05-15 Carlos Garcia Campos <cgarcia@igalia.com>
1818 [GTK] Compile all installed resources as GResources
1819 https://bugs.webkit.org/show_bug.cgi?id=131099
1821 Reviewed by Philippe Normand.
1823 * PlatformGTK.cmake: Do not install the resources.
1824 * platform/audio/gtk/AudioBusGtk.cpp:
1825 (WebCore::AudioBus::loadPlatformResource): Load the audio resource
1826 from GResources and use createBusFromInMemoryAudioFile().
1827 * platform/graphics/Image.h: Remove unsued function loadPlatformThemeIcon.
1828 * platform/graphics/gtk/ImageGtk.cpp:
1829 (WebCore::loadImageFromGResource): Load the given icon name from GResources.
1830 (WebCore::loadResourceSharedBuffer): Use char* instead of CString.
1831 (WebCore::loadMissingImageIconFromTheme): Try to load the missing
1832 icon from the current GTK icon theme.
1833 (WebCore::Image::loadPlatformResource): Call
1834 loadMissingImageIconFromTheme for missing icon or
1835 loadImageFromGResource for any other icon name.
1836 (WebCore::getPathToImageResource): Deleted.
1837 (WebCore::getThemeIconFileName): Deleted.
1838 (WebCore::loadImageFromFile): Deleted.
1839 (WebCore::Image::loadPlatformThemeIcon): Deleted.
1841 2014-05-14 Beth Dakin <bdakin@apple.com>
1843 Tiled scrolling indicator needs to take topContentInset into account
1844 https://bugs.webkit.org/show_bug.cgi?id=132940
1846 Reviewed by Simon Fraser.
1848 The tiled scrolling indicator needs to move down by the value of the
1849 topContentInset. This patch makes that happen by caching the topContentInset in
1850 the TileController. This does feel a little silly since there is already a
1851 function called setTiledScrollingIndicatorPosition() on TiledBacking. However, it
1852 was often the case that calling that function had no effect because m_coverageMap
1853 had not yet been created, and then the information was lost. So instead, we cache
1856 Set TiledBacking’s copy of topContentInset whenever it changes for the FrameView.
1857 * page/FrameView.cpp:
1858 (WebCore::FrameView::topContentInsetDidChange):
1860 New function to set the inset. Use the inset to position the coverage map.
1861 * platform/graphics/TiledBacking.h:
1862 * platform/graphics/ca/mac/TileController.h:
1863 * platform/graphics/ca/mac/TileController.mm:
1864 (WebCore::TileController::TileController):
1865 (WebCore::TileController::setTopContentInset):
1867 When the coverage map is created, consult the value of the inset.
1868 * platform/graphics/ca/mac/TileCoverageMap.mm:
1869 (WebCore::TileCoverageMap::TileCoverageMap):
1871 Once the backing has been ensured, set the inset.
1872 * rendering/RenderLayerCompositor.cpp:
1873 (WebCore::RenderLayerCompositor::updateBacking):
1875 2014-05-14 Brent Fulgham <bfulgham@apple.com>
1877 Merge r1267628 from branch.
1878 <rdar://problem/15751219>
1880 Pratik Solanki <psolanki@apple.com>
1882 Reviewed by Simon Fraser.",
1884 TileController relied on the tiling mode in TileCache to determine if it should use low-res
1885 tiles when zooming. Unfortunately, sometimes the tiling mode gets set to Zooming even though
1886 it's actually a pan. Thus we can end up with blurry tiles. Fix this by adding a new flag on
1887 TileCache that controls this behavior and have UIKit set it only when we have an actual zoom
1890 * platform/ios/LegacyTileCache.h:
1891 (WebCore::LegacyTileCache::tileControllerShouldUseLowScaleTiles):
1892 (WebCore::LegacyTileCache::setTileControllerShouldUseLowScaleTiles):
1893 * platform/ios/LegacyTileCache.mm:
1894 (WebCore::LegacyTileCache::LegacyTileCache):
1895 * platform/ios/wak/WAKWindow.h:
1896 * platform/ios/wak/WAKWindow.mm:
1897 (-[WAKWindow setTileControllerShouldUseLowScaleTiles:]):
1898 * rendering/RenderLayerCompositor.cpp:
1899 (WebCore::RenderLayerCompositor::contentsScaleMultiplierForNewTiles):
1901 2014-05-14 Commit Queue <commit-queue@webkit.org>
1903 Unreviewed, rolling out r168750.
1904 https://bugs.webkit.org/show_bug.cgi?id=132935
1906 Caused repaint bugs (Requested by weinig on #webkit).
1910 "Text decorations do not contribute to visual overflow"
1911 https://bugs.webkit.org/show_bug.cgi?id=132773
1912 http://trac.webkit.org/changeset/168750
1914 2014-05-14 Simon Fraser <simon.fraser@apple.com>
1916 [New multicolumn] Spin in RenderMultiColumnSet::repaintFlowThreadContent()
1917 https://bugs.webkit.org/show_bug.cgi?id=132884
1919 Reviewed by Beth Dakin.
1921 On iOS, wikipedia pages can hang under RenderMultiColumnSet::repaintFlowThreadContent().
1922 It appears that computedColumnHeight is set to 0 in prepareForLayout, but layout never happens
1923 on the RenderMultiColumnSet in some cases, leaving the column height set to zero.
1924 This caused columnIndexAtOffset() to return bad values, which resulted in very long loops
1925 in repaintFlowThreadContent().
1927 This fix is a stop-gap.
1929 * rendering/RenderMultiColumnSet.cpp:
1930 (WebCore::RenderMultiColumnSet::columnIndexAtOffset):
1932 2014-05-14 Benjamin Poulain <bpoulain@apple.com>
1934 Remove FrameView::viewportConstrainedExtentRect, it is unused
1935 https://bugs.webkit.org/show_bug.cgi?id=132927
1937 Reviewed by Simon Fraser.
1939 * page/FrameView.cpp:
1940 (WebCore::FrameView::viewportConstrainedExtentRect): Deleted.
1942 Simon replaced this by viewportConstrainedVisibleContentRect, remove the old code.
1944 2014-05-14 Matthew Hanson <matthew_hanson@apple.com>
1946 Only define MAX_GRID_TRACK_REPETITIONS if CSS_GRID_LAYOUT is enabled.
1948 Reviewed by Dean Jackson.
1950 This was causing -Wunused-const-variable errors.
1952 * css/CSSParser.cpp: Add include guard.
1954 2014-05-14 Beth Dakin <bdakin@apple.com>
1956 Tile cache has way too many tiles when pinch-zoomed in
1957 https://bugs.webkit.org/show_bug.cgi?id=132929
1959 <rdar://problem/16527172>
1961 Reviewed by Benjamin Poulain.
1963 This patch makes the margin sizing functions return the set margin size scaled by
1964 the TileGrid's scale. We also need to get rid of the old notion we used to have
1965 that margin tiles might be allowed to have a different size than the other tiles.
1966 We don't want that. They should have the normal margin size, but they should
1967 affect the overall coverage area.
1969 Scale by the TileGrid's scale.
1970 * platform/graphics/ca/mac/TileController.mm:
1971 (WebCore::TileController::topMarginHeight):
1972 (WebCore::TileController::bottomMarginHeight):
1973 (WebCore::TileController::leftMarginWidth):
1974 (WebCore::TileController::rightMarginWidth):
1976 Get rid of adjustRectAtTileIndexForMargin() since we do not want to ever do this
1977 adjustment. Use tileSize instead of margin size for all sizing computations.
1978 * platform/graphics/ca/mac/TileGrid.h:
1979 * platform/graphics/ca/mac/TileGrid.mm:
1980 (WebCore::TileGrid::rectForTileIndex):
1981 (WebCore::TileGrid::getTileIndexRangeForRect):
1982 (WebCore::TileGrid::adjustRectAtTileIndexForMargin): Deleted.
1984 2014-05-14 Dean Jackson <dino@apple.com>
1986 [Mac] Search fields should not use centered look
1987 https://bugs.webkit.org/show_bug.cgi?id=132930
1988 <rdar://problem/16825842>
1990 Reviewed by Beth Dakin.
1992 We need to explicitly set the centeredLook property
1993 to NO on modern releases of Mac.
1995 * rendering/RenderThemeMac.mm: Declare a new private property and set it to NO.
1996 (WebCore::RenderThemeMac::search):
1998 2014-05-14 Zalan Bujtas <zalan@apple.com>
2000 Subpixel layout: Change Element.offset* client* scroll* return type to double.
2001 https://bugs.webkit.org/show_bug.cgi?id=132895
2003 Reviewed by Simon Fraser.
2005 This patch changes Element.offset*, Element.client* and Element.scroll* APIs return
2006 type from long to double to match the latest CSSOM View Module spec[1].
2007 Element.offset* and Element.client* do return subpixel values from now on.
2008 Element.scroll* still return integral values as the scrolling code hasn't adopted to subpixel rendering yet.
2010 subpixelCSSOMElementMetricsEnabled setting is added to be able to turn this feature on/off
2011 from WK2 preferences. It toggles the return value from subpixel to floored integral.
2012 It does not change layout/rendering behavior.
2014 Reference list of what other browsers do:
2015 IE: http://blogs.msdn.com/b/ie/archive/2012/02/17/sub-pixel-rendering-and-the-css-object-model.aspx
2016 Blink: http://www.chromestatus.com/features/5497402177880064
2017 Firefox: https://bugzilla.mozilla.org/show_bug.cgi?id=825607
2019 [1] http://www.w3.org/TR/2013/WD-cssom-view-20131217/
2021 Test: cssom/subpixel-offsetleft-top-width-height-values.html
2024 (WebCore::localZoomForRenderer):
2025 (WebCore::adjustForLocalZoom):
2026 (WebCore::convertToNonSubpixelValueIfNeeded):
2027 (WebCore::Element::offsetLeft):
2028 (WebCore::Element::offsetTop):
2029 (WebCore::Element::offsetWidth):
2030 (WebCore::Element::offsetHeight):
2031 (WebCore::Element::clientLeft):
2032 (WebCore::Element::clientTop):
2033 (WebCore::Element::clientWidth):
2034 (WebCore::Element::clientHeight):
2035 (WebCore::Element::scrollLeft):
2036 (WebCore::Element::scrollTop):
2037 (WebCore::Element::setScrollLeft):
2038 (WebCore::Element::setScrollTop):
2039 (WebCore::Element::scrollWidth):
2040 (WebCore::Element::scrollHeight):
2043 * html/HTMLBodyElement.cpp:
2044 (WebCore::adjustForZoom):
2045 (WebCore::HTMLBodyElement::scrollLeft):
2046 (WebCore::HTMLBodyElement::setScrollLeft):
2047 (WebCore::HTMLBodyElement::scrollTop):
2048 (WebCore::HTMLBodyElement::setScrollTop):
2049 (WebCore::HTMLBodyElement::scrollHeight):
2050 (WebCore::HTMLBodyElement::scrollWidth):
2051 * html/HTMLBodyElement.h:
2054 2014-05-14 Brady Eidson <beidson@apple.com>
2056 Implement NSSharingServiceDelegate method "transitionImageForShareItem"
2057 <rdar://problem/16878020> and https://bugs.webkit.org/show_bug.cgi?id=132911
2059 Reviewed by Tim Horton.
2062 * WebCore.xcodeproj/project.pbxproj:
2064 2014-05-14 Alex Christensen <achristensen@webkit.org>
2066 Another unreviewed build fix.
2068 * platform/network/mac/ResourceHandleMac.mm:
2069 (WebCore::ResourceHandle::getTimingData):
2070 Added necessary UNUSED_PARAMs.
2072 2014-05-14 Alex Christensen <achristensen@webkit.org>
2074 Unreviewed build fix after r168849.
2076 * platform/network/mac/ResourceHandleMac.mm:
2077 (WebCore::ResourceHandle::getTimingData):
2078 Protect use of timing data with ENABLE(WEB_TIMING).
2080 2014-05-14 Alex Christensen <achristensen@webkit.org>
2082 Refactor duplicate code in web timing.
2083 https://bugs.webkit.org/show_bug.cgi?id=132917
2085 Reviewed by Alexey Proskuryakov.
2087 * platform/network/ResourceHandle.h:
2088 Added getTimingData declaration.
2089 * platform/network/mac/ResourceHandleMac.mm:
2090 (WebCore::ResourceHandle::getTimingData):
2091 * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
2092 (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
2093 * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
2094 (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
2095 Moved duplicate code to ResourceHandle.
2097 2014-05-14 Alex Christensen <achristensen@webkit.org>
2099 Use references instead of pointers with ResourceLoadTiming.
2100 https://bugs.webkit.org/show_bug.cgi?id=132846
2102 Reviewed by Alexey Proskuryakov.
2105 Removed ResourceResponseBase::setResourceLoadTiming linker symbol.
2106 * inspector/InspectorResourceAgent.cpp:
2107 (WebCore::buildObjectForResourceResponse):
2108 * page/PerformanceResourceTiming.cpp:
2109 (WebCore::PerformanceResourceTiming::domainLookupStart):
2110 (WebCore::PerformanceResourceTiming::domainLookupEnd):
2111 (WebCore::PerformanceResourceTiming::connectStart):
2112 (WebCore::PerformanceResourceTiming::connectEnd):
2113 (WebCore::PerformanceResourceTiming::secureConnectionStart):
2114 (WebCore::PerformanceResourceTiming::requestStart):
2115 Use references instead of pointers.
2116 * page/PerformanceResourceTiming.h:
2117 Make an instance instead of a RefPtr.
2118 * page/PerformanceTiming.cpp:
2119 (WebCore::PerformanceTiming::domainLookupStart):
2120 (WebCore::PerformanceTiming::domainLookupEnd):
2121 (WebCore::PerformanceTiming::connectStart):
2122 (WebCore::PerformanceTiming::connectEnd):
2123 (WebCore::PerformanceTiming::secureConnectionStart):
2124 (WebCore::PerformanceTiming::requestStart):
2125 (WebCore::PerformanceTiming::responseStart):
2126 Check to see if the loader exists, then use ResourceLoadTiming reference.
2127 (WebCore::PerformanceTiming::resourceLoadTiming): Deleted.
2128 * page/PerformanceTiming.h:
2129 Removed resourceLoadTiming declaration.
2130 * platform/network/ResourceLoadTiming.h:
2131 (WebCore::ResourceLoadTiming::ResourceLoadTiming):
2132 (WebCore::ResourceLoadTiming::operator=):
2133 Replaced reference counting with copy constructors.
2134 (WebCore::ResourceLoadTiming::create): Deleted.
2135 (WebCore::ResourceLoadTiming::deepCopy): Deleted.
2136 * platform/network/ResourceResponseBase.cpp:
2137 (WebCore::ResourceResponseBase::adopt):
2138 (WebCore::ResourceResponseBase::copyData):
2139 (WebCore::ResourceResponseBase::resourceLoadTiming):
2140 (WebCore::ResourceResponseBase::setResourceLoadTiming):
2141 (WebCore::ResourceResponseBase::compare):
2142 * platform/network/ResourceResponseBase.h:
2143 * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
2144 (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
2145 * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
2146 (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
2147 * platform/network/soup/ResourceHandleSoup.cpp:
2148 (WebCore::ResourceHandle::didStartRequest):
2149 (WebCore::networkEventCallback):
2150 Use references instead of pointers.
2152 2014-05-14 Commit Queue <commit-queue@webkit.org>
2154 Unreviewed, rolling out r168837.
2155 https://bugs.webkit.org/show_bug.cgi?id=132913
2157 The patch added an assertion which fires on 6 tests (Requested
2162 "[CSS Regions] Add ASSERT to make sure using the flowThread
2163 cache does not return incorrect results"
2164 https://bugs.webkit.org/show_bug.cgi?id=132906
2165 http://trac.webkit.org/changeset/168837
2167 2014-05-13 Jon Honeycutt <jhoneycutt@apple.com>
2169 Revert "Don't dispatch 'beforeload' event inside FrameView::layout()",
2170 commit 84fe8cf6fbe8b5de9a06300ca3ef6d0ffc96948c, and associated
2173 "platform/mac/plugins/testplugin-onnew-onpaint.html failing after
2174 r168668", commit c17be3bf5127baf94310af4b4b9bf5a57d29aaf4
2175 "[Win] Unreviewed build fix after r168668.", commit
2176 4fa470ad12c38ee7d4c114541b6dd321181a8bc9
2178 The original merged patch appears to have caused a regression in
2179 fast/dom/HTMLObjectElement/object-as-frame.html.
2181 <https://bugs.webkit.org/show_bug.cgi?id=132886>
2183 Reviewed by Alexey Proskuryakov.
2187 (WebCore::Document::updateLayoutIgnorePendingStylesheets):
2189 * html/HTMLAppletElement.cpp:
2190 (WebCore::HTMLAppletElement::renderWidgetForJSBindings):
2191 * html/HTMLEmbedElement.cpp:
2192 (WebCore::HTMLEmbedElement::renderWidgetForJSBindings):
2193 * html/HTMLObjectElement.cpp:
2194 (WebCore::HTMLObjectElement::renderWidgetForJSBindings):
2195 * page/FrameView.cpp:
2196 (WebCore::FrameView::FrameView):
2197 (WebCore::FrameView::reset):
2198 (WebCore::FrameView::flushAnyPendingPostLayoutTasks):
2199 (WebCore::FrameView::performPostLayoutTasks):
2200 (WebCore::FrameView::updateEmbeddedObjectsTimerFired): Deleted.
2202 * testing/Internals.cpp:
2203 (WebCore::Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks): Deleted.
2204 * testing/Internals.h:
2205 * testing/Internals.idl:
2207 2014-05-14 Kiran <kiran.guduru@samsung.com>
2209 alidation for getUserMedia() errorCallback is missing.
2210 https://bugs.webkit.org/show_bug.cgi?id=132901
2212 Reviewed by Darin Adler.
2214 The patch adds the validation for getUserMedia errorCallBack
2215 and throws TypeMismatchError.
2217 Test: fast/mediastream/getusermedia.html
2219 * Modules/mediastream/NavigatorUserMedia.cpp:
2220 (WebCore::NavigatorUserMedia::webkitGetUserMedia):
2222 2014-05-14 Tibor Meszaros <tmeszaros.u-szeged@partner.samsung.com>
2224 Remove CSS_STICKY_POSITION guards
2225 https://bugs.webkit.org/show_bug.cgi?id=132676
2227 Reviewed by Simon Fraser.
2229 * Configurations/FeatureDefines.xcconfig:
2230 * css/CSSParser.cpp:
2231 (WebCore::isValidKeywordPropertyAndValue):
2232 * css/CSSPrimitiveValueMappings.h:
2233 (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2234 (WebCore::CSSPrimitiveValue::operator EPosition):
2235 * css/CSSValueKeywords.in:
2236 * editing/EditingStyle.cpp:
2237 (WebCore::EditingStyle::convertPositionStyle):
2239 2014-05-14 Radu Stavila <stavila@adobe.com>
2241 [CSS Regions] Add ASSERT to make sure using the flowThread cache does not return incorrect results
2242 https://bugs.webkit.org/show_bug.cgi?id=132906
2244 Reviewed by Andrei Bucur.
2246 If flowThreadContainingBlock() is called on an object which is in a different
2247 flow thread than the one currently being laid out, this method will return an incorrect
2248 result. I added an assertion for that to make sure we catch and treat any such scenarios.
2250 No new tests required.
2252 * rendering/RenderObject.cpp:
2253 (WebCore::RenderObject::locateFlowThreadContainingBlockNoCache):
2254 (WebCore::RenderObject::locateFlowThreadContainingBlock):
2255 * rendering/RenderObject.h:
2257 2014-05-14 Andrei Bucur <abucur@adobe.com>
2259 [CSS Regions] Don't relayout when updating the region range unless necessary
2260 https://bugs.webkit.org/show_bug.cgi?id=132120
2262 Reviewed by Antti Koivisto.
2264 The patch reduces the cases when a relayout is made for boxes that change the region range.
2265 This lowers the amount of nested layouts in most cases and produces big layout speedups for trees
2266 without overhanging floats.
2268 Tests: Major performance improvement with speedups of 50-60% on:
2269 Layout/RegionsAuto.html, Layout/RegionsAutoMaxHeight.html and Layout/RegionsFixed.html
2271 * rendering/RenderBlock.cpp:
2272 (WebCore::RenderBlock::updateRegionRangeForBoxChild): Ask the child box if it needs a relayout
2273 in case its region range changes.
2274 * rendering/RenderBlockFlow.cpp:
2275 (WebCore::RenderBlockFlow::layoutBlockChild): It's not necessary to do two layouts here because
2276 there's no block direction position change between them for the child.
2277 (WebCore::RenderBlockFlow::needsLayoutAfterRegionRangeChange): If the block doesn't have floats
2278 or if it expands to enclose the floats it doesn't need to relayout after a region range chage.
2279 It's not possible for it to have a float inside overflow that must be repositioned using the new
2281 * rendering/RenderBlockFlow.h:
2282 * rendering/RenderBox.h:
2283 (WebCore::RenderBox::needsLayoutAfterRegionRangeChange): By default don't relayout after a region
2286 2014-05-14 Antti Koivisto <antti@apple.com>
2288 RuleData should ref the StyleRule
2289 https://bugs.webkit.org/show_bug.cgi?id=132865
2291 Reviewed by Andreas Kling.
2293 As a defensive move make RuleData ref the StyleRule.
2294 This adds some ref churn but the overall performance impact should be minimal.
2297 (WebCore::RuleData::rule):
2299 2014-05-14 Antti Koivisto <antti@apple.com>
2301 GIF animations don't restart after scrolling on iOS WebKit1
2302 https://bugs.webkit.org/show_bug.cgi?id=132900
2304 Reviewed by Andreas Kling.
2308 2014-05-13 Andrei Bucur <abucur@adobe.com>
2310 [CSS Regions] Assertion failure in some cases with inline blocks
2311 https://bugs.webkit.org/show_bug.cgi?id=132859
2313 Reviewed by Mihnea Ovidenie.
2315 The patch hardens the conditions when the region range caches are
2316 populated to avoid desynchronizations when objects move during layout.
2317 This is true especially in the case of the boxes found inside
2318 inline blocks, that get their range from the containing line.
2320 There is a new function |computedRegionRangeForBox| that will always
2321 return a region range for a box using a best effort algorithm. This should
2322 be used only when there's no need to cache region information.
2324 This change also allows better control over the lifecycle of the
2325 |RenderBoxRegionInfo| objects stored on the regions. We can now iterate
2326 over the full range of the box when cleaning up the region box info. The
2327 same applies for the width change detection function.
2329 Test: fast/regions/inline-block-shifted-region.html
2331 * rendering/RenderBlockLineLayout.cpp:
2332 (WebCore::RenderBlockFlow::updateRegionForLine): Don't set the containing
2333 region if the block doesn't have a range. The returned value would not
2334 be correctly clamped.
2335 * rendering/RenderBox.cpp:
2336 (WebCore::RenderBlock::hasRegionRangeInFlowThread):
2337 * rendering/RenderBox.h:
2338 * rendering/RenderFlowThread.cpp:
2339 (WebCore::RenderFlowThread::removeRenderBoxRegionInfo): Iterate only over
2340 the range of the box, not from the start of the region chain.
2341 (WebCore::RenderFlowThread::logicalWidthChangedInRegionsForBlock): Same as
2343 (WebCore::RenderFlowThread::hasCachedRegionRangeForBox):
2344 (WebCore::RenderFlowThread::getRegionRangeForBoxFromCachedInfo):
2345 (WebCore::RenderFlowThread::getRegionRangeForBox):
2346 (WebCore::RenderFlowThread::computedRegionRangeForBox): Best effort function
2347 to determine the range of a box. It will always return something as long
2348 as the flow thread has regions.
2349 (WebCore::RenderFlowThread::objectShouldFragmentInFlowRegion): Use the new function
2350 to determine the range.
2351 * rendering/RenderFlowThread.h:
2352 * rendering/RenderNamedFlowThread.cpp:
2353 (WebCore::RenderNamedFlowThread::absoluteQuadsForBox): Use the new function to determine
2356 2014-05-13 Simon Fraser <simon.fraser@apple.com>
2358 Fix "ASSERTION FAILED: m_representation == PlatformLayerRepresentation" with UI-side compositing
2359 https://bugs.webkit.org/show_bug.cgi?id=132899
2361 Reviewed by Beth Dakin.
2367 2014-05-13 Hans Muller <hmuller@adobe.com>
2369 [CSS Shapes] line height grows around polygon and incorrectly causes text to wrap to next line
2370 https://bugs.webkit.org/show_bug.cgi?id=131622
2372 Reviewed by Bem Jones-Bey.
2374 Corrected an earlier PolygonShape fix https://bugs.webkit.org/show_bug.cgi?id=132132
2375 When the top or bottom of a layout line is coincident with a polygon edge vertex, we
2376 only consider it an intersection if the edge extends into the line.
2378 Test: fast/shapes/shape-outside-floats/shape-outside-edge-case.html
2380 * rendering/shapes/PolygonShape.cpp:
2381 (WebCore::OffsetPolygonEdge::clippedEdgeXRange):
2383 2014-05-13 Beth Dakin <bdakin@apple.com>
2385 m_layerForOverhangAreas is sometimes not positioned correctly when topContentInset
2387 https://bugs.webkit.org/show_bug.cgi?id=132898
2389 <rdar://problem/16644710>
2391 Reviewed by Anders Carlsson.
2393 This function is called whenever the topContentInset changes, so use it as an
2394 opportunity to ensure that m_layerForOverhangAreas has been positioned correctly.
2395 * rendering/RenderLayerCompositor.cpp:
2396 (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
2398 Everyone gets an anchor point!
2399 (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
2401 2014-05-13 Dean Jackson <dino@apple.com>
2403 Attempted build fix after https://bugs.webkit.org/show_bug.cgi?id=132891
2405 * page/PageDebuggable.cpp:
2407 2014-05-13 Timothy Hatcher <timothy@apple.com>
2409 Force developerExtrasEnabled when a remote Inspector client connects.
2411 https://bugs.webkit.org/show_bug.cgi?id=132891
2413 Reviewed by Joseph Pecoraro.
2415 * page/PageDebuggable.cpp:
2416 (WebCore::PageDebuggable::PageDebuggable): Initialize m_forcedDeveloperExtrasEnabled to false.
2417 (WebCore::PageDebuggable::connect): Set m_forcedDeveloperExtrasEnabled if the setting is changed.
2418 (WebCore::PageDebuggable::disconnect): Switch developerExtrasEnabled back to false
2419 if m_forcedDeveloperExtrasEnabled is true.
2420 * page/PageDebuggable.h: Added m_forcedDeveloperExtrasEnabled.
2422 2014-05-13 Beth Dakin <bdakin@apple.com>
2424 REGRESSION (topContentInset): Searching through Facebook Messenger's chat causes
2425 scrolling in News Feed
2426 https://bugs.webkit.org/show_bug.cgi?id=132889
2428 <rdar://problem/16715716>
2430 Reviewed by Simon Fraser.
2432 First of all, scrollOffsetRelativeToDocument() was very poorly named. This patch
2433 re-names it to the much more accurate documentScrollOffsetRelativeToViewOrigin().
2434 Re-naming it makes it clear that ONE call site was not getting the right offset.
2435 That call site does not want to know the document’s position relative to the view
2436 origin, but rather it wants to know the Document’s position relative to the
2442 Use newly re-named documentScrollPositionRelativeToViewOrigin().
2443 * page/FrameView.cpp:
2444 (WebCore::FrameView::convertToRenderer):
2445 * platform/ScrollView.cpp:
2446 (WebCore::ScrollView::documentScrollOffsetRelativeToViewOrigin):
2447 (WebCore::ScrollView::documentScrollPositionRelativeToViewOrigin):
2448 (WebCore::ScrollView::documentScrollOffsetRelativeToScrollableAreaOrigin):
2449 (WebCore::ScrollView::rootViewToContents):
2450 (WebCore::ScrollView::windowToContents):
2451 (WebCore::ScrollView::scrollOffsetRelativeToDocument): Deleted.
2452 (WebCore::ScrollView::scrollPositionRelativeToDocument): Deleted.
2453 * platform/ScrollView.h:
2455 THIS is the spot that needs the new function,
2456 documentScrollOffsetRelativeToScrollableAreaOrigin()()
2457 * rendering/RenderLayer.cpp:
2458 (WebCore::RenderLayer::scrollRectToVisible):
2460 2014-05-13 Dean Jackson <dino@apple.com>
2462 [iOS] Page scale update messages for media controls should only fire at the end of zooming
2463 https://bugs.webkit.org/show_bug.cgi?id=132857
2464 <rdar://problem/16631009>
2466 Reviewed by Simon Fraser.
2468 As the user was zooming, the media controls that responded
2469 to the page scale (and resized themselves) would do so
2470 slightly out of sync with the screen refreshes, and it looked
2471 terrible. They really only need to get told at the end
2472 of the zoom that they need to relayout.
2474 Allow setPageScaleFactor to accept another parameter
2475 that indicates if the change is stable. That way, changes
2476 during a user triggers zoom gesture can be ignored for
2479 * WebCore.exp.in: Page::setPageScaleFactor takes a new parameter.
2481 (WebCore::Document::pageScaleFactorChangedAndStable): Renamed from pageScaleFactorChanged.
2482 (WebCore::Document::pageScaleFactorChanged): Deleted.
2485 (WebCore::Page::setPageScaleFactor): Accepts a new inStableState parameter,
2486 and tells the main frame that the scale factor has changed if it's stable.
2489 2014-05-13 Eric Carlson <eric.carlson@apple.com>
2491 Unreviewed build fix after r168755.
2493 * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2494 (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive):
2496 2014-05-13 Eric Carlson <eric.carlson@apple.com>
2498 [Mac] hasVideo should return true when video is ready to display
2499 https://bugs.webkit.org/show_bug.cgi?id=132885
2501 Reviewed by Jer Noble.
2503 * html/HTMLMediaElement.cpp:
2504 (WebCore::HTMLMediaElement::parseAttribute):
2506 * platform/graphics/avfoundation/objc/AudioTrackPrivateAVFObjC.mm:
2507 (WebCore::AudioTrackPrivateAVFObjC::resetPropertiesFromTrack): Don't change the
2508 enabled state of the AVPlayerItemTrack during setup.
2510 * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2511 * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2512 (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Initialize
2513 m_cachedIsReadyForDisplay.
2514 (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad): Remove "enabled" KVO observers.
2515 (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Observe "readyForDisplay"
2516 change notifications.
2517 (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyVideoLayer): Remove for "readyForDisplay"
2519 (WebCore::MediaPlayerPrivateAVFoundationObjC::hasAvailableVideoFrame): Return cached readyForDisplay
2520 state instead of polling every time.
2521 (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Call setHasVideo(true) if the
2522 player layer is ready for display.
2523 (WebCore::MediaPlayerPrivateAVFoundationObjC::updateAudioTracks): Update logging.
2524 (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoTracks): Ditto.
2525 (WebCore::MediaPlayerPrivateAVFoundationObjC::firstFrameAvailableDidChange): Cache readyForDisplay
2526 state, call tracksChanged() if we haven't seen a video track yet.
2527 (WebCore::MediaPlayerPrivateAVFoundationObjC::trackEnabledDidChange): New.
2528 (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive): Correct logging.
2529 (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksDidChange): Remove old "enabled" listeners
2530 before release tracks, add new ones to new tracks.
2531 (WebCore::assetTrackMetadataKeyNames): Add "enabled" to the list of properties we require to
2532 be loaded before announcing that metadata has loaded.
2533 (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]): Observe
2534 "readyForDisplay" and "enabled".
2536 * platform/graphics/avfoundation/objc/VideoTrackPrivateAVFObjC.cpp:
2537 (WebCore::VideoTrackPrivateAVFObjC::resetPropertiesFromTrack): Don't change the
2538 enabled state of the AVPlayerItemTrack during setup.
2540 2014-05-13 Myles C. Maxfield <litherum@gmail.com>
2542 Text decorations do not contribute to visual overflow
2543 https://bugs.webkit.org/show_bug.cgi?id=132773
2545 Reviewed by Darin Adler.
2547 Tests: fast/css3-text/css3-text-decoration/repaint/underline-outside-of-layout-rect.html
2549 * rendering/InlineTextBox.cpp:
2550 (WebCore::textDecorationStrokeThickness): Refactor into a common function
2551 (WebCore::wavyOffsetFromDecoration): Ditto
2552 (WebCore::InlineTextBox::extendVerticalVisualOverflowForDecorations): Given
2553 vertical overflow bounds, possibly extend those to include location of
2555 (WebCore::InlineTextBox::paintDecoration): Use refactored functions.
2556 * rendering/InlineTextBox.h: Function signature
2557 * rendering/RenderBlockLineLayout.cpp:
2558 (WebCore::setLogicalWidthForTextRun): Call extendVerticalVisualOverflowForDecorations()
2559 * rendering/style/RenderStyle.cpp:
2560 (WebCore::RenderStyle::changeAffectsVisualOverflow): Inspects shadows and text decorations
2561 (WebCore::RenderStyle::changeRequiresLayout): Calls changeAffectsVisualOverflow()
2562 (WebCore::RenderStyle::changeRequiresRepaintIfTextOrBorderOrOutline): Moved code from here
2563 to changeAffectsVisualOverflow().
2564 * rendering/style/RenderStyle.h: Function signature
2566 2014-05-13 Enrica Casucci <enrica@apple.com>
2568 REGRESSION (WebKit2): Zooming to text field leaves it partially hidden by the form assistant.
2569 https://bugs.webkit.org/show_bug.cgi?id=132879
2570 <rdar://problem/16318049>
2572 Reviewed by Benjamin Poulain.
2574 Adding some exports. The fix to setScrollPosition is to avoid clamping the scroll
2575 position when using delegate scrolling.
2578 * platform/ScrollView.cpp:
2579 (WebCore::ScrollView::setScrollPosition):
2581 2014-05-13 Brady Eidson <beidson@apple.com>
2583 Followup to: Update positioning/drawing of the image controls button.
2584 <rdar://problem/16885077> and https://bugs.webkit.org/show_bug.cgi?id=132883
2586 Reviewed by Tim Horton.
2588 Cleared up the actual intent behind review feedback on the original patch.
2590 * html/shadow/mac/ImageControlsButtonElementMac.cpp:
2591 (WebCore::ImageControlsButtonElementMac::maybeCreate):
2593 2014-05-13 Brady Eidson <beidson@apple.com>
2595 Update positioning/drawing of the image controls button.
2596 <rdar://problem/16885077> and https://bugs.webkit.org/show_bug.cgi?id=132883
2598 Reviewed by Tim Horton.
2600 * html/shadow/mac/ImageControlsButtonElementMac.cpp:
2601 (WebCore::ImageControlsButtonElementMac::maybeCreate): Add inline style for top/right
2602 positioning based on the metrics from the render theme.
2604 * html/shadow/mac/imageControlsMac.css:
2605 (.x-webkit-image-controls-button): Can’t hard code any positioning.
2607 * rendering/RenderTheme.h:
2608 (WebCore::RenderTheme::imageControlsButtonPositionOffset):
2609 * rendering/RenderThemeMac.h:
2610 * rendering/RenderThemeMac.mm:
2611 (WebCore::RenderThemeMac::servicesRolloverButtonCell):
2612 (WebCore::RenderThemeMac::imageControlsButtonPositionOffset):
2614 2014-05-13 Simon Fraser <simon.fraser@apple.com>
2616 [iOS WK2] background-attachment:fixed behaves very poorly
2617 https://bugs.webkit.org/show_bug.cgi?id=132881
2618 <rdar://problem/16789526>
2620 Reviewed by Beth Dakin.
2622 Remove the old ENABLE_FAST_MOBILE_SCROLLING code, and add a setting that
2623 controls whether fixed backgrounds paint relative to the document, which
2624 is enabled for iOS (WK1 and WK2). This setting is consulted when we repaint
2625 fixed backgrounds on scrolling, when we paint them, and when we decide to make
2626 a layer for fixed backgrounds.
2628 * page/Settings.cpp:
2630 * rendering/RenderBoxModelObject.cpp:
2631 (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
2632 * rendering/RenderElement.cpp:
2633 (WebCore::RenderElement::styleWillChange):
2634 (WebCore::RenderElement::willBeRemovedFromTree):
2635 (WebCore::shouldRepaintFixedBackgroundsOnScroll): Deleted.
2636 * rendering/RenderLayerCompositor.cpp:
2637 (WebCore::RenderLayerCompositor::needsFixedRootBackgroundLayer):
2639 2014-05-13 Zalan Bujtas <zalan@apple.com>
2641 REGRESSSION(r168528) Subpixel rendering: Selection rect is not positioned properly when SVG text is selected.
2642 https://bugs.webkit.org/show_bug.cgi?id=132868
2644 Reviewed by Dirk Schulze.
2646 Scale the selection rect. r168528 missed applying this final transform on the selection/painting rect.
2648 Test: svg/text/hidpi-text-selection-rect-position.html
2650 * rendering/svg/SVGInlineTextBox.cpp:
2651 (WebCore::SVGInlineTextBox::selectionRectForTextFragment):
2653 2014-05-13 Martin Hodovan <mhodovan.u-szeged@partner.samsung.com>
2655 ASSERTION FAILED: leftCategory != CalcOther && rightCategory != CalcOther
2656 in WebCore::CSSCalcBinaryOperation::createSimplified
2657 https://bugs.webkit.org/show_bug.cgi?id=132870
2659 According to the standard, calc() should be able to handle angle, time
2660 and frequency values as well: http://www.w3.org/TR/css3-values/#calc
2662 Reviewed by Darin Adler.
2664 Test: fast/css/calc-with-angle-time-frequency.html
2666 * css/CSSCalculationValue.cpp:
2667 (WebCore::unitCategory):
2668 (WebCore::CSSCalcPrimitiveValue::createCalcExpression):
2669 (WebCore::CSSCalcPrimitiveValue::computeLengthPx):
2670 (WebCore::CSSCalcPrimitiveValue::addSubtractResult):
2671 (WebCore::CSSCalcPrimitiveValue::determineCategory):
2672 (WebCore::CSSCalcBinaryOperation::primitiveType)
2673 * css/CSSCalculationValue.h: extending CalculationCategory
2674 * css/CSSParser.cpp:
2675 (WebCore::CSSParser::validCalculationUnit):
2676 * css/CSSPrimitiveValue.cpp:
2677 (WebCore::CSSPrimitiveValue::primitiveType):
2679 2014-05-13 Darin Adler <darin@apple.com>
2681 Try to fix the !ENABLE(ICONDATABASE) build
2683 * loader/icon/IconDatabase.h: Include WTFString.h.
2685 2014-05-13 Carlos Garcia Campos <cgarcia@igalia.com>
2687 REGRESSION(r167771): [GTK] Text fields and areas are rendered unthemed
2688 https://bugs.webkit.org/show_bug.cgi?id=132864
2690 Reviewed by Philippe Normand.
2692 This is because the virtual methods changed the API in the parent,
2693 and since we don't have the methods marked as override we didn't
2694 noticed it. After using override keyword for all virtual methods
2695 in the derived class another problem showed up, the ActiveListBox
2696 selection methods were incorrectly named.
2698 * platform/gtk/RenderThemeGtk.cpp:
2699 (WebCore::RenderThemeGtk::paintTextArea): Update to API changes in the
2701 * platform/gtk/RenderThemeGtk.h: Mark all virtual methods as
2702 override and the class as final.
2703 * platform/gtk/RenderThemeGtk2.cpp:
2704 (WebCore::RenderThemeGtk::paintTextField): Update to API changes
2705 in the parent class.
2706 (WebCore::RenderThemeGtk::platformActiveListBoxSelectionBackgroundColor):
2707 (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionBackgroundColor):
2708 (WebCore::RenderThemeGtk::platformActiveListBoxSelectionForegroundColor):
2709 (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionForegroundColor):
2710 (WebCore::RenderThemeGtk::activeListBoxSelectionBackgroundColor): Deleted.
2711 (WebCore::RenderThemeGtk::inactiveListBoxSelectionBackgroundColor): Deleted.
2712 (WebCore::RenderThemeGtk::activeListBoxSelectionForegroundColor): Deleted.
2713 (WebCore::RenderThemeGtk::inactiveListBoxSelectionForegroundColor): Deleted.
2714 * platform/gtk/RenderThemeGtk3.cpp:
2715 (WebCore::RenderThemeGtk::paintTextField): Update to API changes
2716 in the parent class.
2717 (WebCore::RenderThemeGtk::platformActiveListBoxSelectionBackgroundColor):
2718 (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionBackgroundColor):
2719 (WebCore::RenderThemeGtk::platformActiveListBoxSelectionForegroundColor):
2720 (WebCore::RenderThemeGtk::platformInactiveListBoxSelectionForegroundColor):
2721 (WebCore::RenderThemeGtk::activeListBoxSelectionBackgroundColor): Deleted.
2722 (WebCore::RenderThemeGtk::inactiveListBoxSelectionBackgroundColor): Deleted.
2723 (WebCore::RenderThemeGtk::activeListBoxSelectionForegroundColor): Deleted.
2724 (WebCore::RenderThemeGtk::inactiveListBoxSelectionForegroundColor): Deleted.
2726 2014-05-13 Xabier Rodriguez Calvar <calvaris@igalia.com>
2728 [GStreamer] Move toGstClockTime to utilities
2729 https://bugs.webkit.org/show_bug.cgi?id=132702
2731 Reviewed by Philippe Normand.
2733 toGstClockTime should be in GStreamerUtilities and corrected typo
2736 No new tests needed.
2738 * platform/graphics/gstreamer/GStreamerUtilities.cpp:
2739 (WebCore::getGstPlayFlag): Renamed from getGstPlaysFlag.
2740 (WebCore::toGstClockTime): Moved from MediaPlayerPrivateGStreamer.
2741 (WebCore::getGstPlaysFlag): Deleted.
2742 * platform/graphics/gstreamer/GStreamerUtilities.h:
2743 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2744 (WebCore::MediaPlayerPrivateGStreamer::setDownloadBuffering):
2745 Corrected getGstPlayFlag typo.
2746 (WebCore::toGstClockTime): Deleted.
2748 2014-05-12 Darin Adler <darin@apple.com>
2750 Make a few icon database improvements
2751 https://bugs.webkit.org/show_bug.cgi?id=132812
2753 Reviewed by Brady Eidson.
2755 * WebCore.exp.in: Export more IconDatabase functions, since they are now called
2756 by WebKit2 through pointers to a class marked final.
2758 * loader/icon/IconDatabase.cpp: Removed unneeded includes. Use override for
2761 * loader/icon/IconDatabase.h: Removed unneeded includes. Marked the class final.
2762 Use override for virtual functions. Use a public constructor instead of a create
2765 * loader/icon/IconDatabaseBase.h: Removed unneeded includes.
2767 2014-05-13 Kiran <kiran.guduru@samsung.com>
2769 [MediaStream] MediaStream.addTrack Should not check for active state.
2770 https://bugs.webkit.org/show_bug.cgi?id=132558
2772 Reviewed by Eric Carlson.
2774 MediaStream.addTrack method is checking for active state of a
2775 MediaStream, but it should not check for active state while adding a Track.
2777 Test: fast/mediastream/MediaStream-add-tracks-to-inactive-stream.html
2779 * Modules/mediastream/MediaStream.cpp:
2780 (WebCore::MediaStream::addTrack):
2782 2014-05-12 Mark Lam <mark.lam@apple.com>
2784 WebKit2 on iOS needs to capture the main thread's floating point environment.
2785 <https://webkit.org/b/132755>
2787 Reviewed by Geoffrey Garen.
2789 For iOS, WorkerThread::workerThread() expects to be able to initialize the
2790 worker thread's floating point environment to be the same as the one in the
2791 main thread. The FP env of the main thread is expected to have been captured
2792 in the mainThreadFEnv global. On WebKit2 for iOS, we neglected to initialize
2795 We now introduce a FloatingPointEnvironment class that will encapsulate the main
2796 thread (aka "UIThread") fenv, and we'll call FloatingPointEnv::saveMainThreadEnvironment()
2797 from ChildProcess::platformInitialize() to ensure that the FloatingPointEnvironment
2798 singleton instance is initialized properly for WebKit2.
2800 In the ChildProcess::platformInitialize(), we also need to initialize the ARMv7
2801 FP env to support denormalized numbers. We'll do this before calling
2802 saveMainThreadEnvironment().
2804 Tests: fast/workers/worker-floating-point.html
2805 js/floating-point-denormalized.html
2808 * WebCore.xcodeproj/project.pbxproj:
2809 * platform/ios/wak/FloatingPointEnvironment.cpp: Added.
2810 (WebCore::FloatingPointEnvironment::env):
2811 (WebCore::FloatingPointEnvironment::FloatingPointEnvironment):
2812 (WebCore::FloatingPointEnvironment::enableDenormalSupport):
2813 (WebCore::FloatingPointEnvironment::saveMainThreadEnvironment):
2814 (WebCore::FloatingPointEnvironment::propagateMainThreadEnvironment):
2815 * platform/ios/wak/FloatingPointEnvironment.h: Added.
2816 * platform/ios/wak/WebCoreThread.h:
2817 * platform/ios/wak/WebCoreThread.mm:
2820 * workers/WorkerThread.cpp:
2821 (WebCore::WorkerThread::workerThread):
2823 2014-05-12 Dirk Schulze <krit@webkit.org>
2825 SVG root element accepts background color but fails to repaint it
2826 https://bugs.webkit.org/show_bug.cgi?id=63153
2828 Reviewed by Dean Jackson.
2830 This is back ported from Blink. Don't know the exact commit though.
2831 The patch checks if the SVGSVGElement is an outermost root element.
2832 If it is, mark the whole element for repaint.
2834 Test: svg/custom/svg-root-background.html
2836 * rendering/RenderBoxModelObject.cpp:
2837 (WebCore::RenderBoxModelObject::calculateHasBoxDecorations):
2838 (WebCore::RenderBoxModelObject::updateFromStyle):
2839 * rendering/RenderBoxModelObject.h:
2840 * rendering/svg/RenderSVGRoot.cpp:
2841 (WebCore::RenderSVGRoot::RenderSVGRoot):
2842 (WebCore::RenderSVGRoot::layout):
2843 (WebCore::RenderSVGRoot::paintReplaced):
2844 (WebCore::RenderSVGRoot::clippedOverflowRectForRepaint):
2845 This is a simple optimization by taking the necessary parts
2846 from RenderReplaced and SVGRenderSupport.
2847 * rendering/svg/RenderSVGRoot.h:
2849 2014-05-12 Simon Fraser <simon.fraser@apple.com>
2851 [iOS] Fixed items are sometimes clipped after rubber-banding
2852 https://bugs.webkit.org/show_bug.cgi?id=132851
2853 <rdar://problem/16870790>
2855 Reviewed by Benjamin Poulain.
2857 On iOS fixed-position layers would get clipped to the document rect,
2858 but with rubber-banding, we can now have a custom fixed postion rect
2859 that extends outside the document rect.
2861 Another issue was that we would un-composite fixed elements sometimes
2862 when scrolling fast, again because they could fall outside of the document rect.
2864 A final issue was that pinching could reveal parts of fixed elements that should
2865 lie outside the viewport, rather than clipping the layers.
2867 Fix by converting both call points to use viewportConstrainedVisibleContentRect()
2868 rather than viewportConstrainedExtentRect(). On non-iOS platforms these are
2869 the same, but on iOS viewportConstrainedVisibleContentRect() uses the
2870 custom fixed position rect, which is the correct rect to intersect with.
2872 * rendering/RenderLayerBacking.cpp:
2873 (WebCore::RenderLayerBacking::updateCompositedBounds):
2874 * rendering/RenderLayerCompositor.cpp:
2875 (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
2877 2014-05-06 Jon Honeycutt <jhoneycutt@apple.com>
2879 Don't dispatch 'beforeload' event inside FrameView::layout()
2881 https://bugs.webkit.org/show_bug.cgi?id=132621
2882 <rdar://problem/15661470>
2884 This merges Blink revision 162073 with minor renaming and style
2885 changes. From that commit:
2887 Executing JavaScript code inside FrameView::layout() is problematic.
2888 e.g. an assertion failure tested in fast/events/beforeload-assertion.html.
2891 This CL makes 'beforeload' event dispatching for plugins and iframes asynchronous,
2892 except plugin access from JavaScript code (HTMLPlugInElement::
2893 renderWidgetForJSBindings).
2895 Reviewed by Brent Fulgham.
2897 Tests: fast/events/beforeload-assertion.html
2898 fast/events/beforeload-iframe-crash.html
2899 fast/events/beforeload-input-time-crash.html
2903 (WebCore::Document::updateLayoutIgnorePendingStylesheets):
2905 * html/HTMLAppletElement.cpp:
2906 (WebCore::HTMLAppletElement::renderWidgetForJSBindings):
2907 * html/HTMLEmbedElement.cpp:
2908 (WebCore::HTMLEmbedElement::renderWidgetForJSBindings):
2909 * html/HTMLObjectElement.cpp:
2910 (WebCore::HTMLObjectElement::renderWidgetForJSBindings):
2911 * page/FrameView.cpp:
2912 (WebCore::FrameView::FrameView):
2913 (WebCore::FrameView::reset):
2914 (WebCore::FrameView::updateEmbeddedObjectsTimerFired):
2915 (WebCore::FrameView::flushAnyPendingPostLayoutTasks):
2916 (WebCore::FrameView::performPostLayoutTasks):
2918 * testing/Internals.cpp:
2919 (WebCore::Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks):
2920 * testing/Internals.h:
2921 * testing/Internals.idl:
2923 2014-05-12 Roger Fong <roger_fong@apple.com>
2925 Limit number of active graphics contexts per web process.
2926 https://bugs.webkit.org/show_bug.cgi?id=132833.
2927 <rdar://problem/16888459>
2929 Reviewed by Dean Jackson.
2931 Test: webgl/many-contexts.html
2933 * platform/graphics/GraphicsContext3D.h:
2934 * platform/graphics/mac/GraphicsContext3DMac.mm: Limit number of active contexts to 16.
2935 (WebCore::GraphicsContext3D::create):
2936 (WebCore::GraphicsContext3D::~GraphicsContext3D):
2938 2014-05-12 Simon Fraser <simon.fraser@apple.com>
2942 * page/scrolling/ScrollingCoordinator.cpp:
2943 (WebCore::ScrollingCoordinator::contentShadowLayerForFrameView):
2945 2014-05-12 Brent Fulgham <bfulgham@apple.com>
2947 DataDetectorUI doesn't update with resize
2948 https://bugs.webkit.org/show_bug.cgi?id=132830
2949 <rdar://problem/16871179>
2951 Reviewed by Simon Fraser.
2953 * editing/Editor.cpp:
2954 (WebCore::Editor::scanSelectionForTelephoneNumbers): Add public, no-argument
2955 version that can be called after layout changes.
2956 (WebCore::Editor::didLayout): Reprocess telephone number data
2957 since Ranges will have changed.
2959 * editing/FrameSelection.cpp:
2960 (WebCore::FrameSelection::updateDataDetectorsForSelection): Added.
2961 * editing/FrameSelection.h:
2962 * page/FrameView.cpp:
2963 (WebCore::FrameView::performPostLayoutTasks): Ask the FrameSelection to update the
2964 Range information for selected phone numbers.
2966 2014-05-12 Simon Fraser <simon.fraser@apple.com>
2970 * page/scrolling/ScrollingCoordinator.cpp:
2971 (WebCore::ScrollingCoordinator::contentShadowLayerForFrameView):
2973 2014-05-12 Simon Fraser <simon.fraser@apple.com>
2975 [iOS WK2] Fuzzy tiles on some sites on loading
2976 https://bugs.webkit.org/show_bug.cgi?id=132847
2977 <rdar://problem/16816178>
2979 Reviewed by Benjamin Poulain.
2981 Export WebCore::TileController::contentsScale() const
2985 2014-05-12 Simon Fraser <simon.fraser@apple.com>
2987 Add debug dumping for ViewportConfiguration
2988 https://bugs.webkit.org/show_bug.cgi?id=132843
2990 Reviewed by Benjamin Poulain.
2992 Add some TextStream-based dumping for ViewportConfiguration.
2994 * page/ViewportConfiguration.cpp:
2995 (WebCore::ViewportConfiguration::updateConfiguration):
2996 (WebCore::ViewportConfigurationTextStream::ViewportConfigurationTextStream):
2997 (WebCore::ViewportConfigurationTextStream::increaseIndent):
2998 (WebCore::ViewportConfigurationTextStream::decreaseIndent):
2999 (WebCore::dumpProperty):
3000 (WebCore::ViewportConfigurationTextStream::writeIndent):
3001 (WebCore::ViewportConfigurationTextStream::operator<<):
3002 (WebCore::ViewportConfiguration::description):
3003 (WebCore::ViewportConfiguration::dump):
3004 * page/ViewportConfiguration.h:
3006 2014-05-12 Brady Eidson <beidson@apple.com>
3008 Followup to "Teach Editor to support more direct replacement of a Node"
3009 <rdar://problem/16817952> and https://bugs.webkit.org/show_bug.cgi?id=132834
3011 Pair programmed and pair reviewed by Brady Eidson and Darin Adler.
3013 * editing/mac/EditorMac.mm:
3014 (WebCore::maybeCopyNodeAttributesToFragment):
3015 (WebCore::Editor::replaceNodeFromPasteboard):
3017 2014-05-12 Beth Dakin <bdakin@apple.com>
3019 Content shadow layer needs to move in sync with the content layer
3020 https://bugs.webkit.org/show_bug.cgi?id=132841
3022 <rdar://problem/16641115>
3024 Reviewed by Simon Fraser.
3026 Now that the root content layer moves a little bit (for y scroll positions between
3027 0 and topContentInset), the shadow layer needs to move along with it since the
3028 shadow layer should always have the same position as the root content layer.
3030 Set the root state node’s shadow layer, and update the position whenever the root
3031 content layer’s position is updated.
3032 * page/scrolling/AsyncScrollingCoordinator.cpp:
3033 (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
3034 (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
3036 Fetch the compositor’s layerForContentShadow().
3037 * page/scrolling/ScrollingCoordinator.cpp:
3038 (WebCore::ScrollingCoordinator::contentShadowLayerForFrameView):
3039 * page/scrolling/ScrollingCoordinator.h:
3041 Hook up the contentShadowLayer in the state node.
3042 * page/scrolling/ScrollingStateScrollingNode.cpp:
3043 (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
3044 (WebCore::ScrollingStateScrollingNode::setContentShadowLayer):
3046 Hook it up in the ScrollingTreeNode as well. Move the layer whenever the m
3047 _scrolledContentsLayer is moved.
3048 * page/scrolling/ScrollingStateScrollingNode.h:
3049 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
3050 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
3051 (WebCore::ScrollingTreeScrollingNodeMac::updateBeforeChildren):
3052 (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
3054 The shadow layer needs an anchor point now that we are moving it around.
3055 * rendering/RenderLayerCompositor.cpp:
3056 (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
3058 2014-05-12 Dirk Schulze <krit@webkit.org>
3060 <svg> with opacity and compositing double-applies its opacity
3061 https://bugs.webkit.org/show_bug.cgi?id=116856
3063 Reviewed by Simon Fraser.
3065 The opacity is applied by the compositor. However, all SVG elements
3066 create transparency layers on their own to apply opacity. So did
3069 Added a check if the current element has a compositing layer and skip
3070 creating transparency layer if it has.
3072 Test: svg/custom/composited-svg-with-opacity.html
3074 * rendering/svg/SVGRenderingContext.cpp:
3075 (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
3077 2014-05-12 Brady Eidson <beidson@apple.com>
3079 Teach Editor to support more direct replacement of a Node
3080 <rdar://problem/16817952> and https://bugs.webkit.org/show_bug.cgi?id=132834
3082 Reviewed by Enrica Casucci.
3084 The new method "Editor::replaceNodeFromPasteboard" has the intent that the new DocumentFragment
3085 from the pasteboard is as similar to the old Node as possible.
3087 In practice, the new DocumentFragment:
3088 1 - Can represent a single node that's missing various attributes the original Node had.
3089 2 - Can be an unwanted fragment of arbitrary depth when the replacement happens inside Mail.app
3091 This fixes both of these issues.
3093 Add a MailBlockquoteHandling enum class for various Editor operations to pass through to the
3094 ReplaceSelectionCommand:
3095 * editing/Editor.cpp:
3096 (WebCore::Editor::handleTextEvent):
3097 (WebCore::Editor::pasteAsFragment):
3098 (WebCore::Editor::pasteWithPasteboard):
3099 (WebCore::Editor::replaceSelectionWithFragment):
3102 * dom/TextEvent.cpp:
3103 (WebCore::TextEvent::createForPlainTextPaste):
3104 (WebCore::TextEvent::createForFragmentPaste):
3105 (WebCore::TextEvent::TextEvent):
3107 (WebCore::TextEvent::mailBlockquoteHandling):
3109 * editing/ReplaceSelectionCommand.cpp:
3110 (WebCore::ReplaceSelectionCommand::ReplaceSelectionCommand):
3111 (WebCore::ReplaceSelectionCommand::doApply): Consider whether or not this particular Editor
3112 operation was meant to give special consideration to Mail's Blockquotes.
3113 * editing/ReplaceSelectionCommand.h:
3115 * editing/efl/EditorEfl.cpp:
3116 (WebCore::Editor::pasteWithPasteboard):
3117 * editing/ios/EditorIOS.mm:
3118 (WebCore::Editor::pasteWithPasteboard):
3120 * editing/mac/EditorMac.mm:
3121 (WebCore::Editor::pasteWithPasteboard):
3122 (WebCore::Editor::readSelectionFromPasteboard):
3123 (WebCore::maybeCopyNodeAttributesToFragment): If the new DocumentFragment represents a single HTML node
3124 with the same tag name is the original HTML node, copy over most attributes from the original node.
3125 (WebCore::Editor::replaceNodeFromPasteboard): Create the fragment, run it through maybeCopyNodeAttributesToFragment.
3129 2014-05-12 Alex Christensen <achristensen@webkit.org>
3131 Progress on web timing.
3132 https://bugs.webkit.org/show_bug.cgi?id=132574
3134 Reviewed by Alexey Proskuryakov.
3137 Removed ResourceLoadTiming.cpp.
3139 Added linker symbols for ResourceLoadTiming.
3140 * WebCore.xcodeproj/project.pbxproj:
3141 * WebCore.vcxproj/WebCore.vcxproj:
3142 * WebCore.vcxproj/WebCore.vcxproj.filters:
3143 Removed ResourceLoadTiming.cpp.
3144 * inspector/InspectorResourceAgent.cpp:
3145 (WebCore::buildObjectForTiming):
3146 * inspector/protocol/Network.json:
3147 Updated ResourceTiming structure.
3148 * loader/DocumentLoadTiming.cpp:
3149 (WebCore::DocumentLoadTiming::setNavigationStart):
3150 * loader/DocumentLoadTiming.h:
3151 Deleted unused setNavigationStart function.
3152 * page/Performance.idl:
3154 * page/PerformanceResourceTiming.cpp:
3155 (WebCore::PerformanceResourceTiming::domainLookupStart):
3156 (WebCore::PerformanceResourceTiming::domainLookupEnd):
3157 (WebCore::PerformanceResourceTiming::connectStart):
3158 (WebCore::PerformanceResourceTiming::secureConnectionStart):
3159 (WebCore::PerformanceResourceTiming::responseEnd):
3160 Updated ResourceLoadTiming member variable names.
3161 (WebCore::PerformanceResourceTiming::responseStart):
3162 * page/PerformanceResourceTiming.h:
3163 * page/PerformanceResourceTiming.idl:
3164 Deleted responseStart because it is not in the spec.
3165 * page/PerformanceTiming.cpp:
3166 (WebCore::PerformanceTiming::domainLookupStart):
3167 (WebCore::PerformanceTiming::domainLookupEnd):
3168 (WebCore::PerformanceTiming::connectStart):
3169 (WebCore::PerformanceTiming::secureConnectionStart):
3170 (WebCore::PerformanceTiming::requestStart):
3171 (WebCore::PerformanceTiming::responseStart):
3172 Updated ResourceLoadTiming member variable names.
3173 (WebCore::PerformanceTiming::resourceLoadTimeRelativeToAbsolute):
3174 Use navigationStart as base for resource load times.
3175 * page/PerformanceTiming.idl:
3177 * platform/network/HTTPParsers.h:
3178 Removed unused class declarations.
3179 * platform/network/ResourceHandle.h:
3180 Moved soup request time from ResourceLoadTiming to ResourceHandle.
3181 * platform/network/ResourceLoadTiming.cpp: Removed.
3182 * platform/network/ResourceLoadTiming.h:
3183 (WebCore::ResourceLoadTiming::deepCopy):
3184 (WebCore::ResourceLoadTiming::operator==):
3185 (WebCore::ResourceLoadTiming::ResourceLoadTiming):
3186 Updated ResourceLoadTiming member variable names.
3187 * platform/network/mac/ResourceHandleMac.mm:
3188 (WebCore::ResourceHandle::createNSURLConnection):
3189 Collect timing data.
3190 * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
3191 (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
3192 * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm:
3193 (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]):
3194 Save timing data to a ResourceLoadTiming on the ResourceResponse.
3195 * platform/network/soup/ResourceHandleSoup.cpp:
3196 (WebCore::gotHeadersCallback):
3197 (WebCore::restartedCallback):
3198 (WebCore::milisecondsSinceRequest):
3199 (WebCore::ResourceHandle::didStartRequest):
3200 (WebCore::networkEventCallback):
3201 (WebCore::createSoupMessageForHandleAndRequest):
3202 (WebCore::ResourceHandle::sendPendingRequest):
3203 Updated ResourceLoadTiming member variable names.
3204 (WebCore::wroteBodyCallback): Deleted.
3206 2014-05-12 Dirk Schulze <krit@webkit.org>
3208 SVG outline property is broken and inefficient
3209 https://bugs.webkit.org/show_bug.cgi?id=113666
3211 Reviewed by Dean Jackson.
3213 Patch by Erik Dahlström backported from Blink.
3215 "[SVG2] css 'outline' property should apply to svg elements
3217 The 'outline' property was only partially working in SVG before
3218 this patch, this makes it work on text and text content child
3221 This makes SVG render the outlines as part of the foreground paint
3224 Partly based on Florin Malita's webkit patch https://bugs.webkit.org/show_bug.cgi?id=113666#c12."
3226 Tests: svg/custom/outline-stacking-expected.svg
3227 svg/custom/outline-stacking.svg
3228 svg/custom/rgba-color-outline.svg
3229 svg/text/text-outline-expected.svg
3230 svg/text/text-outline-rgba.html
3231 svg/text/text-outline.html
3232 svg/text/textpath-outline-expected.svg
3233 svg/text/textpath-outline.svg
3234 svg/text/tspan-multiple-outline.svg
3235 svg/text/tspan-outline-2-expected.svg
3236 svg/text/tspan-outline-2.svg
3237 svg/text/tspan-outline-expected.svg
3238 svg/text/tspan-outline.html
3240 * rendering/svg/RenderSVGContainer.cpp:
3241 (WebCore::RenderSVGContainer::paint): Draw outline in forground
3243 * rendering/svg/RenderSVGImage.cpp:
3244 (WebCore::RenderSVGImage::paint): Draw outline in forground
3246 * rendering/svg/RenderSVGRoot.cpp:
3247 (WebCore::RenderSVGRoot::paintReplaced): Pass paint offset.
3248 * rendering/svg/RenderSVGShape.cpp:
3249 (WebCore::RenderSVGShape::paint): Draw outline in forground
3251 * rendering/svg/RenderSVGText.cpp:
3252 (WebCore::RenderSVGText::paint): Draw outline in forground
3254 * rendering/svg/SVGInlineFlowBox.cpp:
3255 (WebCore::SVGInlineFlowBox::paint): Pass paint offset.
3256 * rendering/svg/SVGInlineTextBox.cpp:
3257 (WebCore::SVGInlineTextBox::paint): Draw outline in forground
3259 * rendering/svg/SVGRootInlineBox.cpp:
3260 (WebCore::SVGRootInlineBox::paint): Pass paint offset.
3262 2014-05-12 Beth Dakin <bdakin@apple.com>
3264 Layer for bottom overhang area needs to be offset by the topContentInset
3265 https://bugs.webkit.org/show_bug.cgi?id=132835
3267 <rdar://problem/16641115>
3269 Reviewed by Simon Fraser.
3271 Push this layer down by the topContentInset in addition to the root layer height,
3272 footer height, and header height.
3273 * rendering/RenderLayerCompositor.cpp:
3274 (WebCore::RenderLayerCompositor::updateLayerForBottomOverhangArea):
3276 2014-05-09 Jon Honeycutt <jhoneycutt@apple.com>
3278 REGRESSION (r167818): editing/inserting/typing-space-to-trigger-smart-link.html fails on WebKit1 bots
3280 <https://bugs.webkit.org/show_bug.cgi?id=132207>
3281 <rdar://problem/16730393>
3283 Reverts the previous workaround in favor of a more specific fix for the
3286 Reviewed by Darin Adler.
3288 * editing/ApplyStyleCommand.cpp:
3289 (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
3290 Check whether the run's start and end are still in the document, as
3291 removeConflictingInlineStyleFromRun() may have removed them.
3293 * editing/CompositeEditCommand.cpp:
3294 (WebCore::CompositeEditCommand::apply):
3295 Reverted previous workaround.
3296 (WebCore::ApplyEditCommand::ReentrancyGuard::isRecursiveCall): Deleted.
3297 (WebCore::ApplyEditCommand::ReentrancyGuard::Scope::Scope): Deleted.
3298 (WebCore::ApplyEditCommand::ReentrancyGuard::Scope::~Scope): Deleted.
3300 2014-05-12 Zan Dobersek <zdobersek@igalia.com>
3302 Clean up CrossThreadTask
3303 https://bugs.webkit.org/show_bug.cgi?id=132800
3305 Reviewed by Darin Adler.
3307 Remove the createCallbackTask overloads and the related CrossThreadTask helper classes.
3309 Instead, have one simple CrossThreadTask class that derives from ScriptExecutionContext::Task.
3310 Its templated constructor takes in the method and the variadic pack of parameters. The cross-thread
3311 copies of the parameters are then bound to that method and the resulting bind expression is used to
3312 initialize the base class. The bind expression is constructed with a placeholder for the
3313 ScriptExecutionContext* parameter that's provided through ScriptExecutionContext::Task::performTask().
3315 * Modules/websockets/ThreadableWebSocketChannelClientWrapper.cpp:
3316 (WebCore::ThreadableWebSocketChannelClientWrapper::didConnect):
3317 (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessage):
3318 (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveBinaryData):
3319 (WebCore::ThreadableWebSocketChannelClientWrapper::didUpdateBufferedAmount):
3320 (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshake):
3321 (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
3322 (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageError):
3323 (WebCore::ThreadableWebSocketChannelClientWrapper::processPendingTasks):
3324 * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
3325 (WebCore::WorkerThreadableWebSocketChannel::Peer::send):
3326 (WebCore::WorkerThreadableWebSocketChannel::Peer::bufferedAmount):
3327 (WebCore::WorkerThreadableWebSocketChannel::Peer::didConnect):
3328 (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveMessage):
3329 (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveBinaryData):
3330 (WebCore::WorkerThreadableWebSocketChannel::Peer::didUpdateBufferedAmount):
3331 (WebCore::WorkerThreadableWebSocketChannel::Peer::didStartClosingHandshake):
3332 (WebCore::WorkerThreadableWebSocketChannel::Peer::didClose):
3333 (WebCore::WorkerThreadableWebSocketChannel::Peer::didReceiveMessageError):
3334 (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadInitialize):
3335 (WebCore::WorkerThreadableWebSocketChannel::Bridge::initialize):
3336 (WebCore::WorkerThreadableWebSocketChannel::Bridge::connect):
3337 (WebCore::WorkerThreadableWebSocketChannel::Bridge::send):
3338 (WebCore::WorkerThreadableWebSocketChannel::Bridge::bufferedAmount):
3339 (WebCore::WorkerThreadableWebSocketChannel::Bridge::close):
3340 (WebCore::WorkerThreadableWebSocketChannel::Bridge::fail):
3341 (WebCore::WorkerThreadableWebSocketChannel::Bridge::disconnect):
3342 (WebCore::WorkerThreadableWebSocketChannel::Bridge::suspend):
3343 (WebCore::WorkerThreadableWebSocketChannel::Bridge::resume):
3344 * dom/CrossThreadTask.h:
3345 (WebCore::CrossThreadTask::CrossThreadTask):
3346 (WebCore::CrossThreadTask1::CrossThreadTask1): Deleted.
3347 (WebCore::CrossThreadTask1::performTask): Deleted.
3348 (WebCore::CrossThreadTask2::CrossThreadTask2): Deleted.
3349 (WebCore::CrossThreadTask2::performTask): Deleted.
3350 (WebCore::CrossThreadTask3::CrossThreadTask3): Deleted.
3351 (WebCore::CrossThreadTask3::performTask): Deleted.
3352 (WebCore::CrossThreadTask4::CrossThreadTask4): Deleted.
3353 (WebCore::CrossThreadTask4::performTask): Deleted.
3354 (WebCore::CrossThreadTask5::CrossThreadTask5): Deleted.
3355 (WebCore::CrossThreadTask5::performTask): Deleted.
3356 (WebCore::CrossThreadTask6::CrossThreadTask6): Deleted.
3357 (WebCore::CrossThreadTask6::performTask): Deleted.
3358 (WebCore::CrossThreadTask7::CrossThreadTask7): Deleted.
3359 (WebCore::CrossThreadTask7::performTask): Deleted.
3360 (WebCore::CrossThreadTask8::CrossThreadTask8): Deleted.
3361 (WebCore::CrossThreadTask8::performTask): Deleted.
3362 (WebCore::createCallbackTask): Deleted.
3363 * fileapi/FileReader.cpp:
3364 (WebCore::FileReader::abort):
3365 * loader/WorkerThreadableLoader.cpp:
3366 (WebCore::WorkerThreadableLoader::MainThreadBridge::MainThreadBridge):
3367 (WebCore::WorkerThreadableLoader::MainThreadBridge::destroy):
3368 (WebCore::WorkerThreadableLoader::MainThreadBridge::cancel):
3369 (WebCore::WorkerThreadableLoader::MainThreadBridge::didSendData):
3370 (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveResponse):
3371 (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveData):
3372 (WebCore::WorkerThreadableLoader::MainThreadBridge::didFinishLoading):
3373 (WebCore::WorkerThreadableLoader::MainThreadBridge::didFail):
3374 (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailAccessControlCheck):
3375 (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailRedirectCheck):
3376 * loader/WorkerThreadableLoader.h:
3377 * loader/cache/MemoryCache.cpp:
3378 (WebCore::MemoryCache::removeRequestFromCache):
3379 (WebCore::MemoryCache::removeRequestFromSessionCaches):
3380 * workers/DefaultSharedWorkerRepository.cpp:
3381 (WebCore::SharedWorkerProxy::postExceptionToWorkerObject):
3382 (WebCore::SharedWorkerProxy::postConsoleMessageToWorkerObject):
3383 * workers/WorkerMessagingProxy.cpp:
3384 (WebCore::WorkerMessagingProxy::postConsoleMessageToWorkerObject):
3385 (WebCore::WorkerMessagingProxy::workerObjectDestroyed):
3386 (WebCore::WorkerMessagingProxy::connectToInspector):
3387 (WebCore::WorkerMessagingProxy::disconnectFromInspector):
3388 (WebCore::WorkerMessagingProxy::sendMessageToInspector):
3390 2014-05-12 Alex Christensen <achristensen@webkit.org>
3392 Implement EXT_shader_texture_lod in WebGL.
3393 https://bugs.webkit.org/show_bug.cgi?id=128985
3394 <rdar://problem/16111396>
3396 Based on Chromium patch by bajones@chromium.org.
3397 https://src.chromium.org/viewvc/blink?revision=171465&view=revision
3399 Reviewed by Dean Jackson.
3401 Test: webgl/conformance/extensions/ext-shader-texture-lod.html
3404 * DerivedSources.cpp:
3405 * DerivedSources.make:
3406 * WebCore.vcxproj/WebCore.vcxproj:
3407 * WebCore.vcxproj/WebCore.vcxproj.filters:
3408 * WebCore.xcodeproj/project.pbxproj:
3409 Added new EXTShaderTextureLOD files.
3410 * bindings/js/JSWebGLRenderingContextCustom.cpp:
3412 Added EXTShaderTextureLOD.
3413 * html/canvas/EXTShaderTextureLOD.cpp: Added.
3414 (WebCore::EXTShaderTextureLOD::EXTShaderTextureLOD):
3415 (WebCore::EXTShaderTextureLOD::~EXTShaderTextureLOD):
3416 (WebCore::EXTShaderTextureLOD::getName):
3417 * html/canvas/EXTShaderTextureLOD.h: Added.
3418 * html/canvas/EXTShaderTextureLOD.idl: Added.
3419 * html/canvas/WebGLExtension.h:
3420 Added EXTShaderTextureLODName.
3421 * html/canvas/WebGLObject.cpp:
3422 Removed unused inclusion of EXTTextureFilterAnisotropic.h.
3423 * html/canvas/WebGLRenderingContext.cpp:
3424 (WebCore::WebGLRenderingContext::getExtension):
3425 Added EXT_shader_texture_lod.
3426 * html/canvas/WebGLRenderingContext.h:
3427 Added a EXTShaderTextureLOD member variable.
3429 2014-05-12 Martin Hock <mhock@apple.com>
3431 Disallow drag and drop of non-displayable resources.
3432 https://bugs.webkit.org/show_bug.cgi?id=132745
3433 <rdar://problem/10562662>
3435 Reviewed by Alexey Proskuryakov.
3437 Test: http/tests/security/drag-drop-local-file.html
3439 * page/DragController.cpp:
3440 (WebCore::DragController::startDrag):
3442 2014-05-12 Jozsef Berta <jberta.u-szeged@partner.samsung.com>
3444 WinCairo buildfix after r168611
3445 https://bugs.webkit.org/show_bug.cgi?id=132825
3447 Reviewed by Darin Adler.
3449 * platform/network/curl/CurlDownload.cpp:
3450 (WebCore::CurlDownloadManager::downloadThread):
3451 (WebCore::CurlDownload::didReceiveHeader):
3452 (WebCore::CurlDownload::didReceiveData):
3454 2014-05-12 Antti Koivisto <antti@apple.com>
3456 REGRESSION (r159560): Text clips on tile border if line-height < font-size
3457 https://bugs.webkit.org/show_bug.cgi?id=132822
3459 Reviewed by Andreas Kling.
3461 The first line of simple line layout run range was miscomputed.
3463 Test: fast/text/simple-lines-range-low-line-height.html
3465 * rendering/SimpleLineLayoutResolver.h:
3466 (WebCore::SimpleLineLayout::RunResolver::lineIndexForHeight):
3468 Lines may overlap if line-height < font-size. Apply different adjustment when searching for range begin
3469 so that overflowing earlier lines are taken into account.
3471 (WebCore::SimpleLineLayout::RunResolver::rangeForRect):
3473 2014-05-12 Radu Stavila <stavila@adobe.com>
3475 Invalid information remaining in lineToRegion map of RenderFlowThread.
3476 https://bugs.webkit.org/show_bug.cgi?id=132690
3478 Reviewed by Antti Koivisto.
3480 Test: fast/multicol/newmulticol/lines-region-map-crash.html
3482 * rendering/RenderFlowThread.cpp:
3483 (WebCore::RenderFlowThread::deleteLines):
3484 * rendering/RenderFlowThread.h:
3486 2014-05-12 Zan Dobersek <zdobersek@igalia.com>
3488 Clean up MainThreadTask
3489 https://bugs.webkit.org/show_bug.cgi?id=132799
3491 Reviewed by Darin Adler.
3493 Only have one simple MainThreadTask class that derives from std::function<void ()>.
3494 Its templated constructor takes in the method and a variadic pack of parameters.
3495 The cross-thread copies of the parameter are then bound to the given method through
3496 std::bind(), with the resulting bind expression used to initialize the base
3497 std::function<void ()> class.
3499 The WebCore::callOnMainThread() functions and the helper classes are removed in favor
3500 of passing MainThreadTask rvalues directly to WTF::callOnMainThread().
3502 * fileapi/AsyncFileStream.cpp:
3503 (WebCore::AsyncFileStream::startOnFileThread):
3504 (WebCore::AsyncFileStream::stopOnFileThread):
3505 (WebCore::AsyncFileStream::getSizeOnFileThread):
3506 (WebCore::AsyncFileStream::openForReadOnFileThread):
3507 (WebCore::AsyncFileStream::openForWriteOnFileThread):
3508 (WebCore::AsyncFileStream::readOnFileThread):
3509 (WebCore::AsyncFileStream::writeOnFileThread):
3510 (WebCore::AsyncFileStream::truncateOnFileThread):
3511 * platform/MainThreadTask.h:
3512 (WebCore::MainThreadTask::MainThreadTask):
3513 (WebCore::MainThreadTaskBase::MainThreadTaskBase): Deleted.
3514 (WebCore::MainThreadTaskBase::~MainThreadTaskBase): Deleted.
3515 (WebCore::MainThreadTask1::create): Deleted.
3516 (WebCore::MainThreadTask1::MainThreadTask1): Deleted.
3517 (WebCore::MainThreadTask2::create): Deleted.
3518 (WebCore::MainThreadTask2::MainThreadTask2): Deleted.
3519 (WebCore::MainThreadTask3::create): Deleted.
3520 (WebCore::MainThreadTask3::MainThreadTask3): Deleted.
3521 (WebCore::MainThreadTask4::create): Deleted.
3522 (WebCore::MainThreadTask4::MainThreadTask4): Deleted.
3523 (WebCore::MainThreadTask5::create): Deleted.
3524 (WebCore::MainThreadTask5::MainThreadTask5): Deleted.
3525 (WebCore::MainThreadTask6::create): Deleted.
3526 (WebCore::MainThreadTask6::MainThreadTask6): Deleted.
3527 (WebCore::MainThreadTask7::create): Deleted.
3528 (WebCore::MainThreadTask7::MainThreadTask7): Deleted.
3529 (WebCore::MainThreadTask8::create): Deleted.
3530 (WebCore::MainThreadTask8::MainThreadTask8): Deleted.
3531 (WebCore::executeMainThreadTask): Deleted.
3532 (WebCore::callOnMainThread): Deleted.
3534 2014-05-11 Zan Dobersek <zdobersek@igalia.com>
3536 Simplify FileThread::Task usage
3537 https://bugs.webkit.org/show_bug.cgi?id=132798
3539 Reviewed by Darin Adler.
3541 Remove the createFileThreadTask functions and the related FileThreadTask helper classes.
3543 Instead, the FileThread::Task class now has a templated constructor that takes in a pointer
3544 to the object instance, a method, and a variadic pack of parameters. The pointer and the
3545 cross-thread copies of all the parameters are then bound to the given method through std::bind().
3547 Instead of createFileThreadTask, std::make_unique<>() should be used to construct unique pointers
3548 that wrap FileThread::Task objects.
3550 * WebCore.vcxproj/WebCore.vcxproj:
3551 * WebCore.vcxproj/WebCore.vcxproj.filters:
3552 * WebCore.xcodeproj/project.pbxproj:
3553 * fileapi/AsyncFileStream.cpp:
3554 (WebCore::AsyncFileStream::create):
3555 (WebCore::AsyncFileStream::stop):
3556 (WebCore::AsyncFileStream::getSize):
3557 (WebCore::AsyncFileStream::openForRead):
3558 (WebCore::AsyncFileStream::openForWrite):
3559 (WebCore::AsyncFileStream::close):
3560 (WebCore::AsyncFileStream::read):
3561 (WebCore::AsyncFileStream::write):
3562 (WebCore::AsyncFileStream::truncate):
3563 * fileapi/FileThread.h:
3564 (WebCore::FileThread::Task::Task):
3565 (WebCore::FileThread::Task::performTask):
3566 (WebCore::FileThread::Task::~Task): Deleted.
3567 * fileapi/FileThreadTask.h: Removed.
3569 2014-05-11 Benjamin Poulain <benjamin@webkit.org>
3571 Do not create a temporary string to append the SVGLength's unit
3572 https://bugs.webkit.org/show_bug.cgi?id=132807
3574 Reviewed by Geoffrey Garen.
3576 * svg/SVGLength.cpp:
3577 (WebCore::lengthTypeToString):
3578 The caller just append the string to a number string. The function
3579 lengthTypeToString() was creating a new WTF::String from scratch,
3580 copied the characters to make a new string, and destroyed the WTF::String.
3582 Instead, just append the string literal.
3584 2014-05-11 Yusuke Suzuki <utatane.tea@gmail.com>
3586 CSS JIT: reduce cost of computing backtracking height
3587 https://bugs.webkit.org/show_bug.cgi?id=132546
3589 Reviewed by Benjamin Poulain.
3591 Because compiler previously compute backtracking height for
3592 previous child fragment, by leveraging this, we can limit the
3593 `maxPrefixSize` for `computeBacktrackingHeightFromDescendant`.
3595 For example, consider selector "c>a>b>d>a>b e"'s descendant chain,
3598 At the <a> position, we have matching pattern [b, a, d, b, a] and
3599 calculate the backtracking height by following method.
3601 pattern: [b, a, d, b, a]
3602 candidate0: [b, a, d, b] => Not matched.
3603 candidate1: [b, a, d] => Not matched.
3604 candidate2: [b, a] => Matched against the pattern.
3606 At this time, first candidate0's pattern size is `pattern.size() - 1`.
3607 And get backtracking height from descendant 3, that is
3608 `pattern.size() - candidate.size()`, `5 - 2`.
3610 And next, at the <c> position, we calcucate the backtracking height
3613 pattern: [b, a, d, b, a, c]
3614 candidate0: [b, a, d, b, a] => Not matched.
3615 candidate1: [b, a, d, b] => Not matched.
3616 candidate2: [b, a, d] => Not matched.
3617 candidate3: [b, a] => Not matched.
3618 candidate4: [b] => Not matched.
3619 candidate5: [] => Matched against the pattern.
3621 Then, we get the backtracking height, which is 6 (6 - 0).
3622 However, in the above case, we already know that attempts from candidate0
3623 to candidate1 always fail, since parts of these are already tested at
3624 the <b> position trial and we know they don't match.
3626 So in this case, we should start this computation from candidate2,
3629 pattern: [b, a, d, b, a, c]
3630 candidate2: [b, a, d] => Not matched.
3631 candidate3: [b, a] => Not matched.
3632 candidate4: [b] => Not matched.
3633 candidate5: [] => Matched against the pattern.
3635 We can start computation with candidate size
3636 `pattern.size() - previousChildFragmentBacktrackingHeight`.
3637 In this example, `pattern.size()` is 6 and
3638 `previousChildFragmentBacktrackingHeight` is 3, so candidate size is
3639 3, that is candidate2.
3641 * cssjit/SelectorCompiler.cpp:
3642 (WebCore::SelectorCompiler::computeBacktrackingStartHeightFromDescendant):
3643 (WebCore::SelectorCompiler::computeBacktrackingHeightFromDescendant):
3645 2014-05-11 Beth Dakin <bdakin@apple.com>
3647 Headers and footers are not positioned correctly with topContentInset
3648 https://bugs.webkit.org/show_bug.cgi?id=132787
3650 <rdar://problem/16641115>
3652 Reviewed by Tim Horton.
3654 Headers and footers need to take the inset into account, and they also need to
3655 factor in the fact that the root layer moves around now too.
3657 The existing yPositionForRootContentLayer() is actually the right calculation for
3658 the header layer. The root content layer wants that value, but pushed down by the
3659 header height. Now there are static functions for both of them and the footer to
3660 avoid duplicated code in the three spots where we need this information.
3661 * page/FrameView.cpp:
3662 (WebCore::FrameView::yPositionForHeaderLayer):
3663 (WebCore::FrameView::yPositionForRootContentLayer):
3664 (WebCore::FrameView::yPositionForFooterLayer):
3667 Use the static functions to compute the layer positions.
3668 * page/scrolling/AsyncScrollingCoordinator.cpp:
3669 (WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
3671 How did headers ever work with this bug?? I don’t know. We need to return that
3673 * page/scrolling/ScrollingCoordinator.cpp:
3674 (WebCore::ScrollingCoordinator::headerLayerForFrameView):
3676 Use the static functions to compute the layer positions.
3677 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
3678 (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
3679 * rendering/RenderLayerCompositor.cpp:
3680 (WebCore::RenderLayerCompositor::updateRootLayerPosition):
3681 (WebCore::RenderLayerCompositor::updateLayerForHeader):
3682 (WebCore::RenderLayerCompositor::updateLayerForFooter):
3684 2014-05-11 Zalan Bujtas <zalan@apple.com>
3686 Subpixel rendering[iOS]: <select> decoration is misaligned when the renderer is on subpixel position.
3687 https://bugs.webkit.org/show_bug.cgi?id=132779
3688 <rdar://problem/16631071>
3690 Reviewed by Simon Fraser.
3692 Push <select> theme decoration's rect to device pixel position to ensure
3693 that the theme bounds are aligned with the renderer's bounds. (in painting terms)
3694 However, as the decoration code paints multiple items, they all need to use snapped
3695 final coordinates for painting : tracked here https://bugs.webkit.org/show_bug.cgi?id=132780
3696 This patch also changes the padding values for <select> [iOS] to compensate for the integer
3697 truncation that happened before subpixel.
3703 * platform/efl/RenderThemeEfl.cpp:
3704 (WebCore::RenderThemeEfl::paintMenuListButtonDecorations):
3705 * platform/efl/RenderThemeEfl.h:
3706 * platform/gtk/RenderThemeGtk.cpp:
3707 (WebCore::RenderThemeGtk::paintMenuListButtonDecorations):
3708 * platform/gtk/RenderThemeGtk.h:
3709 * rendering/RenderTheme.cpp:
3710 (WebCore::RenderTheme::paintDecorations):
3711 * rendering/RenderTheme.h:
3712 (WebCore::RenderTheme::paintMenuListButtonDecorations):
3713 * rendering/RenderThemeIOS.h:
3714 * rendering/RenderThemeIOS.mm:
3715 (WebCore::RenderThemeIOS::paintMenuListButtonDecorations):
3716 * rendering/RenderThemeMac.h:
3717 * rendering/RenderThemeMac.mm:
3718 (WebCore::RenderThemeMac::paintMenuListButtonDecorations):
3719 * rendering/RenderThemeSafari.cpp:
3720 (WebCore::RenderThemeSafari::paintMenuListButtonDecorations):
3721 * rendering/RenderThemeSafari.h:
3722 * rendering/RenderThemeWin.cpp:
3723 (WebCore::RenderThemeWin::paintMenuList):
3724 (WebCore::RenderThemeWin::paintMenuListButtonDecorations):
3725 * rendering/RenderThemeWin.h:
3727 2014-05-11 Zan Dobersek <zdobersek@igalia.com>
3729 Move Source/WebCore/workers/ code to std::unique_ptr
3730 https://bugs.webkit.org/show_bug.cgi?id=132401
3732 Reviewed by Darin Adler.
3734 Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/workers (and related places)
3735 with std::unique_ptr.
3737 * bindings/js/JSDOMWindowCustom.cpp:
3738 (WebCore::JSDOMWindow::setTimeout):
3739 (WebCore::JSDOMWindow::setInterval):
3740 * bindings/js/JSWorkerGlobalScopeCustom.cpp:
3741 (WebCore::JSWorkerGlobalScope::setTimeout):
3742 (WebCore::JSWorkerGlobalScope::setInterval):
3743 * bindings/js/ScheduledAction.cpp:
3744 (WebCore::ScheduledAction::create):
3745 * bindings/js/ScheduledAction.h:
3746 * page/DOMTimer.cpp:
3747 (WebCore::DOMTimer::DOMTimer):
3748 (WebCore::DOMTimer::install):
3749 (WebCore::DOMTimer::fired):
3750 (WebCore::DOMTimer::didStop):
3752 * page/DOMWindow.cpp:
3753 (WebCore::DOMWindow::setTimeout):
3754 (WebCore::DOMWindow::setInterval):
3756 * workers/WorkerEventQueue.h:
3757 * workers/WorkerGlobalScope.cpp:
3758 (WebCore::WorkerGlobalScope::WorkerGlobalScope):
3759 (WebCore::WorkerGlobalScope::setTimeout):
3760 (WebCore::WorkerGlobalScope::setInterval):
3761 * workers/WorkerGlobalScope.h:
3762 (WebCore::WorkerGlobalScope::clearScript):
3763 * workers/WorkerLoaderProxy.h:
3764 * workers/WorkerMessagingProxy.h:
3765 * workers/WorkerRunLoop.cpp:
3766 (WebCore::WorkerRunLoop::WorkerRunLoop):
3767 * workers/WorkerRunLoop.h:
3768 * workers/WorkerScriptLoader.cpp:
3769 (WebCore::WorkerScriptLoader::loadSynchronously):
3770 (WebCore::WorkerScriptLoader::loadAsynchronously):
3771 (WebCore::WorkerScriptLoader::createResourceRequest):
3772 * workers/WorkerScriptLoader.h:
3773 * workers/WorkerThread.cpp:
3774 (WebCore::WorkerThread::WorkerThread):
3775 (WebCore::WorkerThread::workerThread):
3776 (WebCore::WorkerThreadStartupData::create): Deleted.
3777 * workers/WorkerThread.h:
3779 2014-05-09 Myles C. Maxfield <litherum@gmail.com>
3781 [Mac] [iOS] Underlines are too low
3782 https://bugs.webkit.org/show_bug.cgi?id=132770
3784 Reviewed by Darin Adler.
3786 computeUnderlineOffset() inside InlineTextBox.cpp lowers underlines from text
3787 baseline by a value that is proportional to the font size. However, this
3788 lowering was done a second time in
3789 GraphicsContext::computeLineBoundsAndAntialiasingModeForText(). This patch
3790 removes this second, platform-dependent lowering.
3792 This duplication was caused by merging iOS into open source, where iOS used
3793 the GraphicsContext approach and open source used the InlineTextBox approach.
3795 Covered by fast/css3-text/css3-text-decoration/text-decoration-thickness.html.
3797 * platform/graphics/GraphicsContext.cpp:
3798 (WebCore::GraphicsContext::computeLineBoundsAndAntialiasingModeForText): Remove
3799 redundant lowering code
3800 * rendering/InlineTextBox.cpp:
3801 (WebCore::InlineTextBox::paintDecoration): Clean up textDecorationThickness
3804 2014-05-11 Antti Koivisto <antti@apple.com>
3806 Text with simple line layout not getting pushed below float when there is not enough space for it
3807 https://bugs.webkit.org/show_bug.cgi?id=126991
3809 Reviewed by Andreas Kling.
3811 Tests: fast/text/simple-lines-intruding-wide-float-dynamic.html
3812 fast/text/simple-lines-intruding-wide-float.html
3814 * rendering/RenderBlockFlow.cpp:
3815 (WebCore::RenderBlockFlow::markLinesDirtyInBlockRange):
3817 Invalidate the line layout path when floats change. We need to check SimpleLineLayout::canUseFor again as
3818 intruding floats may make this flow ineligible to use the path.
3820 * rendering/RenderBlockFlow.h:
3821 (WebCore::RenderBlockFlow::floatingObjectSet):
3822 * rendering/SimpleLineLayout.cpp:
3823 (WebCore::SimpleLineLayout::canUseFor):
3825 Test the top positions of all floats for case that would push text below the float instead of just testing
3826 the first line. We may have floats in the middle of the paragraph too.
3828 2014-05-11 peavo@outlook.com <peavo@outlook.com>
3830 WinCairo crashes on acid3 test
3831 https://bugs.webkit.org/show_bug.cgi?id=131364
3833 Reviewed by Brent Fulgham.
3835 When the 304 (Not-modified) response is received, the Curl backend should look up the cached response,
3836 and call the client method didReceiveResponse with the cached response, instead of the 304 response.
3837 Otherwise the response will contain an empty MIME type, which causes the request to be cancelled, and the client deleted.
3838 When the Curl cache manager then accesses the client afterwards, it is deleted, and we crash.
3840 * platform/network/curl/CurlCacheManager.cpp:
3841 (WebCore::CurlCacheManager::didReceiveResponse): Return early if request is cancelled.
3842 (WebCore::CurlCacheManager::getCachedResponse): Added method to get cached response.
3843 * platform/network/curl/CurlCacheManager.h: Ditto.
3844 * platform/network/curl/ResourceHandleManager.cpp:
3845 (WebCore::headerCallback): When 304 response is received, look up cached response, and use it.
3847 2014-05-10 Tim Horton <timothy_horton@apple.com>
3849 [WKWebView _updateScrollViewBackground] churns UI-and-CGColors while repainting
3850 https://bugs.webkit.org/show_bug.cgi?id=132793
3851 <rdar://problem/16877870>
3853 Reviewed by Dan Bernstein.
3856 Export a Color convenience function.
3858 2014-05-10 Commit Queue <commit-queue@webkit.org>
3860 Unreviewed, rolling out r168578.
3861 https://bugs.webkit.org/show_bug.cgi?id=132789
3863 Speculative rollout since this appears to break PLT3.
3864 (Requested by kling on #webkit).
3868 "Move Source/WebCore/workers/ code to std::unique_ptr"
3869 https://bugs.webkit.org/show_bug.cgi?id=132401
3870 http://trac.webkit.org/changeset/168578
3872 2014-05-10 Darin Adler <darin@apple.com>
3874 REGRESSION (r166853): fast/preloader/document-write.html is very flaky
3875 https://bugs.webkit.org/show_bug.cgi?id=130942
3877 Reviewed by Anders Carlsson.
3879 * style/StyleResolveTree.cpp:
3880 (WebCore::Style::suspendMemoryCacheClientCalls): Use a RefPtr to the main
3881 frame as a weak pointer to a Page that will work unless the page is destroyed.
3882 The old code tried to do it with a RefPtr to a document, but as the FIXME
3883 points out, that won't work if the document is disassociated with its frame.
3885 2014-05-10 Anders Carlsson <andersca@apple.com>
3887 Block exceptions when trying to convert attributed strings to RTF and RTFD
3888 https://bugs.webkit.org/show_bug.cgi?id=132778
3889 <rdar://problem/16675805>
3891 Reviewed by Darin Adler.
3893 When the iOS WebHTMLConverter was upstreamed, converting some attributed strings to RTF and RTFD
3894 started throwing Objective-C exceptions (see <rdar://problem/16876920>).
3896 In WebKit2, we now crash on unhandled exceptions so work around that crash by adding exception blocking macros.
3898 * editing/ios/EditorIOS.mm:
3899 (WebCore::dataInRTFDFormat):
3900 (WebCore::dataInRTFFormat):
3901 * editing/mac/EditorMac.mm:
3902 (WebCore::dataInRTFDFormat):
3903 (WebCore::dataInRTFFormat):
3905 2014-05-10 Zan Dobersek <zdobersek@igalia.com>
3907 Move Source/WebCore/workers/ code to std::unique_ptr
3908 https://bugs.webkit.org/show_bug.cgi?id=132401
3910 Reviewed by Andreas Kling.
3912 Replace uses of OwnPtr and PassOwnPtr in code under Source/WebCore/workers (and related places)
3913 with std::unique_ptr.
3915 * bindings/js/JSDOMWindowCustom.cpp:
3916 (WebCore::JSDOMWindow::setTimeout):
3917 (WebCore::JSDOMWindow::setInterval):
3918 * bindings/js/JSWorkerGlobalScopeCustom.cpp:
3919 (WebCore::JSWorkerGlobalScope::setTimeout):
3920 (WebCore::JSWorkerGlobalScope::setInterval):
3921 * bindings/js/ScheduledAction.cpp:
3922 (WebCore::ScheduledAction::create):
3923 * bindings/js/ScheduledAction.h:
3924 * page/DOMTimer.cpp:
3925 (WebCore::DOMTimer::DOMTimer):
3926 (WebCore::DOMTimer::install):
3927 (WebCore::DOMTimer::fired):
3928 (WebCore::DOMTimer::didStop):
3930 * page/DOMWindow.cpp:
3931 (WebCore::DOMWindow::setTimeout):
3932 (WebCore::DOMWindow::setInterval):
3934 * workers/WorkerEventQueue.h:
3935 * workers/WorkerGlobalScope.cpp:
3936 (WebCore::WorkerGlobalScope::WorkerGlobalScope):
3937 (WebCore::WorkerGlobalScope::setTimeout):
3938 (WebCore::WorkerGlobalScope::setInterval):
3939 * workers/WorkerGlobalScope.h:
3940 (WebCore::WorkerGlobalScope::clearScript):
3941 * workers/WorkerLoaderProxy.h:
3942 * workers/WorkerMessagingProxy.h:
3943 * workers/WorkerRunLoop.cpp:
3944 (WebCore::WorkerRunLoop::WorkerRunLoop):
3945 * workers/WorkerRunLoop.h:
3946 * workers/WorkerScriptLoader.cpp:
3947 (WebCore::WorkerScriptLoader::loadSynchronously):
3948 (WebCore::WorkerScriptLoader::loadAsynchronously):
3949 (WebCore::WorkerScriptLoader::createResourceRequest):
3950 * workers/WorkerScriptLoader.h:
3951 * workers/WorkerThread.cpp:
3952 (WebCore::WorkerThread::WorkerThread):
3953 (WebCore::WorkerThread::workerThread):
3954 (WebCore::WorkerThreadStartupData::create): Deleted.
3955 * workers/WorkerThread.h:
3957 2014-05-09 Dean Jackson <dino@apple.com>
3959 -webkit-filter prevents rendering at retina scale
3960 https://bugs.webkit.org/show_bug.cgi?id=93471
3962 Reviewed by Dirk Schulze.
3964 Implement 2x support for filters that go through
3965 the -webkit-filter property. This includes all
3966 shorthand filters, and any referenced SVG-style filters
3967 (as long as they use only the supported subset of
3968 operations - basically the same as is exposed for