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

Side by Side Diff: Source/core/paint/DeprecatedPaintLayer.cpp

Issue 1122323002: Cleanup: Remove LayoutRegion. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase master Created 5 years, 7 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
5 * 5 *
6 * Other contributors: 6 * Other contributors:
7 * Robert O'Callahan <roc+@cs.cmu.edu> 7 * Robert O'Callahan <roc+@cs.cmu.edu>
8 * David Baron <dbaron@fas.harvard.edu> 8 * David Baron <dbaron@fas.harvard.edu>
9 * Christian Biesinger <cbiesinger@web.de> 9 * Christian Biesinger <cbiesinger@web.de>
10 * Randall Jesup <rjesup@wgate.com> 10 * Randall Jesup <rjesup@wgate.com>
(...skipping 1341 matching lines...) Expand 10 before | Expand all | Expand 10 after
1352 static inline const DeprecatedPaintLayer* accumulateOffsetTowardsAncestor(const DeprecatedPaintLayer* layer, const DeprecatedPaintLayer* ancestorLayer, LayoutPo int& location) 1352 static inline const DeprecatedPaintLayer* accumulateOffsetTowardsAncestor(const DeprecatedPaintLayer* layer, const DeprecatedPaintLayer* ancestorLayer, LayoutPo int& location)
1353 { 1353 {
1354 ASSERT(ancestorLayer != layer); 1354 ASSERT(ancestorLayer != layer);
1355 1355
1356 const LayoutBoxModelObject* layoutObject = layer->layoutObject(); 1356 const LayoutBoxModelObject* layoutObject = layer->layoutObject();
1357 EPosition position = layoutObject->style()->position(); 1357 EPosition position = layoutObject->style()->position();
1358 1358
1359 // FIXME: Positioning of out-of-flow(fixed, absolute) elements collected in a LayoutFlowThread 1359 // FIXME: Positioning of out-of-flow(fixed, absolute) elements collected in a LayoutFlowThread
1360 // may need to be revisited in a future patch. 1360 // may need to be revisited in a future patch.
1361 // If the fixed layoutObject is inside a LayoutFlowThread, we should not com pute location using localToAbsolute, 1361 // If the fixed layoutObject is inside a LayoutFlowThread, we should not com pute location using localToAbsolute,
1362 // since localToAbsolute maps the coordinates from flow thread to regions co ordinates and regions can be 1362 // since localToAbsolute maps the coordinates from flow thread to column set coordinates and column sets can be
1363 // positioned in a completely different place in the viewport (LayoutView). 1363 // positioned in a completely different place in the viewport (LayoutView).
1364 if (position == FixedPosition && (!ancestorLayer || ancestorLayer == layoutO bject->view()->layer())) { 1364 if (position == FixedPosition && (!ancestorLayer || ancestorLayer == layoutO bject->view()->layer())) {
1365 // If the fixed layer's container is the root, just add in the offset of the view. We can obtain this by calling 1365 // If the fixed layer's container is the root, just add in the offset of the view. We can obtain this by calling
1366 // localToAbsolute() on the LayoutView. 1366 // localToAbsolute() on the LayoutView.
1367 FloatPoint absPos = layoutObject->localToAbsolute(FloatPoint(), IsFixed) ; 1367 FloatPoint absPos = layoutObject->localToAbsolute(FloatPoint(), IsFixed) ;
1368 location += LayoutSize(absPos.x(), absPos.y()); 1368 location += LayoutSize(absPos.x(), absPos.y());
1369 return ancestorLayer; 1369 return ancestorLayer;
1370 } 1370 }
1371 1371
1372 // For the fixed positioned elements inside a layout flow thread, we should also skip the code path below 1372 // For the fixed positioned elements inside a layout flow thread, we should also skip the code path below
(...skipping 1604 matching lines...) Expand 10 before | Expand all | Expand 10 after
2977 } 2977 }
2978 } 2978 }
2979 2979
2980 void showLayerTree(const blink::LayoutObject* layoutObject) 2980 void showLayerTree(const blink::LayoutObject* layoutObject)
2981 { 2981 {
2982 if (!layoutObject) 2982 if (!layoutObject)
2983 return; 2983 return;
2984 showLayerTree(layoutObject->enclosingLayer()); 2984 showLayerTree(layoutObject->enclosingLayer());
2985 } 2985 }
2986 #endif 2986 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698