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

Side by Side Diff: Source/core/rendering/RenderLayer.cpp

Issue 164553004: Convert LayoutState/LayoutStateMaintainer/LayoutStateDisabler to references (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 6 years, 10 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
« no previous file with comments | « Source/core/rendering/RenderInline.cpp ('k') | Source/core/rendering/RenderListBox.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 948 matching lines...) Expand 10 before | Expand all | Expand 10 after
959 if (renderer()->isOutOfFlowPositioned() && enclosingPositionedAncestor()) { 959 if (renderer()->isOutOfFlowPositioned() && enclosingPositionedAncestor()) {
960 RenderLayer* positionedParent = enclosingPositionedAncestor(); 960 RenderLayer* positionedParent = enclosingPositionedAncestor();
961 961
962 // For positioned layers, we subtract out the enclosing positioned layer 's scroll offset. 962 // For positioned layers, we subtract out the enclosing positioned layer 's scroll offset.
963 if (positionedParent->renderer()->hasOverflowClip()) { 963 if (positionedParent->renderer()->hasOverflowClip()) {
964 LayoutSize offset = positionedParent->renderBox()->scrolledContentOf fset(); 964 LayoutSize offset = positionedParent->renderBox()->scrolledContentOf fset();
965 localPoint -= offset; 965 localPoint -= offset;
966 } 966 }
967 967
968 if (renderer()->isOutOfFlowPositioned() && positionedParent->renderer()- >isInFlowPositioned() && positionedParent->renderer()->isRenderInline()) { 968 if (renderer()->isOutOfFlowPositioned() && positionedParent->renderer()- >isInFlowPositioned() && positionedParent->renderer()->isRenderInline()) {
969 LayoutSize offset = toRenderInline(positionedParent->renderer())->of fsetForInFlowPositionedInline(toRenderBox(renderer())); 969 LayoutSize offset = toRenderInline(positionedParent->renderer())->of fsetForInFlowPositionedInline(*toRenderBox(renderer()));
970 localPoint += offset; 970 localPoint += offset;
971 } 971 }
972 } else if (parent()) { 972 } else if (parent()) {
973 if (hasCompositedLayerMapping()) { 973 if (hasCompositedLayerMapping()) {
974 // FIXME: Composited layers ignore pagination, so about the best we can do is make sure they're offset into the appropriate column. 974 // FIXME: Composited layers ignore pagination, so about the best we can do is make sure they're offset into the appropriate column.
975 // They won't split across columns properly. 975 // They won't split across columns properly.
976 LayoutSize columnOffset; 976 LayoutSize columnOffset;
977 if (!parent()->renderer()->hasColumns() && parent()->renderer()->isR oot() && renderer()->view()->hasColumns()) 977 if (!parent()->renderer()->hasColumns() && parent()->renderer()->isR oot() && renderer()->view()->hasColumns())
978 renderer()->view()->adjustForColumns(columnOffset, localPoint); 978 renderer()->view()->adjustForColumns(columnOffset, localPoint);
979 else 979 else
(...skipping 3040 matching lines...) Expand 10 before | Expand all | Expand 10 after
4020 } 4020 }
4021 } 4021 }
4022 4022
4023 void showLayerTree(const WebCore::RenderObject* renderer) 4023 void showLayerTree(const WebCore::RenderObject* renderer)
4024 { 4024 {
4025 if (!renderer) 4025 if (!renderer)
4026 return; 4026 return;
4027 showLayerTree(renderer->enclosingLayer()); 4027 showLayerTree(renderer->enclosingLayer());
4028 } 4028 }
4029 #endif 4029 #endif
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderInline.cpp ('k') | Source/core/rendering/RenderListBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698