Bug 207937

Summary: [LFC][Floats] FloatingContext::constraints should be able to handle empty candidate ranges (points)
Product: WebKit Reporter: zalan <zalan>
Component: Layout and RenderingAssignee: zalan <zalan>
Status: RESOLVED FIXED    
Severity: Normal CC: bfulgham, commit-queue, koivisto, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Description zalan 2020-02-19 08:25:11 PST
when the candidate range is empty.
Comment 1 Radar WebKit Bug Importer 2020-02-19 08:25:52 PST
<rdar://problem/59591109>
Comment 2 zalan 2020-02-19 08:30:32 PST
Created attachment 391165 [details]
Patch
Comment 3 Antti Koivisto 2020-02-19 08:46:11 PST
Comment on attachment 391165 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=391165&action=review

> Source/WebCore/layout/floats/FloatingContext.cpp:308
> +                return floatBoxRect.top() <= adjustedCandidateTop && floatBoxRect.bottom() > adjustedCandidateTop;
> +            return !(floatBoxRect.top() >= adjustedCandidateBottom || floatBoxRect.bottom() <= adjustedCandidateTop);

The difference between these would be clearer if the logic was the same way round (that is no !)
Comment 4 zalan 2020-02-19 08:51:58 PST
(In reply to Antti Koivisto from comment #3)
> Comment on attachment 391165 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=391165&action=review
> 
> > Source/WebCore/layout/floats/FloatingContext.cpp:308
> > +                return floatBoxRect.top() <= adjustedCandidateTop && floatBoxRect.bottom() > adjustedCandidateTop;
> > +            return !(floatBoxRect.top() >= adjustedCandidateBottom || floatBoxRect.bottom() <= adjustedCandidateTop);
> 
> The difference between these would be clearer if the logic was the same way
> round (that is no !)
sure.
Comment 5 zalan 2020-02-19 09:40:00 PST
Created attachment 391173 [details]
Patch
Comment 6 WebKit Commit Bot 2020-02-19 11:30:25 PST
Comment on attachment 391173 [details]
Patch

Clearing flags on attachment: 391173

Committed r256928: <https://trac.webkit.org/changeset/256928>
Comment 7 WebKit Commit Bot 2020-02-19 11:30:27 PST
All reviewed patches have been landed.  Closing bug.