1 2014-01-05 Andreas Kling <akling@apple.com>
3 Use lineageOfType to simplify two rendering helpers.
4 <https://webkit.org/b/126498>
6 Reviewed by Antti Koivisto.
8 * rendering/RenderRuby.cpp:
9 (WebCore::findRubyRunParent):
10 * rendering/svg/SVGRenderSupport.cpp:
11 (WebCore::SVGRenderSupport::findTreeRootObject):
13 Simplify two functions that walk their parent chain to find the
14 closest ancestor of a certain type.
16 * rendering/RenderRubyRun.h:
18 Add requisite isRendererOfType<RenderRubyRun>().
20 2014-01-05 Csaba Osztrogonác <ossy@webkit.org>
22 Fix the Mac build too.
24 * page/PageThrottler.h:
26 2014-01-05 Csaba Osztrogonác <ossy@webkit.org>
28 Weekend URTBF after r161319 to make non Mac builds work again.
30 * page/PageThrottler.h:
32 2014-01-05 Gavin Barraclough <barraclough@apple.com>
34 Move process suppression of WebProcess to Page (from UIProcess)
35 https://bugs.webkit.org/show_bug.cgi?id=126480
37 Reviewed by Sam Weinig.
39 Let each page take a UserActivity rather than having to coalesce this state, and take different activity
40 tokens for normal visibility and suppression disabled, so we can see why the process is not suppressed.
44 (WebCore::Page::setIsVisuallyIdle):
46 - setThrottled -> setIsVisuallyIdle.
47 * page/PageThrottler.cpp:
48 (WebCore::PageThrottler::PageThrottler):
49 - Initialize m_visuallyNonIdle.
50 (WebCore::PageThrottler::~PageThrottler):
51 - setThrottled -> setIsVisuallyIdle.
52 (WebCore::PageThrottler::setIsVisuallyIdle):
53 - Use m_visuallyNonIdle to disable supression when the page is not visually idle.
54 * page/PageThrottler.h:
55 - setThrottled -> setIsVisuallyIdle, added m_visuallyNonIdle.
57 2014-01-04 Sam Weinig <sam@webkit.org>
59 Move a few more functions from RenderBlock to RenderBlockFlow
60 https://bugs.webkit.org/show_bug.cgi?id=126494
62 Reviewed by Andreas Kling.
64 * rendering/RenderBlock.h:
65 * rendering/RenderBlockFlow.h:
66 (WebCore::RenderBlockFlow::adjustInlineDirectionLineBounds):
67 * rendering/RenderBlockLineLayout.cpp:
68 (WebCore::RenderBlockFlow::textAlignmentForLine):
69 (WebCore::RenderBlockFlow::updateLogicalWidthForAlignment):
70 (WebCore::RenderBlockFlow::startAlignedOffsetForLine):
71 These are only used by RenderBlockFlow, so move them there.
73 2014-01-04 Simon Fraser <simon.fraser@apple.com>
75 Prepare the ScrollingTree for remote use
76 https://bugs.webkit.org/show_bug.cgi?id=126493
78 Reviewed by Sam Weinig.
80 When committing the scrolling tree, we clone the ScrollingStateTree
81 to hand off to another thread, or (in future) to encode to send to the
82 UI process. During this cloning process, two types of layer transformations
83 take place: for threaded scrolling, we replace GraphicsLayer with PlatformLayers.
84 For remote scrolling, we'll replace GraphicsLayers with PlatformLayerIDs.
85 Allow the ScrollingCoordinator to specify which type of transformation occurs
86 by giving ScrollingStateTree a LayerRepresentation::Type member,
87 which is consulted during ScrollingStateNode cloning.
89 Also only copy layers that have changed to avoid setting dirty bits.
91 Expose some other stuff on ScrollingStateTree which will be needed for
94 * page/scrolling/ScrollingStateFixedNode.cpp:
95 (WebCore::ScrollingStateFixedNode::syncLayerPositionForViewportRect):
96 * page/scrolling/ScrollingStateNode.cpp:
97 (WebCore::ScrollingStateNode::ScrollingStateNode):
98 * page/scrolling/ScrollingStateNode.h:
99 (WebCore::LayerRepresentation::operator GraphicsLayer::PlatformLayerID):
100 (WebCore::LayerRepresentation::toRepresentation):
101 (WebCore::ScrollingStateNode::changedProperties):
102 (WebCore::ScrollingStateNode::setChangedProperties):
103 (WebCore::ScrollingStateNode::parentNodeID):
104 * page/scrolling/ScrollingStateScrollingNode.cpp:
105 (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
106 * page/scrolling/ScrollingStateStickyNode.cpp:
107 (WebCore::ScrollingStateStickyNode::syncLayerPositionForViewportRect):
108 * page/scrolling/ScrollingStateTree.cpp:
109 (WebCore::ScrollingStateTree::ScrollingStateTree):
110 (WebCore::ScrollingStateTree::commit):
111 (WebCore::ScrollingStateTree::setRemovedNodes):
112 (WebCore::ScrollingStateTree::stateNodeForID):
113 * page/scrolling/ScrollingStateTree.h:
114 (WebCore::ScrollingStateTree::nodeCount):
115 (WebCore::ScrollingStateTree::nodeMap):
116 (WebCore::ScrollingStateTree::preferredLayerRepresentation):
117 (WebCore::ScrollingStateTree::setPreferredLayerRepresentation):
118 * page/scrolling/mac/ScrollingCoordinatorMac.mm:
119 (WebCore::ScrollingCoordinatorMac::commitTreeState):
121 2014-01-04 Sam Weinig <sam@webkit.org>
123 Move LineBreaker functions to LineBreaker.cpp
124 https://bugs.webkit.org/show_bug.cgi?id=126491
126 Reviewed by Simon Fraser.
128 - Moves LineBreaker::nextLineBreak() and LineBreaker::nextSegmentBreak() to
129 LineBreaker.cpp from RenderBlockLineLayout.cpp
130 - Moves requiresIndent() to LineWidth.h/cpp from RenderBlockLineLayout.cpp
132 - Adds missing inline specifier to BreakingContext::handleEndOfLine() to avoid
135 * rendering/RenderBlockLineLayout.cpp:
136 (WebCore::updateLogicalInlinePositions):
137 (WebCore::RenderBlockFlow::computeInlineDirectionPositionsForLine):
138 * rendering/line/BreakingContextInlineHeaders.h:
139 (WebCore::BreakingContext::handleEndOfLine):
140 * rendering/line/LineBreaker.cpp:
141 (WebCore::LineBreaker::nextLineBreak):
142 (WebCore::LineBreaker::nextSegmentBreak):
143 * rendering/line/LineWidth.cpp:
144 (WebCore::requiresIndent):
145 * rendering/line/LineWidth.h:
147 2014-01-04 Martin Robinson <mrobinson@igalia.com>
149 [GTK] [CMake] Fix the video and audio build
150 https://bugs.webkit.org/show_bug.cgi?id=126464
152 Reviewed by Philippe Normand.
154 * PlatformGTK.cmake: Complete the audio and video source lists.
156 2014-01-04 Zan Dobersek <zdobersek@igalia.com>
158 Explicitly use the std:: nested name specifier when using std::pair, std::make_pair
159 https://bugs.webkit.org/show_bug.cgi?id=126439
161 Reviewed by Andreas Kling.
163 Instead of relying on std::pair and std::make_pair symbols being present in the current scope
164 through the pair and make_pair symbols, the std:: specifier should be used explicitly.
166 * Modules/webdatabase/DatabaseTracker.cpp:
167 (WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
168 * accessibility/AXObjectCache.h:
169 * accessibility/AccessibilityARIAGridCell.cpp:
170 (WebCore::AccessibilityARIAGridCell::rowIndexRange):
171 (WebCore::AccessibilityARIAGridCell::columnIndexRange):
172 * accessibility/AccessibilityARIAGridCell.h:
173 * accessibility/AccessibilityObject.h:
174 * accessibility/AccessibilityRenderObject.cpp:
175 (WebCore::AccessibilityRenderObject::mathPrescripts):
176 (WebCore::AccessibilityRenderObject::mathPostscripts):
177 * accessibility/AccessibilityTable.cpp:
178 (WebCore::AccessibilityTable::cellForColumnAndRow):
179 * accessibility/AccessibilityTableCell.cpp:
180 (WebCore::AccessibilityTableCell::rowIndexRange):
181 (WebCore::AccessibilityTableCell::columnIndexRange):
182 * accessibility/AccessibilityTableCell.h:
183 * accessibility/atk/WebKitAccessibleInterfaceTable.cpp:
184 (webkitAccessibleTableGetColumnAtIndex):
185 (webkitAccessibleTableGetRowAtIndex):
186 (webkitAccessibleTableGetColumnExtentAt):
187 (webkitAccessibleTableGetRowExtentAt):
188 (webkitAccessibleTableGetColumnHeader):
189 (webkitAccessibleTableGetRowHeader):
190 * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
191 (-[WebAccessibilityObjectWrapper accessibilityHeaderElements]):
192 (-[WebAccessibilityObjectWrapper accessibilityRowRange]):
193 (-[WebAccessibilityObjectWrapper accessibilityColumnRange]):
194 * accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
195 (convertMathPairsToNSArray):
196 * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
197 (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
198 * bindings/js/SerializedScriptValue.cpp:
199 * dom/ContainerNode.cpp:
200 * dom/StyledElement.cpp:
201 (WebCore::attributeNameSort):
202 * html/MediaFragmentURIParser.cpp:
203 (WebCore::MediaFragmentURIParser::parseTimeFragment):
204 * html/parser/HTMLMetaCharsetParser.h:
205 * inspector/ContentSearchUtils.cpp:
206 (WebCore::ContentSearchUtils::getRegularExpressionMatchesByLines):
207 (WebCore::ContentSearchUtils::searchInTextByLines):
208 * inspector/DOMPatchSupport.cpp:
209 (WebCore::DOMPatchSupport::diff):
210 (WebCore::DOMPatchSupport::innerPatchChildren):
211 * inspector/DOMPatchSupport.h:
212 * inspector/InspectorAgent.cpp:
213 (WebCore::InspectorAgent::enable):
214 (WebCore::InspectorAgent::evaluateForTestInFrontend):
215 * inspector/InspectorAgent.h:
216 * loader/FormSubmission.cpp:
217 (WebCore::FormSubmission::create):
218 * loader/cache/CachedImage.cpp:
219 (WebCore::CachedImage::brokenImage):
220 * loader/cache/CachedImage.h:
222 (WebCore::findHostnamesInMailToURL):
223 (WebCore::encodeHostnames):
224 * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.h:
225 * platform/graphics/FontCache.cpp:
226 (WebCore::FontCache::getCachedFontData):
227 * platform/graphics/WidthIterator.cpp:
228 * platform/network/HTTPHeaderMap.cpp:
229 (WebCore::HTTPHeaderMap::adopt):
230 * platform/network/ResourceResponseBase.cpp:
231 (WebCore::ResourceResponseBase::parseCacheControlDirectives):
232 (WebCore::parseCacheHeader):
233 * platform/text/AtomicStringKeyedMRUCache.h:
234 * platform/text/LineBreakIteratorPoolICU.h:
235 * rendering/InlineFlowBox.h:
236 * rendering/RenderImage.cpp:
237 (WebCore::RenderImage::imageSizeForError):
238 (WebCore::RenderImage::paintReplaced):
239 * rendering/RenderTableSection.cpp:
240 (WebCore::RenderTableSection::cachedCollapsedBorder):
241 * rendering/RenderTableSection.h:
242 * rendering/svg/SVGTextRunRenderingContext.cpp:
243 (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter):
244 * svg/SVGAnimatedAngle.cpp:
245 (WebCore::SVGAnimatedAngleAnimator::constructFromString):
246 (WebCore::SVGAnimatedAngleAnimator::addAnimatedTypes):
247 (WebCore::SVGAnimatedAngleAnimator::calculateAnimatedValue):
248 * svg/SVGAnimatedIntegerOptionalInteger.cpp:
249 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::constructFromString):
250 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::addAnimatedTypes):
251 (WebCore::SVGAnimatedIntegerOptionalIntegerAnimator::calculateAnimatedValue):
252 * svg/SVGAnimatedNumberOptionalNumber.cpp:
253 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::constructFromString):
254 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::addAnimatedTypes):
255 (WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateAnimatedValue):
256 * svg/SVGAnimatedType.cpp:
257 (WebCore::SVGAnimatedType::createIntegerOptionalInteger):
258 (WebCore::SVGAnimatedType::createNumberOptionalNumber):
259 * svg/SVGAnimatedType.h:
260 (WebCore::SVGAnimatedType::integerOptionalInteger):
261 (WebCore::SVGAnimatedType::numberOptionalNumber):
262 * svg/SVGAnimatedTypeAnimator.h:
263 (WebCore::SVGAnimatedTypeAnimator::constructFromBaseValues):
264 (WebCore::SVGAnimatedTypeAnimator::resetFromBaseValues):
265 * svg/SVGParserUtilities.h:
266 * svg/animation/SMILTimeContainer.h:
268 2014-01-03 Simon Fraser <simon.fraser@apple.com>
270 Attempt to fix EFL build.
272 * page/scrolling/ScrollingStateTree.cpp:
273 (WebCore::ScrollingStateTree::setHasChangedProperties):
275 2014-01-03 Simon Fraser <simon.fraser@apple.com>
277 Clean up the means of committing the scrolling state tree
278 https://bugs.webkit.org/show_bug.cgi?id=126482
280 Reviewed by Tim Horton.
282 ScrollingStateNodes would manually call scrollingStateTree().setHasChangedProperties()
283 after setPropertyChanged() in lots of places, which was repetitive, and
284 AsyncScrollingCoordinator manually called scheduleTreeStateCommit() in many places.
286 Clean up both of these with a clearer trigger for state tree commits.
287 ScrollingStateNodes::setPropertyChanged() calls ScrollingStateTree::setHasChangedProperties(),
288 which turns around and tells the ScrollingCoordinator that the state tree became dirty.
290 * page/scrolling/AsyncScrollingCoordinator.cpp:
291 (WebCore::AsyncScrollingCoordinator::AsyncScrollingCoordinator):
292 (WebCore::AsyncScrollingCoordinator::scrollingStateTreePropertiesChanged):
293 (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
294 (WebCore::AsyncScrollingCoordinator::requestScrollPositionUpdate):
295 (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
296 (WebCore::AsyncScrollingCoordinator::updateViewportConstrainedNode):
297 (WebCore::AsyncScrollingCoordinator::setScrollLayerForNode):
298 (WebCore::AsyncScrollingCoordinator::setCounterScrollingLayerForNode):
299 (WebCore::AsyncScrollingCoordinator::setHeaderLayerForNode):
300 (WebCore::AsyncScrollingCoordinator::setFooterLayerForNode):
301 (WebCore::AsyncScrollingCoordinator::setNonFastScrollableRegionForNode):
302 (WebCore::AsyncScrollingCoordinator::setWheelEventHandlerCountForNode):
303 (WebCore::AsyncScrollingCoordinator::setScrollBehaviorForFixedElementsForNode):
304 (WebCore::AsyncScrollingCoordinator::setScrollbarPaintersFromScrollbarsForNode):
305 (WebCore::AsyncScrollingCoordinator::setSynchronousScrollingReasons):
306 * page/scrolling/AsyncScrollingCoordinator.h:
307 * page/scrolling/ScrollingStateFixedNode.cpp:
308 (WebCore::ScrollingStateFixedNode::updateConstraints):
309 * page/scrolling/ScrollingStateNode.cpp:
310 (WebCore::ScrollingStateNode::setPropertyChanged):
311 (WebCore::ScrollingStateNode::setLayer):
312 * page/scrolling/ScrollingStateNode.h:
313 * page/scrolling/ScrollingStateScrollingNode.cpp:
314 (WebCore::ScrollingStateScrollingNode::setViewportRect):
315 (WebCore::ScrollingStateScrollingNode::setTotalContentsSize):
316 (WebCore::ScrollingStateScrollingNode::setScrollOrigin):
317 (WebCore::ScrollingStateScrollingNode::setScrollableAreaParameters):
318 (WebCore::ScrollingStateScrollingNode::setFrameScaleFactor):
319 (WebCore::ScrollingStateScrollingNode::setNonFastScrollableRegion):
320 (WebCore::ScrollingStateScrollingNode::setWheelEventHandlerCount):
321 (WebCore::ScrollingStateScrollingNode::setSynchronousScrollingReasons):
322 (WebCore::ScrollingStateScrollingNode::setScrollBehaviorForFixedElements):
323 (WebCore::ScrollingStateScrollingNode::setRequestedScrollPosition):
324 (WebCore::ScrollingStateScrollingNode::setHeaderHeight):
325 (WebCore::ScrollingStateScrollingNode::setFooterHeight):
326 (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayer):
327 (WebCore::ScrollingStateScrollingNode::setHeaderLayer):
328 (WebCore::ScrollingStateScrollingNode::setFooterLayer):
329 * page/scrolling/ScrollingStateStickyNode.cpp:
330 (WebCore::ScrollingStateStickyNode::updateConstraints):
331 * page/scrolling/ScrollingStateTree.cpp:
332 (WebCore::ScrollingStateTree::create):
333 (WebCore::ScrollingStateTree::ScrollingStateTree):
334 (WebCore::ScrollingStateTree::setHasChangedProperties):
335 (WebCore::ScrollingStateTree::didRemoveNode):
336 * page/scrolling/ScrollingStateTree.h:
337 * page/scrolling/mac/ScrollingCoordinatorMac.mm:
338 (WebCore::ScrollingCoordinatorMac::scheduleTreeStateCommit):
339 * page/scrolling/mac/ScrollingStateScrollingNodeMac.mm:
340 (WebCore::ScrollingStateScrollingNode::setScrollbarPaintersFromScrollbars):
342 2014-01-03 Simon Fraser <simon.fraser@apple.com>
344 Try to fix CoordinatedGraphics build after r161303. Remove implementations
345 which are now in the cross-platform file.
347 * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp:
348 (WebCore::ScrollingCoordinatorCoordinatedGraphics::detachFromStateTree):
349 (WebCore::ScrollingCoordinatorCoordinatedGraphics::updateViewportConstrainedNode):
350 * page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp:
351 * page/scrolling/coordinatedgraphics/ScrollingStateScrollingNodeCoordinatedGraphics.cpp:
353 2014-01-03 Simon Fraser <simon.fraser@apple.com>
355 Simplify ScrollingStateNode references to various layer types
356 https://bugs.webkit.org/show_bug.cgi?id=126477
358 Reviewed by Tim Horton.
360 ScrollingStateNodes referenced both GraphicsLayer and PlatformLayers, in
361 confusing ways. In the main thread they have a GraphicsLayer*, but need
362 to check to see if the underlying PlatformLayer changed. Then, when
363 cloned to commit to the scrolling thread, they drop the GraphicsLayer
364 and store a PlatformLayer.
366 Hide the complexity (and prepare for the future) by adding LayerRepresentation,
367 which wraps various different flavors of layers, and knows how to check whether
368 the PlatformLayer underlying a GraphicsLayer changed.
370 ScrollingStateNode layer setters then just take and compare LayerRepresentations.
371 Copy constructors convert to a PlatformLayer representation (though not really
372 in the right place currently), and ScrollingTreeNodes get PlatformLayers.
374 * page/scrolling/AsyncScrollingCoordinator.cpp:
375 (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
376 (WebCore::AsyncScrollingCoordinator::setScrollLayerForNode):
377 * page/scrolling/ScrollingStateFixedNode.cpp:
378 (WebCore::ScrollingStateFixedNode::syncLayerPositionForViewportRect):
379 * page/scrolling/ScrollingStateNode.cpp:
380 (WebCore::ScrollingStateNode::ScrollingStateNode):
381 (WebCore::ScrollingStateNode::setLayer):
382 * page/scrolling/ScrollingStateNode.h:
383 (WebCore::LayerRepresentation::LayerRepresentation):
384 (WebCore::LayerRepresentation::operator GraphicsLayer*):
385 (WebCore::LayerRepresentation::operator PlatformLayer*):
386 (WebCore::LayerRepresentation::operator GraphicsLayer::PlatformLayerID):
387 (WebCore::LayerRepresentation::operator ==):
388 (WebCore::LayerRepresentation::toPlatformLayer):
389 (WebCore::LayerRepresentation::representsGraphicsLayer):
390 (WebCore::LayerRepresentation::representsPlatformLayer):
391 (WebCore::LayerRepresentation::representsPlatformLayerID):
392 (WebCore::ScrollingStateNode::layer):
393 * page/scrolling/ScrollingStateScrollingNode.cpp:
394 (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
395 (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayer):
396 (WebCore::ScrollingStateScrollingNode::setHeaderLayer):
397 (WebCore::ScrollingStateScrollingNode::setFooterLayer):
398 * page/scrolling/ScrollingStateScrollingNode.h:
399 * page/scrolling/ScrollingStateStickyNode.cpp:
400 (WebCore::ScrollingStateStickyNode::syncLayerPositionForViewportRect):
401 * page/scrolling/mac/ScrollingStateNodeMac.mm:
402 * page/scrolling/mac/ScrollingStateScrollingNodeMac.mm:
403 * page/scrolling/mac/ScrollingTreeFixedNode.mm:
404 (WebCore::ScrollingTreeFixedNode::updateBeforeChildren):
405 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
406 (WebCore::ScrollingTreeScrollingNodeMac::updateBeforeChildren):
407 * page/scrolling/mac/ScrollingTreeStickyNode.mm:
408 (WebCore::ScrollingTreeStickyNode::updateBeforeChildren):
410 2014-01-03 Brent Fulgham <bfulgham@apple.com>
412 [WebGL] Blit operation from Multisample FBO to rendering FBO must ignore GL_SCISSOR test
413 https://bugs.webkit.org/show_bug.cgi?id=126470
414 <rdar://problem/15201370>
416 Reviewed by Dean Jackson.
418 Covered by webgl/1.0.2/resources/webgl_test_files/conformance/rendering/gl-scissor-test.html
420 * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
421 (WebCore::GraphicsContext3D::resolveMultisamplingIfNecessary): Temporarily deactivate the GL_SCISSOR
422 test while we do our blit, then reactivate if necessary.
424 2014-01-03 Brent Fulgham <bfulgham@apple.com>
426 [WebGL] CGLPixelFormat should specify SampleBuffer and Sample count when using MSAA
427 https://bugs.webkit.org/show_bug.cgi?id=126468
429 Reviewed by Dean Jackson.
431 Covered by webgl/1.0.2/resources/webgl_test_files/conformance/rendering/gl-scissor-test.html
433 * platform/graphics/mac/GraphicsContext3DMac.mm:
434 (WebCore::setPixelFormat): Add kCGLPFAMultisample, kCGLPFASampleBuffers (and count), and
435 kCGLPFASamples (and count) to our pixel format when 'antialias=true'.
436 (WebCore::GraphicsContext3D::GraphicsContext3D): Pass a new 'antialias' flag to the setPixelFormat
437 method so we can turn on MSAA features when needed.
439 2014-01-03 Simon Fraser <simon.fraser@apple.com>
441 Give all PlatformCALayers a PlatformLayerID, not just remote ones
442 https://bugs.webkit.org/show_bug.cgi?id=126466
444 Reviewed by Tim Horton.
446 The ScrollingStateTree has references to both GraphicsLayers and PlatformLayers
447 which is confusing, and is necessary because the underlying PlatformLayer
448 inside a GraphicsLayer can change. In order to hide some of this complexity,
449 expose GraphicsLayer::primaryLayerID() which is a PlatformLayerID that clients
450 can hold onto to test for underlying layer swapping.
452 Also constify LayerType m_layerType on PlatformCALayer, which required
453 cleaning up the construction of PlatformCALayerMac in the case where a
454 PlatformCALayerMac is wrapping an existing CALayer (which happens for video).
457 * platform/graphics/GraphicsLayer.h:
458 (WebCore::GraphicsLayer::primaryLayerID):
459 * platform/graphics/ca/GraphicsLayerCA.cpp:
460 (WebCore::GraphicsLayerCA::primaryLayerID):
461 * platform/graphics/ca/GraphicsLayerCA.h:
462 * platform/graphics/ca/PlatformCALayer.cpp:
463 (WebCore::generateLayerID):
464 (WebCore::PlatformCALayer::PlatformCALayer):
465 * platform/graphics/ca/PlatformCALayer.h:
466 (WebCore::PlatformCALayer::layerID):
467 * platform/graphics/ca/mac/PlatformCALayerMac.h:
468 * platform/graphics/ca/mac/PlatformCALayerMac.mm:
469 (PlatformCALayerMac::create):
470 (PlatformCALayerMac::PlatformCALayerMac):
471 (PlatformCALayerMac::commonInit):
473 2014-01-03 Andreas Kling <akling@apple.com>
475 Add lineageOfType renderer iterator and start using it.
476 <https://webkit.org/b/126456>
478 Add a convenient way to iterate over a renderers ancestry *including*
479 the starting point renderer (if it meets the type criteria.)
481 This works just like lineageOfType for Elements.
483 Reviewed by Geoffrey Garen.
485 * rendering/RenderAncestorIterator.h:
486 (WebCore::lineageOfType):
488 Added. Returns an adapter for walking a renderer's entire lineage
489 matching any renderer of the given type.
491 * rendering/RenderBoxModelObject.h:
492 * rendering/RenderLayerModelObject.h:
494 Add the requisite isRendererOfType<T> helpers.
496 * rendering/RenderBox.cpp:
497 (WebCore::RenderBox::enclosingFloatPaintingLayer):
498 * rendering/RenderObject.cpp:
499 (WebCore::RenderObject::enclosingLayer):
500 (WebCore::RenderObject::enclosingBox):
501 (WebCore::RenderObject::enclosingBoxModelObject):
503 Simplify with lineageOfType. Added some FIXMEs about functions
504 that should return references instead of pointers.
506 2014-01-03 Martin Robinson <mrobinson@igalia.com>
508 Small build fix for the GTK+ CMake port
510 * PlatformGTK.cmake: Add an IDL file that is missing from the list of IDLs
511 used to generate GObject DOM bindings.
513 2014-01-03 Daniel Bates <dabates@apple.com>
515 [iOS] Upstream WebCore/css changes
516 https://bugs.webkit.org/show_bug.cgi?id=126237
518 Reviewed by Simon Fraser.
520 * css/CSSComputedStyleDeclaration.cpp:
521 (WebCore::ComputedStyleExtractor::propertyValue): Added iOS-specific code and FIXME comment.
523 (WebCore::CSSParserContext::CSSParserContext): Ditto.
524 (WebCore::CSSParser::parseValue): Ditto.
525 * css/CSSPropertyNames.in: Added property -webkit-composition-fill-color. Also added FIXME comment.
526 * css/CSSValueKeywords.in: Added iOS-specific -apple-system-* values.
527 * css/DeprecatedStyleBuilder.cpp:
528 (WebCore::DeprecatedStyleBuilder::DeprecatedStyleBuilder): Added iOS-specific code and FIXME comments.
529 * css/MediaFeatureNames.h: Added media feature -webkit-video-playable-inline.
530 * css/MediaQueryEvaluator.cpp:
531 (WebCore::isRunningOnIPhoneOrIPod): Added. Also added FIXME comment.
532 (WebCore::video_playable_inlineMediaFeatureEval): Added.
533 * css/StyleResolver.cpp:
534 (WebCore::StyleResolver::canShareStyleWithElement): Substitute toHTMLMediaElement() for toMediaElement().
535 (WebCore::StyleResolver::applyProperty): Added iOS-specific code and FIXME comment.
536 * css/html.css: Added iOS-specific CSS styles.
537 (input, textarea, keygen, select, button, isindex):
539 (input[type="date"]):
540 (input[type="datetime"]):
541 (input[type="datetime-local"]):
542 (input[type="month"]):
543 (input[type="time"]):
545 (input:-webkit-autofill):
546 (input[type="radio"], input[type="checkbox"]):
547 (input[type="button"], input[type="submit"], input[type="reset"], input[type="file"]::-webkit-file-upload-button, button):
548 (input[type="range"]::-webkit-slider-thumb, input[type="range"]::-webkit-media-slider-thumb):
549 (input[type="range"]::-webkit-slider-thumb:active):
550 (input:disabled, textarea:disabled):
551 (input[readonly], textarea[readonly]):
552 (textarea::-webkit-input-placeholder):
553 (input[type="checkbox"]):
554 (input[type="radio"]):
555 (input[type="checkbox"]:checked, input[type="radio"]:checked):
556 (input[type="checkbox"]:checked:disabled, input[type="radio"]:checked:disabled):
559 * css/mathml.css: Added iOS-specific CSS styles.
562 * css/mediaControlsiOS.css: Added.
563 * css/svg.css: Added iOS-specific CSS styles.
566 2014-01-03 Brent Fulgham <bfulgham@apple.com>
568 [WebGL] glScissor test is not accounted for when generating internal rendering textures.
569 https://bugs.webkit.org/show_bug.cgi?id=126455
570 <rdar://problem/15744206>
572 Reviewed by Dean Jackson.
574 Covered by webgl/1.0.2/conformance/rendering/gl-scissor-test.html
576 * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
577 (WebCore::GraphicsContext3D::prepareTexture): Check state of GL_SCISSOR_TEST and GL_DITHER, deactivate them during
578 our internal drawing, then turn them back on for further processing.
580 2014-01-03 Simon Fraser <simon.fraser@apple.com>
582 Maybe fix Windows build.
584 * WebCore.vcxproj/copyForwardingHeaders.cmd:
586 2014-01-03 Jer Noble <jer.noble@apple.com>
588 [MediaControls][iOS] Enable JavaScript Media Controls on iOS.
589 https://bugs.webkit.org/show_bug.cgi?id=126440
591 Reviewed by Eric Carlson.
593 Drive-by misspelling fix, and add a convenience function to check if the
594 controls are currently hidden:
595 * Modules/mediacontrols/mediaControlsApple.js:
596 (Controller.prototype.handleWrapperMouseMove):
597 (Controller.prototype.handleWrapperMouseOut):
598 (Controller.prototype.updatePlaying):
599 (Controller.prototype.controlsAreHidden): Added.
601 Add a new subclass of Controller for iOS and a matching CSS:
602 * Modules/mediacontrols/mediaControlsiOS.css: Added.
603 * Modules/mediacontrols/mediaControlsiOS.js: Added.
604 (createControls): Override the createControls() in mediaControlsApple.js.
605 (ControllerIOS): Define a new class.
606 (ControllerIOS.prototype.inheritFrom): Convenience method to mixin parent
608 (ControllerIOS.prototype.createBase): Override, listen for touches instead of mouse events.
609 (ControllerIOS.prototype.createControls): Ditto.
610 (ControllerIOS.prototype.configureInlineControls): Override, only add play, timeline, and full
612 (ControllerIOS.prototype.configureFullScreenControls): Override, and add no buttons.
613 (ControllerIOS.prototype.handlePlayButtonTouchStart): Activate.
614 (ControllerIOS.prototype.handlePlayButtonTouchEnd): De-activate and do action.
615 (ControllerIOS.prototype.handlePlayButtonTouchCancel): De-activate and cancel.
616 (ControllerIOS.prototype.handleWrapperTouchStart): Show controls.
617 (ControllerIOS.prototype.handlePanelTouchStart): Disable video selection.
618 (ControllerIOS.prototype.handlePanelTouchEnd): Re-enable video selection.
619 (ControllerIOS.prototype.handlePanelTouchCancel): Ditto.
621 Drive-by fix to enable the JavaScript controls when the plugin is disabled:
622 * html/HTMLMediaElement.cpp:
623 (WebCore::HTMLMediaElement::parseAttribute):
625 Add the iOS JavaScript by appending it to the generic (Apple) JavaScript:
626 * rendering/RenderThemeIOS.mm:
627 (WebCore::RenderThemeIOS::mediaControlsScript):
629 Add new files to project:
630 * DerivedSources.make:
631 * WebCore.xcodeproj/project.pbxproj:
633 2014-01-03 Simon Fraser <simon.fraser@apple.com>
635 Allow the ChromeClient to provide a custom ScrollingCoordinator
636 https://bugs.webkit.org/show_bug.cgi?id=126450
638 Reviewed by Tim Horton.
640 Some platforms will want to provide a custom ScrollingCoordinator, so let
641 them do so by asking ChromeClient first for one.
643 * page/ChromeClient.h:
644 (WebCore::ChromeClient::createScrollingCoordinator):
646 (WebCore::Page::scrollingCoordinator):
648 2014-01-03 Andreas Kling <akling@apple.com>
650 Deploy more child renderer iterators in RenderBlockFlow.
651 <https://webkit.org/b/126434>
653 Reviewed by Sam Weinig.
655 * rendering/RenderBlockFlow.cpp:
656 (WebCore::shouldCheckLines):
658 Make this helper take a RenderBlockFlow instead of a RenderObject
659 and simplified it a bit. RenderDeprecatedFlexibleBox does not
660 derive from RenderBlockFlow so those checks can be omitted.
662 (WebCore::RenderBlockFlow::layoutBlock):
663 (WebCore::RenderBlockFlow::markAllDescendantsWithFloatsForLayout):
664 (WebCore::RenderBlockFlow::lineAtIndex):
665 (WebCore::RenderBlockFlow::lineCount):
666 (WebCore::RenderBlockFlow::clearTruncation):
668 Use childrenOfType to iterate over block and block-flow children.
669 Tweaked some early return/continue to reduce nesting.
671 2014-01-03 Simon Fraser <simon.fraser@apple.com>
673 Allow different types of ScrollingTrees to have different types of ScrollingTreeNode subclasses
674 https://bugs.webkit.org/show_bug.cgi?id=126445
676 Reviewed by Tim Horton.
678 Make it possible to have ScrollingTree subclasses with different subclasses of ScrollingTreeNodes,
679 by giving ScrollingTree a pure virtual createNode() function. ThreadedScrollingTree implements
680 this, and then delegates node creation to its AsyncScrollingCoordinator (since we have
681 a ScrollingCoordinatorMac but no real need for a ThreadedScrollingTreeMac).
683 Also made ThreadedScrollingTree's m_scrollingCoordinator an AsyncScrollingCoordinator,
684 since by definition a threaded scrolling tree uses an async coordinator.
686 * page/scrolling/AsyncScrollingCoordinator.h:
687 * page/scrolling/ScrollingTree.cpp:
688 (WebCore::ScrollingTree::updateTreeFromStateNode):
689 * page/scrolling/ScrollingTree.h:
690 * page/scrolling/ScrollingTreeScrollingNode.h:
691 * page/scrolling/ThreadedScrollingTree.cpp:
692 (WebCore::ThreadedScrollingTree::create):
693 (WebCore::ThreadedScrollingTree::ThreadedScrollingTree):
694 (WebCore::ThreadedScrollingTree::createNode):
695 * page/scrolling/ThreadedScrollingTree.h:
696 * page/scrolling/mac/ScrollingCoordinatorMac.h:
697 * page/scrolling/mac/ScrollingCoordinatorMac.mm:
698 (WebCore::ScrollingCoordinatorMac::createScrollingTreeNode):
699 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
700 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
701 (WebCore::ScrollingTreeScrollingNodeMac::create):
703 2014-01-03 Gavin Barraclough <barraclough@apple.com>
705 Refactor NSActivity handling code from ChildProcess to UserActivity
706 https://bugs.webkit.org/show_bug.cgi?id=126330
708 Unreviewed build fix.
710 * platform/UserActivity.h:
713 2014-01-02 Gavin Barraclough <barraclough@apple.com>
715 Refactor NSActivity handling code from ChildProcess to UserActivity
716 https://bugs.webkit.org/show_bug.cgi?id=126330
718 Reviewed by Sam Weinig.
720 UserActivity is a mechanism to express to the operating system (where appropriate)
721 that a user initiated activity is taking place, and as such that resources should be
722 made available to the process accordingly.
724 Currently we hold a single NSActivity, at the WebKit layer. This refactoring allows us
725 to hold different activity tokens for different user actions (which simplifies the
726 handling, and aides debugging since the token can more accurately express the activity
727 taking place), and also will allow us to avoid the layering difficulty of calling back
728 up the stack to WebKit to register that an activity is taking place.
730 * WebCore.xcodeproj/project.pbxproj:
732 * platform/UserActivity.cpp: Added.
733 (WebCore::UserActivity::UserActivity):
734 - nop implementation - ignore description.
735 (WebCore::UserActivity::beginActivity):
736 (WebCore::UserActivity::endActivity):
737 - nop implementation - just inc/dec m_count.
738 * platform/UserActivity.h: Added.
739 (WebCore::UserActivity::isActive):
740 - returns true if one or more instance of this activity is in progress.
741 * platform/mac/UserActivityMac.mm: Added.
742 (WebCore::UserActivity::UserActivity):
743 - constructor accepts one argument, a description string.
744 (WebCore::UserActivity::isValid):
745 - used by assertions.
746 (WebCore::UserActivity::beginActivity):
747 (WebCore::UserActivity::endActivity):
748 - track start/end of an activity - calls to these methods should be balanced.
749 (WebCore::UserActivity::hysteresisTimerFired):
750 - used to implement hysteresis in releasing NSActivity.
752 2014-01-03 Alexey Proskuryakov <ap@apple.com>
754 Line ending conversion should be able to handle strings with null chars
755 https://bugs.webkit.org/show_bug.cgi?id=126202
757 This is a merge from Blink.
759 Reviewed by Alexey Proskuryakov.
761 Test: http/tests/local/formdata/send-form-data-with-string-containing-null.html
763 * platform/text/LineEnding.cpp: (WebCore::normalizeToCROrLF): Do it right.
765 2014-01-03 Alberto Garcia <berto@igalia.com>
767 WebKit-GTK 1.8.1 does not build on OS X 10.7
768 https://bugs.webkit.org/show_bug.cgi?id=88407
770 Reviewed by Carlos Garcia Campos.
772 Replace non-portable 'echo -n' with 'true'.
776 2014-01-03 peavo@outlook.com <peavo@outlook.com>
778 [WinCairo] Compile error.
779 https://bugs.webkit.org/show_bug.cgi?id=126428
781 Reviewed by Brent Fulgham.
783 The NativeImagePtr type is not an CGImageRef on WinCairo, cannot use CFRetain.
785 * loader/cache/MemoryCache.cpp: Replace USE(CF) with USE(CG).
786 * loader/cache/MemoryCache.h: Ditto.
788 2014-01-03 Hans Muller <hmuller@adobe.com>
790 [CSS Shapes] Simplify FloatRoundedRect, BoxShape construction
791 https://bugs.webkit.org/show_bug.cgi?id=125995
793 Reviewed by Andreas Kling.
795 Cleanup of various internal Shape issues:
796 - Removed unnecessary Shape() initialization list entries in Shape subclasses
797 per https://bugs.webkit.org/show_bug.cgi?id=125548#c2.
798 - Used const references instead of pointers for non-deprecated Shape:createShape() logic.
799 - Replaced createShape() overloads for Rasters and Boxes with functions named
800 createRasterShape() and createBoxShape().
801 - Added a FloatRoundedRect::Radii() constructor to reduce the parameter list
802 length of the FloatRoundedRect constructor in createBoxShape().
804 There are no new tests, this is just internal refactoring.
806 * platform/graphics/FloatRoundedRect.h:
807 (WebCore::FloatRoundedRect::Radii::Radii):
808 * rendering/shapes/BoxShape.h:
809 (WebCore::BoxShape::BoxShape):
810 * rendering/shapes/PolygonShape.h:
811 (WebCore::PolygonShape::PolygonShape):
812 * rendering/shapes/RasterShape.h:
813 (WebCore::RasterShape::RasterShape):
814 * rendering/shapes/RectangleShape.h:
815 (WebCore::RectangleShape::RectangleShape):
816 * rendering/shapes/Shape.cpp:
817 (WebCore::createInsetShape):
818 (WebCore::Shape::createShape):
819 (WebCore::Shape::createRasterShape):
820 (WebCore::Shape::createBoxShape):
821 * rendering/shapes/Shape.h:
822 * rendering/shapes/ShapeInfo.cpp:
823 (WebCore::ShapeInfo<RenderType>::computedShape):
825 2014-01-03 Andreas Kling <akling@apple.com>
827 Remove unused Document::openSearchDescriptionURL().
828 <https://webkit.org/b/126419>
830 Reviewed by Antti Koivisto.
835 Scrub leftovers from the defunct Chromium port.
837 2014-01-03 Jinwoo Song <jinwoo7.song@samsung.com>
839 VibrationPattern should allocate an single vector instance for single integer input
840 https://bugs.webkit.org/show_bug.cgi?id=126417
842 Reviewed by Gyuyoung Kim.
844 When the Vibration pattern is set with a single integer, the VibrationPattern should
845 be set with this integer as a vibration time. But the VibrationPattern(unsigned vector) was
846 initialized with a single parameter, the vibration time, so the time was used to set
849 * Modules/vibration/NavigatorVibration.cpp:
850 (WebCore::NavigatorVibration::vibrate):
852 2014-01-02 Jaehun Lim <ljaehun.lim@samsung.com>
854 IconController.cpp needs to include <wtf/text/CString.h>
855 https://bugs.webkit.org/show_bug.cgi?id=126415
857 Reviewed by Gyuyoung Kim.
859 Build fails in IconController.cpp when ICONDATABASE is disabled.
860 WebKit/Source/WebCore/loader/icon/IconController.cpp:124:110: error: invalid use of incomplete type ‘class WTF::CString’
861 IconController.cpp needs #include <wtf/text/CString.h>.
863 No new tests. Just build fix.
865 * loader/icon/IconController.cpp: Add #include statement.
867 2014-01-02 Ryuan Choi <ryuan.choi@samsung.com>
869 [EFL] Previous scrollbar is remained sometimes
870 https://bugs.webkit.org/show_bug.cgi?id=126414
872 Reviewed by Gyuyoung Kim.
874 * platform/efl/ScrollbarEfl.cpp:
875 (ScrollbarEfl::invalidate):
876 Updated scrollbar visibility in Scrollbar::invalidate().
877 * platform/efl/ScrollbarEfl.h:
878 Removed show()/hide() which never been called() for scrollbar.
880 2014-01-02 Brent Fulgham <bfulgham@apple.com>
882 [WebGL] Correct symbol lookup logic to handle 1-element arrays
883 https://bugs.webkit.org/show_bug.cgi?id=126411
884 <rdar://problem/15394564>
886 Reviewed by Dean Jackson.
888 Tested by revisions to webgl/1.0.2/conformance/glsl/misc/shader-with-array-of-structs-containing-arrays.html
890 * html/canvas/WebGLRenderingContext.cpp:
891 (WebCore::WebGLRenderingContext::getUniformLocation): Revise to
892 handle access to zeroeth element of the array.
894 2014-01-02 Myles C. Maxfield <mmaxfield@apple.com>
896 Crash in WebCore::translateIntersectionPointsToSkipInkBoundaries
897 https://bugs.webkit.org/show_bug.cgi?id=126252
899 Reviewed by Alexey Proskuryakov.
901 lastIntermediate was a iterator pointing into a Vector, which was being re-used
902 even while appending to the Vector. If any of the append operators triggered
903 a realloc, the iterator would point to the old free'ed memory.
905 Test: fast/css3-text/css3-text-decoration/text-decoration-skip/text-decoration-skip-ink-crash-many-gaps.html
907 * rendering/InlineTextBox.cpp:
908 (WebCore::translateIntersectionPointsToSkipInkBoundaries):
910 2014-01-02 Brent Fulgham <bfulgham@apple.com>
912 [WebGL] Correct symbol lookup logic to handle 1-element arrays
913 https://bugs.webkit.org/show_bug.cgi?id=126411
914 <rdar://problem/15394564>
916 Reviewed by Dean Jackson.
918 * html/canvas/WebGLRenderingContext.cpp:
919 (WebCore::WebGLRenderingContext::getUniformLocation): Revise code to handle the case of single-element
922 2014-01-02 Sam Weinig <sam@webkit.org>
924 Update Promises to the https://github.com/domenic/promises-unwrapping spec
925 https://bugs.webkit.org/show_bug.cgi?id=120954
927 Reviewed by Filip Pizlo.
929 * ForwardingHeaders/runtime/JSPromiseDeferred.h: Added.
930 * ForwardingHeaders/runtime/JSPromiseResolver.h: Removed.
931 * bindings/js/JSDOMGlobalObjectTask.cpp:
932 (WebCore::JSGlobalObjectTask::JSGlobalObjectTask):
933 * bindings/js/JSDOMGlobalObjectTask.h:
934 * bindings/js/JSDOMPromise.cpp:
935 (WebCore::DeferredWrapper::DeferredWrapper):
936 (WebCore::DeferredWrapper::promise):
937 (WebCore::DeferredWrapper::resolve):
938 (WebCore::DeferredWrapper::reject):
939 * bindings/js/JSDOMPromise.h:
940 (WebCore::DeferredWrapper::resolve):
941 (WebCore::DeferredWrapper::reject):
942 (WebCore::DeferredWrapper::resolve<String>):
943 (WebCore::DeferredWrapper::resolve<bool>):
945 (WebCore::DeferredWrapper::reject<String>):
946 * bindings/js/JSDOMWindowBase.cpp:
947 (WebCore::JSDOMWindowBase::queueTaskToEventLoop):
948 * bindings/js/JSDOMWindowBase.h:
949 * bindings/js/JSSubtleCryptoCustom.cpp:
950 (WebCore::JSSubtleCrypto::encrypt):
951 (WebCore::JSSubtleCrypto::decrypt):
952 (WebCore::JSSubtleCrypto::sign):
953 (WebCore::JSSubtleCrypto::verify):
954 (WebCore::JSSubtleCrypto::digest):
955 (WebCore::JSSubtleCrypto::generateKey):
956 (WebCore::JSSubtleCrypto::importKey):
957 (WebCore::JSSubtleCrypto::exportKey):
958 (WebCore::JSSubtleCrypto::wrapKey):
959 (WebCore::JSSubtleCrypto::unwrapKey):
960 * bindings/js/JSWorkerGlobalScopeBase.cpp:
961 (WebCore::JSWorkerGlobalScopeBase::queueTaskToEventLoop):
962 * bindings/js/JSWorkerGlobalScopeBase.h:
964 2014-01-02 Tim Horton <timothy_horton@apple.com>
966 ImageBufferBackingStoreCache should use DeferrableOneShotTimer
967 https://bugs.webkit.org/show_bug.cgi?id=126155
969 Reviewed by Anders Carlsson.
971 Since ImageBufferBackingStoreCache's purge timer is pushed out every time
972 a backing store is deallocated, we can easily waste a lot of time rescheduling
973 the timer. Since it's a cache purge timer and doesn't need that kind of precision,
974 adopt DeferrableOneShotTimer, which is much more performant when deferred frequently.
976 * platform/graphics/cg/ImageBufferBackingStoreCache.cpp:
977 (WebCore::ImageBufferBackingStoreCache::ImageBufferBackingStoreCache):
978 (WebCore::ImageBufferBackingStoreCache::timerFired):
979 (WebCore::ImageBufferBackingStoreCache::schedulePurgeTimer):
980 * platform/graphics/cg/ImageBufferBackingStoreCache.h:
982 2014-01-02 Myles C. Maxfield <mmaxfield@apple.com>
984 Allow ImageBuffer to re-use IOSurfaces
985 https://bugs.webkit.org/show_bug.cgi?id=125477
987 Reviewed by Geoff Garen. Modifications reviewed by Tim Horton.
989 This patch is taken from r160945, but the modifications to ImageBufferCG.cpp
992 This test adds a static class, ImageBufferBackingStoreCache, that vends
993 IOSurfaces. It remembers IOSurfaces that have been returned to it until
994 a configurable timeout.
996 The storage used by this class is in the form of a HashMap from a
997 bucketed size to the IOSurface. There are many other data structures
998 that could be used, but this implementation gives a 80% hit rate on
999 normal browsing of some example sites with Canvas and
1000 text-decoration-skip: ink. Because the buckets are fairly
1001 small (rounding the width and height up to multiples of 8), traversing the
1002 bucket contents takes on average 2 steps.
1004 Test: fast/canvas/canvas-backing-store-reuse.html
1006 * WebCore.xcodeproj/project.pbxproj: Added new caching class
1007 * platform/graphics/cg/ImageBufferBackingStoreCache.cpp: Added.
1008 (WebCore::createIOSurface): Copied from ImageBufferCG.cpp
1009 (WebCore::ImageBufferBackingStoreCache::timerFired): Forget the cache
1011 (WebCore::ImageBufferBackingStoreCache::schedulePurgeTimer):
1012 (WebCore::ImageBufferBackingStoreCache::get): Static getter
1013 (WebCore::ImageBufferBackingStoreCache::ImageBufferBackingStoreCache):
1014 (WebCore::ImageBufferBackingStoreCache::insertIntoCache): Memory-management
1016 (WebCore::ImageBufferBackingStoreCache::takeFromCache): Memory-management
1018 (WebCore::ImageBufferBackingStoreCache::isAcceptableSurface): Does this cached
1019 IOSurface fit the bill?
1020 (WebCore::ImageBufferBackingStoreCache::tryTakeFromCache): Lookup
1021 a bucket and walk through its contents
1022 (WebCore::ImageBufferBackingStoreCache::getOrAllocate): Public function
1023 for clients who want a IOSurface from the cache
1024 (WebCore::ImageBufferBackingStoreCache::deallocate): Public
1025 function for clients to return an IOSurface to the pool
1026 * platform/graphics/cg/ImageBufferBackingStoreCache.h: Added.
1027 (WebCore::ImageBuffer::ImageBuffer):
1028 (WebCore::ImageBuffer::~ImageBuffer):
1030 2014-01-02 Piotr Grad <p.grad@samsung.com>
1032 Video-seek-with-negative-playback was flaky.
1033 https://bugs.webkit.org/show_bug.cgi?id=126379
1035 Reviewed by Eric Carlson.
1037 No new tests. Covered by existing tests.
1039 m_player->setRate() should be called before updating m_playbackRate, because potentiallyPlaying() depends
1040 on endedPlayback(), which checks m_playbackRate.
1042 * html/HTMLMediaElement.cpp:
1043 (WebCore::HTMLMediaElement::setPlaybackRate):
1045 2014-01-02 Daniel Bates <dabates@apple.com>
1047 [iOS] Tapping any link crashes in WebCore::EventHandler::mouseMoved()
1048 (also crashes when scrolling certain sites)
1049 https://bugs.webkit.org/show_bug.cgi?id=126401
1050 <rdar://problem/15739334>
1052 Reviewed by Tim Horton.
1054 * page/ios/EventHandlerIOS.mm:
1055 (WebCore::currentEventSlot): Make the shared variable have static-storage duration.
1057 2014-01-02 Gavin Barraclough <barraclough@apple.com>
1059 Remove WindowIsVisible
1060 https://bugs.webkit.org/show_bug.cgi?id=126270
1062 Reviewed by Tim Horton.
1064 We currently track visibility in two ways - ViewState::IsVisible and ViewState::WindowIsVisible.
1065 The latter detects that the content is hidden in fewer cases than the former, and as such, the
1066 former is always preferable.
1068 This affects the hidden state provided to FocusController::contentAreaDidShowOrHide and to
1069 Plugin::windowVisibilityChanged.
1072 * page/FocusController.cpp:
1073 (WebCore::FocusController::FocusController):
1074 (WebCore::FocusController::setContentIsVisible):
1075 * page/FocusController.h:
1076 - rename ContainingWindowIsVisible -> ContentIsVisible.
1078 2014-01-02 Gavin Barraclough <barraclough@apple.com>
1080 Merge didMoveOnscreen / page visibility to isVisible
1081 https://bugs.webkit.org/show_bug.cgi?id=126268
1083 Reviewed by Tim Horton.
1085 The onscreen state most closely tracks view visibility (though currently
1086 also tracks a mix of in-window state). Make more consistent, simplify,
1087 and move all animation suspension logic to Page, so it can be controlled
1088 by the PageThrottler.
1091 * page/EventHandler.cpp:
1092 (WebCore::EventHandler::fakeMouseMoveEventTimerFired):
1093 * page/FrameView.cpp:
1094 (WebCore::FrameView::shouldSetCursor):
1096 (WebCore::Page::Page):
1097 - initialize new variables.
1098 (WebCore::Page::setIsVisible):
1099 - merge setVisibilityState, didMoveOnscreen, willMoveOffscreen.
1100 (WebCore::Page::setIsPrerender):
1101 - switches visibility state from hidden to prerender.
1102 (WebCore::Page::visibilityState):
1103 - computed from m_isVisible, m_isPrerender.
1104 (WebCore::Page::hiddenPageCSSAnimationSuspensionStateChanged):
1105 - m_visibilityState -> m_isVisible.
1107 - remove didMoveOnscreen/willMoveOffscreen
1108 m_isOnscreen & m_visibilityState -> m_isVisible & m_isPrerender
1109 setVisibilityState -> setIsVisible & setIsPrerender.
1110 (WebCore::Page::isVisible):
1111 - isOnscreen -> isVisible.
1113 2014-01-02 Oliver Hunt <oliver@apple.com>
1115 Update bindings test results
1117 * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
1118 (WebCore::jsTestActiveDOMObjectConstructor):
1119 * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
1120 (WebCore::jsTestCustomNamedGetterConstructor):
1121 * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
1122 (WebCore::jsTestEventConstructorConstructor):
1123 * bindings/scripts/test/JS/JSTestEventTarget.cpp:
1124 (WebCore::jsTestEventTargetConstructor):
1125 * bindings/scripts/test/JS/JSTestException.cpp:
1126 (WebCore::jsTestExceptionConstructor):
1127 * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
1128 (WebCore::jsTestGenerateIsReachableConstructor):
1129 * bindings/scripts/test/JS/JSTestInterface.cpp:
1130 (WebCore::jsTestInterfaceConstructor):
1131 * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
1132 (WebCore::jsTestMediaQueryListListenerConstructor):
1133 * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
1134 (WebCore::jsTestNamedConstructorConstructor):
1135 * bindings/scripts/test/JS/JSTestNode.cpp:
1136 (WebCore::jsTestNodeConstructor):
1137 * bindings/scripts/test/JS/JSTestObj.cpp:
1138 (WebCore::jsTestObjConstructor):
1139 * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
1140 (WebCore::jsTestOverloadedConstructorsConstructor):
1141 * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
1142 (WebCore::jsTestSerializedScriptValueInterfaceConstructor):
1143 * bindings/scripts/test/JS/JSTestTypedefs.cpp:
1144 (WebCore::jsTestTypedefsConstructor):
1145 * bindings/scripts/test/JS/JSattribute.cpp:
1146 (WebCore::jsattributeConstructor):
1147 * bindings/scripts/test/JS/JSreadonly.cpp:
1148 (WebCore::jsreadonlyConstructor):
1150 2013-12-23 Oliver Hunt <oliver@apple.com>
1152 Refactor PutPropertySlot to be aware of custom properties
1153 https://bugs.webkit.org/show_bug.cgi?id=126187
1155 Reviewed by Antti Koivisto.
1157 Update the bindings code generation and custom objects
1158 to the new function signatures
1160 * bindings/js/JSDOMWindowCustom.cpp:
1161 (WebCore::JSDOMWindow::put):
1162 * bindings/objc/WebScriptObject.mm:
1163 (-[WebScriptObject setValue:forKey:]):
1164 * bindings/scripts/CodeGeneratorJS.pm:
1165 (GenerateImplementation):
1166 * bindings/scripts/test/JS/JSTestInterface.cpp:
1167 (WebCore::JSTestInterface::putByIndex):
1168 * bridge/NP_jsobject.cpp:
1171 2014-01-02 Simon Fraser <simon.fraser@apple.com>
1173 Add AsyncScrollingCoordinator, which is a base class for threaded and future remote ScrollingCoordinators
1174 https://bugs.webkit.org/show_bug.cgi?id=126389
1176 Reviewed by Tim Horton.
1178 Add AsyncScrollingCoordinator, a ScrollingCoordinator that knows about ScrollingStateTrees
1179 and ScrollingTrees, but leaves it up to subclasses to decide when and how to commit.
1181 * WebCore.xcodeproj/project.pbxproj: Added AsyncScrollingCoordinator.*
1182 * page/scrolling/AsyncScrollingCoordinator.cpp: Copied from Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.mm.
1183 (WebCore::AsyncScrollingCoordinator::AsyncScrollingCoordinator):
1184 (WebCore::AsyncScrollingCoordinator::~AsyncScrollingCoordinator):
1185 (WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
1186 (WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
1187 (WebCore::AsyncScrollingCoordinator::requestScrollPositionUpdate):
1188 (WebCore::AsyncScrollingCoordinator::scrollableAreaScrollbarLayerDidChange):
1189 (WebCore::AsyncScrollingCoordinator::attachToStateTree):
1190 (WebCore::AsyncScrollingCoordinator::detachFromStateTree):
1191 (WebCore::AsyncScrollingCoordinator::clearStateTree):
1192 (WebCore::AsyncScrollingCoordinator::syncChildPositions):
1193 (WebCore::AsyncScrollingCoordinator::ensureRootStateNodeForFrameView):
1194 (WebCore::AsyncScrollingCoordinator::updateScrollingNode):
1195 (WebCore::AsyncScrollingCoordinator::updateViewportConstrainedNode):
1196 (WebCore::AsyncScrollingCoordinator::setScrollLayerForNode):
1197 (WebCore::AsyncScrollingCoordinator::setCounterScrollingLayerForNode):
1198 (WebCore::AsyncScrollingCoordinator::setHeaderLayerForNode):
1199 (WebCore::AsyncScrollingCoordinator::setFooterLayerForNode):
1200 (WebCore::AsyncScrollingCoordinator::setNonFastScrollableRegionForNode):
1201 (WebCore::AsyncScrollingCoordinator::setWheelEventHandlerCountForNode):
1202 (WebCore::AsyncScrollingCoordinator::setScrollBehaviorForFixedElementsForNode):
1203 (WebCore::AsyncScrollingCoordinator::setScrollbarPaintersFromScrollbarsForNode):
1204 (WebCore::AsyncScrollingCoordinator::setSynchronousScrollingReasons):
1205 (WebCore::AsyncScrollingCoordinator::updateMainFrameScrollLayerPosition):
1206 (WebCore::AsyncScrollingCoordinator::recomputeWheelEventHandlerCountForFrameView):
1207 (WebCore::AsyncScrollingCoordinator::isRubberBandInProgress):
1208 (WebCore::AsyncScrollingCoordinator::setScrollPinningBehavior):
1209 (WebCore::AsyncScrollingCoordinator::scrollingStateTreeAsText):
1210 * page/scrolling/AsyncScrollingCoordinator.h: Copied from Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.h.
1211 (WebCore::AsyncScrollingCoordinator::scrollingTree):
1212 (WebCore::AsyncScrollingCoordinator::setScrollingTree):
1213 (WebCore::AsyncScrollingCoordinator::scrollingStateTree):
1214 (WebCore::AsyncScrollingCoordinator::releaseScrollingTree):
1215 * page/scrolling/ScrollingCoordinator.h: Add casting support.
1216 (WebCore::ScrollingCoordinator::isAsyncScrollingCoordinator):
1217 * page/scrolling/ThreadedScrollingTree.h: commitNewTreeState() needs to be public.
1218 * page/scrolling/mac/ScrollingCoordinatorMac.h:
1219 * page/scrolling/mac/ScrollingCoordinatorMac.mm: Lots of code moved to AsyncScrollingCoordinator.
1220 (WebCore::ScrollingCoordinatorMac::ScrollingCoordinatorMac):
1221 (WebCore::ScrollingCoordinatorMac::~ScrollingCoordinatorMac):
1222 (WebCore::ScrollingCoordinatorMac::pageDestroyed):
1223 (WebCore::ScrollingCoordinatorMac::commitTreeStateIfNeeded):
1224 (WebCore::ScrollingCoordinatorMac::handleWheelEvent):
1225 (WebCore::ScrollingCoordinatorMac::scheduleTreeStateCommit):
1226 (WebCore::ScrollingCoordinatorMac::commitTreeState):
1227 (WebCore::ScrollingCoordinatorMac::updateTiledScrollingIndicator):
1229 2014-01-02 Andreas Kling <akling@apple.com>
1231 Simplify the insides of DocumentSharedObjectPool and reduce memory usage.
1233 Merging Blink r164152 by Elliott Sprehn.
1235 Instead of storing an OwnPtr to an object that has a pointer to the
1236 ShareableElementData as well as a pointer into the ShareableElementData
1237 and the length we can just store a RefPtr to the SharableElementData.
1239 This also reduces the memory usage of the pool by 2 pointers per entry.
1241 * dom/DocumentSharedObjectPool.h:
1242 * dom/DocumentSharedObjectPool.cpp:
1243 (WebCore::attributeHash):
1244 (WebCore::hasSameAttributes):
1245 (WebCore::DocumentSharedObjectPool::cachedShareableElementDataWithAttributes):
1247 2014-01-02 Dirk Schulze <krit@webkit.org>
1249 Support <box> values computed style for 'clip-path' property
1250 https://bugs.webkit.org/show_bug.cgi?id=126148
1252 Reviewed by Simon Fraser.
1254 Calculate computed style for 'clip-path' property.
1256 Updated tests to check for computed style.
1258 * css/BasicShapeFunctions.cpp: Add box value bounding-box.
1259 (WebCore::valueForBox):
1260 (WebCore::boxForValue):
1261 * css/CSSComputedStyleDeclaration.cpp: Return the computed style
1263 (WebCore::ComputedStyleExtractor::propertyValue):
1264 * css/DeprecatedStyleBuilder.cpp: Create CSSValueLists for 'clip-th'.
1265 (WebCore::ApplyPropertyClipPath::applyValue):
1266 * rendering/ClipPathOperation.h: Add bounding-box value.
1267 (WebCore::ShapeClipPathOperation::pathForReferenceRect):
1268 (WebCore::ShapeClipPathOperation::setReferenceBox):
1269 (WebCore::ShapeClipPathOperation::referenceBox):
1270 (WebCore::BoxClipPathOperation::create):
1271 (WebCore::BoxClipPathOperation::pathForReferenceRect):
1272 (WebCore::BoxClipPathOperation::referenceBox):
1273 (WebCore::BoxClipPathOperation::BoxClipPathOperation):
1274 * rendering/shapes/ShapeInfo.h: Add bounding-box value.
1275 (WebCore::ShapeInfo::setShapeSize):
1276 (WebCore::ShapeInfo::logicalTopOffset):
1277 (WebCore::ShapeInfo::logicalLeftOffset):
1278 * rendering/style/BasicShapes.cpp: Add bounding-box value.
1279 (WebCore::BasicShape::referenceBoxSize):
1280 * rendering/style/BasicShapes.h:
1282 2014-01-02 Antti Koivisto <antti@apple.com>
1284 Always resolve style from root
1285 https://bugs.webkit.org/show_bug.cgi?id=126380
1287 Reviewed by Andreas Kling.
1289 Forced style resolve that does not start from the root is never really correct.
1290 Remove the few remaining instances.
1292 * dom/ShadowRoot.cpp:
1293 (WebCore::ShadowRoot::setResetStyleInheritance):
1295 Update style asynchronously.
1299 * html/HTMLPlugInImageElement.cpp:
1300 (WebCore::HTMLPlugInImageElement::createElementRenderer):
1301 (WebCore::HTMLPlugInImageElement::documentWillSuspendForPageCache):
1302 (WebCore::HTMLPlugInImageElement::documentDidResumeFromPageCache):
1304 Delete the render tree synchronously on suspend and rebuild it asynchronously on resume.
1305 No need for m_customStyleForPageCache hack.
1307 * html/HTMLPlugInImageElement.h:
1309 Remove m_customStyleForPageCache.
1311 * style/StyleResolveTree.cpp:
1312 * style/StyleResolveTree.h:
1314 Remove Element version of resolveTree from the interface.
1316 * svg/SVGUseElement.h:
1318 2014-01-02 Antti Koivisto <antti@apple.com>
1320 Remove PlaceholderDocument
1321 https://bugs.webkit.org/show_bug.cgi?id=126382
1323 Reviewed by Andreas Kling.
1325 Remove PlaceholderDocument class and replace it with a bit in Document.
1327 * WebCore.xcodeproj/project.pbxproj:
1329 (WebCore::Document::Document):
1330 (WebCore::Document::createRenderTree):
1333 Also make Synthesized a construction flag instead of a boolean parameter.
1335 (WebCore::Document::createNonRenderedPlaceholder):
1336 * html/HTMLDocument.cpp:
1337 (WebCore::HTMLDocument::HTMLDocument):
1338 * html/HTMLDocument.h:
1339 (WebCore::HTMLDocument::create):
1340 (WebCore::HTMLDocument::createSynthesizedDocument):
1341 * loader/DocumentWriter.cpp:
1342 (WebCore::DocumentWriter::createDocument):
1343 * loader/PlaceholderDocument.cpp: Removed.
1344 * loader/PlaceholderDocument.h: Removed.
1345 * pdf/ios/PDFDocument.h:
1346 (WebCore::PDFDocument::PDFDocument):
1348 2014-01-01 Antti Koivisto <antti@apple.com>
1350 Remove public attachRenderTree
1351 https://bugs.webkit.org/show_bug.cgi?id=126368
1353 Reviewed by Andreas Kling.
1355 Remove the remaining explicit render tree construction.
1358 (WebCore::Document::createRenderTree):
1360 Use recalcStyle() instead of calling attachRenderTree directly.
1362 * html/HTMLViewSourceDocument.cpp:
1363 (WebCore::HTMLViewSourceDocument::addText):
1365 Remove forgotten attachTextRenderer.
1367 * html/shadow/InsertionPoint.cpp:
1368 (WebCore::InsertionPoint::InsertionPoint):
1370 Remove willAttachRenderers/didAttachRenderers hack.
1372 * html/shadow/InsertionPoint.h:
1373 (WebCore::toInsertionPoint):
1374 * loader/PlaceholderDocument.cpp:
1375 (WebCore::PlaceholderDocument::createRenderTree):
1377 Seriously, nothing to do here.
1379 * style/StyleResolveTree.cpp:
1380 (WebCore::Style::attachDistributedChildren):
1381 (WebCore::Style::attachChildren):
1382 (WebCore::Style::detachDistributedChildren):
1383 (WebCore::Style::detachChildren):
1385 Making attaching and detaching distributed insertion point children part of ResolveTree internals.
1387 * style/StyleResolveTree.h:
1389 Remove interfaces with no clients.
1391 2014-01-01 Seokju Kwon <seokju@webkit.org>
1393 Remove stale ScriptProfiler methods
1394 https://bugs.webkit.org/show_bug.cgi?id=126373
1396 Reviewed by Darin Adler.
1398 No new tests, No change behavior.
1400 * bindings/js/ScriptProfiler.h: Remove dead code.
1402 2014-01-01 Andreas Kling <akling@apple.com>
1404 Remove ChromeClient::fullScreenRendererChanged().
1405 <https://webkit.org/b/126370>
1407 This hook was added in r75277 to notify WebFullScreenController when
1408 the full screen renderer changed. In r110216 the code was refactored,
1409 making this notification unnecessary.
1411 Reviewed by Antti Koivisto.
1413 2014-01-01 Simon Fraser <simon.fraser@apple.com>
1415 Fix the build by exposing some more scrolling state node headers
1416 as Private in WebCore.framework.
1418 * WebCore.xcodeproj/project.pbxproj:
1420 2014-01-01 Ryuan Choi <ryuan.choi@samsung.com>
1422 [EFL] Unreviewed build fix after r160903 when ACCESSIBILITY is disabled
1424 * accessibility/AccessibilityObject.h:
1425 (WebCore::AccessibilityObject::children):
1427 2014-01-01 Andreas Kling <akling@apple.com>
1429 RenderScrollbar: Map of scrollbar parts should use RenderPtr.
1430 <https://webkit.org/b/126367>
1432 Turn RenderScrollbar::m_parts into HashMap of RenderPtrs. This makes
1433 renderer destruction automatic and lets us remove some code.
1435 Reviewed by Antti Koivisto.
1437 * rendering/RenderPtr.h:
1439 Add HashTraits for RenderPtr so we can use them as values in
1442 * rendering/RenderScrollbar.h:
1443 * rendering/RenderScrollbar.cpp:
1444 (WebCore::RenderScrollbar::~RenderScrollbar):
1445 (WebCore::RenderScrollbar::setParent):
1446 (WebCore::RenderScrollbar::updateScrollbarParts):
1447 (WebCore::RenderScrollbar::updateScrollbarPart):
1449 Remove now-unneeded kludges of logic to manually delete scrollbar
1450 part renderers in various scenarios.
1452 2014-01-01 Antti Koivisto <antti@apple.com>
1454 Remove reattachRenderTree
1455 https://bugs.webkit.org/show_bug.cgi?id=126366
1457 Reviewed by Andreas Kling.
1459 Remove the last remaining client.
1461 * html/HTMLSelectElement.cpp:
1462 (WebCore::HTMLSelectElement::parseAttribute):
1464 Reconstruct render tree asynchronously.
1466 (WebCore::HTMLSelectElement::scrollToSelection):
1467 (WebCore::HTMLSelectElement::setOptionsChangedOnRenderer):
1468 (WebCore::HTMLSelectElement::selectOption):
1470 It is not safe to cast the renderer based on usesMenuList test. Switch to RenderObject::isMenuList test.
1472 (WebCore::HTMLSelectElement::parseMultipleAttribute):
1474 Reconstruct render tree asynchronously.
1476 (WebCore::HTMLSelectElement::platformHandleKeydownEvent):
1477 (WebCore::HTMLSelectElement::menuListDefaultEventHandler):
1478 (WebCore::HTMLSelectElement::defaultEventHandler):
1479 * style/StyleResolveTree.cpp:
1480 * style/StyleResolveTree.h:
1482 Remove the function.
1484 2014-01-01 Simon Fraser <simon.fraser@apple.com>
1486 Create a ThreadedScrollingTree subclass of ScrollingTree, and push all knowledge of the scrolling thread into it
1487 https://bugs.webkit.org/show_bug.cgi?id=126362
1489 Reviewed by Sam Weinig.
1491 Eventually we'll have a ScrollingTree in situations where there is no scrolling
1492 thread, so make the ScrollingTree base class thread-agnostic (but threadsafe),
1493 and subclass it in ThreadedScrollingTree for scrolling-thread-specific functionality.
1495 The ScrollingTree base class also no longer needs to know about the
1496 ScrollingCoordinator.
1498 ScrollingCoordinatorMac creates a ThreadedScrollingTree.
1501 * WebCore.xcodeproj/project.pbxproj: Add ThreadedScrollingTree.*
1502 Make some headers Private that we'll need in WebKit2 soon.
1503 * page/scrolling/ScrollingStateTree.h: Drive-by cleanup: clone() was unimplemented.
1504 * page/scrolling/ScrollingTree.cpp:
1505 (WebCore::ScrollingTree::ScrollingTree):
1506 (WebCore::ScrollingTree::~ScrollingTree):
1507 (WebCore::ScrollingTree::shouldHandleWheelEventSynchronously): Wrap up some logic that
1508 involves taking the mutex, so ThreadedScrollingTree can conveniently call it.
1509 (WebCore::ScrollingTree::handleWheelEvent):
1510 (WebCore::ScrollingTree::commitNewTreeState):
1511 (WebCore::ScrollingTree::setMainFrameScrollPosition):
1512 (WebCore::ScrollingTree::isHandlingProgrammaticScroll):
1513 * page/scrolling/ScrollingTree.h:
1514 (WebCore::ScrollingTree::isThreadedScrollingTree):
1515 (WebCore::ScrollingTree::invalidate):
1516 * page/scrolling/ThreadedScrollingTree.cpp: Added.
1517 (WebCore::ThreadedScrollingTree::create):
1518 (WebCore::ThreadedScrollingTree::ThreadedScrollingTree):
1519 (WebCore::ThreadedScrollingTree::~ThreadedScrollingTree):
1520 (WebCore::ThreadedScrollingTree::tryToHandleWheelEvent):
1521 (WebCore::ThreadedScrollingTree::handleWheelEvent):
1522 (WebCore::derefScrollingCoordinator):
1523 (WebCore::ThreadedScrollingTree::invalidate):
1524 (WebCore::ThreadedScrollingTree::commitNewTreeState):
1525 (WebCore::ThreadedScrollingTree::updateMainFrameScrollPosition):
1526 (WebCore::ThreadedScrollingTree::handleWheelEventPhase):
1527 * page/scrolling/ThreadedScrollingTree.h: Added.
1528 (WebCore::ThreadedScrollingTree::isThreadedScrollingTree):
1529 * page/scrolling/mac/ScrollingCoordinatorMac.h:
1530 * page/scrolling/mac/ScrollingCoordinatorMac.mm:
1531 (WebCore::ScrollingCoordinatorMac::ScrollingCoordinatorMac):
1532 (WebCore::ScrollingCoordinatorMac::handleWheelEvent):
1534 2014-01-01 Andreas Kling <akling@apple.com>
1536 FrameView: Store scroll corner renderer in a RenderPtr.
1537 <https://webkit.org/b/126364>
1539 Make FrameView::m_scrollCorner a RenderPtr<RenderScrollbarPart> and
1540 remove two manual destroy() calls.
1542 Reviewed by Antti Koivisto.
1544 2014-01-01 Antti Koivisto <antti@apple.com>
1546 Remove elementChildren/elementDescendants shorthands
1547 https://bugs.webkit.org/show_bug.cgi?id=126363
1549 Reviewed by Anders Carlsson.
1551 Just use childrenOfType<Element>/descendantsOfType<Element> instead. They are not that much longer
1552 and consistency is valuable.
1554 * accessibility/AccessibilityNodeObject.cpp:
1555 (WebCore::AccessibilityNodeObject::canvasHasFallbackContent):
1556 (WebCore::siblingWithAriaRole):
1557 * accessibility/AccessibilityTable.cpp:
1558 (WebCore::AccessibilityTable::isDataTable):
1559 * css/StyleInvalidationAnalysis.cpp:
1560 (WebCore::StyleInvalidationAnalysis::invalidateStyle):
1561 * dom/ChildNodeList.cpp:
1562 (WebCore::ChildNodeList::namedItem):
1564 (WebCore::Document::buildAccessKeyMap):
1565 (WebCore::Document::childrenChanged):
1567 (WebCore::Element::resetComputedStyle):
1568 * dom/ElementChildIterator.h:
1569 * dom/ElementDescendantIterator.h:
1570 * dom/SelectorQuery.cpp:
1571 (WebCore::elementsForLocalName):
1572 (WebCore::anyElement):
1573 (WebCore::SelectorDataList::executeSingleTagNameSelectorData):
1574 (WebCore::SelectorDataList::executeSingleClassNameSelectorData):
1575 (WebCore::SelectorDataList::executeSingleSelectorData):
1576 (WebCore::SelectorDataList::executeSingleMultiSelectorData):
1577 * editing/ApplyStyleCommand.cpp:
1578 (WebCore::ApplyStyleCommand::cleanupUnstyledAppleStyleSpans):
1579 * editing/ReplaceSelectionCommand.cpp:
1580 (WebCore::removeHeadContents):
1581 * editing/markup.cpp:
1582 (WebCore::completeURLs):
1583 * html/HTMLFieldSetElement.cpp:
1584 (WebCore::HTMLFieldSetElement::refreshElementsIfNeeded):
1585 * html/HTMLObjectElement.cpp:
1586 (WebCore::HTMLObjectElement::containsJavaApplet):
1587 * loader/PlaceholderDocument.cpp:
1588 (WebCore::PlaceholderDocument::createRenderTree):
1589 * rendering/RenderChildIterator.h:
1590 * svg/SVGSVGElement.cpp:
1591 (WebCore::SVGSVGElement::getElementById):
1592 * svg/SVGUseElement.cpp:
1593 (WebCore::subtreeContainsDisallowedElement):
1594 (WebCore::removeDisallowedElementsFromSubtree):
1596 2014-01-01 Antti Koivisto <antti@apple.com>
1598 Do less synchronous render tree construction
1599 https://bugs.webkit.org/show_bug.cgi?id=126359
1601 Reviewed by Anders Carlsson.
1603 Remove some now-unnecessary attachRenderTree calls.
1605 * html/HTMLDetailsElement.cpp:
1606 (WebCore::HTMLDetailsElement::parseAttribute):
1607 * html/HTMLInputElement.cpp:
1608 (WebCore::HTMLInputElement::parseAttribute):
1609 * html/HTMLObjectElement.cpp:
1610 (WebCore::HTMLObjectElement::renderFallbackContent):
1611 * html/HTMLPlugInElement.cpp:
1612 (WebCore::HTMLPlugInElement::didAddUserAgentShadowRoot):
1613 * html/HTMLPlugInImageElement.cpp:
1614 (WebCore::HTMLPlugInImageElement::willRecalcStyle):
1615 (WebCore::HTMLPlugInImageElement::createShadowIFrameSubtree):
1616 (WebCore::HTMLPlugInImageElement::restartSnapshottedPlugIn):
1617 * html/HTMLViewSourceDocument.cpp:
1618 (WebCore::HTMLViewSourceDocument::createContainingTable):
1619 (WebCore::HTMLViewSourceDocument::addSpanWithClassName):
1620 (WebCore::HTMLViewSourceDocument::addLine):
1621 (WebCore::HTMLViewSourceDocument::finishLine):
1622 (WebCore::HTMLViewSourceDocument::addBase):
1623 (WebCore::HTMLViewSourceDocument::addLink):
1624 * xml/XMLErrors.cpp:
1625 (WebCore::XMLErrors::insertErrorMessageBlock):
1627 2014-01-01 Simon Fraser <simon.fraser@apple.com>
1629 Updating the scrolling tree should use references to state nodes
1630 https://bugs.webkit.org/show_bug.cgi?id=126360
1632 Reviewed by Anders Carlsson.
1634 Change functions related to ScrollingTreeNode updating to take
1635 const references to state nodes rather than pointers.
1637 * page/scrolling/ScrollingStateNode.h:
1638 (WebCore::ScrollingStateNode::hasChangedProperty):
1639 * page/scrolling/ScrollingTree.cpp:
1640 (WebCore::ScrollingTree::commitNewTreeState):
1641 (WebCore::ScrollingTree::updateTreeFromStateNode): The node can be nil so
1642 this continues to take a pointer.
1643 (WebCore::ScrollingTree::removeDestroyedNodes):
1644 * page/scrolling/ScrollingTree.h:
1645 * page/scrolling/ScrollingTreeNode.h:
1646 (WebCore::ScrollingTreeNode::updateAfterChildren):
1647 * page/scrolling/ScrollingTreeScrollingNode.cpp:
1648 (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
1649 * page/scrolling/ScrollingTreeScrollingNode.h:
1650 * page/scrolling/mac/ScrollingTreeFixedNode.h:
1651 * page/scrolling/mac/ScrollingTreeFixedNode.mm:
1652 (WebCore::ScrollingTreeFixedNode::updateBeforeChildren):
1653 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
1654 * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
1655 (WebCore::ScrollingTreeScrollingNodeMac::updateBeforeChildren):
1656 (WebCore::ScrollingTreeScrollingNodeMac::updateAfterChildren):
1657 * page/scrolling/mac/ScrollingTreeStickyNode.h:
1658 * page/scrolling/mac/ScrollingTreeStickyNode.mm:
1659 (WebCore::ScrollingTreeStickyNode::updateBeforeChildren):
1661 2014-01-01 Simon Fraser <simon.fraser@apple.com>
1663 Add a typedef for PlatformLayerID on GraphicsLayer, and migrate RemoteLayerTreeTransaction to use it
1664 https://bugs.webkit.org/show_bug.cgi?id=126346
1666 Reviewed by Tim Horton.
1668 Remote scrolling tree code is soon going to use RemoteLayerTreeTransaction::LayerID,
1669 so it makes more sense to put this layerID type on GraphicsLayer as
1670 GraphicsLayer::PlatformLayerID.
1672 Also add some type cast macros for PlatformCALayer and subclasses, and use them
1675 * platform/graphics/GraphicsLayer.h:
1676 * platform/graphics/ca/GraphicsLayerCA.cpp:
1677 (WebCore::GraphicsLayerCA::setName):
1678 * platform/graphics/ca/PlatformCALayer.h:
1679 (WebCore::PlatformCALayer::isPlatformCALayerMac):
1680 (WebCore::PlatformCALayer::isPlatformCALayerRemote):
1681 (WebCore::PlatformCALayer::PlatformCALayer):
1682 * platform/graphics/ca/mac/PlatformCALayerMac.h:
1684 2013-12-31 Simon Fraser <simon.fraser@apple.com>
1686 ScrollingStateNodes should have a reference to the ScrollingStateTree
1687 https://bugs.webkit.org/show_bug.cgi?id=126348
1689 Reviewed by Sam Weinig.
1691 Make ScrollingStateNodes always belong to a ScrollingStateTree, and thus
1692 have a reference to the tree rather than a pointer. When cloning nodes,
1693 they are adopted by a new ScrollingStateTree, which adds them to its
1694 node map (which didn't happen before).
1696 In subclasses access the ScrollingStateTree through a member function.
1698 * page/scrolling/ScrollingStateFixedNode.cpp:
1699 (WebCore::ScrollingStateFixedNode::create):
1700 (WebCore::ScrollingStateFixedNode::ScrollingStateFixedNode):
1701 (WebCore::ScrollingStateFixedNode::clone):
1702 (WebCore::ScrollingStateFixedNode::updateConstraints):
1703 * page/scrolling/ScrollingStateFixedNode.h:
1704 * page/scrolling/ScrollingStateNode.cpp:
1705 (WebCore::ScrollingStateNode::ScrollingStateNode):
1706 (WebCore::ScrollingStateNode::cloneAndReset):
1707 (WebCore::ScrollingStateNode::cloneAndResetChildren):
1708 (WebCore::ScrollingStateNode::willBeRemovedFromStateTree):
1709 * page/scrolling/ScrollingStateNode.h:
1710 (WebCore::ScrollingStateNode::scrollingStateTree):
1711 * page/scrolling/ScrollingStateScrollingNode.cpp:
1712 (WebCore::ScrollingStateScrollingNode::create):
1713 (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
1714 (WebCore::ScrollingStateScrollingNode::clone):
1715 (WebCore::ScrollingStateScrollingNode::setViewportRect):
1716 (WebCore::ScrollingStateScrollingNode::setTotalContentsSize):
1717 (WebCore::ScrollingStateScrollingNode::setScrollOrigin):
1718 (WebCore::ScrollingStateScrollingNode::setScrollableAreaParameters):
1719 (WebCore::ScrollingStateScrollingNode::setFrameScaleFactor):
1720 (WebCore::ScrollingStateScrollingNode::setNonFastScrollableRegion):
1721 (WebCore::ScrollingStateScrollingNode::setWheelEventHandlerCount):
1722 (WebCore::ScrollingStateScrollingNode::setSynchronousScrollingReasons):
1723 (WebCore::ScrollingStateScrollingNode::setScrollBehaviorForFixedElements):
1724 (WebCore::ScrollingStateScrollingNode::setRequestedScrollPosition):
1725 (WebCore::ScrollingStateScrollingNode::setHeaderHeight):
1726 (WebCore::ScrollingStateScrollingNode::setFooterHeight):
1727 * page/scrolling/ScrollingStateScrollingNode.h:
1728 * page/scrolling/ScrollingStateStickyNode.cpp:
1729 (WebCore::ScrollingStateStickyNode::create):
1730 (WebCore::ScrollingStateStickyNode::ScrollingStateStickyNode):
1731 (WebCore::ScrollingStateStickyNode::clone):
1732 (WebCore::ScrollingStateStickyNode::updateConstraints):
1733 * page/scrolling/ScrollingStateStickyNode.h:
1734 * page/scrolling/ScrollingStateTree.cpp:
1735 (WebCore::ScrollingStateTree::attachNode):
1736 (WebCore::ScrollingStateTree::commit):
1737 (WebCore::ScrollingStateTree::addNode):
1738 * page/scrolling/ScrollingStateTree.h:
1739 * page/scrolling/mac/ScrollingStateNodeMac.mm:
1740 (WebCore::ScrollingStateNode::setScrollLayer):
1741 * page/scrolling/mac/ScrollingStateScrollingNodeMac.mm:
1742 (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayer):
1743 (WebCore::ScrollingStateScrollingNode::setHeaderLayer):
1744 (WebCore::ScrollingStateScrollingNode::setFooterLayer):
1745 (WebCore::ScrollingStateScrollingNode::setScrollbarPaintersFromScrollbars):
1747 2013-12-31 Simon Fraser <simon.fraser@apple.com>
1749 Give ScrollingStateNodes a nodeType()
1750 https://bugs.webkit.org/show_bug.cgi?id=126347
1752 Reviewed by Tim Horton.
1754 When we start serializing ScrollingStateNodes to send to the UI process,
1755 it's more convenient if they have a nodeType member rather than virtual functions,
1756 so give them one, and fix the casting macros to use it. This allows us to use
1757 a switch() on node creation, so the compiler will tell us if we forgot to create
1760 * page/scrolling/ScrollingStateFixedNode.cpp:
1761 (WebCore::ScrollingStateFixedNode::ScrollingStateFixedNode):
1762 * page/scrolling/ScrollingStateFixedNode.h:
1763 * page/scrolling/ScrollingStateNode.cpp:
1764 (WebCore::ScrollingStateNode::ScrollingStateNode):
1765 * page/scrolling/ScrollingStateNode.h: const ScrollingNodeType field
1766 (can't be modified after construction), and move the m_scrollingStateTree
1767 member after it (the awkward protected:/private: will be cleaned up in a later patch).
1768 (WebCore::ScrollingStateNode::nodeType):
1769 * page/scrolling/ScrollingStateScrollingNode.cpp:
1770 (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
1771 * page/scrolling/ScrollingStateScrollingNode.h:
1772 * page/scrolling/ScrollingStateStickyNode.cpp:
1773 (WebCore::ScrollingStateStickyNode::ScrollingStateStickyNode):
1774 * page/scrolling/ScrollingStateStickyNode.h:
1775 * page/scrolling/ScrollingTree.cpp:
1776 (WebCore::ScrollingTree::updateTreeFromStateNode):
1778 2013-12-31 Andreas Kling <akling@apple.com>
1780 Out-of-line RenderStyle substructure copying helpers.
1781 <https://webkit.org/b/126340>
1783 This shrinks the .access() calls by moving memory allocation logic
1784 out-of-line, though I'm really doing this to make Instruments.app
1785 allocations output more readable.
1787 Writes to e.g 'font' or 'color' will now be grouped under a single
1788 StyleInheritedData::copy() call instead of being spread out over
1789 setFontDescription(), setLineHeight(), setColor(), etc.
1791 Reviewed by Anders Carlsson.
1793 2013-12-31 Andreas Kling <akling@apple.com>
1795 RenderListItem should store its marker in a RenderPtr.
1796 <https://webkit.org/b/126298>
1798 Make RenderListItem::m_marker a RenderPtr<RenderListMarker> and
1799 remove two manual destroy() calls. Tweaked code to reduce nesting.
1801 Reviewed by Anders Carlsson.
1803 2013-12-31 Andreas Kling <akling@apple.com>
1805 Element's renderer factory should return RenderPtrs.
1806 <https://webkit.org/b/126318>
1808 Rename Element::createRenderer() to createElementRenderer() and have
1809 it return RenderPtr<RenderElement>. Propagate signature until it
1812 We leakPtr() the renderer at two call sites when handing things over
1813 to raw pointer API. This'll get tidied up in subsequent patches.
1815 Reviewed by Sam Weinig.
1817 2013-12-31 Carlos Garcia Campos <cgarcia@igalia.com>
1819 [SOUP] Return early in ResourceHandle::receivedCancellation if the load has already cancelled
1820 https://bugs.webkit.org/show_bug.cgi?id=126287
1822 Reviewed by Martin Robinson.
1824 This situation can happen when using the network process, because
1825 the ReceivedCancellation message can be received when the resource
1826 loader has already been removed, but the authentication challenge
1827 still has a reference to the ResourceHandleClient.
1829 * platform/network/soup/ResourceHandleSoup.cpp:
1830 (WebCore::ResourceHandle::receivedCancellation):
1832 2013-12-31 Carlos Garcia Campos <cgarcia@igalia.com>
1834 [SOUP] The initiating page is lost after a redirection
1835 https://bugs.webkit.org/show_bug.cgi?id=126293
1837 Reviewed by Martin Robinson.
1839 The initiating page id is attached to the initial soup request
1840 object, but not to the one created after a redirection.
1842 * platform/network/soup/ResourceHandleSoup.cpp:
1843 (WebCore::createSoupRequestAndMessageForHandle): Call
1844 setSoupRequestInitiatingPageIDFromNetworkingContext() here if the
1845 soup request is created successfully.
1846 (WebCore::ResourceHandle::start): Remove the call to
1847 setSoupRequestInitiatingPageIDFromNetworkingContext().
1849 2013-12-31 Carlos Garcia Campos <cgarcia@igalia.com>
1851 [SOUP] Implement ResourceHandle::continueWillSendRequest()
1852 https://bugs.webkit.org/show_bug.cgi?id=126291
1854 Reviewed by Martin Robinson.
1856 * platform/network/soup/ResourceHandleSoup.cpp:
1857 (WebCore::continueAfterWillSendRequest): Helper function that
1858 continues with the load after willSendRequest has been called.
1859 (WebCore::doRedirect): Call continueAfterWillSendRequest() when
1860 client doesn't use async callbacks.
1861 (WebCore::ResourceHandle::continueWillSendRequest): Call
1862 continueAfterWillSendRequest().
1864 2013-12-30 Carlos Garcia Campos <cgarcia@igalia.com>
1866 [SOUP] willSendRequest doesn't work after a redirect
1867 https://bugs.webkit.org/show_bug.cgi?id=126290
1869 Reviewed by Martin Robinson.
1871 The problem is that we are creating the new soup request for the
1872 redirect before calling ResourceHandleClient::willSendRequest() so
1873 that any change made to the request by the client is ignored.
1875 * platform/network/soup/ResourceHandleSoup.cpp:
1876 (WebCore::doRedirect): Create the new soup request and soup
1877 message for the redirect after calling willSendRequest() on the
1880 2013-12-30 Andreas Kling <akling@apple.com>
1882 InputType should return input renderers wrapped in RenderPtr.
1883 <https://webkit.org/b/126307>
1885 Rename InputType::createRenderer() to createInputRenderer() and
1886 make it return RenderPtr<RenderElement>. Also made it non-const.
1888 Reviewed by Anders Carlsson.
1890 2013-12-30 Gyuyoung Kim <gyuyoung.kim@samsung.com>
1892 Cleanup static_cast<HTMLFormElement*> by using toHTMLFormElement()
1893 https://bugs.webkit.org/show_bug.cgi?id=126309
1895 Reviewed by Andreas Kling.
1897 To detect bad type casts, it would be good to use toHTMLFormElement() instead of
1898 using manual type cast. Additionally FORM_ASSOCIATED_ELEMENT_TYPE_CASTS is introduced newly
1901 No new tests, no behavior changes.
1903 * html/FormAssociatedElement.h:
1904 * html/HTMLFormControlElement.h:
1905 * html/HTMLFormElement.cpp:
1906 (WebCore::HTMLFormElement::submitImplicitly):
1907 (WebCore::HTMLFormElement::validateInteractively):
1908 (WebCore::HTMLFormElement::submit):
1909 (WebCore::HTMLFormElement::reset):
1910 (WebCore::HTMLFormElement::defaultButton):
1911 (WebCore::HTMLFormElement::checkInvalidControlsAndCollectUnhandled):
1912 (WebCore::HTMLFormElement::documentDidResumeFromPageCache):
1913 * loader/FormSubmission.cpp:
1914 (WebCore::FormSubmission::create):
1916 2013-12-30 Anders Carlsson <andersca@apple.com>
1918 Replace yield() and pauseBriefly() with std::this_thread::yield()
1919 https://bugs.webkit.org/show_bug.cgi?id=126105
1921 Reviewed by Sam Weinig.
1923 * platform/sql/SQLiteDatabase.cpp:
1924 (WebCore::SQLiteDatabase::interrupt):
1926 2013-12-30 Andreas Kling <akling@apple.com>
1928 Rename createRenderObject() to createRenderer().
1930 Somewhat rubber-stamped by Antti Koivisto.
1932 2013-12-30 Andreas Kling <akling@apple.com>
1934 Document should store its RenderView in a RenderPtr.
1935 <https://webkit.org/b/126299>
1937 Make Document::m_renderView a RenderPtr<RenderView> and remove one
1938 manual destroy() call. Also removed the setRenderView() helper and
1939 inlined it at the two call sites.
1941 Reviewed by Antti Koivisto.
1943 2013-12-30 Martin Robinson <mrobinson@igalia.com>
1945 [CMake] [GTK] Add support for GObject introspection
1946 https://bugs.webkit.org/show_bug.cgi?id=126162
1948 Reviewed by Daniel Bates.
1950 * PlatformGTK.cmake: Build a list of WebKitDOM headers and expose it to the
1951 parent scope of the build.
1953 2013-12-30 Andreas Kling <akling@apple.com>
1955 Text::createTextRenderer() should return a RenderPtr.
1956 <https://webkit.org/b/126292>
1958 Make createTextRenderer() return a RenderPtr and remove one manual
1959 destroy() call. Also, since it should always return a valid object,
1960 I turned a null check into an assertion instead.
1962 Reviewed by Antti Koivisto.
1964 2013-12-30 Antti Koivisto <antti@apple.com>
1967 https://bugs.webkit.org/show_bug.cgi?id=126288
1969 Reviewed by Andreas Kling.
1971 * dom/ContainerNode.cpp:
1972 (WebCore::destroyRenderTreeIfNeeded):
1974 Rename detachChild and move the tests here.
1976 (WebCore::ContainerNode::takeAllChildrenFrom):
1978 No need to call attachRenderTree explicitly anymore.
1980 (WebCore::ContainerNode::removeBetween):
1982 2013-12-29 Andreas Kling <akling@apple.com>
1984 RenderLayer: Store corner and resizer renderers in RenderPtrs.
1985 <https://webkit.org/b/126274>
1987 Turn RenderLayer::m_scrollCorner and m_resizer into RenderPtrs.
1988 Removed manual destroy() calls as appropriate. Also tweaked some
1989 code to reduce nesting.
1991 Reviewed by Anders Carlsson.
1993 2013-12-30 Antti Koivisto <antti@apple.com>
1995 XML document builder should create render tree asynchronously
1996 https://bugs.webkit.org/show_bug.cgi?id=126285
1998 Reviewed by Andreas Kling.
2000 Stop creating renderers explicitly.
2001 Fix SVG <use> element to not rely on parse time render tree construction.
2003 * svg/SVGUseElement.cpp:
2004 (WebCore::SVGUseElement::svgAttributeChanged):
2006 Remove renderer check, we may not have created the render tree yet.
2008 (WebCore::SVGUseElement::willAttachRenderers):
2010 Switch to willAttachRenderers from willRecalcStyle. The latter is only called as long as style
2011 recalc doesn't start creating new renderers.
2013 (WebCore::SVGUseElement::invalidateShadowTree):
2015 Remove renderer check, we may not have created the render tree yet.
2016 Invalidate with ReconstructRenderTree so willAttachRenderers will always get called.
2018 * svg/SVGUseElement.h:
2019 * xml/parser/XMLDocumentParser.cpp:
2020 (WebCore::XMLDocumentParser::exitText):
2021 * xml/parser/XMLDocumentParserLibxml2.cpp:
2022 (WebCore::XMLDocumentParser::startElementNs):
2023 (WebCore::XMLDocumentParser::cdataBlock):
2025 Remove explicit call to attachRenderTree. The render tree will be created lazily.
2027 2013-12-29 Joone Hur <joone.hur@intel.com>
2029 Reverted r156742. The same fix was reverted from Blink due to heap-use-after-free on ClusterFuzz.
2030 https://bugs.webkit.org/show_bug.cgi?id=126275
2032 https://codereview.chromium.org/102993011
2034 Reviewed by Darin Adler.
2036 * rendering/RenderBlock.cpp:
2037 (WebCore::RenderBlock::updateFirstLetter):
2039 2013-12-29 ChangSeok Oh <changseok.oh@collabora.com>
2041 Remove unused functions in GraphicsContext3D.cpp
2042 https://bugs.webkit.org/show_bug.cgi?id=126265
2044 Reviewed by Andreas Kling.
2046 platformGraphicsContext3D, platformTexture and platformLayer in GC3D.cpp
2047 seem not used by any ports.
2049 No new tests, no functionality changed.
2051 * platform/graphics/GraphicsContext3D.cpp:
2053 2013-12-29 Gyuyoung Kim <gyuyoung.kim@samsung.com>
2055 Fix build error on 64bit debug build.
2056 https://bugs.webkit.org/show_bug.cgi?id=126248
2058 r161076 used ‘%lli’(for long long int) for int64_t(aka long int).
2059 However, in a 64bit compile, int64_t is 'long int', not a 'long long int'.
2060 To support 32bit and 64bit, we use static_cast<long long>.
2062 * Modules/indexeddb/IDBTransactionBackend.cpp:
2063 (WebCore::IDBTransactionBackend::commit):
2065 2013-12-29 Antti Koivisto <antti@apple.com>
2067 Remove some accidental commented out code.
2069 * testing/Internals.cpp:
2070 (WebCore::Internals::mallocStatistics):
2072 2013-12-29 Antti Koivisto <antti@apple.com>
2076 * xml/parser/XMLDocumentParser.cpp:
2078 2013-12-29 Antti Koivisto <antti@apple.com>
2080 Remove Node::attached()
2081 https://bugs.webkit.org/show_bug.cgi?id=126276
2083 Reviewed by Sam Weinig.
2085 Node::attached() is poorly defined. Replace it with renderer() and inRenderedDocument() tests as appropriate.
2087 Also remove some unnecessary explicit attachRenderTree/detachRenderTree calls from the tree builders.
2089 2013-12-29 Andreas Kling <akling@apple.com>
2091 RenderLayer: Store reflection renderer in a RenderPtr.
2092 <https://webkit.org/b/126273>
2094 Reviewed by Anders Carlsson.
2096 * rendering/RenderLayer.h:
2097 * rendering/RenderLayer.cpp:
2098 (WebCore::RenderLayer::RenderLayer):
2099 (WebCore::RenderLayer::calculateClipRects):
2101 Turn RenderLayer::m_reflection into a RenderPtr<RenderReplica>
2102 instead of a raw pointer.
2104 * WebCore.xcodeproj/project.pbxproj:
2106 Add RenderPtr.h to private headers.
2108 2013-12-28 Andreas Kling <akling@apple.com>
2110 Add an owning smart pointer for RenderObjects and start using it.
2111 <https://webkit.org/b/126251>
2113 This patch adds a RenderPtr pointer, essentially an OwnPtr for
2114 RenderObjects. The difference is that RenderPtr destroys the object
2115 by calling destroy() on it.
2117 This is necessary to implement the willBeDestroyed() mechanism in
2118 RenderObject that notifies renderers just before they are about to
2119 be deleted, while they can still do tree traversal, etc.
2121 I also added a make_unique-alike helper so you can write:
2123 auto renderer = createRenderObject<RenderImage>(...);
2125 Put it all to use by making ContentData::createRenderer() return
2126 RenderPtr<RenderObject> instead of raw RenderObject*.
2128 Reviewed by Antti Koivisto.
2130 2013-12-28 Benjamin Poulain <benjamin@webkit.org>
2132 Add a missing include path for GTK
2133 https://bugs.webkit.org/show_bug.cgi?id=126257
2135 Reviewed by Philippe Normand.
2139 2013-12-28 Carlos Garcia Campos <cgarcia@igalia.com>
2141 Unreviewed. Update GObject DOM symbols file after r160733.
2143 * bindings/gobject/webkitdom.symbols:
2145 2013-12-28 Carlos Garcia Campos <cgarcia@igalia.com>
2147 [GTK] Downloads are broken with the network process enabled
2148 https://bugs.webkit.org/show_bug.cgi?id=126131
2150 Reviewed by Martin Robinson.
2152 The problem is that the network process crashes when trying to
2153 convert the handle to a download, because at that point the
2154 download has finished and the handle is NULL. This happens because
2155 we are not implementing ResourceHandle::continueDidReceiveResponse().
2157 * platform/network/soup/ResourceHandleSoup.cpp:
2158 (WebCore::nextMultipartResponsePartCallback): Call
2159 continueAfterDidReceiveResponse() when not using async callbacks.
2160 (WebCore::sendRequestCallback): Ditto.
2161 (WebCore::continueAfterDidReceiveResponse): Helper function that
2162 continues the load after didReceiveResponse.
2163 (WebCore::ResourceHandle::continueDidReceiveResponse): Call
2164 continueAfterDidReceiveResponse().
2166 2013-12-27 Daniel Bates <dabates@apple.com>
2168 Another attempt to fix the Windows build after <http://trac.webkit.org/changeset/161106>
2169 (https://bugs.webkit.org/show_bug.cgi?id=126180)
2171 * WebCore.vcxproj/WebCore.vcxproj.filters: Add files platform/audio/{AudioSession, AudioSessionListener}.h
2172 * WebCore.vcxproj/WebCoreCommon.props: Add directory WebCore/platform/audio to the list of
2173 include directories.
2175 2013-12-27 Daniel Bates <dabates@apple.com>
2177 Attempt to fix the Windows build after <http://trac.webkit.org/changeset/161106>
2178 (https://bugs.webkit.org/show_bug.cgi?id=126180)
2180 Add files platform/audio/AudioSession.{cpp, h} and platform/audio/AudioSessionListener.h
2181 to the Visual Studio project. Note, the contents of these files are guarded by USE(AUDIO_SESSION),
2182 which is only enabled on Mac and iOS at the time of writing.
2184 I thought to try this approach to fix the build so as to avoid adding an extraneous
2185 USE(AUDIO_SESSION)-guard around the #include "AudioSession.h" in Settings.cpp since
2186 the contents of the file AudioSession.h is guarded by USE(AUDIO_SESSION).
2188 * WebCore.vcxproj/WebCore.vcxproj:
2190 2013-12-27 Daniel Bates <dabates@apple.com>
2192 [iOS] Upstream WebCore/page changes
2193 https://bugs.webkit.org/show_bug.cgi?id=126180
2195 Reviewed by Darin Adler.
2197 * WebCore.xcodeproj/project.pbxproj:
2199 (WebCore::EventNames::isGestureEventType): Added.
2200 * page/AlternativeTextClient.h: Do not define WTF_USE_DICTATION_ALTERNATIVES when building for iOS.
2202 (WebCore::Chrome::Chrome):
2203 (WebCore::Chrome::dispatchViewportPropertiesDidChange): Added; guarded by PLATFORM(IOS).
2204 (WebCore::Chrome::setCursor): Make this an empty function when building for iOS.
2205 (WebCore::Chrome::setCursorHiddenUntilMouseMoves): Ditto.
2206 (WebCore::Chrome::didReceiveDocType): Added; iOS-specific.
2208 (WebCore::Chrome::setDispatchViewportDataDidChangeSuppressed): Added; guarded by PLATFORM(IOS).
2209 * page/ChromeClient.h:
2210 (WebCore::ChromeClient::didFlushCompositingLayers): Added; guarded by PLATFORM(IOS).
2211 (WebCore::ChromeClient::fetchCustomFixedPositionLayoutRect): Added; guarded by PLATFORM(IOS).
2212 (WebCore::ChromeClient::updateViewportConstrainedLayers): Added; guarded by PLATFORM(IOS).
2213 * page/DOMTimer.cpp:
2214 (WebCore::DOMTimer::install): Added iOS-specific code.
2215 (WebCore::DOMTimer::fired): Ditto.
2216 * page/DOMWindow.cpp:
2217 (WebCore::DOMWindow::DOMWindow): Ditto.
2218 (WebCore::DOMWindow::innerHeight): Ditto.
2219 (WebCore::DOMWindow::innerWidth): Ditto.
2220 (WebCore::DOMWindow::scrollX): Ditto.
2221 (WebCore::DOMWindow::scrollY): Ditto.
2222 (WebCore::DOMWindow::scrollBy): Ditto.
2223 (WebCore::DOMWindow::scrollTo): Ditto.
2224 (WebCore::DOMWindow::clearTimeout): Ditto.
2225 (WebCore::DOMWindow::addEventListener): Ditto.
2226 (WebCore::DOMWindow::incrementScrollEventListenersCount): Added; guarded by PLATFORM(IOS).
2227 (WebCore::DOMWindow::decrementScrollEventListenersCount): Added; guarded by PLATFORM(IOS).
2228 (WebCore::DOMWindow::resetAllGeolocationPermission): Added; Also added FIXME comment.
2229 (WebCore::DOMWindow::removeEventListener): Added iOS-specific code.
2230 (WebCore::DOMWindow::dispatchEvent): Modified to prevent dispatching duplicate pageshow and pagehide
2231 events per <http://www.whatwg.org/specs/web-apps/current-work/multipage/history.html#event-pageshow>.
2232 (WebCore::DOMWindow::removeAllEventListeners): Added iOS-specific code.
2234 * page/DOMWindow.idl: Added IOS_GESTURE_EVENTS-guarded attributes: ongesture{change, end, start}. Also
2235 added IOS_TOUCH_EVENTS-guarded attributes: {Touch, TouchList}Constructor.
2236 * page/EditorClient.h:
2237 * page/EventHandler.cpp:
2238 (WebCore::EventHandler::EventHandler): Added iOS-specific code.
2239 (WebCore::EventHandler::clear): Ditto.
2240 (WebCore::EventHandler::startPanScrolling): Make this an empty function when building for iOS.
2241 (WebCore::EventHandler::handleMousePressEvent): Modified to invalidate a click when the clicked node is
2242 null. Also, opt out of code for updating the scrollbars as UIKit manages scrollbars on iOS.
2243 (WebCore::EventHandler::handleMouseMoveEvent): Opt of code for updating the scrollbars and cursor when building on iOS.
2244 (WebCore::hitTestResultInFrame): Made this a file-local static function since it's only used in EventHandler.cpp.
2245 (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled): Added iOS-specific code.
2246 * page/EventHandler.h:
2247 * page/FocusController.h:
2249 (WebCore::Frame::Frame): Added iOS-specific code.
2250 (WebCore::Frame::scrollOverflowLayer): Added; iOS-specific.
2251 (WebCore::Frame::overflowAutoScrollTimerFired): Added; iOS-specific.
2252 (WebCore::Frame::startOverflowAutoScroll): Added; iOS-specific.
2253 (WebCore::Frame::checkOverflowScroll): Added; iOS-specific.
2254 (WebCore::Frame::willDetachPage): Added iOS-specific code.
2255 (WebCore::Frame::createView): Ditto.
2256 (WebCore::Frame::setSelectionChangeCallbacksDisabled): Added; iOS-specific.
2257 (WebCore::Frame::selectionChangeCallbacksDisabled): Added; iOS-specific.
2259 (WebCore::Frame::timersPaused): Added; guarded by PLATFORM(IOS).
2260 * page/FrameView.cpp:
2261 (WebCore::FrameView::FrameView): Added iOS-specific code.
2262 (WebCore::FrameView::clear): Ditto.
2263 (WebCore::FrameView::flushCompositingStateForThisFrame): Ditto.
2264 (WebCore::FrameView::graphicsLayerForPlatformWidget): Added.
2265 (WebCore::FrameView::scheduleLayerFlushAllowingThrottling): Added.
2266 (WebCore::FrameView::layout): Added iOS-specific code.
2267 (WebCore::countRenderedCharactersInRenderObjectWithThreshold): Added; helper function used by FrameView::renderedCharactersExceed().
2268 Also added FIXME comment.
2269 (WebCore::FrameView::renderedCharactersExceed): Added.
2270 (WebCore::FrameView::visibleContentsResized): Added iOS-specific code.
2271 (WebCore::FrameView::adjustTiledBackingCoverage): Ditto.
2272 (WebCore::FrameView::performPostLayoutTasks): Ditto.
2273 (WebCore::FrameView::sendResizeEventIfNeeded): Ditto.
2274 (WebCore::FrameView::paintContents): Added iOS-specific code. Also added FIXME comments.
2275 (WebCore::FrameView::setUseCustomFixedPositionLayoutRect): Added; iOS-specific.
2276 (WebCore::FrameView::setCustomFixedPositionLayoutRect): Added; iOS-specific.
2277 (WebCore::FrameView::updateFixedPositionLayoutRect): Added; iOS-specific.
2279 * page/Navigator.cpp:
2280 (WebCore::Navigator::standalone): Added; iOS-specific.
2282 * page/Navigator.idl: Added WTF_PLATFORM_IOS-guarded attribute: standalone. Also added FIXME comment.
2283 * page/NavigatorBase.cpp:
2284 (WebCore::NavigatorBase::platform): Added iOS-specific code.
2286 (WebCore::Page::hasCustomHTMLTokenizerTimeDelay): Added; guarded by PLATFORM(IOS). Also added FIXME comment
2287 to remove this method.
2288 (WebCore::Page::customHTMLTokenizerTimeDelay): Added; guarded by PLATFORM(IOS). Also added FIXME comment
2289 to remove this method.
2290 * page/PageGroup.cpp:
2291 (WebCore::PageGroup::removeVisitedLink): Added.
2293 * page/Settings.cpp:
2294 (WebCore::Settings::Settings):
2295 (WebCore::Settings::setScriptEnabled): Added; guarded by PLATFORM(IOS).
2296 (WebCore::Settings::setStandalone): Added; guarded by PLATFORM(IOS).
2297 (WebCore::Settings::setAudioSessionCategoryOverride): Added; guarded by PLATFORM(IOS).
2298 (WebCore::Settings::audioSessionCategoryOverride): Added; guarded by PLATFORM(IOS).
2299 (WebCore::Settings::setNetworkDataUsageTrackingEnabled): Added; guarded by PLATFORM(IOS).
2300 (WebCore::Settings::networkDataUsageTrackingEnabled): Added; guarded by PLATFORM(IOS).
2301 (WebCore::sharedNetworkInterfaceNameGlobal): Added; guarded by PLATFORM(IOS).
2302 (WebCore::Settings::setNetworkInterfaceName): Added; guarded by PLATFORM(IOS).
2303 (WebCore::Settings::networkInterfaceName): Added; guarded by PLATFORM(IOS).
2305 (WebCore::Settings::setMaxParseDuration): Added; guarded by PLATFORM(IOS). Also added FIXME comment.
2306 (WebCore::Settings::maxParseDuration): Added; guarded by PLATFORM(IOS). Also added FIXME comment.
2307 (WebCore::Settings::standalone): Added; guarded by PLATFORM(IOS).
2308 (WebCore::Settings::setTelephoneNumberParsingEnabled): Added; guarded by PLATFORM(IOS).
2309 (WebCore::Settings::telephoneNumberParsingEnabled): Added; guarded by PLATFORM(IOS).
2310 (WebCore::Settings::setMediaDataLoadsAutomatically): Added; guarded by PLATFORM(IOS).
2311 (WebCore::Settings::mediaDataLoadsAutomatically): Added; guarded by PLATFORM(IOS).
2312 (WebCore::Settings::setShouldTransformsAffectOverflow): Added; guarded by PLATFORM(IOS).
2313 (WebCore::Settings::shouldTransformsAffectOverflow): Added; guarded by PLATFORM(IOS).
2314 (WebCore::Settings::setShouldDispatchJavaScriptWindowOnErrorEvents): Added; guarded by PLATFORM(IOS).
2315 (WebCore::Settings::shouldDispatchJavaScriptWindowOnErrorEvents): Added; guarded by PLATFORM(IOS).
2316 (WebCore::Settings::setAlwaysUseBaselineOfPrimaryFont): Added; guarded by PLATFORM(IOS).
2317 (WebCore::Settings::alwaysUseBaselineOfPrimaryFont): Added; guarded by PLATFORM(IOS).
2318 (WebCore::Settings::setAlwaysUseAcceleratedOverflowScroll): Added; guarded by PLATFORM(IOS).
2319 (WebCore::Settings::alwaysUseAcceleratedOverflowScroll): Added; guarded by PLATFORM(IOS).
2320 * page/Settings.in: Added IOS_AIRPLAY-guarded setting: mediaPlaybackAllowsAirPlay.
2321 * page/animation/CSSPropertyAnimation.cpp:
2322 (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap): Added iOS-specific code and FIXME comment.
2323 * page/ios/EventHandlerIOS.mm: Added.
2324 * page/ios/FrameIOS.mm: Added.
2325 * page/mac/ChromeMac.mm:
2326 * page/mac/PageMac.cpp:
2327 (WebCore::Page::addSchedulePair): Opt out of code when building for iOS.
2328 (WebCore::Page::removeSchedulePair): Ditto.
2329 * page/mac/SettingsMac.mm:
2330 (WebCore::Settings::shouldEnableScreenFontSubstitutionByDefault): Added iOS-specific code.
2331 * page/mac/WebCoreFrameView.h:
2333 2013-12-27 Gavin Barraclough <barraclough@apple.com>
2335 Merge PageVisibilityState & ViewState::IsVisible in WebKit2
2336 https://bugs.webkit.org/show_bug.cgi?id=126214
2338 Reviewed by Alexey Proskuryakov.
2340 WebKit2 redundantly tracks the visibility of the view through two mechanisms - the visibility
2341 state, and the view state. Remove visibility state from the WebKit2 layer. The visibility
2342 state also tracks the prerender state - so split this out and handle it separately (a change
2343 we should make in WebCore, too).
2345 WebCore - changes the API tests exposed a bug, a view should only ever come out of the
2346 prerender state when it becomes visible - redundant notifications that the view is still
2347 hidden should be ignored.
2350 (WebCore::Page::setVisibilityState):
2351 - ignore visibility state change to hidden, if the current state is prerender.
2353 2013-12-27 Joseph Pecoraro <pecoraro@apple.com>
2355 Unreviewed Windows build fix for r160946.
2357 Add another file to the Windows InspectorAllInOne.cpp.
2359 * inspector/InspectorAllInOne.cpp:
2361 2013-12-27 Commit Queue <commit-queue@webkit.org>
2363 Unreviewed, rolling out r161096.
2364 http://trac.webkit.org/changeset/161096
2365 https://bugs.webkit.org/show_bug.cgi?id=126256
2367 Made lots of tests crash (Requested by ap on #webkit).
2369 * dom/ContainerNode.cpp:
2370 (WebCore::ContainerNode::insertBefore):
2371 (WebCore::ContainerNode::replaceChild):
2372 (WebCore::willRemoveChildren):
2373 (WebCore::ContainerNode::appendChild):
2375 (WebCore::Document::visibilityStateChanged):
2376 (WebCore::Document::moveNodeIteratorsToNewDocument):
2377 (WebCore::Document::updateRangesAfterChildrenChanged):
2378 (WebCore::Document::nodeChildrenWillBeRemoved):
2379 (WebCore::Document::nodeWillBeRemoved):
2380 (WebCore::Document::textInserted):
2381 (WebCore::Document::textRemoved):
2382 (WebCore::Document::textNodesMerged):
2383 (WebCore::Document::textNodeSplit):
2384 (WebCore::Document::documentWillSuspendForPageCache):
2385 (WebCore::Document::documentDidResumeFromPageCache):
2386 (WebCore::Document::mediaVolumeDidChange):
2387 (WebCore::Document::privateBrowsingStateDidChange):
2388 (WebCore::Document::captionPreferencesChanged):
2389 (WebCore::Document::validateAutoSizingNodes):
2390 (WebCore::Document::resetAutoSizingNodes):
2391 (WebCore::Document::webkitExitFullscreen):
2392 * dom/MutationObserver.cpp:
2393 (WebCore::MutationObserver::disconnect):
2394 (WebCore::MutationObserver::getObservedNodes):
2395 (WebCore::MutationObserver::deliver):
2396 * dom/MutationObserverInterestGroup.cpp:
2397 (WebCore::MutationObserverInterestGroup::isOldValueRequested):
2398 (WebCore::MutationObserverInterestGroup::enqueueMutationRecord):
2399 * dom/MutationObserverRegistration.cpp:
2400 (WebCore::MutationObserverRegistration::clearTransientRegistrations):
2401 (WebCore::MutationObserverRegistration::addRegistrationNodesToSet):
2403 (WebCore::Node::dumpStatistics):
2404 (WebCore::Document::invalidateNodeListAndCollectionCaches):
2405 (WebCore::NodeListsNodeData::invalidateCaches):
2406 (WebCore::Node::didMoveToNewDocument):
2407 (WebCore::collectMatchingObserversForMutation):
2408 (WebCore::Node::notifyMutationObserversNodeWillDetach):
2409 * dom/NodeRareData.h:
2410 (WebCore::NodeListsNodeData::adoptDocument):
2411 * dom/ScriptExecutionContext.cpp:
2412 (WebCore::ScriptExecutionContext::~ScriptExecutionContext):
2413 (WebCore::ScriptExecutionContext::canSuspendActiveDOMObjects):
2414 (WebCore::ScriptExecutionContext::suspendActiveDOMObjects):
2415 (WebCore::ScriptExecutionContext::resumeActiveDOMObjects):
2416 (WebCore::ScriptExecutionContext::stopActiveDOMObjects):
2417 (WebCore::ScriptExecutionContext::closeMessagePorts):
2418 (WebCore::ScriptExecutionContext::adjustMinimumTimerInterval):
2419 (WebCore::ScriptExecutionContext::didChangeTimerAlignmentInterval):
2420 * dom/WebKitNamedFlow.cpp:
2421 (WebCore::WebKitNamedFlow::getRegionsByContent):
2422 (WebCore::WebKitNamedFlow::getRegions):
2423 (WebCore::WebKitNamedFlow::getContent):
2425 2013-12-26 Sam Weinig <sam@webkit.org>
2427 Convert some of WebCore/dom over to range-for loops
2428 https://bugs.webkit.org/show_bug.cgi?id=126250
2430 Reviewed by Andreas Kling.
2432 * dom/ContainerNode.cpp:
2434 * dom/MutationObserver.cpp:
2435 * dom/MutationObserverInterestGroup.cpp:
2436 * dom/MutationObserverRegistration.cpp:
2438 * dom/NodeRareData.h:
2439 * dom/ScriptExecutionContext.cpp:
2440 * dom/WebKitNamedFlow.cpp:
2442 2013-12-26 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
2444 [Nix] Cleanup Source/WebCore/PlatformNix.cmake
2445 https://bugs.webkit.org/show_bug.cgi?id=126226
2447 Reviewed by Csaba Osztrogonác.
2449 No new tests needed.
2451 * PlatformNix.cmake:
2453 2013-12-26 Joseph Pecoraro <pecoraro@apple.com>
2455 Unreviewed attempt at Windows build fix.
2457 I think Window's "AllInOne.cpp" is causing a using namespace JSC
2458 to cause naming conflicts between Inspector::TypeBuilder::Debugger::types
2459 and JSC::types. So removing the ambiguity.
2461 * inspector/InjectedScript.cpp:
2462 (WebCore::InjectedScript::getProperties):
2463 (WebCore::InjectedScript::wrapCallFrames):
2465 2013-12-22 Andreas Kling <akling@apple.com>
2467 Make Text::createTextRenderer() take a const RenderStyle&.
2468 <https://webkit.org/b/126136>
2470 Nuke a FIXME about constifying a RenderStyle& local.
2472 Reviewed by Anders Carlsson.
2474 2013-12-22 Andreas Kling <akling@apple.com>
2476 Move more inlines from RenderObject to RenderElement.
2477 <https://webkit.org/b/126134>
2479 Lift some inline functions that use style() from RenderObject over
2480 to RenderElement, making them branchless.
2482 Reviewed by Anders Carlsson.
2484 2013-12-26 ChangSeok Oh <changseok.oh@collabora.com>
2486 Unreviewed build fix after r159526.
2487 isBoxValue is used at out of ENABLE_CSS_SHAPES gaurd. It causes a compile failure.
2488 So I moved isBoxValue to out side of ENABLE_CSS_SHAPES.
2490 * css/CSSParser.cpp:
2492 2013-12-25 Gyuyoung Kim <gyuyoung.kim@samsung.com>
2494 Set m_pos as private in InlineIterator, and use getter and setter functions.
2495 https://bugs.webkit.org/show_bug.cgi?id=125614
2497 Reviewed by Alexey Proskuryakov.
2499 InlineIterator has been exported m_pos as public directly though it is member variable.
2500 This patch set it as private, and add getter/setter functions for it.
2502 No new tests, no behavior changes.
2504 * rendering/InlineIterator.h:
2505 (WebCore::InlineIterator::setOffset):
2506 (WebCore::operator==):
2507 (WebCore::operator!=):
2508 (WebCore::InlineBidiResolver::appendRun):
2509 * rendering/RenderBlockLineLayout.cpp:
2510 (WebCore::RenderBlockFlow::appendRunsForObject):
2511 (WebCore::constructBidiRunsForLine):
2512 (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange):
2513 (WebCore::RenderBlockFlow::matchedEndLine):
2514 (WebCore::LineBreaker::nextSegmentBreak):
2515 * rendering/line/BreakingContextInlineHeaders.h:
2516 (WebCore::BreakingContext::handleBR):
2517 (WebCore::BreakingContext::handleFloat):
2518 (WebCore::iteratorIsBeyondEndOfRenderCombineText):
2519 (WebCore::ensureCharacterGetsLineBox):
2520 (WebCore::BreakingContext::handleText):
2521 (WebCore::checkMidpoints):
2522 (WebCore::BreakingContext::handleEndOfLine):
2523 * rendering/line/TrailingObjects.cpp:
2524 (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes):
2526 2013-12-25 Kim Byung Jun <bj1987.kim@samsung.com>
2528 [EFL] Delete file.edc and file_*.png.
2529 https://bugs.webkit.org/show_bug.cgi?id=125134
2531 Reviewed by Gyuyoung Kim.
2533 File_theme uses button form.
2535 * platform/efl/DefaultTheme/CMakeLists.txt:
2536 * platform/efl/DefaultTheme/default.edc:
2537 * platform/efl/DefaultTheme/widget/file/file.edc: Removed.
2538 * platform/efl/DefaultTheme/widget/file/file_focus.png: Removed.
2539 * platform/efl/DefaultTheme/widget/file/file_hover.png: Removed.
2540 * platform/efl/DefaultTheme/widget/file/file_normal.png: Removed.
2541 * platform/efl/DefaultTheme/widget/file/file_press.png: Removed.
2543 2013-12-25 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
2545 [Nix] Adding createDragImageIconForCachedImageFilename method to DragImageNix
2546 https://bugs.webkit.org/show_bug.cgi?id=126230
2548 Reviewed by Daniel Bates.
2550 Also returning nullptr in other functions that were returning 0 as a pointer.
2552 * platform/nix/DragImageNix.cpp:
2553 (WebCore::createDragImageFromImage):
2554 (WebCore::createDragImageIconForCachedImage):
2555 (WebCore::createDragImageIconForCachedImageFilename):
2557 2013-12-25 Thiago de Barros Lacerda <thiago.lacerda@openbossa.org>
2559 [Nix] Fixing DragData::asFragment signature in DragDataNix.cpp
2560 https://bugs.webkit.org/show_bug.cgi?id=126229
2562 Reviewed by Daniel Bates.
2564 * platform/nix/DragDataNix.cpp:
2565 (WebCore::DragData::asFragment):
2567 2013-12-25 Commit Queue <commit-queue@webkit.org>
2569 Unreviewed, rolling out r161033 and r161074.
2570 http://trac.webkit.org/changeset/161033
2571 http://trac.webkit.org/changeset/161074
2572 https://bugs.webkit.org/show_bug.cgi?id=126240
2574 Oliver says that a rollout would be better (Requested by ap on
2577 * bindings/js/JSDOMWindowCustom.cpp:
2578 (WebCore::JSDOMWindow::put):
2579 * bindings/objc/WebScriptObject.mm:
2580 (-[WebScriptObject setValue:forKey:]):
2581 * bindings/scripts/CodeGeneratorJS.pm:
2582 (GenerateImplementation):
2583 * bindings/scripts/test/JS/JSTestInterface.cpp:
2584 (WebCore::JSTestInterface::putByIndex):
2585 * bridge/NP_jsobject.cpp:
2588 2013-12-25 Brady Eidson <beidson@apple.com>
2590 DatabaseProcess: Implement version changing
2591 https://bugs.webkit.org/show_bug.cgi?id=126099
2593 Reviewed by Sam Weinig.
2595 No new tests (No change in WebCore behavior).
2597 * Modules/indexeddb/IDBTransactionBackend.cpp:
2598 (WebCore::IDBTransactionBackend::commit): Update some logging.
2600 * Modules/indexeddb/IDBTransactionBackendOperations.cpp:
2601 (WebCore::IDBDatabaseBackend::VersionChangeOperation::perform): Move some things that used to be in
2602 IDBServerConnectionLevelDB::changeDatabaseVersion to this cross-platform location.
2603 * Modules/indexeddb/IDBTransactionBackendOperations.h:
2604 (WebCore::IDBDatabaseBackend::VersionChangeOperation::transaction):
2606 * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp:
2607 (WebCore::IDBServerConnectionLevelDB::changeDatabaseVersion): Move the actual updating of the database backend
2608 metadata to the VersionChangeOperation.
2610 2013-12-25 Martin Robinson <mrobinson@igalia.com>
2612 [GTK] [CMake] Clean up generated sources directories
2613 https://bugs.webkit.org/show_bug.cgi?id=126216
2615 Reviewed by Gustavo Noronha Silva.
2617 * PlatformGTK.cmake: Use the new directory variables.
2619 2013-12-25 Dirk Schulze <krit@webkit.org>
2621 Support <box> values parsing on 'clip-path' property
2622 https://bugs.webkit.org/show_bug.cgi?id=126147
2624 Reviewed by Ryosuke Niwa.
2626 Support parsing of the background reference boxes, margin-box and bounding-box.
2627 A box will be a reference box and define the origin for a basic shape.
2628 If no basic shape is specified, the box defines the clipping path itself.
2629 The specification text follows the changes to CSS Shapes now.
2631 https://dvcs.w3.org/hg/FXTF/raw-file/3f213145303e/css-masking-1/index.html#the-clip-path
2633 Existing parsing test have been extended to test box values as well.
2635 * css/CSSParser.cpp:
2636 (WebCore::CSSParser::parseValue):
2637 (WebCore::CSSParser::parseClipPath):
2639 * css/CSSValueKeywords.in:
2640 * css/DeprecatedStyleBuilder.cpp:
2641 (WebCore::ApplyPropertyClipPath::applyValue):
2643 2013-12-25 David Kilzer <ddkilzer@apple.com>
2645 [iOS] Upstream WebCore/pdf changes
2646 http://webkit.org/b/126097
2648 Reviewed by Sam Weinig.
2650 * WebCore.xcodeproj/project.pbxproj: Added files to project.
2651 * pdf/ios/PDFDocument.cpp: Added.
2652 (WebCore::PDFDocumentParser::create):
2653 (WebCore::PDFDocumentParser::document):
2654 (WebCore::PDFDocumentParser::PDFDocumentParser):
2655 (WebCore::PDFDocument::createParser):
2656 * pdf/ios/PDFDocument.h: Added.
2657 (WebCore::PDFDocument::create):
2658 (WebCore::PDFDocument::PDFDocument):
2660 2013-12-24 Commit Queue <commit-queue@webkit.org>
2662 Unreviewed, rolling out r160959.
2663 http://trac.webkit.org/changeset/160959
2664 https://bugs.webkit.org/show_bug.cgi?id=126222
2666 Caused Windows build to fail (Requested by rfong on #webkit).
2668 * platform/sql/SQLiteDatabase.cpp:
2669 (WebCore::SQLiteDatabase::interrupt):
2671 2013-12-24 Ryosuke Niwa <rniwa@webkit.org>
2673 Unreviewed, rolling out r161051.
2674 http://trac.webkit.org/changeset/161051
2675 https://bugs.webkit.org/show_bug.cgi?id=45994
2677 Caused two DFG tests to hit assertions due to a separate bug
2679 * xml/XMLHttpRequest.cpp:
2680 (WebCore::XMLHttpRequest::status):
2681 (WebCore::XMLHttpRequest::statusText):
2682 * xml/XMLHttpRequest.h:
2683 * xml/XMLHttpRequest.idl:
2685 2013-12-24 Mihnea Ovidenie <mihnea@adobe.com>
2687 [CSSRegions] Crash while repainting an invalid region
2688 https://bugs.webkit.org/show_bug.cgi?id=126152
2690 Reviewed by Daniel Bates.
2692 An invalid region, part of a dependency cycle, should not attempt to repaint content from
2693 its associated named flow, otherwise there may be the case of an infinite repaint cycle,
2694 resulting in a crash due to a stack overflow.
2696 Test: fast/regions/repaint/invalid-region-repaint-crash.html
2698 * rendering/RenderLayer.cpp:
2699 (WebCore::RenderLayer::repaintIncludingDescendants):
2701 2013-12-23 Ryosuke Niwa <rniwa@webkit.org>
2703 XMLHttpRequest: status and statusText throw DOM Exception 11 when the state is UNSENT or OPENED.
2704 https://bugs.webkit.org/show_bug.cgi?id=45994
2706 Reviewed by Alexey Proskuryakov.
2708 Merged https://chromium.googlesource.com/chromium/blink/+/23c90460de16e04c5aba7ed942fba76cb79fdb9b.
2710 Latest XHR spec says that XHR should return 0 and an empty string when it's in UNSENT or OPENED state
2711 or error flag is set: http://www.w3.org/TR/2012/WD-XMLHttpRequest-20121206/#the-status-attribute
2713 * xml/XMLHttpRequest.cpp:
2714 (WebCore::XMLHttpRequest::status):
2715 (WebCore::XMLHttpRequest::statusText):
2716 * xml/XMLHttpRequest.h:
2717 * xml/XMLHttpRequest.idl:
2719 2013-12-23 Ryosuke Niwa <rniwa@webkit.org>
2721 Crash in ReplaceSelectionCommand
2722 https://bugs.webkit.org/show_bug.cgi?id=126107
2724 Reviewed by Benjamin Poulain.
2726 Merge https://chromium.googlesource.com/chromium/blink/+/c1ebe5c1e808daf9db5e348a8d0ab32570b9f7a5
2727 except the test since it doesn't reproduce the crash in WebKit.
2729 * editing/ReplaceSelectionCommand.cpp:
2730 (WebCore::ReplaceSelectionCommand::doApply):
2732 2013-12-23 Benjamin Poulain <benjamin@webkit.org>
2734 Add the pseudo classes link and any-link to the Selector Code Generator
2735 https://bugs.webkit.org/show_bug.cgi?id=126196
2737 Reviewed by Ryosuke Niwa.
2739 * cssjit/SelectorCompiler.cpp:
2740 (WebCore::SelectorCompiler::addPseudoType):
2741 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
2742 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsLink):
2744 (WebCore::Node::flagIsElement):
2745 (WebCore::Node::flagIsLink):
2746 Fix the type to match TrustedImm32.
2748 2013-12-23 Benjamin Poulain <benjamin@webkit.org>
2750 Add the experimental CSS code generator files to the remaining build systems
2751 https://bugs.webkit.org/show_bug.cgi?id=126192
2753 Reviewed by Sam Weinig.
2756 * GNUmakefile.list.am:
2757 * WebCore.vcxproj/WebCore.vcxproj:
2758 * WebCore.vcxproj/WebCore.vcxproj.filters:
2760 2013-12-23 Benjamin Poulain <benjamin@webkit.org>
2762 Add the pseudo class :focus to the Selector Code Generator
2763 https://bugs.webkit.org/show_bug.cgi?id=126189
2765 Reviewed by Ryosuke Niwa.
2767 * cssjit/SelectorCompiler.cpp:
2768 (WebCore::SelectorCompiler::addPseudoType):
2769 (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
2770 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
2771 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementIsFocused):
2773 2013-12-23 Ryosuke Niwa <rniwa@webkit.org>
2775 Remove boolean argument from Element::setChildrenAffectBy* methods
2776 https://bugs.webkit.org/show_bug.cgi?id=126183
2778 Reviewed by Daniel Bates.
2780 Merge https://chromium.googlesource.com/chromium/blink/+/066ef2fa78336b2b65052cb17cb81b367fe7dbbf
2782 These functions are never called with false.
2784 * css/SelectorChecker.cpp:
2785 (WebCore::SelectorChecker::checkOne):
2787 (WebCore::Element::setChildrenAffectedByActive):
2788 (WebCore::Element::setChildrenAffectedByDrag):
2790 (WebCore::Element::setChildrenAffectedByHover):
2792 2013-12-23 Tim Horton <timothy_horton@apple.com>
2794 Fix the iOS build after r161013 and r160672.
2797 * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2798 (PlatformCALayerMac::updateCustomAppearance):
2800 2013-12-23 Oliver Hunt <oliver@apple.com>
2802 Refactor PutPropertySlot to be aware of custom properties
2803 https://bugs.webkit.org/show_bug.cgi?id=126187
2805 Reviewed by msaboff.
2807 Update the bindings code generation and custom objects
2808 to the new function signatures
2810 * bindings/js/JSDOMWindowCustom.cpp:
2811 (WebCore::JSDOMWindow::put):
2812 * bindings/objc/WebScriptObject.mm:
2813 (-[WebScriptObject setValue:forKey:]):
2814 * bindings/scripts/CodeGeneratorJS.pm:
2815 (GenerateImplementation):
2816 * bindings/scripts/test/JS/JSTestInterface.cpp:
2817 (WebCore::JSTestInterface::putByIndex):
2818 * bridge/NP_jsobject.cpp:
2821 2013-12-23 Benjamin Poulain <benjamin@webkit.org>
2823 Add class matching to the Selector Code Generator
2824 https://bugs.webkit.org/show_bug.cgi?id=126176
2826 Reviewed by Antti Koivisto.
2828 Add selector matching based on classname to the Selector Compiler.
2830 * cssjit/SelectorCompiler.cpp:
2831 (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
2832 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementDataMatching):
2833 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementHasClasses):
2834 * dom/ElementData.h:
2835 (WebCore::ElementData::classNamesMemoryOffset):
2836 * dom/SpaceSplitString.h:
2837 (WebCore::SpaceSplitStringData::sizeMemoryOffset):
2838 (WebCore::SpaceSplitStringData::tokensMemoryOffset):
2840 2013-12-23 Daniel Bates <dabates@apple.com>
2842 [iOS] Upstream WebCore/storage changes
2843 https://bugs.webkit.org/show_bug.cgi?id=125913
2845 Reviewed by David Kilzer.
2847 * storage/StorageAreaSync.cpp:
2848 (WebCore::StorageAreaSync::openDatabase): Added iOS-specific code.
2849 (WebCore::StorageAreaSync::sync): Ditto.
2850 * storage/StorageTracker.cpp:
2851 (WebCore::StorageTracker::openTrackerDatabase): Ditto.
2852 (WebCore::StorageTracker::syncImportOriginIdentifiers): Ditto.
2853 (WebCore::StorageTracker::syncFileSystemAndTrackerDatabase): Ditto.
2854 (WebCore::StorageTracker::syncSetOriginDetails): Ditto.
2855 (WebCore::StorageTracker::syncDeleteAllOrigins): Ditto.
2856 (WebCore::StorageTracker::syncDeleteOrigin): Ditto.
2857 (WebCore::StorageTracker::databasePathForOrigin): Ditto.
2859 2013-12-23 Daniel Bates <dabates@apple.com>
2861 Fix the iOS build following <http://trac.webkit.org/changeset/160236>
2862 (https://bugs.webkit.org/show_bug.cgi?id=125239)
2864 * rendering/RenderBlock.h:
2865 * rendering/RenderBox.cpp:
2866 (WebCore::RenderBox::containingBlockLogicalWidthForPositioned): Substitute view() for &view().
2867 * rendering/RenderLayer.cpp:
2868 (WebCore::RenderLayer::scrollTo): Fix indentation of closing brace.
2869 * rendering/RenderLayerCompositor.cpp: Include MainFrame.h.
2870 (WebCore::RenderLayerCompositor::contentsScaleMultiplierForNewTiles): Check that page->mainFrame().view()
2871 is non-null; also add explicit #else clause.
2872 (WebCore::RenderLayerCompositor::ensureRootLayer): Fix up main frame check.
2873 * rendering/RenderTheme.h:
2874 (WebCore::RenderTheme::paintFileUploadIconDecorations): Substitute rect for r.
2875 * rendering/RenderThemeIOS.mm:
2876 (WebCore::RenderThemeIOS::paintTextFieldDecorations): Use .get() to access underlying NeverDestroyed item.
2877 (WebCore::RenderThemeIOS::systemFont):
2878 * rendering/RenderView.cpp:
2879 (WebCore::fixedPositionOffset): Substitute frameView.scrollOffset() for frameView->scrollOffset().
2881 2013-12-23 Ryosuke Niwa <rniwa@webkit.org>
2883 Minor optimization in FrameSelection::setNonDirectionalSelectionIfNeeded()
2884 https://bugs.webkit.org/show_bug.cgi?id=126108
2886 Reviewed by Benjamin Poulain.
2888 Merge https://chromium.googlesource.com/chromium/blink/+/237b987c324e2e389a9e0350293bfaf16a5e201d
2890 * editing/FrameSelection.cpp:
2891 (WebCore::FrameSelection::setNonDirectionalSelectionIfNeeded):
2893 2013-12-23 Ryosuke Niwa <rniwa@webkit.org>
2895 Use isDocumentFragment() instead of comparing nodeType() with Node::DOCUMENT_FRAGMENT_NODE
2896 https://bugs.webkit.org/show_bug.cgi?id=126178
2898 Reviewed by Antti Koivisto.
2900 Inspired by https://chromium.googlesource.com/chromium/blink/+/a622cb80af2bfb0c5d91123cbcfa4fa72a06554c
2902 Use inline Node::isDocumentFragment() instead of virtual nodeType().
2904 * dom/ContainerNode.cpp:
2905 (WebCore::collectChildrenAndRemoveFromOldParent):
2907 (WebCore::Document::canReplaceChild):
2909 2013-12-23 Gwang Yoon Hwang <ryumiel@company100.net>
2911 Clear ScratchBuffer::m_lastLayerSize when clearing the scratch buffer.
2912 https://bugs.webkit.org/show_bug.cgi?id=126150
2914 Reviewed by Simon Fraser.
2916 Since ScratchBuffer::clearScratchBuffer only clears m_lastRadius,
2917 ShadowBlur doesn't draw shadow into the re-created scratch buffer if it
2918 tries to draw shadow without blurRadius.
2920 Clear m_lastLayerSize to empty is enought to ensure that there is no
2921 drawn contents in the scratch buffer.
2923 No new tests due to the flaky nature of reproducing the issue.
2925 * platform/graphics/ShadowBlur.cpp:
2926 (WebCore::ScratchBuffer::clearScratchBuffer):
2928 2013-12-23 Benjamin Poulain <benjamin@webkit.org>
2930 Add id matching to the Selector Code Generator
2931 https://bugs.webkit.org/show_bug.cgi?id=126154
2933 Reviewed by Antti Koivisto.
2935 Compile matching for #id selectors. IDs are Atomic String so it is just a matter
2936 of comparing the pointers.
2938 No attempt is made at optimizing for the double #id case because such problem
2939 do not really happen outside tests.
2941 * cssjit/SelectorCompiler.cpp:
2942 (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
2943 (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
2944 (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
2945 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
2946 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementDataMatching):
2947 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementHasId):
2949 (WebCore::Element::elementDataMemoryOffset):
2950 * dom/ElementData.h:
2951 (WebCore::ElementData::idForStyleResolutionMemoryOffset):
2953 2013-12-23 Oliver Hunt <oliver@apple.com>
2955 Update custom setter implementations to perform type checks
2956 https://bugs.webkit.org/show_bug.cgi?id=126171
2958 Reviewed by Daniel Bates.
2960 Update the bindings code generator for setters so that they perform a real
2963 * bindings/scripts/CodeGeneratorJS.pm:
2964 (GenerateAttributeEventListenerCall):
2966 (GenerateImplementation):
2967 * bindings/scripts/test/JS/JSTestInterface.cpp:
2968 (WebCore::setJSTestInterfaceConstructorImplementsStaticAttr):
2969 (WebCore::setJSTestInterfaceImplementsStr2):
2970 (WebCore::setJSTestInterfaceImplementsStr3):
2971 (WebCore::setJSTestInterfaceImplementsNode):
2972 (WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr):
2973 (WebCore::setJSTestInterfaceSupplementalStr2):
2974 (WebCore::setJSTestInterfaceSupplementalStr3):
2975 (WebCore::setJSTestInterfaceSupplementalNode):
2976 * bindings/scripts/test/JS/JSTestInterface.h:
2977 * bindings/scripts/test/JS/JSTestObj.cpp:
2978 (WebCore::setJSTestObjConstructorStaticStringAttr):
2979 (WebCore::setJSTestObjTestSubObjEnabledBySettingConstructor):
2980 (WebCore::setJSTestObjEnumAttr):
2981 (WebCore::setJSTestObjByteAttr):
2982 (WebCore::setJSTestObjOctetAttr):
2983 (WebCore::setJSTestObjShortAttr):
2984 (WebCore::setJSTestObjUnsignedShortAttr):
2985 (WebCore::setJSTestObjLongAttr):
2986 (WebCore::setJSTestObjLongLongAttr):
2987 (WebCore::setJSTestObjUnsignedLongLongAttr):
2988 (WebCore::setJSTestObjStringAttr):
2989 (WebCore::setJSTestObjTestObjAttr):
2990 (WebCore::setJSTestObjXMLObjAttr):
2991 (WebCore::setJSTestObjCreate):
2992 (WebCore::setJSTestObjReflectedStringAttr):
2993 (WebCore::setJSTestObjReflectedIntegralAttr):
2994 (WebCore::setJSTestObjReflectedUnsignedIntegralAttr):
2995 (WebCore::setJSTestObjReflectedBooleanAttr):
2996 (WebCore::setJSTestObjReflectedURLAttr):
2997 (WebCore::setJSTestObjReflectedCustomIntegralAttr):
2998 (WebCore::setJSTestObjReflectedCustomBooleanAttr):
2999 (WebCore::setJSTestObjReflectedCustomURLAttr):
3000 (WebCore::setJSTestObjTypedArrayAttr):
3001 (WebCore::setJSTestObjAttrWithGetterException):
3002 (WebCore::setJSTestObjAttrWithSetterException):
3003 (WebCore::setJSTestObjStringAttrWithGetterException):
3004 (WebCore::setJSTestObjStringAttrWithSetterException):
3005 (WebCore::setJSTestObjCustomAttr):
3006 (WebCore::setJSTestObjWithScriptStateAttribute):
3007 (WebCore::setJSTestObjWithScriptExecutionContextAttribute):
3008 (WebCore::setJSTestObjWithScriptStateAttributeRaises):
3009 (WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
3010 (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
3011 (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
3012 (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
3013 (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
3014 (WebCore::setJSTestObjConditionalAttr1):
3015 (WebCore::setJSTestObjConditionalAttr2):
3016 (WebCore::setJSTestObjConditionalAttr3):
3017 (WebCore::setJSTestObjConditionalAttr4Constructor):
3018 (WebCore::setJSTestObjConditionalAttr5Constructor):
3019 (WebCore::setJSTestObjConditionalAttr6Constructor):
3020 (WebCore::setJSTestObjAnyAttribute):
3021 (WebCore::setJSTestObjMutablePoint):
3022 (WebCore::setJSTestObjImmutablePoint):
3023 (WebCore::setJSTestObjStrawberry):
3024 (WebCore::setJSTestObjStrictFloat):
3025 (WebCore::setJSTestObjId):
3026 (WebCore::setJSTestObjReplaceableAttribute):
3027 (WebCore::setJSTestObjNullableLongSettableAttribute):
3028 (WebCore::setJSTestObjNullableStringValue):
3029 (WebCore::setJSTestObjAttributeWithReservedEnumType):
3030 * bindings/scripts/test/JS/JSTestObj.h:
3031 * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
3032 (WebCore::setJSTestSerializedScriptValueInterfaceValue):
3033 (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
3034 * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
3035 * bindings/scripts/test/JS/JSTestTypedefs.cpp:
3036 (WebCore::setJSTestTypedefsUnsignedLongLongAttr):
3037 (WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
3038 (WebCore::setJSTestTypedefsAttrWithGetterException):
3039 (WebCore::setJSTestTypedefsAttrWithSetterException):
3040 (WebCore::setJSTestTypedefsStringAttrWithGetterException):
3041 (WebCore::setJSTestTypedefsStringAttrWithSetterException):
3042 * bindings/scripts/test/JS/JSTestTypedefs.h:
3044 2013-12-23 Lucas Forschler <lforschler@apple.com>
3046 <rdar://problem/15682948> Update copyright strings
3048 Reviewed by Dan Bernstein
3052 2013-12-23 Commit Queue <commit-queue@webkit.org>
3054 Unreviewed, rolling out r160945.
3055 http://trac.webkit.org/changeset/160945
3056 https://bugs.webkit.org/show_bug.cgi?id=126164
3058 Seems to have broken multiple canvas tests (Requested by ap on
3061 * WebCore.xcodeproj/project.pbxproj:
3062 * platform/graphics/cg/ImageBufferBackingStoreCache.cpp: Removed.
3063 * platform/graphics/cg/ImageBufferBackingStoreCache.h: Removed.
3064 * platform/graphics/cg/ImageBufferCG.cpp:
3065 (WebCore::createIOSurface):
3066 (WebCore::ImageBuffer::ImageBuffer):
3067 (WebCore::ImageBuffer::~ImageBuffer):
3069 2013-12-23 Eric Carlson <eric.carlson@apple.com>
3071 AudioSessionManager should be MediaSessionManager
3072 https://bugs.webkit.org/show_bug.cgi?id=126087
3074 Reviewed by Jer Noble.
3076 No new tests, no change in functionality.
3078 * WebCore.xcodeproj/project.pbxproj: Change file names.
3080 * html/HTMLMediaElement.cpp:
3081 (WebCore::HTMLMediaElement::HTMLMediaElement): MediaSessionManagerToken::create() takes a client
3082 interface instead of the media type.
3083 * html/HTMLMediaElement.h:
3085 * platform/audio/AudioSessionListener.h: Include <wtf/Noncopyable.h>.
3087 AudioSessionManager.* -> MediaSessionManager.*
3088 * platform/audio/AudioSessionManager.cpp: Removed.
3089 * platform/audio/AudioSessionManager.h: Removed.
3090 * platform/audio/MediaSessionManager.cpp: Copied from Source/WebCore/platform/audio/AudioSessionManager.cpp.
3091 (MediaSessionManagerToken::create):
3092 (MediaSessionManagerToken::MediaSessionManagerToken):
3093 (MediaSessionManagerToken::~MediaSessionManagerToken):
3094 (MediaSessionManager::sharedManager):
3095 (MediaSessionManager::MediaSessionManager):
3096 (MediaSessionManager::has):
3097 (MediaSessionManager::count):
3098 (MediaSessionManager::addToken):
3099 (MediaSessionManager::removeToken):
3100 (MediaSessionManager::updateSessionState):
3101 * platform/audio/MediaSessionManager.h: Copied from Source/WebCore/platform/audio/AudioSessionManager.h.
3103 * platform/audio/mac/AudioDestinationMac.cpp:
3104 (WebCore::AudioDestinationMac::AudioDestinationMac): MediaSessionManagerToken::create() takes a
3105 client interface instead of the media type.
3106 * platform/audio/mac/AudioDestinationMac.h:
3108 * platform/audio/mac/AudioSessionMac.cpp:
3109 * platform/audio/mac/AudioSessionManagerMac.cpp: Removed.
3110 * platform/audio/mac/MediaSessionManagerMac.cpp: Copied from Source/WebCore/platform/audio/mac/AudioSessionManagerMac.cpp.
3111 (MediaSessionManager::updateSessionState):
3113 2013-12-23 Zan Dobersek <zdobersek@igalia.com>
3115 webkit gtk 2.2.3 stable tarball compilation error
3116 https://bugs.webkit.org/show_bug.cgi?id=125987
3118 Reviewed by Gustavo Noronha Silva.
3120 Only try including <gdk/gdkwayland.h> and using GDK_IS_WAYLAND_DISPLAY if the Wayland support has been
3121 enabled and when not compiling with GTK+ 2 (which occurs when building for libPlatformGtk2).
3123 * platform/graphics/GLContext.cpp:
3124 (WebCore::GLContext::createContextForWindow):
3126 2013-12-23 Piotr Grad <p.grad@samsung.com>
3128 [GStreamer] video/audio seeking is not unified.
3129 https://bugs.webkit.org/show_bug.cgi?id=125852
3131 Reviewed by Philippe Normand.
3133 This bug is fixing regression with seeking audio/video elements and unifies seeking
3134 in MediaPlayerPrivateGStreamer.
3136 Test: media/video-seek-with-negative-playback.html
3138 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
3139 (WebCore::MediaPlayerPrivateGStreamer::seek):
3140 (WebCore::MediaPlayerPrivateGStreamer::seekIncludingRate):
3141 (WebCore::MediaPlayerPrivateGStreamer::setRate):
3142 (WebCore::MediaPlayerPrivateGStreamer::updateStates):
3143 * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
3145 2013-12-23 ChangSeok Oh <changseok.oh@collabora.com>
3147 [GTK][WK2] WebGL is not working with GLES
3148 https://bugs.webkit.org/show_bug.cgi?id=126138
3150 Reviewed by Martin Robinson.
3152 m_texture has been unnecessarily regenerated. It's generated in GraphicsContext3D
3153 constructor for offscreen rendering. And m_compositorTexture is used by only Mac port.
3154 They create it in their GraphicsContext3D constructor so that we don't need to recreate it
3155 in GC3DOpenGLES::reshapeFBOs.
3157 No new tests since no functionality changed.
3159 * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
3160 (WebCore::GraphicsContext3D::~GraphicsContext3D):
3161 * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
3162 (WebCore::GraphicsContext3D::reshapeFBOs):
3163 * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
3164 (WebCore::GraphicsContext3D::reshapeFBOs):
3166 2013-12-22 Benjamin Poulain <bpoulain@apple.com>
3168 Create a skeleton for CSS Selector code generation
3169 https://bugs.webkit.org/show_bug.cgi?id=126044
3171 Reviewed by Antti Koivisto and Gavin Barraclough.
3173 Add CSSCompiler, which provides the basic infrastructure to compile
3174 CSS Selectors on x86_64.
3176 Compilation happens in two phases.
3177 1) The various matching and relation of each CSSSelector is aggregated into units
3178 matching a single element: SelectorFragment.
3179 SelectorFragment also knows about the relations between different fragments,
3180 and contains all the information to generate the code for a particular element.
3181 2) The compiler then goes over the fragments, and generate code based on the information
3184 It the current state, SelectorCompiler only compiles the tag matching selectors and
3185 any of the relation between selectors.
3187 Depending on the relation and position of a fragment, failure on traversal or matching
3188 does not necessarily causes the complete selector. A failure can cause matching to
3189 resume from the parent or the sibling of a previously visisted node.
3190 The implementation of this is done through the BacktrackingAction. In case of failure,
3191 the next starting state is setup and the program counter jumps back to the appropriate
3194 When backtracking, the method used to save the starting point depends on the type
3196 The child/parent relation (">") is very common so it uses an additional register to keep
3197 the next starting point (m_descendantBacktrackingStart).
3198 The indirect sibling relation ("~") is much less common and uses the stack to save
3199 the next starting point.
3201 * WebCore.xcodeproj/project.pbxproj:
3202 * cssjit/SelectorCompiler.cpp: Added.
3203 (WebCore::SelectorCompiler::SelectorFragment::SelectorFragment):
3204 (WebCore::SelectorCompiler::compileSelector):
3205 (WebCore::SelectorCompiler::fragmentRelationForSelectorRelation):
3206 (WebCore::SelectorCompiler::SelectorCodeGenerator::SelectorCodeGenerator):
3207 (WebCore::SelectorCompiler::SelectorCodeGenerator::compile):
3208 (WebCore::SelectorCompiler::updateChainStates):
3209 (WebCore::SelectorCompiler::isFirstAncestor):
3210 (WebCore::SelectorCompiler::isFirstAdjacent):
3211 (WebCore::SelectorCompiler::isAfterChildRelation):
3212 (WebCore::SelectorCompiler::solveBacktrackingAction):
3213 (WebCore::SelectorCompiler::requiresAdjacentTail):
3214 (WebCore::SelectorCompiler::requiresDescendantTail):
3215 (WebCore::SelectorCompiler::SelectorCodeGenerator::computeBacktrackingInformation):
3216 (WebCore::SelectorCompiler::testIsElementFlagOnNode):
3217 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToParentElement):
3218 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateParentElementTreeWalker):
3219 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAncestorTreeWalker):
3220 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateWalkToPreviousAdjacent):
3221 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDirectAdjacentTreeWalker):
3222 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateIndirectAdjacentTreeWalker):
3223 (WebCore::SelectorCompiler::SelectorCodeGenerator::markParentElementIfResolvingStyle):
3224 (WebCore::SelectorCompiler::SelectorCodeGenerator::linkFailures):
3225 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateAdjacentBacktrackingTail):
3226 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateDescendantBacktrackingTail):
3227 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateBacktrackingTailsIfNeeded):
3228 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementMatching):
3229 (WebCore::SelectorCompiler::SelectorCodeGenerator::generateElementHasTagName):
3230 * cssjit/SelectorCompiler.h: Added.
3231 (WebCore::SelectorCompilationStatus::SelectorCompilationStatus):
3232 (WebCore::SelectorCompilationStatus::operator Status):
3233 (WebCore::SelectorCompiler::simpleSelectorCheckerFunction):
3234 (WebCore::SelectorCompiler::selectorCheckerFunctionWithCheckingContext):
3236 (WebCore::Element::setChildrenAffectedByDirectAdjacentRules):
3237 (WebCore::Element::setChildrenAffectedByForwardPositionalRules):
3239 (WebCore::Element::tagQNameMemoryOffset):
3240 (WebCore::Element::setChildrenAffectedByForwardPositionalRules):
3242 (WebCore::Node::parentNodeMemoryOffset):
3243 (WebCore::Node::previousSiblingMemoryOffset):
3244 (WebCore::Node::nodeFlagsMemoryOffset):
3245 (WebCore::Node::flagIsElement):
3246 * dom/QualifiedName.h:
3247 (WebCore::QualifiedName::QualifiedNameImpl::localNameMemoryOffset):
3248 (WebCore::QualifiedName::QualifiedNameImpl::namespaceMemoryOffset):
3249 (WebCore::QualifiedName::implMemoryOffset):
3251 2013-12-22 Mihnea Ovidenie <mihnea@adobe.com>
3253 [CSSRegions] Crash when trying to select content from invalid region
3254 https://bugs.webkit.org/show_bug.cgi?id=126113
3256 Reviewed by Antti Koivisto.
3258 After fix for https://bugs.webkit.org/show_bug.cgi?id=120769, positionForPoint for a region attempts to use the associated named flow to perform its task.
3259 However, this should happen only when the region is valid. If the region is invalid, part of a dependency cycle, positionForPoint should behave as usual
3260 for a block instead of a region, otherwise it may run into an infinite loop due to cyclic dependencies and a crash will occur.
3262 This patch ensures that positionForPoint region specifie behaviour is followed only if the region is valid - not part of a dependency cycle.
3264 Test: fast/regions/selection/invalid-region-selection-crash.html
3266 * rendering/RenderRegion.cpp:
3267 (WebCore::RenderRegion::positionForPoint):
3269 2013-12-21 Dirk Schulze <krit@webkit.org>
3271 Start refactoring Filter code to reuse CachedSVGDocument for clipPath
3272 https://bugs.webkit.org/show_bug.cgi?id=126069
3274 Reviewed by Andreas Kling.
3276 Smaller refactoring of the CSS filter style resolver code. Previously the code
3277 requested the FilterOperations list from RenderStyle and compared the content
3278 in this list with an internal map. Then the resource loading was triggered.
3279 With the refactoring we do not request the list from RenderStyle anymore but
3280 rely on the hash map data entirely.
3282 * css/StyleResolver.cpp:
3283 (WebCore::StyleResolver::loadPendingSVGDocuments):
3284 * platform/graphics/filters/FilterOperation.h:
3286 2013-12-20 Andy Estes <aestes@apple.com>
3288 [Mac] Soft-link WebContentAnalysis.framework
3289 https://bugs.webkit.org/show_bug.cgi?id=126102
3291 Reviewed by Dan Bernstein.
3293 * Configurations/WebCore.xcconfig: There's no need to modify LDFLAGS
3294 now that we don't hard link against WebContentAnalysis.framework.
3295 * WebCore.xcodeproj/project.pbxproj: Removed
3296 WebContentAnalysis.framework from the 'Link Binary with Libraries'
3298 * platform/mac/ContentFilterMac.mm: Soft-linked
3299 WebContentAnalysis.framework and the WebFilterEvaluator @class.
3300 (WebCore::ContentFilter::ContentFilter): Called getWebFilterEvaluatorClass().
3301 (WebCore::ContentFilter::isEnabled): Ditto.
3302 * platform/mac/SoftLinking.h: Added an implementation of
3303 SOFT_LINK_PRIVATE_FRAMEWORK().
3305 2013-12-21 Antti Koivisto <antti@apple.com>
3307 Unreviewed, rolling out r160916.
3308 http://trac.webkit.org/changeset/160916
3309 https://bugs.webkit.org/show_bug.cgi?id=126073
3311 Roll out a temporary fix. The underlying issue was fixed.
3313 * accessibility/AccessibilityRenderObject.cpp:
3314 (WebCore::AccessibilityRenderObject::AccessibilityRenderObject):
3315 (WebCore::AccessibilityRenderObject::~AccessibilityRenderObject):
3316 (WebCore::AccessibilityRenderObject::detach):
3317 (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
3318 * accessibility/AccessibilityRenderObject.h:
3320 2013-12-21 Antti Koivisto <antti@apple.com>
3322 Figure out if node is focusable without requiring renderer
3323 https://bugs.webkit.org/show_bug.cgi?id=126118
3325 Reviewed by Andreas Kling.
3328 (WebCore::Element::computedStyle):
3330 Use inDocument() test instead of the attached() test. We can compute style for anything that
3334 (WebCore::Node::isContentEditable):
3335 (WebCore::Node::isContentRichlyEditable):
3336 (WebCore::Node::hasEditableStyle):
3338 Use computedStyle instead of getting the style from renderer. Computed style gets constructed
3339 on demand if renderer does not exist. If it does then the existing style is used.
3341 (WebCore::Node::isEditableToAccessibility):
3342 (WebCore::Node::canStartSelection):
3343 (WebCore::Node::isRootEditableElement):
3344 (WebCore::Node::rootEditableElement):
3346 (WebCore::Node::hasEditableStyle):
3347 (WebCore::Node::hasRichlyEditableStyle):
3349 Renamed from rendererIsEditable since these no longer require renderer.
3351 (WebCore::HTMLElement::supportsFocus):
3353 Stop calling updateStyleIfNeeded() and forcing render tree construction.
3355 2013-12-21 Carlos Garcia Campos <cgarcia@igalia.com>
3357 [SOUP] ResourceHandleSoup should use async client callbacks when client uses async callbacks
3358 https://bugs.webkit.org/show_bug.cgi?id=126006
3360 Reviewed by Martin Robinson.
3362 This fixes WebKit2 loader client unit tests when using the network
3365 * platform/network/ResourceHandle.cpp:
3366 * platform/network/soup/ResourceHandleSoup.cpp:
3367 (WebCore::doRedirect): Call willSendRequestAsync on the client
3368 when usesAsyncCallbacks returns true.
3369 (WebCore::nextMultipartResponsePartCallback): Call
3370 didReceiveResponseAsync on the client when usesAsyncCallbacks
3372 (WebCore::sendRequestCallback): Ditto.
3373 (WebCore::ResourceHandle::continueWillSendRequest): Empty
3374 implementation for now because the default one asserts.
3375 (WebCore::ResourceHandle::continueDidReceiveResponse): Ditto.
3376 (WebCore::ResourceHandle::continueShouldUseCredentialStorage): Ditto.
3378 2013-12-20 Anders Carlsson <andersca@apple.com>
3380 Replace yield() and pauseBriefly() with std::this_thread::yield()
3381 https://bugs.webkit.org/show_bug.cgi?id=126105
3383 Reviewed by Sam Weinig.
3385 * platform/sql/SQLiteDatabase.cpp:
3386 (WebCore::SQLiteDatabase::interrupt):
3388 2013-12-20 Ryosuke Niwa <rniwa@webkit.org>
3390 Assert that RootInlineBox::setLineBreakInfo should is never called on a RenderInline without line boxes
3391 https://bugs.webkit.org/show_bug.cgi?id=126101
3393 Reviewed by Simon Fraser.
3395 Merge assertions added in https://chromium.googlesource.com/chromium/blink/+/716ac74fd475b581d69c0aa8ec2d806201c3a420
3397 The code change was not merged since we never hit the added assertion on the attached test case in WebKit.
3399 * rendering/RootInlineBox.cpp:
3400 (WebCore::RootInlineBox::setLineBreakInfo):
3402 2013-12-20 Joseph Pecoraro <pecoraro@apple.com>
3404 Web Inspector: Remove the references to Node in InjectedScript
3405 https://bugs.webkit.org/show_bug.cgi?id=126091
3407 Reviewed by Timothy Hatcher.
3409 Remove the last DOM references from InjectedScript so that
3410 InjectedScript can move down into JavaScriptCore. The only
3411 remaining references were to Nodes, which are all just thin
3412 wrappers around existing functions. Move Node / JSNode (JSValue)
3413 conversion into InspectorDOMAgent, where it was used.
3415 No new tests, no observable change in functionality.
3417 * bindings/js/JSInjectedScriptHostCustom.cpp:
3418 * inspector/InjectedScript.cpp:
3419 (WebCore::InjectedScript::inspectObject):
3420 (WebCore::InjectedScript::releaseObject):
3421 * inspector/InjectedScript.h:
3422 * inspector/InjectedScriptHost.h:
3423 * inspector/InjectedScriptSource.js:
3424 * inspector/InspectorDOMAgent.cpp:
3425 (WebCore::InspectorDOMAgent::focusNode):
3426 (WebCore::InspectorDOMAgent::highlightNode):
3427 (WebCore::InspectorDOMAgent::requestNode):
3428 (WebCore::InspectorDOMAgent::nodeForObjectId):
3429 (WebCore::InspectorDOMAgent::resolveNode):
3430 (WebCore::InspectorDOMAgent::scriptValueAsNode):
3431 (WebCore::InspectorDOMAgent::nodeAsScriptValue):
3432 * inspector/InspectorDOMAgent.h:
3433 * inspector/PageConsoleAgent.cpp:
3435 2013-12-20 Myles C. Maxfield <mmaxfield@apple.com>
3437 Faster implementation of text-decoration-skip: ink
3438 https://bugs.webkit.org/show_bug.cgi?id=125718
3440 Reviewed by Simon Fraser.
3442 This new implementation of text-decoration-skip: ink extracts
3443 each glyph into a path, then decomposes each path into a series
3444 of contours. It then intersects each contour with the top and
3445 bottom of the underline (by approximating the contour with a line).
3446 It then draws underlines in between these intersection regions.
3448 Tests for text-decoration-skip: ink already exist in
3449 fast/css3-text/css3-text-decoration/text-decoration-skip
3451 * platform/graphics/Font.h: Signature of new function
3452 * platform/graphics/mac/FontMac.mm:
3453 (WebCore::GlyphIterationState::GlyphIterationState): Persistent
3454 between calls to findPathIntersections
3455 (WebCore::findIntersectionPoint): Calculates an intersection point
3457 (WebCore::findPathIntersections): Called by CGPathApply to find
3458 intersections of each contour
3459 (WebCore::Font::intersectionPoints): Function to get the places
3460 where an underline would intersect a TextRun.
3461 * rendering/InlineTextBox.cpp:
3462 (WebCore::compareTuples): Used for sorting intersection ranges
3463 (WebCore::translateIntersectionPointsToSkipInkBoundaries): Converts
3464 a sequence of intersection points to the locations where
3465 text-decoration-skip: ink should draw underlines
3466 (WebCore::drawSkipInkUnderline): Draws a sequence of short underlines
3467 (WebCore::InlineTextBox::paintDecoration):
3468 * rendering/TextPainter.cpp: