Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fork out Masonry into a separate layout function #9410

Commits on Feb 1, 2023

  1. Fork out Masonry into a separate layout function

    https://bugs.webkit.org/show_bug.cgi?id=251459
    
    Reviewed by Matt Woodrow.
    
    I have been finding a significant amount of special cases are getting added to
    the grid code to handle masonry. This has been getting rather messy to maintain,
    and splitting these two would allow easier changes to the layout to support masonry without
    worrying about breaking grid.
    
    * Source/WebCore/rendering/GridMasonryLayout.cpp:
    (WebCore::GridMasonryLayout::collectMasonryItems):
    * Source/WebCore/rendering/GridTrackSizingAlgorithm.cpp:
    (WebCore::GridTrack::cachedTrackSize const):
    * Source/WebCore/rendering/GridTrackSizingAlgorithm.h:
    (WebCore::GridTrack::cachedTrackSize const): Deleted.
    * Source/WebCore/rendering/RenderGrid.cpp:
    (WebCore::RenderGrid::layoutBlock):
    (WebCore::RenderGrid::layoutGrid):
    (WebCore::RenderGrid::layoutMasonry):
    * Source/WebCore/rendering/RenderGrid.h:
    
    Canonical link: https://commits.webkit.org/259662@main
    stwrt committed Feb 1, 2023
    Configuration menu
    Copy the full SHA
    48fe5d1 View commit details
    Browse the repository at this point in the history