Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 9b856c67d85184b03ecd0e893760f79b10fff69f
https://github.com/WebKit/WebKit/commit/9b856c67d85184b03ecd0e893760f79b10fff69f
Author: Sammy Gill <[email protected]>
Date: 2025-11-23 (Sun, 23 Nov 2025)
Changed paths:
M Source/WebCore/layout/formattingContexts/grid/GridLayout.cpp
M Source/WebCore/layout/formattingContexts/grid/GridLayout.h
M Source/WebCore/layout/formattingContexts/grid/GridTypeAliases.h
Log Message:
-----------
[GFC][Cleanup] Move grid item rects computation to its own function.
https://bugs.webkit.org/show_bug.cgi?id=302985
rdar://problem/165241488
Reviewed by Brandon Stewart.
The last step of GridLayout::layout is to map the various geometry we
computed during layout to a list of GridItemRects that will be used by
the formatting context and integration to map geometry back to the
renderers. Since this really isn't a part of grid layout strictly we can
move all of this logic to a dedicated function that we just call at the
end of layout. This improves the clarity of GridLayout::layout when you
want to read what this function is doing in regards to grid layout
specifically.
* Source/WebCore/layout/formattingContexts/grid/GridLayout.cpp:
(WebCore::Layout::computeGridItemRects):
(WebCore::Layout::GridLayout::layout):
(WebCore::Layout::GridLayout::performInlineAxisSelfAlignment):
(WebCore::Layout::GridLayout::performBlockAxisSelfAlignment):
(WebCore::Layout::GridLayout::layoutGridItems const):
* Source/WebCore/layout/formattingContexts/grid/GridLayout.h:
* Source/WebCore/layout/formattingContexts/grid/GridTypeAliases.h:
Canonical link: https://commits.webkit.org/303464@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications