Source/WebCore/ChangeLog

 12021-05-16 Tim Nguyen <ntim@apple.com>
 2
 3 will-change: position should not create a containing block for position: fixed elements
 4 https://bugs.webkit.org/show_bug.cgi?id=225443
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 This partially undoes r276627 which made will-change: position create a CB for all out-of-flow elements:
 9
 10 - Removed CSSPropertyPosition from createsContainingBlockForOutOfFlowPositioned() to not create a containing block
 11 for position: fixed; children.
 12 - Added createsContainingBlockForAbsolutelyPositioned() with CSSPropertyPosition to still create a containing block
 13 for position: absolute; children.
 14
 15 Enabled WPT (which covers both cases): css/css-will-change/will-change-fixpos-cb-position-1.html
 16
 17 * rendering/RenderElement.h:
 18 (WebCore::RenderElement::canContainAbsolutelyPositionedObjects const):
 19 * rendering/style/WillChangeData.cpp:
 20 (WebCore::WillChangeData::createsContainingBlockForAbsolutelyPositioned const):
 21 (WebCore::WillChangeData::createsContainingBlockForOutOfFlowPositioned const):
 22 * rendering/style/WillChangeData.h:
 23
1242021-05-16 Alan Bujtas <zalan@apple.com>
225
326 [LFC] Cleanup FormattingContext class

Source/WebCore/rendering/RenderElement.h

@@inline bool RenderElement::canContainAbsolutelyPositionedObjects() const
449449 return style().position() != PositionType::Static
450450 || (isRenderBlock() && hasTransformRelatedProperty())
451451 // FIXME: will-change should create containing blocks on inline boxes (bug 225035)
452  || (isRenderBlock() && style().willChange() && style().willChange()->createsContainingBlockForOutOfFlowPositioned())
 452 || (isRenderBlock() && style().willChange() && style().willChange()->createsContainingBlockForAbsolutelyPositioned())
453453 || isSVGForeignObject()
454454 || shouldApplyLayoutContainment(*this)
455455 || isRenderView();

Source/WebCore/rendering/style/WillChangeData.cpp

@@bool WillChangeData::containsProperty(CSSPropertyID property) const
6060 return false;
6161}
6262
 63bool WillChangeData::createsContainingBlockForAbsolutelyPositioned() const
 64{
 65 return createsContainingBlockForOutOfFlowPositioned()
 66 || containsProperty(CSSPropertyPosition);
 67}
 68
6369bool WillChangeData::createsContainingBlockForOutOfFlowPositioned() const
6470{
65  return containsProperty(CSSPropertyPosition)
66  || containsProperty(CSSPropertyPerspective)
 71 return containsProperty(CSSPropertyPerspective)
6772 // CSS transforms
6873 || containsProperty(CSSPropertyTransform)
6974 || containsProperty(CSSPropertyTransformStyle)

Source/WebCore/rendering/style/WillChangeData.h

@@public:
5252 bool containsContents() const;
5353 bool containsProperty(CSSPropertyID) const;
5454
 55 bool createsContainingBlockForAbsolutelyPositioned() const;
5556 bool createsContainingBlockForOutOfFlowPositioned() const;
5657 bool canCreateStackingContext() const { return m_canCreateStackingContext; }
5758 bool canTriggerCompositing() const { return m_canTriggerCompositing; }

LayoutTests/ChangeLog

 12021-05-16 Tim Nguyen <ntim@apple.com>
 2
 3 will-change: position should not create a containing block for position: fixed elements
 4 https://bugs.webkit.org/show_bug.cgi?id=225443
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 This partially undoes r276627 which made will-change: position create a CB for all out-of-flow elements:
 9
 10 - Removed CSSPropertyPosition from createsContainingBlockForOutOfFlowPositioned() to not create a containing block
 11 for position: fixed; children.
 12 - Added createsContainingBlockForAbsolutelyPositioned() with CSSPropertyPosition to still create a containing block
 13 for position: absolute; children.
 14
 15 Enabled WPT (which covers both cases): css/css-will-change/will-change-fixpos-cb-position-1.html
 16
 17 * TestExpectations:
 18
1192021-05-16 Sam Weinig <weinig@apple.com>
220
321 Add support for creating/accessing/setting non-sRGB ImageData via canvas

LayoutTests/TestExpectations

@@webkit.org/b/224928 imported/w3c/web-platform-tests/css/css-will-change/will-cha
48594859webkit.org/b/225035 imported/w3c/web-platform-tests/css/css-will-change/will-change-fixedpos-cb-002.html [ ImageOnlyFailure ]
48604860webkit.org/b/225034 imported/w3c/web-platform-tests/css/css-will-change/will-change-fixedpos-cb-003.html [ ImageOnlyFailure ]
48614861webkit.org/b/225442 imported/w3c/web-platform-tests/css/css-will-change/will-change-fixpos-cb-contain-1.html [ ImageOnlyFailure ]
4862 webkit.org/b/225443 imported/w3c/web-platform-tests/css/css-will-change/will-change-fixpos-cb-position-1.html [ ImageOnlyFailure ]
48634862webkit.org/b/224902 [ Debug ] imported/w3c/web-platform-tests/css/css-will-change/parsing/will-change-invalid.html [ Skip ]
48644863
48654864# Implement offset-* properties