Browse Source

LibWeb: Skip frozen tracks while distributing space in GFC

Aliaksandr Kalenik 2 năm trước cách đây
mục cha
commit
2d05c63c7c

+ 3 - 0
Userland/Libraries/LibWeb/Layout/GridFormattingContext.cpp

@@ -895,6 +895,9 @@ void GridFormattingContext::distribute_extra_space_across_spanned_tracks(CSSPixe
         // increase reaches its limit
         CSSPixels increase_per_track = extra_space / spanned_tracks.size();
         for (auto& track : spanned_tracks) {
+            if (track.frozen)
+                continue;
+
             if (increase_per_track >= track.growth_limit) {
                 track.frozen = true;
                 track.item_incurred_increase = track.growth_limit;