Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(145)

Unified Diff: third_party/WebKit/Source/core/layout/LayoutObject.h

Issue 1817693002: Support edge-inclusive intersections in mapToVisibleRectInAncestorSpace (Closed) Base URL: https://chromium.googlesource.com/chromium/src@intersection-observer-idle-callback
Patch Set: Added IntersectionType flag and unit test for LayoutRect::inclusiveIntersect. Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/layout/LayoutObject.h
diff --git a/third_party/WebKit/Source/core/layout/LayoutObject.h b/third_party/WebKit/Source/core/layout/LayoutObject.h
index 387058354128dc2e7c11ef76bba0ec84dd51844c..13ea135ad572cc47043dd1c271372a22cbb9e726 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.h
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.h
@@ -1148,7 +1148,10 @@ public:
// Given a rect in the object's coordinate space, compute a rect in the coordinate space of |ancestor|. If
// intermediate containers have clipping or scrolling of any kind, it is applied; but overflow clipping is *not*
// applied for |ancestor| itself. The output rect is suitable for purposes such as paint invalidation.
- virtual void mapToVisibleRectInAncestorSpace(const LayoutBoxModelObject* ancestor, LayoutRect&, const PaintInvalidationState*) const;
+ // The return value indicates whether the output rect actually has a visible intersection
+ // with the ancestor. If flags is EdgeInclusive, the return value can be true even if the
+ // resulting rect is zero-area.
chrishtr 2016/03/22 17:25:49 "intersection" might lead to the wrong conclusions
szager1 2016/03/22 18:33:35 I think the best documentation is what I wrote for
+ virtual bool mapToVisibleRectInAncestorSpace(const LayoutBoxModelObject* ancestor, LayoutRect&, const PaintInvalidationState*, int flags = 0) const;
chrishtr 2016/03/22 17:25:49 IntersectionFlags instead of int
eae 2016/03/22 17:54:16 Use unsigned (or typedef for unsigned as Chris sug
szager1 2016/03/22 19:42:24 Done.
// Return the offset to the column in which the specified point (in flow-thread coordinates)
// lives. This is used to convert a flow-thread point to a visual point.

Powered by Google App Engine
This is Rietveld 408576698