Changeset 277579 in webkit
- Timestamp:
- May 17, 2021 3:09:03 AM (14 months ago)
- Location:
- trunk
- Files:
-
- 6 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/TestExpectations (modified) (1 diff)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/rendering/RenderElement.h (modified) (1 diff)
-
Source/WebCore/rendering/style/WillChangeData.cpp (modified) (1 diff)
-
Source/WebCore/rendering/style/WillChangeData.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r277577 r277579 1 2021-05-17 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 Antti Koivisto. 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 1 19 2021-05-16 Cameron McCormack <heycam@apple.com> 2 20 -
trunk/LayoutTests/TestExpectations
r277577 r277579 4858 4858 webkit.org/b/225034 imported/w3c/web-platform-tests/css/css-will-change/will-change-fixedpos-cb-003.html [ ImageOnlyFailure ] 4859 4859 webkit.org/b/225442 imported/w3c/web-platform-tests/css/css-will-change/will-change-fixpos-cb-contain-1.html [ ImageOnlyFailure ] 4860 webkit.org/b/225443 imported/w3c/web-platform-tests/css/css-will-change/will-change-fixpos-cb-position-1.html [ ImageOnlyFailure ]4861 4860 webkit.org/b/224902 [ Debug ] imported/w3c/web-platform-tests/css/css-will-change/parsing/will-change-invalid.html [ Skip ] 4862 4861 -
trunk/Source/WebCore/ChangeLog
r277578 r277579 1 2021-05-17 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 Antti Koivisto. 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 1 24 2021-05-17 Zan Dobersek <zdobersek@igalia.com> 2 25 -
trunk/Source/WebCore/rendering/RenderElement.h
r277124 r277579 450 450 || (isRenderBlock() && hasTransformRelatedProperty()) 451 451 // FIXME: will-change should create containing blocks on inline boxes (bug 225035) 452 || (isRenderBlock() && style().willChange() && style().willChange()->createsContainingBlockFor OutOfFlowPositioned())452 || (isRenderBlock() && style().willChange() && style().willChange()->createsContainingBlockForAbsolutelyPositioned()) 453 453 || isSVGForeignObject() 454 454 || shouldApplyLayoutContainment(*this) -
trunk/Source/WebCore/rendering/style/WillChangeData.cpp
r277566 r277579 61 61 } 62 62 63 bool WillChangeData::createsContainingBlockForAbsolutelyPositioned() const 64 { 65 return createsContainingBlockForOutOfFlowPositioned() 66 || containsProperty(CSSPropertyPosition); 67 } 68 63 69 bool WillChangeData::createsContainingBlockForOutOfFlowPositioned() const 64 70 { 65 return containsProperty(CSSPropertyPosition) 66 || containsProperty(CSSPropertyPerspective) 71 return containsProperty(CSSPropertyPerspective) 67 72 // CSS transforms 68 73 || containsProperty(CSSPropertyTransform) -
trunk/Source/WebCore/rendering/style/WillChangeData.h
r276627 r277579 53 53 bool containsProperty(CSSPropertyID) const; 54 54 55 bool createsContainingBlockForAbsolutelyPositioned() const; 55 56 bool createsContainingBlockForOutOfFlowPositioned() const; 56 57 bool canCreateStackingContext() const { return m_canCreateStackingContext; }
Note: See TracChangeset
for help on using the changeset viewer.