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

Side by Side Diff: third_party/WebKit/Source/core/paint/PaintLayerClipper.h

Issue 2621243002: Fix paint offset and clips in SPv2 (Closed)
Patch Set: none Created 3 years, 11 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved.
3 * Copyright (C) 2013 Intel Corporation. All rights reserved. 3 * Copyright (C) 2013 Intel Corporation. All rights reserved.
4 * 4 *
5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
6 * 6 *
7 * Other contributors: 7 * Other contributors:
8 * Robert O'Callahan <roc+@cs.cmu.edu> 8 * Robert O'Callahan <roc+@cs.cmu.edu>
9 * David Baron <dbaron@fas.harvard.edu> 9 * David Baron <dbaron@fas.harvard.edu>
10 * Christian Biesinger <cbiesinger@web.de> 10 * Christian Biesinger <cbiesinger@web.de>
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 ClipRects* clipRectsIfCached(const ClipRectsContext&) const; 207 ClipRects* clipRectsIfCached(const ClipRectsContext&) const;
208 ClipRects& storeClipRectsInCache(const ClipRectsContext&, 208 ClipRects& storeClipRectsInCache(const ClipRectsContext&,
209 ClipRects* parentClipRects, 209 ClipRects* parentClipRects,
210 const ClipRects&) const; 210 const ClipRects&) const;
211 211
212 void getOrCalculateClipRects(const ClipRectsContext&, ClipRects&) const; 212 void getOrCalculateClipRects(const ClipRectsContext&, ClipRects&) const;
213 213
214 bool shouldClipOverflow(const ClipRectsContext&) const; 214 bool shouldClipOverflow(const ClipRectsContext&) const;
215 bool shouldRespectOverflowClip(const ClipRectsContext&) const; 215 bool shouldRespectOverflowClip(const ClipRectsContext&) const;
216 216
217 // Returned clip rect is in the space of the context's rootLayer.
217 ClipRect clipRectWithGeometryMapper(const ClipRectsContext&, 218 ClipRect clipRectWithGeometryMapper(const ClipRectsContext&,
218 bool isForeground) const; 219 bool isForeground) const;
220 // Mutates the given rect into a rect in the space of the context's
221 // rootLayer.
219 void mapLocalToRootWithGeometryMapper(const ClipRectsContext&, 222 void mapLocalToRootWithGeometryMapper(const ClipRectsContext&,
220 LayoutRect& localRect) const; 223 LayoutRect&) const;
224 // Same as calculateRects, but using GeometryMapper.
221 void calculateRectsWithGeometryMapper( 225 void calculateRectsWithGeometryMapper(
222 const ClipRectsContext&, 226 const ClipRectsContext&,
223 const LayoutRect& paintDirtyRect, 227 const LayoutRect& paintDirtyRect,
224 LayoutRect& layerBounds, 228 LayoutRect& layerBounds,
225 ClipRect& backgroundRect, 229 ClipRect& backgroundRect,
226 ClipRect& foregroundRect, 230 ClipRect& foregroundRect,
227 const LayoutPoint* offsetFromRoot = 0) const; 231 const LayoutPoint* offsetFromRoot = 0) const;
228 232
229 ClipRect applyOverflowClipToBackgroundRectWithGeometryMapper( 233 ClipRect applyOverflowClipToBackgroundRectWithGeometryMapper(
230 const ClipRectsContext&, 234 const ClipRectsContext&,
231 const ClipRect&) const; 235 const ClipRect&) const;
232 236
233 const PaintLayer& m_layer; 237 const PaintLayer& m_layer;
234 std::unique_ptr<GeometryMapper> m_geometryMapper; 238 std::unique_ptr<GeometryMapper> m_geometryMapper;
239
240 friend class PaintLayerClipperTest;
235 }; 241 };
236 242
237 } // namespace blink 243 } // namespace blink
238 244
239 #endif // LayerClipper_h 245 #endif // LayerClipper_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698